httrack-3.49.5/0000755000175000017500000000000014555203200010251 500000000000000httrack-3.49.5/test-driver0000755000175000017500000001141714555203165012405 00000000000000#! /bin/sh # test-driver - basic testsuite driver script. scriptversion=2018-03-07.03; # UTC # Copyright (C) 2011-2021 Free Software Foundation, Inc. # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2, or (at your option) # any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see . # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. # This file is maintained in Automake, please report # bugs to or send patches to # . # Make unconditional expansion of undefined variables an error. This # helps a lot in preventing typo-related bugs. set -u usage_error () { echo "$0: $*" >&2 print_usage >&2 exit 2 } print_usage () { cat <"$log_file" "$@" >>"$log_file" 2>&1 estatus=$? if test $enable_hard_errors = no && test $estatus -eq 99; then tweaked_estatus=1 else tweaked_estatus=$estatus fi case $tweaked_estatus:$expect_failure in 0:yes) col=$red res=XPASS recheck=yes gcopy=yes;; 0:*) col=$grn res=PASS recheck=no gcopy=no;; 77:*) col=$blu res=SKIP recheck=no gcopy=yes;; 99:*) col=$mgn res=ERROR recheck=yes gcopy=yes;; *:yes) col=$lgn res=XFAIL recheck=no gcopy=yes;; *:*) col=$red res=FAIL recheck=yes gcopy=yes;; esac # Report the test outcome and exit status in the logs, so that one can # know whether the test passed or failed simply by looking at the '.log' # file, without the need of also peaking into the corresponding '.trs' # file (automake bug#11814). echo "$res $test_name (exit status: $estatus)" >>"$log_file" # Report outcome to console. echo "${col}${res}${std}: $test_name" # Register the test result, and other relevant metadata. echo ":test-result: $res" > $trs_file echo ":global-test-result: $res" >> $trs_file echo ":recheck: $recheck" >> $trs_file echo ":copy-in-global-log: $gcopy" >> $trs_file # Local Variables: # mode: shell-script # sh-indentation: 2 # eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" # time-stamp-end: "; # UTC" # End: httrack-3.49.5/tests/0000755000175000017500000000000014555203200011413 500000000000000httrack-3.49.5/tests/check-network.sh0000755000175000017500000000164214336470674014463 00000000000000#!/bin/bash # # ensure the httrack unit tests are available so that ut will not break # the build in case of network outage # do not enable online tests (./configure --disable-online-unit-tests) if test "$ONLINE_UNIT_TESTS" == "no"; then echo "online tests are disabled" >&2 exit 1 # enable online tests (--enable-online-unit-tests) elif test "$ONLINE_UNIT_TESTS" == "yes"; then exit 0 # check if online tests are reachable else # test url url=http://ut.httrack.com/enabled # cache file name cache=check-network_sh.cache # cached result ? if test -f $cache ; then if grep -q "ok" $cache ; then exit 0 else echo "online tests are disabled (cached)" >&2 exit 1 fi # fetch single file elif bash crawl-test.sh --errors 0 --files 1 httrack --timeout=3 --max-time=3 "$url" 2>/dev/null >/dev/null ; then echo "ok" > $cache exit 0 else echo "error" > $cache echo "online tests are disabled (auto)" >&2 exit 1 fi fi httrack-3.49.5/tests/run-all-tests.sh0000755000175000017500000000040714336470674014427 00000000000000#!/bin/bash # error=0 for i in *.test ; do if bash $i ; then echo "$i: passed" >&2 else echo "$i: ERROR" >&2 error=$[${error}+1] fi done if test "$error" -eq 0; then echo "all tests passed" >&2 else echo "${error} test(s) failed" >&2 fi exit $error httrack-3.49.5/tests/crawl-test.sh0000755000175000017500000001034214336470674014001 00000000000000#!/bin/bash # function warning { echo "** $*" >&2 return 0 } function die { warning "$*" exit 1 } function debug { if test -n "$verbose"; then echo "$*" >&2 fi } function info { printf "[$*] ..\t" >&2 } function result { echo "$*" >&2 } function cleanup { debug "cleaning function called" if test -n "$tmpdir"; then if test -d "$tmpdir"; then if test -z "$nopurge"; then debug "cleaning up $tmpdir" rm -rf "$tmpdir" fi fi fi if test -n "$crawlpid"; then debug "killing $crawlpid" kill -9 "$crawlpid" crawlpid= fi } function usage { cat << EOF usage: $0 EOF } function assert_equals { info "$1" if test ! "$2" == "$3"; then result "expected '$2', got '$3'" exit 1 else result "OK ($2)" fi } function start-crawl { # parse args pos=1 while test "$#" -ge "$pos" ; do case "${!pos}" in --debug) verbose=1 ;; --no-purge|--summary|--print-files) ;; --errors|--files|--found|--not-found|--directory) pos=$[${pos}+1] test "$#" -ge "$pos" || warning "missing argument" || return 1 ;; httrack) pos=$[${pos}+1] break; ;; *) warning "unrecognized option ${!pos}" return 1 ;; esac pos=$[${pos}+1] done debug "remaining args: ${@:${pos}}" # ut/ won't exceed 2 minutes moreargs="--quiet --max-time=120 --timeout=30 --connection-per-second=5" # proxy environment ? if test -n "$http_proxy"; then moreargs="$moreargs --proxy $http_proxy" fi test -n "$tmpdir" || ! warning "no tmpdir" || return 1 tmp="${tmpdir}/crawl" rm -rf "$tmp" mkdir "$tmp" || ! warning "could not create $tmp" || return 1 which httrack >/dev/null || ! warning "could not find httrack" || return 1 ver=$(httrack -O /dev/null --version | sed -e 's/HTTrack version //') test -n "$ver" || ! warning "could not run httrack" || return 1 # start crawl log="${tmp}/log" debug starting httrack -O "${tmp}" ${moreargs} ${@:${pos}} info "running httrack ${@:${pos}}" httrack -O "${tmp}" --user-agent="httrack $ver ut ($(uname -omrs))" ${moreargs} ${@:${pos}} >"${log}" 2>&1 & crawlpid="$!" debug "started cralwer on pid $crawlpid" wait "$crawlpid" result="$?" crawlpid= test "$result" -eq 0 || ! result "error code $result" || return 1 result "OK" grep -iE "^[0-9\:]*[[:space:]]Error:" "${tmp}/hts-log.txt" >&2 # now audit while test "$#" -gt 0; do case "$1" in --no-purge) nopurge=1 ;; --summary) grep -E "^HTTrack Website Copier/[^ ]* mirror complete in " "${tmp}/hts-log.txt" ;; --print-files) find "${tmp}" -mindepth 1 -type f ;; --errors) shift assert_equals "checking errors" "$1" "$(grep -iEc "^[0-9\:]*[[:space:]]Error:" "${tmp}/hts-log.txt")" ;; --found) shift info "checking for $1" if test -f "${tmp}/$1" ; then result "OK" else result "not found" exit 1 fi ;; --not-found) shift info "checking for $1" if test -f "${tmp}/$1" ; then result "OK" else result "not found" exit 1 fi ;; --directory) shift info "checking for $1" if test -d "${tmp}/$1" ; then result "OK" else result "not found" exit 1 fi ;; --files) shift nFiles=$(grep -E "^HTTrack Website Copier/[^ ]* mirror complete in " "${tmp}/hts-log.txt" \ | sed -e 's/.*[[:space:]]\([^ ]*\)[[:space:]]files written.*/\1/g') assert_equals "checking files" "$1" "$nFiles" ;; httrack) break; ;; esac shift done # cleanup if test -z "$nopurge"; then rm -rf "$tmp" else tmpdir= fi } # check args test "$#" -le 0 && usage && exit 0 # tmptopdir=${TMPDIR:-/tmp} test -d "$tmptopdir" || mkdir -p "${tmptopdir}" || die "can not find a temporary directory ; please set TMPDIR" # final cleanup tmpdir= crawlpid= nopurge= verbose= trap "cleanup" 0 1 2 3 4 5 6 7 8 9 11 13 14 15 16 19 24 25 # working directory tmpdir="${tmptopdir}/httrack_ut.$$" mkdir "${tmpdir}" # rock'in start-crawl "${@}" # that's all, folks! httrack-3.49.5/tests/12_crawl_https.test0000755000175000017500000000042214336470674015113 00000000000000#!/bin/bash # bash check-network.sh || ! echo "skipping online unit tests" || exit 77 if test "$HTTPS_SUPPORT" == "no"; then echo "no https support compiled, skipping" exit 77 fi bash crawl-test.sh --errors 0 --files 5 httrack https://ut.httrack.com/simple/basic.html httrack-3.49.5/tests/11_crawl-parsing.test0000755000175000017500000000347714336470674015346 00000000000000#!/bin/bash # bash check-network.sh || ! echo "skipping online unit tests" || exit 77 # http://code.google.com/p/httrack/issues/detail?id=4&can=1 bash crawl-test.sh --errors 0 --files 4 \ --found ut.httrack.com/parsing/back5e1f.gif \ --found ut.httrack.com/parsing/events.html \ --found ut.httrack.com/parsing/fade230f4.gif \ --found ut.httrack.com/parsing/fade3860.gif \ httrack http://ut.httrack.com/parsing/events.html # http://code.google.com/p/httrack/issues/detail?id=2&can=1 bash crawl-test.sh --errors 0 --files 3 \ --found ut.httrack.com/parsing/background-image.css \ --found ut.httrack.com/parsing/background-image.html \ --found ut.httrack.com/parsing/fade.gif \ httrack http://ut.httrack.com/parsing/background-image.html # javascript parsing bash crawl-test.sh --errors 0 --files 3 \ --found ut.httrack.com/parsing/back.gif \ --found ut.httrack.com/parsing/fade.gif \ --found ut.httrack.com/parsing/javascript.html \ httrack http://ut.httrack.com/parsing/javascript.html # handling of + before query string bash crawl-test.sh --errors 0 --files 6 \ --found ut.httrack.com/parsing/escaping.html \ --found "ut.httrack.com/parsing/foo bar30f4.html" \ --found "ut.httrack.com/parsing/foo bar5e1f.html" \ --found "ut.httrack.com/parsing/foo+bar+plus3860.html" \ --found "ut.httrack.com/parsing/foo barae52.html" \ --found "ut.httrack.com/parsing/foo bar7b30.html" \ httrack http://ut.httrack.com/parsing/escaping.html # handling of # encoded in filename # see http://code.google.com/p/httrack/issues/detail?id=25 bash crawl-test.sh --errors 2 --files 4 \ --found "ut.httrack.com/parsing/escaping2.html" \ --found "ut.httrack.com/parsing/++foo++bar++plus++.html" \ --found "ut.httrack.com/parsing/foo#bar#.html" \ --found "ut.httrack.com/parsing/foo bar.html" \ httrack http://ut.httrack.com/parsing/escaping2.html httrack-3.49.5/tests/11_crawl-longurl.test0000755000175000017500000000062714336470674015357 00000000000000#!/bin/bash # bash check-network.sh || ! echo "skipping online unit tests" || exit 77 # http://code.google.com/p/httrack/issues/detail?id=42&can=1 # we expect 2 errors only because other links are too longs (to be modified if suitable) bash crawl-test.sh --errors 2 --files 1 \ --found ut.httrack.com/overflow/longquerywithaccents.html \ httrack http://ut.httrack.com/overflow/longquerywithaccents.php httrack-3.49.5/tests/11_crawl-international.test0000755000175000017500000000576514336470674016554 00000000000000#!/bin/bash # bash check-network.sh || ! echo "skipping online unit tests" || exit 77 # unicode tests bash crawl-test.sh \ --errors 1 --files 10 \ --found ut.httrack.com/unicode-links/caf%a91bce.html \ --found ut.httrack.com/unicode-links/café30f4.html \ --found ut.httrack.com/unicode-links/café3860.html \ --found ut.httrack.com/unicode-links/café463e.html \ --found ut.httrack.com/unicode-links/café5e1f.html \ --found ut.httrack.com/unicode-links/café7b30.html \ --found ut.httrack.com/unicode-links/café8007.html \ --found ut.httrack.com/unicode-links/café9fa8.html \ --found ut.httrack.com/unicode-links/caféae52.html \ --found ut.httrack.com/unicode-links/caféc009.html \ --found ut.httrack.com/unicode-links/utf8.html \ httrack http://ut.httrack.com/unicode-links/utf8.html bash crawl-test.sh \ --errors 4 --files 7 \ --found ut.httrack.com/unicode-links/café3860.html \ --found ut.httrack.com/unicode-links/café9fa8.html \ --found ut.httrack.com/unicode-links/café30f4.html \ --found ut.httrack.com/unicode-links/café5e1f.html \ --found ut.httrack.com/unicode-links/café7b30.html \ --found ut.httrack.com/unicode-links/café8007.html \ --found ut.httrack.com/unicode-links/caf%e939bd.html \ --found ut.httrack.com/unicode-links/caf%e9ae52.html \ --found ut.httrack.com/unicode-links/caféaec2.html \ --found ut.httrack.com/unicode-links/caféfad6.html \ --found ut.httrack.com/unicode-links/default.html \ httrack http://ut.httrack.com/unicode-links/default.html bash crawl-test.sh \ --errors 2 --files 9 \ --found ut.httrack.com/unicode-links/caf%a9ae52.html \ --found ut.httrack.com/unicode-links/caf%a9bf59.html \ --found ut.httrack.com/unicode-links/café30f4.html \ --found ut.httrack.com/unicode-links/café3860.html \ --found ut.httrack.com/unicode-links/café5e1f.html \ --found ut.httrack.com/unicode-links/café647f.html \ --found ut.httrack.com/unicode-links/café7b30.html \ --found ut.httrack.com/unicode-links/café8007.html \ --found ut.httrack.com/unicode-links/caféaec2.html \ --found ut.httrack.com/unicode-links/caféfad6.html \ --found ut.httrack.com/unicode-links/iso88591.html \ httrack http://ut.httrack.com/unicode-links/iso88591.html bash crawl-test.sh \ --errors 4 --files 9 \ --found ut.httrack.com/unicode-links/caf%a8%a6c72a.html \ --found ut.httrack.com/unicode-links/caf%a9bf59.html \ --found ut.httrack.com/unicode-links/café8007.html \ --found ut.httrack.com/unicode-links/cafébf43.html \ --found ut.httrack.com/unicode-links/cafédcd8.html \ --found ut.httrack.com/unicode-links/café2461.html \ --found ut.httrack.com/unicode-links/caf%a8%a61bce.html \ --found ut.httrack.com/unicode-links/caf%a9ae52.html \ --found ut.httrack.com/unicode-links/café7b30.html \ --found ut.httrack.com/unicode-links/café30f4.html \ --found ut.httrack.com/unicode-links/café5e1f.html \ --found ut.httrack.com/unicode-links/café3860.html \ --found ut.httrack.com/unicode-links/gb18030.html \ httrack http://ut.httrack.com/unicode-links/gb18030.html httrack-3.49.5/tests/11_crawl-idna.test0000755000175000017500000000130714336470674014604 00000000000000#!/bin/bash # bash check-network.sh || ! echo "skipping online unit tests" || exit 77 # unicode tests bash crawl-test.sh \ --errors 1 --files 5 \ --found 'café.ut.httrack.com/unicode-links/café3860.html' \ --found 'café.ut.httrack.com/unicode-links/café30f4.html' \ --found 'café.ut.httrack.com/unicode-links/café5e1f.html' \ --found 'café.ut.httrack.com/unicode-links/café7b30.html' \ httrack 'http://ut.httrack.com/unicode-links/idna.html' \ '+*.ut.httrack.com/*' --robots=0 # unicode tests (bogus links) bash crawl-test.sh \ --errors 0 --files 1 \ --found 'ut.httrack.com/unicode-links/idna_bogus.html' \ httrack 'http://ut.httrack.com/unicode-links/idna_bogus.html' \ '-*' --robots=0 httrack-3.49.5/tests/11_crawl-cookies.test0000755000175000017500000000050214336470674015321 00000000000000#!/bin/bash # bash check-network.sh || ! echo "skipping online unit tests" || exit 77 bash crawl-test.sh --errors 0 --files 3 \ --found ut.httrack.com/cookies/third.html \ --found ut.httrack.com/cookies/second.html \ --found ut.httrack.com/cookies/entrance.html \ httrack http://ut.httrack.com/cookies/entrance.php httrack-3.49.5/tests/10_crawl-simple.test0000755000175000017500000000026114336470674015157 00000000000000#!/bin/bash # bash check-network.sh || ! echo "skipping online unit tests" || exit 77 bash crawl-test.sh --errors 0 --files 5 httrack http://ut.httrack.com/simple/basic.html httrack-3.49.5/tests/01_engine-simplify.test0000755000175000017500000000075014336470674015662 00000000000000#!/bin/bash # # simplify engine test "$(httrack -O /dev/null -#1 ./foo/bar/)" == "simplified=foo/bar/" || exit 1 test "$(httrack -O /dev/null -#1 ./foo/bar)" == "simplified=foo/bar" || exit 1 test "$(httrack -O /dev/null -#1 ./foo/./bar)" == "simplified=foo/bar" || exit 1 test "$(httrack -O /dev/null -#1 ./foo/bar/.././tmp/foobar)" == "simplified=foo/tmp/foobar" || exit 1 test "$(httrack -O /dev/null -#1 ./foo/bar/.././tmp/foobar/../foobaz)" == "simplified=foo/tmp/foobaz" || exit 1 httrack-3.49.5/tests/01_engine-idna.test0000755000175000017500000000072214336470674014740 00000000000000#!/bin/bash # # IDNA routine test "$(httrack -O /dev/null -#4 "www.café.com")" == "www.xn--caf-dma.com" || exit 1 test "$(httrack -O /dev/null -#4 "www.もののけ姫-the-movie.com")" == "www.xn---the-movie-g63irla2z8297c.com" || exit 1 # reverse IDNA test "$(httrack -O /dev/null -#5 "www.xn--caf-dma.com")" == "www.café.com" || exit 1 test "$(httrack -O /dev/null -#5 "www.xn---the-movie-g63irla2z8297c.com")" == "www.もののけ姫-the-movie.com" || exit 1 httrack-3.49.5/tests/01_engine-hashtable.test0000755000175000017500000000012514336470674015755 00000000000000#!/bin/bash # # httrack internal hashtable autotest on 100K keys httrack -#7 100000 httrack-3.49.5/tests/01_engine-entities.test0000755000175000017500000000036214336470674015651 00000000000000#!/bin/bash # # basic entities handling (with boggy entities handling) test "$(httrack -O /dev/null -#6 "&foo; thé&café&#e9;もののけ姫")" == "&foo; thé&café&#e9;もののけ姫" || exit 1 httrack-3.49.5/tests/01_engine-charset.test0000755000175000017500000000017214336470674015455 00000000000000#!/bin/bash # # minimalistic charset test test "$(httrack -O /dev/null -#3 "iso-8859-1" "café")" == "café" || exit 1 httrack-3.49.5/tests/00_runnable.test0000755000175000017500000000011014336470674014356 00000000000000#!/bin/bash # # check that httrack starts httrack --version >/dev/null httrack-3.49.5/tests/Makefile.in0000644000175000017500000006461114555203173013421 00000000000000# Makefile.in generated by automake 1.16.5 from Makefile.am. # @configure_input@ # Copyright (C) 1994-2021 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ VPATH = @srcdir@ am__is_gnu_make = { \ if test -z '$(MAKELEVEL)'; then \ false; \ elif test -n '$(MAKE_HOST)'; then \ true; \ elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ true; \ else \ false; \ fi; \ } am__make_running_with_option = \ case $${target_option-} in \ ?) ;; \ *) echo "am__make_running_with_option: internal error: invalid" \ "target option '$${target_option-}' specified" >&2; \ exit 1;; \ esac; \ has_opt=no; \ sane_makeflags=$$MAKEFLAGS; \ if $(am__is_gnu_make); then \ sane_makeflags=$$MFLAGS; \ else \ case $$MAKEFLAGS in \ *\\[\ \ ]*) \ bs=\\; \ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ esac; \ fi; \ skip_next=no; \ strip_trailopt () \ { \ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ }; \ for flg in $$sane_makeflags; do \ test $$skip_next = yes && { skip_next=no; continue; }; \ case $$flg in \ *=*|--*) continue;; \ -*I) strip_trailopt 'I'; skip_next=yes;; \ -*I?*) strip_trailopt 'I';; \ -*O) strip_trailopt 'O'; skip_next=yes;; \ -*O?*) strip_trailopt 'O';; \ -*l) strip_trailopt 'l'; skip_next=yes;; \ -*l?*) strip_trailopt 'l';; \ -[dEDm]) skip_next=yes;; \ -[JT]) skip_next=yes;; \ esac; \ case $$flg in \ *$$target_option*) has_opt=yes; break;; \ esac; \ done; \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkglibexecdir = $(libexecdir)/@PACKAGE@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ subdir = tests ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/check_zlib.m4 \ $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/snprintf.m4 \ $(top_srcdir)/m4/visibility.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = AM_V_P = $(am__v_P_@AM_V@) am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) am__v_P_0 = false am__v_P_1 = : AM_V_GEN = $(am__v_GEN_@AM_V@) am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) am__v_GEN_0 = @echo " GEN " $@; am__v_GEN_1 = AM_V_at = $(am__v_at_@AM_V@) am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) am__v_at_0 = @ am__v_at_1 = SOURCES = DIST_SOURCES = am__can_run_installinfo = \ case $$AM_UPDATE_INFO_DIR in \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) am__tty_colors_dummy = \ mgn= red= grn= lgn= blu= brg= std=; \ am__color_tests=no am__tty_colors = { \ $(am__tty_colors_dummy); \ if test "X$(AM_COLOR_TESTS)" = Xno; then \ am__color_tests=no; \ elif test "X$(AM_COLOR_TESTS)" = Xalways; then \ am__color_tests=yes; \ elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \ am__color_tests=yes; \ fi; \ if test $$am__color_tests = yes; then \ red=''; \ grn=''; \ lgn=''; \ blu=''; \ mgn=''; \ brg=''; \ std=''; \ fi; \ } am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ *) f=$$p;; \ esac; am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; am__install_max = 40 am__nobase_strip_setup = \ srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` am__nobase_strip = \ for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" am__nobase_list = $(am__nobase_strip_setup); \ for p in $$list; do echo "$$p $$p"; done | \ sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ if (++n[$$2] == $(am__install_max)) \ { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ END { for (dir in files) print dir, files[dir] }' am__base_list = \ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' am__uninstall_files_from_dir = { \ test -z "$$files" \ || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ $(am__cd) "$$dir" && rm -f $$files; }; \ } am__recheck_rx = ^[ ]*:recheck:[ ]* am__global_test_result_rx = ^[ ]*:global-test-result:[ ]* am__copy_in_global_log_rx = ^[ ]*:copy-in-global-log:[ ]* # A command that, given a newline-separated list of test names on the # standard input, print the name of the tests that are to be re-run # upon "make recheck". am__list_recheck_tests = $(AWK) '{ \ recheck = 1; \ while ((rc = (getline line < ($$0 ".trs"))) != 0) \ { \ if (rc < 0) \ { \ if ((getline line2 < ($$0 ".log")) < 0) \ recheck = 0; \ break; \ } \ else if (line ~ /$(am__recheck_rx)[nN][Oo]/) \ { \ recheck = 0; \ break; \ } \ else if (line ~ /$(am__recheck_rx)[yY][eE][sS]/) \ { \ break; \ } \ }; \ if (recheck) \ print $$0; \ close ($$0 ".trs"); \ close ($$0 ".log"); \ }' # A command that, given a newline-separated list of test names on the # standard input, create the global log from their .trs and .log files. am__create_global_log = $(AWK) ' \ function fatal(msg) \ { \ print "fatal: making $@: " msg | "cat >&2"; \ exit 1; \ } \ function rst_section(header) \ { \ print header; \ len = length(header); \ for (i = 1; i <= len; i = i + 1) \ printf "="; \ printf "\n\n"; \ } \ { \ copy_in_global_log = 1; \ global_test_result = "RUN"; \ while ((rc = (getline line < ($$0 ".trs"))) != 0) \ { \ if (rc < 0) \ fatal("failed to read from " $$0 ".trs"); \ if (line ~ /$(am__global_test_result_rx)/) \ { \ sub("$(am__global_test_result_rx)", "", line); \ sub("[ ]*$$", "", line); \ global_test_result = line; \ } \ else if (line ~ /$(am__copy_in_global_log_rx)[nN][oO]/) \ copy_in_global_log = 0; \ }; \ if (copy_in_global_log) \ { \ rst_section(global_test_result ": " $$0); \ while ((rc = (getline line < ($$0 ".log"))) != 0) \ { \ if (rc < 0) \ fatal("failed to read from " $$0 ".log"); \ print line; \ }; \ printf "\n"; \ }; \ close ($$0 ".trs"); \ close ($$0 ".log"); \ }' # Restructured Text title. am__rst_title = { sed 's/.*/ & /;h;s/./=/g;p;x;s/ *$$//;p;g' && echo; } # Solaris 10 'make', and several other traditional 'make' implementations, # pass "-e" to $(SHELL), and POSIX 2008 even requires this. Work around it # by disabling -e (using the XSI extension "set +e") if it's set. am__sh_e_setup = case $$- in *e*) set +e;; esac # Default flags passed to test drivers. am__common_driver_flags = \ --color-tests "$$am__color_tests" \ --enable-hard-errors "$$am__enable_hard_errors" \ --expect-failure "$$am__expect_failure" # To be inserted before the command running the test. Creates the # directory for the log if needed. Stores in $dir the directory # containing $f, in $tst the test, in $log the log. Executes the # developer- defined test setup AM_TESTS_ENVIRONMENT (if any), and # passes TESTS_ENVIRONMENT. Set up options for the wrapper that # will run the test scripts (or their associated LOG_COMPILER, if # thy have one). am__check_pre = \ $(am__sh_e_setup); \ $(am__vpath_adj_setup) $(am__vpath_adj) \ $(am__tty_colors); \ srcdir=$(srcdir); export srcdir; \ case "$@" in \ */*) am__odir=`echo "./$@" | sed 's|/[^/]*$$||'`;; \ *) am__odir=.;; \ esac; \ test "x$$am__odir" = x"." || test -d "$$am__odir" \ || $(MKDIR_P) "$$am__odir" || exit $$?; \ if test -f "./$$f"; then dir=./; \ elif test -f "$$f"; then dir=; \ else dir="$(srcdir)/"; fi; \ tst=$$dir$$f; log='$@'; \ if test -n '$(DISABLE_HARD_ERRORS)'; then \ am__enable_hard_errors=no; \ else \ am__enable_hard_errors=yes; \ fi; \ case " $(XFAIL_TESTS) " in \ *[\ \ ]$$f[\ \ ]* | *[\ \ ]$$dir$$f[\ \ ]*) \ am__expect_failure=yes;; \ *) \ am__expect_failure=no;; \ esac; \ $(AM_TESTS_ENVIRONMENT) $(TESTS_ENVIRONMENT) # A shell command to get the names of the tests scripts with any registered # extension removed (i.e., equivalently, the names of the test logs, with # the '.log' extension removed). The result is saved in the shell variable # '$bases'. This honors runtime overriding of TESTS and TEST_LOGS. Sadly, # we cannot use something simpler, involving e.g., "$(TEST_LOGS:.log=)", # since that might cause problem with VPATH rewrites for suffix-less tests. # See also 'test-harness-vpath-rewrite.sh' and 'test-trs-basic.sh'. am__set_TESTS_bases = \ bases='$(TEST_LOGS)'; \ bases=`for i in $$bases; do echo $$i; done | sed 's/\.log$$//'`; \ bases=`echo $$bases` AM_TESTSUITE_SUMMARY_HEADER = ' for $(PACKAGE_STRING)' RECHECK_LOGS = $(TEST_LOGS) AM_RECURSIVE_TARGETS = check recheck TEST_SUITE_LOG = test-suite.log am__test_logs1 = $(TESTS:=.log) am__test_logs2 = $(am__test_logs1:@EXEEXT@.log=.log) TEST_LOGS = $(am__test_logs2:.test.log=.log) TEST_LOG_DRIVER = $(SHELL) $(top_srcdir)/test-driver TEST_LOG_COMPILE = $(TEST_LOG_COMPILER) $(AM_TEST_LOG_FLAGS) \ $(TEST_LOG_FLAGS) am__set_b = \ case '$@' in \ */*) \ case '$*' in \ */*) b='$*';; \ *) b=`echo '$@' | sed 's/\.log$$//'`; \ esac;; \ *) \ b='$*';; \ esac am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/test-driver DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AM_CFLAGS = @AM_CFLAGS@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CFLAGS_PIE = @CFLAGS_PIE@ CFLAG_VISIBILITY = @CFLAG_VISIBILITY@ CPPFLAGS = @CPPFLAGS@ CSCOPE = @CSCOPE@ CTAGS = @CTAGS@ CYGPATH_W = @CYGPATH_W@ DEFAULT_CFLAGS = @DEFAULT_CFLAGS@ DEFAULT_LDFLAGS = @DEFAULT_LDFLAGS@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DLLTOOL = @DLLTOOL@ DL_LIBS = @DL_LIBS@ DSYMUTIL = @DSYMUTIL@ DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ ETAGS = @ETAGS@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ FILECMD = @FILECMD@ GREP = @GREP@ HAVE_VISIBILITY = @HAVE_VISIBILITY@ HTTPS_SUPPORT = @HTTPS_SUPPORT@ ICONV_LIBS = @ICONV_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LD = @LD@ LDFLAGS = @LDFLAGS@ LDFLAGS_PIE = @LDFLAGS_PIE@ LFS_FLAG = @LFS_FLAG@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ LIPO = @LIPO@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ LT_CV_OBJDIR = @LT_CV_OBJDIR@ LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ MAINT = @MAINT@ MAKEINFO = @MAKEINFO@ MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ NM = @NM@ NMEDIT = @NMEDIT@ OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ ONLINE_UNIT_TESTS = @ONLINE_UNIT_TESTS@ OPENSSL_LIBS = @OPENSSL_LIBS@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ RANLIB = @RANLIB@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ SHLIBPATH_VAR = @SHLIBPATH_VAR@ SOCKET_LIBS = @SOCKET_LIBS@ STRIP = @STRIP@ THREADS_CFLAGS = @THREADS_CFLAGS@ THREADS_LIBS = @THREADS_LIBS@ V6_FLAG = @V6_FLAG@ VERSION = @VERSION@ VERSION_INFO = @VERSION_INFO@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ builddir = @builddir@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ runstatedir = @runstatedir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ EXTRA_DIST = $(TESTS) crawl-test.sh run-all-tests.sh check-network.sh # note: libtool should handle that ### TESTS_ENVIRONMENT += $(SHLIBPATH_VAR)="$(top_builddir)/src/$(LT_CV_OBJDIR)$${$(SHLIBPATH_VAR):+$(PATH_SEPARATOR)}$$$(SHLIBPATH_VAR)" TESTS_ENVIRONMENT = PATH=$(top_builddir)/src$(PATH_SEPARATOR)$$PATH \ ONLINE_UNIT_TESTS=$(ONLINE_UNIT_TESTS) \ HTTPS_SUPPORT=$(HTTPS_SUPPORT) TEST_EXTENSIONS = .test TESTS = 00_runnable.test 01_engine-charset.test 01_engine-entities.test 01_engine-hashtable.test 01_engine-idna.test 01_engine-simplify.test 10_crawl-simple.test 11_crawl-cookies.test 11_crawl-idna.test 11_crawl-international.test 11_crawl-longurl.test 11_crawl-parsing.test 12_crawl_https.test CLEANFILES = check-network_sh.cache all: all-am .SUFFIXES: .SUFFIXES: .log .test .test$(EXEEXT) .trs $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ && { if test -f $@; then exit 0; else break; fi; }; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu tests/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --gnu tests/Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(am__aclocal_m4_deps): mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs tags TAGS: ctags CTAGS: cscope cscopelist: # Recover from deleted '.trs' file; this should ensure that # "rm -f foo.log; make foo.trs" re-run 'foo.test', and re-create # both 'foo.log' and 'foo.trs'. Break the recipe in two subshells # to avoid problems with "make -n". .log.trs: rm -f $< $@ $(MAKE) $(AM_MAKEFLAGS) $< # Leading 'am--fnord' is there to ensure the list of targets does not # expand to empty, as could happen e.g. with make check TESTS=''. am--fnord $(TEST_LOGS) $(TEST_LOGS:.log=.trs): $(am__force_recheck) am--force-recheck: @: $(TEST_SUITE_LOG): $(TEST_LOGS) @$(am__set_TESTS_bases); \ am__f_ok () { test -f "$$1" && test -r "$$1"; }; \ redo_bases=`for i in $$bases; do \ am__f_ok $$i.trs && am__f_ok $$i.log || echo $$i; \ done`; \ if test -n "$$redo_bases"; then \ redo_logs=`for i in $$redo_bases; do echo $$i.log; done`; \ redo_results=`for i in $$redo_bases; do echo $$i.trs; done`; \ if $(am__make_dryrun); then :; else \ rm -f $$redo_logs && rm -f $$redo_results || exit 1; \ fi; \ fi; \ if test -n "$$am__remaking_logs"; then \ echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \ "recursion detected" >&2; \ elif test -n "$$redo_logs"; then \ am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \ fi; \ if $(am__make_dryrun); then :; else \ st=0; \ errmsg="fatal: making $(TEST_SUITE_LOG): failed to create"; \ for i in $$redo_bases; do \ test -f $$i.trs && test -r $$i.trs \ || { echo "$$errmsg $$i.trs" >&2; st=1; }; \ test -f $$i.log && test -r $$i.log \ || { echo "$$errmsg $$i.log" >&2; st=1; }; \ done; \ test $$st -eq 0 || exit 1; \ fi @$(am__sh_e_setup); $(am__tty_colors); $(am__set_TESTS_bases); \ ws='[ ]'; \ results=`for b in $$bases; do echo $$b.trs; done`; \ test -n "$$results" || results=/dev/null; \ all=` grep "^$$ws*:test-result:" $$results | wc -l`; \ pass=` grep "^$$ws*:test-result:$$ws*PASS" $$results | wc -l`; \ fail=` grep "^$$ws*:test-result:$$ws*FAIL" $$results | wc -l`; \ skip=` grep "^$$ws*:test-result:$$ws*SKIP" $$results | wc -l`; \ xfail=`grep "^$$ws*:test-result:$$ws*XFAIL" $$results | wc -l`; \ xpass=`grep "^$$ws*:test-result:$$ws*XPASS" $$results | wc -l`; \ error=`grep "^$$ws*:test-result:$$ws*ERROR" $$results | wc -l`; \ if test `expr $$fail + $$xpass + $$error` -eq 0; then \ success=true; \ else \ success=false; \ fi; \ br='==================='; br=$$br$$br$$br$$br; \ result_count () \ { \ if test x"$$1" = x"--maybe-color"; then \ maybe_colorize=yes; \ elif test x"$$1" = x"--no-color"; then \ maybe_colorize=no; \ else \ echo "$@: invalid 'result_count' usage" >&2; exit 4; \ fi; \ shift; \ desc=$$1 count=$$2; \ if test $$maybe_colorize = yes && test $$count -gt 0; then \ color_start=$$3 color_end=$$std; \ else \ color_start= color_end=; \ fi; \ echo "$${color_start}# $$desc $$count$${color_end}"; \ }; \ create_testsuite_report () \ { \ result_count $$1 "TOTAL:" $$all "$$brg"; \ result_count $$1 "PASS: " $$pass "$$grn"; \ result_count $$1 "SKIP: " $$skip "$$blu"; \ result_count $$1 "XFAIL:" $$xfail "$$lgn"; \ result_count $$1 "FAIL: " $$fail "$$red"; \ result_count $$1 "XPASS:" $$xpass "$$red"; \ result_count $$1 "ERROR:" $$error "$$mgn"; \ }; \ { \ echo "$(PACKAGE_STRING): $(subdir)/$(TEST_SUITE_LOG)" | \ $(am__rst_title); \ create_testsuite_report --no-color; \ echo; \ echo ".. contents:: :depth: 2"; \ echo; \ for b in $$bases; do echo $$b; done \ | $(am__create_global_log); \ } >$(TEST_SUITE_LOG).tmp || exit 1; \ mv $(TEST_SUITE_LOG).tmp $(TEST_SUITE_LOG); \ if $$success; then \ col="$$grn"; \ else \ col="$$red"; \ test x"$$VERBOSE" = x || cat $(TEST_SUITE_LOG); \ fi; \ echo "$${col}$$br$${std}"; \ echo "$${col}Testsuite summary"$(AM_TESTSUITE_SUMMARY_HEADER)"$${std}"; \ echo "$${col}$$br$${std}"; \ create_testsuite_report --maybe-color; \ echo "$$col$$br$$std"; \ if $$success; then :; else \ echo "$${col}See $(subdir)/$(TEST_SUITE_LOG)$${std}"; \ if test -n "$(PACKAGE_BUGREPORT)"; then \ echo "$${col}Please report to $(PACKAGE_BUGREPORT)$${std}"; \ fi; \ echo "$$col$$br$$std"; \ fi; \ $$success || exit 1 check-TESTS: @list='$(RECHECK_LOGS)'; test -z "$$list" || rm -f $$list @list='$(RECHECK_LOGS:.log=.trs)'; test -z "$$list" || rm -f $$list @test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG) @set +e; $(am__set_TESTS_bases); \ log_list=`for i in $$bases; do echo $$i.log; done`; \ trs_list=`for i in $$bases; do echo $$i.trs; done`; \ log_list=`echo $$log_list`; trs_list=`echo $$trs_list`; \ $(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) TEST_LOGS="$$log_list"; \ exit $$?; recheck: all @test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG) @set +e; $(am__set_TESTS_bases); \ bases=`for i in $$bases; do echo $$i; done \ | $(am__list_recheck_tests)` || exit 1; \ log_list=`for i in $$bases; do echo $$i.log; done`; \ log_list=`echo $$log_list`; \ $(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) \ am__force_recheck=am--force-recheck \ TEST_LOGS="$$log_list"; \ exit $$? .test.log: @p='$<'; \ $(am__set_b); \ $(am__check_pre) $(TEST_LOG_DRIVER) --test-name "$$f" \ --log-file $$b.log --trs-file $$b.trs \ $(am__common_driver_flags) $(AM_TEST_LOG_DRIVER_FLAGS) $(TEST_LOG_DRIVER_FLAGS) -- $(TEST_LOG_COMPILE) \ "$$tst" $(AM_TESTS_FD_REDIRECT) @am__EXEEXT_TRUE@.test$(EXEEXT).log: @am__EXEEXT_TRUE@ @p='$<'; \ @am__EXEEXT_TRUE@ $(am__set_b); \ @am__EXEEXT_TRUE@ $(am__check_pre) $(TEST_LOG_DRIVER) --test-name "$$f" \ @am__EXEEXT_TRUE@ --log-file $$b.log --trs-file $$b.trs \ @am__EXEEXT_TRUE@ $(am__common_driver_flags) $(AM_TEST_LOG_DRIVER_FLAGS) $(TEST_LOG_DRIVER_FLAGS) -- $(TEST_LOG_COMPILE) \ @am__EXEEXT_TRUE@ "$$tst" $(AM_TESTS_FD_REDIRECT) distdir: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) distdir-am distdir-am: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ dist_files=`for file in $$list; do echo $$file; done | \ sed -e "s|^$$srcdirstrip/||;t" \ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ case $$dist_files in \ */*) $(MKDIR_P) `echo "$$dist_files" | \ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ sort -u` ;; \ esac; \ for file in $$dist_files; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ if test -d $$d/$$file; then \ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ if test -d "$(distdir)/$$file"; then \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ else \ test -f "$(distdir)/$$file" \ || cp -p $$d/$$file "$(distdir)/$$file" \ || exit 1; \ fi; \ done check-am: all-am $(MAKE) $(AM_MAKEFLAGS) check-TESTS check: check-am all-am: Makefile installdirs: install: install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-am install-strip: if test -z '$(STRIP)'; then \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ install; \ else \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ fi mostlyclean-generic: -test -z "$(TEST_LOGS)" || rm -f $(TEST_LOGS) -test -z "$(TEST_LOGS:.log=.trs)" || rm -f $(TEST_LOGS:.log=.trs) -test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG) clean-generic: -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-generic clean-libtool mostlyclean-am distclean: distclean-am -rm -f Makefile distclean-am: clean-am distclean-generic dvi: dvi-am dvi-am: html: html-am html-am: info: info-am info-am: install-data-am: install-dvi: install-dvi-am install-dvi-am: install-exec-am: install-html: install-html-am install-html-am: install-info: install-info-am install-info-am: install-man: install-pdf: install-pdf-am install-pdf-am: install-ps: install-ps-am install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-am -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-generic mostlyclean-libtool pdf: pdf-am pdf-am: ps: ps-am ps-am: uninstall-am: .MAKE: check-am install-am install-strip .PHONY: all all-am check check-TESTS check-am clean clean-generic \ clean-libtool cscopelist-am ctags-am distclean \ distclean-generic distclean-libtool distdir dvi dvi-am html \ html-am info info-am install install-am install-data \ install-data-am install-dvi install-dvi-am install-exec \ install-exec-am install-html install-html-am install-info \ install-info-am install-man install-pdf install-pdf-am \ install-ps install-ps-am install-strip installcheck \ installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-generic \ mostlyclean-libtool pdf pdf-am ps ps-am recheck tags-am \ uninstall uninstall-am .PRECIOUS: Makefile # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: httrack-3.49.5/tests/Makefile.am0000644000175000017500000000144214555203161013376 00000000000000EXTRA_DIST = $(TESTS) crawl-test.sh run-all-tests.sh check-network.sh TESTS_ENVIRONMENT = TESTS_ENVIRONMENT += PATH=$(top_builddir)/src$(PATH_SEPARATOR)$$PATH # note: libtool should handle that ### TESTS_ENVIRONMENT += $(SHLIBPATH_VAR)="$(top_builddir)/src/$(LT_CV_OBJDIR)$${$(SHLIBPATH_VAR):+$(PATH_SEPARATOR)}$$$(SHLIBPATH_VAR)" TESTS_ENVIRONMENT += ONLINE_UNIT_TESTS=$(ONLINE_UNIT_TESTS) TESTS_ENVIRONMENT += HTTPS_SUPPORT=$(HTTPS_SUPPORT) TEST_EXTENSIONS = .test TESTS = 00_runnable.test 01_engine-charset.test 01_engine-entities.test 01_engine-hashtable.test 01_engine-idna.test 01_engine-simplify.test 10_crawl-simple.test 11_crawl-cookies.test 11_crawl-idna.test 11_crawl-international.test 11_crawl-longurl.test 11_crawl-parsing.test 12_crawl_https.test CLEANFILES = check-network_sh.cache httrack-3.49.5/html/0000755000175000017500000000000014555203200011215 500000000000000httrack-3.49.5/html/httrack.css0000644000175000017500000000357214336470674013340 00000000000000 body { margin: 0; padding: 0; margin-bottom: 15px; margin-top: 8px; background: #77b; } body, td { font: 0.96em/1.3em "Trebuchet MS", Verdana, Arial, Helvetica, sans-serif; } #subTitle { background: #000; color: #fff; padding: 4px; font-weight: bold; } /* Width for "#siteNavigation td" based on number of buttons Six: 16.6% */ #siteNavigation td { width: 16.6%; } #siteNavigation a { display: block; padding: 2px; text-align: center; font-weight: bold; color: #448; /* font-size: 12px; */ background-color: #99c; } #siteNavigation a:link { text-decoration: none; } #siteNavigation a:visited { text-decoration: none; } #siteNavigation a:hover { text-decoration: none; background-color: #fff; color: #000; } #siteNavigation a:active { text-decoration: none; background-color: #ccc; } a:link { text-decoration: underline; color: #00f; } a:visited { text-decoration: underline; color: #000; } a:hover { text-decoration: underline; color: #c00; } a:active { text-decoration: underline; } #pageContent { clear: both; border-bottom: 6px solid #000; padding: 10px; padding-top: 20px; line-height: 1.65em; background-image: url(images/bg_rings.gif); background-repeat: no-repeat; background-position: top right; } #pageContent p { margin: 0; margin-bottom: 30px; } #pageContent, #siteNavigation { background-color: #ccd; } .tableWidth { min-width: 400px; } /* ----------------------------------- */ .imgLeft { float: left; margin-right: 10px; margin-bottom: 10px; } .imgRight { float: right; margin-left: 10px; margin-bottom: 10px; } hr { height: 1px; color: #000; background-color: #000; margin-bottom: 15px; } h1 { margin: 0; font-weight: bold; font-size: 2em; } h2 { margin: 0; font-weight: bold; font-size: 1.6em; } h3 { margin: 0; font-weight: bold; font-size: 1.3em; } .blak { background-color: #000; } .hide { display: none; } httrack-3.49.5/html/step.html0000644000175000017500000001166014336470674013024 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

How to start, Step-by-step






Back to Home

httrack-3.49.5/html/step9_opt9.html0000644000175000017500000001467714360553245014074 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Option panel : Log files, Index, Cache




  • Force to store all files in cache

  • Force to store all files in the cache, even gif files, zip files and so on..
    Without this option, the engine will only save in cache html files for updating/continue purpose.
    It can be useful, however, to keep all files in cache if you want in the future to change the site structure
    Warning! This option will appreciably inflate the cache that will become as big as the mirror itself!


  • Do not re-download locally erased files

  • This option prevents HTTrack from re-asking a file that exists locally with null size, or that has been erased by the user
    (If the user erased the file, this option will create a null-file to prevent the engine to catch the file next time)
    Useful if you are erasing progressively large files on the local mirror and do not want to reload them!


  • Create Log files

  • Create log file where informations, error and warnings about the current mirror will be saved
    If you do not generate log files, you will not be able to know what errors occurred!
    It is strongly advised to leave this option checked
    Note: You can define the debug-level of the log-files. Default is "normal"


  • Make an index

  • Generate an index.html on the top of the directory. Very useful.

  • Make a word database

  • Generate an index.txt database on the top of the directory. Very useful for linguistic analysis, this feature will allow you to list all words of all mirrored pages in the current project.
    With this index file, you will be able to list which words were detected, and where.






Back to Home

httrack-3.49.5/html/step9_opt8.html0000644000175000017500000001405714336470674014072 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Option panel : Browser ID




  • Browser "Identity"

  • Enter here the name of the engine, as it will be seen by Web-servers
    For example, entering "Mozilla/4.5 (compatible; MSIE 4.01; Windows 98)" will disguise HTTrack into a standard MSIE4 browser
    This field is for statistical purpose, and you can enter whatever you want, a browser name that does not exist or even your grandma's name
    However, beware that several sites may deliver a different content whether the browser is called "Netscape" or "Explorer".. some elitist ones will even refuse to deliver anything depending on the browser name. This case is rare, fortunately.


  • HTML Footer

  • Enter here the optionnal text that will be included as a comment in each HTML file to make archiving easier
    The string entered is generally an HTML comment (<!-- HTML comment -->) with optionnal %s, which will be transformed into a specific string information:
    %s #1 : host name (for example, www.someweb.com)
    %s #2 : file name (for example, /index.html)
    %s #3 : date of the mirror
    Example: <!-- Page mirrored from %s, file %s. Archive date: %s -->
    Note: You can select (none), in this case no comments will be added to the pages. However, this is NOT advised as you may want to know in the future where the page has been taken, when/why..






Back to Home

httrack-3.49.5/html/step9_opt7.html0000644000175000017500000001325114336470674014064 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Option panel : Proxy




  • Proxy

  • You can enter manually the proxy name and port (enter the name in the first field, the port in the second field)

  • Use proxy for FTP transfers

  • The engine can use default HTTP proxy for all ftp (ftp://) transfers. Most proxies allow this, and if you are behind a firewall, this option will allow you to easily catch all ftp links. Besides, ftp transfers managed by the proxy are more reliable than the engine's default FTP client.
    This option is checked by default


  • Configure

  • Click on this button to configure the proxy.
    If the proxy needs authentication you can define the login username/password







  • Hide password

  • Use it if you do not want to display the password (hides the proxy name)





Back to Home

httrack-3.49.5/html/step9_opt6.html0000644000175000017500000001457414336470674014074 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Option panel : Spider




  • Accept cookies

  • Accept cookies generated by the remote server
    If you do not accept cookies, some "session-generated" pages will not be retrieved


  • Check document type

  • Define when the engine has to check document type
    The engine must know the document type, to rewrite the file types. For example, if a link called /cgi-bin/gen_image.cgi generates a gif image, the generated file will not be called "gen_image.cgi" but "gen_image.gif"
    Avoid "never", because the local mirror could be bogus


  • Parse java files

  • Must the engine parse .java files (java classes) to seek included filenames?
    It is checked by default


  • Spider

  • Must the engine follow remote robots.txt rules when they exist?
    The default is "follow"


  • Update hack

  • Attempt to limit transfers by wrapping known bogus responses from servers. For example, pages with same size will be considered as "up to date", even if the timestamp seems different. This can be useful for many dynamically generated pages, but this can also cause not-updated pages in rare cases.

  • Tolerant requests

  • Tolerate wrong file size, and make requests compliant with old servers
    It is unchecked by default, because this option can cause files to become bogus


  • Force old HTTP/1.0 requests

  • This option forces the engine to use HTTP/1.0 requests, and avoid HEAD requests.
    Useful for some sites with old server versions, or with many dynamically generated pages.






Back to Home

httrack-3.49.5/html/step9_opt5.html0000644000175000017500000001514714360553245014061 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Option panel : Build




  • Local Structure Type

  • Lets you define the local structure of the site.
    The default is "site structure": you will get the same folder/files names and structure as the original
    You can, however, put all images in one single folder, html in another and so on..


  • DOS Names

  • Force the engine to generate DOS names (8 characters for the name, 3 for the type)

  • ISO9660 Names

  • Force the engine to generate ISO9660-compatible names for storing on medias such as CDROM or DVDROM

  • No error pages

  • Do not generate error pages (if a 404 error occurred, for example)
    If a page is missing on the remote site, there will not be any warning on the local site


  • No external pages

  • Rewrite all external links (links that needs an Internet connection) so that there can be a warning page before ("Warning, you need to be online to go to this link..")
    Useful if you want to separate the local and online realm


  • Hide passwords

  • Do not include username and password for protected sites in the code, when a link will not be caught. This allow to remain the access data private.

  • Hide query strings

  • Do not include query strings for local links. Query strings (?foo=45&bar=67) are generally not necessary for local (file://) files, but query strings can be useful to show several information (example: page-4.html?index=History). However, some basic browsers may not understand that (wireless browsers, especially), and hiding query strings might be a good idea in this case.

  • Do not purge old files

  • Do not purge, after an update, the local files that no longer exist on the remote site, or that have been skipped





Back to Home

httrack-3.49.5/html/step9_opt4.html0000644000175000017500000001564214336470674014067 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Option panel : Scan Rules






Back to Home

httrack-3.49.5/html/step9_opt3.html0000644000175000017500000001371314360553245014054 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Option panel : Flow Control




  • Number of connections

  • Define the number of simultaneous connections that can be initiated by the engine.
    It is recommended to limit this number to 1 or 2 if you are mirroring big files on a site, more on standard sites (8 is recommended, up to 42 if it is supported by the system)


  • TimeOut

  • Define what time the engine has to wait if no response if given by a server.
    120 seconds is recommended (less of fast pipes, more if you connection is sloppy)
    You can optionally skip all links from a host that has generated a timeout. Warning: is this checkbox is selected, a timeout will eliminate all links from the origin server


  • Retries

  • Number of retries if a non-fatal error occurred (timeout, for example)
    Note that this will not solve fatal errors such as "Not Found" pages and so on!


  • Min Transfer Rate

  • Minimum transfer rate tolerated on a site. If the transfer rate if slower that the defined value, then the link is skipped
    You can optionally skip all links from a host that has generated a "too slow" error. Warning: is this checkbox is selected, a "too slow" errors will eliminate all links from the origin server






Back to Home

httrack-3.49.5/html/step9_opt2.html0000644000175000017500000001736214336470674014066 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Option panel : Limits




  • Maximum mirror depth

  • Define how deep will the engine seek in the site A depth of 3 means that you will catch all pages you have indicated, plus all that can be accessed clicking twice on any link
    Note: This option is not filled by default, so the depth is infinite. But because the engine will stay on the site you indicated, only the desired sites will be mirrored, and not all the web!


  • Maximum external depth

  • Define how deep will the engine seek in external sites, or on addresses that were forbidden.
    Normally, HTTrack will not go on external sites by default (except if authorized by filters), and will avoid addresses forbidden by filters. You can override this behaviour, and tell the engine to catch N levels of "external" sites.
    Note: Use this option with great care, as it is overriding all other options (filters and default engine limiter)
    Note: This option is not filled by default, so the depth is equal to zero.


  • Maximum size of an HTML file

  • Define the biggest Html file the engine is allowed to catch.
    This option allows you to avoid big files if you do not want to download them.


  • Max size of a non-HTML file

  • Define the biggest non-html file (image, ZIP file..) the engine is allowed to catch.
    This option allows you to avoid big files if you do not want to download them.


  • Site size limit

  • This option limits the total amount of bytes that can be downloaded in the current mirror

  • Pause after downloading..

  • This option lets the engine do a pause every time it has retrieved a specific amount of bytes
    Useful if you are mirroring a site bigger than the available space: you can then backup and erase the downloaded files during the pause


  • Max time overall

  • This option limits the total amount of time that can be spent on the current mirror

  • Max transfer rate

  • This option limits the transfer rate on the current mirror
    Useful if you do not want HTTrack to monopolize the bandwidth!


  • Max connections / seconds

  • This option limits the number of connections per second for the current mirror. This number can be a floating number (such as 0.1 == 1 connection per 10 seconds)
    Useful to limit server load.
    The default is 10, but you can disable it with a value of 0 - THIS IS NOT ADVISED UNLESS YOU KNOW WHAT YOU ARE DOING (risks of server overload)


  • Maximum number of links

  • Maximum number of links that can be analyzed, that is, either downloaded, or not downloaded. Do not set a too low limit for that, because once the limit is reached, the engine will stop immediately.
    Do not set a too high limit, too, because it will take some memory.. 100,000 links (default) is generally enough.






Back to Home

httrack-3.49.5/html/step9_opt1.html0000644000175000017500000001357214360553245014055 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Option panel : Links




  • Attempt to detect all links

  • Asks the engine to try to detect all links in a page, even for unknown tags or unknown javascript code. This can generate bad requests or error in pages, but may be helpful to catch all desired links
    Useful, for example, in pages with many javascript tricks


  • Get non-html files related to a link

  • This option allows you to catch all file references in captured HTML files, even external ones
    For example, if an image in an Html page has its source on another web site, this image will be captured together.


  • Test validity of all links

  • This option forces the engine to test all links in spidered pages, i.e. to check if every link is valid or not by performing a request to the server. If an error occurred, it is reported to the error log-file.
    Useful to test all external links in a website


  • Get HTML files first!

  • With this option enabled, the engine will attempt to download all HTML files first, and then download other (images) files. This can speed up the parsing process, by efficiently scanning the HTML structure.





Back to Home

httrack-3.49.5/html/step9_opt11.html0000644000175000017500000001520314336470674014136 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Option panel : MIME Types






  • MIME Types

  • An important new feature for some people. This panel tells the engine that if a link is encountered, with a specific type (.cgi, .asp, or .php3 for example), it MUST assume that this link has always the same MIME type, for example the "text/html" MIME type. This is VERY important to speed up many mirrors. Some big HTML files which have many links of unknown type embedded, such as ".asp", cause the engine to test all links, and this slows down the parser.

    In this case, you can tell HTTrack: ".asp pages are in fact HTML pages"
    This is possible, using:

    File type: asp MIME identity: text/html

    You can declare multiple definitions, or declare multiple types separated by ",", like in:
    File type: asp,php,php3 MIME identity: text/html

    Most important MIME types are:
    text/htmlHtml files, parsed by HTTrack
    image/gifGIF files
    image/jpegJpeg files
    image/pngPNG files
    application/x-zip.zip files
    application/x-mp3.mp3 files
    application/x-foo.foo files
    application/octet-streamUnknown files

    You can rename files on a mirror. If you KNOW that all "dat" files are in fact "zip" files renamed into "dat", you can tell httrack:
    File type: dat MIME identity: application/x-zip

    You can also "name" a file type, with its original MIME type, if this type is not known by HTTrack. This will avoid a test when the link will be reached:
    File type: foo MIME identity: application/octet-stream

    In this case, HTTrack won't check the type, because it has learned that "foo" is a known type, or MIME type "application/octet-stream". Therefore, it will let untouched the "foo" type.






Back to Home

httrack-3.49.5/html/step9_opt10.html0000644000175000017500000001354514336470674014144 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Option panel : Expert Options




    Advice: leave these options to default values!

  • Use a cache for updates

  • This option MUST be set if you want to update the site later, or if you want to have the opportunity to continue a crashed mirror
    Disable it only if you want to save few kilobytes, but, err, again, it is not advised to disable this option!


  • Primary filter (scan mode)

  • Which files must be saved?
    You can choose Html and/or Non-Html, or none (this last option is automatically set for scanning)


  • Travel mode

  • Set the default spidering direction
    The default is to catch all files in the same level and lower levels, which is the most logical


  • Global travel mode

  • Set the default global spidering direction
    The default is to stay on the same address if no specific authorization has been delivered


  • Activate debug mode

  • Enables some extra debug informations, like headers debugging and some interface informations (for debugging purpose only)





Back to Home

httrack-3.49.5/html/step9.html0000644000175000017500000001321614336470674013114 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Option panel


  • Click on one of the option tab below to have more informations

  • Each option tab is described, including remarks and examples

Back to Home

httrack-3.49.5/html/step5.html0000644000175000017500000001152514336470674013111 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Step 5 : Check the result


  1. Check log files

  2. You may check the error log file, which could contain useful information if errors have occurred


  3. See the troubleshooting page




Back to Home

httrack-3.49.5/html/step4.html0000644000175000017500000001173214336470674013110 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Step 4 : Wait!


  1. Wait until the mirror is finishing

  2. You can cancel at any time the mirror, or cancel files currently downloaded for any reasons (file too big, for example)
    Options can be changed during the mirror: maximum number of connections, limits...



  3. Go to the next step...




Back to Home

httrack-3.49.5/html/step3.html0000644000175000017500000001353014336470674013105 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Step 3 : Ready to start


  1. If you want, you may connect immediately or delay the mirror

  2. If you don't select anything, HTTrack will assume that you are already connected to the Internet and that you want to start the mirror action now

    • Connect to this provider

    • You can select here a specific provider to connect to when begining the mirror if you are not already connected to the Internet.

    • Disconnect when finished

    • Click on this checkbox to ask httrack to disconnect the network when mirror is finished.

    • Shutdown PC when finished

    • Click on this checkbox to ask httrack to shutdown your computer when mirror is finished.

    • On Hold

    • You can enter here the time of the mirror start. You can delay up to 24 hours a mirror using this feature.



  3. Click on the FINISH button


  4. Go to the next step...




Back to Home

httrack-3.49.5/html/step2.html0000644000175000017500000001534114336470674013106 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Step 2 : Fill the addresses


  1. Select an action

  2. The default action is Download web sites



    • Download web site(s)

    • Will transfert the desired sites with default options
    • Download web site(s) + questions

    • Will transfert the desired sites with default options, and ask questions if any links are considered as potentially downloadable
    • Get individual files

    • Will only get the desired files you specify (for example, ZIP files), but will not spider through HTML files
    • Download all sites in pages (multiple mirror)

    • Will download all sites that appears in the site(s) selected. If you drag&drop your boormark file, this option lets you mirror all your favorite sites
    • Test links in pages (bookmark test)

    • Will test all links indicated. Useful to check a bookmark file
    • * Continue interrupted download

    • Use this option if a download has been interrupted (user interruption,crash..)
    • * Update existing download

    • Use this option to update an existing project. The engine will recheck the complete structure, checking each downloaded file for any updates on the web site


  3. Enter the site's addresses

  4. You can click on the Add a URL button to add each address, or just type them in the box



  5. You may define options by clicking on the Set options button

  6. You can define filters or download parameters in the option panel


  7. You may also add a URL by clicking on the Add a URL button

  8. This option lets you define additional parameters (login/password) for the URL, or capture a complex URL from your browser


  9. Click on the NEXT button


  10. Go to the next step...




Back to Home

httrack-3.49.5/html/step1.html0000644000175000017500000001310514336470674013101 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Step 1 : Choose a project name and destination folder


  1. Change the destination folder if necessary

  2. It is more convenient to organize all mirrors in one directory, for example My Web Sites
    If you already have made mirrors using HTTrack, be sure that you have selected the correct folder.




  3. Select the project name:
    • Select a new project name

    • This name is, for example, the theme of the mirrored sites, for example My Friend's Site



      OR

    • Select an existing project for update/retry

    • Directly select the existing project name in the popup list



  4. Click on the NEXT button


  5. Go to the next step...




Back to Home

httrack-3.49.5/html/start.html0000644000175000017500000000050014336470674013175 00000000000000 HTTrack documentation HTTrack documentation httrack-3.49.5/html/shelldoc.html0000644000175000017500000001246514336470674013652 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Windows Shell Documentation


Note: WinHTTrack (Windows release of HTTrack) and WebHTTrack (Linux/Unix release of HTTrack) are very similar, but not exactly identical. You may encounter minor differences (in the display, or in various options) between these two releases. The engine behind these two release is identical.

WinHTTrack WebHTTrack

httrack-3.49.5/html/scripting.html0000644000175000017500000002003714336470674014051 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

HTTrack Programming page - scripting


We will see here several examples, written in batch script (can be adapted to almost all batch script languages) or in C.



How to get one single file

httrack --get http://localhost/


How to get one single file and pipe it to stdout

httrack --quiet --get http://localhost/ -O tmpget -V "cat \$0" | grep -iE "TITLE" rm -rf tmpget


How to search in all HTML files on a website

httrack --skeleton http://localhost/ -V "if grep -iE \"TITLE\" \"\$0\">/dev/null; then echo \"Match found at \$0\"; fi"
rm -rf tmpget

Same thing but matches only the first file:
httrack --skeleton http://localhost/ -V "if grep -iE \"TITLE\" \"\$0\">/dev/null; then echo \"Match found at \$0\"; kill -9 \$PPID; fi"
rm -rf tmpget


Indexing a website, and using the index as a search engine

httrack localhost -%I
Will generate an index.txt file, which contains all detected keywords, sorted and indexed using this format:

keyword
<tab>   number_of_hits_in_current_page_for_this_keyword   page_location
<tab>   number_of_hits_in_current_page_for_this_keyword   page_location
<tab>   number_of_hits_in_current_page_for_this_keyword   page_location
...
=total_number_of_hits_for_this_keyword
((total_number_of_hits_for_this_keyword*1000)/total_number_of_keywords)

Example:

abilities
	1 localhost/manual/mod/index-2.html
	1 localhost/manual/mod/index.html
	1 localhost/manual/mod/mod_negotiation.html
	=3
	(0)
ability
	2 localhost/manual/misc/FAQ.html
	2 localhost/manual/suexec.html
	1 localhost/manual/handler.html
	1 localhost/manual/misc/security_tips.html
	1 localhost/manual/mod/mod_rewrite.html
	1 localhost/manual/mod/mod_setenvif.html
	1 localhost/manual/multilogs.html
	1 localhost/manual/netware.html
	1 localhost/manual/new_features_1_3.html
	1 localhost/manual/windows.html
	=12
	(0)
able
	4 localhost/manual/dso.html
	4 localhost/manual/mod/core.html
	3 localhost/manual/dns-caveats.html
	3 localhost/manual/mod/mod_auth.html
	3 localhost/manual/mod/mod_rewrite.html
	3 localhost/manual/upgrading_to_1_3.html
	2 localhost/manual/misc/API.html
	2 localhost/manual/misc/FAQ.html
	2 localhost/manual/misc/windoz_keepalive.html
	2 localhost/manual/mod/mod_auth_db.html
	2 localhost/manual/mod/mod_auth_dbm.html
	1 localhost/manual/misc/descriptors.html
	1 localhost/manual/misc/fin_wait_2.html
	1 localhost/manual/misc/security_tips.html
	1 localhost/manual/mod/mod_auth_digest.html
	1 localhost/manual/mod/mod_cern_meta.html
	1 localhost/manual/mod/mod_env.html
	1 localhost/manual/mod/mod_example.html
	1 localhost/manual/mod/mod_unique_id.html
	1 localhost/manual/mod/mod_usertrack.html
	1 localhost/manual/stopping.html
	1 localhost/manual/suexec.html
	1 localhost/manual/vhosts/ip-based.html
	1 localhost/manual/windows.html
	=43
	(0)
...

Script example: search.sh


httrack-3.49.5/html/plug.html0000644000175000017500000006070114360553245013011 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

HTTrack Programming page - plugging functions


You can write external functions to be plugged in the httrack library very easily. We'll see there some examples.

The httrack commandline tool allows (since the 3.30 release) to plug external functions to various callbacks defined in httrack. The 3.41 release introduces a cleaned up verion of callbacks, with two major changes:
  • Cleaned up function prototypes, with two arguments always passed (the caller carg structure, and the httrackp* object), convenient to pass an user-defined pointer (see CALLBACKARG_USERDEF(carg))
  • The httrackp* option structure can be directly accessed to plug callbacks (no need to give the callback name and function name in the commandline!)
  • The callback plug is made through the CHAIN_FUNCTION() helper, allowing to chain multiple callbacks of the same type (the callbacks MUST preserve the chain by calling ancestors)

References:
  • the httrack-library.h prototype file
    Note: the Initialization, Main functions, Options handling and Wrapper functions sections are generally the only ones to be considered.
  • the htsdefines.h prototype file, which describes callback function prototypes
  • the htsopt.h prototype file, which describes the full httrackp* structure
  • the callbacks-example*.c files given in the httrack archive
  • the htsjava.c source file (the java class plugin ; overrides 'detect' and 'parse')
  • the example given at the end of this document

Below the list of functions to be defined in the module (plugin).

module function namefunction descriptionfunction signature
hts_plug The module entry point. The opt structure can be used to plug callbacks, using the CHAIN_FUNCTION() macro helper. The argv optional argument is the one passed in the commandline as --wrapper parameter.
return value: 1 upon success, 0 upon error (the mirror will then be aborted)

Wrappers can be plugged inside hts_plug() using:
CHAIN_FUNCTION(opt, <callback name>, <our callback function name>, <our callback function optional custom pointer argument>);

Example:
CHAIN_FUNCTION(opt, check_html, process, userdef);
extern int hts_plug(httrackp *opt, const char* argv);
hts_unplug The module exit point. To free allocated resources without using global variables, use the uninit callback (see below)extern int hts_unplug(httrackp *opt);

Note that all callbacks (except init and uninit) take as first two argument:
  • the t_hts_callbackarg structure
    this structure holds the callback chain (parent callbacks defined before the current callback) pointers, and the user-defined pointer ; see CALLBACKARG_USERDEF(carg))
  • the httrackp structure
    this structure, holding all current httrack options and mirror state, can be read or mofidied

Below the list of callbacks, and associated external wrappers.
callback namecallback descriptioncallback function signature
initNote: the use the "start" callback is advised. Called during initialization.
return value: none
void mycallback(t_hts_callbackarg *carg);
uninitNote: the use os the "end" callback is advised.
Called during un-initialization
return value: none
void mycallback(t_hts_callbackarg *carg);
startCalled when the mirror starts. The opt structure passed lists all options defined for this mirror. You may modify the opt structure to fit your needs.
return value: 1 upon success, 0 upon error (the mirror will then be aborted)
int mycallback(t_hts_callbackarg *carg, httrackp* opt);
endCalled when the mirror ends
return value: 1 upon success, 0 upon error (the mirror will then be considered aborted)
int mycallback(t_hts_callbackarg *carg, httrackp* opt);
choptCalled when options are to be changed. The opt structure passed lists all options, updated to take account of recent changes
return value: 1 upon success, 0 upon error (the mirror will then be aborted)
int mycallback(t_hts_callbackarg *carg, httrackp* opt);
preprocessCalled when a document (which is an html document) is to be parsed (original, not yet modified document). The html address points to the document data address (char**), and the length address points to the lenth of this document. Both pointer values (address and size) can be modified to change the document. It is up to the callback function to reallocate the given pointer (using the hts_realloc()/hts_free() library functions), which will be free()'ed by the engine. Hence, return of static buffers is strictly forbidden, and the use of hts_strdup() in such cases is advised. The url_address and url_file are the address and URI of the file being processed
return value: 1 if the new pointers can be applied (default value)
int mycallback(t_hts_callbackarg *carg, httrackp* opt, char** html, int* len, const char* url_address, const char* url_file);
postprocessCalled when a document (which is an html document) is parsed and transformed (links rewritten). The html address points to the document data address (char**), and the length address points to the lenth of this document. Both pointer values (address and size) can be modified to change the document. It is up to the callback function to reallocate the given pointer (using the hts_realloc()/hts_free() library functions), which will be free()'ed by the engine. Hence, return of static buffers is strictly forbidden, and the use of hts_strdup() in such cases is advised. The url_address and url_file are the address and URI of the file being processed
return value: 1 if the new pointers can be applied (default value)
int mycallback(t_hts_callbackarg *carg, httrackp* opt, char** html, int* len, const char* url_address, const char* url_file);
check_htmlCalled when a document (which may not be an html document) is to be parsed. The html address points to the document data, of lenth len. The url_address and url_file are the address and URI of the file being processed
return value: 1 if the parsing can be processed, 0 if the file must be skipped without being parsed
int mycallback(t_hts_callbackarg *carg, httrackp* opt, char* html, int len, const char* url_address, const char* url_file);
queryCalled when the wizard needs to ask a question. The question string contains the question for the (human) user
return value: the string answer ("" for default reply)
const char* mycallback(t_hts_callbackarg *carg, httrackp* opt, const char* question);
query2Called when the wizard needs to ask a questionconst char* mycallback(t_hts_callbackarg *carg, httrackp* opt, const char* question);
query3Called when the wizard needs to ask a questionconst char* mycallback(t_hts_callbackarg *carg, httrackp* opt, const char* question);
loopCalled periodically (informational, to display statistics)
return value: 1 if the mirror can continue, 0 if the mirror must be aborted
int mycallback(t_hts_callbackarg *carg, httrackp* opt, lien_back* back, int back_max, int back_index, int lien_tot, int lien_ntot, int stat_time, hts_stat_struct* stats);
check_linkCalled when a link has to be tested. The adr and fil are the address and URI of the link being tested. The passed status value has the following meaning: 0 if the link is to be accepted by default, 1 if the link is to be refused by default, and -1 if no decision has yet been taken by the engine
return value: same meaning as the passed status value ; you may generally return -1 to let the engine take the decision by itself
int mycallback(t_hts_callbackarg *carg, httrackp* opt, const char* adr, const char* fil, int status);
check_mimeCalled when a link download has begun, and needs to be tested against its MIME type. The adr and fil are the address and URI of the link being tested, and the mime string contains the link type being processed. The passed status value has the following meaning: 0 if the link is to be accepted by default, 1 if the link is to be refused by default, and -1 if no decision has yet been taken by the engine
return value: same meaning as the passed status value ; you may generally return -1 to let the engine take the decision by itself
int mycallback(t_hts_callbackarg *carg, httrackp* opt, const char* adr, const char* fil, const char* mime, int status);
pauseCalled when the engine must pause. When the lockfile passed is deleted, the function can return
return value: none
void mycallback(t_hts_callbackarg *carg, httrackp* opt, const char* lockfile);
filesaveCalled when a file is to be saved on disk
return value: none
void mycallback(t_hts_callbackarg *carg, httrackp* opt, const char* file);
filesave2Called when a file is to be saved or checked on disk
The hostname, filename and local filename are given. Two additional flags tells if the local file is new (is_new), if the local file is to be modified (is_modified), and if the file was not updated remotely (not_updated).
(!is_new && !is_modified): the file is up-to-date, and will not be modified
(is_new && is_modified): a new file will be written (or an updated file is being written)
(!is_new && is_modified): a file is being updated (append)
(is_new && !is_modified): an empty file will be written ("do not recatch locally erased files")
not_updated: the file was not re-downloaded because it was up-to-date (no data transferred again)

return value: none
void mycallback(t_hts_callbackarg *carg, httrackp* opt, const char* hostname, const char* filename, const char* localfile, int is_new, int is_modified, int not_updated);
linkdetectedCalled when a link has been detected
return value: 1 if the link can be analyzed, 0 if the link must not even be considered
int mycallback(t_hts_callbackarg *carg, httrackp* opt, char* link);
linkdetected2Called when a link has been detected
return value: 1 if the link can be analyzed, 0 if the link must not even be considered
int mycallback(t_hts_callbackarg *carg, httrackp* opt, char* link, const const char* tag_start);
xfrstatusCalled when a file has been processed (downloaded, updated, or error)
return value: must return 1
int mycallback(t_hts_callbackarg *carg, httrackp* opt, lien_back* back);
savenameCalled when a local filename has to be processed. The adr_complete and fil_complete are the address and URI of the file being saved ; the referer_adr and referer_fil are the address and URI of the referer link. The save string contains the local filename being used. You may modifiy the save string to fit your needs, up to 1024 bytes (note: filename collisions, if any, will be handled by the engine by renaming the file into file-2.ext, file-3.ext ..).
return value: must return 1
int mycallback(t_hts_callbackarg *carg, httrackp* opt, const char* adr_complete, const char* fil_complete, const char* referer_adr, const char* referer_fil, char* save);
sendheadCalled when HTTP headers are to be sent to the remote server. The buff buffer contains text headers, adr and fil the URL, and referer_adr and referer_fil the referer URL. The outgoing structure contains all information related to the current slot.
return value: 1 if the mirror can continue, 0 if the mirror must be aborted
int mycallback(t_hts_callbackarg *carg, httrackp* opt, char* buff, const char* adr, const char* fil, const char* referer_adr, const char* referer_fil, htsblk* outgoing);
receiveheadCalled when HTTP headers are recevived from the remote server. The buff buffer contains text headers, adr and fil the URL, and referer_adr and referer_fil the referer URL. The incoming structure contains all information related to the current slot.
return value: 1 if the mirror can continue, 0 if the mirror must be aborted
int mycallback(t_hts_callbackarg *carg, httrackp* opt, char* buff, const char* adr, const char* fil, const char* referer_adr, const char* referer_fil, htsblk* incoming);
detectCalled when an unknown document is to be parsed. The str structure contains all information related to the document.
return value: 1 if the type is known and can be parsed, 0 if the document type is unknown
int mycallback(t_hts_callbackarg *carg, httrackp* opt, htsmoduleStruct* str);
parseThe str structure contains all information related to the document.
return value: 1 if the document was successfully parsed, 0 if an error occurred
int mycallback(t_hts_callbackarg *carg, httrackp* opt, htsmoduleStruct* str);


Note: the optional libhttrack-plugin module (libhttrack-plugin.dll or libhttrack-plugin.so), if found in the library environment, is loaded automatically, and its hts_plug() function being called.

An example is generally more efficient than anything else, so let's write our first module, aimed to stupidely print all parsed html files:
/* system includes */
#include <stdio.h>
#include <stdlib.h>
#include <string.h>

/* standard httrack module includes */
#include "httrack-library.h"
#include "htsopt.h"
#include "htsdefines.h"

/* local function called as "check_html" callback */
static int process_file(t_hts_callbackarg /*the carg structure, holding various information*/*carg, /*the option settings*/httrackp *opt, 
                        /*other parameters are callback-specific*/
                        char* html, int len, const char* url_address, const char* url_file) {
  void *ourDummyArg = (void*) CALLBACKARG_USERDEF(carg);    /*optional user-defined arg*/

  /* call parent functions if multiple callbacks are chained. you can skip this part, if you don't want previous callbacks to be called. */
  if (CALLBACKARG_PREV_FUN(carg, check_html) != NULL) {
    if (!CALLBACKARG_PREV_FUN(carg, check_html)(CALLBACKARG_PREV_CARG(carg), opt,
                                                html, len, url_address, url_file)) {
        return 0;  /* abort */
      }
  }

  printf("file %s%s content: %s\n", url_address, url_file, html);
  return 1;  /* success */
}

/* local function called as "end" callback */
static int end_of_mirror(t_hts_callbackarg /*the carg structure, holding various information*/*carg, /*the option settings*/httrackp *opt) {
  void *ourDummyArg = (void*) CALLBACKARG_USERDEF(carg);    /*optional user-defined arg*/

  /* processing */
  fprintf(stderr, "That's all, folks!\n");

  /* call parent functions if multiple callbacks are chained. you can skip this part, if you don't want previous callbacks to be called. */
  if (CALLBACKARG_PREV_FUN(carg, end) != NULL) {
    /* status is ok on our side, return other callabck's status */
    return CALLBACKARG_PREV_FUN(carg, end)(CALLBACKARG_PREV_CARG(carg), opt);
  }

  return 1;  /* success */
}

/*
module entry point
the function name and prototype MUST match this prototype
*/
EXTERNAL_FUNCTION int hts_plug(httrackp *opt, const char* argv) {
  /* optional argument passed in the commandline we won't be using here */
  const char *arg = strchr(argv, ',');
  if (arg != NULL)
    arg++;

  /* plug callback functions */
  CHAIN_FUNCTION(opt, check_html, process_file, /*optional user-defined arg*/NULL);
  CHAIN_FUNCTION(opt, end, end_of_mirror, /*optional user-defined arg*/NULL);

  return 1;  /* success */
}

/*
module exit point
the function name and prototype MUST match this prototype
*/
EXTERNAL_FUNCTION int hts_unplug(httrackp *opt) {
  fprintf(stder, "Module unplugged");

  return 1;  /* success */
}

Compile this file ; for example:
gcc -O -g3 -shared -o mylibrary.so myexample.c
and plug the module using the commandline ; for example:
httrack --wrapper mylibrary http://www.example.com
or, if some parameters are desired:
httrack --wrapper mylibrary,myparameter-string http://www.example.com
(the "myparameter-string" string will be available in the 'arg' parameter passed to the hts_plug entry point)


httrack-3.49.5/html/plug_330.html0000644000175000017500000004513114336470674013405 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

HTTrack Programming page - plugging functions
releases 3.30 to 3.40 (not beyond)


You can write external functions to be plugged in the httrack library very easily. We'll see there some examples.

The httrack commandline tool allows (since the 3.30 release) to plug external functions to various callbacks defined in httrack.
See also: the httrack-library.h prototype file, and the callbacks-example.c given in the httrack archive.

Example: httrack --wrapper check-html=callback:process_file ..
With the callback.so (or callback.dll) module defined as below:
int process_file(char* html, int len, char* url_adresse, char* url_fichier) {
  printf("now parsing %s%s..\n", url_adresse, url_fichier);
  strcpy(currentURLBeingParsed, url_adresse);
  strcat(currentURLBeingParsed, url_fichier);
  return 1;  /* success */
}
Below the list of callbacks, and associated external wrappers:
typedef void (* t_hts_htmlcheck_filesave2)();
"callback name"callback descriptioncallback function signature
"init"Note: deprecated, should not be used anymore (unsafe callback) - see "start" callback or wrapper_init() module function below this table.Called during initialization ; use of htswrap_add (see httrack-library.h) is permitted inside this function to setup other callbacks.
return value: none
void (* myfunction)(void);
"free"Note: deprecated, should not be used anymore (unsafe callback) - see "end" callback or wrapper_exit() module function below this table.
Called during un-initialization
return value: none
void (* myfunction)(void);
"start"Called when the mirror starts. The opt structure passed lists all options defined for this mirror. You may modify the opt structure to fit your needs. Besides, use of htswrap_add (see httrack-library.h) is permitted inside this function to setup other callbacks.
return value: 1 upon success, 0 upon error (the mirror will then be aborted)
int (* myfunction)(httrackp* opt);
"end"Called when the mirror ends
return value: 1 upon success, 0 upon error (the mirror will then be considered aborted)
int (* myfunction)(void);
"change-options"Called when options are to be changed. The opt structure passed lists all options, updated to take account of recent changes
return value: 1 upon success, 0 upon error (the mirror will then be aborted)
int (* myfunction)(httrackp* opt);
"check-html"Called when a document (which may not be an html document) is to be parsed. The html address points to the document data, of lenth len. The url_adresse and url_fichier are the address and URI of the file being processed
return value: 1 if the parsing can be processed, 0 if the file must be skipped without being parsed
int (* myfunction)(char* html,int len,char* url_adresse,char* url_fichier);
"preprocess-html"Called when a document (which is an html document) is to be parsed (original, not yet modified document). The html address points to the document data address (char**), and the length address points to the lenth of this document. Both pointer values (address and size) can be modified to change the document. It is up to the callback function to reallocate the given pointer (using standard C library realloc()/free() functions), which will be free()'ed by the engine. Hence, return of static buffers is strictly forbidden, and the use of strdup() in such cases is advised. The url_adresse and url_fichier are the address and URI of the file being processed
return value: 1 if the new pointers can be applied (default value)
int (* myfunction)(char** html,int* len,char* url_adresse,char* url_fichier);
"postprocess-html"Called when a document (which is an html document) is parsed and transformed (links rewritten). The html address points to the document data address (char**), and the length address points to the lenth of this document. Both pointer values (address and size) can be modified to change the document. It is up to the callback function to reallocate the given pointer (using standard C library realloc()/free() functions), which will be free()'ed by the engine. Hence, return of static buffers is strictly forbidden, and the use of strdup() in such cases is advised. The url_adresse and url_fichier are the address and URI of the file being processed
return value: 1 if the new pointers can be applied (default value)
int (* myfunction)(char** html,int* len,char* url_adresse,char* url_fichier);
"query"Called when the wizard needs to ask a question. The question string contains the question for the (human) user
return value: the string answer ("" for default reply)
char* (* myfunction)(char* question);
"query2"Called when the wizard needs to ask a questionchar* (* myfunction)(char* question);
"query3"Called when the wizard needs to ask a questionchar* (* myfunction)(char* question);
"loop"Called periodically (informational, to display statistics)
return value: 1 if the mirror can continue, 0 if the mirror must be aborted
int (* myfunction)(lien_back* back,int back_max,int back_index,int lien_tot,int lien_ntot,int stat_time,hts_stat_struct* stats);
"check-link"Called when a link has to be tested. The adr and fil are the address and URI of the link being tested. The passed status value has the following meaning: 0 if the link is to be accepted by default, 1 if the link is to be refused by default, and -1 if no decision has yet been taken by the engine
return value: same meaning as the passed status value ; you may generally return -1 to let the engine take the decision by itself
int (* myfunction)(char* adr,char* fil,int status);
"check-mime"Called when a link download has begun, and needs to be tested against its MIME type. The adr and fil are the address and URI of the link being tested, and the mime string contains the link type being processed. The passed status value has the following meaning: 0 if the link is to be accepted by default, 1 if the link is to be refused by default, and -1 if no decision has yet been taken by the engine
return value: same meaning as the passed status value ; you may generally return -1 to let the engine take the decision by itself
int (* myfunction)(char* adr,char* fil,char* mime,int status);
"pause"Called when the engine must pause. When the lockfile passed is deleted, the function can return
return value: none
void (* myfunction)(char* lockfile);
"save-file"Called when a file is to be saved on disk
return value: none
void (* myfunction)(char* file);
"save-file2"Called when a file is to be saved or checked on disk
The hostname, filename and local filename are given. Two additional flags tells if the file is new (is_new) and is the file is to be modified (is_modified).
(!is_new && !is_modified): the file is up-to-date, and will not be modified
(is_new && is_modified): a new file will be written (or an updated file is being written)
(!is_new && is_modified): a file is being updated (append)
(is_new && !is_modified): an empty file will be written ("do not recatch locally erased files")
return value: none
void (* myfunction)(char* hostname,char* filename,char* localfile,int is_new,int is_modified);
"link-detected"Called when a link has been detected
return value: 1 if the link can be analyzed, 0 if the link must not even be considered
int (* myfunction)(char* link);
"transfer-status"Called when a file has been processed (downloaded, updated, or error)
return value: must return 1
int (* myfunction)(lien_back* back);
"save-name"Called when a local filename has to be processed. The adr_complete and fil_complete are the address and URI of the file being saved ; the referer_adr and referer_fil are the address and URI of the referer link. The save string contains the local filename being used. You may modifiy the save string to fit your needs, up to 1024 bytes (note: filename collisions, if any, will be handled by the engine by renaming the file into file-2.ext, file-3.ext ..).
return value: must return 1
int (* myfunction)(char* adr_complete,char* fil_complete,char* referer_adr,char* referer_fil,char* save);
"send-header"Called when HTTP headers are to be sent to the remote server. The buff buffer contains text headers, adr and fil the URL, and referer_adr and referer_fil the referer URL. The outgoing structure contains all information related to the current slot.
return value: 1 if the mirror can continue, 0 if the mirror must be aborted
int (* myfunction)(char* buff, char* adr, char* fil, char* referer_adr, char* referer_fil, htsblk* outgoing);
"receive-header"Called when HTTP headers are recevived from the remote server. The buff buffer contains text headers, adr and fil the URL, and referer_adr and referer_fil the referer URL. The incoming structure contains all information related to the current slot.
return value: 1 if the mirror can continue, 0 if the mirror must be aborted
int (* myfunction)(char* buff, char* adr, char* fil, char* referer_adr, char* referer_fil, htsblk* incoming);


Below additional function names that can be defined inside the module (DLL/.so):
"module function name"function description
int function-name_init(char *args);Called when a function named function-name is extracted from the current module (same as wrapper_init). The optional args provides additional commandline parameters. Returns 1 upon success, 0 if the function should not be extracted.
int wrapper_init(char *fname, char *args);Called when a function named fname is extracted from the current module. The optional args provides additional commandline parameters. Besides, use of htswrap_add (see httrack-library.h) is permitted inside this function to setup other callbacks. Returns 1 upon success, 0 if the function should not be extracted.
int wrapper_exit(void);Called when the module is unloaded. The function should return 1 (but the result is ignored).


Below additional function names that can be defined inside the optional libhttrack-plugin module (libhttrack-plugin.dll or libhttrack-plugin.so) searched inside common library path:
"module function name"function description
void plugin_init(void);Called if the module (named libhttrack-plugin.(so|dll)) is found in the library path. Use of htswrap_add (see httrack-library.h) is permitted inside this function to setup other callbacks.




httrack-3.49.5/html/overview.html0000644000175000017500000001261614336470674013721 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Overview


Please visit our website!


WinHTTrack snapshot

HTTrack HTTrack is an easy-to-use offline browser utility. It allows you to download a World Wide website from the Internet to a local directory, building recursively all directories, getting html, images, and other files from the server to your computer. HTTrack arranges the original site's relative link-structure. Simply open a page of the "mirrored" website in your browser, and you can browse the site from link to link, as if you were viewing it online. HTTrack can also update an existing mirrored site, and resume interrupted downloads. HTTrack is fully configurable, and has an integrated help system.

httrack-3.49.5/html/options.html0000644000175000017500000003440314360553245013535 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Options

  • Filters: how to use them

  • Here you can find informations on filters: how to accept all gif files in a mirror, for example

  • List of options

w  mirror with automatic wizard
This is the default scanning option, the engine automatically scans links according to the default options, and filters defined. It does not prompt a message when a "foreign" link is reached.

W  semi-automatic mirror with help-wizard (asks questions)
This option lets the engine ask the user if a link must be mirrored or not, when a new web has been found.

g  just get files (saved in the current directory)
This option forces the engine not to scan the files indicated - i.e. the engine only gets the files indicated.

i  continue an interrupted mirror using the cache
This option indicates to the engine that a mirror must be updated or continued.

rN  recurse get with limited link depth of N
This option sets the maximum recurse level. Default is infinite (the engine "knows" that it should not go out of current domain)

a   stay on the same address
This is the default primary scanning option, the engine does not go out of domains without permissions (filters, for example)

d   stay on the same principal domain
This option lets the engine go on all sites that exist on the same principal domain.
Example: a link located at www.someweb.com that goes to members.someweb.com will be followed.

l   stay on the same location (.com, etc.)
This option lets the engine go on all sites that exist on the same location.
Example: a link located at www.someweb.com that goes to www.anyotherweb.com will be followed.
Warning: this is a potentially dangerous option, limit the recurse depth with r option.

e   go everywhere on the web
This option lets the engine go on any sites.
Example: a link located at www.someweb.com that goes to www.anyotherweb.org will be followed.
Warning: this is a potentially dangerous option, limit the recurse depth with r option.

n   get non-html files 'near' an html file (ex: an image located outside)
This option lets the engine catch all files that have references on a page, but that exist outside the web site.
Example: List of ZIP files links on a page.

t   test all URLs (even forbidden ones)
This option lets the engine test all links that are not caught.
Example: to test broken links in a site

x   replace external html links by error pages
This option tells the engine to rewrite all links not taken into warning pages.
Example: to browse offline a site, and to warn people that they must be online if they click to external links.

sN  follow robots.txt and meta robots tags
This option sets the way the engine treats "robots.txt" files. This file is often set by webmasters to avoir cgi-bin directories, or other irrevelant pages.
Values: 
  s0  Do not take robots.txt rules
  s1  Follow rules, if compatible with internal filters
  s2  Always follow site's rules

bN  accept cookies in cookies.txt
This option activates or unactivates the cookie
  b0 do not accept cookies
  b1 accept cookies

S   stay on the same directory
This option asks the engine to stay on the same folder level.
Example: A link in /index.html that points to /sub/other.html will not be followed

D   can only go down into subdirs
This is the default option, the engine can go everywhere on the same directoy, or in lower structures

U   can only go to upper directories
This option asks the engine to stay on the same folder level or in upper structures

B   can both go up&down into the directory structure
This option lets the engine to go in any directory level

Y   mirror ALL links located in the first level pages (mirror links)
This option is activated for the links typed in the command line
Example: if you have a list of web sites in www.asitelist.com/index.html, then all these sites will be mirrored

NN  name conversion type (0 *original structure 1,2,3 html/data in one directory)
  N0 Site-structure (default)
  N1 Html in web/, images/other files in web/images/
  N2 Html in web/html, images/other in web/images
  N3 Html in web/,  images/other in web/
  N4 Html in web/, images/other in web/xxx, where xxx is the file extension (all gif will be placed onto web/gif, for example)
  N5 Images/other in web/xxx and Html in web/html

  N99 All files in web/, with random names (gadget !)

  N100 Site-structure, without www.domain.xxx/
  N101 Identical to N1 except that "web" is replaced by the site's name
  N102 Identical to N2 except that "web" is replaced by the site's name
  N103 Identical to N3 except that "web" is replaced by the site's name
  N104 Identical to N4 except that "web" is replaced by the site's name
  N105 Identical to N5 except that "web" is replaced by the site's name
  N199 Identical to N99 except that "web" is replaced by the site's name

  N1001 Identical to N1 except that there is no "web" directory
  N1002 Identical to N2 except that there is no "web" directory
  N1003 Identical to N3 except that there is no "web" directory (option set for g option)
  N1004 Identical to N4 except that there is no "web" directory
  N1005 Identical to N5 except that there is no "web" directory
  N1099 Identical to N99 except that there is no "web" directory

LN  long names
  L0 Filenames and directory names are limited to 8 characters + 3 for extension
  L1 No restrictions (default)

K   keep original links (e.g. http://www.adr/link) (K0 *relative link)
This option has only been kept for compatibility reasons

pN  priority mode:
  p0 just scan, don't save anything (for checking links)
  p1 save only html files
  p2 save only non html files
  p3 save all files
  p7 get html files before, then treat other files

cN  number of multiple connections (*c8)
Set the numer of multiple simultaneous connections

O   path for mirror/logfiles+cache (-O path_mirror[,path_cache_and_logfiles])
This option define the path for mirror and log files
Example: -P "/user/webs","/user/logs"

P   proxy use (-P proxy:port or -P user:pass@proxy:port)
This option define the proxy used in this mirror
Example: -P proxy.myhost.com:8080

F   user-agent field (-F \"user-agent name\
This option define the user-agent field
Example: -F "Mozilla/4.5 (compatible; HTTrack 1.2x; Windows 98)"

mN maximum file length for a non-html file
This option define the maximum size for non-html files
Example: -m100000

mN,N'  for non html (N) and html (N')
This option define the maximum size for non-html files and html-files
Example: -m100000,250000

MN maximum overall size that can be uploaded/scanned
This option define the maximum amount of bytes that can be downloaded
Example: -M1000000

EN maximum mirror time in seconds (60=1 minute, 3600=1 hour)
This option define the maximum time that the mirror can last
Example: -E3600

AN maximum transfer rate in bytes/seconds (1000=1kb/s max)
This option define the maximum transfer rate
Example: -A2000

GN pause transfer if N bytes reached, and wait until lock file is deleted
This option asks the engine to pause every time N bytes have been transferred, and restarts when the lock file "hts-pause.lock" is being deleted
Example: -G20000000

u check document type if unknown (cgi,asp..)
This option define the way the engine checks the file type
  u0 do not check
  u1 check but /
  u2 check always

RN number of retries, in case of timeout or non-fatal errors (*R0)
This option sets the maximum number of tries that can be processed for a file

o *generate output html file in case of error (404..) (o0 don't generate)
This option define whether the engine has to generate html output file or not if an error occurred

TN timeout, number of seconds after a non-responding link is shutdown
This option define the timeout
Example: -T120

JN traffic jam control, minimum transfert rate (bytes/seconds) tolerated for a link
This option define the minimum transfer rate
Example: -J200

HN host is abandoned if: 0=never, 1=timeout, 2=slow, 3=timeout or slow
This option define whether the engine has to abandon a host if a timeout/"too slow" error occurred

&P extended parsing, attempt to parse all links (even in unknown tags or Javascript)
This option activates the extended parsing, that attempt to find links in unknown Html code/javascript

j *parse Java Classes (j0 don't parse)
This option define whether the engine has to parse java files or not to catch included files

I *make an index (I0 don't make)
This option define whether the engine has to generate an index.html on the top directory

X *delete old files after update (X0 keep delete)
This option define whether the engine has to delete locally, after an update, files that have been deleted in the remote mirror, or that have been excluded

C *create/use a cache for updates and retries (C0 no cache)
This option define whether the engine has to generate a cache for retries and updates or not

k  store all files in cache (not useful if files on disk)
This option define whether the engine has to store all files in cache or not

V execute system command after each files ($0 is the filename: -V \"rm \\$0\
This option lets the engine execute a command for each file saved on disk

q  quiet mode (no questions)
Do not ask questions (for example, for confirm an option)

Q  log quiet mode (no log)
Do not generate log files

v  verbose screen mode
Log files are printed in the screen

f *log file mode
Log files are generated into two log files

z  extra infos log
Add more informations on log files

Z  debug log
Add debug informations on log files


--mirror   *make a mirror of site(s) 
--get   get the files indicated, do not seek other URLs
--mirrorlinks   test links in pages (identical to -Y)
--testlinks     test links in pages
--spider    spider site(s), to test links (reports Errors & Warnings)
--update    update a mirror, without confirmation
--skeleton  make a mirror, but gets only html files

--http10  force http/1.0 requests when possible

httrack-3.49.5/html/library.html0000644000175000017500000001133114336470674013510 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

HTTrack Programming page - using the library


All library prototypes are available in the httrack-library.h file.
You may also want to check the httrack.c and httrack.h files to get an example of use of this library.



httrack-3.49.5/html/index.html0000644000175000017500000001341614336470674013161 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Documentation

httrack-3.49.5/html/httrack.man.html0000644000175000017500000013475414555203113014256 00000000000000 httrack

httrack

NAME
SYNOPSIS
DESCRIPTION
EXAMPLES
OPTIONS
FILES
ENVIRONMENT
DIAGNOSTICS
LIMITS
BUGS
COPYRIGHT
AVAILABILITY
AUTHOR
SEE ALSO

NAME

httrack - offline browser : copy websites to a local directory

SYNOPSIS

httrack [ url ]... [ -filter ]... [ +filter ]... [ -O, --path ] [ -w, --mirror ] [ -W, --mirror-wizard ] [ -g, --get-files ] [ -i, --continue ] [ -Y, --mirrorlinks ] [ -P, --proxy ] [ -%f, --httpproxy-ftp[=N] ] [ -%b, --bind ] [ -rN, --depth[=N] ] [ -%eN, --ext-depth[=N] ] [ -mN, --max-files[=N] ] [ -MN, --max-size[=N] ] [ -EN, --max-time[=N] ] [ -AN, --max-rate[=N] ] [ -%cN, --connection-per-second[=N] ] [ -GN, --max-pause[=N] ] [ -cN, --sockets[=N] ] [ -TN, --timeout[=N] ] [ -RN, --retries[=N] ] [ -JN, --min-rate[=N] ] [ -HN, --host-control[=N] ] [ -%P, --extended-parsing[=N] ] [ -n, --near ] [ -t, --test ] [ -%L, --list ] [ -%S, --urllist ] [ -NN, --structure[=N] ] [ -%D, --cached-delayed-type-check ] [ -%M, --mime-html ] [ -LN, --long-names[=N] ] [ -KN, --keep-links[=N] ] [ -x, --replace-external ] [ -%x, --disable-passwords ] [ -%q, --include-query-string ] [ -o, --generate-errors ] [ -X, --purge-old[=N] ] [ -%p, --preserve ] [ -%T, --utf8-conversion ] [ -bN, --cookies[=N] ] [ -u, --check-type[=N] ] [ -j, --parse-java[=N] ] [ -sN, --robots[=N] ] [ -%h, --http-10 ] [ -%k, --keep-alive ] [ -%B, --tolerant ] [ -%s, --updatehack ] [ -%u, --urlhack ] [ -%A, --assume ] [ -@iN, --protocol[=N] ] [ -%w, --disable-module ] [ -F, --user-agent ] [ -%R, --referer ] [ -%E, --from ] [ -%F, --footer ] [ -%l, --language ] [ -%a, --accept ] [ -%X, --headers ] [ -C, --cache[=N] ] [ -k, --store-all-in-cache ] [ -%n, --do-not-recatch ] [ -%v, --display ] [ -Q, --do-not-log ] [ -q, --quiet ] [ -z, --extra-log ] [ -Z, --debug-log ] [ -v, --verbose ] [ -f, --file-log ] [ -f2, --single-log ] [ -I, --index ] [ -%i, --build-top-index ] [ -%I, --search-index ] [ -pN, --priority[=N] ] [ -S, --stay-on-same-dir ] [ -D, --can-go-down ] [ -U, --can-go-up ] [ -B, --can-go-up-and-down ] [ -a, --stay-on-same-address ] [ -d, --stay-on-same-domain ] [ -l, --stay-on-same-tld ] [ -e, --go-everywhere ] [ -%H, --debug-headers ] [ -%!, --disable-security-limits ] [ -V, --userdef-cmd ] [ -%W, --callback ] [ -K, --keep-links[=N] ] [

DESCRIPTION

httrack allows you to download a World Wide Web site from the Internet to a local directory, building recursively all directories, getting HTML, images, and other files from the server to your computer. HTTrack arranges the original site’s relative link-structure. Simply open a page of the "mirrored" website in your browser, and you can browse the site from link to link, as if you were viewing it online. HTTrack can also update an existing mirrored site, and resume interrupted downloads.

EXAMPLES

httrack www.someweb.com/bob/

mirror site www.someweb.com/bob/ and only this site

httrack www.someweb.com/bob/ www.anothertest.com/mike/ +*.com/*.jpg
-mime:application/*

mirror the two sites together (with shared links) and accept any .jpg files on .com sites

httrack www.someweb.com/bob/bobby.html +* -r6

means get all files starting from bobby.html, with 6 link-depth, and possibility of going everywhere on the web

httrack www.someweb.com/bob/bobby.html --spider -P
proxy.myhost.com:8080

runs the spider on www.someweb.com/bob/bobby.html using a proxy

httrack --update

updates a mirror in the current folder

httrack

will bring you to the interactive mode

httrack --continue

continues a mirror in the current folder

OPTIONS

General options:

-O

path for mirror/logfiles+cache (-O path mirror[,path cache and logfiles]) (--path <param>)

Action options:

-w

*mirror web sites (--mirror)

-W

mirror web sites, semi-automatic (asks questions) (--mirror-wizard)

-g

just get files (saved in the current directory) (--get-files)

-i

continue an interrupted mirror using the cache (--continue)

-Y

mirror ALL links located in the first level pages (mirror links) (--mirrorlinks)

Proxy options:

-P

proxy use (-P proxy:port or -P user:pass@proxy:port) (--proxy <param>)

-%f

*use proxy for ftp (f0 don t use) (--httpproxy-ftp[=N])

-%b

use this local hostname to make/send requests (-%b hostname) (--bind <param>)

Limits options:

-rN

set the mirror depth to N (* r9999) (--depth[=N])

-%eN

set the external links depth to N (* %e0) (--ext-depth[=N])

-mN

maximum file length for a non-html file (--max-files[=N])

-mN,N2

maximum file length for non html (N) and html (N2)

-MN

maximum overall size that can be uploaded/scanned (--max-size[=N])

-EN

maximum mirror time in seconds (60=1 minute, 3600=1 hour) (--max-time[=N])

-AN

maximum transfer rate in bytes/seconds (1000=1KB/s max) (--max-rate[=N])

-%cN

maximum number of connections/seconds (*%c10) (--connection-per-second[=N])

-GN

pause transfer if N bytes reached, and wait until lock file is deleted (--max-pause[=N])

Flow control:

-cN

number of multiple connections (*c8) (--sockets[=N])

-TN

timeout, number of seconds after a non-responding link is shutdown (--timeout[=N])

-RN

number of retries, in case of timeout or non-fatal errors (*R1) (--retries[=N])

-JN

traffic jam control, minimum transfert rate (bytes/seconds) tolerated for a link (--min-rate[=N])

-HN

host is abandoned if: 0=never, 1=timeout, 2=slow, 3=timeout or slow (--host-control[=N])

Links options:

-%P

*extended parsing, attempt to parse all links, even in unknown tags or Javascript (%P0 don t use) (--extended-parsing[=N])

-n

get non-html files near an html file (ex: an image located outside) (--near)

-t

test all URLs (even forbidden ones) (--test)

-%L

<file> add all URL located in this text file (one URL per line) (--list <param>)

-%S

<file> add all scan rules located in this text file (one scan rule per line) (--urllist <param>)

Build options:

-NN

structure type (0 *original structure, 1+: see below) (--structure[=N])

-or

user defined structure (-N "%h%p/%n%q.%t")

-%N

delayed type check, don t make any link test but wait for files download to start instead (experimental) (%N0 don t use, %N1 use for unknown extensions, * %N2 always use)

-%D

cached delayed type check, don t wait for remote type during updates, to speedup them (%D0 wait, * %D1 don t wait) (--cached-delayed-type-check)

-%M

generate a RFC MIME-encapsulated full-archive (.mht) (--mime-html)

-LN

long names (L1 *long names / L0 8-3 conversion / L2 ISO9660 compatible) (--long-names[=N])

-KN

keep original links (e.g. http://www.adr/link) (K0 *relative link, K absolute links, K4 original links, K3 absolute URI links, K5 transparent proxy link) (--keep-links[=N])

-x

replace external html links by error pages (--replace-external)

-%x

do not include any password for external password protected websites (%x0 include) (--disable-passwords)

-%q

*include query string for local files (useless, for information purpose only) (%q0 don t include) (--include-query-string)

-o

*generate output html file in case of error (404..) (o0 don t generate) (--generate-errors)

-X

*purge old files after update (X0 keep delete) (--purge-old[=N])

-%p

preserve html files as is (identical to -K4 -%F "" ) (--preserve)

-%T

links conversion to UTF-8 (--utf8-conversion)

Spider options:

-bN

accept cookies in cookies.txt (0=do not accept,* 1=accept) (--cookies[=N])

-u

check document type if unknown (cgi,asp..) (u0 don t check, * u1 check but /, u2 check always) (--check-type[=N])

-j

*parse Java Classes (j0 don t parse, bitmask: |1 parse default, |2 don t parse .class |4 don t parse .js |8 don t be aggressive) (--parse-java[=N])

-sN

follow robots.txt and meta robots tags (0=never,1=sometimes,* 2=always, 3=always (even strict rules)) (--robots[=N])

-%h

force HTTP/1.0 requests (reduce update features, only for old servers or proxies) (--http-10)

-%k

use keep-alive if possible, greately reducing latency for small files and test requests (%k0 don t use) (--keep-alive)

-%B

tolerant requests (accept bogus responses on some servers, but not standard!) (--tolerant)

-%s

update hacks: various hacks to limit re-transfers when updating (identical size, bogus response..) (--updatehack)

-%u

url hacks: various hacks to limit duplicate URLs (strip //, www.foo.com==foo.com..) (--urlhack)

-%A

assume that a type (cgi,asp..) is always linked with a mime type (-%A php3,cgi=text/html;dat,bin=application/x-zip) (--assume <param>)

-can

also be used to force a specific file type: --assume foo.cgi=text/html

-@iN

internet protocol (0=both ipv6+ipv4, 4=ipv4 only, 6=ipv6 only) (--protocol[=N])

-%w

disable a specific external mime module (-%w htsswf -%w htsjava) (--disable-module <param>)

Browser ID:

-F

user-agent field sent in HTTP headers (-F "user-agent name") (--user-agent <param>)

-%R

default referer field sent in HTTP headers (--referer <param>)

-%E

from email address sent in HTTP headers (--from <param>)

-%F

footer string in Html code (-%F "Mirrored [from host %s [file %s [at %s]]]" (--footer <param>)

-%l

preffered language (-%l "fr, en, jp, *" (--language <param>)

-%a

accepted formats (-%a "text/html,image/png;q=0.9,*/*;q=0.1" (--accept <param>)

-%X

additional HTTP header line (-%X "X-Magic: 42" (--headers <param>)

Log, index, cache

-C

create/use a cache for updates and retries (C0 no cache,C1 cache is prioritary,* C2 test update before) (--cache[=N])

-k

store all files in cache (not useful if files on disk) (--store-all-in-cache)

-%n

do not re-download locally erased files (--do-not-recatch)

-%v

display on screen filenames downloaded (in realtime) - * %v1 short version - %v2 full animation (--display)

-Q

no log - quiet mode (--do-not-log)

-q

no questions - quiet mode (--quiet)

-z

log - extra infos (--extra-log)

-Z

log - debug (--debug-log)

-v

log on screen (--verbose)

-f

*log in files (--file-log)

-f2

one single log file (--single-log)

-I

*make an index (I0 don t make) (--index)

-%i

make a top index for a project folder (* %i0 don t make) (--build-top-index)

-%I

make an searchable index for this mirror (* %I0 don t make) (--search-index)

Expert options:

-pN

priority mode: (* p3) (--priority[=N])

-p0

just scan, don t save anything (for checking links)

-p1

save only html files

-p2

save only non html files

-*p3

save all files

-p7

get html files before, then treat other files

-S

stay on the same directory (--stay-on-same-dir)

-D

*can only go down into subdirs (--can-go-down)

-U

can only go to upper directories (--can-go-up)

-B

can both go up&down into the directory structure (--can-go-up-and-down)

-a

*stay on the same address (--stay-on-same-address)

-d

stay on the same principal domain (--stay-on-same-domain)

-l

stay on the same TLD (eg: .com) (--stay-on-same-tld)

-e

go everywhere on the web (--go-everywhere)

-%H

debug HTTP headers in logfile (--debug-headers)

Guru options: (do NOT use if possible)

-#X

*use optimized engine (limited memory boundary checks) (--fast-engine)

-#0

filter test (-#0 *.gif www.bar.com/foo.gif ) (--debug-testfilters <param>)

-#1

simplify test (-#1 ./foo/bar/../foobar)

-#2

type test (-#2 /foo/bar.php)

-#C

cache list (-#C *.com/spider*.gif (--debug-cache <param>)

-#R

cache repair (damaged cache) (--repair-cache)

-#d

debug parser (--debug-parsing)

-#E

extract new.zip cache meta-data in meta.zip

-#f

always flush log files (--advanced-flushlogs)

-#FN

maximum number of filters (--advanced-maxfilters[=N])

-#h

version info (--version)

-#K

scan stdin (debug) (--debug-scanstdin)

-#L

maximum number of links (-#L1000000) (--advanced-maxlinks[=N])

-#p

display ugly progress information (--advanced-progressinfo)

-#P

catch URL (--catch-url)

-#R

old FTP routines (debug) (--repair-cache)

-#T

generate transfer ops. log every minutes (--debug-xfrstats)

-#u

wait time (--advanced-wait)

-#Z

generate transfer rate statistics every minutes (--debug-ratestats)

Dangerous options: (do NOT use unless you exactly know what you are doing)

-%!

bypass built-in security limits aimed to avoid bandwidth abuses (bandwidth, simultaneous connections) (--disable-security-limits)

-IMPORTANT

NOTE: DANGEROUS OPTION, ONLY SUITABLE FOR EXPERTS

-USE

IT WITH EXTREME CARE

Command-line specific options:

-V

execute system command after each files ($0 is the filename: -V "rm \$0") (--userdef-cmd <param>)

-%W

use an external library function as a wrapper (-%W myfoo.so[,myparameters]) (--callback <param>)

Details: Option N

-N0

Site-structure (default)

-N1

HTML in web/, images/other files in web/images/

-N2

HTML in web/HTML, images/other in web/images

-N3

HTML in web/, images/other in web/

-N4

HTML in web/, images/other in web/xxx, where xxx is the file extension (all gif will be placed onto web/gif, for example)

-N5

Images/other in web/xxx and HTML in web/HTML

-N99

All files in web/, with random names (gadget !)

-N100

Site-structure, without www.domain.xxx/

-N101

Identical to N1 except that "web" is replaced by the site s name

-N102

Identical to N2 except that "web" is replaced by the site s name

-N103

Identical to N3 except that "web" is replaced by the site s name

-N104

Identical to N4 except that "web" is replaced by the site s name

-N105

Identical to N5 except that "web" is replaced by the site s name

-N199

Identical to N99 except that "web" is replaced by the site s name

-N1001

Identical to N1 except that there is no "web" directory

-N1002

Identical to N2 except that there is no "web" directory

-N1003

Identical to N3 except that there is no "web" directory (option set for g option)

-N1004

Identical to N4 except that there is no "web" directory

-N1005

Identical to N5 except that there is no "web" directory

-N1099

Identical to N99 except that there is no "web" directory

Details: User-defined option N
%n Name of file without file type (ex: image)
%N Name of file, including file type (ex: image.gif)
%t File type (ex: gif)
%p Path [without ending /] (ex: /someimages)
%h Host name (ex: www.someweb.com)
%M URL MD5 (128 bits, 32 ascii bytes)
%Q query string MD5 (128 bits, 32 ascii bytes)
%k full query string
%r protocol name (ex: http)
%q small query string MD5 (16 bits, 4 ascii bytes)
%s? Short name version (ex: %sN)
%[param] param variable in query string
%[param:before:after:empty:notfound] advanced variable extraction

Details: User-defined option N and advanced variable extraction
%[param:before:after:empty:notfound]

-param

: parameter name

-before

: string to prepend if the parameter was found

-after

: string to append if the parameter was found

-notfound

: string replacement if the parameter could not be found

-empty

: string replacement if the parameter was empty

-all

fields, except the first one (the parameter name), can be empty

Details: Option K

-K0

foo.cgi?q=45 -> foo4B54.html?q=45 (relative URI, default)

-K

-> http://www.foobar.com/folder/foo.cgi?q=45 (absolute URL) (--keep-links[=N])

-K3

-> /folder/foo.cgi?q=45 (absolute URI)

-K4

-> foo.cgi?q=45 (original URL)

-K5

-> http://www.foobar.com/folder/foo4B54.html?q=45 (transparent proxy URL)

Shortcuts:
--mirror

<URLs> *make a mirror of site(s) (default)

--get

<URLs> get the files indicated, do not seek other URLs (-qg)

--list

<text file> add all URL located in this text file (-%L)

--mirrorlinks

<URLs> mirror all links in 1st level pages (-Y)

--testlinks

<URLs> test links in pages (-r1p0C0I0t)

--spider

<URLs> spider site(s), to test links: reports Errors & Warnings (-p0C0I0t)

--testsite

<URLs> identical to --spider

--skeleton

<URLs> make a mirror, but gets only html files (-p1)

--update

update a mirror, without confirmation (-iC2)

--continue

continue a mirror, without confirmation (-iC1)

--catchurl

create a temporary proxy to capture an URL or a form post URL

--clean

erase cache & log files

--http10

force http/1.0 requests (-%h)

Details: Option %W: External callbacks prototypes
see htsdefines.h

FILES

/etc/httrack.conf

The system wide configuration file.

ENVIRONMENT

HOME

Is being used if you defined in /etc/httrack.conf the line path ~/websites/#

DIAGNOSTICS

Errors/Warnings are reported to hts-log.txt by default, or to stderr if the -v option was specified.

LIMITS

These are the principals limits of HTTrack for that moment. Note that we did not heard about any other utility that would have solved them.

- Several scripts generating complex filenames may not find them (ex: img.src=’image’+a+Mobj.dst+’.gif’)

- Some java classes may not find some files on them (class included)

- Cgi-bin links may not work properly in some cases (parameters needed). To avoid them: use filters like -*cgi-bin*

BUGS

Please reports bugs to <bugs@httrack.com>. Include a complete, self-contained example that will allow the bug to be reproduced, and say which version of httrack you are using. Do not forget to detail options used, OS version, and any other information you deem necessary.

COPYRIGHT

Copyright (C) 1998-2024 Xavier Roche and other contributors

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program. If not, see <http://www.gnu.org/licenses/>.

AVAILABILITY

The most recent released version of httrack can be found at: http://www.httrack.com

AUTHOR

Xavier Roche <roche@httrack.com>

SEE ALSO

The HTML documentation (available online at http://www.httrack.com/html/ ) contains more detailed information. Please also refer to the httrack FAQ (available online at http://www.httrack.com/html/faq.html )


httrack-3.49.5/html/filters.html0000644000175000017500000004605114336470674013523 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Filters: Advanced


See also: The FAQ

You have to know that once you have defined starts links, the default mode is to mirror these links - i.e. if one of your start page is www.someweb.com/test/index.html, all links starting with www.someweb.com/test/ will be accepted. But links directly in www.someweb.com/.. will not be accepted, however, because they are in a higher strcuture. This prevent HTTrack from mirroring the whole site. (All files in structure levels equal or lower than the primary links will be retrieved.)

But you may want to download files that are not directly in the subfolders, or on the contrary refuse files of a particular type. That is the purpose of filters.

Scan rules based on URL or extension (e.g. accept or refuse all .zip or .gif files)

To accept a family of links (for example, all links with a specific name or type), you just have to add an authorization filter, like +*.gif. The pattern is a plus (this one: +), followed by a pattern composed of letters and wildcards (this one: *).

To forbide a family of links, define an authorization filter, like -*.gif. The pattern is a dash (this one: -), followed by a the same kind of pattern as for the authorization filter.

Example: +*.gif will accept all files finished by .gif
Example: -*.gif will refuse all files finished by .gif

Scan rules based on size (e.g. accept or refuse files bigger/smaller than a certain size)

Once a link is scheduled for download, you can still refuse it (i.e. abort the download) by checking its size to ensure that you won't reach a defined limit. Example: You may want to accept all files on the domain www.example.com, using '+www.example.com/*', including gif files inside this domain and outside (eternal images), but not take to large images, or too small ones (thumbnails)
Excluding gif images smaller than 5KB and images larger than 100KB is therefore a good option; +www.example.com +*.gif -*.gif*[<5] -*.gif*[>100]
Important notice: size scan rules are checked after the link was scheduled for download, allowing to abort the connection.

Scan rules based on MIME types (e.g. accept or refuse all files of type audio/mp3)

Once a link is scheduled for download, you can still refuse it (i.e. abort the download) by matching its MIME type against certain patterns. Example: You may want to accept all files on the domain www.example.com, using '+www.example.com/*', and exclude all gif files, using '-*.gif'. But some dynamic scripts (such as www.example.com/dynamic.php) can both generate html content, or image data content, depending on the context. Excluding this script, using the scan rule '-www.example.com/dynamic.php', is therefore not a good solution.
The only reliable way in such cases is to exclude the specific mime type 'image/gif', using the scan rule syntax:
-mime:image/gif
Important notice: MIME types scan rules are only checked against links that were scheduled for download, i.e. links already authorized by url scan rules. Hence, using '+mime:image/gif' will only be a hint to accept images that were already authorized, if previous MIME scan rules excluded them - such as in '-mime:*/* +mime:text/html +mime:image/gif'

Scan rules patterns:

1.a. Scan rules based on URL or extension


Filters are analyzed by HTTrack from the first filter to the last one. The complete URL name is compared to filters defined by the user or added automatically by HTTrack.

A scan rule has an higher priority is it is declared later - hierarchy is important:

+*.gif -image*.gif Will accept all gif files BUT image1.gif,imageblue.gif,imagery.gif and so on
-image*.gif +*.gif Will accept all gif files, because the second pattern is prioritary (because it is defined AFTER the first one)

Note: these scan rules can be mixed with scan rules based on size (see 1.b)

We saw that patterns are composed of letters and wildcards (*), as in */image*.gif


Special wild cards can be used for specific characters: (*[..])

* any characters (the most commonly used)
*[file] or *[name] any filename or name, e.g. not /,? and ; characters
*[path] any path (and filename), e.g. not ? and ; characters
*[a,z,e,r,t,y] any letters among a,z,e,r,t,y
*[a-z] any letters
*[0-9,a,z,e,r,t,y] any characters among 0..9 and a,z,e,r,t,y
*[\*] the * character
*[\\] the \ character
*[\[\]] the [ or ] character
*[] no characters must be present after


Here are some examples of filters: (that can be generated automatically using the interface)

www.thisweb.com* This will refuse/accept this web site (all links located in it will be rejected)
*.com/* This will refuse/accept all links that contains .com in them
*cgi-bin* This will refuse/accept all links that contains cgi-bin in them
www.*[path].com/*[path].zip This will refuse/accept all zip files in .com addresses
*someweb*/*.tar* This will refuse/accept all tar (or tar.gz etc.) files in hosts containing someweb
*/*somepage* This will refuse/accept all links containing somepage (but not in the address)
*.html This will refuse/accept all html files.
Warning! With this filter you will accept ALL html files, even those in other addresses. (causing a global (!) web mirror..) Use www.someweb.com/*.html to accept all html files from a web.
*.html*[] Identical to *.html, but the link must not have any supplemental characters at the end (links with parameters, like www.someweb.com/index.html?page=10, will be refused)

1.b. Scan rules based on size


Filters are analyzed by HTTrack from the first filter to the last one. The sizes are compared against scan rules defined by the user.

A scan rule has an higher priority is it is declared later - hierarchy is important.
Note: scan rules based on size can be mixed with regular URL patterns


Size patterns:

*[<NN] the file size must be smaller than NN KB
(note: this may cause broken files during the download)
*[>NN] the file size must be greater than NN KB
(note: this may cause broken files during the download)
*[<NN>MM] the file size must be smaller than NN KB and greater than MM KB
(note: this may cause broken files during the download)


Here are some examples of filters: (that can be generated automatically using the interface)

-*[<10] the file will be forbidden if its size is smaller than 10 KB
-*[>50] the file will be forbidden if its size is greater than 50 KB
-*[<10] -*[>50] the file will be forbidden if if its size is smaller than 10 KB or greater than 50 KB
+*[<80>1] the file will be accepted if if its size is smaller than 80 KB and greater than 1 KB

2. Scan rules based on MIME types


Filters are analyzed by HTTrack from the first filter to the last one. The complete MIME type is compared against scan rules defined by the user.

A scan rule has an higher priority is it is declared later - hierarchy is important
Note: scan rules based on MIME types can NOT be mixed with regular URL patterns or size patterns within the same rule, but you can use both of them in distinct ones


Here are some examples of filters: (that can be generated automatically using the interface)

-mime:application/octet-stream This will refuse all links of type 'application/octet-stream' that were already scheduled for download (i.e. the download will be aborted)
-mime:application/* This will refuse all links of type begining with 'application/' that were already scheduled for download (i.e. the download will be aborted)
-mime:application/* +mime:application/pdf This will refuse all links of type begining with 'application/' that were already scheduled for download, except for 'application/pdf' ones (i.e. all other 'application/' link download will be aborted)
-mime:video/* This will refuse all video links that were already scheduled for download (i.e. all other 'application/' link download will be aborted)
-mime:video/* -mime:audio/* This will refuse all audio and video links that were already scheduled for download (i.e. all other 'application/' link download will be aborted)
-mime:*/* +mime:text/html +mime:image/* This will refuse all links that were already scheduled for download, except html pages, and images (i.e. all other link download will be aborted). Note that this is a very unefficient way of filtering files, as aborted downloads will generate useless requests to the server. You are strongly advised to use additional URL scan rules

2. Scan rules based on URL or size, and scan rules based on MIME types interactions

You must use scan rules based on MIME types very carefully, or you will end up with an imcomplete mirror, or create an unefficient download session (generating costly and useless requests to the server)


Here are some examples of good/bad scan rules interactions:

Purpose Method Result
Download all html and images on www.example.com -*
+www.example.com/*.html
+www.example.com/*.php
+www.example.com/*.asp
+www.example.com/*.gif
+www.example.com/*.jpg
+www.example.com/*.png
-mime:*/* +mime:text/html +mime:image/*
Good: efficient download
-*
+www.example.com/*
-mime:*/* +mime:text/html +mime:image/*
Bad: many aborted downloads, leading to poor performances and server load
Download only html on www.example.com, plus ZIP files -*
+www.example.com/*.html
+www.example.com/somedynamicscript.php
+www.example.com/*.zip
-mime:* +mime:text/html +mime:application/zip
Good: ZIP files will be downloaded, even those generated by 'somedynamicscript.php'
-*
+www.example.com/*.html
-mime:* +mime:text/html +mime:application/zip
Bad: ZIP files will never be scheduled for download, and hence the zip mime scan rule will never be used
Download all html, and images smaller than 100KB on www.example.com -*
+www.example.com/*.html
+www.example.com/*.php
+www.example.com/*.asp
+www.example.com/*.gif*[<100]
+www.example.com/*.jpg*[<100]
+www.example.com/*.png*[<100]
-mime:*/* +mime:text/html +mime:image/*
Good: efficient download
-*
+www.example.com/**[<100]
-mime:*/* +mime:text/html +mime:image/*
Bad: many aborted downloads, leading to poor performances and server load

httrack-3.49.5/html/fcguide.html0000644000175000017500000031604314360553245013453 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Httrack Users Guide (3.10)

By Fred Cohen

Background and Introduction

I started using httrack in mid-2000 and found it to be an excellent tool for imaging web sites. Various words are used to describe this process - from imaging to mirroring to snaking and so on. I will be using a variety of these words in my description.

I have used many such tools over the years, have performed many manual and semi-automatic operations of similar sorts, and written partial programs to do similar functions, but - at least for now - httrack seems to me to be the best option for this function.

The only problem I encountered when using httrack was that it is so rich with features that I could never really figure out precisely the right thing to do at any given point. I was using recepies rather than knowledge to get the job done - and I was pestering the authors for those recepies. After a few days of very helpful assistance from the authors I volunteered to write a users manual for httrack - and here it is. I hope it gets the job done.


Basics

Httrack is a program that gets information from the Internet, looks for pointers to other information, gets that information, and so forth. If you ask it to, and have enough disk space, it will try to make a copy of the whole Internet on your computer. While this may be the answer to Dilbert's boss when he asks to get a printout of the Internet for some legal document, for most of us, we want to get copies of just the right part of the Internet, and have them nicely organized for our use. This is where httrack does a great job. Here's a simple example:


httrack "http://www.all.net/" -O "/tmp/www.all.net" "+*.all.net/*" -v

In this example, we ask httrack to start the Universal Resource Locator (URL) http://www.all.net/ and store the results under the directory /tmp/www.all.net (the -O stands for "output to") while not going beyond the bounds of all the files in the www.all.net domain and printing out any error messages along the way (-v means verbose). This is the most common way that I use httrack. Please note that this particular command might take you a while - and run you out of disk space.

This sort of a mirror image is not an identical copy of the original web site - in some ways it's better such as for local use - while in other ways it may be problematic - such as for legal use. This default mirroring method changes the URLs within the web site so that the references are made relative to the location the copy is stored in. This makes it very useful for navigating through the web site on your local machine with a web browser since most things will work as you would expect them to work. In this example, URLs that point outside of the www.all.net domain space will still point there, and if you encounter one, the web browser will try to get the data from that location.

For each of the issues discussed here - and many more - httrack has options to allow you to make different choices and get different results. This is one of the great things about httrack - and one of the the real major problems with using it without the knowledge of all that it can do. If you want to know all the things httrack can do, you might try typing:


httrack --help

Unfortunately, while this outputs a though list of options, it is somewhat less helpful it might be for those who don't know what the options all mean and haven't used them before. On the other hand, this is most useful for those who already know how to use the program but don't remember some obscure option that they haven't used for some time.

The rest of this manual is dedicated to detailing what you find in the help message and providing examples - lots and lots of examples... Here is what you get (page by page - use to move to the next page in the real program) if you type 'httrack --help':

>httrack --help
 HTTrack version 3.03BETAo4 (compiled Jul  1 2001)
	usage: ./httrack ] [-]
	with options listed below: (* is the default value)

General options:
  O  path for mirror/logfiles+cache (-O path_mirror[,path_cache_and_logfiles]) (--path )
 %O  top path if no path defined (-O path_mirror[,path_cache_and_logfiles])

Action options:
  w *mirror web sites (--mirror)
  W  mirror web sites, semi-automatic (asks questions) (--mirror-wizard)
  g  just get files (saved in the current directory) (--get-files)
  i  continue an interrupted mirror using the cache
  Y   mirror ALL links located in the first level pages (mirror links) (--mirrorlinks)

Proxy options:
  P  proxy use (-P proxy:port or -P user:pass@proxy:port) (--proxy )
 %f *use proxy for ftp (f0 don't use) (--httpproxy-ftp[=N])

Limits options:
  rN set the mirror depth to N (* r9999) (--depth[=N])
 %eN set the external links depth to N (* %e0) (--ext-depth[=N])
  mN maximum file length for a non-html file (--max-files[=N])
  mN,N'                  for non html (N) and html (N')
  MN maximum overall size that can be uploaded/scanned (--max-size[=N])
  EN maximum mirror time in seconds (60=1 minute, 3600=1 hour) (--max-time[=N])
  AN maximum transfer rate in bytes/seconds (1000=1kb/s max) (--max-rate[=N])
 %cN maximum number of connections/seconds (*%c10)
  GN pause transfer if N bytes reached, and wait until lock file is deleted (--max-pause[=N])

Flow control:
  cN number of multiple connections (*c8) (--sockets[=N])
  TN timeout, number of seconds after a non-responding link is shutdown (--timeout)
  RN number of retries, in case of timeout or non-fatal errors (*R1) (--retries[=N])
  JN traffic jam control, minimum transfert rate (bytes/seconds) tolerated for a link (--min-rate[=N])
  HN host is abandoned if: 0=never, 1=timeout, 2=slow, 3=timeout or slow (--host-control[=N])

Links options:
 %P *extended parsing, attempt to parse all links, even in unknown tags or Javascript (%P0 don't use) (--extended-parsing[=N])
  n  get non-html files 'near' an html file (ex: an image located outside) (--near)
  t  test all URLs (even forbidden ones) (--test)
 %L )

Build options:
  NN structure type (0 *original structure, 1+: see below) (--structure[=N])
     or user defined structure (-N "%h%p/%n%q.%t")
  LN long names (L1 *long names / L0 8-3 conversion) (--long-names[=N])
  KN keep original links (e.g. http://www.adr/link) (K0 *relative link, K absolute links, K3 absolute URI links) (--keep-links[=N])
  x  replace external html links by error pages (--replace-external)
 %x  do not include any password for external password protected websites (%x0 include) (--no-passwords)
 %q *include query string for local files (useless, for information purpose only) (%q0 don't include) (--include-query-string)
  o *generate output html file in case of error (404..) (o0 don't generate) (--generate-errors)
  X *purge old files after update (X0 keep delete) (--purge-old[=N])

Spider options:
  bN accept cookies in cookies.txt (0=do not accept,* 1=accept) (--cookies[=N])
  u  check document type if unknown (cgi,asp..) (u0 don't check, * u1 check but /, u2 check always) (--check-type[=N])
  j *parse Java Classes (j0 don't parse) (--parse-java[=N])
  sN follow robots.txt and meta robots tags (0=never,1=sometimes,* 2=always) (--robots[=N])
 %h  force HTTP/1.0 requests (reduce update features, only for old servers or proxies) (--http-10)
 %B  tolerant requests (accept bogus responses on some servers, but not standard!) (--tolerant)
 %s  update hacks: various hacks to limit re-transfers when updating (identical size, bogus response..) (--updatehack)
 %A  assume that a type (cgi,asp..) is always linked with a mime type (-%A php3=text/html) (--assume )

Browser ID:
  F  user-agent field (-F "user-agent name") (--user-agent )
 %F  footer string in Html code (-%F "Mirrored [from host %s [file %s [at %s]]]" (--footer )
 %l  preffered language (-%l "fr, en, jp, *" (--language )

Log, index, cache
  C  create/use a cache for updates and retries (C0 no cache,C1 cache is prioritary,* C2 test update before) (--cache[=N])
  k  store all files in cache (not useful if files on disk) (--store-all-in-cache)
 %n  do not re-download locally erased files (--do-not-recatch)
 %v  display on screen filenames downloaded (in realtime) (--display)
  Q  no log - quiet mode (--do-not-log)
  q  no questions - quiet mode (--quiet)
  z  log - extra infos (--extra-log)
  Z  log - debug (--debug-log)
  v  log on screen (--verbose)
  f *log in files (--file-log)
  f2 one single log file (--single-log)
  I *make an index (I0 don't make) (--index)
 %I  make an searchable index for this mirror (* %I0 don't make) (--search-index)

Expert options:
  pN priority mode: (* p3) (--priority[=N])
      0 just scan, don't save anything (for checking links)
      1 save only html files
      2 save only non html files
     *3 save all files
      7 get html files before, then treat other files
  S  stay on the same directory
  D *can only go down into subdirs
  U  can only go to upper directories
  B  can both go up&down into the directory structure
  a *stay on the same address
  d  stay on the same principal domain
  l  stay on the same TLD (eg: .com)
  e  go everywhere on the web
 %H  debug HTTP headers in logfile (--debug-headers)

Guru options: (do NOT use)
 #0  Filter test (-#0 '*.gif' 'www.bar.com/foo.gif')
 #f  Always flush log files
 #FN Maximum number of filters
 #h  Version info
 #K  Scan stdin (debug)
 #L  Maximum number of links (-#L1000000)
 #p  Display ugly progress information
 #P  Catch URL
 #R  Old FTP routines (debug)
 #T  Generate transfer ops. log every minutes
 #u  Wait time
 #Z  Generate transfer rate statistics every minutes
 #!  Execute a shell command (-#! "echo hello")

Command-line specific options:
  V execute system command after each files ($0 is the filename: -V "rm \$0") (--userdef-cmd )
 %U run the engine with another id when called as root (-%U smith) (--user )

Details: Option N
  N0 Site-structure (default)
  N1 HTML in web/, images/other files in web/images/
  N2 HTML in web/HTML, images/other in web/images
  N3 HTML in web/,  images/other in web/
  N4 HTML in web/, images/other in web/xxx, where xxx is the file extension
(all gif will be placed onto web/gif, for example) N5 Images/other in web/xxx and HTML in web/HTML N99 All files in web/, with random names (gadget !) N100 Site-structure, without www.domain.xxx/ N101 Identical to N1 except that "web" is replaced by the site's name N102 Identical to N2 except that "web" is replaced by the site's name N103 Identical to N3 except that "web" is replaced by the site's name N104 Identical to N4 except that "web" is replaced by the site's name N105 Identical to N5 except that "web" is replaced by the site's name N199 Identical to N99 except that "web" is replaced by the site's name N1001 Identical to N1 except that there is no "web" directory N1002 Identical to N2 except that there is no "web" directory N1003 Identical to N3 except that there is no "web" directory (option set for g option) N1004 Identical to N4 except that there is no "web" directory N1005 Identical to N5 except that there is no "web" directory N1099 Identical to N99 except that there is no "web" directory Details: User-defined option N %n Name of file without file type (ex: image) (--do-not-recatch) %N Name of file, including file type (ex: image.gif) %t File type (ex: gif) %p Path [without ending /] (ex: /someimages) %h Host name (ex: www.someweb.com) (--http-10) %M URL MD5 (128 bits, 32 ascii bytes) %Q query string MD5 (128 bits, 32 ascii bytes) %q small query string MD5 (16 bits, 4 ascii bytes) (--include-query-string) %s? Short name version (ex: %sN) %[param] param variable in query string Shortcuts: --mirror

For many of you, the manual is now complete, but for the rest of us, I will now go through this listing one item at a time with examples... I will be here a while...


Syntax

httrack  [-option] [+] [-] 

The syntax of httrack is quite simple. You specify the URLs you wish to start the process from (), any options you might want to add ([-option], any filters specifying places you should ([+]) and should not ([-]) go, and end the command line by pressing . Httrack then goes off and does your bidding. For example:


httrack www.all.net/bob/

This will use the 'defaults' (those selections from the help page marked with '*' in the listing above) to image the web site. Specifically, the defauls are:

  w *mirror web sites
 %f *use proxy for ftp (f0 don't use)
  cN number of multiple connections (*c8)
  RN number of retries, in case of timeout or non-fatal errors (*R1)
 %P *extended parsing, attempt to parse all links, even in unknown tags or Javascript (%P0 don't use)
  NN  name conversion type (0 *original structure, 1+: see below)
  LN  long names (L1 *long names / L0 8-3 conversion)
  K   keep original links (e.g. http://www.adr/link) (K0 *relative link)
  o *generate output html file in case of error (404..) (o0 don't generate)
  X *purge old files after update (X0 keep delete)
  bN  accept cookies in cookies.txt (0=do not accept,* 1=accept)
  u check document type if unknown (cgi,asp..) (u0 don't check, * u1 check but /, u2 check always)
  j *parse Java Classes (j0 don't parse)
  sN  follow robots.txt and meta robots tags (0=never,1=sometimes,* 2=always)
  C  create/use a cache for updates and retries (C0 no cache,C1 cache is prioritary,* C2 test update before)
  f *log file mode
  I *make an index (I0 don't make)
  pN priority mode: (* p3)  *3 save all files
  D  *can only go down into subdirs
  a  *stay on the same address
  --mirror       *make a mirror of site(s) (default)

Here's what all of that means:

      w *mirror web sites 

    Automatically go though each URL you download and look for links to other URLs inside it, dowloading them as well.

     %f *use proxy for ftp (f0 don't use) 

    If there are and links to ftp URLs (URLs using the file transfer protocol (FTP) rather than the hypertext transfer protocol HTTP), go through an ftp proxy server to get them.

      cN number of multiple connections (*c8) 

    Use up to 8 simultaneous downloads so that at any gioven time, up to 8 URLs may be underway.

      RN number of retries, in case of timeout or non-fatal errors (*R1) 

    Retry once if anything goes wrong with a download.

     %P *extended parsing, attempt to parse all links, even in unknown tags or Javascript (%P0 don't use) 

    Try to parse all URLs - even if they are in Javascript, Java, tags of unknown types, or anywhere else the program can find things.

      NN  name conversion type (0 *original structure, 1+: see below) 

    Use the original directory and file structure of the web site in your mirror image of the site.

      LN  long names (L1 *long names / L0 8-3 conversion) 

    If filenames do not follow the old DOS conventions, store them with the same names used on the web site.

      K   keep original links (e.g. http://www.adr/link) (K0 *relative link) 

    Use relative rather than the original links so that URLs within this web site are adjusted to point to the files in the mirror.

      o *generate output html file in case of error (404..) (o0 don't generate) 

    IF there are errors in downloading, create a file that indicates that the URL was not found. This makes browsing go a lot smoother.

      X *purge old files after update (X0 keep delete) 

    Files not found on the web site that were previously there get deleted so that you have an accurate snapshot of the site as it is today - losing historical data.

      bN  accept cookies in cookies.txt (0=do not accept,* 1=accept) 

    Accept all cokkies sent to you and return them if requested. This is required for many sites to function. These cookies are only kept relative to the specific site, so you don't have to worry about your browser retaining them.

      u check document type if unknown (cgi,asp..) (u0 don't check, * u1 check but /, u2 check always) 

    This causes different document types to be analyzed differently.

      j *parse Java Classes (j0 don't parse) 

    This causes Java class files to be parsed looking for URLs.

      sN  follow robots.txt and meta robots tags (0=never,1=sometimes,* 2=always) 

    This tells the program to follow the wishes of the site owner with respect to limiting where robots like this one search.

      C  create/use a cache for updates and retries (C0 no cache,C1 cache is prioritary,* C2 test update before) 

    If you are downloading a site you have a previous copy of, supplemental parameters are transmitted to the server, for example the 'If-Modified-Since:' field will be used to see if files are newer than the last copy you have. If they are newer, they will be downloaded, otherwise, they will not.

      f *log file mode 

    This retains a detailed log of any important events that took place.

      I *make an index (I0 don't make) 

    This makes a top-level index.html file so that if you image a set of sites, you can have one place to start reviewing the set of sites.

      pN priority mode: (* p3)  *3 save all files 

    This will cause all downloaded files to be saved.

      D  *can only go down into subdirs 

    This prevents the program from going to higher level directories than the initial subdirectory, but allows lower-level subdirectories of the starting directory to be investigated.

      a  *stay on the same address 

    This indicates that only the web site(s) where the search started are to be collected. Other sites they point to are not to be imaged.

      --mirror       *make a mirror of site(s) (default) 

    This indicates that the program should try to make a copy of the site as well as it can.

Now that's a lot of options for the default - but of course there are a lot more options to go. For the most part, the rest of the options represent variations on these themes. For example, instead of saving all files, we might only want to save html files, or instead of 8 simultaneous sessions, we might want only 4.

If we wanted to make one of these changes, we would specify the option on the command line. For example:


httrack www.all.net/bob/ -c4 -B

This would restrict httrack to only use 4 siumultaneous sessions but allow it to go up the directory structure (for example to www.all.net/joe/) as well as down it (for example to www.all.net/bob/deeper/).

You can add a lot of options to a command line!


A Thorough Going Over

Now that you have an introduction, it's time for a more though coverage. This is where I go through each of the options and describe it in detail with examples... Actually, I won't quite do that. But I will get close.

Options tend to come in groups. Each group tends to be interrelated, so it's easier and more useful to go through them a group at a time with some baseline project in mind. In my case, the project is to collect all of the information on the Internet about some given subject. We will assume that, through a previous process, I have gotten a list of URLs of interest to me. Typically there will be hundreds of these URLs, and they will be a mixed bag of sites that are full of desired information, pages with lists of pointers to other sites, URLs of portions of a web site that are of interest (like Bob's home pages and subdirectories), and so forth. Let us say that for today we are looking for the definitive colleciton of Internet information on shoe sizes from around the world.


General Options


General options:
  O  path for mirror/logfiles+cache (-O path_mirror[,path_cache_and_logfiles])

For this project, I will want to keep all of the information I gather in one place, so I will specify that output area of the project as /tmp/shoesizes by adding '-O /tmp/shoesizes' to every command line I use.. for example:


httrack http://www.shoesizes.com -O /tmp/shoesizes

The action options tell httrack how to operate at the larger level.


Action Options


Action options:
  w *mirror web sites
  W  mirror web sites, semi-automatic (asks questions)
  g  just get files (saved in the current directory)
  i  continue an interrupted mirror using the cache
  Y   mirror ALL links located in the first level pages (mirror links)

If I want httrack to ask me questions - such as what options to use, what sites to mirror, etc. I can tell it to ask these questions as follows:


httrack http://www.shoesizes.com -O /tmp/shoesizes -W


I can also do:

httrack
OR
httrack -W
OR
httrack -w

The '-W' options asks whether the or not a site has to be mirrored, while the '-w' option does not ask this question but asks the remainder of the questions required to mirror the site.

The -g option allows you to get the files exactly as they are and store them in the current directory. This is handy for a relatively small collection of information where organization isn't important. With this option, the html files will not even be parsed to look for other URLs. This option is useful for getting isolated files (e.g., httrack -g www.mydrivers.com/drivers/windrv32.exe).

If I start a collection process and it fails for one reason or another - such as me interrupting it because I am running out of disk space - or a network outage - then I can restart the process by using the -i option:

httrack http://www.shoesizes.com -O /tmp/shoesizes -i 

Finally, I can mirror all links in the first level pages of the URLs I specify. A good example of where to use whis would be in a case where I have a page that points to a lot of other sites and I want to get the initial information on those sites before mirroring them:

httrack http://www.shoesizes.com/othersites.html -O /tmp/shoesizes -Y 

Proxy Options

Many users use a proxy for many of their functions. This is a key component in many firewalls, but it is also commonly used for anonymizing access and for exploiting higher speed communications at a remote server.

Proxy options:
  P  proxy use (-P proxy:port or -P user:pass@proxy:port)
 %f *use proxy for ftp (f0 don't use)

If you are using a standard proxy that doesn't require a user ID and password, you would do something like this:

httrack http://www.shoesizes.com -O /tmp/shoesizes -P proxy.www.all.net:8080 

In this case, we have asusmed that proxy.www.all.net is the host that does the proxy service and that it uses port 8080 for this service. In some cases you will have to ask your network or firewall administrator for these details, however, in most cases they should be the same as the options used in your web browser.

In some cases, a user ID and password are required for the proxy server. This is common in corporate environments where only authorized users may access the Internet.

httrack http://www.shoesizes.com -O /tmp/shoesizes -P fc:password@proxy.www.all.net:8080 

In this case, the user ID 'fc' and the password 'password' are used on proxy.www.all.net port 8080. Again, your network or firewall administrator can be most helpful in addressing the specifics for your environment.

FTP normally operates through a proxy server, but for systems that have direct connections to the Internet, the following option should help:

httrack ftp://ftp.shoesizes.com -O /tmp/shoesizes -%f0 

Limits Options


Limits options:
  rN set the mirror depth to N
  mN maximum file length for a non-html file
  mN,N'                  for non html (N) and html (N')
  MN maximum overall size that can be uploaded/scanned
  EN maximum mirror time in seconds (60=1 minute, 3600=1 hour)
  AN maximum transfer rate in bytes/seconds (1000=1kb/s max)
  GN pause transfer if N bytes reached, and wait until lock file is deleted
  %eN set the external links depth to N (* %e0) (--ext-depth[=N])
  %cN maximum number of connections/seconds (*%c10)

Setting limits provides the means by which you can avoid running out of disk space, CPU time, and so forth. This may be particularly helpful for those who accidentally try to image the whole Internet.


httrack http://www.shoesizes.com -O /tmp/shoesizes -r50

In this example, we limit the directlry depth to 50 levels deep. As a general rule, web sites don't go much deeper than 20 levels or so, and if you think about it, if there are only 2 subdirectories per directory level, a directory structure 50 deep would have about 10 trillion directories. Of course many sites have a small number of files many levels deep in a directory structure for various reasons. In some cases, a symbolic link will cause an infinite recursion of directory levels as well, so placing a limit may be advisable.


httrack http://www.shoesizes.com -O /tmp/shoesizes -m50000000

This example sets the maximum file length for non-HTML files to 50 megabytes. This is not an unusual length for things like tar files, and in some cases - for example when there are images of CD-ROMs to fetch from sites, you might want a limit more like 750 megabytes.


httrack http://www.shoesizes.com -O /tmp/shoesizes -m50000000,100000

In this example, we have set a limit for html files as well - at 100,000 bytes. HTML files are rarely larger than this, however, in some cases larger sizes may be needed.


httrack http://www.shoesizes.com -O /tmp/shoesizes -M1000000000

This option sets the maximum total size - in bytes - that can be uploaded from a site - in this case to 1 gigabyte. Depending on how much disk space you have, such an option may be worthwhile.


httrack http://www.shoesizes.com -O /tmp/shoesizes -E3600

This sets the maximum runtime for the download process. Of course depending on the speed of your connection it may take longer or shorter runtimes to get the same job done, and network traffic is also a factor. 3600 seconds corresponds to one hour.


httrack http://www.shoesizes.com -O /tmp/shoesizes A100000000

This option specifies the largest number of bytes per second that should be used for transfers. For example, you might want to go slow for some servers that are heavily loaded in the middle of the day, or to download slowly so that the servers at the other end are less likely to identify you as mirroring their site. The setting above limits my bandwidth to 100 million bytes per second - slow I know, but I wouldn't want to stress the rest of the Internet.


httrack http://www.shoesizes.com -O /tmp/shoesizes -G100000000

In this case, the G option is used to 'pause' a download after the first gigabyte is downloaded pending manual removal of the lockfile. This is handy of you want to download some portion of the data, move it to secondary storage, and then continue - or if you want to only download overnight and want to stop before daylight and continue the next evening. You could even combine this option with a cron job to remove the lock file so that the job automatically restarts at 7PM every night and gets another gigabyte.


httrack http://www.shoesizes.com -O /tmp/shoesizes %e5

In this case, httrack will only go to depth 5 for external links, thus not imaging the entire web, but only yhose links within 5 links of these web pages.

Also note that the interaction of these options may cause unintended consequences. For example, limiting bandwidth and download time conspire to limit the total amount of data that can be downloaded.


Flow Control Options


Flow control:
  cN number of multiple connections (*c8)
  %cN maximum number of connections/seconds (*%c10)
  TN timeout, number of seconds after a non-responding link is shutdown
  RN number of retries, in case of timeout or non-fatal errors (*R1)
  JN traffic jam control, minimum transfert rate (bytes/seconds) tolerated for a link
  HN host is abandoned if: 0=never, 1=timeout, 2=slow, 3=timeout or slow


This example allows up to 128 simultaneous downloads. Note that this is likely to crash remote web servers - or at least fail to download many of the files - because of limits on the number of simultaneous sessions at many sites. At busy times of day, you might want to lower this to 1 or 2, especially at sites that limit the number of simultaneous users. Otherwise you will not get all of the downloads.


httrack http://www.shoesizes.com -O /tmp/shoesizes -c128

Many operating systems have a limit of 64 file handles, including internet connections and all other files that can be opened. Therefore, in many cases, more that 48 connections might cause a "socket error" because the OS can not handle that many sockets. This is also true for many servers. As an example, a test with 48 sockets on a cgi-based web server (Pentium 166,80Meg RAM) overloaded the machine and stopped other services from running correctly. Some servers will ban users that try to brutally download the website. 8 sockets is generally good, but when I'm getting large files (e.g., from a a site with large graphical images) 1 or 2 sockets is a better selection. Here are some other figures from one sample set of runs:

    Tests: on a 10/100Mbps network, 30MB website, 99 files (70 images (some are
    little, other are big (few MB)), 23 HTML)
    With 8 sockets: 1,24MB/s
    With 48 sockets: 1,30MB/s
    With 128 sockets: 0,93MB/s
    

This limits the number of connections per second. It is similar to the above option but allows the pace to be controlled rather than the simultanaety. It is particulsrly useful for long-term pulls at low rates that allow little impact on remote infrastructure. The default is 10 connections per second.


httrack http://www.shoesizes.com -O /tmp/shoesizes -%c20

The timeout option causes downloads to time out after a non-response from a download attempt. 30 seconds is pretty reasonable for many sites. You might want to increase the number of retries as well so that you try again and again after such timeouts.


httrack http://www.shoesizes.com -O /tmp/shoesizes -T30

This example increases the number of retries to 5. This means that if a download fails 5 times, httrack will give up on it. For relatively unreliable sites - or for busy times of day, this number should be higher.


httrack http://www.shoesizes.com -O /tmp/shoesizes -R5

This is an interesting option. It says that in a traffic jam - where downloads are excessively slow - we might decide to back off the download. In this case, we have limited downloads to stop bothering once we reach 10 bytes per second.


httrack http://www.shoesizes.com -O /tmp/shoesizes -J10

These three options will cause the download from a host to be abandoned if (respectively) (0) never, (1) a timeout is reached, (2) slow traffic is detected, (or) (3) a timeout is reached OR slow traffic is detected.


httrack http://www.shoesizes.com -O /tmp/shoesizes -H0
httrack http://www.shoesizes.com -O /tmp/shoesizes -H1
httrack http://www.shoesizes.com -O /tmp/shoesizes -H2
httrack http://www.shoesizes.com -O /tmp/shoesizes -H3

Of course these options can be combined to provide a powerful set of criteria for when to continue a download and when to give it up, how hard to push other sites, and how much to stress infrastructures.


Link Following Options


Links options:
 %P *extended parsing, attempt to parse all links, even in unknown tags or Javascript (%P0 don't use)
  n   get non-html files 'near' an html file (ex: an image located outside)
  t   test all URLs (even forbidden ones)
 %L  add all URL located in this text file (one URL per line)

The links options allow you to control what links are followed and what links are not as well as to provide long lists of links to investigate. Any setting other than the default for this option forces the engine to use less reliable and more complex parsing. 'Dirty' parsing means that links like 'xsgfd syaze="foo.gif"' will cause HTTrack to download foo.gif, even if HTTrack don't know what the "xsgfd syaze=" tag actually means! This option is powerful because some links might otherwise be missed, but it can cause errors in HTML or javascript.

This will direct the program to NOT search Javascript for unknown tag fields (e.g., it will find things like foo.location="bar.html"; but will not find things like bar="foo.gif";). While I have never had a reason to use this, some users may decide that they want to be more conservative in their searches. As a note, javascript imported files (.js) are not currently searched for URLs.


httrack http://www.shoesizes.com -O /tmp/shoesizes '%P0'

Now here is a classic bit of cleverness that 'does the right thing' for some cases. In this instance, we are asking httrack to get images - like gif and jpeg files that are used by a web page in its display, even though we would not normally get them. For example, if we were only getting a portion of a web site (e.g., everything under the 'bob directory') we might want to get graphics from the rest of the web sote - or the rest of the web - that are used in those pages as well so that our mirror will look right.


httrack http://www.shoesizes.com -O /tmp/shoesizes -n

Here, we limit the collection to bob's area of the server - except that we get images and other such things that are used by bob in his area of the server.


httrack http://www.shoesizes.com/bob/ -O /tmp/shoesizes -n

This option 'tests' all links - even those forbidden (by the robot exclusion protocol) - by using the 'HEAD' protocol to test for the presence of a file.


httrack http://www.shoesizes.com/ -O /tmp/shoesizes -t

In this case, we use a file to list the URLs we wish to mirror. This is particularly useful when we have a lot to do and don't want to tirelessly type in URLs on command line after command line. It's also useful - for example - if you update a set of mirrored sites evey evening. You can set up a command like this to run automatically from your cron file.


httrack -%L linkfile -O /tmp/shoesizes

This will update the mirror of your list of sites whenever it is run.


httrack -%L linkfile -O /tmp/shoesizes -B --update

The link file is also useful for things like this example where, after a binary image of a hard disk was analyzed (image) URLs found on that disk were collected by httrack:


strings image | grep "http://" > list;
httrack -%L list -O /tmp/shoesizes

Mirror Build Options


Build options:
  NN  name conversion type (0 *original structure, 1+: see below)
  N   user defined structure (-N "%h%p/%n%q.%t")
  LN  long names (L1 *long names / L0 8-3 conversion)
  K   keep original links (e.g. http://www.adr/link) (K0 *relative link)
  x   replace external html links by error pages
  o *generate output html file in case of error (404..) (o0 don't generate)
  X *purge old files after update (X0 keep delete)
  %x  do not include any password for external password protected websites (%x0 include) (--no-passwords)
  %q *include query string for local files (information only) (%q0 don't include) (--include-query-string)

The user can define naming conventions for building the mirror of a site by using these options. For example, to retain the original structure, the default is used. This only modifies the structure to the extent that select characters (e.g., ~, :, <, >, \, and @) are replaced by _ in all pathnames.


httrack http://www.shoesizes.com -O /tmp/shoesizes -N0

OR


httrack http://www.shoesizes.com -O /tmp/shoesizes

In either case, the mirror will build with the same directory hierarchy and name structure as the original site. For cases when you want to define your own structure, you use a string like this:


httrack http://www.shoesizes.com/bob/ -O /tmp/shoesizes -N "%h%p/%n.%t"

In this case, %h, %p, $n, and %t stand for the href element (e.g., http://www.shoesizes.com or ftp://ftp.shoesizes.com), %p stands for the pathname (e.g., /bob/), %n stands for the name of the file, and %t stands for type (file extension). The full list of these options follows:

    %n      Name of file without file type (ex: image)
    %N      Name of file, including file type (ex: image.gif)
    %t      File type (ex: gif)
    %p      Path [without ending /] (ex: /someimages)
    %h      Host name (ex: www.all.net)
    %M      URL MD5 (128 bits, 32 ascii bytes)
    %Q      query string MD5 (128 bits, 32 ascii bytes)
    %q      small query string MD5 (16 bits, 4 ascii bytes)
    %s?     Short name version (ex: %sN)
    

Other 'N' options include:

    
    Details: Option N
      N0 Site-structure (default)
      N1 HTML in web/, images/other files in web/images/
      N2 HTML in web/HTML, images/other in web/images
      N3 HTML in web/,  images/other in web/
      N4 HTML in web/, images/other in web/xxx, where xxx is the file extension
    (all gif will be placed onto web/gif, for example) N5 Images/other in web/xxx and HTML in web/HTML N99 All files in web/, with random names (gadget !) N100 Site-structure, without www.domain.xxx/ N101 Identical to N1 except that "web" is replaced by the site's name N102 Identical to N2 except that "web" is replaced by the site's name N103 Identical to N3 except that "web" is replaced by the site's name N104 Identical to N4 except that "web" is replaced by the site's name N105 Identical to N5 except that "web" is replaced by the site's name N199 Identical to N99 except that "web" is replaced by the site's name N1001 Identical to N1 except that there is no "web" directory N1002 Identical to N2 except that there is no "web" directory N1003 Identical to N3 except that there is no "web" directory (option set for g option) N1004 Identical to N4 except that there is no "web" directory N1005 Identical to N5 except that there is no "web" directory N1099 Identical to N99 except that there is no "web" directory

Long names are normally used (the -L0 option) but if you are imaging to a DOS file system or want accessibility from older versions of DOS and Windows, you can use the -L1 option to generate these filename sizes.


httrack http://www.shoesizes.com -O /tmp/shoesizes -L1

With the 'K' option, you can keep the original links in files. While this is less useful in being able to view a web site froim the mirrored copy, it is vitally important if you want an accurate copy of exactly what was on the web site in the first place. In a forensic image, for example, you might want to use this option to prevent the program from modifying the data as it is collected.


httrack http://www.shoesizes.com -O /tmp/shoesizes -K

In this case, instead of leaving external links (URLs that point to sites not being mirrored) in the pages, these links are replaced by pages that leave messages indicating that they could not be found. This is useful for local mirrors not on the Internet or mirrors that are on the Internet but that are not supposed to lead users to external sites. A really good use for this is that 'bugging' devices placed in web pages to track who is using them and from where will be deactivated byt his process.


httrack http://www.shoesizes.com -O /tmp/shoesizes -x

This option prevents the generation of '404' error files to replace files that were not found even though there were URLs pointing to them. It is useful for saving space as well as eliminating unnecessary files in operations where a working web site is not the desired result.


httrack http://www.shoesizes.com -O /tmp/shoesizes -o0

This option prevents the authoatic purging of files from the mirror site that were not found in the original web site after an 'update' is done. If you want to retain old data and old names for files that were renamed, this option should be used. If you want an up-to-date reflection of the current web site, you should not use this option.


httrack http://www.shoesizes.com -O /tmp/shoesizes -X0

These options can be combined as desired to produce a wide range of different arrangements, from collections of only graphical files stored in a graphics area, to files identified by their MD5 checksums only, all stored in the same directory.


httrack http://www.shoesizes.com -O /tmp/shoesizes %x0 include

This will not include passwords for web sites. If you mirror http://smith_john:foobar@www.privatefoo.com/smith/, and exclude using filters some links, these links will be by default rewritten with password data. For example, "bar.html" will be renamed into http://smith_john:foobar@www.privatefoo.com/smith/bar.html This can be a problem if you don't want to disclose the username/password! The %x option tell the engine not to include username/password data in rewritten URLs.


httrack http://www.shoesizes.com -O /tmp/shoesizes %q

This option is not very useful, because parameters are useless, as pages are not dynamic anymore when mirrored. But some javascript code may use the query string, and it can give useful information. For example: catalog4FB8.html?page=computer-science is clearer than catalog4FB8.html Therefore, this option is activated by default.


Spider Options

These options provide for automation with regard to the remote server. For example, some sites require that cookies be accepted and sent back in order to allow access.


Spider options:
 bN  accept cookies in cookies.txt (0=do not accept,* 1=accept)
 u   check document type if unknown (cgi,asp..) (u0 don't check, * u1 check but /, u2 check always)
 j   *parse Java Classes (j0 don't parse)
 sN  follow robots.txt and meta robots tags (0=never,1=sometimes,* 2=always)
 %h  force HTTP/1.0 requests (reduce update features, only for old servers or proxies)
 %B  tolerant requests (accept bogus responses on some servers, but not standard!)
 %s  update hacks: various hacks to limit re-transfers when updating
 %A  assume that a type (cgi,asp..) is always linked with a mime type (-%A php3=text/html) (--assume )

By default, cookies are universally accepted and returned. This makes for more effective collection of data, but allows the site to be identified with its collection of data more easily. To disable cookies, use this option:


httrack http://www.shoesizes.com -O /tmp/shoesizes -b0

Some documents have known extension types (e.g., html), while others have unknown types (e.g., iuh87Zs) and others may have misleading types (e.g., an html file with a 'gif' file extension. These options provide for (0) not checking file types, (1) checking all file types except directories, and (2) checking all file types including directories. Choose from these options:


httrack http://www.shoesizes.com -O /tmp/shoesizes -u0
httrack http://www.shoesizes.com -O /tmp/shoesizes -u1
httrack http://www.shoesizes.com -O /tmp/shoesizes -u2

Meta tags or 'robots.txt' files on a web site are used to indicate what files should and should not be visited by automatic programs when collectiong data. The polite and prudent move for normal data collection (and the default) is to follow this indication:


httrack http://www.shoesizes.com -O /tmp/shoesizes -s2

This follows the robots protocol and meta-tags EXCEPT in cases where the filters disagree with the robots protocols or meta-tags.


httrack http://www.shoesizes.com -O /tmp/shoesizes -s1

In this next case, we ignore meta-tags and robots.txt files completely and just take whatever we can get from the site. The danger of this includes the fact that automated programs - like games or search engines may generate an unlimited number of nearly identical or identical outputs that will put us in an infinite loop collecting useless data under different names. The benefit is that we will get all the data there is to get.


httrack http://www.shoesizes.com -O /tmp/shoesizes -s0

This next option uses strict HTTP/1.0 protocol. This means the program will use HTTP/1.0 headers (as in RFC1945.TXT) and NOT extended 1.1 features described in RFC2616.TXT. For example, reget (complete a partially downloaded file) is a HTTP/1.1 feature. The Etag feature is also a HTTP/1.1 feature (Etag is a special identifier that allow to easily detect file changes).


httrack http://www.shoesizes.com -O /tmp/shoesizes -%h

Some servers give responses not strictly within the requirements of the official http protocol. These 'Bogus' responses can be accepted by using this option. For example, when requesting foo.gif (5132 bytes), the server can, optionally, add:

Content-length: 5132

This helps the client by allowing it to reserve a block of memory, instead of collecting each byte and re-reserving memory each time data is being received. But some servers are bogus, and send a wrong filesize. When HTtrack detects the end of file (connection broken), there are three cases:

    1- The connection has been closed by the server, and we have received all data (we have received the number of bytes incicated by the server). This is fine because we have successfully received the file.

    2- The connection has been closed by the server, BUT the filesize received is different from the server's headers: the connection has been suddenly closed, due to network problems, so we reget the file

    3- The connetion has been closed by the server, the filesize received is different from the server's headers, BUT the file is complete, because the server gave us a WRONG information! In this case, we use the bogus server option:


httrack http://www.shoesizes.com -O /tmp/shoesizes -%B

These options can be combined for the particular needs of the situaiton and are often adapted as a result of site-specific experiences.


httrack http://www.shoesizes.com -O /tmp/shoesizes -%s

This is a collection of "tricks" which are not really "RFC compliant" but which can save bandwidth by trying not to retransfer data in several cases.


httrack http://www.shoesizes.com -O /tmp/shoesizes -%A asp=text/html

The most important new feature for some people, maybe. This option tells the engine that if a link is en countered, with a specific type (.cgi, .asp, or .php3 for example), it MUST assume that this link has always the same MIME type, for example the "text/html" MIME type. This is VERY important to speed up many mirrors.

We have done tests on big HTML files (approx. 150 MB, 150,000,000 bytes!) with 100,000 links inside. Such files are being parsed in approx. 20 seconds on my own PC by the latest optimized releases of HTTra ck. But these tests have been done with links of known types, that is, html, gif, and so on.. If you have, say, 10,000 links of unknown type, such as ".asp", this will cause the engine to test ALL t hese files, and this will SLOOOOW down the parser. In this example, the parser will take hours, instead of 20 seconds! In this case, it would be great to tell HTTrack: ".asp pages are in fact HTML pages" This is possible, using: -%A asp=text/html

The -%A option can be replaced by the alias --assume asp=text/html which is MUCH more clear. You can use multiple definitions, separated by ",", or use multiple options. Therefore, these two lines are identical:

--assume asp=text/html --assume php3=text/html --assume cgi=image/gif
--assume asp=text/html,php3=text/html,cgi=image/gif

The MIME type is the standard well known "MIME" type. Here are the most important ones:

text/html       Html files, parsed by HTTrack
image/gif       GIF files
image/jpeg      Jpeg files
image/png       PNG files

There is also a collection of "non standard" MIME types. Example:

application/x-foo       Files with "foo" type

Therefore, you can give to all files terminated by ".mp3" the MIME type: application/x-mp3

This allow you to rename files on a mirror. If you KNOW that all "dat" files are in fact "zip" files ren amed into "dat", you can tell httrack:

--assume dat=application/x-zip

You can also "name" a file type, with its original MIME type, if this type is not known by HTTrack. This will avoid a test when the link will be reached:

--assume foo=application/foobar

In this case, HTTrack won't check the type, because it has learned that "foo" is a known type, or MIME type "application/foobar". Therefore, it will let untouched the "foo" type.

A last remark, you can use complex definitions like:

--assume asp=text/html,php3=text/html,cgi=image/gif,dat=application/x-zip,mpg=application/x-mp3,application/foobar

..and save it on your .httrackrc file:

set assume asp=text/html,php3=text/html,cgi=image/gif,dat=application/x-zip,mpg=application/x-mp3,application/foobar

Browser Options

Browsers commonly leave footprints in web servers - as web servers leave footprints in the browser.


Browser ID:
  F  user-agent field (-F "user-agent name")
 %F  footer string in Html code (-%F "Mirrored [from host %s [file %s [at %s]]]"
 %l  preffered language (-%l "fr, en, jp, *" (--language )

The user-agent field is used by browsers to determine what kind of browser you are using as well as other information - such as your system type and operating system version. The 'User Agent' field can be set to indicate whatever is desired to the server. In this case, we are claiming to be a netscape browser (version 1.0) running a non-exitent Solaris operating system version on a Sun Sparcstation.


httrack http://www.shoesizes.com -O /tmp/shoesizes -F "Mozilla 1.0, Sparc, Solaris 23.54.34"

On the other side, we may wish to mark each page collected with footer information so that we can see from the page where it was collected from, when, and under what name it was stored.


httrack http://www.shoesizes.com -O /tmp/shoesizes -%F "Mirrored [from host %s [file %s [at %s]]]"

This makes a modified copy of the file that may be useful in future identification. While it is not 'pure' in some senses, it may (or may not) be considered siilar to a camera that adds time and date stamps from a legal perspective.


httrack http://www.shoesizes.com -O /tmp/shoesizes -%l "fr, en, jp, *"

"I prefer to have pages with french language, then english, then japanese, then any other language"


Log, Cache, and Index Options

A lot of options are available for log files, indexing of sites, and cached results:


Log, index, cache
  C  create/use a cache for updates and retries (C0 no cache,C1 cache is prioritary,* C2 test update before)
  k  store all files in cache (not useful if files on disk)
 %n  do not re-download locally erased files
  Q  log quiet mode (no log)
  q  quiet mode (no questions)
  z  extra infos log
  Z  debug log
  v  verbose screen mode
  %v display on screen filenames downloaded (in realtime) (--display)
  f  log file mode
  f2 one single log file (--single-log)
  I  *make an index (I0 don't make)
  %I make an searchable index for this mirror (* %I0 don't make) (--search-index)

A cache memory area is used for updates and retries to make the process far more efficient than it would otherwise be. You can choose to (0) go without a cache, (1) do not check remotly if the file has been updated or not, just load the cache content, or (2) see what works best and use it (the default). Here is the no cache example.


httrack http://www.shoesizes.com -O /tmp/shoesizes -C0

The cache can be used to store all files - if desired - but if files are being stored on disk anyway (the normal process for a mirroring operation), this is not helpful.


httrack http://www.shoesizes.com -O /tmp/shoesizes -k

In some cases, a file from a mirror site is erased locally. For example, if a file contains inappropriate content, it may be erased from the mirror site but remain on the remote site. This option allows you to leave deleted files permanently deleted when you do a site update.


httrack http://www.shoesizes.com -O /tmp/shoesizes -update '%n'

If no log is desired, the following option should be added.


httrack http://www.shoesizes.com -O /tmp/shoesizes -Q

If no questions should be asked of the user (in a mode that would otherwise ask questions), the following option should be added.


httrack http://www.shoesizes.com -O /tmp/shoesizes -q

By adding these options, you get (-z) extra log information or (-Z) debugging information, and (-v) verbose screen output.


httrack http://www.shoesizes.com -O /tmp/shoesizes -z -Z -v

Multiple log files can be created, but by default, this option is used to put all logs into a single log file.


httrack http://www.shoesizes.com -O /tmp/shoesizes -f2

Finally, an index is normally made of the sites mirrored (a pointer to the first page found from each specified URL) in an index.html file in the project directory. This can be prevented through the use of this option:


httrack http://www.shoesizes.com -O /tmp/shoesizes -I0

httrack http://www.shoesizes.com -O /tmp/shoesizes %v

Animated information when using console-based version, example:

17/95: localhost/manual/handler.html (6387 bytes) - OK

httrack http://www.shoesizes.com -O /tmp/shoesizes f2

Do not split error and information log (hts-log.txt and hts-err.txt) - use only one file (hts-log.txt)


httrack http://www.shoesizes.com -O /tmp/shoesizes -%I linux.localdomain

Still in testing, this option asks the engine to generate an index.txt, useable by third-party programs or scripts, to index all words contained in html files. The above example will produce index.txt:

..
abridged
        1 linux/manual/misc/API.html
        =1
        (0)
absence
        3 linux/manual/mod/core.html
        2 linux/manual/mod/mod_imap.html
        1 linux/manual/misc/nopgp.html
        1 linux/manual/mod/mod_proxy.html
        1 linux/manual/new_features_1_3.html
        =8
        (0)
absolute
        3 linux/manual/mod/mod_auth_digest.html
        1 linux/manual/mod/mod_so.html
        =4
        (0)
..

Expert User Options

For expert users, the following options provide further options.


Expert options:
  pN priority mode: (* p3)
      0 just scan, don't save anything (for checking links)
      1 save only html files
      2 save only non html files
     *3 save all files
      7 get html files before, then treat other files
  S   stay on the same directory
  D  *can only go down into subdirs
  U   can only go to upper directories
  B   can both go up&down into the directory structure
  a  *stay on the same address
  d   stay on the same principal domain
  l   stay on the same location (.com, etc.)
  e   go everywhere on the web
 %H  debug HTTP headers in logfile

One interesting application allows the mirror utility to check for valid and invalid links on a site. This is commonly used in site tests to look for missing pages or other html errors. I often run such programs against my web sites to verify that nothing is missing.


httrack http://www.shoesizes.com -O /tmp/shoesizes -p0

To check for valid links outside of a site, the '-t' option can be used:


httrack http://www.shoesizes.com -O /tmp/shoesizes -t

These options can be combined, for example, to provide a service that checks sites for validity of links and reports back a list of missing files and statistics.

Other options allow the retention of select files - for example - (1) only html files, (2) only non-html files, (3) all files, and (7) get all html files first, then get other files. This last option provides a fast way to get the web pointers so that, for example, a time limited collection process will tend to get the most important content first.

In many cases, we only want the files froma given directory. In this case, we specify this option:


httrack http://www.shoesizes.com/bob/ -O /tmp/shoesizes -S

This option allows the mirror to go only into subdirectories of the initial directory on the remote host. You might want to combine it with the -n option to get all non-html files linked from the pages you find.


httrack http://www.shoesizes.com/bob/ -O /tmp/shoesizes -D -n

If you only want to work your way up the directory structure from the specified URL (don't ask me why you might want to do this), the following command line is for you:


httrack http://www.shoesizes.com/bob/ -O /tmp/shoesizes -U

If you want to go both up and down the directory structure (i.e., anywhere on on this site that the requested page leads you to), this option will be best:


httrack http://www.shoesizes.com/bob/ -O /tmp/shoesizes -B

The default is to remain on the same IP address - or host name. This option specifes this explicitly:


httrack http://www.shoesizes.com/bob/ -O /tmp/shoesizes -a

If you want to restrict yourself only to the same principal domain (e.g., include sites liks ftp.shoesizes.com), you would use this option.


httrack http://www.shoesizes.com/bob/ -O /tmp/shoesizes -d

To restrict yourself to the same major portion of the Internet (e.g., .com, .net, .edu, etc.) try this option:


httrack http://www.shoesizes.com/bob/ -O /tmp/shoesizes -l

Finally, if you want to mirror the whole Internet - at least every place on the internet that is ever led to - either directly or indirectly - from the starting point, use this one... Please note that this will almost always run you out of resources unless you use other options - like limiting the depth of search.


httrack http://www.shoesizes.com/bob/ -O /tmp/shoesizes -e

Last but not least, you can include debugging informaiton on all headers from a collection process by using this option:


httrack http://www.shoesizes.com/bob/ -O /tmp/shoesizes -'%H'

The options S, D, U, B, a, d, l, and e can be replaces with filter options approximately as follows:


S     -www.foo.com/* +www.foo.com/bar/*[file]
D     (default)
U     +www.foo.com/bar/* -www.foo.com/*[name]/*
B     +www.foo.com/bar/*
a     (default)
d     +*[name].foo.com/*
l     +*[name].com/*
e     +* (this is crazy unless a depth limit is used!)

Guru Options - DO NOT USE!!!

This is a new section, for all "not very well documented options". You can use them, in fact, do not believe what is written above!

 #0  Filter test (-#0 '*.gif' 'www.bar.com/foo.gif')

To test the filter system. Example:

$ httrack -#0 'www.*.com/*foo*bar.gif' 'www.mysite.com/test/foo4bar.gif'
www.mysite.com/test/foo4bar.gif does match www.*.com/*foo*bar.gif
 #f  Always flush log files

Useful if you want the hts-log.txt file to be flushed regularly (not buffered)

 #FN Maximum number of filters

Use if if you want to use more than the maximum default number of filters, that is, 500 filters: -#F2000 for 2,000 filters

 #h  Version info

Informations on the version number

 #K  Scan stdin (debug)

Not useful (debug only)

 #L  Maximum number of links (-#L1000000)

Use if if you want to use more than the maximum default number of links, that is, 100,000 links: -#L2000000 for 2,000,000 links

 #p  Display ugly progress information

Self-explanatory :) I will have to improve this one

 #P  Catch URL

"Catch URL" feature, allows to setup a temporary proxy to capture complex URLs, often linked with POST action (when using form based authentication)

 #R  Old FTP routines (debug)

Debug..

 #T  Generate transfer ops. log every minutes

Generate a log file with transfer statistics

 #u  Wait time

"On hold" option, in seconds

 #Z  Generate transfer rate statistics every minutes

Generate a log file with transfer statistics

 #!  Execute a shell command (-#! "echo hello")

Debug..


Command-line Specific Options


Command-line specific options:
  V execute system command after each files ($0 is the filename: -V "rm \$0") (--userdef-cmd )

This option is very nice for a wide array of actions that might be based on file details. For example, a simple log of all files collected could be generated by using:


httrack http://www.shoesizes.com/bob/ -O /tmp/shoesizes -V "/bin/echo \$0"
 %U run the engine with another id when called as root (-%U smith) (--user )

Change the UID of the owner when running as r00t

  Details: User-defined option N
    %[param] param variable in query string

This new option is important: you can include query-string content when forming the destination filename!

Example: you are mirroring a huge website, with many pages named as:
www.foo.com/catalog.php3?page=engineering
www.foo.com/catalog.php3?page=biology
www.foo.com/catalog.php3?page=computing
..

Then you can use the -N option:

httrack www.foo.com -N "%h%p/%n%[page].%t"

If found, the "page" parameter will be included after the filename, and the URLs above will be saved as:

/home/mywebsites/foo/www.foo.com/catalogengineering.php3
/home/mywebsites/foo/www.foo.com/catalogbiology.php3
/home/mywebsites/foo/www.foo.com/catalogcomputing.php3
...

Shortcuts

These options provide shortcust to combinations of other options that are commonly used.


Shortcuts:
--mirror       *make a mirror of site(s) (default)
--get           get the files indicated, do not seek other URLs (-qg)
--list     add all URL located in this text file (-%L)
--mirrorlinks   mirror all links in 1st level pages (-Y)
--testlinks     test links in pages (-r1p0C0I0t)
--spider        spider site(s), to test links: reports Errors & Warnings (-p0C0I0t)
--testsite      identical to --spider
--skeleton      make a mirror, but gets only html files (-p1)
--update              update a mirror, without confirmation (-iC2)
--continue            continue a mirror, without confirmation (-iC1)
--catchurl            create a temporary proxy to capture an URL or a form post URL
--clean               erase cache & log files
--http10              force http/1.0 requests (-%h)

Mirror is the default behavior. It is detailed earlier.

get simply gets the files specified on the command line.

The list option is useful for including a list of sites to collect data from.

The mirrorlinks option is ideal for using the result of a previous search (like a list of pages found in a web search or somebody's URL collection) to guide the collection of data. With additional options (such as depth 1) it can be used to collect all of the pages linked to a given page without going further. Here is an example:


httrack http://www.shoesizes.com/bob/ -O /tmp/shoesizes --mirrorlinks -e -r1

Testing links in pages is useful for automating the verification that a link from a file is not pointing to a non-existent page.

The spider option does a site test automatically and returns errors for broken links.

The skeleton option makes a mirror of html files only.

The update option updates a site to match a remote mirror.

The continue option continues a previously terminated mirroring activity. This is useful for all sorts of mirror failures.

The catchurl option is a small application designed to catch difficult pages, like sites protected via formulas. You can see at http://httrack.free.fr/HelpHtml/addurl.html a Windows description of this application. The purpose is to create a temporary proxy, that will catch the user request to a page, and then store this request to continue the mirror. For example,

    1. browse www.foo.com/bar/ until you have a page with a form
    2. fill this form to enter the site BUT do not click "submit"
    3. start the --catchurl application
    4. change your browser proxy settings according to the --catchurl application
    5. click on "submit" on your browser
    6. HTTrack has now captured this click and has stored it
    7. restore your proxy settings
    8. (click back in your browser)
    

The clean option erases cache and log files.

The http10 option forces http/1.0 requests (the same as -%h).


Filters

Filters are normally placed at the end of the command line, but can be intermixed with other command line options if desired, except that if they are placed between (for example) the '-O' and the pathname, your results may be different than you might otherwise predict. There are two sorts of filters, filters that indicate what to include (+) and filters that indicate what to exclude (-).

Starting with the initially specified URLs, the default operation mode is to mirror starting from these URLs downward into the directory structure of the host (i.e. if one of your starting pages was www.all.net/test/a.html, all links starting with www.all.net/test/ will be collected but links in www.all.net/anything-else will not be collected, because they are in a higher directory strcuture level. This prevents HTTrack from mirroring the whole site. If you may want to download files are in other parts of the site or pf particular types - or to not download files in a particular part of the site or of a particular type, you can use filters to specify more precisely what to collect and what not to collect.

The syntax for filters is similar to Unix regular expressions. A simple filter can be made by using characters from the URL with '*' as a wildcard for 0 or more characters - with the last filter rule having the highest precendence. An initial '+' indicates URLs to include and an initial '-' indicated URLs to not include. For example:


'-*' '+*jpg'

would only get files ending in the 'jpg' extension, while:


'-*jpg'

would not get any files ending in the jpg extension. You can add more filter lines to restrict or expand the scope as desired. The last rule is checked first, and so on - so that the rules are in reverse priority order. Here's an example:
+*.gif -image*.gif Will accept all gif files BUT image1.gif,imageblue.gif,imagery.gif and so on
-image*.gif +*.gif Will accept all gif files, because the second pattern is prioritary (because it is defined AFTER the first one)

The full syntax for filters follows:
* any characters (the most commonly used)
*[file] or *[name] any filename or name, e.g. not /,? and ; characters
*[path] any path (and filename), e.g. not ? and ; characters
*[a,z,e,r,t,y] any letters among a,z,e,r,t,y
*[a-z] any letters
*[0-9,a,z,e,r,t,y] any characters among 0..9 and a,z,e,r,t,y
*[] no characters must be present after
*[< NN] size less than NN Kbytes
*[> PP] size more than PP Kbytes
*[< NN > PP] size less than NN Kbytes and more than PP Kbytes

Here are some examples of filters: (that can be generated automatically using the interface)
-www.all.net* This will refuse/accept this web site (all links located in it will be rejected)
+*.com/* This will accept all links that contains .com in them
-*cgi-bin* This will refuse all links that contains cgi-bin in them
+*.com/*[path].zip This will accept all zip files in .com addresses
-*someweb*/*.tar* This will refuse all tar (or tar.gz etc.) files in hosts containing someweb
+*/*somepage* This will accept all links containing somepage (but not in the address)
-*.html This will refuse all html files from anywhere in the world.
+*.html*[] Accept *.html, but the link must not have any supplemental characters at the end
(e.g., links with parameters, like www.all.net/index.html?page=10 will not match this filter)
-*.gif*[> 5] -*.zip +*.zip*[< 10] refuse all gif files smaller than 5KB, exlude all zip files, EXCEPT zip files smaller than 10KB


User Authentication Protocols

Smoe servers require user ID and password information in order to gain access. In this example, the user ID smith with password foobar is accessing www.all.net/private/index.html


httrack smith:foobar@www.all.net/private/index.html

For more advanced forms of authentication, such as those involving forms and cookies of various sorts, an emerging capability is being provided through th URL capture features (--catchurl). This feature don't work all of the time.


.httrackrc

A file called '.httrackrc' can be placed in the current directory, or if not found there, in the home directory, to include command line options. These options are included whenever httrack is run. A sample .httrack follows:

    
     set sockets 8
     set retries 4
     index on
     set useragent "Mozilla [en] (foo)"
     set proxy proxy:8080
    

But the syntax is not strict, you can use any of these:

    
     set sockets 8
     set sockets=8
     sockets=8
     sockets 8
    

.httrackrc is sought in the following sequence with the first occurence used:

  • in the dirctory indicated by -O option (.httrackrc)
  • in the current directory (.httrackrc)
  • in the user's home directory (.httrackrc)
  • in /etc/httrack.conf (named httrack.conf to be "standard")

An example .httrackrc looks like:

    
    set sockets=8
    set index on
    retries=2
    allow *.gif
    deny ad.doubleclick.net/*
    

Each line is composed of an option name and a parameter. The "set" token can be used, but is not mandatory (it is ignored, in fact). The "=" is also optionnal, and is replaced by a space internally. The "on" and "off" are the same as "1" and "0" respectively. Therefore, the example .httrackrc above is equivalent to:

    
    sockets=8
    index=1
    retries=2
    allow=*.gif
    deny=ad.doubleclick.net/*
    

Because the "=" seems to (wrongly) imply a variable assignment (the option can be defined more than once to define more than one filter) the following .httrackrc:

    
    allow *.gif
    allow *.jpg
    

looks better for a human than:

    
    allow=*.gif
    allow=*.jpg
    

Here's a example run with the example .httrackrc file:

    
    $ httrack ghost
    $ cat hts-cache/doit.log
    -c8 -C1 -R2 +*.gif -ad.doubleclick.net/* ghost
    

The "-c8 -C1 -R2 +*.gif -ad.doubleclick.net/*" was added by the .httrackrc


Release Notes

Some things change between releases. Here are some recent changes in httrack that may affect some of these options:

Options S,D,U,B, and a,d,l,e are default behaviours of HTTrack. they were the only options in old versions (1.0). With the introduction of filters, their roles are now limited, because filters can override them.

Note for the -N option: "%h%p/%n%q.%t" will be now be used if possible. In normal cases, when a file does not have any parameters (www.foo.com/bar.gif) the %q option does not add anything, so there are no differences in file names. But when parameters are present (for example, www.foo.com/bar.cgi?FileCollection=133.gif), the additionnal query string (in this case, FileCollection=133.gif) will be "hashed" and added to the filename. For example:

'www.all.net/bar.cgi?FileCollection=133.gif'

will be named

'/tmp/mysite/bar4F2E.gif'

The additionnal 4 letters/digits are VERY useful in cases where there are a substantial number of identical files:


www.all.net/bar.cgi?FileCollection=133.gif
www.all.net/bar.cgi?FileCollection=rose.gif
www.all.net/bar.cgi?FileCollection=plant4.gif
www.all.net/bar.cgi?FileCollection=silver.gif
and so on...

In these cases, there is a small probability of a hash collision for large numbers of files.


Some More Examples

Here are some examples of special purpose httrack command lines that might be useful for your situation.

This is a 'forensic' dump of a web site - intended to collect all URLs reachable from the initial point and at that particular site. It is intended to make no changes whatsoever to the image. It also prints out an MD5 checksum of each file imaged so that the image can be verified later to detect and changes after imaging. It uses 5 retries to be more certain than normal of getting the files, never abandons its efforts, keeps original links, does not generate error files, ignores site restrictions for robots, logs as much as it can, stays in the principal domain, places debugging headers in the log file,


httrack "www.website.com/" -O "/tmp/www.website.com" -R5H0Ko0s0zZd %H -V "md5 \$0" "+*.website.com/*" 

Here's an example of a site where I pulled a set of data related to some subject. In this case, I only wanted the relevant subdirectory, all external links were to remain the same, a verbose listing of URLs was to be printed, and I wanted files near (n) and below (D) the original directory. Five retries just makes sure I don't miss anything.


httrack "http://www.somesite.com/~library/thing/thingmain.htm" -O /tmp/thing -R5s0zZvDn

This listing is, of course, rather verbose. To reduce the noise, you might want to do something more like this:


httrack "http://www.somesite.com/~library/thing/thingmain.htm" -O /tmp/thing -R5s0zvDn

A still quieter version - without any debugging information but with a list of files loaded looks like this:


httrack "http://www.somesite.com/~library/thing/thingmain.htm" -O /tmp/thing -R5s0vDn

For the strong silent type, this might be still better:


httrack "http://www.somesite.com/~library/thing/thingmain.htm" -O /tmp/thing -R5s0qDn

General questions:

Q: The install is not working on NT without administrator rights!

A: That's right. You can, however, install WinHTTrack on your own machine, and then copy your WinHTTrack folder from your Program Files folder to another machine, in a temporary directory (e.g. C:\temp\)

Q: Where can I find French/other languages documentation?

A: Windows interface is available on several languages, but not yet the documentation!

Q: Is HTTrack working on NT/2000?

A: Yes, it should

Q: What's the difference between HTTrack and WinHTTrack?

A: WinHTTrack is the Windows release of HTTrack (with a graphic shell)

Q: Is HTTrack Mac compatible?

A: No, because of a lack of time. But sources are available

Q: Can HTTrack be compiled on all Un*x?

A: It should. The Makefile may be modified in some cases, however

Q: I use HTTrack for professional purpose. What about restrictions/license fee?

A: There is no restrictions using HTTrack for professional purpose, except if you want to sell a product including HTTrack components (parts of the source, or any other component). See the license.txt file for more informations

Q: Is a DLL/library version available?

A: Not yet. But, again, sources are available (see license.txt for distribution infos)

Q: Is there a X11/KDE shell available for Linux and Un*x?

A: No. Unfortunately, we do not have enough time for that - if you want to help us, please write one!


Troubleshooting:

Q: Only the first page is caught. What's wrong?
A: First, check the hts-err.txt error log file - this can give you precious informations.

The problem can be a website that redirects you to another site (for example, www.all.net to public.www.all.net) : in this case, use filters to accept this site

This can be, also, a problem in the HTTrack options (link depth too low, for example)

Q: With WinHTTrack, sometimes the minimize in system tray causes a crash!

A: This bug sometimes appears in the shell on some systems. If you encounter this problem, avoid minimizing the window!

Q: URLs with https:// are not working!
A: HTTrack does not support https (secure socket layer protocol), only http protocol

Q: Files are created with strange names, like '-1.html'!

A: Check the build options (you may have selected user-defined structure with wrong parameters!)

Q: When capturing real audio links (.ra), I only get a shortcut!

A: Yes. The audio/video realtime streaming capture is not yet supported

Q: Using user:password@address is not working!

A: Again, first check the hts-err.txt error log file - this can give you precious informations

The site may have a different authentication scheme (form based authentication, for example)

Q: When I use HTTrack, nothing is mirrored (no files) What's happening?

A: First, be sure that the URL typed is correct. Then, check if you need to use a proxy server (see proxy options in WinHTTrack or the -P proxy:port option in the command line program). The site you want to mirror may only accept certain browsers. You can change your "browser identity" with the Browser ID option in the OPTION box. Finally, you can have a look at the hts-err.txt (and hts-log.txt) file to see what happened.

Q: There are missing files! What's happening?

A: You may want to capture files that are in a different folder, or in another web site. In this case, HTTrack does not capture them automatically, you have to ask it to do. For that, use the filters.

Example: You are downloading http://www.all.net/foo/ and can not get .jpg images located in http://www.all.net/bar/ (for example, http://www.all.net/bar/blue.jpg)

Then, add the filter rule +www.all.net/bar/*.jpg to accept all .jpg files from this location

You can, also, accept all files from the /bar folder with +www.all.net/bar/*, or only html files with +www.all.net/bar/*.html and so on..

Q: I'm downloading too many files! What can I do?

A: This is often the case when you use too large filters, for example +*.html, which asks the engine to catch all .html pages (even ones on other sites!). In this case, try to use more specific filters, like +www.all.net/specificfolder/*.html

If you still have too many files, use filters to avoid somes files. For example, if you have too many files from www.all.net/big/, use -www.all.net/big/* to avoid all files from this folder.

Q: File types are sometimes changed! Why?

A: By default, HTTrack tries to know the type of remote files. This is useful when links like http://www.all.net/foo.cgi?id=1 can be either HTML pages, images or anything else. Locally, foo.cgi will not be recognized as an html page, or as an image, by your browser. HTTrack has to rename the file as foo.html or foo.gif so that it can be viewed.

Sometimes, however, some data files are seen by the remote server as html files, or images : in this case HTTrack is being fooled.. and rename the file. You can avoid this by disabling the type checking in the option panel.

Q: I can not access to several pages (access forbidden, or redirect to another location), but I can with my browser, what's going on?

A: You may need cookies! Cookies are specific datas (for example, your username or password) that are sent to your browser once you have logged in certain sites so that you only have to log-in once. For example, after having entered your username in a website, you can view pages and articles, and the next time you will go to this site, you will not have to re-enter your username/password.

To "merge" your personnal cookies to an HTTrack project, just copy the cookies.txt file from your Netscape folder (or the cookies located into the Temporary Internet Files folder for IE) into your project folder (or even the HTTrack folder)

Q: Some pages can't be seen, or are displayed with errors!

A: Some pages may include javascript or java files that are not recognized. For example, generated filenames. There may be transfer problems, too (broken pipe, etc.). But most mirrors do work. We still are working to improve the mirror quality of HTTrack.

Q: Some Java applets do not work properly!

A: Java applets may not work in some cases, for example if HTTrack failed to detect all included classes or files called within the class file. Sometimes, Java applets need to be online, because remote files are directly caught. Finally, the site structure can be incompatible with the class (always try to keep the original site structure when you want to get Java classes)

If there is no way to make some classes work properly, you can exclude them with the filters. They will be available, but only online.

Q: HTTrack is being idle for a long time without transfering. What's happening?

A: Maybe you try to reach some very slow sites. Try a lower TimeOut value (see options, or -Txx option in the command line program). Note that you will abandon the entire site (except if the option is unchecked) if a timeout happen You can, with the Shell version, skip some slow files, too.

Q: I want to update a site, but it's taking too much time! What's happening?

A: First, HTTrack always tries to minimize the download flow by interrogating the server about the file changes. But, because HTTrack has to rescan all files from the begining to rebuild the local site structure, it can takes some time. Besides, some servers are not very smart and always consider that they get newer files, forcing HTTrack to reload them, even if no changes have been made!

Q: I am behind a firewall. What can I do?

A: You need to use a proxy, too. Ask your administrator to know the proxy server's name/port. Then, use the proxy field in HTTrack or use the -P proxy:port option in the command line program.

Q: HTTrack has crashed during a mirror, what's happening?

A: We are trying to avoid bugs and problems so that the program can be as reliable as possible. But we can not be infallible. If you occurs a bug, please check if you have the latest release of HTTrack, and send us an email with a detailed description of your problem (OS type, addresses concerned, crash description, and everything you deem to be necessary). This may help the other users too.

Q: I want to update a mirrored project, but HTTrack is retransfering all pages. What's going on?

A: First, HTTrack always rescan all local pages to reconstitute the website structure, and it can take some time. Then, it asks the server if the files that are stored locally are up-to-date. On most sites, pages are not updated frequently, and the update process is fast. But some sites have dynamically-generated pages that are considered as "newer" than the local ones.. even if there are identical! Unfortunately, there is no possibility to avoid this problem, which is strongly linked with the server abilities.


Questions concerning a mirror:

Q: I want to mirror a Web site, but there are some files outside the domain, too. How to retrieve them?

A: If you just want to retrieve files that can be reached through links, just activate the 'get file near links' option. But if you want to retrieve html pages too, you can both use wildcards or explicit addresses ; e.g. add www.all.net/* to accept all files and pages from www.all.net.

Q: I have forgotten some URLs of files during a long mirror.. Should I redo all?

A: No, if you have kept the 'cache' files (in hts-cache), cached files will not be retransferred.

Q: I just want to retrieve all ZIP files or other files in a web site/in a page. How do I do it?

A: You can use different methods. You can use the 'get files near a link' option if files are in a foreign domain. You can use, too, a filter adress: adding +*.zip in the URL list (or in the filter list) will accept all ZIP files, even if these files are outside the address.

Example : httrack www.all.net/someaddress.html +*.zip will allow you to retrieve all zip files that are linked on the site.

Q: There are ZIP files in a page, but I don't want to transfer them. How do I do it?

A: Just filter them: add -*.zip in the filter list.

Q: I don't want to load gif files.. but what may happen if I watch the page?

A: If you have filtered gif files (-*.gif), links to gif files will be rebuild so that your browser can find them on the server.

Q: I get all types of files on a web site, but I didn't select them on filters!

A: By default, HTTrack retrieves all types of files on authorized links. To avoid that, define filters like

-* +<website>/*.html +<website>/*.htm +<website>/ +*.<type wanted>

Example: httrack www.all.net/index.html -* +www.all.net/*.htm* +www.all.net/*.gif +www.all.net/*.jpg

Q: When I use filters, I get too many files!

A: You are using too large a filter, for example *.html will get ALL html files identified. If you want to get all files on an address, use www.<address>/*.html. There are lots of possibilities using filters.

Example:httrack www.all.net +*.www.all.net/*.htm*

Q: When I use filters, I can't access another domain, but I have filtered it!

A: You may have done a mistake declaring filters, for example +www.all.net/* -*all* will not work, because -*all* has an upper priority (because it has been declared after +www.all.net)

Q: Must I add a  '+' or '-' in the filter list when I want to use filters?

A: YES. '+' is for accepting links and '-' to avoid them. If you forget it, HTTrack will consider that you want to accept a filter if there is a wild card in the syntax - e.g. +<filter> if identical to <filter> if <filter> contains a wild card (*) (else it will be considered as a normal link to mirror)

Q: I want to find file(s) in a web-site. How do I do it?

A: You can use the filters: forbid all files (add a -* in the filter list) and accept only html files and the file(s) you want to retrieve (BUT do not forget to add +<website>*.html in the filter list, or pages will not be scanned! Add the name of files you want with a */ before ; i.e. if you want to retrieve file.zip, add */file.zip)

Example:httrack www.all.net +www.all.net/*.htm* +thefileiwant.zip

Q: I want to download ftp files/ftp site. How to do?

A: First, HTTrack is not the best tool to download many ftp files. Its ftp engine is basic (even if reget are possible) and if your purpose is to download a complete site, use a specific client.

You can download ftp files just by typing the URL, such as ftp://ftp.www.all.net/pub/files/file010.zip and list ftp directories like ftp://ftp.www.all.net/pub/files/ .

Note: For the filters, use something like +ftp://ftp.www.all.net/*

Q: How can I retrieve .asp or .cgi sources instead of .html result?

A: You can't! For security reasons, web servers do not allow that.

Q: How can I remove these annoying <!-- Mirrored from... --> from html files?

A: Use the footer option (-&F, or see the WinHTTrack options)

Q: Do I have to select between ascii/binary transfer mode?

A: No, http files are always transferred as binary files. Ftp files, too (even if ascii mode could be selected)

Q: Can HTTrack perform form-based authentication?

A: Yes. See the URL capture abilities (--catchurl for command-line release, or in the WinHTTrack interface)

Q: Can I redirect downloads to tar/zip archive?

A: Yes. See the shell system command option (-V option for command-line release)

Q: Can I use username/password authentication on a site?

A: Yes. Use user:password@your_url (example: http://foo:bar@www.all.net/private/mybox.html)

Q: Can I use username/password authentication for a proxy?

A: Yes. Use user:password@your_proxy_name as your proxy name (example: smith:foo@proxy.mycorp.com)

Q: Can HTTrack generates HP-UX or ISO9660 compatible files?

A: Yes. See the build options (-N, or see the WinHTTrack options)

Q: If there any SOCKS support?

A: Not yet!

Q: What's this hts-cache directory? Can I remove it?

A: NO if you want to update the site, because this directory is used by HTTrack for this purpose. If you remove it, options and URLs will not be available for updating the site

Q: Can I start a mirror from my bookmarks?

A: Yes. Drag&Drop your bookmark.html file to the WinHTTrack window (or use file://filename for command-line release) and select bookmark mirroring (mirror all links in pages, -Y) or bookmark testing (--testlinks)

Q: I am getting a "pipe broken" error and the mirror stops, what should I do?

A: Chances are this is a result of downloading too many pages at a time. Remote servers may not allow or be able to handle too many sessions, or your system may be unable to provide the necessary resources. Try redusing this number - for example using the -c2 options for only 2 simultaneous sesions.

httrack-3.49.5/html/faq.html0000644000175000017500000014711614360553245012617 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

F A Q



    Tips:
  • In case of troubles/problems during transfer, first check the hts-log.txt (and hts-err.txt) files to figure out what happened. These log files report all events that may be useful to detect a problem. You can also ajust the debug level of the log files in the option
  • The tutorial written by Fred Cohen is a very good document to read, to understand how to use the engine, how the command line version works, and how the window version works, too! All options are described and explained in clear language!




Very Frequently Asked Questions:

Q: HTTrack does not capture all files I want to capture!
A: This is a frequent question, generally related to the filters. BUT first check if your problem is not related to the
robots.txt website rules.

Okay, let me explain how to precisely control the capture process.

Let's take an example:

Imagine you want to capture the following site:
www.someweb.com/gallery/flowers/

HTTrack, by default, will capture all links encountered in www.someweb.com/gallery/flowers/ or in lower directories, like www.someweb.com/gallery/flowers/roses/.
It will not follow links to other websites, because this behaviour might cause to capture the Web entirely!
It will not follow links located in higher directories, too (for example, www.someweb.com/gallery/flowers/ itself) because this might cause to capture too much data.

This is the default behaviour of HTTrack, BUT, of course, if you want, you can tell HTTrack to capture other directorie(s), website(s)!..
In our example, we might want also to capture all links in www.someweb.com/gallery/trees/, and in www.someweb.com/photos/

This can easily done by using filters: go to the Option panel, select the 'Scan rules' tab, and enter this line: (you can leave a blank space between each rules, instead of entering a carriage return)
+www.someweb.com/gallery/trees/*
+www.someweb.com/photos/*


This means "accept all links begining with www.someweb.com/gallery/trees/ and www.someweb.com/photos/" - the + means "accept" and the final * means "any character will match after the previous ones". Remember the *.doc or *.zip encountered when you want to select all files from a certain type on your computer: it is almost the same here, except the begining "+"

Now, we might want to exclude all links in www.someweb.com/gallery/trees/hugetrees/, because with the previous filter, we accepted too many files. Here again, you can add a filter rule to refuse these links. Modify the previous filters to:
+www.someweb.com/gallery/trees/*
+www.someweb.com/photos/*
-www.someweb.com/gallery/trees/hugetrees/*


You have noticed the - in the begining of the third rule: this means "refuse links matching the rule" ; and the rule is "any files begining with www.someweb.com/gallery/trees/hugetrees/
Voila! With these three rules, you have precisely defined what you wanted to capture.

A more complex example?

Imagine that you want to accept all jpg files (files with .jpg type) that have "blue" in the name and located in www.someweb.com
+www.someweb.com/*blue*.jpg

More detailed information can be found here!


General questions:

Q: Is there any 'spyware' or 'adware' in this program? Can you prove that there isn't any?
A: No ads (banners), and absolutely no 'spy' features inside the program.
The best proof is the software status: all sources are released, and everybody can check them. Open source is the best protection against privacy problems - HTTrack is an open source project, free of charge and free of any spy 'features'.
However, be sure to always download HTTrack from a trusted source (preferably httrack.com), as some rogue freeware sites are "embedding" free software inside adware/spyware installers. If the version you installed contained some embedded adware/tool bar/whatever, there is a high potential risk of virus/badware infection (the only official Internet Explorer feature is a 'Launch WinHTTrack' optional menu in the Tools section, which can be selected while installing).


Q: This software is 'free', but I bought it from an authorized reseller . What's going on?
A: HTTrack is free (free as in 'freedom') as it is covered by the GNU General Public License (GPL). You can freely download it, without paying any fees, copy it to your friends, and modify it if you respect the license. There are NO official/authorized resellers, because HTTrack is NOT a commercial product. But you can be charged for duplication fees, or any other services (example: software CDroms or shareware collections, or fees for maintenance), but you should have been informed that the software was free software/GPL, and you MUST have received a copy of the GNU General Public License. Otherwise this is dishonnest and unfair (ie. selling httrack on ebay without telling that it was a free software is a scam).

Q: Are there any risks of viruses with this software?
A: For the software itself: All official releases (at httrack.com) are checked against all known viruses, and the packaging process is also checked. Archives are stored on Un*x servers, not really concerned by viruses. It has been reported, however, that some rogue freeware sites are embedding free softwares and freewares inside badware installers. Always download httrack from the main site (www.httrack.com), and never from an untrusted source!
For files you are downloading on the WWW using HTTrack: You may encounter websites which were corrupted by viruses, and downloading data on these websites might be dangerous if you execute downloaded executables, or if embedded pages contain infected material (as dangerous as if using a regular Browser). Always ensure that websites you are crawling are safe. (Note: remember that using an antivirus software is a good idea once you are connected to the Internet)


Q: The install is not working on Windows without administrator rights!
A: That's right. You can, however, install WinHTTrack on your own machine, and then copy your WinHTTrack folder from your Program Files folder to another machine, in a temporary directory (e.g. C:\temp\). You may download the 'non-installer' version, and unzip it in any directory (or an USB key).

Q: Where can I find French/other languages documentation?
A: Windows interface is available on several languages, but not yet the documentation!

Q: Is HTTrack working on Windows Vista/Windows Seven/Windows 8 ?
A: Yes, it does

Q: Is HTTrack working on Windows 95/98 ?
A: No, not anymore. You may try to pick an older release (such as 3.33)

Q: What's the difference between HTTrack, WinHTTrack and WebHTTrack?
A: WinHTTrack is the Windows GUI release of HTTrack (with a native graphic shell) and WebHTTrack is the Linux/Posix release of HTTrack (with an html graphic shell)

Q: Is HTTrack Mac compatible?
A: Yes, using the original sources, or with MacPorts.

Q: Can HTTrack be compiled on all Un*x?
A: It should. The configure.ac may be modified in some cases, however

Q: I use HTTrack for professional purpose. What about restrictions/license fee?
A: HTTrack is covered by the GNU General Public License (GPL). There is no restrictions using HTTrack for professional purpose, except if you develop a software which uses HTTrack components (parts of the source, or any other component). See the license.txt file for more information. See also the next question regarding copyright issues when reditributing downloaded material.

Q: Is there any license royalties for distributing a mirror made with HTTrack?
A: On the HTTrack side, no. However, sharing, publishing or reusing copyrighted material downloaded from a site requires the authorization of the copyright holders, and possibly paying royalty fees. Always ask the authorization before creating a mirror of a site, even if the site appears to be royalty-free and/or without copyright notice.

Q: Is a DLL/library version available?
A: Yes. The default distribution includes a DLL (Windows) or a .so (Un*X), used by the program

Q: Is there a GUI version available for Linux and Un*x?
A: Yes. It is called WebHTTrack. See the download section at www.httrack.com!

Troubleshooting:

Q: Some sites are captured very well, other aren't. Why?
A: There are several reasons (and solutions) for a mirror to fail. Reading the log files (ans this FAQ!) is generally a VERY good idea to figure out what occurred.
There are cases, however, that can not be (yet) handled:
  • Flash sites - no full support
  • Intensive Java/Javascript sites - might be bogus/incomplete
  • Complex CGI with built-in redirect, and other tricks - very complicated to handle, and therefore might cause problems
  • Parsing problem in the HTML code (cases where the engine is fooled, for example by a false comment (<!--) which has no closing comment (-->) detected. Rare cases, but might occur. A bug report is then generally good!
Note: For some sites, setting "Force old HTTP/1.0 requests" option can be useful, as this option uses more basic requests (no HEAD request for example). This will cause a performance loss, but will increase the compatibility with some cgi-based sites.

Q: Only the first page is caught. What's wrong?
A: First, check the hts-log.txt file (and/or hts-err.txt error log file) - this can give you precious information.
The problem can be a website that redirects you to another site (for example, www.someweb.com to public.someweb.com) : in this case, use filters to accept this site
This can be, also, a problem in the HTTrack options (link depth too low, for example)


Q: With WinHTTrack, sometimes the minimize in system tray causes a crash!
A: This bug sometimes appears in the shell on some systems. If you encounter this problem, avoid minimizing the window!

Q: Are https URL working?
A: Yes, HTTrack does support (since 3.20 release) https (secure socket layer protocol) sites

Q: Are ipv6 URL working?
A: Yes, HTTrack does support (since 3.20 release) ipv6 sites, using A/AAAA entries, or direct v6 addresses (like http://[3ffe:b80:12:34:56::78]/)

Q: Files are created with strange names, like '-1.html'!
A: Check the build options (you may have selected user-defined structure with wrong parameters!)

Q: When capturing real audio/video links (.ram), I only get a shortcut!
A: Yes, but .ra/.rm associated file should be captured together - except if rtsp:// protocol is used (not supported by HTTrack yet), or if proper filters are needed

Q: Using user:password@address is not working!
A: Again, first check the hts-log.txt and hts-err.txt error log files - this can give you precious information
The site may have a different authentication scheme - form based authentication, for example. In this case, use the URL capture features of HTTrack, it might work.
Note: If your username and/or password contains a '@' character, you may have to replace all '@' occurences by '%40' so that it can work, such as in user%40domain.com:foobar@www.foo.com/auth/. You may have to do the same for all "special" characters like spaces (%20), quotes (%22)..


Q: When I use HTTrack, nothing is mirrored (no files) What's happening?
A: First, be sure that the URL typed is correct. Then, check if you need to use a proxy server (see proxy options in WinHTTrack or the -P proxy:port option in the command line program). The site you want to mirror may only accept certain browsers. You can change your "browser identity" with the Browser ID option in the OPTION box. Finally, you can have a look at the hts-log.txt (and hts-err.txt) file to see what happened.

Q: There are missing files! What's happening?
A: You may want to capture files that exist in a different folder, or in another web site. You may also want to capture files that are forbidden by default by the
robots.txt website rules. In these cases, HTTrack does not capture these links automatically, you have to tell it to do so.

  • Either use the filters.
    Example: You are downloading http://www.someweb.com/foo/ and can not get .jpg images located in http://www.someweb.com/bar/ (for example, http://www.someweb.com/bar/blue.jpg)
    Then, add the filter rule +www.someweb.com/bar/*.jpg to accept all .jpg files from this location
    You can, also, accept all files from the /bar folder with +www.someweb.com/bar/*, or only html files with +www.someweb.com/bar/*.html and so on..

  • If the problems are related to robots.txt rules, that do not let you access some folders (check in the logs if you are not sure), you may want to disable the default robots.txt rules in the options. (but only disable this option with great care, some restricted parts of the website might be huge or not downloadable)

Q: There are corrupted images/files! How to fix them?
A: First check the log files to ensure that the images do really exist remotely and are not fake html error pages renamed into .jpg ("Not found" errors, for example). Rescan the website with "Continue an interrupted download" to catch images that might be broken due to various errors (transfer timemout, for example). Then, check if the broken image/file name is present in the log (hts-log.txt) - in this case you will find there the reason why the file has not been properly caught.
If this doesn't work, delete the corrupted files (Note: to detect corrupted images, you can browse the directories with a tool like ACDSee and then delete them) and rescan the website as described before. HTTrack will be obliged to recatch the deleted files, and this time it should work, if they do really exist remotely!.


Q: FTP links are not caught! What's happening?
A: FTP files might be seen as external links, especially if they are located in outside domain. You have either to accept all external links (See the links options, -n option) or only specific files (see
filters section).
Example: You are downloading http://www.someweb.com/foo/ and can not get ftp://ftp.someweb.com files
Then, add the filter rule +ftp.someweb.com/* to accept all files from this (ftp) location

Q: I got some weird messages telling that robots.txt do not allow several files to be captured. What's going on?
A: These rules, stored in a file called robots.txt, are given by the website, to specify which links or folders should not be caught by robots and spiders - for example, /cgi-bin or large images files. They are followed by default by HTTrack, as it is advised. Therefore, you may miss some files that would have been downloaded without these rules - check in your logs if it is the case:
Info: Note: due to www.foobar.com remote robots.txt rules, links begining with these path will be forbidden: /cgi-bin/,/images/ (see in the options to disable this)
If you want to disable them, just change the corresponding option in the option list! (but only disable this option with great care, some restricted parts of the website might be huge or not downloadable)


Q: I have duplicate files! What's going on?
A: This is generally the case for top indexes (index.html and index-2.html), isn't it?
This is a common issue, but that can not be easily avoided!
For example, http://www.foobar.com/ and http://www.foobar.com/index.html might be the same pages. But if links in the website refers both to http://www.foobar.com/ and http://www.foobar.com/index.html, these two pages will be caught. And because http://www.foobar.com/ must have a name, as you may want to browse the website locally (the / would give a directory listing, NOT the index itself!), HTTrack must find one. Therefore, two index.html will be produced, one with the -2 to show that the file had to be renamed.
It might be a good idea to consider that http://www.foobar.com/ and http://www.foobar.com/index.html are the same links, to avoid duplicate files, isn't it? NO, because the top index (/) can refer to ANY filename, and if index.html is generally the default name, index.htm can be choosen, or index.php3, mydog.jpg, or anything you may imagine. (some webmasters are really crazy)

Note: In some rare cases, duplicate data files can be found when the website redirect to another file. This issue should be rare, and might be avoided using filters.


Q: I'm downloading too many files! What can I do?
A: This is often the case when you use too large a filter, for example +*.html, which asks the engine to catch all .html pages (even ones on other sites!). In this case, try to use more specific filters, like +www.someweb.com/specificfolder/*.html
If you still have too many files, use filters to avoid somes files. For example, if you have too many files from www.someweb.com/big/, use -www.someweb.com/big/* to avoid all files from this folder. Remember that the default behaviour of the engine, when mirroring http://www.someweb.com/big/index.html, is to catch everything in http://www.someweb.com/big/. Filters are your friends, use them!


Q: The engine turns crazy, getting thousands of files! What's going on?
A: This can happen if a loop occurs in some bogus website. For example, a page that refers to itself, with a timestamp in the query string (e.g. http://www.someweb.com/foo.asp?ts=2000/10/10,09:45:17:147). These are really annoying, as it is VERY difficult to detect the loop (the timestamp might be a page number). To limit the problem: set a recurse level (for example to 6), or avoid the bogus pages (use the filters)

Q: File are sometimes renamed (the type is changed)! Why?
A: By default, HTTrack tries to know the type of remote files. This is useful when links like http://www.someweb.com/foo.cgi?id=1 can be either HTML pages, images or anything else. Locally, foo.cgi will not be recognized as an html page, or as an image, by your browser. HTTrack has to rename the file as foo.html or foo.gif so that it can be viewed.

Q: File are sometimes *incorrectly* renamed! Why?
A: Sometimes, some data files are seen by the remote server as html files, or images : in this case HTTrack is being fooled.. and rename the file. This can generally be avoided by using the "use HTTP/1.0 requests" option. You might also avoid this by disabling the type checking in the option panel.

Q: How do I rename all ".dat" files into ".zip" files?
A: Simply use the --assume dat=application/x-zip option

Q: I can not access several pages (access forbidden, or redirect to another location), but I can with my browser, what's going on?
A: You may need cookies! Cookies are specific data (for example, your username or password) that are sent to your browser once you have logged in certain sites so that you only have to log-in once. For example, after having entered your username in a website, you can view pages and articles, and the next time you will go to this site, you will not have to re-enter your username/password.
To "merge" your personnal cookies to an HTTrack project, just copy the cookies.txt file from your Netscape folder (or the cookies located into the Temporary Internet Files folder for IE) into your project folder (or even the HTTrack folder)


Q: Some pages can't be seen, or are displayed with errors!
A: Some pages may include javascript or java files that are not recognized. For example, generated filenames. There may be transfer problems, too (broken pipe, etc.). But most mirrors do work. We still are working to improve the mirror quality of HTTrack.

Q: Some Java applets do not work properly!
A: Java applets may not work in some cases, for example if HTTrack failed to detect all included classes or files called within the class file. Sometimes, Java applets need to be online, because remote files are directly caught. Finally, the site structure can be incompatible with the class (always try to keep the original site structure when you want to get Java classes)
If there is no way to make some classes work properly, you can exclude them with the filters. They will be available, but only online.


Q: HTTrack is taking too much time for parsing, it is very slow. What's wrong?
A: Former (before 3.04) releases of HTTrack had problems with parsing. It was really slow, and performances -especially with huge HTML files- were not really good. The engine is now optimized, and should parse very quickly all html files. For example, a 10MB HTML file should be scanned in less than 3 or 4 seconds.

Therefore, higher values mean that the engine had to wait a bit for testing several links.
  • Sometimes, links are malformed in pages. "a href="/foo"" instead of "a href="/foo/"", for example, is a common mistake. It will force the engine to make a supplemental request, and find the real /foo/ location.


  • Dynamic pages. Links with names terminated by .php3, .asp or other type which are different from the regular .html or .htm will require a supplemental request, too. HTTrack has to "know" the type (called "MIME type") of a file before forming the destination filename. Files like foo.gif are "known" to be images, ".html" are obviously HTML pages - but ".php3" pages may be either dynamically generated html pages, images, data files...

    If you KNOW that ALL ".php3" and ".asp" pages are in fact HTML pages on a mirror, use the assume option:
    --assume php3=text/html,asp=text/html

    This option can be used to change the type of a file, too : the MIME type "application/x-MYTYPE" will always have the "MYTYPE" type. Therefore,
    --assume dat=application/x-zip
    will force the engine to rename all dat files into zip files


Q: HTTrack is being idle for a long time without transfering. What's happening?
A: Maybe you try to reach some very slow sites. Try a lower TimeOut value (see options, or -Txx option in the command line program). Note that you will abandon the entire site (except if the option is unchecked) if a timeout happen You can, with the Shell version, skip some slow files, too.

Q: I want to update a site, but it's taking too much time! What's happening?
A: First, HTTrack always tries to minimize the download flow by interrogating the server about the file changes. But, because HTTrack has to rescan all files from the begining to rebuild the local site structure, it can take some time. Besides, some servers are not very smart and always consider that they get newer files, forcing HTTrack to reload them, even if no changes have been made!

Q: I wanted to update a site, but after the update the site disappeared!! What's going on?
A: You may have done something wrong, but not always
  • The site has moved : the current location only shows a notification. Therefore, all other files have been deleted to show the current state of the website!
  • The connection failed: the engine could not catch the first files, and therefore deleted everything. To avoid that, using the option "do not purge old files" might be a good idea
  • You tried to add a site to the project BUT in fact deleted the former addresses.
    Example: A project contains 'www.foo.com www.bar.com' and you want to add 'www.doe.com'. Ensure that 'www.foo.com www.bar.com www.doe.com' is the new URL list, and NOT 'www.doe.com'!

Q: I am behind a firewall. What can I do?
A: You need to use a proxy, too. Ask your administrator to know the proxy server's name/port. Then, use the proxy field in HTTrack or use the -P proxy:port option in the command line program.

Q: HTTrack has crashed during a mirror, what's happening?
A: We are trying to avoid bugs and problems so that the program can be as reliable as possible. But we can not be infallible. If you occurs a bug, please check if you have the latest release of HTTrack, and send us an email with a detailed description of your problem (OS type, addresses concerned, crash description, and everything you deem to be necessary). This may help the other users too.


Q: I want to update a mirrored project, but HTTrack is retransfering all pages. What's going on?
A: First, HTTrack always rescans all local pages to reconstitute the website structure, and it can take some time. Then, it asks the server if the files that are stored locally are up-to-date. On most sites, pages are not updated frequently, and the update process is fast. But some sites have dynamically-generated pages that are considered as "newer" than the local ones.. even if they are identical! Unfortunately, there is no possibility to avoid this problem, which is strongly linked with the server abilities.

Q: I want to continue a mirrored project, but HTTrack is rescanning all pages. What's going on?
A: HTTrack has to (quickly) rescan all pages from the cache, without retransfering them, to rebuild the internal file structure. However, this process can take some time with huge sites with numerous links.

Q: HTTrack window sometimes "disappears" at then end of a mirrored project. What's going on?
A: This is a known bug in the interface. It does NOT affect the quality of the mirror, however. We are still hunting it down, but this is a smart bug..


Questions concerning a mirror:

Q: I want to mirror a Web site, but there are some files outside the domain, too. How to retrieve them?
A: If you just want to retrieve files that can be reached through links, just activate the 'get file near links' option. But if you want to retrieve html pages too, you can both use wildcards or explicit addresses ; e.g. add www.someweb.com/* to accept all files and pages from www.someweb.com.

Q: I have forgotten some URLs of files during a long mirror.. Should I redo all?
A: No, if you have kept the 'cache' files (in hts-cache), cached files will not be retransferred.

Q: I just want to retrieve all ZIP files or other files in a web site/in a page. How do I do it?
A: You can use different methods. You can use the 'get files near a link' option if files are in a foreign domain. You can use, too, a filter adress: adding +*.zip in the URL list (or in the filter list) will accept all ZIP files, even if these files are outside the address.
Example : httrack www.someweb.com/someaddress.html +*.zip will allow you to retrieve all zip files that are linked on the site.


Q: There are ZIP files in a page, but I don't want to transfer them. How do I do it?
A: Just filter them: add -*.zip in the filter list.

Q: I don't want to download ZIP files bigger than 1MB and MPG files smaller than 100KB. Is it possible?
A: You can use
filters for that ; using the syntax:
-*.zip*[>1000] -*.mpg*[<100]

Q: I don't want to load gif files.. but what may happen if I watch the page?
A: If you have filtered gif files (-*.gif), links to gif files will be rebuilt so that your browser can find them on the server.

Q: I don't want to download thumbnail images.. is it possible?
A: Filters can not be used with image pixel size ; but you can filter on file size (bytes). Use advanced
filters for that ; such as:
-*.gif*[<10] to exclude gif files smaller than 10KiB.


Q: I get all types of files on a web site, but I didn't select them on filters!
A: By default, HTTrack retrieves all types of files on authorized links. To avoid that, define filters like
-* +<website>/*.html +<website>/*.htm +<website>/ +*.<type wanted>
Example: httrack www.someweb.com/index.html -* +www.someweb.com/*.htm* +www.someweb.com/*.gif +www.someweb.com/*.jpg

Q: When I use filters, I get too many files!
A: You might use too large a filter, for example *.html will get ALL html files identified. If you want to get all files on an address, use www.<address>/*.html.
If you want to get ONLY files defined by your filters, use something like -* +www.foo.com/*, because +www.foo.com/* will only accept selected links without forbidding other ones!
There are lots of possibilities using filters.
Example:httrack www.someweb.com +*.someweb.com/*.htm*

Q: When I use filters, I can't access another domain, but I have filtered it!
A: You may have done a mistake declaring filters, for example +www.someweb.com/* -*someweb* will not work, because -*someweb* has an upper priority (because it has been declared after +www.someweb.com)

Q: Must I add a  '+' or '-' in the filter list when I want to use filters?
A: YES. '+' is for accepting links and '-' to avoid them. If you forget it, HTTrack will consider that you want to accept a filter if there is a wild card in the syntax - e.g. +<filter> is identical to <filter> if <filter> contains a wild card (*) (else it will be considered as a normal link to mirror)


Q: I want to find file(s) in a web-site. How do I do it?
A: You can use the filters: forbid all files (add a -* in the filter list) and accept only html files and the file(s) you want to retrieve (BUT do not forget to add +<website>*.html in the filter list, or pages will not be scanned! Add the name of files you want with a */ before ; i.e. if you want to retrieve file.zip, add */file.zip)
Example:httrack www.someweb.com +www.someweb.com/*.htm* +thefileiwant.zip

Q: I want to download ftp files/ftp site. How do I do it?
A: First, HTTrack is not the best tool to download many ftp files. Its ftp engine is basic (even if reget are possible) and if your purpose is to download a complete site, use a specific client.
You can download ftp files just by typing the URL, such as ftp://ftp.somesite.com/pub/files/file010.zip and list ftp directories like ftp://ftp.somesite.com/pub/files/
.
Note: For the filters, use something like +ftp.somesite.com/*

Q: How can I retrieve .asp or .cgi sources instead of .html result?
A: You can't! For security reasons, web servers do not allow that.

Q: How can I remove these annoying <!-- Mirrored from... --> from html files?
A: Use the footer option (-%F, or see the WinHTTrack options)

Q: Do I have to select between ascii/binary transfer mode?
A: No, http files are always transferred as binary files. Ftp files, too (even if ascii mode could be selected)

Q: Can HTTrack perform form-based authentication?
A: Yes. See the URL capture abilities (--catchurl for command-line release, or in the WinHTTrack interface)

Q: Can I redirect downloads to tar/zip archive?
A: Yes. See the shell system command option (-V option for command-line release)

Q: Can I use username/password authentication on a site?
A: Yes. Use user:password@your_url (example: http://foo:bar@www.someweb.com/private/mybox.html)

Q: Can I use username/password authentication for a proxy?
A: Yes. Use user:password@your_proxy_name as your proxy name (example: smith:foo@proxy.mycorp.com)

Q: Can HTTrack generates HP-UX or ISO9660 compatible files?
A: Yes. See the build options (-N, or see the WinHTTrack options)

Q: If there any SOCKS support?
A: Not yet!

Q: What's this hts-cache directory? Can I remove it?
A: NO if you want to update the site, because this directory is used by HTTrack for this purpose. If you remove it, options and URLs will not be available for updating the site

Q: What is the meaning of the Links scanned: 12/34 (+5) line in WinHTTrack/WebHTTrack?
A: 12 is the number of links scanned and stored, 34 the total number of links detected to be parsed, and 5 the number of files downloaded in background. In this example, 17 links were downloaded out of a (temporary) total of 34 links.

Q: Can I start a mirror from my bookmarks?
A: Yes. Drag&Drop your bookmark.html file to the WinHTTrack window (or use file://filename for command-line release) and select bookmark mirroring (mirror all links in pages, -Y) or bookmark testing (--testlinks)

Q: Can I convert a local website (file:// links) to a standard website?
A: Yes. Just start from the top index (example: file://C:\foopages\index.html) and mirror the local website. HTTrack will convert all file:// links to relative ones.

Q: Can I copy a project to another folder - Will the mirror work?
A: Yes. There is no absolute links, all links are relative. You can copy a project to another drive/computer/OS, and browse is without installing anything.

Q: Can I copy a project to another computer/system? Can I then update it ?
A: Absolutely! You can keep your HTTrack favorite folder (C:\My Web Sites) in your local hard disk, copy it for a friend, and possibly update it, and then bring it back!
You can copy individual folders (projects), too: exchange your favorite websites with your friends, or send an old version of a site to someone who has a faster connection, and ask him to update it!

Note: Export (Windows <-> Linux)
The file and cache structure is compatible between Linux/Windows, but you may have to do some changes, like the path
Windows -> Linux/Unix
Copy (in binary mode) the entire folder and then to update it, enter into it and do a
httrack --update -O ./

Note: You can then safely replace the existing folder (under Windows) with this one, because the Linux/Unix version did not change any options
Note: If you often switch between Windows/Linux with the same project, it might be a good idea to edit the hts-cache/doit.log file and delete old "-O" entries, because each time you do a httrack --update -O ./ an entry is added, causing the command line to be long
Linux/Unix -> Windows
Copy (in binary mode) the entire folder in your favorite Web mirror folder. Then, select this project, AND retype ALL URLs AND redefine all options as if you were creating a new project. This is necessary because the profile (winprofile.ini) has not be created with the Linux/Unix version. But do not be afraid, WinHTTrack will use cached files to update the project!


Q: How can I grab email addresses in web pages?
A: You can not. HTTrack has not be designed to be an email grabber, like many other (bad) products.


Other problems:

Q: My problerm is not listed!
A: Feel free to
contact us!


httrack-3.49.5/html/dev.html0000644000175000017500000001355014336470674012627 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

HTTrack Programming page


HTTrack can be used as a third-party program in batch files, or as library. Depending on your needs, you may look:

Programming

Technical references

  • Cache format

  • HTTrack stores original HTML data and references to downloaded files in a cache, located in the hts-cache directory. This page describes the HTTrack cache format.


httrack-3.49.5/html/contact.html0000644000175000017500000002200014336470674013472 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Contact Us!


Please visit our website!

About this project:
Informations on this project:

This project has been developed by:
Xavier Roche (xroche at httrack dot com)
  for the main engine and Windows interface
  and maintainer for v2.0 and v3.0
Yann Philippot (yphilippot at lemel dot fr)
  for the java binary  dot class parser
David Lawrie (dalawrie at lineone dot net)
Robert Lagadec (rlagadec at yahoo dot fr)
  for checking both English & French translations
Juan Pablo Barrio Lera (University of Len)
  for Spanish translations
Rainer Klueting (rainer at klueting dot de)
Bastian Gorke (bastiang at yahoo dot com)
Rudi Ferrari (Wyando at netcologne dot de)
Marcus Gaza (MarcusGaza at t-online dot de)
  for German translations
Rudi Ferrari (Wyando at netcologne dot de)
  for Dutch translations
Lukasz Jokiel (Opole University of Technology, Lukasz dot Jokiel at po dot opole dot pl)
  for Polish translations
Rui Fernandes (CANTIC, ruiefe at mail dot malhatlantica dot pt)
Pedro T dot  Pinheiro (Universidade Nova de Lisboa-FCT, ptiago at mail dot iupi dot pt)
  for Portuguese translations
Andrei Iliev (iliev at vitaplus dot ru)
  for Russian translations
Witold Krakowski (wtkrak at netscape dot net )
  for Italian translations
Jozsef Tamas Herczeg (hdodi at freemail dot hu)
  for Hungarian translation
Paulo Neto (company at layout dot com dot br)
  for Brazilian translation
Brook Qin (brookqwr at sina dot com) 
   for simplified Chinese translation
David Hing Cheong Hung (DAVEHUNG at mtr dot com dot hk)
Addy Lin (addy1975 at pchome dot com dot tw)
   for traditional Chinese translation
Jesper Bramm (bramm at get2net dot dk)
   for Danish translation
Tnu Virma
   for Estonian translation
Staffan Strm (staffan at fam-strom dot org)
   for Swedish translation
Mehmet Akif Keolu (mak at ttnet dot net dot tr)
  for Turkish translation
Aleksandar Savic (aleks at macedonia dot eu dot org)
  for Macedonian translation
Takayoshi Nakasikiryo
  for Japanese translation
Martin Sereday (sereday at slovanet dot sk)
  for Slovak translation
Antonn Matjk (matejcik at volny dot cz)
  for Czech translation
Andrij Shevchuk (http://programy dot com dot ua)
  for Ukrainian translation
Tobias "Spug" Langhoff (spug_enigma at hotmail dot com)
  for Norwegian translation
Jadran Rudeciur (jrudec at email dot si)
  for Slovenian translation
Alin Gheorghe Miron (miron dot alin at personal dot ro)
  for Romanian translation
Michael Papadakis (mikepap at freemail dot gr)
  for Greek translation

Thanks to:
Leto Kauler (molotov at tasmail dot com)
  for the site/logos design

Special Thanks to:
Patrick Ducrot & Daniel Carr (ENSI of Caen)
  for their initial support
Fred Cohen (fc at all dot net)
  for HTTrack user's guide

Greetings to:
Christian Marillat (marillat dot christian at wanadoo dot fr)
  for autoconf compliance and  .deb package
Jean-loup Gailly from gzip dot org
  for the help provided with Zlib
Eric A dot  Young (eay at cryptsoft dot com)
  for SSL cryptographic material (OpenSSL)

Russ Freeman from gipsymedia
  for hints on DLL dynamic load
Paul DiLascia
  for helping to fix problems with CHtmlView
ISMRA/Ensi of Caen 
  for their initial support
 .. and all users that are using and supporting HTTrack!



If you want to ask any question to the authors, report bugs/problems, please first check the HTTrack Website Copier forum.
You can also contact by email, but due to the large volume of messages, it is impossible to always respond (especially for configuration help or other configuration-related questions).




This program is covered by the GNU General Public License.
HTTrack/HTTrack Website Copier is Copyright (C) 1998-2007 Xavier Roche and other contributors
httrack-3.49.5/html/cmddoc.html0000644000175000017500000001271714336470674013306 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Command-Line Documentation


The command-line version
  • Command line Options

  • List of all powerful command line options

  • How to use httrack command-line version:
    • Open a shell window


    • Type in httrack (or the complete path to the httrack executable)

    • httrack

    • Add the URLs, separated by a blank space

    • httrack www.someweb.com/foo/

    • If you need, add some options (see the option list)

    • httrack www.someweb.com/foo/ -O "/webs" -N4 -P proxy.myhost.com:3128

    • Launch the command line, and wait until the mirror is finishing

    • You can (especially on the Unix release) press ^C to stop the mirror or put httrack in background

httrack-3.49.5/html/cache.html0000644000175000017500000002547714336470674013127 00000000000000 HTTrack Website Copier - Cache format specification
HTTrack Website Copier
Open Source offline browser

Cache format specification


For updating purpose, HTTrack stores original (untouched) HTML data, references to downloaded files, and other meta-data (especially parts of the HTTP headers) in a cache, located in the hts-cache directory. Because local html pages are always modified to "fit" the local filesystem structure, and because meta-data such as the last-Modified date and Etag can not be stored with the associated files, the cache is absolutely mandatory for reprocessing (update/continue) phases.

The (new) cache.zip format

The 3.31 release of HTTrack introduces a new cache format, more extensible and efficient than the previous one (ndx/dat format). The main advantages of this cache are:
  • One single file for a complete website cache archive
  • Standard ZIP format, that can be easily reused on most platforms and languages
  • Compressed data with the efficient and opened zlib format
The cache is made of ZIP files entries ; with one ZIP file entry per fetched URL (successfully or not - errors are also stored).
For each entry:
  • The ZIP file name is the original URL [see notes below]
  • The ZIP file contents, if available, is the original (compressed, using the deflate algorythm) data
  • The ZIP file extra field (in the local file header) contains a list of meta-fields, very similar to the HTTP headers fields. See also RFC.

  • The ZIP file timestamp follows the "Last-Modified-Since" field given for this URL, if any
Example of cache file:
$ unzip -l hts-cache/new.zip
Archive:  hts-cache/new.zip
HTTrack Website Copier/3.31-ALPHA-4 mirror complete in 3 seconds : 5 links scanned, 
3 files written (16109 bytes overall) [17690 bytes received at 5896 bytes/sec]
(1 errors, 0 warnings, 0 messages)
  Length     Date   Time    Name
 --------    ----   ----    ----
       94  07-18-03 08:59   http://www.httrack.com/robots.txt
     9866  01-17-04 01:09   http://www.httrack.com/html/cache.html
        0  05-11-03 13:31   http://www.httrack.com/html/images/bg_rings.gif
      207  01-19-04 05:49   http://www.httrack.com/html/fade.gif
        0  05-11-03 13:31   http://www.httrack.com/html/images/header_title_4.gif
 --------                   -------
    10167                   5 files
Example of cache file meta-data:
HTTP/1.1 200 OK
X-In-Cache: 1
X-StatusCode: 200
X-StatusMessage: OK
X-Size: 94
Content-Type: text/plain
Last-Modified: Fri, 18 Jul 2003 08:59:11 GMT
Etag: "40ebb5-5e-3f17b6df"
X-Addr: www.httrack.com
X-Fil: /robots.txt
There are also specific issues regarding this format:
  • The data in the central directory (such as CD extra field, and CD comments) are not used
  • The ZIP archive is allowed to contains more than 2^16 files (65535) ; in such case the total number of entries in the 32-bit central directory is 65536 (0xffff), but the presence of the 64-bit central directory is not mandatory
  • The ZIP archive is allowed to contains more than 2^32 bytes (4GiB) ; in such case the 64-bit central directory must be present (not currently supported)

Meta-data stored in the "extra field" of the local file headers
The extra field is composed of text data, and this text data is composed of distinct lines of headers. The end of text, or a double CR/LF, mark the end of this zone. This method allows you to optionally store original HTTP headers just after the "meta-data" headers for informational use.

The status line (the first headers line)
Status-Line = HTTP-Version SP Status-Code SP X-Reason-Phrase CRLF

Other lines:

Specific fields:
  • X-In-Cache

  • Indicates if the data are present (value=1) in the cache (that is, as ZIP data), or in an external file (value=0). This field MUST be the first field.
  • X-StatusCode

  • The modified (by httrack) status code after processing. 304 error codes ("Not modified"), for example, are transformed into "200" codes after processing.
  • X-StatusMessage

  • The modified (by httrack) status message.
  • X-Size

  • The stored (either in cache, or in an external file) data size.
  • X-Charset

  • The original charset.
  • X-Addr

  • The original URL address part.
  • X-Fil

  • The original URL path part.
  • X-Save

  • The local filename, depending on user's "build structure" preferences.

Standard (RFC 2616) "useful" fields:
  • Content-Type
  • Last-Modified
  • Etag
  • Location
  • Content-Disposition

Specific fields in "BNF-like" grammar:
X-In-Cache          = "X-In-Cache" ":" 1*DIGIT
X-StatusCode        = "X-StatusCode" ":" 1*DIGIT
X-StatusMessage     = "X-StatusMessage" ":" *<TEXT, excluding CR, LF>
X-Size              = "X-Size" ":" 1*DIGIT
X-Charset           = "X-Charset" ":" value
X-Addr              = "X-Addr" ":" scheme ":" "//" authority
X-Fil               = "X-Fil" ":" rel_path
X-Save              = "X-Save" ":" rel_path
RFC standard fields:
Content-Type        = "Content-Type" ":" media-type
Last-Modified       = "Last-Modified" ":" HTTP-date
Etag                = "ETag" ":" entity-tag
Location            = "Location" ":" absoluteURI
Content-Disposition = "Content-Disposition" ":" disposition-type *( ";" disposition-parm )

And, for your information,
X-Reason-Phrase     = *<TEXT, with a maximum of 32 characters, and excluding CR, LF>
Note: Because the URLs may have an unexpected format, especially with double "/" inside, and other reserved characters ("?", "&" ..), various ZIP uncompressors can potentially have troubles accessing or decompressing the data. Libraries should generally handle this peculiar format, however.

httrack-3.49.5/html/addurl.html0000644000175000017500000001323114336470674013320 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

Add a URL


  1. Enter a typical Web address

  2. Just type in your address in the field



    OR

  3. Enter a Web address with authentication

  4. Useful when you need basic authentication to watch the Web page



    OR

  5. Capture a link from your Web browser to HTTrack

  6. Use this tool only for form-based pages (pages delivered after submiting a form) that need some analysis



    Set, as explained, your Web browser proxy preferences to the values indicated : set the proxy's address, and the proxy's port, then click on the button or link as you usually do in your Web browser.
    The temporary proxy, installed by HTTrack, will then capture the link and display a confirmation page.






Back to Home

httrack-3.49.5/html/abuse.html0000644000175000017500000005111714336470674013151 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
Open Source offline browser

For HTTrack users:


For webmasters having problems with bandwidth abuse / other abuses related to HTTrack:



Advice & what not to do

Please follow these common sense rules to avoid any network abuse


  • Do not overload the websites!

  • Downloading a site can overload it, if you have a fast pipe, or if you capture too many simultaneous cgi (dynamically generated pages).
    • Do not download too large websites: use filters
    • Do not use too many simultaneous connections
    • Use bandwidth limits
    • Use connection limits
    • Use size limits
    • Use time limits
    • Only disable robots.txt rules with great care
    • Try not to download during working hours
    • Check your mirror transfer rate/size
    • For large mirrors, first ask the webmaster of the site

  • Ensure that you can copy the website
    • Are the pages copyrighted?
    • Can you copy them only for private purpose?
    • Do not make online mirrors unless you are authorized to do so

  • Do not overload your network
    • Is your (corporate, private..) network connected through dialup ISP?
    • Is your network bandwidth limited (and expensive)?
    • Are you slowing down the traffic?

  • Do not steal private information
    • Do not grab emails
    • Do not grab private information


Abuse FAQ for webmasters

How to limit network abuse
HTTrack Website Copier FAQ (updated - DRAFT)


Q: How to block offline browsers, like HTTrack?

A: This is a complex question, let's study it

First, there are several different reasons for that
Why do you want to block offline browsers? :

  1. Because a large part of your bandwidth is used by some users, who are slowing down the rest
  2. Because of copyright questions (you do not want people to copy parts of your website)
  3. Because of privacy (you do not want email grabbers to steal all your user's emails)


  1. Bandwidth abuse:

    Many Webmasters are concerned about bandwidth abuse, even if this problem is caused by a minority of people. Offline browsers tools, like HTTrack, can be used in a WRONG way, and therefore are sometimes considered as a potential danger.
    But before thinking that all offline browsers are BAD, consider this: students, teachers, IT consultants, websurfers and many people who like your website, may want to copy parts of it, for their work, their studies, to teach or demonstrate to people during class school or shows. They might do that because they are connected through expensive modem connection, or because they would like to consult pages while travelling, or archive sites that may be removed one day, make some data mining, comiling information ("if only I could find this website I saw one day..").
    There are many good reasons to mirror websites, and this helps many good people.
    As a webmaster, you might be interested to use such tools, too: test broken links, move a website to another location, control which external links are put on your website for legal/content control, test the webserver response and performances, index it..

    Anyway, bandwidth abuse can be a problem. If your site is regularly "clobbered" by evil downloaders, you have
    various solutions. You have radical solutions, and intermediate solutions. I strongly recomment not to use
    radical solutions, because of the previous remarks (good people often mirror websites).

    In general, for all solutions,
    the good thing: it will limit the bandwidth abuse
    the bad thing: depending on the solution, it will be either a small constraint, or a fatal nuisance (you'll get 0 visitors)
    or, to be extreme: if you unplug the wire, there will be no bandwidth abuse

    1. Inform people, explain why ("please do not clobber the bandwidth")
      Good: Will work with good people. Many good people just don't KNOW that they can slow down a network.
      Bad: Will **only** work with good people
      How to do: Obvious - place a note, a warning, an article, a draw, a poeme or whatever you want

    2. Use "robots.txt" file
      Good: Easy to setup
      Bad: Easy to override
      How to do: Create a robots.txt file on top dir, with proper parameters
      Example:
          User-agent: *

          Disallow: /bigfolder

    3. Ban registered offline-browsers User-agents
      Good: Easy to setup
      Bad: Radical, and easy to override
      How to do: Filter the "User-agent" HTTP header field

    4. Limit the bandwidth per IP (or by folders)
      Good: Efficient
      Bad: Multiple users behind proxies will be slow down, not really easy to setup
      How to do: Depends on webserver. Might be done with low-level IP rules (QoS)

    5. Priorize small files, against large files
      Good: Efficient if large files are the cause of abuse
      Bad: Not always efficient
      How to do: Depends on the webserver

    6. Ban abuser IPs
      Good: Immediate solution
      Bad: Annoying to do, useless for dynamic IPs, and not very user friendly
      How to do: Either ban IP's on the firewall, or on the webserver (see ACLs)

    7. Limit abusers IPs
      Good: Intermediate and immediate solution
      Bad: Annoying to do, useless for dynamic IPs, and annoying to maintain..
      How to do: Use routine QoS (fair queuing), or webserver options

    8. Use technical tricks (like javascript) to hide URLs
      Good: Efficient
      Bad: The most efficient tricks will also cause your website to he heavy, and not user-friendly (and therefore less attractive, even for surfing users). Remember: clients or visitors might want to consult offline your website. Advanced users will also be still able to note the URLs and catch them. Will not work on non-javascript browsers. It will not work if the user clicks 50 times and put downloads in background with a standard browser
      How to do: Most offline browsers (I would say all, but let's say most) are unable to "understand" javascript/java properly. Reason: very tricky to handle!
      Example:
      You can replace:
          <a href="bigfile.zip">Foo</a>
      by:
          <script language="javascript">
          <!--
          document.write('<a h' + 're' + 'f="');
          document.write('bigfile' + '.' + 'zip">');
          // -->
          </script>
          Foo
          </a>

      You can also use java-based applets. I would say that it is the "best of the horrors". A big, fat, slow, bogus java applet. Avoid!

    9. Use technical tricks to lag offline browsers
      Good: Efficient
      Bad: Can be avoided by advanced users, annoying to maintain, AND potentially worst that the illness (cgi's are often taking some CPU usage). . It will not work if the user clicks 50 times and put downloads in background with a standard browser
      How to do: Create fake empty links that point to cgi's, with long delays
      Example: Use things like <ahref="slow.cgi?p=12786549"><nothing></a> (example in php:)
          <?php
          for($i=0;$i<10;$i++) {
              sleep(6);
              echo " ";
          }
          ?>

    10. Use technical tricks to temporarily ban IPs
      Good: Efficient
      Bad: Radical (your site will only be available online for all users), not easy to setup
      How to to: Create fake links with "killing" targets
      Example: Use things like <a href="killme.cgi"><nothing></a> (again an example in php:)
      <?php
      	// Add IP.
      	add_temp_firewall_rule($REMOTE_ADDR,"30s");
      ?>
      function add_temp_firewall_rule($addr) {
      	// The chain chhttp is flushed in a cron job to avoid ipchains overflow
          system("/usr/bin/sudo -u root /sbin/ipchains -I 1 chhttp -p tcp -s ".$addr." --dport 80 -j REJECT");
          syslog("user rejected due to too many copy attemps : ".$addr);
      }
      
      
      
      
      

  2. Copyright issues

    You do not want people to "steal" your website, or even copy parts of it. First, stealing a website does not
    require to have an offline browser. Second, direct (and credited) copy is sometimes better than disguised
    plagiarism. Besides, several previous remarks are also interesting here: the more protected your website will be,
    the potentially less attractive it will also be. There is no perfect solution, too. A webmaster asked me one day
    to give him a solution to prevent any website copy. Not only for offline browsers, but also against "save as",
    cut and paste, print.. and print screen. I replied that is was not possible, especially for the print screen - and
    that another potential threat was the evil photographer. Maybe with a "this document will self-destruct in 5 seconds.."
    or by shooting users after consulting the document.
    More seriously, once a document is being placed on a website, there will always be the risks of copy (or plagiarism)

    To limit the risk, previous a- and h- solutions, in "bandwidth abuse" section, can be used


  3. Privacy

    Might be related to section 2.
    But the greatest risk is maybe email grabbers.

    1. A solution can be to use javascript to hide emails.
      Good: Efficient
      Bad: Non-javascript browsers will not have the "clickable" link
      How to do: Use javascript to build mailto: links
      Example:
          <script language="javascript">
          <!--
          function FOS(host,nom,info) {
            var s;
            if (info == "") info=nom+"@"+host;
            s="mail";
            document.write("<a href='"+s+"to:"+nom+"@"+host+"'>"+info+"</a>");
          }
          FOS('mycompany.com','smith?subject=Hi, John','Click here to email me!')
          // -->
          </script>
          <noscript>
          smith at mycompany dot com
          </noscript>

    2. Another one is to create images of emails
      Good: Efficient, does not require javascript
      Bad: There is still the problem of the link (mailto:), images are bigger than text, and it can cause problems for blind people (a good solution is use an ALT attribute with the email written like "smith at mycompany dot com")
      How to do: Not so obvious of you do not want to create images by yourself
      Example: (php, Unix)
      <?php
      /*
      Email contact displayer
      Usage: email.php3?id=<4 bytes of user's md5>
      The <4 bytes of user's md5> can be calculated using the 2nd script (see below)
      Example: http://yourhost/email.php3?id=91ff1a48
      */
      $domain="mycompany.com";
      $size=12;

      /* Find the user in the system database */
      if (!$id)
        exit;
      unset($email);
      unset($name);
      unset($pwd);
      unset($apwd);
      $email="";
      $name="";
      $fp=@fopen("/etc/passwd","r");
      if ($fp) {
        $pwd=@fread($fp,filesize("/etc/passwd"));
        @fclose($fp);
      }
      $apwd=split("\n",$pwd);
      foreach($apwd as $line) {
        $fld=split(":",$line);
        if (substr(md5($fld[0]),0,8) == $id) {
          $email=$fld[0]."@".$domain;
          $nm=substr($fld[4],0,strpos($fld[4],","));
          $name=$email;
          if ($nm)
            $name="\"".$nm."\" <".$email.">";
        }
      }
      if (!$name)
        exit;

      /* Create and show the image */
      Header ("Content-type: image/gif");
      $im = imagecreate ($size*strlen($name), $size*1.5);
      $black = ImageColorAllocate ($im, 255, 255, 255);
      $white = ImageColorAllocate ($im, 0,0,0);
      ImageTTFText($im, $size, 0, 0, $size , $white, "/usr/share/enlightenment/E-docs/aircut3.ttf",$name);
      ImageGif ($im);
      ImageDestroy ($im);
      ?>

      The script to find the id:

      #!/bin/sh

      # small script for email.php3
      echo "Enter login:"
      read login
      echo "The URL is:"
      printf "http://yourhost/email.php3?id="
      printf $login|md5sum|cut -c1-8
      echo

    3. You can also create temporary email aliases, each week, for all users
      Good: Efficient, and you can give your real email in your reply-to address
      Bad: Temporary emails
      How to do: Not so hard todo
      Example: (script & php, Unix)
      #!/bin/sh
      #
      # Anonymous random aliases for all users
      # changed each week, to avoid spam problems
      # on websites
      # (to put into /etc/cron.weekly/)

      # Each alias is regenerated each week, and valid for 2 weeks

      # prefix for all users
      # must not be the prefix of another alias!
      USER_PREFIX="user-"

      # valid for 2 weeks
      ALIAS_VALID=2

      # random string
      SECRET="my secret string `hostname -f`"

      # build
      grep -vE "^$USER_PREFIX" /etc/aliases > /etc/aliases.new
      for i in `cut -f1 -d':' /etc/passwd`; do
        if test `id -u $i` -ge 500; then
          off=0
          while test "$off" -lt $ALIAS_VALID; do
            THISWEEK="`date +'%Y'` $[`date +'%U'`-$off]"
            SECRET="`echo \"$SECRET $i $THISWEEK\" | md5sum | cut -c1-4`"
            FIRST=`echo $i | cut -c1-3`
            NAME="$USER_PREFIX$FIRST$SECRET"
            echo "$NAME : $i" >> /etc/aliases.new
            #
            off=$[$off+1]
          done
        fi
      done

      # move file
      mv -f /etc/aliases /etc/aliases.old
      mv -f /etc/aliases.new /etc/aliases

      # update aliases
      newaliases

      And then, put the email address in your pages through:

      <a href="mailto:<?php
          $user="smith";
          $alias=exec("grep ".$user." /etc/aliases | cut -f1 -d' ' | head -n1");
          print $alias;
      ?>@mycompany.com>>

httrack-3.49.5/html/Makefile.in0000644000175000017500000007077514555203173013233 00000000000000# Makefile.in generated by automake 1.16.5 from Makefile.am. # @configure_input@ # Copyright (C) 1994-2021 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ VPATH = @srcdir@ am__is_gnu_make = { \ if test -z '$(MAKELEVEL)'; then \ false; \ elif test -n '$(MAKE_HOST)'; then \ true; \ elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ true; \ else \ false; \ fi; \ } am__make_running_with_option = \ case $${target_option-} in \ ?) ;; \ *) echo "am__make_running_with_option: internal error: invalid" \ "target option '$${target_option-}' specified" >&2; \ exit 1;; \ esac; \ has_opt=no; \ sane_makeflags=$$MAKEFLAGS; \ if $(am__is_gnu_make); then \ sane_makeflags=$$MFLAGS; \ else \ case $$MAKEFLAGS in \ *\\[\ \ ]*) \ bs=\\; \ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ esac; \ fi; \ skip_next=no; \ strip_trailopt () \ { \ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ }; \ for flg in $$sane_makeflags; do \ test $$skip_next = yes && { skip_next=no; continue; }; \ case $$flg in \ *=*|--*) continue;; \ -*I) strip_trailopt 'I'; skip_next=yes;; \ -*I?*) strip_trailopt 'I';; \ -*O) strip_trailopt 'O'; skip_next=yes;; \ -*O?*) strip_trailopt 'O';; \ -*l) strip_trailopt 'l'; skip_next=yes;; \ -*l?*) strip_trailopt 'l';; \ -[dEDm]) skip_next=yes;; \ -[JT]) skip_next=yes;; \ esac; \ case $$flg in \ *$$target_option*) has_opt=yes; break;; \ esac; \ done; \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkglibexecdir = $(libexecdir)/@PACKAGE@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ subdir = html ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/check_zlib.m4 \ $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/snprintf.m4 \ $(top_srcdir)/m4/visibility.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = AM_V_P = $(am__v_P_@AM_V@) am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) am__v_P_0 = false am__v_P_1 = : AM_V_GEN = $(am__v_GEN_@AM_V@) am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) am__v_GEN_0 = @echo " GEN " $@; am__v_GEN_1 = AM_V_at = $(am__v_at_@AM_V@) am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) am__v_at_0 = @ am__v_at_1 = SOURCES = DIST_SOURCES = am__can_run_installinfo = \ case $$AM_UPDATE_INFO_DIR in \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ *) f=$$p;; \ esac; am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; am__install_max = 40 am__nobase_strip_setup = \ srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` am__nobase_strip = \ for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" am__nobase_list = $(am__nobase_strip_setup); \ for p in $$list; do echo "$$p $$p"; done | \ sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ if (++n[$$2] == $(am__install_max)) \ { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ END { for (dir in files) print dir, files[dir] }' am__base_list = \ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' am__uninstall_files_from_dir = { \ test -z "$$files" \ || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ $(am__cd) "$$dir" && rm -f $$files; }; \ } am__installdirs = "$(DESTDIR)$(HelpHtmldir)" \ "$(DESTDIR)$(HelpHtmlTxtdir)" "$(DESTDIR)$(HelpHtmldivdir)" \ "$(DESTDIR)$(HelpHtmlimagesdir)" "$(DESTDIR)$(HelpHtmlimgdir)" \ "$(DESTDIR)$(HelpHtmlrootdir)" "$(DESTDIR)$(VFolderEntrydir)" \ "$(DESTDIR)$(WebHtmldir)" "$(DESTDIR)$(WebHtmlimagesdir)" \ "$(DESTDIR)$(WebIcon16x16dir)" "$(DESTDIR)$(WebIcon32x32dir)" \ "$(DESTDIR)$(WebIcon48x48dir)" "$(DESTDIR)$(WebPixmapdir)" DATA = $(HelpHtml_DATA) $(HelpHtmlTxt_DATA) $(HelpHtmldiv_DATA) \ $(HelpHtmlimages_DATA) $(HelpHtmlimg_DATA) \ $(HelpHtmlroot_DATA) $(VFolderEntry_DATA) $(WebHtml_DATA) \ $(WebHtmlimages_DATA) $(WebIcon16x16_DATA) \ $(WebIcon32x32_DATA) $(WebIcon48x48_DATA) $(WebPixmap_DATA) am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) am__DIST_COMMON = $(srcdir)/Makefile.in DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AM_CFLAGS = @AM_CFLAGS@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CFLAGS_PIE = @CFLAGS_PIE@ CFLAG_VISIBILITY = @CFLAG_VISIBILITY@ CPPFLAGS = @CPPFLAGS@ CSCOPE = @CSCOPE@ CTAGS = @CTAGS@ CYGPATH_W = @CYGPATH_W@ DEFAULT_CFLAGS = @DEFAULT_CFLAGS@ DEFAULT_LDFLAGS = @DEFAULT_LDFLAGS@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DLLTOOL = @DLLTOOL@ DL_LIBS = @DL_LIBS@ DSYMUTIL = @DSYMUTIL@ DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ ETAGS = @ETAGS@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ FILECMD = @FILECMD@ GREP = @GREP@ HAVE_VISIBILITY = @HAVE_VISIBILITY@ HTTPS_SUPPORT = @HTTPS_SUPPORT@ ICONV_LIBS = @ICONV_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LD = @LD@ LDFLAGS = @LDFLAGS@ LDFLAGS_PIE = @LDFLAGS_PIE@ LFS_FLAG = @LFS_FLAG@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ LIPO = @LIPO@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ LT_CV_OBJDIR = @LT_CV_OBJDIR@ LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ MAINT = @MAINT@ MAKEINFO = @MAKEINFO@ MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ NM = @NM@ NMEDIT = @NMEDIT@ OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ ONLINE_UNIT_TESTS = @ONLINE_UNIT_TESTS@ OPENSSL_LIBS = @OPENSSL_LIBS@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ RANLIB = @RANLIB@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ SHLIBPATH_VAR = @SHLIBPATH_VAR@ SOCKET_LIBS = @SOCKET_LIBS@ STRIP = @STRIP@ THREADS_CFLAGS = @THREADS_CFLAGS@ THREADS_LIBS = @THREADS_LIBS@ V6_FLAG = @V6_FLAG@ VERSION = @VERSION@ VERSION_INFO = @VERSION_INFO@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ builddir = @builddir@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ runstatedir = @runstatedir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ HelpHtmlrootdir = $(docdir) HelpHtmldir = $(htmldir) HelpHtmlimgdir = $(HelpHtmldir)/img HelpHtmldivdir = $(HelpHtmldir)/div HelpHtmlimagesdir = $(HelpHtmldir)/images HelpHtmlTxtdir = $(HelpHtmldir) WebHtmldir = $(HelpHtmldir)/server WebHtmlimagesdir = $(HelpHtmldir)/server/images WebPixmapdir = $(datadir)/pixmaps WebIcon16x16dir = $(datadir)/icons/hicolor/16x16/apps WebIcon32x32dir = $(datadir)/icons/hicolor/32x32/apps WebIcon48x48dir = $(datadir)/icons/hicolor/48x48/apps VFolderEntrydir = $(prefix)/share/applications HelpHtmlroot_DATA = ../httrack-doc.html ../history.txt HelpHtml_DATA = *.html HelpHtmldiv_DATA = div/search.sh HelpHtmlimg_DATA = img/* HelpHtmlimages_DATA = images/* HelpHtmlTxt_DATA = ../greetings.txt ../history.txt ../license.txt WebHtml_DATA = server/*.html server/*.js server/*.css WebHtmlimages_DATA = server/images/* # note: converted & normalized by # ico2xpm favicon.ico -o httrack.xpm # mogrify -format xpm -map /usr/share/doc/menu/examples/cmap.xpm httrack.xpm WebPixmap_DATA = server/div/*.xpm WebIcon16x16_DATA = server/div/16x16/*.png WebIcon32x32_DATA = server/div/32x32/*.png WebIcon48x48_DATA = server/div/48x48/*.png VFolderEntry_DATA = server/div/*.desktop EXTRA_DIST = $(HelpHtml_DATA) $(HelpHtmlimg_DATA) $(HelpHtmlimages_DATA) \ $(HelpHtmldiv_DATA) $(WebHtml_DATA) $(WebHtmlimages_DATA) \ $(WebPixmap_DATA) $(WebIcon16x16_DATA) $(WebIcon32x32_DATA) $(WebIcon48x48_DATA) \ $(VFolderEntry_DATA) \ httrack.css all: all-am .SUFFIXES: $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ && { if test -f $@; then exit 0; else break; fi; }; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu html/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --gnu html/Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(am__aclocal_m4_deps): mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs install-HelpHtmlDATA: $(HelpHtml_DATA) @$(NORMAL_INSTALL) @list='$(HelpHtml_DATA)'; test -n "$(HelpHtmldir)" || list=; \ if test -n "$$list"; then \ echo " $(MKDIR_P) '$(DESTDIR)$(HelpHtmldir)'"; \ $(MKDIR_P) "$(DESTDIR)$(HelpHtmldir)" || exit 1; \ fi; \ for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; \ done | $(am__base_list) | \ while read files; do \ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(HelpHtmldir)'"; \ $(INSTALL_DATA) $$files "$(DESTDIR)$(HelpHtmldir)" || exit $$?; \ done uninstall-HelpHtmlDATA: @$(NORMAL_UNINSTALL) @list='$(HelpHtml_DATA)'; test -n "$(HelpHtmldir)" || list=; \ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ dir='$(DESTDIR)$(HelpHtmldir)'; $(am__uninstall_files_from_dir) install-HelpHtmlTxtDATA: $(HelpHtmlTxt_DATA) @$(NORMAL_INSTALL) @list='$(HelpHtmlTxt_DATA)'; test -n "$(HelpHtmlTxtdir)" || list=; \ if test -n "$$list"; then \ echo " $(MKDIR_P) '$(DESTDIR)$(HelpHtmlTxtdir)'"; \ $(MKDIR_P) "$(DESTDIR)$(HelpHtmlTxtdir)" || exit 1; \ fi; \ for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; \ done | $(am__base_list) | \ while read files; do \ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(HelpHtmlTxtdir)'"; \ $(INSTALL_DATA) $$files "$(DESTDIR)$(HelpHtmlTxtdir)" || exit $$?; \ done uninstall-HelpHtmlTxtDATA: @$(NORMAL_UNINSTALL) @list='$(HelpHtmlTxt_DATA)'; test -n "$(HelpHtmlTxtdir)" || list=; \ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ dir='$(DESTDIR)$(HelpHtmlTxtdir)'; $(am__uninstall_files_from_dir) install-HelpHtmldivDATA: $(HelpHtmldiv_DATA) @$(NORMAL_INSTALL) @list='$(HelpHtmldiv_DATA)'; test -n "$(HelpHtmldivdir)" || list=; \ if test -n "$$list"; then \ echo " $(MKDIR_P) '$(DESTDIR)$(HelpHtmldivdir)'"; \ $(MKDIR_P) "$(DESTDIR)$(HelpHtmldivdir)" || exit 1; \ fi; \ for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; \ done | $(am__base_list) | \ while read files; do \ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(HelpHtmldivdir)'"; \ $(INSTALL_DATA) $$files "$(DESTDIR)$(HelpHtmldivdir)" || exit $$?; \ done uninstall-HelpHtmldivDATA: @$(NORMAL_UNINSTALL) @list='$(HelpHtmldiv_DATA)'; test -n "$(HelpHtmldivdir)" || list=; \ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ dir='$(DESTDIR)$(HelpHtmldivdir)'; $(am__uninstall_files_from_dir) install-HelpHtmlimagesDATA: $(HelpHtmlimages_DATA) @$(NORMAL_INSTALL) @list='$(HelpHtmlimages_DATA)'; test -n "$(HelpHtmlimagesdir)" || list=; \ if test -n "$$list"; then \ echo " $(MKDIR_P) '$(DESTDIR)$(HelpHtmlimagesdir)'"; \ $(MKDIR_P) "$(DESTDIR)$(HelpHtmlimagesdir)" || exit 1; \ fi; \ for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; \ done | $(am__base_list) | \ while read files; do \ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(HelpHtmlimagesdir)'"; \ $(INSTALL_DATA) $$files "$(DESTDIR)$(HelpHtmlimagesdir)" || exit $$?; \ done uninstall-HelpHtmlimagesDATA: @$(NORMAL_UNINSTALL) @list='$(HelpHtmlimages_DATA)'; test -n "$(HelpHtmlimagesdir)" || list=; \ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ dir='$(DESTDIR)$(HelpHtmlimagesdir)'; $(am__uninstall_files_from_dir) install-HelpHtmlimgDATA: $(HelpHtmlimg_DATA) @$(NORMAL_INSTALL) @list='$(HelpHtmlimg_DATA)'; test -n "$(HelpHtmlimgdir)" || list=; \ if test -n "$$list"; then \ echo " $(MKDIR_P) '$(DESTDIR)$(HelpHtmlimgdir)'"; \ $(MKDIR_P) "$(DESTDIR)$(HelpHtmlimgdir)" || exit 1; \ fi; \ for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; \ done | $(am__base_list) | \ while read files; do \ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(HelpHtmlimgdir)'"; \ $(INSTALL_DATA) $$files "$(DESTDIR)$(HelpHtmlimgdir)" || exit $$?; \ done uninstall-HelpHtmlimgDATA: @$(NORMAL_UNINSTALL) @list='$(HelpHtmlimg_DATA)'; test -n "$(HelpHtmlimgdir)" || list=; \ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ dir='$(DESTDIR)$(HelpHtmlimgdir)'; $(am__uninstall_files_from_dir) install-HelpHtmlrootDATA: $(HelpHtmlroot_DATA) @$(NORMAL_INSTALL) @list='$(HelpHtmlroot_DATA)'; test -n "$(HelpHtmlrootdir)" || list=; \ if test -n "$$list"; then \ echo " $(MKDIR_P) '$(DESTDIR)$(HelpHtmlrootdir)'"; \ $(MKDIR_P) "$(DESTDIR)$(HelpHtmlrootdir)" || exit 1; \ fi; \ for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; \ done | $(am__base_list) | \ while read files; do \ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(HelpHtmlrootdir)'"; \ $(INSTALL_DATA) $$files "$(DESTDIR)$(HelpHtmlrootdir)" || exit $$?; \ done uninstall-HelpHtmlrootDATA: @$(NORMAL_UNINSTALL) @list='$(HelpHtmlroot_DATA)'; test -n "$(HelpHtmlrootdir)" || list=; \ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ dir='$(DESTDIR)$(HelpHtmlrootdir)'; $(am__uninstall_files_from_dir) install-VFolderEntryDATA: $(VFolderEntry_DATA) @$(NORMAL_INSTALL) @list='$(VFolderEntry_DATA)'; test -n "$(VFolderEntrydir)" || list=; \ if test -n "$$list"; then \ echo " $(MKDIR_P) '$(DESTDIR)$(VFolderEntrydir)'"; \ $(MKDIR_P) "$(DESTDIR)$(VFolderEntrydir)" || exit 1; \ fi; \ for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; \ done | $(am__base_list) | \ while read files; do \ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(VFolderEntrydir)'"; \ $(INSTALL_DATA) $$files "$(DESTDIR)$(VFolderEntrydir)" || exit $$?; \ done uninstall-VFolderEntryDATA: @$(NORMAL_UNINSTALL) @list='$(VFolderEntry_DATA)'; test -n "$(VFolderEntrydir)" || list=; \ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ dir='$(DESTDIR)$(VFolderEntrydir)'; $(am__uninstall_files_from_dir) install-WebHtmlDATA: $(WebHtml_DATA) @$(NORMAL_INSTALL) @list='$(WebHtml_DATA)'; test -n "$(WebHtmldir)" || list=; \ if test -n "$$list"; then \ echo " $(MKDIR_P) '$(DESTDIR)$(WebHtmldir)'"; \ $(MKDIR_P) "$(DESTDIR)$(WebHtmldir)" || exit 1; \ fi; \ for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; \ done | $(am__base_list) | \ while read files; do \ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(WebHtmldir)'"; \ $(INSTALL_DATA) $$files "$(DESTDIR)$(WebHtmldir)" || exit $$?; \ done uninstall-WebHtmlDATA: @$(NORMAL_UNINSTALL) @list='$(WebHtml_DATA)'; test -n "$(WebHtmldir)" || list=; \ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ dir='$(DESTDIR)$(WebHtmldir)'; $(am__uninstall_files_from_dir) install-WebHtmlimagesDATA: $(WebHtmlimages_DATA) @$(NORMAL_INSTALL) @list='$(WebHtmlimages_DATA)'; test -n "$(WebHtmlimagesdir)" || list=; \ if test -n "$$list"; then \ echo " $(MKDIR_P) '$(DESTDIR)$(WebHtmlimagesdir)'"; \ $(MKDIR_P) "$(DESTDIR)$(WebHtmlimagesdir)" || exit 1; \ fi; \ for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; \ done | $(am__base_list) | \ while read files; do \ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(WebHtmlimagesdir)'"; \ $(INSTALL_DATA) $$files "$(DESTDIR)$(WebHtmlimagesdir)" || exit $$?; \ done uninstall-WebHtmlimagesDATA: @$(NORMAL_UNINSTALL) @list='$(WebHtmlimages_DATA)'; test -n "$(WebHtmlimagesdir)" || list=; \ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ dir='$(DESTDIR)$(WebHtmlimagesdir)'; $(am__uninstall_files_from_dir) install-WebIcon16x16DATA: $(WebIcon16x16_DATA) @$(NORMAL_INSTALL) @list='$(WebIcon16x16_DATA)'; test -n "$(WebIcon16x16dir)" || list=; \ if test -n "$$list"; then \ echo " $(MKDIR_P) '$(DESTDIR)$(WebIcon16x16dir)'"; \ $(MKDIR_P) "$(DESTDIR)$(WebIcon16x16dir)" || exit 1; \ fi; \ for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; \ done | $(am__base_list) | \ while read files; do \ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(WebIcon16x16dir)'"; \ $(INSTALL_DATA) $$files "$(DESTDIR)$(WebIcon16x16dir)" || exit $$?; \ done uninstall-WebIcon16x16DATA: @$(NORMAL_UNINSTALL) @list='$(WebIcon16x16_DATA)'; test -n "$(WebIcon16x16dir)" || list=; \ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ dir='$(DESTDIR)$(WebIcon16x16dir)'; $(am__uninstall_files_from_dir) install-WebIcon32x32DATA: $(WebIcon32x32_DATA) @$(NORMAL_INSTALL) @list='$(WebIcon32x32_DATA)'; test -n "$(WebIcon32x32dir)" || list=; \ if test -n "$$list"; then \ echo " $(MKDIR_P) '$(DESTDIR)$(WebIcon32x32dir)'"; \ $(MKDIR_P) "$(DESTDIR)$(WebIcon32x32dir)" || exit 1; \ fi; \ for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; \ done | $(am__base_list) | \ while read files; do \ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(WebIcon32x32dir)'"; \ $(INSTALL_DATA) $$files "$(DESTDIR)$(WebIcon32x32dir)" || exit $$?; \ done uninstall-WebIcon32x32DATA: @$(NORMAL_UNINSTALL) @list='$(WebIcon32x32_DATA)'; test -n "$(WebIcon32x32dir)" || list=; \ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ dir='$(DESTDIR)$(WebIcon32x32dir)'; $(am__uninstall_files_from_dir) install-WebIcon48x48DATA: $(WebIcon48x48_DATA) @$(NORMAL_INSTALL) @list='$(WebIcon48x48_DATA)'; test -n "$(WebIcon48x48dir)" || list=; \ if test -n "$$list"; then \ echo " $(MKDIR_P) '$(DESTDIR)$(WebIcon48x48dir)'"; \ $(MKDIR_P) "$(DESTDIR)$(WebIcon48x48dir)" || exit 1; \ fi; \ for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; \ done | $(am__base_list) | \ while read files; do \ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(WebIcon48x48dir)'"; \ $(INSTALL_DATA) $$files "$(DESTDIR)$(WebIcon48x48dir)" || exit $$?; \ done uninstall-WebIcon48x48DATA: @$(NORMAL_UNINSTALL) @list='$(WebIcon48x48_DATA)'; test -n "$(WebIcon48x48dir)" || list=; \ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ dir='$(DESTDIR)$(WebIcon48x48dir)'; $(am__uninstall_files_from_dir) install-WebPixmapDATA: $(WebPixmap_DATA) @$(NORMAL_INSTALL) @list='$(WebPixmap_DATA)'; test -n "$(WebPixmapdir)" || list=; \ if test -n "$$list"; then \ echo " $(MKDIR_P) '$(DESTDIR)$(WebPixmapdir)'"; \ $(MKDIR_P) "$(DESTDIR)$(WebPixmapdir)" || exit 1; \ fi; \ for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; \ done | $(am__base_list) | \ while read files; do \ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(WebPixmapdir)'"; \ $(INSTALL_DATA) $$files "$(DESTDIR)$(WebPixmapdir)" || exit $$?; \ done uninstall-WebPixmapDATA: @$(NORMAL_UNINSTALL) @list='$(WebPixmap_DATA)'; test -n "$(WebPixmapdir)" || list=; \ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ dir='$(DESTDIR)$(WebPixmapdir)'; $(am__uninstall_files_from_dir) tags TAGS: ctags CTAGS: cscope cscopelist: distdir: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) distdir-am distdir-am: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ dist_files=`for file in $$list; do echo $$file; done | \ sed -e "s|^$$srcdirstrip/||;t" \ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ case $$dist_files in \ */*) $(MKDIR_P) `echo "$$dist_files" | \ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ sort -u` ;; \ esac; \ for file in $$dist_files; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ if test -d $$d/$$file; then \ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ if test -d "$(distdir)/$$file"; then \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ else \ test -f "$(distdir)/$$file" \ || cp -p $$d/$$file "$(distdir)/$$file" \ || exit 1; \ fi; \ done check-am: all-am check: check-am all-am: Makefile $(DATA) installdirs: for dir in "$(DESTDIR)$(HelpHtmldir)" "$(DESTDIR)$(HelpHtmlTxtdir)" "$(DESTDIR)$(HelpHtmldivdir)" "$(DESTDIR)$(HelpHtmlimagesdir)" "$(DESTDIR)$(HelpHtmlimgdir)" "$(DESTDIR)$(HelpHtmlrootdir)" "$(DESTDIR)$(VFolderEntrydir)" "$(DESTDIR)$(WebHtmldir)" "$(DESTDIR)$(WebHtmlimagesdir)" "$(DESTDIR)$(WebIcon16x16dir)" "$(DESTDIR)$(WebIcon32x32dir)" "$(DESTDIR)$(WebIcon48x48dir)" "$(DESTDIR)$(WebPixmapdir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-am install-strip: if test -z '$(STRIP)'; then \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ install; \ else \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ fi mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-generic clean-libtool mostlyclean-am distclean: distclean-am -rm -f Makefile distclean-am: clean-am distclean-generic dvi: dvi-am dvi-am: html: html-am html-am: info: info-am info-am: install-data-am: install-HelpHtmlDATA install-HelpHtmlTxtDATA \ install-HelpHtmldivDATA install-HelpHtmlimagesDATA \ install-HelpHtmlimgDATA install-HelpHtmlrootDATA \ install-VFolderEntryDATA install-WebHtmlDATA \ install-WebHtmlimagesDATA install-WebIcon16x16DATA \ install-WebIcon32x32DATA install-WebIcon48x48DATA \ install-WebPixmapDATA @$(NORMAL_INSTALL) $(MAKE) $(AM_MAKEFLAGS) install-data-hook install-dvi: install-dvi-am install-dvi-am: install-exec-am: install-html: install-html-am install-html-am: install-info: install-info-am install-info-am: install-man: install-pdf: install-pdf-am install-pdf-am: install-ps: install-ps-am install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-am -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-generic mostlyclean-libtool pdf: pdf-am pdf-am: ps: ps-am ps-am: uninstall-am: uninstall-HelpHtmlDATA uninstall-HelpHtmlTxtDATA \ uninstall-HelpHtmldivDATA uninstall-HelpHtmlimagesDATA \ uninstall-HelpHtmlimgDATA uninstall-HelpHtmlrootDATA \ uninstall-VFolderEntryDATA uninstall-WebHtmlDATA \ uninstall-WebHtmlimagesDATA uninstall-WebIcon16x16DATA \ uninstall-WebIcon32x32DATA uninstall-WebIcon48x48DATA \ uninstall-WebPixmapDATA .MAKE: install-am install-data-am install-strip .PHONY: all all-am check check-am clean clean-generic clean-libtool \ cscopelist-am ctags-am distclean distclean-generic \ distclean-libtool distdir dvi dvi-am html html-am info info-am \ install install-HelpHtmlDATA install-HelpHtmlTxtDATA \ install-HelpHtmldivDATA install-HelpHtmlimagesDATA \ install-HelpHtmlimgDATA install-HelpHtmlrootDATA \ install-VFolderEntryDATA install-WebHtmlDATA \ install-WebHtmlimagesDATA install-WebIcon16x16DATA \ install-WebIcon32x32DATA install-WebIcon48x48DATA \ install-WebPixmapDATA install-am install-data install-data-am \ install-data-hook install-dvi install-dvi-am install-exec \ install-exec-am install-html install-html-am install-info \ install-info-am install-man install-pdf install-pdf-am \ install-ps install-ps-am install-strip installcheck \ installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-generic \ mostlyclean-libtool pdf pdf-am ps ps-am tags-am uninstall \ uninstall-HelpHtmlDATA uninstall-HelpHtmlTxtDATA \ uninstall-HelpHtmldivDATA uninstall-HelpHtmlimagesDATA \ uninstall-HelpHtmlimgDATA uninstall-HelpHtmlrootDATA \ uninstall-VFolderEntryDATA uninstall-WebHtmlDATA \ uninstall-WebHtmlimagesDATA uninstall-WebIcon16x16DATA \ uninstall-WebIcon32x32DATA uninstall-WebIcon48x48DATA \ uninstall-WebPixmapDATA uninstall-am .PRECIOUS: Makefile install-data-hook: if test ! -L $(DESTDIR)$(prefix)/share/httrack/html ; then \ ( cd $(DESTDIR)$(prefix)/share/httrack \ && $(LN_S) $(htmldir) html \ ) \ fi # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: httrack-3.49.5/html/Makefile.am0000755000175000017500000000313514336470674013220 00000000000000 HelpHtmlrootdir = $(docdir) HelpHtmldir = $(htmldir) HelpHtmlimgdir = $(HelpHtmldir)/img HelpHtmldivdir = $(HelpHtmldir)/div HelpHtmlimagesdir = $(HelpHtmldir)/images HelpHtmlTxtdir = $(HelpHtmldir) WebHtmldir = $(HelpHtmldir)/server WebHtmlimagesdir = $(HelpHtmldir)/server/images WebPixmapdir = $(datadir)/pixmaps WebIcon16x16dir = $(datadir)/icons/hicolor/16x16/apps WebIcon32x32dir = $(datadir)/icons/hicolor/32x32/apps WebIcon48x48dir = $(datadir)/icons/hicolor/48x48/apps VFolderEntrydir = $(prefix)/share/applications HelpHtmlroot_DATA = ../httrack-doc.html ../history.txt HelpHtml_DATA = *.html HelpHtmldiv_DATA = div/search.sh HelpHtmlimg_DATA = img/* HelpHtmlimages_DATA = images/* HelpHtmlTxt_DATA = ../greetings.txt ../history.txt ../license.txt WebHtml_DATA = server/*.html server/*.js server/*.css WebHtmlimages_DATA = server/images/* # note: converted & normalized by # ico2xpm favicon.ico -o httrack.xpm # mogrify -format xpm -map /usr/share/doc/menu/examples/cmap.xpm httrack.xpm WebPixmap_DATA = server/div/*.xpm WebIcon16x16_DATA = server/div/16x16/*.png WebIcon32x32_DATA = server/div/32x32/*.png WebIcon48x48_DATA = server/div/48x48/*.png VFolderEntry_DATA = server/div/*.desktop EXTRA_DIST = $(HelpHtml_DATA) $(HelpHtmlimg_DATA) $(HelpHtmlimages_DATA) \ $(HelpHtmldiv_DATA) $(WebHtml_DATA) $(WebHtmlimages_DATA) \ $(WebPixmap_DATA) $(WebIcon16x16_DATA) $(WebIcon32x32_DATA) $(WebIcon48x48_DATA) \ $(VFolderEntry_DATA) \ httrack.css install-data-hook: if test ! -L $(DESTDIR)$(prefix)/share/httrack/html ; then \ ( cd $(DESTDIR)$(prefix)/share/httrack \ && $(LN_S) $(htmldir) html \ ) \ fi httrack-3.49.5/html/server/0000755000175000017500000000000014555203200012523 500000000000000httrack-3.49.5/html/server/style.css0000644000175000017500000000400614336470674014337 00000000000000body { margin: 0; padding: 0; margin-bottom: 15px; margin-top: 8px; background: #77b; } body, td { font: 14px "Trebuchet MS", Verdana, Arial, Helvetica, sans-serif; } #subTitle { background: #000; color: #fff; padding: 4px; font-weight: bold; } .tabCtrl { background: #000; color: #fff; padding: 4px; font-weight: bold; } #siteNavigation a, #siteNavigation .current { font-weight: bold; color: #448; } #siteNavigation a:link { text-decoration: none; } #siteNavigation a:visited { text-decoration: none; } #siteNavigation .current { background-color: #ccd; } #siteNavigation a:hover { text-decoration: none; background-color: #fff; color: #000; } #siteNavigation a:active { text-decoration: none; background-color: #ccc; } a:link { text-decoration: underline; color: #00f; } a:visited { text-decoration: underline; color: #000; } a:hover { text-decoration: underline; color: #c00; } a:active { text-decoration: underline; } #pageContent { clear: both; border-bottom: 6px solid #000; padding: 10px; padding-top: 20px; line-height: 1.65em; background-image: url(images/bg_rings.gif); background-repeat: no-repeat; background-position: top right; } #pageContent, #siteNavigation { background-color: #ccd; } .imgLeft { float: left; margin-right: 10px; margin-bottom: 10px; } .imgRight { float: right; margin-left: 10px; margin-bottom: 10px; } hr { height: 1px; color: #000; background-color: #000; margin-bottom: 15px; } h1 { margin: 0; font-weight: bold; font-size: 2em; } h2 { margin: 0; font-weight: bold; font-size: 1.6em; } h3 { margin: 0; font-weight: bold; font-size: 1.3em; } h4 { margin: 0; font-weight: bold; font-size: 1.18em; } .blak { background-color: #000; } .hide { display: none; } .tableWidth { min-width: 400px; } .tblRegular { border-collapse: collapse; } .tblRegular td { padding: 6px; background-image: url(images/fade.gif); border: 2px solid #99c; } .tblHeaderColor, .tblHeaderColor td { background: #99c; } .tblNoBorder td { border: 0; } httrack-3.49.5/html/server/ping.js0000644000175000017500000000161014336470674013756 00000000000000// Function aimed to ping the webhttrack server regularly to keep it alive // If the browser window is closed, the server will eventually shutdown function ping_server() { var iframe = document.getElementById('pingiframe'); if (iframe && iframe.src) { iframe.src = iframe.src; setTimeout(ping_server, 30000); } } // Create an invisible iframe to hold the server ping result // Only modern browsers will support that, but old browsers are compatible // with the legacy "wait for browser PID" mode if (document && document.createElement && document.body && document.body.appendChild && document.getElementById) { var iframe = document.createElement('iframe'); if (iframe) { iframe.id = 'pingiframe'; iframe.style.display = "none"; iframe.style.visibility = "hidden"; iframe.width = iframe.height = 0; iframe.src = "/ping"; document.body.appendChild(iframe); ping_server(); } } httrack-3.49.5/html/server/step4.html0000644000175000017500000002262414336470674014420 00000000000000 '${projname}' - HTTrack Website Copier
HTTrack Website Copier
${/* show help only if available */} ${do:if-file-exists:html/index.html} ${do:end-if}
${LANG_OSFWB} ${LANG_O1} | ${LANG_O5}
${/* show help only if available */} ${do:if-file-exists:html/index.html} ${do:end-if}

Start

${LANG_TIPHELP}

${LANG_J10}
${LANG_J10b}
${/* Real commands and ini file generated below */} ${do:output-mode:html} ${do:output-mode:inifile} ${do:output-mode:} ${do:output-mode:inifile} ${do:output-mode:}
httrack-3.49.5/html/server/step3.html0000644000175000017500000001422614336470674014416 00000000000000 '${projname}' - HTTrack Website Copier
HTTrack Website Copier
${/* show help only if available */} ${do:if-file-exists:html/index.html} ${do:end-if}
${LANG_OSFWB} ${LANG_O1} | ${LANG_O5}
${/* show help only if available */} ${do:if-file-exists:html/index.html} ${do:end-if}

Select URLs

${LANG_TIPHELP}

${LANG_G31}
${LANG_G44}

${LANG_URLLIST}:
${LANG_G41}
httrack-3.49.5/html/server/step2.html0000644000175000017500000002026114336470674014411 00000000000000 '${projname}' - HTTrack Website Copier
HTTrack Website Copier
${/* show help only if available */} ${do:if-file-exists:html/index.html} ${do:end-if}
${LANG_OSFWB} ${LANG_O1} | ${LANG_O5}
${/* show help only if available */} ${do:if-file-exists:html/index.html} ${do:end-if}

${fexist:index.html:LANG_G42}

${LANG_TIPHELP}
${/* Default values for empty settings */} ${do:set:cache:1} ${/* Convert winprofile.ini into internal variables */} ${do:copy:CurrentUrl:urls} ${do:copy:Category:projcateg} ${do:copy:CurrentAction:todo} ${do:copy:CurrentURLList:filelist} ${do:copy:Proxy:proxy} ${do:copy:Port:port} ${do:copy:Near:link} ${do:copy:Test:testall} ${do:copy:ParseAll:parseall} ${do:copy:HTMLFirst:htmlfirst} ${do:copy:Cache:cache} ${do:copy:NoRecatch:norecatch} ${do:copy:Dos:dos} ${do:copy:Index:index} ${do:copy:WordIndex:index2} ${do:copy:Log:logf} ${do:copy:RemoveTimeout:remt} ${do:copy:RemoveRateout:rems} ${do:copy:KeepAlive:ka} ${do:copy:FollowRobotsTxt:robots} ${do:copy:NoErrorPages:errpage} ${do:copy:NoExternalPages:external} ${do:copy:NoPwdInPages:hidepwd} ${do:copy:NoQueryStrings:hidequery} ${do:copy:NoPurgeOldFiles:nopurge} ${do:copy:Cookies:cookies} ${do:copy:CheckType:checktype} ${do:copy:ParseJava:parsejava} ${do:copy:HTTP10:http10} ${do:copy:TolerantRequests:toler} ${do:copy:UpdateHack:updhack} ${do:copy:URLHack:urlhack} ${do:copy:StoreAllInCache:cache2} ${do:copy:LogType:logtype} ${do:copy:UseHTTPProxyForFTP:ftpprox} ${do:copy:Build:build} ${do:copy:PrimaryScan:filter} ${do:copy:Travel:travel} ${do:copy:GlobalTravel:travel2} ${do:copy:RewriteLinks:travel3} ${do:copy:BuildString:BuildString} ${do:copy:MaxHtml:maxhtml} ${do:copy:MaxOther:othermax} ${do:copy:MaxAll:sizemax} ${do:copy:MaxWait:pausebytes} ${do:copy:Sockets:connexion} ${do:copy:Retry:retry} ${do:copy:MaxTime:maxtime} ${do:copy:TimeOut:timeout} ${do:copy:RateOut:rate} ${do:copy:UserID:user} ${do:copy:Footer:footer} ${do:copy:MaxRate:maxrate} ${do:copy:WildCardFilters:url2} ${do:copy:Proxy:proxy} ${do:copy:Port:port} ${do:copy:Depth:depth} ${do:copy:ExtDepth:depth2} ${do:copy:MaxConn:maxconn} ${do:copy:MaxLinks:maxlinks} ${do:copy:MIMEDefsExt1:ext1} ${do:copy:MIMEDefsExt2:ext2} ${do:copy:MIMEDefsExt3:ext3} ${do:copy:MIMEDefsExt4:ext4} ${do:copy:MIMEDefsExt5:ext5} ${do:copy:MIMEDefsExt6:ext6} ${do:copy:MIMEDefsExt7:ext7} ${do:copy:MIMEDefsExt8:ext8} ${do:copy:MIMEDefsMime1:mime1} ${do:copy:MIMEDefsMime2:mime2} ${do:copy:MIMEDefsMime3:mime3} ${do:copy:MIMEDefsMime4:mime4} ${do:copy:MIMEDefsMime5:mime5} ${do:copy:MIMEDefsMime6:mime6} ${do:copy:MIMEDefsMime7:mime7} ${do:copy:MIMEDefsMime8:mime8} ${/* End convert winprofile.ini into internal variables */}
${do:if-project-file-exists:/hts-cache/winprofile.ini} ${do:end-if} ${do:if-project-file-exists:/hts-in_progress.lock} ${do:end-if}
${do:loadhash} ${LANG_S11b}
${LANG_S11}
${LANG_S13}

${LANG_S12}
${do:if-not-empty:urls}

${LANG_URLS}:


${urls}


${do:end-if:}
httrack-3.49.5/html/server/refresh.html0000644000175000017500000002305314336470674015014 00000000000000 '${projname}' - HTTrack Website Copier
HTTrack Website Copier
${/* show help only if available */} ${do:if-file-exists:html/index.html} ${do:end-if}
${LANG_OSFWB} ${LANG_O1} | ${LANG_O5}

${LANG_H20}


${LANG_H8}${info.stat_bytes} ${LANG_H9}${info.lien_n}/${info.lien_tot} (+${info.stat_back})
${LANG_H10}${info.stat_time_str} ${LANG_H17}${info.stat_written}
${LANG_H14}${info.irate} (${info.rate}) ${LANG_H18}${info.stat_updated}
${LANG_H11}${info.stat_nsocket} ${LANG_H19}${info.stat_errors}

${LANG_H20} ${info.currentjob}

${info.state[0]}${info.name[0]}${info.file[0]}${info.size[0]}/${info.sizetot[0]}
${info.state[1]}${info.name[1]}${info.file[1]}${info.size[1]}/${info.sizetot[1]}
${info.state[2]}${info.name[2]}${info.file[2]}${info.size[2]}/${info.sizetot[2]}
${info.state[3]}${info.name[3]}${info.file[3]}${info.size[3]}/${info.sizetot[3]}
${info.state[4]}${info.name[4]}${info.file[4]}${info.size[4]}/${info.sizetot[4]}
${info.state[5]}${info.name[5]}${info.file[5]}${info.size[5]}/${info.sizetot[5]}
${info.state[6]}${info.name[6]}${info.file[6]}${info.size[6]}/${info.sizetot[6]}
${info.state[7]}${info.name[7]}${info.file[7]}${info.size[7]}/${info.sizetot[7]}
${info.state[8]}${info.name[8]}${info.file[8]}${info.size[8]}/${info.sizetot[8]}
${info.state[9]}${info.name[9]}${info.file[9]}${info.size[9]}/${info.sizetot[9]}
${info.state[10]}${info.name[10]}${info.file[10]}${info.size[10]}/${info.sizetot[10]}
${info.state[11]}${info.name[11]}${info.file[11]}${info.size[11]}/${info.sizetot[11]}
${info.state[12]}${info.name[12]}${info.file[12]}${info.size[12]}/${info.sizetot[12]}
${info.state[13]}${info.name[13]}${info.file[13]}${info.size[13]}/${info.sizetot[13]}
 
httrack-3.49.5/html/server/option9.html0000644000175000017500000001727114336470674014764 00000000000000 '${projname}' - HTTrack Website Copier
HTTrack Website Copier
${LANG_OSFWB}
${/* show help only if available */} ${do:if-file-exists:html/index.html} ${do:end-if}

${LANG_O2} - ${LANG_IOPT9}

${LANG_TIPHELP}

${LANG_IOPT1} ${LANG_IOPT2} ${LANG_IOPT3} ${LANG_IOPT4} ${LANG_IOPT5} ${LANG_IOPT11}
${LANG_IOPT6} ${LANG_IOPT7} ${LANG_IOPT8} ${LANG_IOPT9} ${LANG_IOPT10}  


${LANG_I61}

${LANG_I34b}

${LANG_I36}

${LANG_I35}

${LANG_I35b}

httrack-3.49.5/html/server/option8.html0000644000175000017500000002011614336470674014753 00000000000000 '${projname}' - HTTrack Website Copier
HTTrack Website Copier
${LANG_OSFWB}
${/* show help only if available */} ${do:if-file-exists:html/index.html} ${do:end-if}

${LANG_O2} - ${LANG_IOPT8}

${LANG_TIPHELP}

${LANG_IOPT1} ${LANG_IOPT2} ${LANG_IOPT3} ${LANG_IOPT4} ${LANG_IOPT5} ${LANG_IOPT11}
${LANG_IOPT6} ${LANG_IOPT7} ${LANG_IOPT8} ${LANG_IOPT9} ${LANG_IOPT10}  


${LANG_I58}

${LANG_I59}


${LANG_I60}

${LANG_I55}


${LANG_I62b}

${LANG_I62b2}

${LANG_I62}

${LANG_I63}

httrack-3.49.5/html/server/option7.html0000644000175000017500000001560014336470674014754 00000000000000 '${projname}' - HTTrack Website Copier
HTTrack Website Copier
${LANG_OSFWB}
${/* show help only if available */} ${do:if-file-exists:html/index.html} ${do:end-if}

${LANG_O2} - ${LANG_IOPT7}

${LANG_TIPHELP}

${LANG_IOPT1} ${LANG_IOPT2} ${LANG_IOPT3} ${LANG_IOPT4} ${LANG_IOPT5} ${LANG_IOPT11}
${LANG_IOPT6} ${LANG_IOPT7} ${LANG_IOPT8} ${LANG_IOPT9} ${LANG_IOPT10}  


${LANG_B10}
${LANG_B13}
httrack-3.49.5/html/server/option6.html0000644000175000017500000001614414336470674014757 00000000000000 '${projname}' - HTTrack Website Copier
HTTrack Website Copier
${LANG_OSFWB}
${/* show help only if available */} ${do:if-file-exists:html/index.html} ${do:end-if}

${LANG_O2} - ${LANG_IOPT6}

${LANG_TIPHELP}

${LANG_IOPT1} ${LANG_IOPT2} ${LANG_IOPT3} ${LANG_IOPT4} ${LANG_IOPT5} ${LANG_IOPT11}
${LANG_IOPT6} ${LANG_IOPT7} ${LANG_IOPT8} ${LANG_IOPT9} ${LANG_IOPT10}  


${LANG_I43}
${LANG_I43b}
httrack-3.49.5/html/server/option5.html0000644000175000017500000002115314336470674014752 00000000000000 '${projname}' - HTTrack Website Copier
HTTrack Website Copier
${LANG_OSFWB}
${/* show help only if available */} ${do:if-file-exists:html/index.html} ${do:end-if}

${LANG_O2} - ${LANG_IOPT5}

${LANG_TIPHELP}

${LANG_IOPT1} ${LANG_IOPT2} ${LANG_IOPT3} ${LANG_IOPT4} ${LANG_IOPT5} ${LANG_IOPT11}
${LANG_IOPT6} ${LANG_IOPT7} ${LANG_IOPT8} ${LANG_IOPT9} ${LANG_IOPT10}  


${LANG_G32}
${LANG_G32b}
${LANG_I50}
${LANG_I50b}
${LANG_I51}
${LANG_I65}
${LANG_I52}
${LANG_I54}
${LANG_I64}
${LANG_I64b}
httrack-3.49.5/html/server/option4.html0000644000175000017500000002003214336470674014744 00000000000000 '${projname}' - HTTrack Website Copier
HTTrack Website Copier
${LANG_OSFWB}
${/* show help only if available */} ${do:if-file-exists:html/index.html} ${do:end-if}

${LANG_O2} - ${LANG_IOPT4}

${LANG_TIPHELP}

${LANG_IOPT1} ${LANG_IOPT2} ${LANG_IOPT3} ${LANG_IOPT4} ${LANG_IOPT5} ${LANG_IOPT11}
${LANG_IOPT6} ${LANG_IOPT7} ${LANG_IOPT8} ${LANG_IOPT9} ${LANG_IOPT10}  


${LANG_I44}
${LANG_I47e}
${LANG_I47d}
${LANG_I45}
${LANG_I48}
${LANG_I46}
${LANG_I47}
httrack-3.49.5/html/server/option3.html0000644000175000017500000001770414336470674014757 00000000000000 '${projname}' - HTTrack Website Copier
HTTrack Website Copier
${LANG_OSFWB}
${/* show help only if available */} ${do:if-file-exists:html/index.html} ${do:end-if}

${LANG_O2} - ${LANG_IOPT3}

${LANG_TIPHELP}

${LANG_IOPT1} ${LANG_IOPT2} ${LANG_IOPT3} ${LANG_IOPT4} ${LANG_IOPT5} ${LANG_IOPT11}
${LANG_IOPT6} ${LANG_IOPT7} ${LANG_IOPT8} ${LANG_IOPT9} ${LANG_IOPT10}  


${LANG_I40c}
${LANG_I34}

${LANG_I39}


${LANG_I40}


${LANG_I40b}


${LANG_I40e}


${LANG_I40d}

httrack-3.49.5/html/server/option2.html0000644000175000017500000002105014336470674014743 00000000000000 '${projname}' - HTTrack Website Copier
HTTrack Website Copier
${LANG_OSFWB}
${/* show help only if available */} ${do:if-file-exists:html/index.html} ${do:end-if}

${LANG_O2} - ${LANG_IOPT2}

${LANG_TIPHELP}

${LANG_IOPT1} ${LANG_IOPT2} ${LANG_IOPT3} ${LANG_IOPT4} ${LANG_IOPT5} ${LANG_IOPT11}
${LANG_IOPT6} ${LANG_IOPT7} ${LANG_IOPT8} ${LANG_IOPT9} ${LANG_IOPT10}  


${LANG_I33}
${LANG_I38}
${LANG_I56}
${LANG_I66}
${LANG_I67}
${LANG_I57}
httrack-3.49.5/html/server/option2b.html0000644000175000017500000000730214336470674015111 00000000000000 '${projname}' - HTTrack Website Copier
HTTrack Website Copier
${LANG_OSFWB}
${/* show help only if available */} ${do:if-file-exists:html/index.html} ${do:end-if}

${LANG_Q1}

${LANG_TIPHELP}


${LANG_O2}:
${LANG_Q2}

${LANG_Q3}

httrack-3.49.5/html/server/option1.html0000644000175000017500000001731014336470674014746 00000000000000 '${projname}' - HTTrack Website Copier
HTTrack Website Copier
${LANG_OSFWB}
${/* show help only if available */} ${do:if-file-exists:html/index.html} ${do:end-if}

${LANG_O2} - ${LANG_IOPT1}

${LANG_TIPHELP}

${LANG_IOPT1} ${LANG_IOPT2} ${LANG_IOPT3} ${LANG_IOPT4} ${LANG_IOPT5} ${LANG_IOPT11}
${LANG_IOPT6} ${LANG_IOPT7} ${LANG_IOPT8} ${LANG_IOPT9} ${LANG_IOPT10}  


${LANG_I31}
${LANG_I32}
${LANG_I32b}
${LANG_I32c}
httrack-3.49.5/html/server/option11.html0000644000175000017500000002322214336470674015026 00000000000000 '${projname}' - HTTrack Website Copier
HTTrack Website Copier
${LANG_OSFWB}
${/* show help only if available */} ${do:if-file-exists:html/index.html} ${do:end-if}

${LANG_O2} - ${LANG_IOPT11}

${LANG_TIPHELP}

${LANG_IOPT1} ${LANG_IOPT2} ${LANG_IOPT3} ${LANG_IOPT4} ${LANG_IOPT5} ${LANG_IOPT11}
${LANG_IOPT6} ${LANG_IOPT7} ${LANG_IOPT8} ${LANG_IOPT9} ${LANG_IOPT10}  


${LANG_W1}:
${LANG_W2}   ${LANG_W3}


httrack-3.49.5/html/server/option10.html0000644000175000017500000001624014336470674015027 00000000000000 '${projname}' - HTTrack Website Copier
HTTrack Website Copier
${LANG_OSFWB}
${/* show help only if available */} ${do:if-file-exists:html/index.html} ${do:end-if}

${LANG_O2} - ${LANG_IOPT10}

${LANG_TIPHELP}

${LANG_IOPT1} ${LANG_IOPT2} ${LANG_IOPT3} ${LANG_IOPT4} ${LANG_IOPT5} ${LANG_IOPT11}
${LANG_IOPT6} ${LANG_IOPT7} ${LANG_IOPT8} ${LANG_IOPT9} ${LANG_IOPT10}  


${LANG_IOPT10}: :
${LANG_I47c}

httrack-3.49.5/html/server/index.html0000644000175000017500000000756214336470674014474 00000000000000 HTTrack Website Copier - Offline Browser
HTTrack Website Copier
${/* show help only if available */} ${do:if-file-exists:html/index.html} ${do:end-if}
${LANG_OSFWB} ${LANG_O1} | ${LANG_O5}

${LANG_G30}

${html:LANG_Y1}

${LANG_P15}
httrack-3.49.5/html/server/help.html0000644000175000017500000000602114336470674014302 00000000000000 '${projname}' - HTTrack Website Copier
HTTrack Website Copier
${LANG_OSFWB}

${LANG_O1}


${/* show help only if available */} ${do:if-file-exists:html/index.html} ${do:end-if}
${LANG_O16}...
${LANG_O17}...
${LANG_P16}


httrack-3.49.5/html/server/finished.html0000644000175000017500000000774414336470674015160 00000000000000 '${projname}' - HTTrack Website Copier
HTTrack Website Copier
${/* show help only if available */} ${do:if-file-exists:html/index.html} ${do:end-if}
${LANG_OSFWB} ${LANG_O1} | ${LANG_O5}

${LANG_F18b}

${LANG_TIPHELP}


${do:if-not-empty:commandReturn}
${LANG_F19}

${commandReturnMsg}

${LANG_F20}

httrack ${commandReturnCmdl}

${LANG_F21}
${do:end-if}

${do:if-empty:commandReturn}
${LANG_F22}
${do:end-if}
${LANG_G8} : ${do:output-mode:html-urlescaped} ${do:output-mode:} ${path}/${projname}
 
httrack-3.49.5/html/server/file.html0000644000175000017500000000510614336470674014274 00000000000000 '${projname}' - HTTrack Website Copier
HTTrack Website Copier
${LANG_OSFWB}

${LANG_O1}


${LANG_D8}
${do:loadhash}
${LANG_S11b}


httrack-3.49.5/html/server/exit.html0000644000175000017500000000124214336470674014323 00000000000000 '${projname}' - HTTrack Website Copier ${LANG_SERVEND}.  ${LANG_CANCLSWND}. httrack-3.49.5/html/server/error.html0000644000175000017500000000375214336470674014513 00000000000000 '${projname}' - HTTrack Website Copier
HTTrack Website Copier
${LANG_OSFWB}

${LANG_FATALERR}:


${error}
${LANG_CANCLSWND}.
httrack-3.49.5/html/server/addurl.html0000644000175000017500000001146514336470674014635 00000000000000 '${projname}' - HTTrack Website Copier
HTTrack Website Copier
${/* show help only if available */} ${do:if-file-exists:html/index.html} ${do:end-if}
${LANG_OSFWB} ${LANG_O1} | ${LANG_O5}

${LANG_G43}

${LANG_TIPHELP}

${LANG_T2}http://
${LANG_T4}
${LANG_T5}:
${LANG_T6}:
${LANG_T7}:
httrack-3.49.5/html/server/about.html0000644000175000017500000000450514336470674014471 00000000000000 '${projname}' - HTTrack Website Copier
HTTrack Website Copier
${LANG_OSFWB}

${LANG_K2}


${LANG_K1}

${LANG_K3} : ${HTTRACK_WEB}



httrack-3.49.5/html/server/images/0000755000175000017500000000000014555203200013770 500000000000000httrack-3.49.5/html/server/images/header_title_4.gif0000644000175000017500000000370214336470674017277 00000000000000GIF89a"kk??_{{ ++AUU44NvvJJo-``!,!@I8ͻ`% $hlpAm m׸ۡ_MF ~rl:)pJ 2ӠP#jimq0 tA{ -}5t6kWb|:,; z j<R?MիXj'0`  $Cn T+R 2&r@@BM%Nha;F V=>&A  :T"˫Ed}% +:cPYc[PY!]m& \*C`9Ϝ&|L.HlPPgW#59rA+xV:vZ T Q{#0`r U$ 04Y`|# D)8p5"+EUR.4=Q@SP巕Ol(D+v%L9Fv`TViUH^e,R/ dœS5].E6QqԢ}dhM8Y>$0 H6R_@@+ 6!@`\ y㗻ڴĄUh TNcr4 ': =@]0x4 GkU1itA9>|s|ՕAwlp JVV2d# `'vb*r58l!1.f{U"!, ^0@(brг ɲCYS:뚆BB#"5l}TwEzq'XA\U{*+`,tUH*AH qWa\fG 1gbҌ;f ґ pxw2G`>a&ўKW%UaD~XB*-J1b598!0)a^+[#I|-)fx/6FP;^&Mmt 9T8TQ81+ Ũ*eD53MV! 9Frs_6Yϖjnj[XU LVU>4PZQ*F܂#MHaՌ6S]#B[ZV.1FzBx*@2Ny d&QIh$c A WR]Mt5 J%ҸNֲDnX[|VoJWMG6!\6]o/r m:T|ZX?T./2Z@⼖[Nj̀ UAEK,ꁴR/gX\{kXIF;httrack-3.49.5/html/server/images/fade.gif0000644000175000017500000000006514336470674015321 00000000000000GIF89a! !, p܂* ;httrack-3.49.5/html/server/images/bg_rings.gif0000644000175000017500000001021314336470674016210 00000000000000GIF87aݹ׾ڽ,@0I8ͻ`(dihlp,tm"!CpH,Ȥ8htJtvz0i-hBOn](@y=BM;wzO;MmCX$nxǗ4suУ+xwקA־{߿͇i$=ʑL< 9dP%$V^Owa[>ҢhY4gfmk^Et'qs֩'wW{B)"d}0B#ᣐFhVjR!fxC6ZDRԦS@ph>(:=.k;"`l#:,6b K""{`Ut!xgXn9+2f`! rݷ\IpSde p\qFq(Rv0-0qaoS9XMl$,.ߵsd@ 5d]5,We,!RHn-}5R- N%vgQ=lVͶ^FKu/97hkP}6w߂k7țxo"G\?= wǰvaR,hh+9a!ynXS2;ة ;n:G|)g+:E<4}eZ*LpO-O~d2tv=s!R齗ɳ3_y>O^Y>!{89[:( ^ &A iuHpCj!pTC;ɐT |u@ H"v. U cbxL`@P%aeQb$ܢvzQ*#xjZ4)-Rbc__C1D^x@:ʼn#X勊} }XE. $Iұ ҩF0D !X/ +KɁS]!$RVIز(d/$RR&EdLCf] '}YP3??lf?\)"z(?kzCNyp!DAvTϤWrmRI 2+!̝#5r A#XIEO "?Th%6V!2&)7S J% DaXC^JME%9-MP Uq0`3JtڐhZI͏̂ȬBP 5S'P:rV{͇\-wX`9ʄgmބk]Yo&ιl/i ekpVگzZhi*5i% ,!a7'[(SHk&ҢbmliBk .jur\ºI41.^kp}m>ݛMwb)Sy3^ymInY]TW'eb}c[T7iEwr|}hi0_yeJV>j#a*Qp;\ "PySz#3Jl'3ü:r*| %Eq\AY(^'TAX`qcvT$(6.rOfM f<)+lP0D%g HקPjq:,k6̜ƚPi*6[=}PZ[f_MMʚi`l}됺Z8@ lId@j?PsA".峱6Uub;`n/thݾa `ޠwo{${ ?%8MyƊ)|U+V[ϸ7{ GNriH߁'K~'?b f\D>܅ok 1xnj|t[pM)o+"# uk})uIt}O/;,˴oq#=°&OłQ5n4GwySX}ndtR<>_?mz͆nX%^Nf^my@XQ'?ؾ ,FK?uY [{7|{?~P?7w^69X:0y7oIBLxT\8s3&sxFZ旁3Z&%8\%ep( 2!d΀ x>?^bȂDGq&+r78 49 K?yu5D يC H2My }MMyDe%[$EgiFXPWqY=y6Ya)sy6Hȗ<9[{9}MCYNukZ_€BИ(YdוyZ5qcõGY_L&陑ś \Mi9  A&y (щ >VrIQ`Y `9L9p集gI%9(cE4lnENdϗ]՞@9NeYɩᝋLuCӉ4gٙ.k'V':ѢRC%DK5:XJz2D?xTQ@Pʤ_ĠA*E:*VXEK8*HegDb@a,fr,iz{q}~ @]ڣzQ>4q@O!l8W"&PBJ wzɧ*bz¨WQ{:z"{ӦNYqE+(rx.Z = <"'**: Ϻ5"]3UP,`^wോDq[3 v!"=xz5o=3fj+++A KŪnWA'/;YeaA(*oZA)PoS"+CcCJ5ĭ%30ijKa0!IU$>bK@fO[VSfU7 O˵ W֬c[fgk}8Kj^;([ o;`upj4FƷPQH{ [s}j[Qwk"!m['0+&p'($ÇN*uD`A4 Et{*eT#Z4[j˼l rQoKp%q˽q rKts=8˾~ tXG0 0ۿx|VtGVtһ hiKFs =\x@̳wZrruG0G+*,. o ;httrack-3.49.5/html/server/div/0000755000175000017500000000000014555203200013305 500000000000000httrack-3.49.5/html/server/div/WebHTTrack-Websites.desktop0000644000175000017500000000033314336470674020362 00000000000000[Desktop Entry] Version=1.0 Type=Application Categories=Network; Terminal=false Name=Browse Mirrored Websites Comment=Browse Websites Mirrored by WebHTTrack Keywords=browse mirrored; Exec=webhttrack browse Icon=httrack httrack-3.49.5/html/server/div/WebHTTrack.desktop0000644000175000017500000000047614336470674016607 00000000000000[Desktop Entry] Version=1.0 Type=Application Categories=Network; Terminal=false Name=WebHTTrack Website Copier Comment=Copy websites to your computer Keywords=copy website;backup website;capture website;offline browser;surf offline;mirror;mirroring;archiving;forensics;crawl;preservation; Exec=webhttrack Icon=httrack httrack-3.49.5/html/server/div/httrack48x48.xpm0000644000175000017500000000635714336470674016170 00000000000000/* XPM */ static char *httrack__[] = { /* columns rows colors chars-per-pixel */ "48 48 34 1", " c #040404040404", ". c #080808080808", "X c #0C0C0C0C0C0C", "o c #111111111111", "O c #161616161616", "+ c #1C1C1C1C1C1C", "@ c #222222222222", "# c #292929292929", "$ c #333333333333", "% c #393939393939", "& c #333333336666", "* c #424242424242", "= c #4D4D4D4D4D4D", "- c #555555555555", "; c #5F5F5F5F5F5F", ": c #666666666666", "> c #777777777777", ", c #666666669999", "< c #66666666CCCC", "1 c #808080808080", "2 c #868686868686", "3 c #969696969696", "4 c #999999999999", "5 c #A0A0A0A0A4A4", "6 c #B2B2B2B2B2B2", "7 c #99999999CCCC", "8 c #C0C0C0C0C0C0", "9 c #CCCCCCCCCCCC", "0 c #D7D7D7D7D7D7", "q c #DDDDDDDDDDDD", "w c #E3E3E3E3E3E3", "e c #EAEAEAEAEAEA", "r c #F1F1F1F1F1F1", "t c None", /* pixels */ "77777777777777777777777777777777777777777<,,<777", ";&,77,&-<-&&&&&,-&&&&&,777777777777777777<$$<777", "# ,77, +X;+34%21X", ";; -$ 2;tt*qqO:00%1qtq6t8 99q 40e:Xqw=4$rt:9w-", "$1 1- 4*4=@66$5%:$1%9%5-$ $8#=O9$:8X6:24$6=+6;4", "O4 51 4*> O4>%5O $1 6 4O >- *2 X0X5O54$3 6O5", " 6 64O2*4-@42+3: $1 6 5:* 3@ :- 5#5O44$6-@6O4", " 6O46$>*re*08 =w*$1 6 6e6 5X 2$ 2%6>14$ee;6:2", " 2=15:=*96$ee% 48$1 6 561 5X 2# 1%wq@4$06*0w$", " :4-24@*> O4:2 X9*1 6 4O 5O 2% 2$8* 4$3 88 ", " %w#:0X*> O4#3 4;1 6 4O 3$ :; 6+5 4$3 68X", " OrO%0 *> O4#24X3;1 6 4+ >1 *6 X8X5 4$4 64#", " 6 +5 *61#62:6:8*1 6 52: #w=:Xq:13X5 4$81$6;:", " > : *tt*e0+:r8$1 6 6t8 8eq 3rr%X5 4$rt:6#4", " @ @ +::O;# O5*O# * *:* $6: +61 % %O;:@% %", " ", " ", " " }; httrack-3.49.5/html/server/div/httrack32x32.xpm0000644000175000017500000000260014336470674016135 00000000000000/* XPM */ static char *httrack__[] = { /* columns rows colors chars-per-pixel */ "32 32 7 1", " c #040404040404", ". c #0C0C0C0C0C0C", "X c #161616161616", "o c #333333333333", "O c #333333336666", "+ c #666666669999", "@ c #99999999CCCC", /* pixels */ "@@+ @@@@@@@@@@@+ @@@", "@@+ @@@@@@@@@@@+ @@@", "@@+ @@@@@@@@@@@+ @@@", "@@+ @@@@@@@@@@@+ @@@", "@@+ @@@@@@@@@@@+ @@@", "@@+ @@@@@@@@@@@+ @@@", "@@+ @@@@@@@@@@@+ @@@", "@@+ @@@@@@@@@@@+ @@@", "@@+ @@@@@@@@@@@+ @@@", "@@+ @@@@@@@@@@@+ @@@", "@@+ @@@@@@@@@@@+ @@@", "@@+ OOOOOOOOOOOo @@@", "@@+ @@@", "@@+ @@@", "@@+ @@@", "@@+ @@@", "@@+ @@@", "@@+ @@@", "@@+ XXXXXXXXXXX. @@@", "@@+ @@@@@@@@@@@+ @@@", "@@+ @@@@@@@@@@@+ @@@", "@@+ @@@@@@@@@@@+ @@@", "@@+ @@@@@@@@@@@+ @@@", "@@+ @@@@@@@@@@@+ @@@", "@@+ @@@@@@@@@@@+ @@@", "@@+ @@@@@@@@@@@+ @@@", "@@+ @@@@@@@@@@@+ @@@", "@@+ @@@@@@@@@@@+ @@@", "@@+ @@@@@@@@@@@+ @@@", "@@+ @@@@@@@@@@@+ @@@", "@@+ @@@@@@@@@@@+ @@@", "@@+ @@@@@@@@@@@+ @@@" }; httrack-3.49.5/html/server/div/httrack16x16.xpm0000644000175000017500000000075414336470674016151 00000000000000/* XPM */ static char *httrack__[] = { /* columns rows colors chars-per-pixel */ "16 16 3 1", " c #000000000000", ". c #000000008080", "X c #808080808080", /* pixels */ "X. XXXXXX .X", "X. XXXXXX .X", "X. XXXXXX .X", "X. XXXXXX .X", "X. XXXXXX .X", "X. XXXXXX .X", "X. .X", "X. .X", "X. .X", "X. XXXXXX .X", "X. XXXXXX .X", "X. XXXXXX .X", "X. XXXXXX .X", "X. XXXXXX .X", "X. XXXXXX .X", "X. XXXXXX .X" }; httrack-3.49.5/html/server/div/48x48/0000755000175000017500000000000014555203200014104 500000000000000httrack-3.49.5/html/server/div/48x48/httrack.png0000644000175000017500000000473414336470674016224 00000000000000PNG  IHDR00WbKGD pHYs  tIME ";S= iIDAThoHI$b4[AT J հI+-bk+@.H rAP VMa+. ƄMeq4m6஫1Fk9qMRnSB^Xvg3sy}ϮihM+U])uxPUu:cIN)c:VUp}ґ0ƅ~Ln|>_`Oiŋns5`/)c044|-s{ I{%''G(bG||<Y&&&H$@UAU _8 Kh~|3gÁ?t =-(vEIK}d ç] @8|O/:>ܹçWʕYd<&TUC!<@(Bc7گXߟmًz(޽{Ym V'gL͛7e6k0iiil޼9fff:Z*PЙ 'Z&KgwnnvHOOGUƍ W>_Z8mr+j Y٘VLV믿߿}4Q! /;?$&&J޿r%-@JJʊ,sANp|||L Tb,V=>sϙBJh0/\njbU$33ue;]o$s-v[R-atd&''W<8{vp8b&j.Wn!U͛7?쿃6Zؽ]mLٿB^bUR 9|(a Q (QXuuYfݍhJ^/CC_~!1alllati?b5Fl='ں !D"l۶u1==Maa!|駼k|>jkkqiiicX~:;}v>޽{|W_ p8\v Ikk+|ݻ>|Mܹɓ')--Ν;|۷nUUUBQQ^^.TU'O*EEE0 aHMMA188(Dmm0 C!\.tPE~z{{Eoo0 C("࠸}4M$$$0D eeeA*"4M@ ˅z)++`׮] e R]]ݻ^QYY|Byy8v옜޽G}DVV*++QU n7\pCssL3B Ν;ǖ-*}-n^n76Btvv?>VdXڳgW_I555|w~? 0<|UUe={Chii2;FBBIII1/633Ç9qC M6rY ߗ'p?ˌbg@?%%%x^~?^jW\޿]7ۇ7ңLڱ&&&Y($&&266&V:8lܸ~l_~E^T_u2֙gKP(D{{;PյgofoΦ;w߲}j]..\@ul6ڵjl"n%۱cǏŚիHX\*qnn._~ӧO'k9 ?\tID|> /drr&Ο?ӧxW`Ϟ=߿i"Zw=zo[n MDjj/PE3g#Djj_TT$5Mяr M.K6yyyѱ5Mv]ӂ)?h}~bv'IENDB`httrack-3.49.5/html/server/div/32x32/0000755000175000017500000000000014555203200014066 500000000000000httrack-3.49.5/html/server/div/32x32/httrack.png0000644000175000017500000000034614336470674016201 00000000000000PNG  IHDR szzbKGD pHYs  tIME ""8sIDATXֱ 0 OZ3cxV12C2]Ҧ `pZ}/.'`nQq` &` ^0aVa N a#hb %W߉,搢..֚߼m-Vb1S8׍;fODM@d( 壜A}]0e1yK@QdRthH1Y P\24@9w=yJoTH3 *rUTj'h-jHFo;IרsAP2ivYd桟Aji[RڔKLu)5zdeu6(M u"Bb+'Vkĵzw=l &7ҟQj¢0 ٪np kQ%|0+w0g"l ,S3ǜ`<h<=-C ;,L7PG- !Xg\w8V{J`hlp r|qm7'chx⌳]wa cMygE>&P椗޶x>z_뚣ꯄnî;㲧{o޽7@+0:v{A%p/=[o>/|+ٔzMixzG|[NJ}c\6A v4-`;  m̠*8щ/#W@P7gL[ 'x} M>"hB&0|cx*m< eM>F0p#7I`:@юkG0ZnQEΎ}L$"G3s"7YdcfRL$(?/<$"C1|+HYғK-ֻr`2)$'HO#Ki2{Y4E!aGʄe-s:\Z[*L]&3;qF|AlQ_'8iub+(yQΐU',jPlT":sQV^a8!6NQԡA zCP\i?nڳm :N>p3IRٔD,Jai区S!?B5ISjxGզM+U"3Z-֔,\08r]+]bT0+NU^%X%W'," Ɗjɬf3z B)&ڌZiWԮʵݐeU0ң(mѡ[vÁG*=q"woHZQuzG=oIXZPJ B\^^7qn0Ta &ŁZ-LHו %pt la޵u*:Lb S@0aQKZkf*W[X}ֱj< BbD꾉2N2b, #RFagW`jYno "B9)1MgIgY|qtvv ptDhRh.}E[ ʒinNbhEz,樛CaeY4aRrmSz[WwIM8bأf|l^Z!kѶר$Z/UmPCkUlZmEu5p,& ]xc wa:~߃x /2++Kww[nuwq('K`N<%}]w>=pmۿ3`(}n*1=>qԿ7uVB]:^n{3:d_f:G73nO1s(coH[_YSY&?`t;BC/"]S%$ӟwtujP'd'|4Pgv4nƗl 8WXqs:nO"$w#o@BoDrp.Y285\&Á{<( >>@0bTJ L3)7^MAXXa-ws`x]H6aXf]c:\[8ct8{CS;8b9^"XmHw|u<{xRx5qxx]xnl\8ir7}ۖvWDmbTztvxJh^h|wz`vtӈTX'ˆ؀H(y+Xleŷ,8\f{ȌC{HWvt8$ڸc㘇xfmWh`?;ihu(ŠʖFk]菹(s)F (vaX? Mh֐%%9CYi$HN68= )]($*(E4LPO2CY%sXك09`]`+b9sݦjn_)0h9]gXZezS9INEP5,IyNǎKg~iyk2a.I^m eIיYyd3|H#){ &I (Ӛ0 lr鑿8XfBYw6z؜ )7ډhY 9Y*#߹fvaHjAٞg̉cǛͧJFvHh֠ZFXɠgEyE x': Y /5)Y-G*W&lAyWBjNN37 w8E&GYyQZڥZ:: fy =:&Rf "hl*3b*qoz'oy7іx)\@Ɨڤ+9zF|[Byc'~j rْ4~:v!mʞ1ZvZWxwwK𹞷Zơx8Z~6zdy鬰Zvڬʬ靥szldgx=&㺮٭Aˊ 0ʙ٪j6*Ɗ*Z/ >y  swʪi׊*I鱎ű粍Zd 4uׇD:W ՖF$ 1S'U*^:mT{29=b\^bd[qhkpwM§p #p;նbGVz7|g5*}zzJ;ڲڇlaHڪ*ʸZ8 $0{2;K &y 9k˝FZ[۲Je.*;{e定ظ뭔ˑx{l[+z8˗޻ۺ&ʹ'˼Qk;}۰ˋ~0 ,k;V+|>ꋲʛ~5W&.ۯv6=MK O+"XKV;FoZ*LK܁OQS,[ULWܦY[ sIjb\E k~k6:+B8": ~\Ty|RMk7|+a1+ẹ\ X{ |\(ɤ\ ɻadG#| 3̿ c۷HȮָ:뙲lɤ[́F +⬭;KwȌ|μ<ڬʻ¦$JJΫ,<:L\2lϾ|l1zы΋O#O2]Jy_.Ha_̢&}7:= j@}[<=c[FmHPLB:hRMN]ռX]qZ^=Q0d f} fnpr},v}xzW~׀؂=؄]؆}؈؊،؎ْؐ=ٔ]ٖ}ٜ٘ٚٞ٠ڢ=ڤ]ڦ}ڨڪڬڮڰ۲=۴]۶}۸ۺۼ۾=]}ȝʽ=]}؝ڽ=]}ޟ;httrack-3.49.5/html/img/snap9_j.gif0000644000175000017500000000755514336470674014001 00000000000000GIF87aνޥk,@0I8ͻ`(dihlp,tmx|pH,_FR\2J 6R2R[0vѵ~Xm^omzNxxcyG#xzVz`LbeiqWIM;h1!:{ф{H ׿/UJ -O riӧ CIɓ(S\ɲ˗0Qi&Ǜ87u Ν>  jPG" (ҟ4Ҫ1j旚r#׳hӪ]˶Gʝ ݻx˷߿͵ LŐ!<1#ő2f֭ϠC~I!IXG^ͺ^uF4Ҟ;93Vꦍn?.^|T[\"yS}XqW]U<ˋGm'Ը{qwIZV[FH5` 5!m5u ($h(,@hxDQ>< o!, I#BhTVEI0 2PV)dihlp)tix|矀*蠄j衈&袌6裐F*餔Vj饘f馜v駠*ꨤjꩨꪬp9b@a7z3XDe-dE.mS"΢,"a%/kfc:jn@7XCY6G,Wl9PnLp+RGQ-|YN&2ƅ+4l8<@W0߅]TSD_M#\T$MVjI}SwsJ6qgߧSM}UpHimx8hs%Wd<kD(7 Lccܜw9s/ nq_ WSCq _x7UۺT꣧zٴM;ﲻtvD^ԳO_=K[E<RÉƩ﫯o ,N0@]ůk1=&W# %%?P0Cf21ce$(L W0 gH8̡w@ H"HL&:PH*ZX̢.zE+pK/*W3vڪ25 w$WF"AY;*H\rXet A BcY-~c 'ɮm,Jq&Un *gIZJH Ҁ¥<⛞`4ŖRGn$IaH\lUHrD\IַD,Hݲ:vi Q{jI绤-Mz̫*kƧ:bjhWn̗׾ 9XZPw0>@LD%#%K!PtF- K-DN9Ԯqc+&ev p Mrypt+ nv:n4tUj-E WnH | zʴaϻZkuyi=Zb3Fkꀣ;RxyY{Nؽ ߆7+ [[31 8}{8LX{CR)خ]qf"RݞTc%HnSs|֥i1e<W%Ǭ] ,.׌:3 ͂L:xγg*b]%xYR."}%GX`ϔ,g+Nm"Sel$/ȑA^%S䣢ul*^bf%2Zָεw^MbNf;ЎMj[ζn{MrNvMzη~Np/6l+돥VtJ Y*R,eUM7ڗoyhrz&sR6̖2mT.e. US쓡uѕpFOoz^&h5$D k[IS )-.#5m+3=ըuyͩ&U}NBPZ>0BY;񐏼'*_qʃ¢eaq?Λ'}0_>d̡I >.Ou VP6{UFq{R ?;h꽏OOXGo3Gx!+Fh'b~?8WGEt[I(uqwrpwXr3'IĀFQZt]Y:2g2ƗP÷vuP}^pFiOvS$ҷ"ăDsf'F(IoKO(mwpTXVxXZ\؅^`b 'gjfh: fggpH!ag\bmb#!C^aqsgǓi=d5_6HAV66e<<^Jua#ֈtmXgss`Èb1Becs`V+{6U=ae;xd%fbec^_F`V01y9匈h&ָrBVgk8Xx蘎긎؎7XxC$`YQ'Qx1珥/pko@6Y`ϔ)#<7$)Argv2Yji,tV|ɧiWW7u2BDuC")@{qv'y|yx8cLٔNPQ:!VyXZVHAbyVEpf `n)xt)q) ݱ!8&_(]uxud1wXևd40r5W嗌x'9ɗ}y& eʼnXed8gК!P;`eyHVɉcY` Ƙ։I 9 yci0"&a`ƙ`xx؊ҹcqeĈ^ \3GSY`tٞC];iiah Jϳd)`z m +!lf$ə\A0J镔e:-J:ΨG@B;D[F{HJL:۴NPR;T[V{XZ\۵^`b;d[f{hjl۶np E ;httrack-3.49.5/html/img/snap9_i.gif0000644000175000017500000000457314336470674013775 00000000000000GIF87aνޥk,0I8ͻ`(dihlp,tmx|pH,Ȥrl:ШtJZجvzxL.zn|N~ ( &S ]{$@"68p`@`^}lHŊ/z0d?^D~0$MdLYey=Vgy5 efPؓ{ִw})(6V \OFXvv7buڛvdls.6kv)ccGPWd^I j_"]B* lXZ&ݳ|oÊQrj8PFkkFbFuA okeqVj\Vzﻯ߹; ˯zkm4l۹9i{riřr'X) )>ltBEL7PG-TWmXg\w`-dmhlp-tmx|߀.n'7G.Wngw砇.o騧ꬷ.\m0/?|t|nG/Wog_=bݫB]'Qڧ 91\ oy*4&J:H Z׫4:Tx@v3EPM1+ D>`0 קw  :@aU(& հ~y!v*[oU3eSbH=񆥚b: eEZMkFR5F/тw,xF9u)A+T"4NFrhd$?{6F_{c5DDp9`W?򕖌d+eZ6Q%I$ g³eؙX/ %%cIf값y4+|:idri} #"sʜ%&t-ѤFiыn gG=02)IY`RԂP Wїڴ"MmT PJԢHMRTPTJժZXͪVծbLu>j5#0 ;jU[+(QZ;~PHx}KI酘v_w)I sr41],!@b$)٦E%;ݬiV`N'N;d;y+b:-RnGr6`2(}kRtk)m MXFq=QKMz|Kͯ~PwAVLhQ^92`$d^iUR&aZf`Viٚ;LPN3s VevZ<YaűGQJZ -=uJf[I9^1l)YLv=E*^1u/gbr 4+IHSp>$E`g8Q1r z)UZf/QVA A1M{ӠGMRԨNWVհgMZָεw^MbNf;ЎMj[ζn{MrNvMzη~NO;'N[ϸ7{ GN(OW0gN8Ϲw@HЇNHOҗ;PԧN[XϺַ{`NhOpܷ;httrack-3.49.5/html/img/snap9_h.gif0000644000175000017500000000543114336470674013766 00000000000000GIF87aZνޥk{{,Z@0I8ͻ`(dihlp,tmx|pH,Ȥrl:ШWZجvzxL.zno S͠1|~zw}w q p͌@٪ۯs Ϛ*\ȰÇ#JHEI,G<8 ? 0Q1)e˚6K>Y zShPe@&-ʲN-2=zlP@i::hժYicnU{+DxR@nݻ-߿mu2x]̸ǐ#KL˘3k̹ϠCMӨS^ͺװc˞M۸sͻ Nȓ+_μУKNسkνËOӫ_Ͼ˟OϿ(h& 6F(v |RRԑXΈ$h(⊧b(O\ՅhcKJp?hɘd'”6Ob)(˕V6$IFSz.`iHJ\J)Z:I٦"_0"c9eؠj衈&^h裐F*)w"uHG8Tyl*$&Y1E^Im5`*L4*C*2~E#šZSSVE {( 9 ފXX)m\)iAYCY[^ku-Mm}=ռ,C20oet+l' 7G,Wlgw ,$l(,0,4l8<@-DmH'L7PG-TWmH\w`33X "hh]D" otiN`Y&TB/c2odbW 컏5ZGމh:Tz 0]yy^9'~N;'ϩJ2)%-{gK㖗^pv wt;I斻Wo iG dP{G2.EC'H ZH`E6 k GHq W0 gRC]@>AFka H".C ?pxP9H"*o,V V-{-]"CƵEv]"׻-le\`&mH5tԶYIZUY7"'P#"+QUW"+iJNR] HuHG"^h2 ^|%OI+!E6L"EJX DVL2f:Ќ4IjZ̦6nz 8IrL:v~ @JЂMBІ:D'JъZͨF7юz HGJҒ(MJWҖ0LgJӚ8ͩNwӞ@ PJ8BVHMRԦ:PTJժZXͪV{BI#0ÁLZֶn{yiJWѫ9AXO¡a@[Kְpc.jAE >Amˬ2I~{_F@jV8~9|ץZdƼGBhn:] @B8DXFxHJL؄NPR8TXVxXZ\؅^`b8dXfxhjl؆npr8tXvxxz|؇~8Xx؈;httrack-3.49.5/html/img/snap9.gif0000644000175000017500000001135614336470674013462 00000000000000GIF87ahν;x` Njoe,hI8ͻ`(dihlp,tWA|pH,Ȥrl:ШtJZجv+\xL.znA/@~tx1 ,P!ÆIH!F2.ڨѣD@nI$R}嬨ѣǤa6MmנJjm۪5tHٳ!H჆pUP]A\̻#Ǐ@ V$IH1}:)ibO_Jf*囩^]3NvO2b?4[ԧZݍ߿aJ=w^Ţ]`yF \ B 6 p!»ӷT8L#g< e-oOLB,LiB%8 Q(àkHlY3[mHNS9&"ǕqcU_bs0<3q4Pu`@ )PB4xHڕ|QzQ{^|MXJ%eeVM`&)ڃ53"S!lqԞz~8 \]bʩ\h=57n %>PDIGQ*t:䫰:*^%T^5`f寖Xc[/I&gyfNih"xkت6QuVh!}fg8yp#[軋*Jϊ{֤X ;AhV y*E³ j K2rOJ|kl! MaL|,lNC%:o-@iQ{ pLxh+=/[o/+tXP\A*<:ђKzPj!ry,*2ff//l,|KXͩ Srl'~+}vG[N'5Ym5LZi]S<B0?jlqܭ*vovgq Zo,-c̎?N5[p:óp.m_.ձ.9QKV5npW/ZlH^ 7=Vi&'QYQ&ק#"~=i*QBw.vыǠFw%PK|w^t6uLTfK r4[Bzl޶Fr:GNe+9Wuz3JT$'J)f+[b*;'jdC+aƤQuM+#rydqca; 1,r^2Ki4Mfl)Αl9g%QNL2F|9Q(OɌ~bџl%1PRLƩy]N58NRa#-j\*VTJNA xl\I:Mt ׾”a {XQҒ:=vyT{ZqbBŀJժ:p 2R:#mefѐQ}*zIJ0 w#AF]Mo<O/iL,ExOx;S|5o{~' ?sO=Wy֣o?>ϽG{H +7|6A01w ?#_lf>K0 ㇃ӏ q-Ds P~%'/bG75/r(L؀a%|o)8eb@p~-ȁ8h@bH(,`Mh$J(u(XV60AEFX}=Xӷ5%8L[Hq2Whi(94]x$0vh5Іu(R7:x<|d5hȈx58H3PhQ5HUQ腟Hc)x6xȉfhan؂Mro(taXpP5ȈiȄ|~&ȉr((dЍh8Xx^U8(8D()>8FXXhYؐ+x H"وx$,!(y8qx3C鈮8HȒ}1 Khs.1y'I6Ȕ(&YH7l)y)Mi)?9|5DFQN Pؑ^ْ3ȕ_ٗbo,먆 ~)'P͘)Rzyٚ'PiɑIa 񨆴IyٕMiTHY8 } 4X2Oُ艰G6HInYTI/f(ι#؟Yiۉ3Ǡgm`j9szhZzqPiq9~)jpjI}wYθr,Y v=ڝk`3p8p{{J:{"R:3zb8*hSj`~FzV5*7rפLڦWzK*lj|W{uڧxjztz~ꦫ?90Jzz'%zqWururxZretczqZtZrj }\zsUqzt*qqZp(Út:qsq q*qZ*tZqt:qJvFȃjp Z.* گky7'ڒJ>YڂѸi#p[ k[+J+}2y)%Ji:9Z2-[,0,D0ȳJ+*!-pS;1`p9@(ߙN{fȖx)ˎVɞo0~;/H;i. WtZhmY'Vg1YcD[;ik+9؎K+ L~4 {}h;+K}ٻ ٛѻڛ} }7+x;)?J(Iȍ{*ɽ˿ ۶ Y|˜\I`); )Xv> JWʶ"0 *K91,< *p[||0Jc;9ܿ̓כp5<躲ۊ=ܛ+d,ĭgkj<:<ܰ뱫C. K:ڱ&iK[t[k{f+=<){y|\]k̊j{J, X71ΪA+ L4'I=Dt9EJ]v@KP}uGQ]VW\sS]b-sM c}hMr_]inqeo=tM--uzqM{׀m]؆mYԇ،=;Սْ-&ד}ٜ٘֫}}M͝ڌ٠-ڦ؟-ϧzMӬc$*۶G;httrack-3.49.5/html/img/snap9_g.gif0000644000175000017500000000375014336470674013767 00000000000000GIF87aνޥk,@0I8ͻ`(dihlp,tmx|pH,Ȥrl:@ZجvzxL.xn[|N~ߥv  rlqpts.ʨϝ<*uՆP|ܕ0 ?E>G i`0>zZذciU\ɲ˗0cʜI͛8sɳϟ@ JѣH*]ʴӧPJJիXjʵׯ`ÊKٳhӪ]˶۷pʝKݻx˷߿ LÈ+^̸ǐ#KL˘3k̹ϠCMӨS^ͺװc˞M۸sͻ NKm]ƼУJ:%&%_&[no>vY0\ >F%rN|( +^>~$ .h܃F(!1{]$INC6qQgB:͘H<@)DiH&L6PF)TViXf\v`)dihlp)tix|矀*蠄j衈&袌6裐F*餔Vj饘fv駝XPdHx _7*무>'jzbjY` >@39֪̒r+z"5B ϯ$;ɳEȴq2זt˻.&K+橫:l 7GZ0x`K`:F1~$Gʲ/2ӬRRC12WK:m "_Br(UK7,'5~&YI$>ve7m/`w|߀.n'7G.Wngw砇.褗n騧ꬷ.n/o'7G/Wogw/o觯/o )5L:\ u"x@ ̠7z 3h,am& W ǂ)H8 C#F{@PlŌ#afP [.DR[6%6`tVFŁe,64na`J@Ը ạ5 vF:}i46g\|UD΃ (3F\12P8TtEEY9UUiB99B@r..c]4RSa.Wofe7;6MMKJII-JK66H;;7q77C,,F,GGhF)) H&Dg^=m 琡;$n^C CIRnTQD-P0bD&IOPf :LE)]tiOJ:iUb!XN:Vٲ0}0-lMÃv޾2 8 }l8̠bNj+x0Z|l={~k}o?OHk,S & ΁T[D@s۞B;x+ĚV΅*!bCn>ib֒(ͭ@ġ7C ^'" 'l e&&oh3aٰ Mnh+qqs#6:bqnh<>L"HlְIJZy H (GIRf_ [LV#U)6Pƒq.w^ f/Ka##Hғd%ޤG-\E<#">qnЈ6c'1-sv%92ϱQ3}@>/xe$WyeS$4HDxZ?QzDg"g"s MJWҖNtLgJӚҤ3m9u͔_jӢAvj1i=Tnш{aA?tSJP/ψFMJEFeWpj kHS `TFMb+7dXNL+[Kzm%_-Қ#5,iQֺ6~kgK:Tnw[ pK\6Mretآi;jM,wwǕy^퍯|]^=%n՛WLENX; l0'LIp.{X0+|?L&Nۆck1gb&>pwq۸@LdQ-'<%;:&\&S2 ^-s}/Ym$'ӼLh|I)չ'v4CEux~cFoYZgDٔ.%* E[D7(GG1ԗWMNi^gMkYw+l\ՖC\[0vݘ YzfEmӤڪjn{{\N}tk]jWSv:Co<ɷo{ai^GlbҘ1"'NqD*s_#yg? zFh(ʵWKӮj8դXOs H鐁P@QR EY=Sʦ4RYǨaks@TBK2.mɋB_ػB2,7;1ú e,hoYͪ6ig[a$ ?u3PH_D7Ē-UBEC$M؎0>ٓ@BD9FYHyJLN);ٓNٔT9VYAZXy^ٕ`bRYQ9hjɕgٖkilqIuyE9!\ؗe~Ye#fZSF<hXQNQ0QMa|$bԑ+8$88`(ASONNę9Su۔ayDޓBdEve?=bW`Ei7;֝Y)繞2։OtRlՐY<&P y3gigŞT y2DguF$tWŊDHV}sRJ !Zi&5ꩢ.I2 `d\58K1̹sU%S䟉i5ۘBAs4-gĔl72ܘc{fܳ3e3k9unXqotgmLG%о(z߀h\W"F(@ :ڄfVSq($(a,x(48٨< !(D!L:dMF)唇=YKTfd9r)dVXl޸ja)tc%-i֩u y jQ袌NydF*iNj3V馜i ᧢j}yꪬV&*뉯䬸V*Iz+&+T6D>+ Պf+Nv뭱Pz+Y"bmnn *|陶+|- k-6,1OlqBzƆVdz Zދ'()r,+r0r48s8h9>-"B!F' J7]΅:-LOmsU_a Kg*d?eǪsY-wYqmVu߭UPw`y-QnxPxk]=6ͶgNUw{.Q`騧ꬷ.n/oK>bW9}OQZ]? z'O/ikSS:/Aɟ̡P2IIp(dTmv='KA? ^:n Vػs! gH`A)NԀCP"4}!"3(4N"H*Zq @E,jq cH2q @#F5N@ :v|=x 'A,"B2$#%IH2 @&7Nr2 `@(CQR e*QVtd)Yڒ,=җ@0),L&2d:sτ4 Pք&6n&'0r3@:ӹNt3<tƳ@< ~9Ђ@4uC#P@F7 zt 5@H3 R$MIWJ ԥ05@LgSȴ)Nm<jN洨HMR4NSzTV*V Xի`:VZgkZֶIG`(^KW lE‚_ cb5H%+G4y98vV 9Edj)Ij KV4n5޺ .KY,_%s)f2n4]lf3۴6N~s&P 4'BjP.T}/:xG30aReH5\2-LC SO{?QJc7TT_"q:jլF.kY-d&Nf~$rA`l *PA VP0 T Af.21 hba&Χhd)+Y˾q>~֏$$#}HFL#Uk7IRV%*Y9:í%-;`:m.1{Izd&wjNvx)n7E/;yz3/})O}Zݯ@ xFǝr;(F g 7lR)uiM~봦Y,ǘ3‘zc?=vjU g5Ejjd&#imrZ-bo=\{PP ! TD swΈb 2E4V++G dIHAvҔÞIֶ'C RRnWo{VLn+Ls<&/;L㺙u5}] [/oz{Nps|;VޯXv J MJ8wH{wX wGb0L,HCDa#ff1?֠\ _9SKc `[Q iA@ &q@Prx?tM[щ q?z;s[aZk [q%@{Uae;p@y@zyk>;%Q X{ o۹;ݑ 빡[!ً ۻWKz$c n'Kkid~KWH?{, $˸k{J+;gK) !k>P'(*,.0<2\4$´//,,X{6\D|FH6 JL;Qk6s ,z!~|Ǎ|m 3lɷ1ȓ?3aɝ\ ʭ;ܵ,; -% rqʴL@<ҁa̡\]p<|ͺ|ȣɟlcl˼˰뻴kL@ی\Al'|ՠQ&@<\ϣ|@̹QL {kʟ)}@-/-{l4rK=M M |l2 #'~ۼC)}A]Cmۻ r3nC =]s=:ڽݞ<ޙ3M9}ޏT" 1=]}ߴm* ObLn   .Ԝ<"">$^ >8,!a6~89:p%T|մNP㯰`` >8HDa 8`@ j^lP my~k>R瀮T ~n8gu0m-]m? `-XqX~^pꮾ nP) [ܽ ]L;~w癰ꖐ~0 덞 g> b^iq~`磎T~>CrP ?P7I:d1^&5*,)N44C:I&/<;=DA&cNM?POR_XZo\]^`?__bodgi/:3ރ#r7t_{sx7~p4-ۅރ#B(Mm}{ i{B4].q&{쐡 Hr K slL8^Ϳ\?-ҹOeGOO}nP0K;fNI]ԾI֢㼼>aJ^ԏ# g Ƥ̤УբߕĞ HЕ|$ 7%7.!mۖ]+J(j͞&QLI?_rI͛8sd%s@WlIӣ(|*]ʴӧPJJQPHGʵׯ`ÊKvUNYEm-˶۷pe{Qڑs˷߿B*Z+^̸@vL˘C ̠CMZ·>^ͺd&۸s#>]g ē+_ΜͣKNsճkߞZËwӫm?YLwh@}w 6؊9(^$[7 VB! f'({)t"4c8hۍ:h<(䐍XH&9߅&*p T~%eXfԕZv%NFdreh9˙jf*l)眎In9 |igzgV9h:yhgF:墒VJ#f"v "Jj*jj*|jzx#2 WkN7l.wl kЪ+vVݲfvކkٳ榻۴뮍Koラ` U LPKq) 5IL{$[\A*RY~'0r4Bb ׬L7@#(Sm4@3MsJt+; ԯ}==}.|= WO-KO>/gI~iO?f P@]-P[{ ({J0( rH <(L W0 gH8̡w@ H9P  %0NdX;wĽ@z"f6Cyb^ƹpQ+\8.2n'h#12g"v&lU1Hԑ#,?ǹ5;tHhXD0AE"D␂069ERYH䏰ܤ0&iVďd:GTD~-aa\☹'3LФ)6j֢!cX!|%-@o !ˬy6vEjbz7n1:}{ӟ&?(Ospc%C#JQ"Qу8R;httrack-3.49.5/html/img/snap9_g2.gif0000644000175000017500000002041114336470674014042 00000000000000GIF87aνkRcsB)9!1ZJ{k{cJ!11B{c111cc1111c11RR111c111c1ΜcΜc1cc,@@pH,Ȥrl:ШtJZجvz`@DN.ڙ͠|@of!~           "?"!Æ HH-jȑ H(4@˖\ʌ)e7s<3M:"8 F"=ʴi GJE„ bݺ5Vpal Җk2@@Zuɘ#@ p ` w pJO@8e l'E)H38|Zt _~lۯF-.XR!0`ƒ33h IFzmϾ}\8tԩkG~޻zL_@)?>?}QI*}Ibp`L-3dM7SPqŬ.psoEDtՎ|G.l<(3:ԏ i\]WzǟWkvBd?uw}J^g:c` Z]P 7e{ ES EV0 c @d2p8ao6 C"j* C\_HEe\xbԆ-Q Mt"n=mi[B F(`Ycਅ..F>֋ IBL"HB&qy_$'R%3NrG(@Q&攌LcAA ╋p,e I\▘.5F8E)PAݸbȔpr!]8s80c09h2 P;7;XG:#ȣh{ }Dd?HFPSTDfZ3JWU5H㯁u s"sL<es|\>1CO  D@BmJЇBɄ.JdXh(Ї,%&"iL"L+\a2Ԧ`pGOX$E2 c@'pxγgHjaqjLaJF7АtiҘAgΙGMmZtoW$ 9Ju|jVWs' f^ӪGa{AVe;{&XωQݸ= DǶ}.7-Atۅ&Ywۛ^mt٣V]yG0H)hJ 8+. !.qc<wG'.o6.9=˛ $9u^?{:҅t-M-Vz[Py)[?RQzQ,/_Wv!|G}cu'ٗy?m;p] %vp=n*JW"$R–e(8@ B=lIL"jm[bv끅,C}kor΅˙s0>O{g=7{b|سl)RP 5QBf!EFdu[[E[O\PVReR"\X\[R^7Be#וSg<5EuA CUFeHJJ^pzd^:^<^U]U`{D{L{V_$|W|ʇ`W &}VXEa}XaW~0OAabTZZAcucac$a 8Q4!Q2!BV[!d"Q'Beǵ"WeW4e6r4#$@55E1] 00XM5U1UPE^h%Vgiń_`G`dW& y`qMZHW@EaՎ}gXN Y b@bYYOOZAZLJ8Pc28!u?q[Iƀ[" y$5\WA\ŵRW\4\R)0#"zqzq^'K^?xK5K{A{V_q q 1(MV8À א }xNl}a%~x5bDO!5wP0veUc!Q 1)0Gd"ROvHhXR2de`1k#Huy9vy#Ss}vcr}B9Gtșʹ:Fw/4w>99I#DFsҜA4c3o7B3mplh΂k*9;G,wfF:)b,zàhFZ?7u١$ZRd]WC,D-:C/.:0J2Z8z:j<=>@:?ZBjDzJj* NB!RG9Q7ySAU 9b4wCmkZ&פ[Yqvyj 7koʥ*Fpk*z-ZYx֨꜐juIHʣ %٩J%$mXpn,kpĝm~W9c3s3*mIm9G5#d:9)r<& *ԊDz>wǪɬ͊.Orym %ZVrs:#tJ@tӯ*;ZN$&ڦ" I;) 0fB[+AZ⊫ZEzh֧ i"[_@] {ʲW/;h1KZ-+;f=;<lIFJVsTU'V kA;PjR#>Gʭ9r:r:s[*t{v~iCfg$k۩'n{;ҷk*¸h'w&;e\ZǴN;[M۹0 {p)-6n3[{ۻ;[ۤں[p΋vӼ[j؛%[]۽Λk`$kn+Ӯ'WdvV[EgD>3>c8Fx@ҭD۾s9k$ J aЭj t{@ b0&wJ}CRvse(*,.0' I@G=8L†> 9^<;IJZFLHĠL\uHRɏK{Os_|L8z}|msŕ|8 Na}M-mYno Y.F)-Z+7 鐋P3[?FQϜd[,>m"GQRQe--\IeR2TVp+ 3 /XFJ%֥דl^gzeK@ H{u_J y-|ݍM^|ϧ}a}AX,c a6M!7e- ̂c\"HR[ UA(ƽɍܦ2u2"|8,HTT٭1J `ċNqWz֢ _ AXVUiZ T] <}Ӈ^bmt˥}ڃ !Ҍ c<iQ.H[Q7>R3r05S%G84ɊS+,pT[NU־^B(}@{g%hUN9aUyPg`_^ M'N^o)q'~dDE']~8&(>yrQ9J5>9^ĥ㹾\LS H]F^y>5 s݉ݧD^tKeNUz^UNN@|T u͍M X(NN͖]~a>YP(O)&=+ڇ.;P9ېI7]dEd(O^"B"*[ͥA>:3Y7(EuQJTXaA e g^PtDՠMMa v/Nn!Oɐ`81Dbp`b&4TVrDeLшvݓ\vĄ&', -.,! &)++0%! @CEG:,ft QGG`$D!,#LR%l'R)+R-\. S1,3LS57S9;t=? N=-CMT? ]G!TIlK1TM״OA UQS@UYmWaUYi[qU]y_[- MSQ-KHIVemgVikvZ褙YH EjPZZkxjGZ޸[3=ri>ZipFcdnTƚlG_'1]Yͥ 4m%O?}K?%Zi2bٕ=ZߕwuOpԫzZ1sWUwϵO~OT؎O߽K_3@LN*` =̉,R3ipl-ˆ]HE3R&Kp+B%fkУԠw-P\Ȍ8 oIs)r!+ApaB3ȌvDybtHB(BP#ʆ(7c HD96ZOgݱIp4]ɼ:c!A|`#ȵ1{d%$IQd't:-d)QERt%JYP-q>B撗d,}LaoQ`t)NIM+aaӖj " 8`saSno.f^88+N(c#鷻MSӴL-fHOsӟ<4fN4 %h!QNE/J>sH d*M1jgCCƂ.ԛ'%M6ch)FnTA~,*U6]F?]cQyКBӊhO[jZZ_5+^"guMR"o+$ʤޕx+Y:=x.~U^(*Ve%9vf,c1ZѮJl<ٯj|d_Ok$&ɫdmk'Z]N*N泐e줇[R_F4,f1׮ѕ+tzEŵj7Y}w Qiy*/rco(V"V,x9*5pMLWj6b XʗkLO ^އaxJYO5ߌKlcljB<.96>cLX[*^-f[Lg.d,IWtjpYEp U.t䙅tOR*~Pڡǖ-jf4 1X\o?ДSskg$EtC&NŐӛzNǡ~5m'f_Ƶ"-bZֿޙ)J!ۗ6a#d-[f6seDR1voyϛ6GsŪf>nw'Zx!.Gx1g㐚xAΧxQ}x,]J_3}|u/eei5i9xأV'}K_v;yߝIyg<]ЖYJ}Zz||;EP<|ˉ^~.3N7;zϛ0pdpp 0o),3/58.ADpcMŽY]a0epimq0upy;httrack-3.49.5/html/img/snap9_f.gif0000644000175000017500000000642314336470674013766 00000000000000GIF87aνޥk,0I8ͻ`(dihlp,tmx|pH,Ȥrl:ШtJZجvzxL.zn|N~ H ( '  Ha#g\C@8H!9~츒dIcWlƝ/$ϢH 5̧fhSNG.kKEJ6TU7ZY2[e󆡈6mۯ ӭJX 5T(Q^f:7̍C_yl/e*SM-lG֩Ug]Ѹ09 N8+|УKNسkνËOӫ_Ͼ˟OϿ(h&_o5bZF(VhfvbԠ#f(,0(/R1S"@)DidW9"ҙ=bUPxXf36Y΍%QFElf^.$8$[uy4LJŦ'W%ZJxɦSkxo6裎Ʃag)g~aӡVc٢lEjP\کWz[b*j($[2S*dؚ U+Ov Bl^ JKN6.ƩWf,m" Tj2\ZT5lZ# k_  EozkrSh-qˇդ3CA@@4DiNljĂ#m]&|h[\#tl_tk]N7*b?R5$6] }}tkv}6y9/,It+n4ъ//8Mgwp4醛o7n7~崎X|<; ]4C;Ƴů{z/~X> O9KƸ%v#sAR&|)%y5|e#) IzZTܗVF3В0'e+"-#?)̫ƏU.%rT]>̦6nz 8IrL:v~|=o MBPRp8p`'JыL`Scc)UKR7 /ڨ1J'k(Jg:^AI##Lq@M3\mʏli:wNAMPoLr4QSQ5T+LjK Y?}EP ևQSlRX6B1z#\VyX۞AUY]Kq5㰝6 =ɍu&.t{0R9"m]\`AwpU}7fK+,G{qX[(ږu'ܭNNiyJ9r놾6,}+sk!W*s[ka䥘t V8$%pDkhްG 41)W,#*f@1Qt!߸ˉ̂HN%PL*[Xβ.{=D2w "_[HjrXcn35JnhJ@rVB )%3G懝́8GNBHťO4fH- K28qPdH@4+C}aOb3Bua-$L{O,$Ul_iξddSr٬ aZ*N%y/9k>-ff\"?ET? =5,^)ݳt1.x B/-5K7snRdh l!B0cKzI0M29AI@}4O_ԧN[XϺַ{`NhO76Ib;D#IrD[w7{?fM0~m-WvWCQˋz95ρk.F?늷LʺSk)KsoeExW{[ޮs_K|ljyV +_HGg>k\W8׌Ȱ _T- ?G\זWGG[Wzt:rA5i4qRyrFjwLi7 Iws0dPw E''xu.0X6x8:<؃>@B8DXFxHJvL dD[}Axb!7{$wpb{3K^dR%0wpn8v`HMu$p5X2Vxuo׀gx|e{~5oy)2xgu`(.gXmHsxzx3|lwfdȇ xg1lqITUՊg|rXׇitgzGnqĀFpxuhgňhɨ~gӷgg(+eRdhRzwpއgԘָxȆF¤&l8yhǸu"$a؂Uv+iv +$*,ْ.0294Y6y8:<ٓ>@B9DYFyHJLٔNPR9TYVyXZ\ٕ^`b9dYfyhjlٖnpr9tYvyxz|ٗ~9Yy٘9Yyٙ9Yyٚ9Yyٛ9Yyșʹٜ9Yyؙڹٝd;httrack-3.49.5/html/img/snap9_e.gif0000644000175000017500000000660214336470674013764 00000000000000GIF87aνޥk,0I8ͻ`(dihlp,tmx|pH,Ȥrl:ШtJZجvzxL.zn|N~% 8$ ND[0;z jPB8BaD"wAGWn!S .$D֥9s%wO SM]ˆ&PFx0y6ٔ$t:ڲבZo5iUYRz'خjGf*,ʝNwٳWc݆k? M;|s'b*ި7ypd5LfmFM*Tũ{oܿq&my1dI9-.u.^ރ_˱୆?gjƉٲ.qսMyau9[-en*Tq%TW)VqJ(5G{VZfH~bFwY&e؆.8kU@c;I@)DiH&L6PF)TViXf\v%ژdihlp)tix| 9j衈&袌6裐F*餔Vj饘f馜v駠Bܟa 0@ꪬ꫰*무j뭸뮼+;ˊIj+Vkfv[+>l覫  *0 +l+ ',W.~CǫkȷFL3,bt ǻ ";*8 4Dm427@sѢ0 CݪPjW=^]ԪB5F5dLl4M}a+vg4Y ޵=ی7 5wo9֠1\ʗ?+;QyМ:֨.x v9{'/k ľʹ|{~O|ރ_{ʇ/~/s=_{ϽQ}ԏy;rÝм&6jYS 7  avl[\D]@x4ʅ' Bիq0 wCwY5[H" YIB&:PH*ZJ..ac}`H2hL6pH:x̣>ы IBL"F:򑐌$'IJZ̤&7Nz (GIRL*WVbҏ,#W&p-KMre&~ Lm@-y@bb6@vLgZ4mLk3LZ2 8A59 p@A9na ٌ>@ꌁY92}w)UFFI:JѐbH]z ֠B)Mal;EOӠ ^JR*%}TꦧZXͪVծz` XJֲhMZֶ6CIC\:1i1k|3CQ̄W Ab# *Q `WgY FG0'HDmQݧjJƞ@kk(S6?YcZZAɚ+f\P`^fsmNA*M)rE\P Ϟi+4Ez{38y;*ۀ~PMiӟM,4[SE uGy^6(lyK*ϑdr.Gu5s|䵮r_b:|M(C=<(gֳo!q]˪rx,{ "ư1z<?Mf.(;e {tBrߋ^wȡ0C kb̉[-YrzKhN8D#nwZ =곟]( å+= IӠGMRԨNWVհgMZָεw^u]`ϝ7lHs̾2alt1&K{\,ڻhq04s͛ X[>$C`Ż! kXy|b߬|Jܛ 7,N7j,q\Pɼenܰ--G@FVy(6 |ߑw@ЇNHOҗ;PԧNkV/TgWvZ#ȍ W( Bv2gu74)'׌~G+d 7{hr3߸u[;Bs,>h.v@Ӟ#ȳE&كz2>ˈgA2\أ[l><^+n3.x;KQ?%5pk5~᯿_o̳,r汾-q2M|߀.n'7G.Wng2n[]){A z؄= UN62,6S1Lwn' ̺? }$D3zC?'c7LϏ_~?N9ׯ?ҟTzw:Lseo\Gr0Z̠7Ar,dػM/tL;uQ/^!϶F0m u;/n'樂@"HÜPH*ZX̢[фVH<ʋ<@jlhpL! 5MjFC4LRHsG@)aj63H8:YYҀi<55-2ǫ1R *?cI?q,gIK9p^ 0Ib#.蒋 Pf3IM<3E]Tnz9$'3p͍8# n~M80N^t4OxS8@JЂL;І\ܧC'KnQͨ,Ejh= ҒIX$IW*'^Q,i\jEVimӞ*ITOY$R:GU2*dYXͪVRguSJֲ{Wv"j~yrh4up<ּvl KX멡/ZAv5b!mPjӸZ7mn}1XJLhC {=6]\62ߑB i\? pKMr:ЍtKZͮv:o9щ6,nIBz1-Zl"Bٲ0]_gR:fݻ&wjAxhOmxX@ő_ \Z0>(%nBlc3¿Ѩ/ W"#kq#ȓKx 8f豏}05e`벉)L\sV8 m>OvdCp@Vnp`Mh9nv`iV!||WVհgMkR R^[@w[Zrf^͓c6_ڒXrpY;N [o<W>օ]NmGM}\u_j\N;'N[ϸ7^z J&BGN(OW򖻼WI6JZ8Ϲw[.u.D b.󍷽a V4++CJUJ=JUjHRщNEQz ^"|p+d+MJn|?Mץw;=tdOxJN\%ɓ],Ftn5ThOKcW>_8=ɭKuڤ$W|$^BmD|Fe7{{_<ϷO~'Qkp|$?8v0Tzg~4~IvCp3QmJhh|+0e z̖;o.g#4*}"X."+8Gg4f1:Mbf@jjgȀADCdi(C`!bA=m7N@V/ECg0vz`-V ̶[Pf F[vEwGmؖ3UdV'XYaQZgƖK36i8esC f=);h*Yiiz wGxz+\(\x{,,,L{$ukİT'x(؄{rH!!܆ c˲D˾ ZtˬdļR9Ȝ%̗Ql9<U͕sr}#73{3#77F-"7> RMs%A Rqe> Ɲ$BT9|&NQΉ->QXP+*D8:A0̬ŻD^FNϽxC~NPU_M Z\rvV~Tf~h~(HU䟒pi+xPnmYz·^~舞%-zk^)\9ʗ^!9.; 84HٴiӋD𗣶s Z 6֓O>jD79쥵>;pzWHK5jA?7nivh3q@z=v.Cv5s$Ǫ.$)߉)7NF~h'SLzBoW+FɩWC>/<:ʵJ90oR2c`)9j[mԳvٛ%;[iUPqKޢ/Ho0>I׮UN'hqld v.sqh??vzZr^j8^v@^ f]/qa멎ltOepƾtJ0)ye 3jh3]zYQ;ckD<ʿ?_؟ڿ?_?ڐ;httrack-3.49.5/html/img/snap9_d8.gif0000644000175000017500000000670514336470674014057 00000000000000GIF89a {Jε, @8'G8m`})delp,t^f!: PRID:;ͨg|B}+73 I5喥]mN~+(G"r,5ano*qZWUgKCjmp+[_IT;Dĭ2 'H0 A \ȰÇ JD8E ^mǏ CIɉ,R nbeU1hbaЦ? 80bѡE"RJFmJPNbjRɯ`ÊKV"hӪ|ɯOʝKwlǺx+Rߔm7 !^̸^jkL˘3gՠ];t=+M麗%㱙U>+mۧs;5[ _n>aSs[XУK;0 Oνwխfx.!LϿ(){ 6`F(Vhfvx` ($h(8LV4K0ڍ3hq3c A (Ԙ+fؘ\.,"q1% %r*ViXfy"Q)G=ҘC w Rdg9$pN"`i|矀*蠄j衈~&'J)g0„cqT!馕j&F6âq&ꪬ"&무 i[ xy7&۝`驨F;Oq@lB=QV9USTjTSJUE.VnH^)+nT/$ ydXa{X\Zxt 7;Ml7glVަ},sX2d,0\rtv 台Ac '[q@-4H3kk0LL7tEETW4Nm\|/_KRO4hlv1Hdmx筷L,ཤ0A ^6ʊc䔦RxN\3vLw>W蠛4xBIE C{ WA:񔒞 Eh։h't3EZŋzњLZKj͑?o'H Z̠7z h=bq\TB0x0L!zzcdĻ(D]¶Q'85NAK~K $'Bn:b/&z\'F`Lc!\25Dl:b׀a>`Vrxۄ&9򑐌$'IJ2̤&7Nz,[neu4/;* GߑB ]G`?8)񒮏.BJU-`k y)Hz[l9kA\25tk\ g6sIp!ݼ7OBbnm& ۍDP=~Дe6XD#P]ZABRvZKi*Q-4DYA+npm;я&-fHA䙔.JOd+48> x)pJԇTQHZJ^\5txq_H8xgM81+q엣: =_s@Xy! A?=_O8u%3 [+7Yʲ33ɤ(0=C%(ٗƱO5&\ɪ8)C= 9뙪)89|h oYc؜t7Q< l Q:AtWVհgMZָεw^>5CuV1@c۪$fj#.8]dBc"4I\ClCzK3EYЦZwKX~-nP{1Aj?4W}FK:ɸ3}?-Tӎ>.t3%N} # s濒 tnα@wStQ) t9*=Mcǧ_e+>u}녺vroI/HAH.RaU3xϻO/~>[TRXKit cmH@V2a=="G2 _աIU.o!\GgsrӠrB|oDW|L?1tJ5/Lk3K> W' oM y~0-\ve&p Ӕz2NtהzX] :5gp0W@.||.5X}[aM8({G% '`uoLX^e3%A-88W~uhI8zusU_~^xz1Q{pl8ysXkXyww|21Swie]x~X"~s"PvaY!(8X2+EŊxu"-C5~BMe栋BTws##@TCÌW(GG 3gFnISzȍ.5Uܣ>c~~8VnFfNq&Hhoi-^I'=?I~eJf#7K [YRy@0 'T[`bZx%Cclٖn!͒Tgi%\xzv)YY[[u6sY%ww'9oCwyٚoFEt .g4vtDEr@_ ƛĹ\V&fg\qfP8[q=xVi&`xi $rm*nfe#j8WA_7X_ppݒ%77bމ8(Taxb:OhfIA[rV_oV3^+&ւ'qY>N2 XCyO&<%*]Ydb"(&Xf4q? BDJVWԀe:I!ڝĹr©x;httrack-3.49.5/html/img/snap9_d7.gif0000644000175000017500000001753014336470674014054 00000000000000GIF87aFνkcRsB)91!ZJ{k{cJ!11B{c111cc1111c11RR111c111c1ΜcΜc1cc,F@@pH,Ȥrl:ШtJZجvz$Rv:PkGA F]χ |        `A,X@JXbĊ0b(1cǍ-x(dD(eJ Sf͛1%O$ bh *M* PJ#D!V 0cЂD4l0;w@HP"=w(24#$ kJS Gi rf9XV[nװ]R K`2eb?Flr{!@޻v}8pABD;E#>pQ<#A<qU/FcUT\5#7Na#8v?DiW`PċLXФNB)PNe0rIXn饓`>cVfUypƹErixt矀*(}j衈&h.裐F:dVj饘jAinU|Zꩦ:*꫰*무j뭸檫"`! ddH,jɩlF:괭>B[-*Bk+I>첀.@;oޫ ,p #7 W.n ,$l(,0ǜJVkէڂ,3Ѥ=*CϦB}ަkX.f_y[gg-kڱpǽ6mxYw|{-{g]xGN?bXXY9UJ.PeG` {IH?~;NV;]#[&i^*߸{?S6oڇһ޾W6?o#n<+o/qMcb%xs=ZR7 r |CHj&L +j! gHɰ8an <H-f%$bcXe~cDK5QC̃`@A =}qQIʧp&xG(.d)HuId —F `$JVD'6OB2H*LRxEg:s ] M0TC6%4\oz3Lr#809uc;X:$Ax;H8/G=1 S>6gKz?>A@Miʂ2% (10\!.PD]G"!$@b')0"`6cS2<]e->⨥1 jA$55|ydFV1pG8q)@>~d:6Ms;x̣v=zֹ$>qMzޤ?=O@O!f%Q\C`ҚL"HFDh`"AILt2dn=ۛt* IU*SBC4F3hSRU7͍8|cENx㜴ҩNu޺&;ݙyC#U`IRY,~X<J tY,KI=/07lB6~ޱ0ί}b6{l^8cKNw,B#>1|c62a%9gqL*kaˠ_6 FڵUp9ZKV.mߪLrBȲpE|LBйV ZE3 rJmt.NAnsR*̥63Ej5ͪJg=eO7Z(M^r5$ bNvmfr$ /]lcr DdoN^7=8*@<qozx˞Hg'vܶ]~JkhyW"u3Nb~Zu'\x]xÏgjw1>.FONE. V.JqQz#5f3t- _{юYrH4-rfx>Ǎ?65wz0{GOқOWֻgO=5{Bˡ/@ `B/APH2=#aGXȤNhi)?ATT@*&8Ms1eFOM/1X xL5ޕa5V h@VluM1t^x5NE__X!*`)1OV`6Y B B`t 8Y YhZ"5uQ"EzH !Sh}}P ` G :U c e \T͵\qKRKVuUY]4EV xV8$oMMQa5_eN#ANTO,X-X$Y?% V Ea: o!Gep+PQP)QLx*d@Q87}.uAI1 :hSBJFTAK]1 p] [Ea LДfŀЈn^MhW aAUNXNq/1O ;Q@4uEaYBEPI xvq1+<}ZE D[`Iٗ єG~D gi\ET﷎TTQU1LQ@VLt^ Wx9Q_!X"%_*՘Y*I4O `z>u5{Y!Bpٚ[ĚRm0&s6F9;#)b@lWqfm gro@+6b,8kx=cofp 8y"ޙy7 vyYYuٞQt9IWYtsן:CwyAl .TgcVF6ei i:xi44ef4A-jjh+J0jgJu@s*'cφ1ڣ>Zk3jA Fzps2B Cڤ3THJeÉnoc ĭE=E: 2 v#F,!sZ!1c[ tzr2"!=h<냦 T) G3'S yX{/ɤ^u]}4dGf{mjDl۶CpG`;J'vu|tx!귂s[Ikt~g7פM/2Bb[{ۭIиc)vw\Zw8ZwZ*Wsr7V1g2$Yxd#ɉwv'#BG,wxk(r#7xM{zzz{yqۃKl%4!z \|ʋ;|}5CI &|¶@ ,.SiJ~TñG\9Kt@g٥Uj)HVNvtՐ| _XKQ{@6_R݋ZB R!PtJvm` OE]XE hUʴIt)ƪ$ B`6` +eՎ$$ŸZH+}]J =vp\|} ]O2 HxMmk( n_]_#xB,It$zL%kHrJ*Kx .W8vـ@y !#%!&/13579;=?AC9+DMOQSUWY[UI]cegikmoaqwy{})JYuq3!#5 ? ,~x%<8`EJ'o#ŋR Q㿐PZg!B/xE3oVDWOgϘ6=Ę3#ќ 鵕Z*)ͥTqfȰgȚI=,M[6U)$*:$ПU*2M%4SȖvmc`mmt<28ȕ1gfϟA7ti|FVsj֯auvmom n߿>x-ő'Ou\ys磆=>}sױ{wѽhx˟W{VlSWbPshKsXCCw14?#/__}ӆ~_o~|ڿ_?ޣ4/ x@j# t`4@ " **xA BY#>AuPo"0&`KǿtB6}<) H֬M! f,@,^EvA\uX- WP`2tx /"b_Z͘WQmEjbx1,i2†(j50Y5UJG=h*q91phj,r*u&Yr#>MM;Z!U%U]lm۩6} W"$nq5x\ZP˕`s@FWӥ{]fWnw]O_y>W}eޯVo}{_W5n\&s |`&Xep`o7} 1|a gpAa#61S[(-vacf;S*]@sajnkwDZly܇ d-rS|\$aɍ`$R,9>]u&L cDMHy4)ʊX3g9jDD?R*V f[s!McIV5'Fӹ3TDEDdw.<2Nj}ѳu}fX_hkM2!XM?\QxUjd^gmmoۙj',AB+"Ot[>f7y[wm}p7 ;httrack-3.49.5/html/img/snap9_d6.gif0000644000175000017500000001744214336470674014055 00000000000000GIF87aFνkcRsB)91!ZJ{k{cJ!11B{c111cc1111c11RR111c111c1ΜcΜc1cc,F@@pH,Ȥrl:ШtJZجvv"Htr\lnL@ z~{ ~     | ,` #>,0"1ЈF:b I@I !P^ʄMhy`g  ! F"PaiM"@Cx @k1"thAD6HAO; 0Q dQ_D84 3!ĉӄŢ4@V -BK.a!KXgMmmkeۛq{;x[~>( |}bÊ`~yMiJ(WΔreM/oٳϝ@%Q@S"SLńV\yńVhfv($h(VѢ/#-xU5RUx?(D4ʨ$1/:T(S>I[^yUMȥ:J$gj%F[tixJ!g|矀vgj衈1h6). 餔Vji^JVTJJ**꫰*무j뭸&FhaIeXi)j"Ϯ*-Ξz괝b{mZj nk+D[/+pl 7 CpOl ,"է ,$l(,0,3V*oy6;mUق* \ʶo]Cm^?ȱ|{- v'W eSa#/nT4j`n9eʘfXv3VI~:VĞ?:,6Q<+;c.9][Y}&{o}o}O:f$j^8G@OXE]/u3ֱgyĺW2 GHBM(La_pR'| g88 sn> U!!D'4fU+UDJ}lcPDB;M*jz`D3a"!GkuX%C\@oI$H@e/#0D% NhEdDSd*9 p.~1`斨ykgT3ƘpQrG9`<1wt9`; v*rrZ""9OzS $I}j2OG?zrh*QAB +d(A H0D@`A L:E.x A%_ 0PDe,J H&'ԧO]I 4H*iJsa5hk:P`6F7p :ch9HdN@|3;Ed9O{0w=,|ZR6O.П32S=]V*P1$M-VHBd" !Idr$MAP6 .+[¨R`tF/ІV͍vq,8yfY3^4gpftCw$R"aSؑ {{/|&fmH|,upJ1(۹tߛ'|uƍ-xH7Rȏ7m^s;_j7#.~.7MЏ#_|mr@σNH1t? PӣN MXճ5>萒c{ CY$s b.9aeMV;*r w=zfO<_n;)2'& ϼ7{GOқOWֻe?x^H P@}KЃԎ!ldk]+Ev*uD&mKl >ʜDEO[yUҸLh o;Ay"Eqr7uyYYuٝQt9IWYt虞A 19Yy^Vv@FlZ*ƶgxwVimf+60V&>Cj4&k4u6vffj (J.jlRd&ɛ5l 6zRj֟8@5(âţ쩝y薤AJe5iQDF HNZei6ZYlB4j2g'f*%#z4"*?$ *zF'r=*o4fjDSF7i4B5u5zzWz|zIs?aOZ+u97B1Ӫꪴ:*yJE :W:ɤƚlȚ̊!.>q^z9Y3gxc/9qaAj"i!S9sq,wIBDw)&&zb֛ :1nJo6r+v-';{q(歿h;sqZ<*qs rtR02;v?Z69{( )h3ogp/˴hvA 8e=&ctQ8޹\^b{d[yh۞j=nGps4t;Ev{Lz+jm۷ƷH;&w}xG /k/K/;˹۹{i_X{{ 'hv{ 칺;wv+xSZ@iZW_Pex>k^wjw{lk6;[yۢʋ3 `0{껾7ʸC;4T+C^q˫<[l| XZ||{QI7  < "<$t«P~°p7SiKmX6\Ua> m l\(xכZ꽇d ] h^֑!")ه \a &<]=+!{cQQGԈLt0nq-N؄-nRRRaܹ兝8ST eH .\j \Y W\y=Hm4M\oċ(AW 9XXY*\6P.vM;7(ns'[Q 4*`*Q 7N8* ߘֱQFW ŐtUHޚU_ޢLޏ,HJ\W_s{ a-!N V̕=ƩP;Y>PQ"G9M7<4[~ k~EMo=<7KNÄ](VU>|\M8oaďW|T˕=>/`^35} &* 2>H]IU8}\}}dߗc k i\q Tː ]}%- Mo`x_S_X>/8` rɣZ^Y~a\6i^?n^yo  !#%+-/135(7=?ACEFMOQSU:W]_ac#[ekmoqhz~}ׂ~딱swýͽ{ûיߧտ96Դg3 \{{GL`~A8#U$n`IW[QG GlJ94|櫡LAv49ʚ.fpRJmҟ.&ӄMjwQ Q>*{m[\iƕ;w\w=cWo_<0]'zXqcǶ?zuױg׾{w߿/`'ЧW}{Ǘ?~}׿?{."LPl> ",P 9C #-0LOVE^T/iIm+uK@}r>sSRT*P-jꪙ2 /Ikm x_8]A^cշ@; >7ZK>Y”EFAIb'ƹޕL:SLm`R{7ִWE]8 i`N;S1TO֒SS?z][M"K\-쪗Ujf\kœTsv辗_F$ nz<^{i`{ú^T?_}Q_M_~Ÿ_P?"4S6(0 <8+XzAµ$|fP+ Ib'oDBUN -8kʟ. +>fх=Mu:q^P`E,n |ɉHR؅/]艊H xa_xbDPpYHD:.!=RPx|G4 cQTYBAZđl4DT%7;Rd9vt[3>Q6H 231&Kc2&T 3sY;iP!'%w8c#!fYHDt|UqK0enjxRe6q⹓df|Yjv,7qKY/ь'1zήqdg$GRzd B5b3(F F)(L&"!ϤDG[ Nr ŃO`ZhE5Q M!Ԥx+'/GyH/8SK ڳNg75k~~ZsQL(6euw=KUxձʴ&sh;|aR⍛,YjuMhMڛc jkAZP`mm?v|W#nqw\O_s=Fw{ӥ{eWnw]lŢx[׉e/Wo}o{_Vm \x&q( vp!` Gp1|a cسEAb%62Ev.P#ƙ1ib5| 4fp{\]Ҹc0>T4 Lb%Y M^͐((s4ÑB+~2ʾ榒$E5'+z's"Eg|E5WmÏtĠqU/FcUT\5#7Na#8v?DiW`PċLXФNB)PNe0rIXn饓`>cVfUypƹErixt矀*(}j衈&h.裐F:dVj饘jAinUZʩꪬz*묫J뭸뮳ĦG+$Yic\&jkʳJ mj*BZߒ ➛.뮬2 o+L'\3p?,G\gw/ګhӂΚ,jr\r̥M tZAPQR'yn- z2)QNlh3Jv$uHw t5.r"CC55F3hSBW7P΍8|3ENWҩNuB&;ݙyC#UI:90~`,x 4a,K! kX{ѐ#MJ7+*57HMduњl$&pi"RFPkQk(Xڐ]za~f;Uap@iЖ̵Ky5DuU2-=?nj=ms.!_`E\/2iK0nFtUDH-[\wpy'+8B]i}0gNsN xyKMn?OЇ.tѭ+χ}Iԧn:jNs# WwpJro7'ro&y2N܁e.T{9!;z{4+]Qqvʏ]{;̏\^*sRk)GSN*.^}iJwE,D|0.Cbl52q|oUY_sl{}S~m7׿s1B 2%X ؀€X~MM"$2wr(ARmXAf7"!#YA1!hpO0 -X!/xL&'|DXFxHJG؃ȄPR8KhvNx@\؅^`b8dXfxhjl؆npr8]XxaeP/X1%E} Eb%vb)FZQ,/cQRQp[% #URAMpZ#K"F#N><,;igME,njB1Xx'*X|D|q)Nz'ey: XQ":9:xOijZzFګ::zGpڪ–mGd4vB=Ϊmjm7OҚ|GuXZ\8L07xz`&tʤ6JtöL]rKsW:DNt$8A8JuA7t7sA˶B׸{;:β:uRzdK6u`nOw7o7tKoY8[S?S0Y/P$vSKÛƫ{˼λK[ػ۽KwkSc yǂ#+l;gyj.wZ~;+z++kC)r̳C>;VȣO#,6 w˧ʇ|B.h62,&<ʪ|oP|%8"e\zy?kCt'DL;촚,5߷FL{ k}*F$&YSnjwG z̿Ēy+qI̓\y\?_ʮͱ,$ǨŚDx:аj} MȺ[X8}-m "= X&m(,.2m)L_ӝ@/p#P#5ş)[xc`ڭ<qdYSF!j]JT띛P(@a‰^yUXՔff8_5aEgu/H u)WJ#^g'{92PEP Yِ&by )[[QEy=d ad%Q޶RF!T5šZ%^=U~Vug1`c^خkE^nWIg٤"xE#X"wz)ŸvPYu**/ ݟc*uP DΡ"5N>됢+jPu^]fY!p&^gVH{ J*a{%xXFfwX,`7iusYوIZ  * U > +Yd)G~%% 0ȃdid>(4Z l`gHl𷜞yC_ .  &!%%1&,C&.',.;1>C9-@-LM TZ]WLcRDbZFNV\Ndrs#++8*+)(*(6))7=xA|B :8D *:Q=|Q&Qd+Wd e͙3ΜC~!rd#H*)PHU˕-]dE2jҸg,wQgO)B4QHw1<ңL6Y'§R cUhɺ P01 3jİFlF\;ȭgOz/@"OyÈSQƋ!Cv耤SҁL ǼifN;{&/H?_i* 28`#9ƂP9Dk 4k5˓MH@1Xh\2 j,x$f ,#e5ods |ܬ-.  S!*ȹ".:@nO<ȓ)nZ=+С(bʉGBR@K R0 8cIP >8<$AldJLEK+x=eW 6lcM6 H$dIi͜k-)ߙG-3x14tH"60(:#$$%>a&Aqz/C᳏"rbz J@8PÌ5B #,CU>9A\0VH25DE/|.%kLZ饙n駡Zꩩ꫱Z뭹^Z2.N[n\ O\o\)m-\9F=]IQO]չ>}i[j]icٽw}g]]}wف]̱YaŜoݡoޱwm={_Yy]~zW~|ч{1<wK_O|۟AMss ?{l5;`PK )Yp׿ G@|Ay!(C).CEUQ]E0e͘F5hltF8ΑcQ}cGA2q$!ib%T!II %VILnOd'AJ-R4HyJU2id+JXҏ$pK]/La41Le.\@lIYմ5Mmn7NqZitZ479qt;Oyg2J#:1y? zҜM%)j*4d(C цNhYPZ %C?(GPҔJ!hGQJҒʔG-eHWҔԤ:(NwӊU c4ы> dBk ԤTͩJa*URգU%N:UZuBkX:ҭn5Du5/J.i#!G'qZZJͬtKX"YٺB(`1W2ͮ` YW/6U:ӲEkR*ml_KY˾=ځք<Mk^:r F̒er@CcԒ%s\܊yg Jgw)*_Yuh<+ڟ ` X4f43|~FӐo ;ςR2QjUխvakY:֐t?J#W{k0Z40vc)FImZOնjGoŽv !6&Mhvjihݢoyضv ͭ ig,wS#hF^pt _1p |xj{w#7@/n ţt;|Fw{19m#ё~,Rη&l2|Bzs_=_ıuUOُUN/wM˵u{{4wU7p?yx>jGS/~v}ڹo4+QuT^>'MԗfWuev3'/y2>U^r|d3&~^V[?ݷq|Bҟ}꙱a6?g>oY%>ן̿97Oo OpPy>ПV0̏|\04p)/2O궆9t,M֯LrpȎϴLkʳky'XmsbϬϵ, \jO 'K˫(v̧|˄-PD Llo̱n0 Qp PjP(B咰\qJ 1*+~ƭ' 19l*YGW)M 7. )MA#QlQ.Ͼj踲<oyf1Ѳ-||Q '^}Ful@0 ̪ oM Gw P!r!o O0%("#)k'yP %q F&g2)&#LҪ1jq(7Bh1%+'rG))?)2-i,q,2P-7p-1. -ŌQxЏYr  qf// Y/!Sr1wk'00p093%}037<3.1Y6_s &6,n-%s8(88s9eH7999s:I9:KG:s;:;5G;sS>>>s?S??3t@= @A4o tAIA%ktBB-TA14CtC9t@=C3DEt?IDDQt>UtE߳E]t=a4FsFitpQ<#A<qU/FcUT\5#7Na#8v?DiW`PċLXФNB)PNe0rIXn饓`>cVfUypƹErixt矀*(}j衈&h.裐F:dVj饘jAinUZʩꪬz*묫J뭸뮳ĦG+$Yic\&jkʳJ mj*BZߒ ➛.뮬2 o+L'\3p?,G\gw/ګVl(,0,4lY)D"騠tmH' a5Yk鳨b5\w`s<[mhYvlk-t{%glS,B7J1d7xqc%_H&Vw_n}yT)&mlU+挧 옊N3k{/|ou̯|GWo}_Ud-x}:뾷 ~j6~7A>4$֭NG_66%/S_ Q _%m|'@! >允 _fG0#vX L8fD&>1 Ɍ"0*؊&r-tAE^4PS а3jsgt7M@rюyG>G NvCHX#FF$xOI#Ē-~6ٓ)(4J5) BeTV*@X #HD Tr[撇Bu^h0 b EXDdPk~1 7ʼnʈ3.BӋv4!_  mnnx8AC8ǙNLk.9E+F a͠MmO57C9&9=sJ>J:9d7tg"y*RҏT=)%JGK'LSSO*POU.啸}e,7 .(YijCLWcKw>׀c'\CExwn=zٖj}|9_,lͯ~_Uaq]x5"d֫m9\"H`Kp*- 9!8K`,mgLj&Fqp<7Ջ,h"Jۥ/\0L*K2 Ld+{`ƕcn@>;U5mu\0xL^yC{V€Lh>pXTsD]it.5hɅf^3#mӠv^CMj6Ԩ٨Sj=}հЫcM.ָ̺­sk>.ѮMZT d~B/q%A,8[oN⊛!h;~f[vCQ+ VqFz{W 4QeƷ=O;'N[ϸ7{ yȏ=s[exAJҖ/xy zBU2!jhUg>5OtBB$b7 %"PD*Z]4oi: +c5xglh|憟M7F8hBnuchwbG-C=, T;wYY4Z4IрTy5ay4I8>S"[R5z 8"g9&!BKgk5T{Bt{s&ڝ;\"6г6=%94ښ9mD*h7FJ`>lCIn59gɒ5ڒJ:]y\WٶKJv:<:S[;_Co0sڪ:ZFr;nF_cйSVz!ɝ rjĚb.ZT1]ګݶR{o 42`㖮kaɭ*zY1n">᪫gR鮀59"D馭&?"wa K\@ D[FKDR'uMԴp}WGƘEݷZxX{fPԸ~`{PkufkGehYpHRt[vK񘷤ŀ+4Z=aBQ[J< Hz˸Tw0{UųU=CD_utDx ND O!WȈu4vzeO׵kvmt%ȁXQX}m{s;&ZȷѷQIZZT CjgdA40;0#@ssC΄U[[|DMhDue5 ۴;SK O^u`ąػ8liHs kQU4HQRHHz+IK;Jk{ Qᜠg',82@{gxG Lnj(w  \GM7NJt紺OkVV \W°AW³/EFwšUPjGA|t1כkxQdIX$zBc9Ff$8Ke(+{p1r{v1yyC0TM`MI}LNOVU}tP _Qл댚|v45밍lh{>l;Yg命%OHMAD|TNN/A70֢I8:XJږh[@d;e]Mb9Wb[FnNLUO91]@9]bx]^؊JB?Hh\ϚX ieiUb/.yG?}sZh?2YIJ\],F0/o>Cjߦp??vZƟ:?ҏ<_r/)ڿ(#C䯩ꃰ?"ک?! X4IYQZ^Y~a\')\q^ȧ !* 1)5.3=?AJ#QSUWM/;*]fhag]no)s~amirc;wq{7C NY#'k7t}ۅבm_}Zp5|FdrCEKEq1Vqb@2R'p`{P_IL.w>13 "8|1qF9-4dG#OUPj>xJUifjFul`u“HCl#T)S:HZ.TVp$T1޹;`˗16sgφ"<4ҧQVhAaǖ=vmn@ֽwo߿>xqQ GܛgϡG>zuױg׾{w{n}0s2W^oKr%{k?}) \?9!)A<@r0 9dܘ( k*,M4P*!;"F$QIXҊ Հ #$qJQ)kȎra1<ȷLB"$R.2)ˬN+|/Ot)? BSCM< mGmcI)t/I-TMOA H,E-M==UUMWaXiB#mUWf_KabM)OT9UV@MɈ"fiEZ$Ȣ-tSlyZtmwxsDZy IfiSp٭[u(hc#X(1ތ9'R=^LE_bE_h_w9uuֶ#!˱~wqeNcCMΖ8gZ˚ޫV#R5Xl#kK:|lյ9pZjlmnĹ1_u!G)?1ou9AI'qQoY}a7iWq?ymށ_/m⑿t䙇g詟_vrccӟ??VO^ <&0y d`EP`swA N]=:L-$4a QxB+ta aBƐ2D C=C׬P!><e#lBD1q *⡠A)DLPq~[Sʰ.Zbr #$A3`nLc*H8\:H;Ճs\E*tJc5o$c EJI\d7JR_d,‰(]>y$Jx#h/ɾL/ -E 8Q:/H@ S,}BsL3%0JV 7 k/49찑d޶f)uYx<=s%h z1 uC!QNE1Qn ;httrack-3.49.5/html/img/snap9_d3.gif0000644000175000017500000001636314336470674014053 00000000000000GIF87aEνkcRsB)91!ZJ{k{cJ!11B{c111cc1111c11RR111c111c1ΜcΜc1cc,E@@pH,Ȥrl:ШtJZجvzB$Rv:PkGA F]χ |        `A,X@JXbĊ0b(1cǍ-x(dD(eJ Sf͛1%O$ bh *M* PJ#D!V 0cЂD4l0;w@HP"=w(24#$ kJS Gi rf9XV[nװ]R K`2eb?Flr{!@޻v}8pABD;E#>pQ<#A<OR T(e\N)Ve`B)f?neVaYՐI)[Hx|Rag*蠄g&袌qhF*F>J饘fiKn*VX%Uꪬꫩ*ڪ뮼Z+I|d>$[Qb*ԆkbJmւ[z{+/"!,>+pl 7 CpOlWw/ԫ[,0,4l8)X1A Iln<8}(r${hNusΚ4!D#TzhJOnT "e)\.K^Ѕ=q\-wOfe ݕ`Pe\KFrswn||7x~5omF$v/'M]SQ ]"We*t+i p7.v $*aoj ngL" F`|̙ULMEF+וLf^1r|EpՆc.7΋c3 7=3k].KL,@;Z .\J;yNsnj^t1H,QzԸ۱Uzm{3YۚO]|qa>e;[N᳧hSz[2 b $< /ݿ&pIIh/8nB ͣwIYpƭr3(ӷpDnR  iv‚?Q6{ GN(OW0gNƸ92 %=Ȫv@ k6qDJXBp':&>VDS-"[+.4~Fܕ46nAssPcctH:豏vӉfSRB!)diKkbRIMQ V)!emm{[@"Pzٞt%ԩ_@#X d.͜&BB_OuZ}%2b'jVB跅fF׶ӯ|e }p<(B:V8G YxxPHRYdy(ZZ4ZIz5z?JC>1T[R…{ :2QSCep+`LP)Lɧ*d@|7Pu_q}tA[D1 NE~cTQFuX1 рXp s %xAx|GdxYHwR y1AeISI6q/AJx;1@4FuEqTTKIAcr@REUbt˷}0NU_V V De Gtuvb'E@~g~r fhOvivdFdw(aPyDe$HgH"倕Ya83%8zzS YJyAJ('{[T (s i!$ i9W(Inj, 4 ג0i/avi[he1 "#i?c:i\R6nSh22bnTA!#"=ӕ`sb9WfphlmnrltYvxylz>)3q9YYcu6fs֘d7Vqf`+glGdAV=+/f4!b-2ab-)暱-)b496)B0YidٜIdÙByR#3iBk9m?*B4HtF2)` .g9ɖn9bI)gSSge5iU^_y<bҲJ6J/^jonf" $<#2 ,.0ڢ12Z4z0|jBږDZpyH:JJҠդY:&9Q9h6U*3\dzkFj\Q ;FybzyjNi#]ʉj#C:nsJ)bjZigZ{vzgL֩ZTz_z󕪪ڪj:Zʩ_֫jk:֗ e'Y=mT03BbZzֺۚ.9*(hJj_*i֦rpUCCc]5ϊmz!Xk_:h5ojj]ڰԖ]P:c!*g;m)#K,y'ts4[׮[ֲ hȺճ> :x6"3z68LNP۴QR[T{S6ص8t\t^%H f{g@ l۶n˶xEgwvXT~lGHFo{GP+Q %ZKI4S۹˹+4qx[=BѺ KG {KUNj;|؄`EXVHtDDjulx cwE wkq짆݈1ww5zwPWv4xxć1YQ׀ˈX{1eZIQJY[&[+T Nu*:hdA40&<0p#@؋tu0D4Vfuf}DbEWvp5 [ٻ{K OskX刎 w~HpR#HRRQI|II L%J{ $QQ@g'A82|ɷȄ3Ɍxw ; :\xNNrKv4dhvڨWk qİW4ų1W|GexuQ͒Hi|Ĉ1Q1zy# |J,Ht{Me|9#{e=@X|pH|3~*MCTN! V!v^0wKxFOQ @w,=(|PxP۾6!`HkƓKeRHߡy\ZxǮUL[}SBqF[KwKT'$s"܃D| }d:ts}}!ʈMNQЌbEaN_ذexWz˾~5w - lPXǎx Yƛu NMz,I[CqȷȴkK"6vUsdALLɉuoїyQ4 ޤ̛ugNtNg~x~{{һ~+}w0MŁw[xő+HtYQ@}+y4P݉2TzV )JZm{$59(p(L:>L{@wMm2ыVB R!?܅ޮ0E&(Mw` %/] E ~WZP6ݾ{H=(zN$5Ԡ~Z>Kz Y⿍[LT?έۂdMȶ4ֻW=+t.b_5DՇDwuY}}PE+vC M!ܨ˾ukWGX-x~ږ)R>I >ǰǢȂ[[ 6ܷ^|?dGkuۼ@lEa W~E<˶W\ h̰wVXNp~6ʼnGxHeۈ(J}ZZWSSM&ձG[ E\dIROAT_XZu^_?`/d^ccp:ʦt4?٪C9&k;]n!Vejj[:vct]Z:yiڡK$N)^^򊱛w*]?oPyu/$[lO6Hd2Qx [ Uo^r qi?jdCܟ^f/Y*=?=3VOBX4It>QZ^YMB\6iv^y=> !#)+-/1&39>ACEGIKMOQSUWY[]_acege6;sz}puoɗٛxϑ⬗Flp >KhagS_!BK@nj:X$„#EɑeI3Tyңƚa$85gdF葦5 '˕@eδZ$֩>_rźMe~JP(>E%OCަxnz6v eXR<;+lc bBA췰`׬_}*u]!Ty-ʰy8Nܺ?{yypGG/M4OMakۖ0zy۽.uՄ{77`o:=N?] KE9ny|BbѢspf]3؛Ù;gW/VלUp Zl|G>[-mXVԸh@^{iVize 7)úU>yf8mF^P $`@.p d@N0 ? nP1`AP#` MA+d!]BPa xCP;_}?0AYA|=h JtD#"R Dd[ EG]$cxF%,ltcF9ƑscxG=摏zHA4!HgMD&J q HqDL*hA$$!F2aXh'2 :R5&U,PJ IF܎3$f0T.)8ju[$7u9P23.- #ssհY+s-w2x :)O(.\A-O*6 ECx!֐&@I"t=h<1Kt$"aSTESz ^RiOS.PC=`Q:@&q;httrack-3.49.5/html/img/snap9_d2.gif0000644000175000017500000002141714336470674014046 00000000000000GIF87aFνkcRsB)91!ZJ{k{cJ!11B{c111cc1111c111RR11c111c1ΜcΜc1cc,F@@pH,Ȥrl:ШtJZجvz` Htr\lnL7z~?h{~       4pa #>40"E3ЈF:b I@ !P^ʄMh܉`gN  ! F"`aM"@Cx 1dthAD6Hh@O; 0QdQ_D84`3!ĉŢ6@V BK.a![XgMmmkeۛq{;x[~>( |}bÊ#d~yMiJ(WΔreM/oٳϝ@5Q@S"SLńV\yVhfva~($h(aOXeR8PHUYHU7V?D"N32)UK38eX6ɣRRyU\2;^I&V]jdF[ tixJ!g|矀vgj衈1h6). 餔Vji^JVt駠*ꨤjꩨꪬ*_!UMd*$W&dګNpk&쩴1K P@Zv܂mk薛뮼koҫ/OH;-qG\ouGwE} C,p}dG\qY\BX,yO#gݶڂ㝸n{8y/ng۟=w#w˞߱g߼_S՗>;г+O_9ϾV~VXW֕nqsx@0{{[ݸ ox'Y 0?m[mOzK]5*0pXx=Y@ ?L8P~f*Zq*".1^ H1+#FMp#(:Ot嘀^ G8D#IK4F&CXt vT"EDr$pIĥ,~f(N1) *T2Ԣ)W #@D T+>A0q LP-}3S'NoS)B-l+PjV>74D3ɈE@&6͸nӾ̯]sœ`N&v@ |Md' &1(pPij[[P:I1mH<E|G#!Y(>a~kY@Q"TGMj.yI*X2&*W^3$i%'K(I0g)9fYhr>{M~+-BІNFU'Ma]:a\QҕG+e*|cj;k@gMr^fҽhCi꾡,ZO_'O?YD(8Xx ؀8Xx'~sKdP/NT1P%4Lʔ^^uV@Me_Mv5N NWt NNL ` ɠXO YQY a±aZZ%rxb1[*Qq[!c16R7VR!1\'c>1dB6d ISrڅT,%^`!/T#U'@U`U l^m]^bL}1VL D 9wE yE U pQ`NX `QOXWȅOeYaq %6ZlhZn(uQ(QwA!.c4FR"18R+ERH\6]> IF Dd %e+0U@)U )[Vu^ ҤVV110WW A{)XTXOad  OPܨYceؕ PXZk8Z&FUy(!c#eRꑗ*E\)!1 SBA]@E ITBB|!S*4ӊ/^-)ExT 8CM0X GIXJ 5OuAYqbȕ5U Po8Q$ՎvbzQt)6yI;\)SiϕS8:dL] xǁفj$7jJz Z")c7D4&|[f:k"ee5kv#jlVj"Re]]cf|8&:gspvҠ_ã@:uGFJ"BzJ ?N' R I:DZV X \^ZG}nR:fk(D:EjyJ>Men:Zz4L0Gr5x3vHCmIz2!ql.mmҶUs2}0jnZn6V ÚJS趫yU%2&L6JLmmuzmtJ+"ZJ4l7HO3L԰{0˰{[K #{&$%K? +k:Kv|fvbxlGo\C?+s5>f^ij-xgpoHxB,sn'xU['*3[sxʡ6FNxcr:=j{CSC}CAf=Wx d@*a}eC9{c=;uA;x2׷VvvQtOowx˸G U&N@@C Bˤ;WBGqKvrXx wrT;m[׳uC\K۫:&gC x+C ۶Gfw6Իywכy{*kv'rk7{Z ;{kG;[;{h{tr{n{ d>k: 9 ̫ L,؋,_*”si2y4ޛPkx{Œg,*0,kЋR7/4FǽvJåT֦\^`b|~fzjlprQPuUZNmQ$nՖ,!aA4.MS );%F3m39^dyWyLtLxd\.Vl))eMTEUHfReQl32uqLv!Z1H^~ge^^W2NAW@F9`6M FL~.A}YިHXbsH'f qۺm|X_+Rޞ}dB!8p=Tsݸ. QOp #awU0ᒐ`AE_ ^Wzu~@֌7 w> 䎅.Hb8Ԩm!P5b^Q lµ 1Q ߈ySO}񰞉E5wj(p(U>PQfAXtdT2)X!r**Z]6R D\tobMŞ== > ''!2!00A?EH?@HSOSQQ%4^%bim5n%l{~u"# # 3 2 . /.&00þ HB F|h"E dԸq#q*'TR-_l&M%Gn:IK,=fah,_xI /aA*k`CÝ=yh!A-RH$4eSP@5o_Y_ ,!a[q&bʖ)sv4Ϧ]m6pȅ.s䩋7y>~  a&RnA@qǑ)Jϡ?w s̚6딲3R| 蘥OѤOUjz9odǫz);Ey,yAJ!U0pe\^E`a[P2h,m`qDǜs) 5uڡG}h:h7 -ʊ"+ .8/ S1,3LS5l7S9KS=? TAēCMTEm? }TI)K1=3L9OA 5ME-SQMUPRUmWa#.e[q\y_L$vc46Le4Y3/k}g踌7\hUr7 [pw]^b%7xo}zU[}ۃaն؀^o!܇\f%^~A܉=fXdQFXX#6x^98k.]icWNԖu&9ލ%d?&fC]qݟjƸ[nS)[o> /2>\N!?)-\T1;ITQO}Uo C~Q3:ӈ*)ERLDO擪JM8Ԥvԩ&5*Dկ.6ipxˀZT^5$*R:ו4q}jUWJ%,PÊWլ!Lf #Xncroth=ZծT@m2Ym%q[ _l{ZbMcR7К|>pe p݊&F!{\uw;ފW8|yPV~ \-9EtPm\Jݯ_h.yQ#y.E!7r;=Nh,b6$<CX~_^?wov1X@["˘MiSXm[]BYq=u.c-{mv:[89AI;d7ىUlՌY~~H[gyp_HYLv|gDkYwbtM#O9--]bSgntLۺPx҆tdUm~?<.t}ab<e7K,d!{=iW~ϔ3)Mb9z~_tmxN nv۬5+MG7ĘNgICZol{Opߚu_ko[ _ɏd%}?ߣF 򜇜mx%siưO$ZYeD$M1ΑN(kz^hNN$E™#Z4mijӰ z~1$)$&"7#$ +eT;q&1D!KO4 QM(@qp5$5'ke Q)e)=-ٜez 2a2#UUؤ|Ȳ,Ͳ*Pr-2|%R4r..2/}j/R/A)031s111!32%s2)s2;httrack-3.49.5/html/img/snap9_c.gif0000644000175000017500000000477314336470674013771 00000000000000GIF87aνޥk,@0I8ͻ`(dihlp,tmx|pH,Ȥrl:Шt!XجvzxL g@:VnZox>xw~ueag%_B}yā{<Ҧ *ⓧ$hz HAc ,(! IHŋ3jȱ,^ C( IlZ8sꬢhOF5IѣH*!S-$JqNvL¯nP0]iHA'54]Om߿ LîRld 9.{ᛱ.9lS+ϠCMӨS^ͺװc˞M۸sͻ Nȓ+_μУKNسkνËOӫ_Ͼ˟Ofz7{CLc@DWaݧAadݧƄ6,H/whNt!\_D,_-E /e%b̥a0VWYXcQ7HB:V)]e1j+* $䭸׬@[v k9.E0A+k,l' 7G,Wlgw ,$l(,pmh9dvHU|\[]'b *iO5Q#Ce JJd:{)ڴgͶuxx6%rɼ}.@fuڂ-2]SMaf[ZhηnA~ʡWW7nNC.NZ?MCyst| fG᱾*o* I*֦W觯~/S̽2NΈOB1hTb}hĘyGAK%7 RV{ƢCњqԈʉ3GvQr,"Rԟ!CFuZj>g|wy+PW,`$&vd>ʨ#WDB#VXOč1ڝ&éVlN]+[J _nr0kfְls\uتu]giwR n#UmMzg|e{~aO^FZ ӿd* ECA:|-Ă;K_V\+FcTbK5*g [-DUpW4:ͱw@̣HF(vWV+rg+nɉZm%ɐRXyjJscTPjSHD<ak6@90 @͌Vz'MiFҘδ#m${u3VO6c @kF60&B>44`)hB?C I0=;$ʹaCskA؛dtC,Kcˆ=Kenz f&\ V\#Q֝Ϫ|np$‡oBz#h Δ04 qT xGNܚ;y,Nt-Z= eTN teAy11, +;EG?!OXMA,g:D;-\{UpNxϻOO;񐏼'O[ϼ7{GOқOWֻgOϽwOO;I;httrack-3.49.5/html/img/snap9_b.gif0000644000175000017500000001051114336470674013753 00000000000000GIF87aνޥk,0I8ͻ`(dihlp,tmx|pH,Ȥrl:ШtJZجvzxL.zn|N~m߱śgP! ŋ ȑ8x@d&PȲ%F> 9f\vR>@ih˟@| f SOJ2աSRJTSv{fVagз.:(j&׭Mj)$4u=9-Vi,'%讲)t'.Zp} hXEVSYu_WmK/^o ts)( RU{$-)N'T,K_Zi4MDŽӜj}WHOEERԦ:PTJժZ ̪V!ԫީ XSi[*\( @- qn>%(͙u,]=Jə\{@؇sh׻b5Nxrnj,XFLVa(G&$̝vH*U2,ȬYG$iH ?"^Y0 ZPj:@-ngV Vler,^TN}H47 QyYjfT=fn ]n829hϋ1o[W?Њ9Ⳛcpp ׶sl9RZNAgecb"Z}4 C& k Hɠr2v e I:Trw,k3\ƍl0飼dɄ4Vh}:Ssγ>πM:mЈ ѐ3#-Z{,E2$m`-B=%N2D\($.u7cϪX ækUy.4l`f'0T [siEd;K~odc{h얯v\\in݆2] v|KS{D2O{ɵs)DoM'qzy9Y'z 3f"8 Xr|x,uvv5~,((scr{Pu8h <;>EP4H F2L؄4'NlV pVZ`ubxg`Xfxhjl؆npr8tXvxxz|؇~8Xx؈mhvx@_nhlwRxXV713V"S؉U)c?yE| 7=Yo0Y5M%lWELO3GNzxPxϵ51G:}$NiԌ|2r[wDs5e8#w`X`jOW5!ntyR:HptUl{GIx>"aΆ/eO$(!5,6Z([4~qW1#Z%Ye$t䣉\A}Ջ( DiFٔuERyO#7yDCi\ [Ψ [zcЅTj cGtYvyxz|9}IQ9Ԋ00}s4I)&/5D ё~ēe"Ib%V)w i.zY}7q'ZH:y0pf M qC Y9`ǘƔ*Zr~3ѵ|o9K9bɚg X\2) EYܶn%H'Wy )dw$Y]BƏ6_E]599Ovy}'&ΧH 1(m*>)#H_5oYm&:ebGx^I?i-ʞOQWY uXbdefzybF]ʦRpsi)uvZr~:Zzڨ:ZzکZh9\sz+qj)0@IIUj+nzf/466PD*jpW%35 C@Ȍ)FgZZ:|OrEؓfUY$¬FAHwV~m׍oQ|ګߙi7#XH kIWZYWJOw}9%P⩮4q ҭ k ] ;WXS(Kɡ&{:-+  I!zoK˙sbatq+1wE0c3*mz>*|Aڳ/L[vJʪ2 t[Xl+jn{|vG0kc'z!@l9g۹;[{ۺ;[{{[[W-k *XK}/Rk*,K;;+S{*Pj;kқ*y}tfzayY6'wSk*}Ckԟe[*BataƊ~缜Jo8!HºuAԾͪO괋.|0Iij7|o 'vI,)4|Id54g(Or[S;Yn:,N|PÒ:HeǣjǢ bv8+ȡK;˨lċ ɚܧɞɠʢ<ʤ\ʦ|ʨʪʬ ;httrack-3.49.5/html/img/snap9_a.gif0000644000175000017500000000477714336470674013773 00000000000000GIF87aνޥk,@0I8ͻ`(dihlp,tmx|pH,Ȥrl:ШtJZX! .`, nh>7z}r}trs|xwvvnyzg|pYD#a0+@[_cfwރߝ٥ZiH?VޕưCd {Hŋ3jȱǏ CIɓ(S\ɲ˗0cʜI5k@Nx,7]B;h[~G)UjjݚWrKٳhӪ]˶۷p۾r[7+^e0K t^̸ǐ#KL˘3k̹ϠCMӨS^ͺװc˞M۸sͻ Nȓ+_μУKNسkνËO{".⼴dL`{117#?e7إ)G)A@X=G1 %Ka`hz4h߱^ﱱ _Q."̨_}8FD8n0]:T( ]{MR%¡>%u"|jHS`LBU/TfU*蠄j衈&袌6I:^u5_J@eRW\S`I!DyrV]*czjj0ʥi'k&nejNEcliԬpH)d@i+k覫+k,l' 7G,Wlgw ,$l]O\0Tf ֦K^0 7| 7 sԈS`BJѷEwޞӴ|Pgmh'[)fUbm/"|߀.%VYB܌S;3hZj̢\f͓Y1ntM5c#me!VUeOY:*+@+V6ܶ͸y.Wogw/ox2K^y̔,O~l龺t*۫F0aqV]BpEBtIVywMOy`f GH(L W8H=yڲ"(EoJ 9?EW982E]Cmfx4Z[K̢.z` H2hL6pH:x̣> IBL"F:򑐌$'IJZ̤&7Nz (GIRL*WV򕰌,gIZ̥.I^.Ke`Ot?Ek~EP-< timw&u3[r9?蔓7?ۭ [=LSu>!Դ󠨸jVEOи)Bb'0i "1V*6ac4L!:Sh땮s-ZsMՖ7tJ*S5M^v)5X tRPIAbuipyE-z"Ԫh 60i^ʆB#TNyMT4ŕE+?oVt6}d'K#b, hGKҚ%0WKa#d5d/( ![3mJh[ '.ꣾ-/M.>x]k:N깉MsH͡ψ`}'ҏt.SyԷu]G .]v';xtX]N %Ip;z ~5V8:πMBй`-0]h+ 543E[\h*~5}h|TS+O<.1Gt:4!w3@yL;5Cyb4,xm[;u76,mā9UtԮ;3 -c+Am\}6tn0>8UKu^vHW1pe&3Ь0'N[ϸ7{Њ%?N{ .k>q)WjDžu+2S6M1-n±Ua;}S>ڽ99V'^YhOpNxϻOO;񐏼'O[ϼ7{GOқOWֻgOϽwOO;Џu;httrack-3.49.5/html/img/snap5_a.gif0000644000175000017500000003522114336470674013753 00000000000000GIF87a# )^`XzKjĻïʵν,@PI8ͻ`(dihlp,ϴAsB.匋F.͂Ь.l@JF[0q4h.eH*-iKI,6TNj`~$vsĝ3`7m 67 @gmK.8Ň7v;lqgΞCviѧG^kq_n zmٸi ;۵}> pݚCFnw͜x{']/8S_}߻Ox߯||g`}֡C`6 >(aBhVvHhb(+.0(<=6NuL6PF)TViXf\v`)dihfp6\tVƎHJލ|g蟂J衃&z[ t: 馚v駜i裨Qjجmy"c:VgĊjl2xj:wu=l ` Gɚܐ7sݲ ظIב{+n:L0™> mjخ\jUBV=q5Y$`LO;|5k$^z*+[ o832P+,S@J+1GV!|`G]uzہUMQvܩ14j*Bw1}uؑs2;D|XZoEyW>n 60x-ɏ~V^)jXʓEY ԜW}ٓ;ӹ҆m;d<@\q)Y^Ϩ}׿m̲ⓥ+4-t>WcL52-6jӶo<?~o!@_Gà |_E8:DK(C/Ev^H.L9E/3LЄGÕizшט) Meډ7/a@8}2Sh‘G F4ұgh"5ʏl!&G q!GFƏX ^\.+vEwuGË 酮f.:o2ڑ WDU,\+ [K(ϒiv/1Y${|ͺ: (s/5ͱhJ;Z>YseI3ʄKuf],z6T$EGDM>2 lCqĶ FO &Ygl'"7Z,}B, t0ǡ#`@9z҉f,<*RR UIєq0#eԢ=4 \7I7S;%iUH8VFk $WU,PVǺVGzQ6uj[?՞j^٪BUam:Wyb FR``XZvb/!)ݬh5KZΚvl"~}lO;G:AbmC[.cU YJֵMnp[fӭXK]V׹ tskֆ൮x;fmҝ,y^:ҋ\ڷo~'$_ },n$u#i nYiSUawDu@"5Xa9"iZ̩ S8&b(fO Ldl8N2c8ȃiE:e)TƲ%wyE0d#UwD<3P6< ?^7;y]z"C:4npsGQvinK$ݒyy5g787]O4wVհgMZָ~*kQ5IjHl_8sy.٣nx-l yL6ǝrVMnv;CzMzXCbp%DA#%M8;\'߉8'{\WJU2x\<ʍ^; x7(@Xl]o.v P<> }c1Ωo;>}*TGhԲKK=d9xs3JۓDgq9n1a&RWWtm-eV'nS5S (~f) 8 %H&('؂*,24687X8:؃9<>D8F(HXIxJ؄LKN(P8VXXHG9 n^؅`Xnde&5_%h&ertxj``Ush}ݵ[~ȇn8-qBACICt16T:ENس/ؓBbNODISW:P3MCᏴcm"l<4ӑ@ԓУCÂVБÑDd+D28:سC=3=)tu cptc1H\uDP;uG L^TbxpvN@uw!Lw$w(Apw{š /x. úKkäxFxEé Ĭ wqD, &wy zYĶl ͔>Cvhԓ;0ky| Mـ ,{^~ >^~=k^/6Af}"#^$~&(*,.0>2^4~68:<..%zRHJ[Zd^b.Q<Գ9Q}jañ`>G~1KFJD:PzzB|Z?%c1K1ڠ8ǨK್$^EN0w&^nn݈ݘPI}9$g нN@!0V|~][mdճь32.ݛ]!)M3 7-Mrf;$~7_5.MJ:C)-C2Tz>3o>Of<.E2݆ `SG>=9b9/mc+IXϳ yi ۙAOW @4fz||ݖm~O$!wV=/TlU I))X_ns߼$Es90EQHOt@HC+UPH,*eP%(]3M6cuV#p9 m )O+^mMZeevYg59]dX{>mmִk%r'Zئ%P3kM[}n=w,{7_sC]9pc *zR^|w\'b-/kbX=V^=l%6b=/⼌ZwK^y&l>aCfy7jgr9贒Nz ySy_j< 5jťקSjFl@jNOvnu>[ʴf;Tsp.\qgn~㭼sS<6wsxL\ZCbYܹUƻw7 vFyvu#6} |yGp^tkoz{>|ؾ ٣?w?~Ӈ9׿A›bCeo}K %A .P-$ 8A vS0h? σ!D UB{P c e?p 9?C9ABD"1fF D**H#Zq^UDi`Døƴ~H"՘F97n,a G;-b՗A8яc"XyOzgOQx!&ESzF(h=M@æ#iNqS?iP:TG5*R6|DK ӘӣQJ2Ϋ;WRv0LTiխ][*׸uw}Z{m]ְֺ,k^Zb +C x-bc lX*uSd`,/  Γl_Ki:O"@dj SHbNKӂgZ[.:H-4YLDc12C, -es\ZEgT) %b_jFq["jIXJKpU;VTzT bV"FO+v1eo7p}2`rg#s:_ȑIm{Ol'$r,Z2(gZ]」Qr$㶣\N 0Ӛ6t`4at 1h:ЏV43hψƴ5-~hӟuE=jRԧFuUjVկue=kZַuuk^׿Va6vl~v-mjWvmnww]fFw}nu~w=oywo}x>pGxp7~#^G81~kxB>r&y9-j[r6ǹos>?Ѕ?':2t7Ozԥ>uWWz֫>c/\u3Fٙmhioۣ-nNnw߇7x7x%|,7cy}GE~jbDA7G /_0} {; zoO}?>>//Ku7{w_h{췯?տg;|nw\׿$+C@C<<K@`fr&  h8փ:{# [: zZcp+a#<>K +$>(dx=A;Ⱦ>>e#;;s4\C668Cm{?kqCC??~~#Dt88@$9HHst@$ANgb)Ad#|\ KAW|%s\>`\{zA'H+H'%<0$$s_6i-E/>2<0$Gr>CøSs4|Cw:G;6?BDD??@KHEdȅs3GDtD7ϫȌDNOl'@H.RX/3XPElףA Vd-ATAe s#6h,f$J#Bi.<lԷG-E,cCuMʴ KvDx4#z;k[KN=CKiGܿ4HCKDD8DDƬ1Sh'05 6S5=8%S3}2e:uS: ==S 2S1:-T;E=9T=mE! IRHU)(LGUYQM1?1US9&UUHI:!JMW]QTZIUdCaq2` :A*dK3V@#VkPjU0;<0gXhu2`bWc2:!S 聖خ`RX iX-!Y tWWmWWzWwX@ٓ֓e֐QXx-~ن(ɎeБi2% ˆ Xp5#}v֪ gu E Z X(l.O&aX-kZm'(ג艰lꉍ觩l-ٔ'Z{\[@&S?]B݄zLձQ,]ڷڴm2%V2eZm+:yWx[גf\uݪ]2IuX$ް(^BU^emu}^^ %_5eu__^f@4]5KF~_N`} V`~ ` ` ~ a`a)fnaa`& 0 !&"6#F$V%f&v'()*+,bg2 5p1a2F"0W06.7 + IY9Ycuucv!=&=%Y-1d1>1bPk@IB?>.O'T(Zf:r-pxTqzgZ{s n&f>8٘M[ jhMb%uَX;lUb^p> X蟀x Ն iW((Z%fT X\\U1UiFj .f]vj <  q[jX^F-q(V6j (`נ%aQ谵&h&)1vkϦA1Zjehi$Юmg ?BÆVڿ؎P6nH ؜-m0!p]Pd2`XSxfUkXXk_`ii P`(Uh hgX\^8 Rnn19E\m)*x1k]%'9~e6##o&?OoX~ ^͇ vdU}.p(qfp#pL0XQPdgWRHO XR_to2 RdVnHB!h O?gqfƀX0A%uqQЮp2xbR`jϚ-j^ѮO@2mtZi icrV{`c۹ N${۠`a!!a"WCD^"`b'kg+j,,cdV&1(MQtŲDt32w77Pmnmzy;;;{ʮ=eٰ@~V\QC : QD b.AP )GHIy*IdzzC%L=e*0 i@M 1@RjǣN ĭX*HzT"V궧 *z4h[\7-]Ks0<Ĉ'9SR 7k2i'Q F[;sZ*- HX{v-z8qno!U>|Rq)Sn9tǏD0N :KDC׬J V>iQD*%t{Ѧ\fz!\\SWnq Pa;u n8h]ݑ esD`?*|";?Y$'h͉TQZf%/)$%MڤN)X!BZǚqRuzyy儧 NJy湨5bh8!J)aj 6A>]Oi"Jhꢫ:;>V>jʺ饁k:,zbL l=t^ kZ+-cdBI% KZh2^Sꕅmnꀗ^qp;3V[{2-HLQ3G^] 0Mz4AnȕZpީa&s|peyQqE `l Y heJpɳu}[ Y[[FHEU6u`Xh[iMϬ@DDJ^h>];VP{͵H= RqZ)۹;^`y5`m#$oNxZWь7u;H(T5F To8]WGtCBqL]/bk Hǔ$ A I¼.CzdĶ\Q JV Y+R{52(WP!.f>45IDn}<=ރ u!ę ziFq8iwa'@,~:b5l !B?0+>r0Z!}EW2PE0#g "(~6UPP+$0oQIO E+41]VvnoX\&weo܋޷C=S_8 <:݆ 7E[그{ sxn/Un"6=b8v1Nm cHθl:qg[V=V(\ϾJ֑jO򬢜-{7WY0c^2+K'ذE3,,9Gbol4HwsgAwσ>4Mhyъ~t#mCKҎ4hKs:ӝ( OӦO]Q:Ң^5[@zֱ\׾qo-^{»5l[~1zlh/hmms nbe;f6sNnf{7|;~-Tw>G.qO w83qCD\ǥpqo&GAKr#_[ <6_.5yσo @ύkf`ԣ.SV:ֳs^z|:7b0v;o/ T\yOvjN4魞UHL &c\x]Aux6%VvL7p@;!NA<y h^zH(BH) YȾy&|ikI2w8A/|e_2Gg>xX*EqQcKq_ _^a9i^Yv ٩}ʋlIha`_&^I) Z4ie C` !!& 6! joY!jaT( Z` 9m_!a _"!v!!aM!&!"a"`:^- .b#f%R#ơJ80`IFbAԅ+",+֢,"-ޢ."///"00 _xb'.ڨhUl/`*F!Ie#/6R77z7J7 "#zZ=4;nA4,8P8>"YA: )BP<=2$ "%~Wb܈\B}zG_Zc2c* (lAP`J N"%FAL ZP ]wKH]XQPĘ@A~߁ \; E҃M>P`1 ~LW߈%dUHH}Ie}?U֤K8&(<\"ASҥSN] [dd9GR¸!$:!:$/ie2w$W'`)`8#7fp)tix|矀*蠄j衈&袌6裐 1 `饘fk1ݬŤ2WdRBKj$ꮴʫZh&]"#$zHm~+kkm/c.k>L-YO p|PEpdY _+q;{qv.V%uE@)5|0sV0#0_3E@x|MG c!_qVg5`o5o#̬'wjʣ>Z-7s5akwy-7e)ڐWu7NvGO>ޗݜ> V&'WKW.;N9{Tk:8} ?5p?z$\XaX|= \O=/Um}`s_9q[zc# j.0`Fk,9Zr$ )@  3!/_y hTFa  g`7[v +ZѠ  >m-iIW~띻׿I@qԪ(nr7br8.Ix'@n`|X<3vCkk 5)gG$ #9(*dYE.B2@YdH]:LST&x"f*g^4 2L׿ ۘBM<)Tc=ԝuERȞ'y2H9%gxg:DaIdae& 0u>-#TvA|̧JSzjiO3idLuj0 *O/ ԡU5EI崨PjT*ժRS*ԐQTZ*jV=ZVuWܔ|6#g2ZD8mbX:vIɧ )ܘҐ Xz}lh?15jWbڤ fJZjf"gnooezh{վ!KVj3[qMYtaòVl\6MX(E|Y ODrxF3 gX4e] WFDUf%$bX<þJ A pV1I.۴`l9+5ap~3^ zFshm 7 ès]0˸1 ׶Ǵ߭jZW:5Otd.^ěw|Mt^Sr{>=$miG,m~$  R?~=2rf m#W8srWҔb3Ԡ v*B{ l_01[OXM^C~6ʵm_[`^bD03!}jK9JVAsIy3 hwzYun&x >nxAaQo7|Zo"|| yfYHz;pW"$4fafQ>8Tns{P0 /'QRVXXUqg.x5W yuY6 b`'c3sЃv>k1^g_3tGL8u5ktkt)mVaR gWb3,ua  u[qbEDqn^D~Zc$63Htjc=s@Pv3s_fxnHd*eg@6o3ƂNvm"&|uyL׃/8@8NzF䨎VWX Q%؅Py51XMd荍IRf4vIdi3†2v{s_X~.b^ņmhא~ZwwkL6KV+&U&&,tHQd^J7z`F8Xׁ8x簔MO)3 %b*!_X5xhɍUCf)^p$6ԎDXNegxyz|x)*w#XFbyednjLliqXXCHWz_/s2 4B$Xagwk"By3s4+hl5ٛ2mPJ;BVcM'5TY!tYiqygȜoUϹUB1Agٜ#I p~yiy{)j)W`3؍Wј yI%6}}sda9` 'ڒqhaƑ~#*aAPgDٶ B3;* F`HYɢ1va4if"FS!I@#QSZu1JNX0{&ifttGnI= ☢/a^o)>C3ڨkyu_pYzoips.+3QX}{%(*:~J7OSਐj] |^Gj_Viٗ}H$Xx΀3l:Vkl S -)BʬZcAs>zl$vCҶfQ eJ]J6TX |JDU)ĥF yx,vi5ʝ?zAKʞjS:Z& AL2gT@|ȋOӏtvFh= ;+TV [R%SHۨZJ,^Z;Qjsp|ƐwdWAlt/t;.|/||vu$d˝k>(B ĝu6"R!djJ*/|ckokcIr=.DIb,^~^ˍPL0"z&*,.0㇐ )q8PW;rr =\`W@pz~w^1p'k.>Ap1$"Q 5^7㢾 < ?ꪎCn kn4[Hkw T@V' PK]hAmz'Fq9JmG+z%S^ћՅź^!H$n㰇3s} 3F_K}B|:]̂p+N ͻ-+ ?l`Β "?_&%$*#'2455o8o7<*B?D0FLNOP?>/ARoT?M3\>bOUo:?@;_jOmootXQ1[X% H9/B/]R폿 4Bk#?;ݎ\-ʞOsy : 'AkrGs352 nwO_oC>XGlD6M8p4B 6<⵻Q;3^w3X(̈4eySM9{q#D;zd!})%L\AcJi4C:̐cF ^E;- B\5 |0d`jz>^@ H q@*!@kc80S 0kx!iwbEL"54M>O4W5\m?5at6,n4z̛3{2zWxK> isD R8@0>A&=c=%rG$pISΚ2̒|L=!ڒ!{#@@N 3F4-JJc3r B)/MRGKiKL7814L!:SP#RYSYcU-mu'uLN5M]͵X\%YcevY,U_ %'U6[luVn6\i:ZU]v7^w]r$U%SMq` D{,DG%@^x^/XVk(I\TWG͘c[c_X4J݀ԽcJA>;Q {+;/:,רJK iPANm:m\k-F<٪$n ?ց5ucN PXtehH^|ǔYi`I5Iz%Jg =ȀxdF>ygx!$aƮa߇SorkW۾/u i0d[X>)xq.AjFbH96zyocw A^=1z'| tȄ)!_l G k)Bd:cI`$߶j%3x9çu` ORo0 Y"a:7A i u+Tٙ MiHTMmM+ƎIr @g:չNvs g`D5 JIKj!g,Js|VBVAs^DO|2㌻z%19vԣq46^%f!d! { 9bM%ڍݔQUK'5J6Di@U΀J}e+$ O,$/ط Ze`(l_TtJ:M~xҏ%8I_)XwfN @O9S84> N(?VT mW.L*-#䤱5clA{ֶSCJG4 [Z= uVRgmgȫR6.NQ>'' I.s0jeTkoT}Xpn.Wo ֻu46Q͔Cn]98M1}I8Uf-zn! ]{W-U`ߙN,9K.z,':[HQL>6 4VHwxkH(Fd&XljȈd+Iʧiww[.z-p00#5i7K2dDNK^o%]WVQzm2PX{`wn%.*AVݯ_0mhYZ?zmcI5u)ǘ]?,ekZD,YzbR 6Y,TǮ2x7 Ffl[EDiʢ#j,wrAՕ[FՍ(ˆN"ھZP7%띵:]5Ԙ".}Jķ t*a:4vj&,qq(bv\N`N*YnLV.ЁBl-l)-l#ry\u-g+xwt}gwLϐ{nH:߻u֮^+#GZy-spU6>:ёʩ)iK7EY;MOén` Mly|VMh)u}obz XxO5խ1s۷1߮8`zW `"D Cv4JhlhTfzI.b2[@J`+[ Dpch hBhz$F;;K$B+(`Y3,C;<4,Zc,$M>>+sc3_ql8 .nXVc({Clh2A(NʺɂR S6 )L;6D4C3.\EN@3-J \.zēHFDH?֙KJ˚pޛk|A <10+sl$t!D>0Z+%;43 aS=1.J&I=Z0RA(lQ1[C;,Y' [zA4a'.@Đԃ {F lI8?Q$O:3JE6Up0H#V XzƫʬʭʮJb?IePFGhTKBF F4F"/q$*rD8Ku"w|%G}uǍ $+B}ܮ(tLj'}Ʉ lw<i،ڀK:8C;$u ?9 pIA ɡ+.IcD A,y;A)#E$R-O TF KKfɝ|DlD֤AF$AAAMtL LlŬˋCǜ,M֫0{,̍ tCL =AԨ̸YJٌs9=T4Kz 2(D>ĝ|tFLS2+6R,Nm1那 2%O3%3.b6u4)TTIK&Od){N'b&ʡz|K9C4PJPR HL]4wȋ =BAP̳K,L_0Ss%T8@|,OeԹeWL! 0).G/Q54:D;LNCЋ$< (R,8R뼗E\RetRBD.\ESd?!ŠLW:s?Uc/e$7:x\J-KpS8h;ƒaRomDĩ>K +J}s  pTT{U4 L ì iU. OL]Mi߃YGiѠ%b%cd՜Ѫ<Mj kՂl]deSR4Nyq?LA1EWכE}0S}u0Z?[\sS;[ ؀-fVso<J$ΰe[K!Zy?ms"5suR$.b$fb"'Vb!Fb#*+,-.b.^ cc".c1b41fc+.7V0c2c:nc;9<=c9d@&?B^A>C6DfFvGfE^@JKvhxň1`BY0pPcbC4aYae00$8TT U>YaCPd`e]6`b~1fY>^Zb&)!%6s>guNwxy>36c/n9.b8V~|:8h?hFhBFdIFdEhLd~hGhhHd&T{,je"9@ivVfp^d6 ?d]1@fdaSN@Yfc @m0$>Zjwgt&vy6F/-^k|~gc~h~>Fh;v^芎hJ荶hVlY=p0ٮ5) cH&6mfFNmUfvmU~؆mveܦmm@6n&V>Fn߆VnmfnnnvnVfvoT;MK io2:{Wd[tċRr^uM[!  H! Ȍ^UV / >VTo7TpPڝp9pR W[ w1 p*oH @/H GCTl $ƞmRq )q+ Rb[d#p6sqq !5ϕ:swB/ptKtt!tF=uI2ROTNsRWuMW7G96_5sYGW]XsLu>Epb?u sBUgv^vmewv_uuAfgtnv^OOGvNws ?_tisvmNDu1v<7-ro]gno'vqvw"Ww-}wp|wH8w'7GWgwyEG[Dbޯxay7xOwp/gzozGPAz?zOz_z?W7{{uwpln^z|{/{GW?|tzj% UY|g|}̷57i|ow֏}0gW}֯ވ}ؿ}7~gv{歜0wsX Y}T~/_o~GF+p~4rh@Xh@p9{PQlʮ.ӷ;=ވ6 R*(=N嵙}nԯk\7[0vP(oŏ!֚V Y##Z`Фe%&&g(!dYi骩k*k+i+l( [oY_gr2%jgr33tt.*mnvv79:: 0<0߁_ >6~ ,8N\9vS!B\8!C^G@G$i$ʓ*MLbD0-ʬqK1o꤉<(vJJ2mtӨPiu'VYnub"0p0`D[TSҍkwݓ\+N(p=y'\2˚3s}Cw%1B<i͘gˮ6mܶ1} |6C[T)d@[>ڝ: H= x?"BxG^Y߭c:\@Hbۂ5pzJV X*04 h֎r]4F2+\0‡*arB8Ui*̥j']4ړ(* צ.pz)d! >IR$=hr*C\j- ɣ&-jzk, :ɍhc|XKP,aY[xH=m…9(]h^a;tߙ ⸝QB2IlDkrrȣT:3\lц!b2@v,N>{M{-V3=hJ![4K4ew.0yG]Xy?_-e{8ٛF-3ȹ]\r9 am\Aj+ԧ2"ܛs7C"\ OxBt~w-㵮6堶Me⨟k}'oOadHu~J I'Ld=C)Bi3/''x>H@ s`DO`9±r#hUI{PժIY *`M`)jdإujQn6(/Do$f&dOjџ|6'2N *4F=%8 lêR @zXl;=+8R"D6qS2raG{ aֶ'Jޙ@q>a86ADh`iĐ:Ky)X+?8ph (,V4(pS%$Kkݞ3hze>=> f.=gd5|{kD~H]O@IB/~g k!cdK3[ 'OyFgP~hiATZғO ixzƂC"`C1vP`{oSֶ>>& 9eAe{^W;ic\7ml/;|wHCv ,\Ɓ[1IL8Tpd[ @hee8j@W5  V@͇\\@QXw|Fx`%wTPYKUa@Ǡp]ȌOihTށYe#db\\m E%a*N`aI1^ ?ډQ ݤ9@Bmk \s35倽,)VŞ^dG墭-%D"r ڔ# -VhXM(&255^#@-EhV .I0%c_!c_ h-#'ďב\ !c]ܻF0hMJ":b<# N BeؠFz tXUYU هdhGzU)v]^UܿH Յ (KY~ΗXaF舤Hhi pX`cF1Zpaĩ_YUJaDrD:F1"fy3R$Bic*VAy0f8 ˽1_"x@UG/Td6cZuy j/6>P_AZQ#nV4cof9_6bqg-y}c1¸=_f!&w) d!4„HY 9N&`c8{gM ބ+$ӱvC ^G  t ؈Lʵ`Q$9E@HL xI=H\zK LX:NKOfݐ]PfeQT*^Q}:RcoFgA )6)*|€= d+!f0ȦJ*Dxf`b'ΩDҤi!,YVb2cݦ;b^i>< *꠮_ jVz uYBN$~z.~)"竪;E**j=m___[)=0P5'xg $؀nϟrZVY M&q}҇J v`yg'F}Ԃ9:IkE. dza(#Ƒ$v$GՌJ\evY͛u9 }\>鑾ۥ!\ hಸl] : fvֆv` y\ft^+^my!-'s"Pmkv-ke9VNe'pnm؞R*b kD8-uv!m2וhs$E&^ F)iÑ+kbAC<Ի~Q~h؄.AъXknLF 2HΈVᇮM,]Q] iy!ܮ~PA(#w(jY[)XĪ|UHudiᕜWMD.~l.a u@.64p zGo'4/mPd#^X#hrWj% -& `+ ’Y`"n@D1׶Cqٯ V F]cX4kYt,hVau9Q4APx?G ,iY5 3}gN*+^J4_[36g3ڂM7HqKH)Bee1&N_qm%hoOloC.lVjo/W;{_;cp.wsA Wz`Ky҂v~rvB\wФ{7.+㻽{-;+{++gC\:rK4-7S&_*9K4(8*CDlS`D;Dׅ5ox8}$/yS< Nh_3Wd47g7˸HG輤ǍzQȎH7EzŠ%^G4;9Ƣo,GCݒdOS!9ؿוy !Kb :)?Y?i{5&\?b[]v_4o4&beG1)qIcA6*ȳ}m /z$wy5ojm3v-w{AHu x؊ޭv\^7{z;?xK{¿^7|W6Stse]AIAAIQM0h@9~Y@,I$)Q4PJ@U~x@8A 5F@eBCp 8v6 v*t48֖FZ:LLD0 &0iLJ&B P4LYs57Y ~e*ΆوJ*dltPƏ1si5JY]94;2PBpD81Ċ%8Be+r0!d.0` |YLI$ =| 9E8\$"*'6bXjjK"x`5bWS0<-v$fzk߾W/*f"MPT Hrd˕1_D^@=tiӠgIƞ>;a觡F Tެg"oJ85'>]zױg{w߽ ќx @ذ!hLS?BJ].X4k8>p! 56`BB$.t:'QI,q ƐCup7'?T-pzCjd!0"㮘>QHR>V"gutlS$0dLLI&K9UZQVMԔ<`N G{YA7Ux(zKq ]dMξG| lobAҪJjM\6/ j ڥ-K.KFᬢ֭ߔNJ/E x٥r.2/[ *L-<ckaF,\fYhZ%~z6Uƈ,J!L:9D&ݖ覟jEO뭹溷.OlCdZlꑢ%XG9#֢4BWV!Tä\3Ol8n nnV?fcJ$%drԀrd0{0Ya{d~Lf,:yS3Is!:ѳeX2?99PTngWP=᧕n_uaQXZTbejC]`2-n"|>p"ނ8.n=Uʻ0`= ^zk]1 XY"] w?![Lc#:fcMdbcb*7 LL4\Y'xE Lw C(!C&Us&)-pIij9L1$XGł@((kgAW^'@1#ͥNrN"IA.R 3PM\3A5;dIRjf^D%JPZ$#YA զDڠH&mn7Nq49љNut;OyΓ=L@36L4@ZP.TL,)Ibgr&CQn(G==J0kfPЏT,K]ӖI(,ڬȤLkTEQ#hZp>JգNTjUZԛz*WV_-XJVlUk[Vnk\:W|k_W数~-l`;X.Ulc!X&ld/;Yn@Zю5iQZծuka[6 mA[nk[w%q\.We.rJwԍu[]nw^񎗼5yћ^ > @(W/}ꗿo;_-|`' o`O1ar \;ϭ.qkbuvb8->^=>k`nXc~dhc2" 8S[c]"`YVpl`5 Z ªh|g }>mo|[Z"}k"ш!]ߘƔƱ_\c86\Ǜч#sRݪ+ TP@P^3g|d6pg[gC-aeCci][g'Xw3ilr6g bڴ׮Mo{{h?5x;x ǴǛ]Pomy5$938=8[:Ȟ/z}mpߞlT{.7i-7[?6o;4!n;n|g^7-gֶg;ozߋ&;耗js#wIgsbK#aa3_+}%ִ.ڍZrLPԍ(Į.Bય& PK_uyn0mp`ːп~R/L٪pά~PO{ϵ p+ pΎ.Pј/pO7Qn\`0 Y@]`!#(*A/1->E[[h%Ђ\E ^R= !dQ<'d5.ui1!blHGcuFsDхB1?Q1"|Ѧɡ)jQıӱ)fv_1 S\q ҙR0o@~@V<)($㱔R S Y)%&jGf%C&ݱ  B#@@Q M@PCI~ܡ LHoVJQ$iR& %O2q'QirERѪR%ҎȒ!OvC8.H AvKN  r'j'0EA+I1I'-Mr,r!S,-A1"-/2&,G)ZVUJS4M!SLA^4v<(s-}1Es35ҏ33$93&s8+sj,`\ <&31KHӑsS,<ۓ2R:2+S=!'hi&f2$s>sA:+%ߒA=9=54$0DPCMTDODQDUDGtE]4EcEIEmFYFitGwTG_TEWHg4HHeHsITI4ItIqI}DJytF4K4JtJ{KKa4J4LtLTLtM>siNH4NM4{4O5.PN uP QPuNuNoPTRqO%UN-Q5uQuR5Q4TIQ4TKuTSuUST-QTVQiUTcUU7OwWoUSaTUT!5YqWuRN15ZuQZ9RuYT5SRQ5RQ?>mA3]]:AS>^]%B_u?˲_`1>5C`sB?^%u>uabݕ`UaSA7_6b?3`bbUVcs-9aWV=TucEv^ceSvbYvgK6_Ac7foVbQ6h?c{VgCi A 6ivg6*fihm6`^caǖCh6lkaVks3mM)v:kyVk6oߖcVmVi1pvmkVovqBvp7B3m#pk-7k msV]d5sGrvjw$g$&w&oI7u3qd7pVw1?7wCpAv7au/ bnJuvug[iwwxsI64urxngYP-}w}mЗ}7~w~~~7w8x 8h( c4Aw F1؂Q39=87X;xMQOXSY]8WX[xmqoXsy}oX3rp #w=zwwz{t8X8%(@SS؍xߘ㘋ḋ8؎X 2¢WX8Xy!9-X+M٠<7ya_Y19Y/9SiHL!eugqY]Ytrƌa",t+9ٖy9ϙf8% ,YyӹyYy߹E5ț!#Z-8hF91zZ٤SU:/GA)%+ڥy}zQu1ݹ٣YG:XZ{9@z?zV J!0P <VAꩱڭwzڪ푣 :08JZB)U!hPvQt6z19=-Zڦ)A &HTGI8u  &0q\B47%t`hǕKz zMƾX@%ZIӵsϤ" 6x@+D}Tm#6;z}|=.i ̠>Ne6DDavvD0աF8a.{ G=E v`\Q` |e$ Fv4Y+rLOj~t!)Ƀ:TZ<5 ކaNG` 4p$>9XBb3e%1H87X%eY%(xGS7yWzi*F: :Kj87s*(l ,M9Z-UUV3'PC ,d텝,On?_~P=v,x*d 7oр 4Y$aCIv,侕!Tir H)c{s?x"ŋ2N0wR^δԨ0K97r*Td,zΑ9*tt&l|thXc֮4~5  m3 `Q9;#NUe,MLˆJ,cw-w fsdMׯ D+as<>1`I{?'w V |V@Zjk[=I%[ Y0GS\$i@mw_r01p 10*h0.Ȝ9-@sF`֢uE,Ba&,:%g_D2aNQX=6 $J 6`Dԇ]EG =@%1Κh\6XmA}@#x|V#xcf  &P*#M'[M9V^iрV}Gc&roHxj\2IRp:Ē*.B#(9l keiiXjhIjk4h|.M4@{X| jerX/]KM,n5po0RN,W+f\۰Vu|?Lp2)7ܱiqk ǿUWnd(6ӐanQXWKdtŜ o̲YVU5T~6f;'[msE]y Ɯ r_GnM|DHa?rX],7הoNhVČZ֌]&%`ҀAu5&f@wAֹbxo2=k>9 5snOfd]Yp8{K5n),/*v'J )t'Kچ.!*׋^%qZ @#xd ^CW+l Z( ^ZBp @L0ἦt-i-߭y@ \%C GD+fqYӢghA{R8mq_dGsB"܈GqܣH%Fl:@}D1T$#E/<4d4b*Gjd'7I+jO2l*]Jgѱ"v+o\rF9Rn=L.{c*ӗ#0 YK 6sɜ5M>3yMj3f9mM2vf9xsHg%ͣ '?π[gک`h?ЈǞ7] u (D=*я$';ytaLPtv:Ј,O Ԡ uD-QԤ*uLmS ըJuTUzԡ-cj1)*E7$L?ꥧKT0ָut]׼u|_ v-a*vz2`ԫC/z 9#҅1\,t mHzqBIU0҈+}k{ '8!:)INTM~ ]J7_!V2o`u]7EZ]dW@ȝ`wNoa-"sk 8Œd#x n0?`_t/ĸ{yw-P¬F$b05rOf`cQ2P e)MM*`rVba#/8\QqB̨=`F 9o>Hv`nAT nΥ '0/n޳t|h0 и!A/4hbgƨ&:zh7t! D"퟾;Ug>"}|7>]A7Q7E07 ~& F0#B//7#%vP3rZ< JvU f.3~x!D(-&Z80D$&ul314`A+P&եB'4 hP{.ê,/W2H|~a-] ~Kh¥YpbX|5^RAQ4'~w8WlE=2Y1j\&F  wB [e%- 15#A#B6!!a;a=ȃ?8a`|a0(=*xG0ajbbb3;S c9&6]8 Ā 9F0q cς=cdÄddEi}7u(es HC U _mq"g#s7xnpz&gc7uh"fZ.r{Vig6fzhZCfiFpC`Fa(Btqqա8KusZa8\c,0EkI w[Їw^ʶm6"ЖwWo8r)7xd$"canVo3o6Hs P4oio4&qhpW@nq7%psthb!#&)&>/ySw"vQ{B#b:F`4"r#-*P^q6DŽ:}3ٱ^98ۧI'KWh>P}M}FxhHWOY~:G|\Fn؁-a CXe!(%&(0uu Mx273C&B[;AĠ!GCā2 OZ0&YZ[d53 )hi0=ڡi :`egj`ijjkm 9zUB3j74G26bprt4CbH$ ICvlʩj4 x{h( jd3rhI1JKқg8ā$0jQnC7v /8؉H5ɺ!gkתhhhH?x!~kҊAj*gca'Ij50Zc# Cm)r+K }Ѝh6jyK 6  }1Dq k@Fmz?“Bu'nw8& (Ak=$y?eHv}55Z]) ;fY a ujp&vv's7? B=a 7RضqW!b%#nOFo E KD)19K+,{Y*M2zV+H{:(iшgq`"|`Н" 7|7 g] y4|HB'G|{<{0| |>A4}>rY[]^,eFH,uK}<*㷎 Z] %~EEj*EK[WKujX"J&!%Ȍ (Ȓ.z~Y xsL-NR44z 2駁Qb{4{ ˱́HdfQ˴!5n|I8LC|*ɬBʭHdڦeJ|֬|ۜg*OxurTKj5b)̂ j"|  &ƜH|fЙcr(euwd*|Hy LLp΅xs n:H}{ 謥"*H6Hͮ֋jhʈˈKÌ&rfKp"m,4EؿK9!{<í$낲']l4m+u>9km; Rwp@" k_)n }UPAsAOy-ר4\v.͑˭aތf]]^אktzQQW1nR!nu'f8gkpbҎy+lw _+wCw {"Dbc>W)$ [z1ZDݘqОL',}R{:k/l+ K!ȳ/;$Ⱥ[ ] *{a.ȢPUf>YѸJg8 칅8 ēJ濻C„G5L MV,+ BZ@W r;N>[NJ_P* %@"l9 zB<: wbUc课2$΂ȵŮ><Ȟ^VaEش^},#x5(멬 g2mCυ܁X_ЇyVXٲDΥ.}TCܬ L,nW<匎ѧf_? l>}_';*~4 ֐N2nМڸXHx< Kf!}zJ^Ӯ]nҖҹXCJs4zgHvs;Ӽ7HnC]JJ3L#`!qʋ3ޑ YOtG1nVW8fH{iuO92;<1 %IE[kN P^?-CR6;&9n;mFػ^a"/4`(J ]u]6u0l~e(ґ@)$(PR )0J=D .41HI, *- E8@41Vq@C#%4$Z$>IWp[&l$_pջjmZ∳k4@ >v\v%%\.u#j 84]}2|b&ܸρw1GsO^}&٭7jfo}.%!_ueY3D("\N|e|AO>"o@!°B 3pC;X<QK$DSDQ]j£(HO*S,% QA #s{p%0"2+rK%LK2JfdQϑ@rOG5̓#SH>DH' mr=TDtDtRJ+RL3/*SPA;M<71Ψz;4b11H$k191^8e.}d>[v`ǘ,#-[4ޖZʖS39%({z$p2KZ6yJr"TQ y+4oQ u8mMu.4E+DFeo[hG=QQsWM @@7|oؔFXSq>ũ KU-5uT& WsP ^t`*5 YQ6CCa@:*i֓xS>"(RT`Ԋr \ʀ[7'5ӉЌUru#Nᰚ%R)!hJÇp&1c!{|e$|=BFmfjֻfȂS-TJaD,E%l Xq.a69֝E^S b[(&ɭdVzYvlS@ōqhRx8-n|\̘>%sڸ bAAu] op JrVR;uonm6ڟ MA?U@FN>'wr{vdkN]#Vh[av(m* *ׂqXU' #ָ'0wӝ8.`CsPw@@ fD#w1@C5Ugz M Nyφi>3 d[m]na%, av:SHӜ@yX0蠑KWryQ%Yh!,Pk5j986D7@GfY|([e/ϻ9Y&S,2TS5H"*:}O=p_48jm~!Sy?iaMwiм6Mv9 N):JL5-EJ4/˴׺P4+^NupRjT\zEvUmA=.+޽(_ =ڀCW.=c!AAXhe5L -(w@kQ`}{0$*?$ֲgDt;,fCYbٌb1t;66ژ,+36Y]p}mOPr?8 1.20OC|@@炇2PS8МP,sPsTK» XS 4r!`x0{]˪ф;QHiI)[s?c0=+<oఠ0!k1c %4P11DS6[0d 6xGnH4P֩XڱJ{, os`P!yȳO 1c;u|ܼ ctҋ${#EDz3 O{я@InS=͖qS1l;> H>XM(6A?DR%u&N"l)yI?R1eȸ@pxc-gH/{#!cpS @ UcUAdO}P@c  xf]# ?T31V܀hو}- U#!{{.dt,!TT,iMBJ$-'E < ?(6(D'b3̀T)-t/mnQ0 yCh Ú%3HC:ij?| c Ʀ]١aCHlzX4P }xum1u;j)SU5Y Lѣ(K#}hL%(ec$L3K5.=Fg 3ml8@F>CG@p!=E`G-]r4r!I0O~6D% S0 j$ݗr1MS/-+Q#K[$W׭{5[t!s"+PXXҿԈ0{ب bnöT6]a6_mK6\h $lLK8qpJt+L(HҋƤt`#(L}Rp$us%UK̮(J rA& %!P`y[.6fZu8eJMz[X_ǣS-Wk09TN‚!4fNKgBM: 0c=ct?BBCNC)*;+V/3N5[쩻v\T*S4Yɻc=U/:9XAAP߆mRK|MUTNQxx:&NƻQg;$QeA] 5_`67,RRRu>ݘg$*-ieX\[n1M[*-)H6IXT Pޢ3U0U@XxA٦4U DUe-Q;pdif,7i90 ,XpiF1o8ՔGr;s/bI~V[/ fE|]}R~%_O(_akJ$d< Xi 1@U,bBxR@liqUCa@1]1;TGC1d  #l3(:C!V"nC@|x@]|0v:_kUi*{ԄhrXb,Et"^]Υoĥ bF jYhr]Z9GC瑝D{w_mǨ5$eҭjxDj9pC$9DLfXuCn婳)ꖶWa𖏹lI8ƍ+fR'fNJ 脸<ʫ USA2 [06W2MJ&>K 6ۨ5Ja# D:L'̣CRD0D/IP|#dUBdC Ӑ6MO$\Kg =-M6B"$IuCu_o( *NfL= M$5 㑺369-c\M/x[I@$J" S:?c cz傩w{w|w}H=vJ,'LvXwQ WvQhOmu[)#XZr>,v7m_of_wkyM>놯ϒxWfWg}fGh暣xIeJh(f3 qyW(wBg.Pg3.v_VgjW>1tפWx^mWcY~3BBC}q~\e4rlF'I h :*i9t-\OVR؄[m@?VG!9*&6Ajqj Yj-i bU)HF$/z'5V*R\ǞAplsHp-ΎVG7Tm"&8'T%W*zz-T@j% sD|4 Lh&S0:$I?S1YWV3ҕ$ L,Mdx4n8t::<<6RN&攈 uZ 4 |,J~TddAi0s |$#|8%!u'3$ XND$*t4#`ɜ@,mD%^x -&!rN1cQ%240hL6v 2X0xI Nk'_x"-c"`p"9(NPuNyu!SZ ,Zli*_0 2c&(q-B]\'Ö'bL1#W |'h[1=='Er\},!&}X<4fw$7ˁc[f):۳.q3Ҥ\{byݣ@N\jfѝw_^z~gKaKYhRnG`!woQ (aRanLa Tf ӆ"^蟅:"8A@d?"K2kXSRYWb9 c^0cU))2U,=yoH8 rcؠ{:'WhΟbՎ~%fXy֙j]ک < ꢡ:ɃZ묷4⤮0| X Y7m*Wr鬴k34 !O}BméB\eҷZ.u5潋""0RH'/x{ z iĊe,fEj4EBB8N 5TXjC8Ͱ +cp2c8UT3cOk85^x k2yvLvv l)p2fWKЃ\\q GXv }Xw[6T36F;6UPTNY {0%%N` 7B>;F~[AMb@ĨP^pN9u'Tzmh MjjxPE`1I0aIƊ.%1iG!\ rCM4Am# `;}n@R@8]?,!R?D bA1md1ڙE'd*[Kq"g-|0  ^`" r*W Sut"KGAa<8Oh1q_3F 3QW&O-8)jBJc9Dek&R.f/dNII$sdsUƗ} &CX8s#7x'%j]J&J!C.rA;M IHA2zeғIdYZ)K[*-S't Eƴ-'%Q@6j"se:BRBqvhNrΔyJSS3 .>WZVVr+]m84&U%3:dpuZ +zmg q-j@h*XC %CSZԭD6{sN7k`.9 N螉}QV#X jrmb lkF֊!Uڒ=O.;5nfgΑKxUtvQi{S'7eY,^~x uϥDv~IE7$@\(8jǽ2#j7|UM pۥn߂K%&0 Ty._IBِm'y[F'"ab{ą̥$y (?%0t|t KPl/=Z|A?Au8gBtoUhb,WZ vܡLDN,wGi-Ԧ%jИtxD#}J {lOYch: f}(~, 9&?h{&'%.:QYHSI8]2`* hs-.kk'E͉/9M% ldbZ5M#V9-|<'s% mI2<2#L+%4G61 cʻҕ ;[Ps&V/̐+uKx%s$ge9j'6ҙh"ұѪ?|7y񰼳E&Jozӷ3rח~?W5rq%dKUv*ѥ%-UZQ^/U1|jt/>/ʏB:H?G?{u(4)3l@wfǯWPqSFUT)PS Y=Vr%%`:U΍U *W` NC\U ʠ\ J9e Y^W!Xyg8d!d\\V`TjakZXICnC?@<5 )y @̬]V ltWʀ wq|a5a<"TXHM~F$DMQxB7ؗz͘$L7jɢɋјe^.XXqK!= qm>oEeF͆I}d84ÿ\.A, IX@LC#Hh=CL\6!O=(,^_.Z%L/6YĮ ic$QWݲ ǍNP鞋XɐI4HP5aJ`QEyj4 9T1T_A=TD'tHq_IY_ ܛ`\ a"x`~Սq腮`}Qf( :`(} J! g7'Ν b ZTn(Y)i5(},8 ڃ0FUPm'nonGVJ4 굺0` &_C +FĎcnrREA> 0t^:΁ 6ràiupDdU',!1R8*P{azbÅa% 51a #8|a] Ȃ₢8*NP"*rq_c(AqNoR48֑`"яs%FFL"9dJ%C-:<$:%&8J.ѓ%YV򕰌,wIHIi'$7JNo|$Xa23|'MEjfҗ0czO3Yqj&NQaLb3|g)rѼM@ y[JU0+Ubk%B *әA@3=r8hLT(J7pҕrP.ek#ED'.8})NѡoբPQS.Q*թt%6e*4U5U Ųc̣} G/~1i'M:q|%Nͬf[ӖN}hEJ`:52 `:x >rWf /g-,\hH +O ,E'2 3N@܇إ'Ұ&;PL*[Xβ.{=Fv1A,hN6pL:xs90w;ƢLBЈNh4CWS@;qЍδ7N{ђjuK1{̟NWVo:Ԃuq KRεߌ]а$yk<3жs8b8*6Tfnkю3Mn6O}m؇vqoi{V7y>խM[̸o+6^jXu\!Ϸ=A#[$O9O>˻*v'\,/9s|(1%/m[gis#d-Dϓot=0._=sgߝvgkMm[_9t_|=wxVֶ3'^xw=Uׁox7=msz~}%Ͼ-KO׹p/-]yϿ[/e﫿^7g5qR ؀y_8-t~ ĆR+Ӂ" W"E*4F{ {/hF1H)dMvn7xa,Qw-v=r#GCAQC+҄i,$pLB'3~Vǂj*XTDOhRX)_x/Bs<1E1:2ƒ1e"1SZD13E7!:s~1s:RB[Xb;l93:Q9{sa9(:r'gVJ'~iv74$ *2<8hAdkh`x89H7X$X$pb3;oB4&S'53&z1Ŷ`?hShN 3؅8Xs2h8N.2L.gԐ_)8 ɏ\ )DIY؂d>88}Flxf&",72s%f@CȊB)nXB:BwSB؋ja.g8 Y=iC?; cKӫS*ڊtg69X*z٭-ЬL@Gzs&ʐzNz뺯飢iXC=$ NE3$KT(_UE- ױ[[e@(y@)N7c& 0*,kDeVktWVXtVuJ4H\AFԳ=+Ud$X VB[M,*;N 6XXG5XGuGLfQHouG%YvDXօx{TZ-tI.TZZvpOyZINtP[Z-$ZӤX[TB}ޤ\ȥIDeu ]\ٔMջ%n[@(KJ;]M[p]]Żue_n^𤺫rI$XE_pEO^_U_H_[]C{]9PL&af `F` F %O,i` u2\YR"k[Rz(T@ 24'T܅uzX7w/73kxȫ+Ht-&62Yt|"??&IaNĞ ~Ȟʾ>^~؞ھ>^~..~G?_ eeI^Z^#fV'T# 8?\a0B"F$|8'a.J&7oDigL~򮝔U2A܂8aT MX3h_p/d#.lAJU}O<.ow?N5 xOr?kvIls__eFY2=g#5F55 eTWbtG8߫iO:9oqOCz?CW>BN b]s.q$ Jue[W872}EM?6f@"EX,KfFS"zMKLe冕߰;.kv vCc8[GQ^D$,D3lK$bl@̪L t d1E]em}t҂$P# E .6>FNV^fn>yťΜ.p/'/7?GOW w_߇ZP@UD QD-^ĘQF=~RH%MDRJ-]SL5męSN=}TPEETRM>UTU^ŚUV]~VXe͞EVZmݾW\uśW^}X`… FXbƍ?Ydʕ-;httrack-3.49.5/html/img/snap2_b.gif0000644000175000017500000012056014336470674013752 00000000000000GIF87aJνƵƵεƽƭ{εB)9!!c1Z))!R{skƽ!ƭεcZBZkJkRν)!!JJsskscJc9999kcZkZBBBB{BkcJ筥skck!!!91!s1BB9!ƽ)))sZZR!!cccZ1kkcsk111!B91scZR{s9911)){ν{{{RRR91)BB99JJJ11)JJBcccJBB֌{kJ911Rkkk{sss{sZJ9BZRJ{)kZƵRRJƵksƵZZZsscZR9cRBZRR{{s{{kRƽ{RJBƵJB9skkZJRJJνƽJB1ƽskcBcƭRJ9RJ1skRνޥε9Z眔{c{c!ZRBRRB{csR{ZkƽkcRs,J@H*\ȰÇ#JHŋ3jȱǏ CfIN@`ʔ-ata@tRN:kr( =5 EҧC>@(Sy&Ua`}0hӪ]hZJu JNݻJ+8Bx%#;<#2e+c9330c4ӟSvpk֬yĆ@l#d=GEF8P1'q*FxU>O:C>y/^=鵏Nз;£.z(D 4Nъ^}w8m=P>󣣟7@0q3`?E. \A{r85pwAF'HBorMjxc@0= =E"l&DnmlbKy3" F~ m82Ѕ3#h(2#GF {5ܠ VQoL!(J-XA9q}k IRҍ7B8RQ\7K&j҄% 0^^*sybL&29P4 @5th̦6nz 8IrL:v} 2p&( XN t!9Qʽd$_r"3 GJ(GԤ,EH+DT/ŨHoҹ@:Hh,yH]Q/]^M:Ӟڔ*OcZQ\ݩW*S,^3-)VֲNeZ˺$j:jb pziSe`is1q-k6łKGԺ4Q,NAKZ~bUVjj*Y PzT:v> '7!pKЂ(-CP3 @" I,Me('P2$7lg8(ц%w. aA0"MeO*.%.>։4+SiӒv?ݼwxSg}Ϝ;@ Tύ⾽Uo+ֲVFqkX~9'okG^9[~Ylnڱ[O}6Ozc֫.Ryd-hi0M.u,'Ls;Ѯ~=hnrDžNx$tGϺ>,YO399ؿ|ɗi9^}D~UXP,|d77 O2|Du`l0Pwc@@hNONxzOX8hcu0h[p|h!hgH Hhwg^5h2`88X:Q>çC[:'U"WP}sttT4a'}/h.v3gQ"ъ8wp8~tͤ|طd͗r7cԂ-Foq(z(pV|r|Cƍߘ8a<ljox:$yoQq4dKtA׌](W{wCg'T:ȐG:YHS|Lpw:#IKG9 bhU(iJՈDY43@=B6~B:<lkA#4C'yb(=(>渍@ &eiN -,B%?l2\ IL2l\;!8J(x-ekP Hwwy B8xXD8:F%j6z<=^ 9{x c`zԍV (DGtA$ƺ˾fT2JX`I4ɝ,u3ꉛP` P\˴|˶\˲˻˽˴ ̺˹\̱,ˬL֌̽<\=.p`Fe}Ddܾg<=s' Y545c>^ѾnܮTCn۞Yڣn,=-qg} ~̡Ew/m+'^8hPz6ҍW3a}\ٕ4c_C$H*ZQvv4ɸ[AT-eAϮ|ת8#o~x6i}4v {h_u=Î`~iZMt..{o\P^LߞoڠucHZK_RQOvgʣ_A*%5h2&lbA&n|"O|'c((n2ԟqa{؏??***+a++1++x1P C%ذbK`Lq SX8$$-r1SR 4qi9@O%RXiS$H0*US%T*W T%[, h%Ab!H[]$D;^~&7"$>xa(|Ǿ|O}~~'o x@P &\`wAb -AN0$;nu1VϒtxWcMdwl]8G7f1V"E]qc5t^[II^2$' XR hՂ'@V @V@xŚ&oGQQqTfHB:Ȕ3]w٤&3Mo>3Фd5iXqj5Lvӝl&hy{2t/)NudHsRE8j.(C9ЈB!QNt 9P^u`ORgaҌ+PQM:YTT,%jFz:>4K]fT]ԩV#}jHJRnыiYky9EXV!(^ 3 QZ0Tt!xB k T 08p 8т% K(+܀RUz6u^+Wqz4HP?J\yjU?-;\:WgfLåVbġkB@&r} gۀ)5qނXtݻ[ƗRoG[bjG]ZVektJ0gjap! 1r\T!-\`p Uޗ5nW]40LSbva pE,ai@34p ՌS2@P %r\1P4H@] jd{dZ\D .XW 'lv3 PpS^s6`elk;iF/yNkδ`#\@ uu. 6ͮkIg*fw ᝰBA!-<5RҖn%Q/O o]nu9'Zu]ǣ6nȭ;ykr/5Cl2޴HCMnzR'7sZw'snugTw*)]au8WJS4JoA36F}ܪZda1Fg~tO;|]qq>˲){z 8:d+yDB?{6ް=>tWƏ|F9oNļ$׵ɵrnܮ*/vrW8N~"60 O>??g>?8_g~}~O?~_?|??c@,;@#;=H=X;p;"n'HZ,2ZAA266#mc.Dk&@2<=/-(BW5V-/ؘ؂#"<$+WW[B)C?C@hq+? &?@})L$LqcPPJЋ0piO@lEW;`X҃-|E[E\@0>?xH\=k==撽[9˳*(€IH$>+_`h<3i!0I"@<Á p2HԴ,38&ȁlǀ0×bKbʔƽljĤ*cہ&љ*6Ń8c$̆ PRdd wPIFt!|χ\S6 >T9RCM(MT=E.}59u0UTBT:CMT;U-O7]T6mTIKVeT+E UZU0018M;L* <4Ȝ'Aȃ8CMf5@0AiC/-pn 6x A6:ḿ-x>CЃ>x/`-;;:EoCnM6ȃ6:WˁxXxXF6\X YY}Al`uДIV}@HYYYY-+05]5P-(ǿ7T'ZZZZZ5(Z 2yJ-ZuLN*VZ[[[Z=Z-;RPR/G9b[1 6~[}\ȍ\ý5 [ͺM2\Fګ\-]=ݻ[EZ]ڋFDbr]FbUJ[]]ŞsFaĜG[[8r/]^^(Ȃ,EP3[Z`$;m=iq X^[e]E.ZNʍޢE f~```˵`\[Ua ܰM Vav`^Na.ba ` a&b$՝vb'n`굩&p{s#Хsj#b#_!a"kKl,&P̘O| RcUinLIS:\!Y#odnZPb gcb \敜sdtO>87_ՍTR,eqs+G/_Uzi坻Fk$bbIMfJQT&J PsutBJJzՍeeQn-*be6CJavcЭ= {d$%p8Х?"esO$p`g*U\½Ih0]ۀ)EIPh (]U fS7wDHd$aNfjPhjZx)hZ" 1w1k^cAc5N^8} evHMgыJj納FO)F^ #nvl6lŖžlllG6jY72d%g趮e ew,kiV_$z$n>ʿ~$%}ek2JnPnf>uIm8^kZ6Bgy0fQJ ob&Oxvkp9`ooopp/p?pOp_poppg]f62"ftsmc)b!K7xLX"Kh0hq٤q'$xbC-iX?fqKh4Drp؃P*<=3N0'!h =%LI4( Ok\lvKb߿"'`J " "$(! J8~!abHB aIE @RsB+ 5IA 9P(rK;H3C)(CDR*(@2 2lsK/HREHA)ede9+hf*DkdZl-non!g ͭtE7t]v+y]'$p}g~ {)X`pJra"{(&!}C!=xD%2N(E)BN8+r\" AF X5n$#xF9sc88汏~# )ARA0$"D2rl$$#IR򐔜%/Mrd0&P`$%&DTN$+]X2%.oW%_s,^Ô!P@2YAf/ILmZӗ8C6 asWPf9 Lb2iOmS>p*L@IPm*8)΃EIN|tgC=JL“AMҕNtfKIЏ2.E25Ӆ&T1h?kMt mHazOT $0҇.4p2DU (A(MZ 3tBfhd tK)0"d`BY! :)OlTRY5-EISF)lJS'jgQמvmP?YЂֳ-MeQі(>Gkۜ5fq]Fwviz xH"p0RAsǴoZC@f KZ7$xf^ڷ q02Az%ql%]kq{[W4nrQ/|WRzMzd6J>.r R iPA'۸2E+vf*w7df s#\>.c<8zr u&1sk@>fE@2wx2q#+y|\U4ՂNgCcaf*2PR״4vkiW#׼ƩSkl3&U2ciwUւn6[yF٢9FQn4mip{ K6qYxN4uٽ貚ٻ~nlGү>s80  + <*=˕S ??h`)`!J`N2 8un |tLTm׽-i]q]u ">߭!`` `2Eq n0( υ!6 V\2 -! "  ¡V!Ix!P]ב`R"a%j%X'bby" Z)b&& Bb&=-b@`vIhI (ʢ" '`2+b*c Nc4**23f5Rc,Z,b –-R!..b [#c(.#7 8 8 c"b!J8=a%*~a@B+$'Md ?DnD EcqcUcdaV(B0=A2A4cXYRKrTV%V /B$2T c8$@c8:d^P"cQ*&!dQ:e6&>eP&%-6.VcFݷ8=َ[^]\Κ͛j$f2fCn&Ago!p"@cbdd3jEfS~aTjDݍTƤj$tras$R sN'Qbo!rDI":Zd?/>j$u'aZH=^rff}}?zvjdAP"~Qm>UfMc1>2ph5BVRhq|()}zj2"[Hh[! h `@d@7 p7y)KcAeUZ4H坐)?bhB⤇ g"abdjL'& x A2U`gr (_xXXX@ 1T(d@#SdR#Z%d\ ]&]e2uЁ~!*d@T;-+gU0A(6=AXkA2e@TAd|zfhR&*Nh>PTĆ@,F$ij 2::A ,^+WlCutv)Ѐ@l(8SA2AB2@ɺA/)ҭR,̺AɆBXR7-A0)G@/ @#AάGЀA4 ^ 9)&:2n6smA@,0ulu[bE;X)=٧ĵd&g"zjrh1ި*bNZf_"Ng!ٵ'6Z꾨9ƮhBfn f/0Sv  /1Q"j*kng!&6//#"b>oRf2JBb-! z_no k/]/{,$}Q]pf6/qpN/xRd  q wp0 ? ;u/S񚦸 ]f._$"dKq?#~.f(1+dSYqge1Tz.ٯUdjߕqr'&# cq7im⒚x1,+322#q,'#&/*sWSpqf#h(è,'o+322 r%% (0wj22ڑYp#2*r6/35s/O1->Gq-?8/ o+r)I%s26Ftۣ=i BGwG4HH4II4JJ4KK4L4 \؀t,A-DL(0'/YTA%\ \؀%؀S@TS'|-/x&2!׳/k5'Ax fl9!A^w84a6b'6h&A<+A0v Ldm29%@@u"`5U6TdU-D[@r$yqZ+۹ZFAA h&ppl\+!Ap\@ TrϵALl(d_r@azAlf_ 5qwwh~w}w_ba366a(LcGSve{rBo(g:*5E3,3;O06/[x]p4\Ȍϸ!8G[wxA@86g_GxAx`\ptF,K9p999x 0x]R5mx0C5951o8 vo#L_tC" ':/7:?G:OW:_g:ow::UStH6Y WCU0ӹ9S0y$d5?o>MYlr?B;O;GS;W;`w;{{_ح׶X3:߰EyX rC]Ӷ.=!g;=nWܿy 0Żu:FŮ:綌6;/<l;{C[ D$k}d}sׇ=؏kٗدڷ=ٿ}=˽ǽ=ދ&֠oW>6;Yu<ɻ9B|G49S~S}W.*T>|`EOy/e߻X{!~fg3tnxAW~ݠ7/hw2Ԡ|r@ @4e@,@uhC5W2k1+G Hynˏ 0 .,@C 'D8v(*B2xą KbXҢB- `ƞ!%;fI5\0MYjNjh.LXb4Uڭ=Ghd.D6S7ŕs@C[vQv)IP&ɡ҅T~J}I&! S`b8aB/یK ;iO^TOʃR7[|w%mNڜK]'gVђ`Zl2/;hz wݦ'%阃%4kMWc;?)>lhR 垛ힻ7ޛp87!.W# }MJZx<! BH=28z/>:z#!ؘ/1:w/duelwe 6r F8 >'>v/|>ӧ}.!  X@;SH%p br]!Ț%sLf[] > C!=> +_G0O ! ay ۂVmY'Dv `G ^ꐸ,r$ ^ȁE,z F7qtq:.p@(] w:?]j<ܡ$)I@2iT*Z_5HfGmj2J,iKj2D'+b(Q+_[)9gf!Ċ+kLg>Ѥ%o[#f2}D[!sHzL:Nwsn%9OfIeSZ~.ss:l1 UB*Kj撓6;ŶN$=FLnmOhHIZR2 $HV4zmrJgNSܹ<9M^_0%%jQ~kiPZU2=%g2_BzSҢ"UV$Wy}^jL?MQ[ [XþqY]Q:SD-}FJP,tAa9Y-%茔w})(6 r XlakV5gy[npyǘ*~yr XNPήo"p!+y`&2X.EtUk3dUqU1>W \jr='6\a203l w0Ia 'NaX0fq]a׸+60I۸ 9 DүveD-򽗌t;ILźoxa@{+bv&'9Q4S2 9'k6b cs]8@q4@ q"0E"&02XD! ! 2% LiIFP9ۥ)"pFHK$(t#ak%a ,N[%TNONNOPTPOuOPPQtQq (P8oj/QDAI H0 cU APU *@>`@:C `Z U`!2@`j N$,4&ZcN j"@X$@E Z L$*r` z] ~Bv !R`#R ZU>L4D0T#453?kN3Kv1RAJ 䠫$v@?WS^VcDfd / Tv]&vejb"]*Q*@_,bRh.$5t0ï>M3nFb.1M+ F"U1@X*"AhTA`6bB[EYa; g'4s]g_5uY0=sۄ41HV93v0G3$޴M2afK4CUJP+eEwXLfHsWx'*f7-iSSs;y`p^@|G@F@@~RU ^>J 걾¯>5-˞,@-~)^  _> !!?$,7;7/_@0aIP_$_`_\b?ɼE o `Emg ay֡ו]qd!"!ٙ]ٷ_١}_۱dÝK!ϝ BɃ J&<2! &`A!NƋ!ȨqFGK I)t f̙.k֌i3'<{hTJ@QU̙լ*RuDcZ0+6TX`޶k7/ݺ{RKn` ?b S0رaɏ+OLAc 9S9-!uf I` جgf=5 {!Å(~E i^$éKOr< v$VQB@8"o>|!` @X_H '5̿oNU ?,JhA|i)r $K!p r1,)h<"B, /J3#>A 9#:HTBPB9dESN RFQD!fJJ)2DS dB@J$MFdERFy%YGZ~tEtdn}fhI7MpSuމgQC%"LT#]\]h`)V#裓8_꧑a&vjbOZ&ڬngf :l۱= foܵ;ܵN.ҕqK W,x1u  ygdx |&G9Kn\eTYK2dk9dl-_yjF3}c]x1ft+\85mch8׻nv]c]ۘ<vm[n dp76j?vq xof4q_{u+-K􎷻dz6>sc;W7n^v|,0Vb3`Q(j a^U!H7+pqbf{']ȌͨZGwh|7utڶdH7v! xh<B&xlrl6q~~G6ywv㸅pȆ8}ȐvZgȍ] Yȑf(incטq~떒f qvƄxw6qw&Q؍-w y}UXɔնIɋۈָ;)]I'~IF qqI 0rYvwuɗx{)II ٗyiI٘ yY)Ii)yɚInofn(f(k9qVǜj֜ r9YF˹ỉΙY i虜멜l7 kٞ቟噟蹟iiٟ)t ީzɠ~ovjGu9vvjygj'H$-zv/;Im(*ʕm+ZDs&ȑ2*I١4j>7-xlY9O(*WjW 9I*_zhʑ(ydfg~Z90I?~H>*(jH%ڦN9C|E Z7I7M:hMhYjDZ-)~Q8}x ɥʦ$FY^ǒQ(xB 痢 "YxjǪejɺk^YjZmzZJ\H̪8zoCʢ:#* :2`jʤȚvzZȩڰZ su' ɱʯVzIJʦK+=h D^[-n .]|Mܞ[3X g@{pt!S.a5F ,zَc505|Xtan7>>==q @ݪO ӑ-aθulh[_ً^~>:OM`_aO^axjE~pgP ܒg9d? B_;@?^𫾧Zc~]ZcFooo_bOԷvoS{] 4ۯϼOOFǮ:߹ъZm9?ЏO`$hP`ƒ 6d!DJhD9:4@H%M7bUSMFDulڰݾ- -۵J;^j-ݧpwd oߓ-Lj̙5oNՍv<; ~KIJnwdì ob7c๗'[q轡S.q~J/9Ӵ}M D٤7/V6aK9KŦSNPA!d= 70C8DP<Ȭ< j' `oEJ!t1G!1$"W0J9+'d:Lr*mDJl<лI+x82lh?§'csJF2AɶXqɠ †8˘"8-j,O''UU|U.ug@Y!3<27;3E\Zu՘ dX%WD) 9a2%2`\A0 \ *6I+=#CVN?!4JЂ5}x Us6~.hTw5y1Zd/V3!*,=sq"hٚX& _v ֐+YQA%l3   D!%FY6D8,ASAy@N؀*B0`3@+@*!Q88M}f  4C"h2F~[ 9ASnVYډ#T >6VO"=Eell`U='E`\eӾ=i{d,ZUm+BlTB@IEUDTj(IUˎ4MX:et-ۨ=[],,y h/h$2IҴ o_7WefHb6Ӣs&\Zc\g?ѐ2=Ҩ7 LL=H"ϫjVghO1Jw3C={3 R UB).,=KOT,2HՓ;cPtd-S%)US:kγt3՗()Ѱj„1M Kͯa5k^zVzώ J95ҕr*b;qnqX**Rieb)k>|(Ht55f Z~8]sMzՒUnElTxwm,YKZWpJK4uz]z;V=@oR*s帑E0D4VQ}Ui9/s[\} b8K}/5_̐Ǔ}*i&fQic]zFt/΢+fkzV BbeL߃YVv*2piL;2x\e2>v'KSȝg_&7ŧ4NAkYP?wٟre퇏^9vtN:ɹZȘ0  ZVik%#i%7h6V2q]i]Szri3dZ٤fq QvfTKZTwx2uo!&v Ub` z`-vU,uͣ5w+pt2Q=׽zi)-^/O&=$4DTd@ T@ <@ @ $A =p,40a*XmҷsdK HR$ڐ؋&2`%d&t'($`+<`s򻿴póċQ(F(J0;2 Z8Dð3>H: K>jDx)HIJ`?L8۽?Z=x$;!И4?G>=R.= Hȃ:0d F `yɃ> =ȃ@o(L(M` ˊQt;(j8P@(Fki9D $Tn$ mh6FmƉ =6#=Hd$=FiɌ2#(I<-`"ȁ-IAF< ǧc8`0DmB= cw(WC<&hP8(8XpJhKo0qh70BCRD4R$4Fo mnF1PBF>d=$ -άȅ 8 >Ѓ @>ӬM ׬M݌$NăPDtx& 323DuY>?" >;" *x` FbL @$6F܄=%|=] NšUrWKR]#$VW\Ķ#U[5VMȀ `]RD$ڷc*[2 @&'ȣ}m௭Q齸F>FA^5`m7c[`8.~8֠ǟȀ>iXdW:% 'KbmMMcf* ~e04YJ.dZY+ @YWyd@H"(fhdH(edc\Vh\fGN н8ZKJOxn 1rQ%4^@h/&8VWC.%܍-B X7xh@Wh Iur!ס x@Ji c2(h*\]~ޗ >hWNBn.B8iXJ(s0YkFy&fR^3E2 3(xNqKI4k9xik&=X(H9OmT><킨6+0e_ 9X:ء`!(~ 6;m=oVCZYbIn?#oX|UHN8 Plx8KfA8KD`Km)1ݹcy>zv&Nƃ4̟+%p=` n"UH7lW`l>i'f֜?̀E恰P=(!/p!B'^.nН^CO W pb 6 ޭsXU7+ˆܜOƾk+كhZsc$zwM~0|+~F` WeR<{W1$oYg?X VfeB_JexDžm涙nyL}cɣkj}Au[u N\b&P!PkҥYk\> r,޸r^,rV4jst3R~f&l!F8z@/`})[X7+:ǹsK]zvZ.S_՞#`Bɼ?<[-8ue<#vl\]_o{-Uf!x 0POt^*h b5h@})_ @ǻYr0> 3h0*;bȕzNHtN%(PR"e?" kd!?@"@?/O‰b7#A+ ^32Ё#\$#ó{$ZD)ojd[2Hsela2 Z@jZS ]hnSY#s>J8&2 z缓"iCI#b&G>P4s `̎곝&%a>sSB5bO~U&߷ĊPոJ5jU є5\\Q*Vҵ4Z׿ƆYD=).6QW:Rt@_k˞UU҃~9"]9~f]-kgҶpRsY[C:Vf)wB3ՖS1 'pJ2nu .u&u$Ǹzw i}& !B:WJBVTuVU&,ѬFE䑟w]kԁM`c8D sϦk 62rA:&w7 m;+KO5?`7w`54'K_ x> ?{ sKWDEދi!q! ,o+s@`0-CrΜ7*mދW&jwTd@x p?π-hCЄFthEC:ђnt)=iFcїִ;JzӠt=MS:բ^UjV:֨_mkY:y3?h6` QR+x͒f5bK{ƙ…n(aX$fO`Xt{nwr> ⛘^2oHF6ɝy .otc_8|~ӓ-^pz%q}?LN )"Ld1ٳn,- ؊$xUqko\zwni{9bxNk7I˽7ld|OnOz Њ\ǻy]}gk0~ <͠q%Cw.y]2O;ȣ]~|r'H'9]|ۯf䱷|}o>yN%8  qQWޔ(MƊE^mm@]]_ǹ-!^`e v ` _* ˝)`J ૼ)9 ̵ɒA!j`X`!g3E!!_B"_R!]NaE-%r!v.I^̥))Zb*b&z8tAa.\LVt9WɖQbI 3.c33Fc4:#5N4V#4^c6Z6zc7b#887#7r46^4c:#;~;c<:ޣ=c<#>c>#@;#:@c?B d6:C$<#3Rd3uT!$ Tax=WHH */䐐= UWMaъSWQKNu8aIriLҕR֤POq!H$T*VQUN/$E?^ͤG6YBbH\& Krm1H&]T^te!VX0M^_:&f_j^JE dRd&eBdQ"VGFeMTeddO%]ae$mjI.Iem2%MU&x^"x&/rkFoE&)t^av.F[W`anY:{pQwNgSiq s&i"Yrx2j"h]&Sr&udSj'P6igV&wʦxڇkʞz$$RA!?ah|gUjU(qVI(b nmKo~&}hV~'lBiGf~z(\({e!qzՁʧ}^v参&M(,W..=t/Fhv QѨ)f)Z6&Gd^>*^Riv"yJ(Q]^jePfru*i NSfjt*iȤ芞Jj`njkҬ6jJRj:ޤbhd(AԀ븚k빪k뺺kkkk{ZW 'L~fbNrhZ2a겂zV{xW:ReЪ`y0vH ҀaTߥ'\ 挓wHzjiNڪRƷʆGˊُx-ҊQ*^RkiY4[ 4@!0RJ(huD/ @HN&chl)&))>Ǔe~2r2mjjbkîu"+(L)H<onV z t@ 4J^bL lR(F/R/No-ŮΈb.xh.Yp9C*mbkK1,lHdL@AzXІ EԜBm44A4$o"J2jf04A~wHW􅩊f嘊^Y~EoϒGܞE>tEd̮ޞ{( 0 1(> gr/o{px!plpHN--"&  m]} @4.W@adԁXm% -lE؂ ^in~gw f/o~쀢j_nF˪n xa*Y[00.On*DYT[.Fqj*]mԦ/v 0778s88s99s::s;;s<<39kW(zs؂z5-ƒ//âIbljZվp~CmTinljY!lIgWItJIJJtKLtM˴MtNMNNtOP4`!,%(uR#rlf5.ְFf6dvN.js}2r'm"C q%]rl]ߵ^^_u``ua6avF-HJhb"V-1(WfTbz,BnӞ(($yW~e2lwtgk/\׬jZ'>2XSuu6>li)s*kJ^vilc~v>gEiZ5Ed&grqpZ+nWǵZwfW'鏊,/b2Wzҕ>-wTe6n$k}hm[qt,3iβw7Y5ii6x(67fvnj{{7hzvx︎77ӕ2wl1V {T1L6x7+9eR"5F8u'9#hu~{vdxR54y~kV6N8_y_p_;n}xwv89t"l}6hr%!oUζVfJw]1v@z7sGsw_h{0˺tz ;{ {#{;/7CK;+{_{G;k{gsx ӹ{i{uA; Rcd@ u7(`,H d@sϧ' i~>8z;xn(9R8:d[<ߣg<{|ǃo|7oWpE'x {u*dj1PB |w5U@p i[߲+nvœjud=lk}5.֗wׇe d=+~YxW3|y/C7K ,TAE(T,V@@A T>@@l{Vvd@-Ȼ T~ ~@H$!1B0A(?'@+BW A2@Tȼ@_@xhXnN8CKx7Z-x@ct@()ɠ XC+,@E #xȍ%IXE'Grd˒0`ɗq(miSO>@U H G:eϤ3V0J`"+N53n*d 4Tb *Q^j*;d dE "6(AT|bpI\M4΀1jBv S%,Ѳ&%R2Q2#)v،4>B ^R-/qþgml*@-3qӣ]rg zh,)܃S% \Um(Wۍ\|dYn@#tSe o^2``B03v@1p()"b5l[ 3̌bUe}*@'/tC E; W߭ V-Yo)xxRwOWǶ}F|Zo7oU}3'(!* ;K 602@O>#9p/mnKP^n+&f[7{~\'e!?Yt^.7! d|ΝfP +50Y+q} $W˃(4s^t[V6]a1G E)wlBNf!_J9^m{8{ ضqqctD6]~fp12 UdP}X*{b+Q62/%1D0_/# Gh+WJY,eY\.uK_Җf0yaR\2Lgr|f.+yP_E[FW9̊G&IHNߜ J.Їm\gHG9-( jP, =BZP C):Q.@C#jPRT!MFQJғBTKY҄b*F%җT'(OBݎ8Q$HS,S|bH3PΏ4b@nu0^OH~'dPUbUUzuF(~kO.¼$?#bzVϩrR Y"5*\*r>tn^VVRWQ_o=b!.+(.(0aT=+paU5 mYk0BE;g^{[Em?s[L~`a?DsUzuYpⵑQw[ u,$ZJp5j:DFUdjeԱ 8.w7p]텛.SdxGvD eq1zU\SOiK wsd/_y>.C^nB>s%Y=b\\-ҰX+fՊuҚNWrqS|OcFC窜ϺFFmIEmh_pA쵖fQōt{sB3 {z|ly^NKoP촎hvݹ^w. o*"C ڂ91."ѺEk#>lV˝V<˫V~-qyrk7]9ںv̬l Fo<6Q;Jb ">ō䭑GSJwۘeHj[6>oK|6cF?7Fw;P~c! v6+haο[~Z}sJJ+Fo>9Ÿ?}Ώk^ク筞u@p_?ݓ]$Sܑ|pc;y+%xI>R}k얍 ,ܤ-\~L2) 2ːkЦb!^MHOPx*np4ҺoVUL. o|EL,O*i.pn<~mϷj ͨ=R;httrack-3.49.5/html/img/snap2_a.gif0000644000175000017500000014035514336470674013755 00000000000000GIF87ayνƵνƵεB{s9)c1!!{{{R!ZsRBBBJJJRRR!111Zk))!JkތRJ1ƽRJZZRJRJJccZ{cZBRRJokcsog-{{c֔cƽ-)){9ZZZƽƭs{skƭB{{{skkgZν凜sB)!!B=9ﭭΈsZsƵcZRR1kkk1!c{{Ƶ!!!cZN{!))B11)sssRJBƵν1!!obFJBBJJBJvRֽքs<1*{{k!!9!!)sskR!!{kR֥΄{Z)!罽 {))BsJB9ƽ޽kRƵƔƜέ{{kc9ZνVuu޵ZNA{{s!ƵRB1νk!!9))kR99RRsdd!{ZB{{凜k,y@ *40aÅ#BD/jǍ;)dȓ$QLrK0[|)&͛3sԉ`~M'ПE*%ԉNJ*իb}Z]=xvXfN8GMf׾$n۷Wo߿O0A ABÏW3ɒ/cƬ9fL0 Ϩ+NtU:׷gö ;߶ .ȓ+78.p01ѧ` qX†?7/9 ߯C ǁtRr:X ` b!&x |@bEb.RP $#8Ed0 Y$, #$D&œ0LBWE0heWB&aIFg,@&oi(qy}#@JRG-eSPah42UEUeXT]XnUఋ18Zl5k ^~՚c1va4eF9&likf,9j6lҶiVlp"Gsˡs!7vءwWa'{^{ՠ}W}p~_7X(V`'Lr%!(.B)("5"1dC,D $L"4IvWZ_Re_en5n)'dY'}z$ЀdA4n ``|IKD*>,AY,}* 1@̱w-y8n/1Az4,H%A =D~=n::@|W|7ߨKoz3<|~_>=>o{ԣ_ρ{g:0zL7A`GX@qCaxA6{X P(>0y !io]x"Љs~b(zъ&b+? .thF P (A Oal#W?#%dc=^\c'y,cA8F>:2p Jz(QQ IHfl'}Gr$hqi % cK҇Z%mAb&FTVS;5YIH]f\d xJ^0o2}T$LoR!4OQp"#qIO_w y HwbCd(6qRL(χ>ΤHтV4h*/cP=- Nt-8ͩNwSv!ZA`!H`1\Rԧ/›*S]5Z\U7-k߾BMcTTrժe+]zWϬ kZּu[[W W Oo%l\ ;Uxma-X-vg/б, M;U}\Xm~$ַаFJthJ*r׬<#zR= 3mK@R7ɕc$ibףT$H*PJ&Ipez/]>WË́T內nStOQ ]Tjf=KN޷.0,LiҼyKx03]j~qvK_7Dote;`.=mF h%We_z;y^/+X._ ׷sved8#峓1;7Os׻o M_AKT o 裑lj@@{S] x[ a KxW+q|hG%Ձ ^DՌaH%#z[r汒|6#FrLbo htmLP3xa/Uc% 5AF]T55\w['w2#vܟu8A"c\G&8,+ھk='e}鑷4s"\ %p.Gu%N t9hH7yÛn;1:۹qgO԰ _ P;8 ײw;hްYu#^wh  m  D@PWP7-!HPz2>Pj`D%|<-nQ@^[Mܜ3"7Tt`]4D^d6D~؀h;pl]g:C8'{{7~%؁ 7Hwʷ7f;7={pI s; 4p>HGIHg7I;w08P86h7^Qp!09$J<yCІCVp {S; 3%aC@  zP}C0 _ @09nerhim'vf]Vattu`3D< tTjSuxFS9VS%CHb8swKM=_׋uFFqku4euuWNVsqm>oh6)e^rt tW%u]\OOn8 mUNhXyw\yaVux) ijk*Wg(xhw{ESaHaȎw甎eR'S VH'ic,א%Ȍn(HposXd擐VJypStY$iu[]E)d9fi(NXvkYoHv6(`p)uً8bpsL o?>w[S`We!Nz9yrɕ"i ' via癆@HR.)$*ْ,)riGog`8ɘ 瘦`ٙ:IC0dm3~ioYjyyɍē@9YyY 2 7x?IwwIo4UIj &c!ԍDGx4) |߉[9%S"`/yx8uxj"S/ `F+$`&jP'+-Fp1x8I$J* qf`x851УV:MSKZ 'dZejP?ivhǗ"wYUFMyQ t qا @ d  ꩑ਟjZpʪ:Z* dj*ŚĚzʬ j꬏ -ت*JJ*Zzᚮ亮* ƐjJ'rvژVYzJɍs9IqY`@P |0K| N`"K@[P0k /K@ &[) k @ #  `| [G[F0Z\۵^`b;d[f{CK :FYpNyXy:oڰ:)K)Iy=8 "иMxS8G 6.[RSi 8j/x3j[щɰʠԯy{{OK};PJSP@ӻϓv~AQ7]]м;C>ڦ9*=0(;g⛾ꋞM :r:ӹJtɺo]=p{|C%7Vpg Q`cc>g0z7;pC`s0$S7|{gW$lm];wH|];Pþ`p' p˥8"jAj MRi +pFJRS<꣇^*`*;t\Ǹj|l[r;}qYhz۽.ǧ ʽ4v\ɖ|ɘL+dɞʀxzǐg ɬR80iq0LڡW<~p˳R~ ~L_`9%F@  SZ*Ƭ˝;$ `#p|>Z> ",M`m|f`R-f`qDl2 6\IĮ[wֺ(EʴkzۿF4]99E<m`,'@\j>/:5Bj+8EF-:F 8K-E==`8SE}8š? -jtUi۬6]x\ AM,{ʎʫ|ؘ}8mi չ#0-ej;ը]ǛYנ^Wx/6ӫs;nݡaJSc^h7场=/npf;O Y^^sU~c~7H5`}H&.A?0 . 凞S.TN>ꧮꠞ^岾>Nc^>.~Ş쾎쬮>^ܮ.NNnӎ  03t]F rʽN&p|Ca͏>7(o/ ?$(*&_,/*'?5O2:67;2D?/E_AJo&W˓yȸ=_[fsEGHipPrH$\n߶ImhXyߔpcv}~lr|_!'>J_gp&΍zG`kZt?y<y6u??_ǟȿX~ g~nc,>? Ə nȅ:? Cx S70H@ 0!B J$!/ PG3YbG% ҤƓ?$D9uOA%ZQG78BY fL-Fm(iEa=~PU H3L- Ap)׵$_ \6YYr(P@p`B>H^A.=1uw;7]zyľe3&wqͧMྫ#f=[95 /B34oBlp7P" ߣ0ĔΣn%YtC q P6\'dSгӰK%2QC..[nJ>s3,qI,N$MbBBߔݪ!U3 ;lTM&IJ"#m.a|AAvXBWR$B xR`A$;vD`A81 m=B]/v2:u "YxH#!.Aax5 /t`|ux{"dވE`W[wڀ%.LQ+8/%X8Q@4F-|Nu",DCQZ9ETΙD痁thV R$1< ǫJLOdsN:˲=.ܳ:S-K ZJ)~3fEf[/n!b`+*z!`:_ s_ 0!o`sl&ld+D'OH6FFdFa^cDܗh=/3dv|P P`}և_g} GPR0`-(apҦ'5oKNp9SgF w3.°O-˛ MOxf ËHlB_&!=jdWD.m`dǮF |*xF3v/SPLVhQiuw73&q ݲ׵C wC_YOS\ϼ!3}mg["ɇlDؚ=zFSydæ!O@Ȟ'^핢x$BT+CP-bSI1 z!&WT"6XF29(DФ@) r= >Љ׶umm?`[-nKAoK"wEnr\Bȝ.{]b0(wa],|ox˂ e/ X,6ܗͯ}_B@p |`% @`" &#x!Q'2B3pl'?O@oȏ '~?s???[???@K[k??<d@t \@| Ad@4A ?? @ AAA,B@%@#\lBBA&T*BAB0\ _b#28Aj"˚mڥg?t& 3U eʦFr>*DG&G,%3uj&MLM˽EkC 7D>[T#RKCS:[0 ųq>9 K'"EaDDf=e>PdC#*a?jF$b]܍H[xn 59'%Ҹڛ&42%U_!r_ "yԦW,&{lG<&=&z"yqGKҢ`|&sAہ=` uovC]zdžY%4HvT&kL2ƈńtɠɡÃT>SȘdȥld ${'vlOr˅LFlELеNK+Km|K-L{-HPN M4PD׀NQ,QLP|QNQMh<@(/T[qT(@HH=(XJTh5MVhASS[i429FH5]!>9q͐ۓ$VT?]:=GKUSh_`45H( a6KՕ b57SAmgUց0HS($P;% PX:X,F` MJ%HXf4(Vl{]@=0(d%V0Xc;amb@Vփ 48nKKLK9!+ %8K(Weњ J!9Q`: !#Q9@8?& $Jܓ"+R[O]`=t,$N`B$$ܭ &I,^0%$%%&#}QȞ[] Rͥ] EhRݸ,ܔt_C-Oe_u^ؽ] Q߃M-mĤ _pZٝޅF>D_`']O aGIMa]Gz]m_|,]+P#^J|/^D#`e%KbtbmⳭP^DEQB>-b%f6[<^Ea`>`N`b$*6bN^..ݝ,:A6@<dB6A.D6dEfdG^ACdInFGdKFIdLN.LM&eMRPU6O>eWneXVM &5%La 8&[ %&$883 lJm֮m۾mmmml-yAO`f1~l9NV(na~nl" ++Ђno.No&o^oNn.ofVo.no"wwp^ׂO7GWp pp po Z^O$=n`nj;N.kqiՀ8|Ng!gPrr Xkȃ0rrtV0"7r h1 )  t~H  Ph#_r >8& (@@s 87_&VBg`s.t5stNoL L_ .&^9>b52X ksNV$Pffh.ZlیijN]&xNqaԫ=]U@(]uvi HsN #獶yw~wh;$n.YeЍL/lv̭$@f:ߵ6y}ww)@8CWP:yt6n4y05Ow   4?t73GBwzqxj=u/u>'0Gy_{o{{{{{{{{{wr(Gx &/&0t s#Ot^5{\'}7T{AdUU|^!Ws}})`Q]zia_FeeSem&F*Y_ZeUgoפ[ť!I$:ʷ噉*Shi dAI#@bIHI0 HlvY2Heӭ*^,c,&jlV$dy.,ai>&z)aw$U gQUeGBke%.ʋ{ ld[ *آC X$[NumcNXk1@lp"' f;p'i'g#_M,-~ETЀ>pA -4Xz4QK=uMQ$X7)._܆hcv;s@݀ ds@,H(?Roq׋x 08А#w:~ϕ]@^^y?N97yO9gCn;cNߞz.|{ȣny7//o鯓.;s>w< |=b%]53L/nk\V6'G žUI%N%n}p*K~yk$BЂ9a~vˢ$7I1a$hG$QEWё`e-88e!Ġ0/}ljǞ7SӳIilD'3,-%DD_xI<A $O+/Pڲ<`g V>Ri4!j%UR HD&% 9bdP Lr 1c-==SR6COvSi"FӋƩb8Li-cCeU3N|*#vpR+iy9[2Q%Yեi%Qձէ VVgiPf^3}ͩv@-QDыC#[UY2-D=KQpw,3wכ6eZQ/Xq=o \gAzSD*BVuczY~.D9]עaFp e+_Wo{K7+毁W f0a!Anc7AT eز[$%7 +XAQXys@n@JzV"PB ze,GIi|<p p- ȚN >"@"9wp-`<cʈVtPPJ5u"]6&(j@$4hh "Zp$$ AA(:A!Du( :0 By.n{?z6(sR%˶ήA\bO."vA]Y:SÙ$vo[V1tz^vF9>RV)ں1+hS2U?@4,n.5ku+s=-vbpQ.j{?Ǭ5KrbܴyAԙ2mzY]>}K]@κemNX?ܸ_ar׼9Yr e[6W?ǛUlSyǫlwn2w{~]x ^%7}nwܔ1m+<~g[z߼nOe7byNJޯz dfp2O~/Wi~[i ` _`N Z"VB @ )8 3 z Ԡ Ҡ ԁ a "a,6z@N@NJZ!baZ~!VT&XX&!aaVaV@0aa b!" b!b0A<":#Jb8$>"&V&j%vb%v"(~"()")"*@) +Ģ"+. /"/-@  p/.c3r2F# #4r@5&#5Zc6Z6z#8vt6vt ph98;;=#>=R@=;R أ?@|? PCB&$@RE^$FfEEbAGZ$ X$GG$$@GdI dJ$M$L$LdLBNPPB@Q %P"%R2%TF%R*TB%UV%Uf%P,,/.HB |(8&/81B Cؠ\  `B ,/#|20A((Ƞl98Z(C$$_A5TCH:.,7x!BBBh12|!@2kzjnBr!nZN@zfNaq!!a a!N!2:"u"v2"6"&Fb&:%b"%J'r"z"'()'*§b-'+,+b,,,.6ڀ"3c2b2>(2F6R2N6~#c7n(@ ::Z::#=v(>=@.@ΨA"dCJd@ZdjnHRGH~dH&iL$I$NOdMMNMOPQ*Q"R:TVFU陞pBB9(C8]3(B1\ ]e B!HB#((%T/$2(|=@$p1P(CT<,$D7:Bjm&>jԁm&aJgr.t:\t!N'("w^vz#Zxg&'k(b{)k|g}:}+"./".h+**cB3F45V(tテ7nhf~(c;c>cޣ=#dB"d)hE"dE(()G&J$8)GI&iKIRL$$LB@MrQziP2N)SZeU)r pr~-v؆גٞ-ڦڮ-۶ڂA--m݂mm.nF"&.*&.+@N.+A$\nn."VNv"nnnN.N.Aή.n$.®ή/..o.>/FN/V^/2o.r/v//~n*/2ooo*/!oop#pw;p7꧶Գߣ~߷ 1>x=<0IX$%Y%@%,d?$-@*0['m> Tл8G}.7 0 (PB!*P!Ɔ "|XP#ǐ)~,ّ!H=4)D2SLhS%̏$u&s$FwfJCY<'MJqTj΍D lXcvH BZ qP"Ø WnWD 7Ex^])K^wkŨ* sёYY**tr괚o6NXO2]ݤWSƜ.활w q۱}͛8Wu~=jٺ+WwٯwoSHw_|79Kt.=r6c7p T'<Ī7AkϸYC'\,-jMĤőrd"!Q1$oR.&0I( W?,I԰5R/1C-RD',?qK1 FdN2;܏U[7H* S,4=U9*$pMn@1̰NM5C|M,ĪduMEMt*O[I|PqJ|Kp%`@o?j#!;%%H\cn tPnqmr= wP`E248:>#]0V޸98bwEUĖZhmaDJH_e~0΄WOXi &a6VeCCJ¡7(%Vla|P@*#/F7,F  _`dl!`NxxdB;.,#v9qZXX ! :V"v /\ ?ÊጁH_Ƚ~~ Cp pv  %F W*&V|D!bBA귇`p@`;!B$=HVx@-bIn@ +D! x(R$# B@@[X1fMJ:F ; bW` +@ ]Ԭ zKp4>dsո Hx;\ ƃ=Z"y@•܆P/#+̶X QI(Kdv$r3_yEl|(0(%\Qn&,r aghI(O ={(eH XϕDHx3!A7CuӚ'6q B0 3aB ^$wڻbh#&K?JZt.n5sEZ^G$LڃIe\ _L[Dʃ `A-T;V@Δ^*O KZe0~nAjIt%({Ȟgf6hHl$yC{ڨ@4"GWNjXbZj\qʕA~eWdKOӪj1@B_ӬDFXlTXz hō]mO{YꬨvU7\ _vm{K_ MV[TyjQ%\d̽s€ kB{/{+첉vҹF\bk?wq6;_UץE8&&9܁ vp{7C ':?st17~_c)Q{2U;MeZӯq._UGױnu+MaW{ûs wzz_~X{<{u*gfݿwk}ߵǫS>S ,A]`S8s&SF3;$:4 0z<% `$AaC3(; At @6$$AC9Tv`FuE 24BbG $E\2<` 6EZ!C+t>TLǔL˔=@| :s: @F@#ύ10OP:.Sd;-U;%!Q)aGU `F3 DtE`uFI5a(a!RG;W&T) (!;SV(AVQeTKV TLYYS,Z T?$n/ ߘ31\:S] z ^U^^Ͳ 4OݸU\ٕ\NEn!U4|o"yQD&P BPiM .v -cBDt@0.fy1 D "gwf1b1 gB gr /6L1 Q .g`D@ `jE`jj2iUm ԴALOO4v@SUo?LװspLb&q5HR Q1dQlq e,`eV ,kfؑqI qvQ W iՑiwqmWu\m@n."u"i.Ȇ#.64 n)f'!H"V'!fu8uH@s]u']wmwqYǢm4P)؂Aߴ{\+ tr!s r!#NrBF(G y@N `tr'tj7tVtX%&h 7N(w\6&fǢtrCX1d1Xu1\ux6oNĮJk|0F#D*kv @.6 \pXp'pr V!uR(F b @yQ+w 1[Ay*K7qyiVA_w@vz V~abn6o񴼆d_%R5y7[ٜ+y12Y{+P:v# {61Mut+jy@$%c񯒒^'_y,b _׹NZ>Om-*:c^)v;9sG^q'7wZpTqv.xwCb!!Pg"1xbvC@Wu'Qq ff%y1Z)e 2 v99!3o0b|so-`Z+^izm?a ;lwYZ@[^(eڰ8A7.95e-/;S6/v 4 8,iiU $ Җ[蜻Zo0Y[ebG,d\5wO {Z *ZsI@rB{_`u zjzu`|'`)eGf z%xqr5;չ9. ";o2Ins,iVr,0 pq_A(e{|]2)qW|i|+q \Msw1 <|0 {<ǣ@k M`oŅ3-\ܞWѫl#^GƱ>9mm%ɂr%wB H` V5 Ass?!\W֟Aw`j_}(bՀji:>v`@Ys!ʱ fB` t{Ѩa}@ = !G=떎;9=]B =&5O5@ ػ% H-C@{W<:G@MeC rcQ VC@,>4 b #&myx{e&I -e-O;A!W#ө^_\3Tռ>'2Ϟ)W Q}+tO Np zg!i44@c¯!)cMq [:RyC>>їa v! V !1P!Otk]v(+_1P  :y "% ?rI߇q!΋m$`P l8 /X1ƍ;z2ȑ$K)ʕ,[s¥̙4kڜ ر<7{ 4СDm C&t aA RqT N5bXRVu ;$` .YL.x\l >8Ō;~ 9|Al,`qkiZR ޸cJUVDv[hK$L9̛;=:s˘5S4USϖ6v{VnJW+Ĕ|Sd9VW ?wT=aJE` .`@WUGov7Zp}8Zjv"jqǕl])e4@݊bqg:c>dA]Tbxpڅ 'ezJf+hY~2'LY&@\&($B`کe'f}zꥠzzh(BJ餖>zJi))jjZꪮ knf%^ ;^uaahXzRǙ39q8(?f nN+oKogo+ +1x0CÛ1k7Lr [qf9(@.∑X2 C";- %5mӶqXϫ}'bjf5| qf*lrS1ڗ=|M'My]sV|7{~;^]nKy#9{n6b@^}%~xˎld95E]1ΈЕJS?G=뫟}O}_?oog@YS?awш8h#Yz!pN3R* wِՌ F3La*q8$ܡDO`(i1iSb#iP!Laa'Mc86q-#(š!b G< RR )BGFҍ%),>zx \ RkgE2<^#1IGF2?K"ߨB[Аdc/e_ e-Gc0w )SN|1MָjtڶoS[\ʌ2-]f*i"󑽬&XfN&>gI" Ќg0dWv6yi<7- j4]JɧS3,)QsL". 9I\g"iArHOBxLbƲRSXtR H4uXhG/@u&ZqMjf[AuU ׆x|#wU;M?hW׭{?LDJJ5/")N$E*n1_X0kc;f1dC.2 #ͻ/]v("`tiT%9ՊT 'i{R͎D;89Έ=) aNN,)eقT0J%zr^%y`2GڪZV _Ӥ//ZZ4ϕp@Sf'*/L䁹|R֯4U&[FMJ$˱3A_JMy=+ԭ^L=gE~"|Z3ώ;?jK뎲Zt绢ַJC<3We~wOOp7ýmTS\li}hԂ=>VU*wuc0-?s(, "x/O&CS'Awo=D`XA σa>+lg|~!([#Vhp{TR ЗpVy@>RhuEF&rGG,'oq~1x[sD᳂ d}тq+P4LGg?C4٤tvDhC_4PVp P  <gqtQ z@~B 4` TA'p 0<@0yQ3w5vfTfHsm9'kflFe#x-ZiLf'so؈sȁXRiܶq^j^ak2HI{U3ht>MQCpo ERe$7w¦RC(uhHl%ps+9lI#wlh'7wHmg6U5bP5Ȏ8HÏ혎9X( yib!pxx6jՈgfxx YTSwWhqP]E]QRsmVPAoW`q@EɓJIU2ƄxngXn[ȉ.)%1ilaYs8W rOE^~V`$lnhuilYf&&NxQ_IF#t%ȍhWBhpxza:EDE*I3ƘԄ9aّɕٓ|H`~#ƙy^n)9IۉCȇ Z Dwřig)除kur/ ȟ捷{85Y䶒\Grmt(i Ɜv%9_,):atFwIOYfysd_C/z@zI)©֢颴I: Z^7y L,Z=jJ&*gqyz|~ *ڧJjꨋ *ʨJj꩛ *ʩJjꪫ *ʪJ꫿ЫJZɊʬ*J*.؊ڭߪʭj犮j65` 0jZ5.j5 ڰ ۰k˱!#k&%n/.2K,[.39. >K00BD[DnKKKM0S˴U+U۴Y lp\˵M[XelPhj۶l˶lqpJ wl[xශ+J@k[J ˸+ 븗˹ ᐺp { p [) )N@ ;N{{˛ ۼPԛՋԫ[߫KK绾[ K[r@+ '7m+,1 JFm?B = >F|BNT֎Pʀߡ0 >^;?~޿n=!++M.$ %,l.,o7~5J@.P)+X W_,[<8?@ 7 `')P[1'A~ɫ_'x|у_CAP& AB̟ǻIφka 7sW۱sDo~Sx%2bx'zXrOKR8Fb![_٢D+Y;&1g_GCN~wV)f6:^<y|bP)߉ÊG׵AIwӂta:8&6C D 60'j%iv\EOH gguӸ.Sm5ntmp u+C:X8-d4]4m pق=(*bywt?ЉEG:ԣ.Dӱo]z>T_չ^v]hzڿvvܽ^\|t~?:oG_.yx{x WE_yk>|^,G=\D0R{>ķǞ,9/6=~'d~Om{a'H0#܋ßh!T? @>>LZ R۾>==z* !>k{6m,b9k1 ˹L #K%8-CH{Eҭ -.r+Bi#0rY3+6Y6AB 8kۭB& ðl,e+-Rڸ>7|ƒ+4A6!$9+ Ë9jKA!4DHN+DI6S%FB8;68>*ś44t4:8F#L'QZ& ^كef]eybWEX. g'!h ,H$"N 8/ AHZ@ )cp%Pс؁7hh30KUhDֽd=#j֌Dh_jjfgjhhn6=pn/'/+*Fp!%>wή!p221/ ETЃ͹ꖭcKV]Oktc~heV Rtuhfݞm8lkE7(hܧX@/+ 2xXK>2wvz,nHЃ( Xp(FFBNh^ndN`V vf~W8VK^ݪvp,aLV=Y&z59 6pN..fb5}>p܆m>d qd~ ggL"`^E#67g|M0a^@[hF/adff5_6Pf6>'?^nAG]B-SNME3HN='b6~#t5St:s74?Wnfno&ιV$a[6wsn&sJ p^.vZR(guArM`\o) wZYt%:t]d5tQWwRt$v QwjtVoW.awWτ`/FmpgcdewnmPp\e/u4wVE*A~a1GyGot7&y{t}r۶x x|}whٓmnu\ymW㙿y /zaɽxugvb%h;jss?Zzzl'xWx{ WOtDxu~{Gu܊x7z|`W>E8r/%bO:v6x! 3h/m 2@~"̾fp! L3F  (im> :؁*E3=؁9TH&&!G~`ǎ!i0\BgXR#F$EM (H KDr#Ȏ"Mތ3H=?SF"Mi(~`P qP#Obea!гK%IIR #20bHCZ={sC,KءhH^J;ACC 26w,$!+&YY20fk[ !BGo!w^`Kb=8R)b3| `!>|πދwх/ NpS-I:@ԥ[rjy9! xP _ ]luFgep't ]Hኈi$REaK-h M_h!tQ,_r< F2-y`DzŽp@DEC<65}@]WXQFf9$Rl_  ep;# }y_eӤBqW^I.*q|rQ @QM=eU pU4A|wfo aw%yLKdK;(d ^̲^^  8- V"$$!@d$4(9CXdS\i518&a #dBxlfP: s֬f8ݘHc+X7X)7 PQm!VT Kbq48OX/b#C ΰ6ZI $B"! rD`L< 0l#Q!$@ z7)}Ԓ1'A ̡h6J'̓~7*^Vd.ou\~HB0 3JSNe*՛91*59)XBX< % @b<=U mJP*w33x@&kOQT5Px 4=*kTJMn+hO&TRϴ(E_U}JORRg@JljKe*2 ֖O A H  `J!T$`! ڕ ҉H5{"Ty_զa9(|IJ&Q5J3,KTʯ,iG{XJ=/%S ?j괴h3'˾*v.l[JUY|Bْ'5kR.'ji'͞׼M/{‚}]<>喩Y \6l [6w3SEmpP+<Η}0g \j-mJ7hGUmW!>qXw://[Gx1["WVº]r;'L^/˛Rn<['2)g^o_kSg )ҥW'ն2<*/qN4]1GعfxLg]7}a~2PJ2`iӔWYla*<1@rsɪГ5#-j<Ә~6Zmfz}]F0﫵,ъF_4G^hS0c{=_=gc(_!mM_OV'Gok~7vGmox/=sw8z3ks|PV>[/gNހ:W_⻞]%_ٝM"؉إU 1`Y\i_Uo%) 损^R߻[Ҡ ` ]%%`N_ 1^׹^ J!`NFܙ^ašcq `V^!"6Am\ s!;; nb"a M b(!(ݙ:bR =ʵb#"+š`uEX&j"):`֢b2r6a)B jJ!"B a"&JZ6[݈YFbp1c`' ": 8bZ5RaCV!40.bQ.!$G ay^Ercqy%:1J?4DAbBFb.dFfcNR Z(&bA$9z$D$Sa["cq!6> Lnb d$T42$%Ybd۹!L$mOZ7\92R%_fW]b[X:#ɤP.dQ+-FI%yf]*eQj$,֡af&OR$DB%#[FC#dIfJFcE9f]@~kUf`58ez`_r$`p" ^2`$f"c gu>ue,Fn^4bd^j$p v'nڧuguƧ&i7G&ggmdJe}1$ze<%fT(N_i%^fh芲hhzChhh @/2ͣ=IP3'IN"J,E6%~F!~h$c隲i雾 ) lD%dN "]o^Z6 (HT–,B%@B̏|L72{6%R>fijʪST{&䟶,[W2cLFiP@@* 菂$  B,8Df\_fe:ā:7\I& L@@X@\ *.Ee#YjT q%HPlP^=Kl"UkvĒjuĪ hE ̫| h4UʀA:5mӦQ,N@$l\h@LJ@`mm&A EԒ@\ܒ1 -ljmپj B.*+\a) \^'rη@| G9bgr.~z)ڕΒѾ-k8Ā+ 4QH$S|m å , &zooQ- ,߆ʥo0 H@<.&l pNM|TAU 'tcFWZCGlF  0 -ӎΖHZ2mDW0N&`LA1E[5N20J#-0 ;Uv>'*kFnfa0sgs&j2 J!X r"+2Ie 5R,1Ҭfb@ZŦZe((׬uۓ"r+ZZΙpj"+{rrh:\1#p:gvDJP P3K34S4[s5c5ks6s6{s77s88s99s::ks43?o2S#B%nsgJrbK#xD$vxH/$v(80tvtS#|$lB#$6x\wv$Pwe@(4bw2$$8(T&\Az#6l‚Owb#Sx[chA5=i)ͦսu©s;k*_bsC'6!\&4C98/&4/\Pw#@}C2wt|G(A6l3l38\Tb;A((l˜#o`879d7wy4Övu3sm=ǸW>K:_gۤytAetk4sw/yz{@5`8èK'Bebw;%xo2{2zK9pgm[Bx"mr;1hs>`x/v ĻbgGgC;3;;Agvb@bygub;<'6ÇxGP{{ǫ`^-'WǦ<2[:%\μ,L-)< =|}'3/OO$.LK=[=sOB֫-w}=A_6}.=0LܟO=}}} $0}~#7~W=0_>g~o)tc;>s>'| kXB)\nwg]=D-+r!!A"[?f+st5Af˟s7p_,?_  @X`AWh8XP"b,8A1fԸcG%6@L0ʕ-[4YeJ\R̔;|'L.e9( ;$@$ ˮHmeX^ dӓB5*4)M]yIV޼}!6 Ӧ3M3;(Ђ,M u N9/!.A UԐ ).Z\Es O%H RQ%ylGaDUISAdtEfX[ZR[m-Z#( #j¡X4 v@͂d 7s%W}8! 0h { dx|+"v_e#5$ w0 :c&>as?(oԟ.peQMY` W]2ENF}ةj2@Puln&ٻ*ق!~:Q,‹!T rn_ ')5 0 s7A}}`iPYgũu5+UnW%@i:N $n @|_?=tB (C=cm8/ .t\y;h ABL$bBpH-\`ЮD'JV4QPq-A V8p }h |lж9($: &G x;'"b< DO෿npB!dCe m=x}BgUPH $)nH ;BV OY4ЊX4Un;!PkZ tXa([z@2 I,=80MTz`+,@$/S!#HҶ@{Q%vL 4 Цy%Id$v.5dl <ư d;W@.` _;Wg6 XAP'fpEeNa%<TVڝ]T "u4)]p+2ܡѾDWI\@]'* Y:,_\RIѥD]Gi׮Hid$LTbO @ڈ\/$rӟ+E_ɶqU"'d`D0Q1 `?HaA#vLa=jN#$(ZRHCA.<@IH')`$0-`cJ!*X)~Mx,j}C 0VG; e7&1OV"hD,lkd]v` ~Ę,ːK^Nټwgh#\Qu6:+@ôhBMZO &=FSC@5F P:hO#"Pt8P. ꖮȼ ۬Lb*^Ж |0DH`Q-afjJ "`0:c06>r` BI̠ k `υ 3 J H "<81N0 I >F 0d"9#LE = q Q"%1ςѮ.oG DmqWMHqx~AElT&" eZK#^ ΃@Tglh̜rsAqtFqV])Z1Cq"&C`^2]Pp&=h<^<:@!i'B=^ @1FB*udq[,"U2ıY `PJг0@&[L& d('P^btN Y Ed$#dpѣ'?Qr&[/. ]P.gRd  JV##Ω"l/VR.%o\N8!OL£_DJf?䳮d<3% N#Djն!3O:*3 bS:*ec j=le^>.ÊJ EټHL23 nC<%76:.&W L30NN6YK5; PCe6G7hsA>=HSd3;29CHT/K#@0_1wDQ5 %sT0"et# Rڔj#S_Tк%Fi4JrH/Iu0/;K+E00Jm1zC3V-D#= AT"d@"e8B<@F: 3ŬjјOItP}0 %!>%A,GSam0Rv ;}: # = ^;PS$Yp] VbIq^AlUf,_c*kjDLFʄiW@8<гdXóD!4<@@6l/oB/Be5c ht.HԌLq^4^WPtV%Voh#,8gr b΅ 2ar r1*7r_!t&u5WϺn30Kr t9GvCWs W1Owf3ҨB1hTE#F|6:1xq"ϱI*qo[f]pqQaRwzj4n"WT7#v#7#|Ihx{ |s:fUyIfq׵. `>c 3Ce7:s6Py+Kw|7gD| D?8Q6ko2n 0 "`5Yc3XO!~/ 5~\{,at+|Ey ķ 6'ܨ}ԶWv G]^飞^곞5^Þ^Ӟ쥝;}~  HJ$~/ķ[pձZd>7$\0QTNRP~ۜݼ\G=iO]%'^?Ew?AuMgK?gS_ܹ??@3(eP̙%\?ڭ]Q˚. L H&|1@ 8tq8D5bXQǎ#QܨbƓ [^\ҥɚ.?XD9Ul3hLixS&ФCI2iH= UҗU* ֩ب1"=땬ZDA,9h rmJqѲqnIqpJ:.(T`@, YB ohC> bD" H<$6qN"*J]/]:GFRh<FXP5Z.$6б1d QNo,^7B p;dY,$B2$'IJZ̤&7Nz %(S |^ 핮,@\D:;:i?R}b|@23~|3GEDh̦6nz9)wUr\8ְvRˌf5GJs9L=3&ĝ Bc/WMxD'  \9rΜgH[L]2dS5|Rz@bh<7͂Adz%#o|jȂJs} 5H5_$EծzX9(%gĺHsi;Sϗ;HJ':ꓜ$Pʿ|(kn>+' #<*2* VP5me[MWVfӫrq5W4N[97MfxQ B. `>`DU/>EA*ưd ŭL`Y0 h ƬYFuZmKszN؟ħ^ц0R# pG_W6C((\0]M7NwmjL&Cu^ ![VOV2kD.iKzjPv&^ R:/ X}"M{ˠOiF &P@Hi(+L`3MmX[֖ǗO~K뤉Uy^s3;f 302ㆇl,QG^Qմ~ jNGHCsn#6-rFu[nw-zVE'Pñp:tu1<\4ϙKW5ĕܬm?iiihSS~?;&A߀hzwu}vf137La.Lz8t* >BMҗ{%Kݙᵂn#RQ2b$W-!4'+s]M|U9$׮{~˙or˩;x5T bJw9ǖX#<]]䴻]夷U{mGGuq=A?zŻ48?XuSqN󿂯QBKv['WEl­=}~Kٍeٳ}\k=LC6O~Q|wOg}zzهvv6(]G;baǁζWu&zWK|'!Hv{%uL u5Xez>(#vm4z3h8g\wWhE{`CO{4PxŕZ&#VfRx|7P~slxz-}}F8vgv_:X}}HPWU؁yhƇ}{.&7S;^Hu*x?膠Zl|bW.X']xSffhhkMmfqHxXĨ!GwvKsPYpkטظ؍޸(x鈎츎؎GsX|]ȏ0>Xa37op=P t~j1WQ0_| t =(!< `#(# (’'0")(#23B*“&3YB9":"@)CI=9uy׀SiTIk/HlLU:`=e lj`P fIjaKaekSᗀ9zɗ}A=@KS w`w pqtIYe th`Br8yrX,s'Zr}2ϓdE06<79YȮp y<oP [PV oseiyo@ yСEo)T'St*IP2>q@z7zT&Z)Q1zlY7; =ZQABu4"R6|J4p쉘Bsh>qYtAЄ)I+hC\ȉ Z7h %  I 404P{[A4@`! /[DYDJ]]1[Х [0 } >- +)+W_I:3MXvq;=WjI)+P a w@' @;Z4` BCKjPE:uj:St ."EMݒ }="GI+B%b"$+J$W*|uhum|9=~φqJɑȤH`:3UY%W=)qUm@ 3a W[֐Rֈ@@=ϲ<-ιV7|˨LGͅOLflJlR[DŽ]KN% N-,5rƹ_]Nlئ=Ӏ|q=RܸDzy׏=Ɏ ǹˤw<ƀ2.k=}l4 [[݂}a6ݱieɛ]}Ρ,cBw,}}Uۤ&DT>ʘ}:9,Ԁ=>9-ULjhYE}#,lmǪƳݝWYiNu ǺŽH #|~Ό}K.8W(W|MqbX5mMز׉峬JEޝX?~asN 7x沊U־vg rߩk><ѿ -1ף nw|E`y` hg6zUH`u B衄R!h'B`i!H(c2hb8ƨ#;>$N [-d|]Fdqaɷ$hY߅ ft\ibz\QNiguW{Ry:(w(>G<餒VJ饖fڀӧ*ꨤjꩨꪬ꫰*무j뭸+D ub^>+-:Kf-j[m~+.zK.[n+/kk/ǶF!_i`k 7L C̰GlwKa1*($=!@G^^S=err45isͼImDmH'L7PG-Kl& {m,"#ٵTF1'@T XK1$<- gQ v,Z`SQ$x,0&zIr2G8Mh.X2ƤFL)JWzҖԥ,}LcJSt7E C3NÝi$cP\0{5?'H9NO-GyuP >zu+$6&kRZdFZJWR+G "纬tt&펫*~Ȧ^vK!ljhf0̙tbfbYjDQ0}tiӶuiQ[;0Q:_IPfuq`@<){ 2WYid"y#ìCub-aB8V 8ԥjo]wu\eG9V>=w{ǗdAƬT*²LpzYXCtq"|a:SKTik[B-^((:`٬G9IP_4pŊX XQF+NokSʒ_IɇS/ 8S9X V6a;mITs0˄ϚrcfvVqK,uk^<*Cqz ة\SF$?m\?*~z /uj2h|$ˎ8M}5b" ψ/Fy\V#OXwB])8SQSf FOm4rJNR$ek3X7*nڝ}+)&[ (Hn۸W>\'F4qpIޛIݚ{3., zM-sk}5)`+]K5B_1ijHg`M5bl?Nu_8:[VWo^Kcf8<EҠxiWӝZڐR!Y#:Ul˫$uًb% {=z0Z4&_gT🣶3smEξG "iE!%ĸ.z:};+i^^Շew.Ɠ0,|<]gSpm$V~D^]7aҕBEKv2EXQuCDBUlmfau"X#xѷK&T(6s\Q]$deaN7Tiݥ $|wQAQKBjVZ\A\b-J(k{F$(6gcP$.-$3EB4#;7x@(9ėQ-jRBP`ghZyHYeXHg^Ilz8䗃QunHWHvW!ݲacHuj،8X֨?uڸ؍ȌhgYҖtxaHǎ؎x8T|<3C1eCUFMW19i  Y  ّ@P&y(p0}p294Y2 q>@铙DYDy=P24H>WJNPO 8P H^NW ph fЖm@堒xg@i|.I/I`P`i  iL`17U18p Niqc8UeE-ϸ>SLR9WSH—J$\VuR83勹Rʅi_v3|g!霪I<%?E 4SpЙ V qn7Z zCT98Ğ AuRC]gxL%j9XI.{x;bXj"}(!D,xUsxl|聰p-& )024:6Z8z:<>ڣ@BD:FZHzJLNڤPRT:VZʏ纮ʮ Zzʯh1gjq%#Pw7Fqx6yIQYoY&G7ys2~\ z%{&-˲XqM44[66:[/7j84$jT#DŽFR0ߡ57{X3)ױ೐D%ᚫU$HX|ye2y8ȁ ڊ0ƺ|۷jE`@t{~ćB(RPHtEW< 7s }qtU(Hj(<tvE^vEz|&HdPt6ZoX@Q¹hjj%q8;[{؛ &c55[,X7*pV7CqM&`oSo8[MC`vת2Wh2W%CH;DI'I5 $N>)5y+6; 8t#ۤ2x_k䙼 -u cG幙{xu HZLH+C3ZZ/b7npNydV"yV%&~+sYPlikc:??H@헨Z( ) U!۶:HmJ h^r0[7FV\ͻ[~:wˀT.n<ைkw!?YaFpaph?j/lOkmfoot/i7tngOrq~_lspqn?/v:|O/___O?jO 5-\'~>w[j/1uz-t$J1YS/?_O@ ik9l$IY}/*4DSue[x5aom< PxD&Kf<yRhkR EcQV, m>،Vt8xpbpxx`h$d,8 ty”| <88$(p`)yp8!u&9&:!Rq >2B ":[SChHPS0 MoWGsONBBTG rAA!$`!R Vv +֯b8YLLTp4Ҧ]SF ɵmE*-\0M~E*>2Zu݀ j1 ̪3 "$>*Wo70K喛:Jbƍ082P';XfΝ= :jխv}5ٴU-۵c[uN4p` pLt=oCCK-=Nl;ӮAG@H 7i`zj# ``zq +xI'SӣBCC7\>8 |OaS[D3t>6U.HܳloCvM34Q6dEJ?RQ3Es4FQɠrHB#<+0@7H%+=լ-$ ?uSM[0>LYSOG/wS5[ m~5G]E03ỳ]Ճm {0hd&{.lfm^{n{oo~&BjMQĵʯPG%*RT.UfLjT:UhLizGƒg8S=[NMnԢUnm*\V‹ Bj^Wկ,Ǡ'3xEzZEӠUvg+& NWp6QVbΒ`a ִƵ\ֶۚmnu\HVAh6Au,VgViIdU_3{zJNmw;^׼쫄{1~M.о*ٵW>PU64t/(6nC q]{\FTXUmQ=$>ʊ]*}x[u?1ao<}+J=Ne~:ic0IM-[߁Lb-\/Ժf59og:_35BuhHk| mhX䤲zJt"]~ e*Ki Ybkbm1eΤ6O5CUmjVVvuadQ^9 2wS"bizT=_9YkhηU)C>VFͰPܨ7EszuM.rW%G gWyE4Z,rg\W]WCZm"&֔㵎 O#fF8G-NEyoU:UPKv'>jkrq'_mPUV~zԥNŇct&EZN]cHo=~+]*Wt>,YI,B6z/"p5;!.̲"0@<OdDP`@q89矨 Hп^IS7>ĹR!Ŏ7Xa;aydAdVlt#.n>*[\Vo<]fkOdU_ǓD[&ICp\܃@;z(=:> Cz5 ۳Xi z/k3])<)K5>z@ :RKcYA["A!D+"8Ki6ҩ½[ɘ:?ʠq1hr89|:C;;AB C$DDC"هFGt'?@*+>ӣR:<2k%=6C4c˲1jAmΙ/>Z<']EőabEbG6[۠C;? +.{z||>~|G{ȂvCǃ(ALDFASQ9{{{ӮLy*s8K9.|[21hrȟå/b[8$ɜIAltGlc6yV:>.[7[nLb*F7T*gJƣž#C7SaI{.ZKIIl(Se#)()`O,6cɠas6S;CJ;I' l[zKQmK,GSAѴx1a# ,)lBt2zLET,B& &,<@S9:4EdoFDEΉKDLNJ͈Klf$k)Aʪ!ȮLOdOL4CC>c"SL * EC[urTP"ѡ21^M&yuma?Қ]2$=n^!Zj]~:a@::d ȞHәC JCY5>M\WzK<67`OiyxfTTuhDe u=.y `?8xeT8a#yi}&bg4 e! a1G^v8a g 7piQy`FDb&k=[LkIҌ1\FW/J5R幽ƾMӛ#8sR89(`)KSE&eý\c- NeٙI!R2Jm#[Y[od454g˷̀k7ZK-TXO&U"Q039scNFQOKrK,,˾̈́EyR8}&XF&,c=[l.UgU3X>˚)uw40)2YRNhJa;`Hk:`# WDSElRZٴe;7VL0anj'kΏM]d1 Wjp^X³Alp׆FڒKAkNf5;3W|Kw2RAHSM%X\N,2?c=^| A-rPj%kD0ɥM|)elLnP ;KtfWlgVJ'l1ʚ;GZ[pjqC[3AԅMHcqUG4Y[O;mFbF>ۦn2eour~sRZsX>1:uBnںU̶ljYdC0\f{F+*,5FΛ5y8Zs+딎z7zXzFB%RbwzozTBѩzzކzC'pNG1G(oWN){Z/#iQ%CL'W7|GwƇ|Ɨǟȧ˷̯|}> 7G}ch؉"ڷ}P + ~oHG HXp~@~p~~~( Y_~pGOǁO׏h}~ ~8E\&mTcy±@@N\6~# y-%4G”r[/8,3:^ `-{~>ߏ!b"㢄cD%䥤EBg@ *KEˀA)RC Órs04\WuVVo7TV8Yy9[:\;}rb`_j%i:$D" T@u*WXZ FYw@+9FX/mF˖0eSGQm_~ⅈdu*֬l {ʣ?~ײekK BܴBO*~2ʀzxLYA#W<9.nn3ϕׄҹ,/PF TqRAgնܺvum39" sR$+Mf)aiX'uVif6_S70Rw$u]S~ UX  qbcVYPsІrRWA)6%x$hb&1 Vظė x0GEv$ʶ9fԧ Y֠Wpgb!(!rEwCd.thJm])2'uyyYQzg :hg(w `ba*^z)rj*J*i({e*z+(ui'[,,>/X+ZڊE -_VE~.+`vJ|ɫK+{ ; g b..V1.2|I˭ S􁶅 @-q[.D: lk_{4On!k|k+l1^=+/)v)'}v()vAPtgMAt @y-8K;5KGoܴ.|ׯn}[5Z<}',o7M{'|;t7;Ik +qaNj2{B'b2#T'/7Qԝ 1>z<%G8)qh)*!-n)P*ԡF=*RT@Nz*ըRuV*Vլk^W ֱd=Y*'|k:J^`](Wu}k]EGda[ؿ&},^ _-Y*v,VF>AƎ|4-jW:S+-BaӪ6n(mD޶mjg\fqc W].t޶{vX4_k-]Z7.U[*=/|;^7C^z!Zn/K^AD;w>`B')L .0{av] N'6&0:l 0[ 6µ.e_Br.ٸc& Mn7/rNyDre,X+enO!oDUFO6\1^$]+7Y|ᜡb>y{vEq+hSiϮ=6Uu2S]O߹+䣕mYǚ#Pu9򕟼3KAϓ>SՋwaכ)Q>y~{_/>|/|O_ͯ>}O`g8VG}4?=w~oJǟw׿_ `_  ^kE^Z zf`n ` `|E2m3uJY&a!*9!>aNVa^!J AN]S 5 .*`!a!a!!ޡ!a vaMಽNRa"Za*b#2#F"$N"V#Z" > D4"*^*+*b++",΢-".Zpb'.GX6z!ٴ%$b"%jb 3>#4F4 `/b*X-P(<Q@:ʡ:a&yd#=֣=#>q \ >~!ZXylt-TH zDx\dz(xvl$ܠI J֠J,B<,%]I#D6יU`#;cHY^&fff>vH,Zr#I][vA[8(PZډ8jNͤ%PW*#o^Ԃfp'Ѥ,Mdvh O<)х khO=b-UKy'z&(|fN4ge<w* 7%8)[ߜ&X"'z&^fk{&5R.vmzccdaǴ䂮(dT[5:fHh>'BRi趕HgSK!H۫YH͗Jdc?>@iD)NJ)Vi^v)~閆))#:q_,h')JU|(h?P$ѕI>  ( i)E*NVH:Rfwj*~'TVj)Q贍}~ԍ*™aWf{( ]#ܱ2+6Iz=+"+(jm#3ӟΊwYR"g%e $YSʈK+:NkV.+&,R 0dOz+.}V}ŖIU $]cxv¶ DqdإX,l,lM'&$t~EV9?)Xh~i&xhkW,tE5Wigھ-m1jъ $^1AY( NJ8*B풥,A2)ӞfkUj6.X-un.~unPZ* bt=yP7NVcY<֧l&:@BoRZPG=^ E/RVf$o1&.1}nަҪ~ͺoj~u⩮.lّk/mp۩1+0i멁mPȚR&bn%}Wm  0 p0p0 1q30##W?1GqSmStxvvX o-ڬfpmׂc+y /Ry h2!;J8:f`cARlT^1~F^ )lyPErٶo%r!,W0lbj{>B!' @G Q:"[5T9ާ8!/ьՈ% 4eñYsD\H;N3-hʼn.on*㚳$Ol* Q(`` ,1׉%`eS^v+&jt/3#} p$1@)==ssPHgL=í8\t =+@kfA; .,B*G0kcDW2ـ‹b 8PZ3F*dDV($2F1)j.[%ual4[ņmOM49>c\`ܳsd7܋>@?>?6@3eB$PUcfA .q( H^$ 'hvɥcZv=y-em'hg> 80@t`lwSCbt)dSM7Shv{gkviD@ Dn $6ĝ1[IΑOGsVj/aӬUu17C4_?WWlp 'Rr7iiz!፫'5/jVhڸ0xyx7yfl.,ux68䷵/uhI׽,Y89-NّeBԹ9繞997 [R˼R/$cvZI9'KaQ)Zz)YDV*z::ϺN4TylLjc6t@2>8wVgflkYDXwWv{};V{;2{C63 eF,O ;w%$IͺRKkw,+}}No 9_ι09>~,/u/NZG7Z]z#qp{my+wZ(*e)C7)?*ϸv'D~YϸWbk葢O\AjJ*PH @LF36iSE NA+o!<S)zY*u{JqDX^.RNf4c^^ !z(q"th!afL PKvbfDh1mqgu-{}Iӆ9n/ ?KÊ_,Xh(I÷De)H23qKW@il-^^LD9>-] ՚XUX!I6W$EDgrѣzBsIVM  %Ұ: ڐv,tdqҵ4Z9AFk>N$rztMگ+( s  j-7uӧ:Ul[Ρ Ci(A F PA QI,QLQYlE?|QeqQG;{ Tp"=DR h $+R-/ S1,3LSM. 20@0jd6 `=!;D C"QC=F@TI J݂MqRNeSGCR?MUOmTWcUE AHfN:ȼ(ӓ;tMa5ʘ*Eܬ-bI"Ymk0[oX.twKJfU]:`8ƽ.ܗvXr( 1T` o@'$ <( p@x!0AS+ &lBTH" do~bExyTi./# b>~DDSM,]@ploԚ'5 8 S ú&E^paK\>N|Q"H4<0{ nۙPD S &J9GTzRbm#q -LF3YێаR"N+\Of/P7) cQd ;١|y31>OoVA.,7LFPe2\Xf6}&[ӽ$>)Q*>8QPꨢVwW瘬 0W3́U̓ 0" fE$25&V4u8lMW4:MfJÕZ,)sOlbbˠގ{@*$)Kő$5?ArZslf_UNP ̡'(p1|cl@ [m_!P1c3}`wPpH^`7 ,ÝѴ"ZvӴt$;llj1mfsdwU'Aq`c6`94^ =jaD6G$n+9 odo ͤ9p '>ER.^gg.M8/~%cwe쫘8ݝD1v DX:iL08c#);`sLChC|319n D"$m5yvd 1hto,t›^v4 әvjwvQֵfDh( O 'B@yNxvÓT*< fECY!Q+H %)BRQZ6 >6Z3<$5u&6@Zܧ?/Pґ4mmU_~IEzA!U2cZ-o.P^I 1U 13[ur:_lj'}5N!2Nuea^5爽&R;mX"SesiQ;N* zI'VHWʵ֨{@g rha^tSSQ9b} *(./cɌH}ڂ0ޮȇ $ nNTnϣ,#eo{?hP(^GUP+~Psx!MEvj/bǓfgdv|p/l$ cf̮,|, ~+2\/#iF6p }"nԯEP x -gppJ pG:ZIuo?0qBi'phf.F jxN8;.F~1rr8FG)3H61aR0cF .6x#l(P=W񸐆P𣺰3y:CPnlzbJNP# ㈆j,g.rA bWx'8 *bP qs䪱)gf" =>P$^P o@A/8/ "' igfknpz/S JO6/̨GPn[R8G,%2/ KKhh_j(S yNQ4$f0;> k? J# ~;b~/33iO J&ϭc7W 5QO nF`RT2Hpf =D)ذCM^(J!i 5A54f(@;*Z3.7rth32*sA3=g /ѡh2#pMB}1ё: sjcVC}g/\T]&s.XLj8=Q JYvRD3 sU EEtbPlEy)MOCjJLqөLIKn Ύ6SL 3ʃJ3IdU{.{L5mrY?S6t74R^U[[v_ՓRR/bes2JT2F`M1so^yRK0?!a_Xs <zh#epc4@ [u3XTC=<$# Q,LW݃daXX6oXJb"Wk=kGԋUif4n+h-Ն+@&02adċu88!cU@dG-kI_]ի 4hgMb]nARjR1@bT-7⎓h%rwqj ,ٕjݲ/[Gu0`S/k"RZc9/aBhq FU;z "" /* _-wFws7 J\P0;C\űUA hoJ~i‹:vVQR4N=CTI_&?qSf}#E}q&qptj1yS/@W xx#.4&Z(y<`#JeV1gPS[%"_B8x>}㔤S`[ɨ{qY9t osrtcI|i`r1#u)Tcu;Dz}%8WrEw__G"D0qn3SeNcЉNLC7T63p~4Zg^<;p w>=xvIOx$S9hؖ2˒Z^ ̕pB5 Rۓat҇CT͕&rZlQcYEM?K p9py9yYY9yYٟY﹠ ڜz9z:ڠ'I&ؗ]`M@:EzIMQ:UZKW^YSS_&؅mqu:yz}g:z:zqxjk@Q暵z::Z՚ך<Ӛڬ::ẫ z6@ 9ck.=[ !۱%;)Gs1۲'9+;7[=(i]SgQuab$i3j{m;q{eo۷uy{gÇQ7[;o/y*j@HQ۹;{Ż;b%9׽[)ەV])T1K{ ?u6)‡Å{-0oiCu";httrack-3.49.5/html/img/snap1_b.gif0000644000175000017500000002450714336470674013755 00000000000000GIF87a ȵfC~zn+)?6=EaLNJZI]\ Z`h\b^okwvpby{QG*\0'I"51EVHeHǏ CRLf|J b͚)N/aC1R ˚XVSLd*ͨ_z زhϪ56m۵n\t߽N}k^ N3yʘ)k93ϞC%K4ΨO6:uծcÞo립6߾I XμЛOp`سkνËOӫ_ϾJ,Чn"h`E.5ht(&HfXh- J Օ[0q!*(4h8sX@U 5p,P/82ԋ1( ,Yg.qi,e,QAp)pN7cؐsBߊo`衈&haƧ~ *i3Q@8$p NAj B(`3ı*}l*7xCj*4k&, Tqߤb-`M-@+n\LrdFm#TX@I(@/Z S,/N@2`yٲhr 8@ p&pJ;r ,U+@22*2<8s"2Qnu qs|s%7w+U@3s P\T\M2UX~U8tY3G9s=3"tx4κ<-xqG6Am'0sS20knso.C1/r ˯9s>!:&~PO'}e X)kIHXtɄJX` ^"&VX`FR*.:h ~p+ ;'% w8ֆ)ߍηWx{ ^"3|"m!H}a`~ 'Thр0FMIA\Q%T.~ '^lOGdV-Y&LQܔtHVbFi'k1iJHN' @:Y Q ($BJ"w)EY%^X#"҈L&0fb!&a*ә̼6hBF3&`Mlsl7NS2Ldb&Vt9oBYt9^/>P-i-4}`*$F'MɌ"I<4ȚC [3 { CL(>S0~cL۸8I;@"B~0?@Y-G2l6T2X?Ͳ<.Z{M(e ދ0a+F=SE%^uЈN6/h~?s37ІV73kE%O>봟' ҪVzկgMZO1ܨ62ZCv4B%hSP]TR@}a?{c{քF>8P8D^tY^rJB/Ձ꣜ҧ{y'tFD:{_ZN@=x!aSb+InDlAn$rh S:`~JODaڧL[ZJBd,dZz BjکE:eaڪ:Zzګ*4hzzƚȺڬjwhȩޚQfLG~zzJ'ךe:gj*e&h~XL8/T4k "_n7xuA4th~H;g IYeqFΧ|j0kwFo7Q;'^IJ]>+];۲`1{575aaKGH;4h{ԭP+R:29bd;f[h{jln۶prt;v[x+\TKn۵hjbmVn"r¢",+f;nַW*~;mฑ)6P*6b8l++*y"6@m,"{kS)bѤĵ xӻʻۼ7- \6oi}wKӽ:QPEm2wTiS'#6psZ-OE:{|+c2Qutq@Dw25.34uNG۾V.CaGjca^2l^ $?r >]1s\5Wxoa$A[4d`@̣؁1s,#53kÛrᴚkĊQp:ql9ǀ;ǥȠ1fSu@kuj)rTŇ&j2xj+#lSn*AtFlgqfetl`3:2ǂfV|jɤ;T},4,|'Ys|yr'f w2pKg6&wsgwҟBm@Rwq J$,0ܤDg'Z-}68:<>@=B]D}FHJLNP=R]@}|#>\`ʘ=/Ghm5`Qs _lR=(2jMPQN+җG2_)l[OѱlRB.m|n~n>=y^ꍞQ}nҨ5n,U랮 츎n͋~[Έ>ˣԎɞ]~nn>]8铑ީ^.{~en~wDBa5 / /?_O? O"_(*o,-.0?/_2oYЕB/CEeHJoTɑRVU\?` +E +(gO p?T|sx_EK`Um9XUT/ #vVBb68bcf\mi.jO*r9XO?rtyِ{ߐP~TM?/`Ekʩz$ )9 R Xn W R +ՉW"W"3X67;X\ IWi6bDSue[Ux\bC`x"@pBb,NsP02 h, , B"QWKPtH3T( 8kT8|C--@\H]muŽp (.!XFnF9y6–IZV:rjj k8(C8pj@i{3€&< ANxI4)K(hcTK<ijd+J-e/24S2=?@iP|#E7I]#ux\-Hg]=R5͙, ШaEB']lCr2DWH`(QzV`)kRRKafV3yvSϊ~#HoAvfөR=@lڱ-qmr@A# " \zS8P]dݷnMzXxŐτiY1c΢Mv}hP^pŹn- !G@@, tpB ρ'6pC?1D+BK1EWdESD=x0qv0G $R !,rG#Ldr(qtJ)RI(K.BI1L322 M-(+D:SBϴO>P?s;SPEE (dL`JHxQS?SSeuUWUX_VZo/,U?3Wv.+*^Q+`` Y v6[g[qq7\r57rE7UJ@J+ib^y}p6^P*xٷ`uۅaٝ8b/8㊷ +ؼGPx'x5իv6}b4S(څ 1ޘgwZwW3[|zh뫳zXO?:޺l;m ކ;n离n;oo⇷xvGgz1}z>zߞj?'|^|_|w>}ۧ~/'AЀD`@6Ё`%8A VЂ`)8AaE86 *TBЅ- eCІ5DR@BBw?![C&0G8E#RVt0Wb8F,K\D XF2otcΈ->1j_cG>Q s#ՈB?qDd4d$!9-$))Cv׳%EOnҔ̒1~|ym՞x ܱ=|~"q?;^wk/xߕ鑃.W ʯ{,nUz Pn)B }w?窧{)wK *ҷJo:uޡ? .\ovJnq*"i"@h,8)ʖl,&˿ ̿j֫+!w"5A#k#5;+@?@?3\g&2&!{g|>j>bA(_dDf< ¼rذ»8XG;[j Dk>&ȸz|džlz"~DGDTK2FA.$r:1G++D˸5XlZ"T'It2' Ÿ8I%98×=E`Ȇ l%ee 81IE@:Z×39üӸɪT=[I0{šdK>@=#ljC][u$5KA9k+븻ܱKgCKgEpÜ;K[I{ÊltMܨB[JT='0քה Mפ۴܌MMݬNN$4 NNԵ$ͤtDNqNlLt $/ ~NYyOl3i'3$5EUeu ]\'«3UeuQR\Kf+YM@6'()*!,8AQpOD QVq42!},vR2uS"4]"] S85S<=0e.U:%6岖 dޘ7SXQSaӢ:4A)MES_?mN'yx2|iѽޫ&9om#yȇ(ȇ+'aռE-Fe:TS;ϱ=M{sx]E= zo`?K 2\}gNU,Mm}{؂7I1{=5:Z a٣Mc"eSuYөeGDٞ7j:uq i?Py0X-UE[V]hgc}N]/ n؅YTeEs:'`Q.=RI^Q(bW=m3=dhz&5`ݕ\\Zm\ hi@a֍ZU9ې<VuM6Aɛ_G*|^xq.H{'yeW'_ͪP]*zu}BU-0)^ ِ՚k_w+1*8`ez*3Z UBu:#-EBlxBek*`*,pmf.4]!,Ω_Qbqnz`R iZQIBG12Z6uf!姅g挹Uf:7elkbnv/fqfvmZt~1Mp&vgTf#u|heڿ g|VNd.h;h1f芖ىV~V腦s猖:FF>jnfihwaVilh>qiiMegjSgjiR~hOf7qVꜦާV^ꯆŦdۣhgj>VkV`vkNk>g^Nne4h<.6Sid˖&6F{@TD뺺Rڶޜ9}mWT6l&n3^dl6~ngϖ,npjnN&.Fn%;httrack-3.49.5/html/img/snap1_a.gif0000644000175000017500000002330514336470674013747 00000000000000GIF87a-TPYd\{Roïʵνν,@PI8ͻ`(dihl@\״M;Nvh|[<6F0&G^skbwL.tpd'N>z    HZ^4C>Y?Fb]`TVebL_gjmhqqxyr}䂀胁틀󊕅0`< A0!H5P02%J@\h ׫Te4bT$(Ί*3#ѣ ]iQFe"SWjkׯ\z ,Ӥ`͊Mjٶ^ʅ*ժq=ܭ|?B7/۵cN|bňldgVkgf?[jӗSVzְY~=;6۶s.w߾ȏ+7УKN}zx?.ɝ߿{=㷟߀߁"*`2h`J( \uv:Rf%\(,.Za*8ԴW0<cDI(h8c^&rrQ) \v`Y]be a ɓO͸5a)SF`^"%`KPK*ʟ5%f-hfqdih(Nb/RFb8@*h `l(,t@Ţiѩ9blʀP{,ݮ~+vi;(b"Jە"@%`g'ZpFo'U,G1_o1lr('2/,,5Yb N;i)hJ-zHqfJ 5*j)+CvJ+?N]@ @g^uR5WY4_RBZTIk9+>w@׮ɹ[;=H(B`8 aD'JъZB8ʁHGJҒ&qb0KaJ{ĔPW+8 1х!Р 3@ SNzi*jd`=8ƁҁHG?&#aî*])J5Ή'<u񼷁EIp ^$+a]QXYa-l ?uV l e֦`(8b7yDjb(*P pEye;IM3dJte#Z fm6HxC񚷼=z}|Kڷ~L>y]6X~0$ GvN_9{ >1l%*NY.8.4H 75J$8A D!aER). (mMn!o'z3f-FwZ8lqjlEGyکG{ ;BW:Sc.ݘ)_ڌl泤I Mhח$ Iܰh:V"_$z԰FO]h&xֱF-HkrWu-bNe;f=mh_k3‹9TJt.FS"'8 ӍVD>؍**Nq#9\׳[W^+c1p@G;BKW2EKE, 0饄3#[Y\'ˊf.69w>:Ї.:oQ04$RkvQ;í}m@9VFW:aw{eXyzpܧڧ֝Krq(M>Tn#O[򘿼3{COћ'|NSj=eςݒx:[R4D&IN{y&)xn|?%߻앦q} HgPڝ{_};4~T~CQp`w<Tvw'L7}w{zWwyW{zx({ী{8M 8 `& ,؂.0284X6x8:<؃>@B8DX, Ygc'PxKhhM8VW <Cᅟ]_Hahcȅkb؆elt8v(xzxyȇ{~8HXxX}hw(Hȉ(I4 PUx `haHQcuguV8mՋVr$WW`W)0'9 XvAO >%q C5PApf 0?USOPXE`4@UTjU]5eo@he㠋oVXIɈ(E%ASS-ՎS( D))똒P h؊ZF98uI R RpVIWwuzUɕxR0o8a 1XIn ZP#UWq5 tPW0vR/e8٘9YSwqٙ I-e)陭Ia' qV_YYwp*UQ]5yEؕGwx vE[0@|(-P6B\A9ҝ$6dx1`1@YtACIvyZǜFFBG6C% :6-anP qqek *j$ң37v#]}3Cs>E?*Jwqf~?,𴢉z@:BZDzFHJڤLNzyYXXx:VXE]\:_ Xfzhjlڦnpr:tZvzxz|ڧ~v*[-'^O~~JvHbx=zz~gX*}Shk jǨᨠa:qJZbCd`6>Ѫ!;!W!Wi%~&ZMCh&\y cgq|eIe#t(guodꄏ8Zr*@ pspb([+*qg{ qgFdc+"p̲;rcgtӯd Di% &C.G4VWU>yz1uJRf+",b ,3e,g2eRI[+-"+ϡ.fp++ R Iq'k/&.+z#2+kz_gJ\%Gbjf!2!{!+Ḓ !M1ґjM{,'1J({'r{hWVX|{ki#'K>rzA˅g -K.:Q(%`c9B(Ή:7Bd eKfСqg\/%&u R 8Vk7ē ,7'+~q3*p!~'ղ? /߂f&qZe-/,+;R,-rK;/" !3Qw?BntBha^L49*ōJŶ]n25prtn@A>CD.H~JnLNE?MT.QnKWU>[\`Nph%V|0W9t^sٗy}5|I9Sn:%B PP 昞jLwoeNyx~WN.p/![.~ U\XMr XTp rNH^pVJ|0yX&uyꫮ環3!%A fRNX%yr>V^3`TxX N%=iRn Z~_Km.pP9R )wnNr _):cdYu1ᖡr0 x6`T@SSpfFTS@,yG>UX9VvQV#OVIzٗyiy` /:ˈ`QS0,=pPBa@ bRT?PP(cTEYYޔdŔ^>r.cOɗnhߕ"cr? c, .H~OhGip NeVoԎMO__i/ikgyB`ne̠_gɠ )/UPB .YgCq$KS,XYՅ5]Y~z xD&K|&sZYXmڭ~c,M vۭH<ξc D\ȣKKp;d[TLT4=EM]@dEEeUpMՍ+%%U4.Ff>>VNm'.GOW/O[[/_Ͽ7(|ChPaB}\X>*>xQEzĆ qaƑ'QrNxH^4_   RfJ-S.uʱ)T7R%֨ ~5,XbZT#@[#ΚXkwZEW4EػWm.{7^N=JR;_YthҚr~qӫGi vp\sNw'wƽy.z3k\Aol}Zy˲/VlDy>}l U,0o.S(LZg⼼~uΏZ yEN Z26IT`=6r6I_6 yr5Uc:#_\#Oy͝". W)[wȆ1z~wawD+6e%iyLlMؓFfz5e# #&ɣq?Қ{Rt>{a+"A 09= 9 ctлDo驺B̺y#AAA%Q3))*D3++,B*B/B,12B3 3T4dC0ǠC:4%ȉ5E[k yG(JA<CBTC$FDELBlDFTGIDGDHKMzH¯ /)2AW\XVWEXz8Ei?T0E[$FYa4[DF3:6C`uYcFeb[9\=>UmlLsudf^$qFr$sL{|DndGzHGvGt,vt0~M qHIȃ4ȉyUHɊɃȕHutI|ɋ~T5biɜHII {@H0&qYIɑ$@T@;OJ8~I3ɰ{J@˵3XP˺˻˼˽˾˿$4DTLIh+J(p ;l먹+u$4DTМ[5E iwp=8P Jͥt CIIl\ETN:༐L՘MVdMI:+ MqN yj3K} ^n( ,NNQ=:H "C81]%(S(4\ O*ʨÃ2A)+, JI"T9%GCu ;<,HTTT'KLN-Ԃ@TPL=W5UIUUXO\EYZ FX zU|XU;O|V]Vf* GEemk(VfV Uluqmc=V]pVquWуV vWr]syS|w}tdz{XX|MhTjeׄ؅]%ʈ׊U؏MxQtUؔ?RR EٙUWYycCQ [١׆Y %ZMYVȄقٝZe؞u oىMڮCmZZکqeZ֧Z[hXU±m۲}ۼSU[oe[۳\SKX]Wۜ۟M0\M5܍E\ɵ­Q]U[܎\[Ռ=Y֕ͅMե]I5-;hK%^5eu^ꠥ^_%5-ܽc&6F`װMԿ]mV[TݕvX}` Hs`V`_Vխ`_,6G=aaڌ;httrack-3.49.5/html/img/httrack.gif0000644000175000017500000000776514336470674014101 00000000000000GIF89aufff̙ffffff3̙ff̙f̙f3f33fff̙ffffff3ff333f33!,o dihlp,D4x|FG,BL:( \Hl2`jp4 f ໇z7} }+ wvV< 1GH(|: 0(-n'/'nm;0% ڈ( ׵ٽ#; Zc'Aqd}ݵw$G!;fܻk&/Ædh:kӽև"7谇o `JPA@P枍B'bm6E)&D] gxmYffΌ1 GR6pr0Ru[BH*380̠# Ï@@;q- [ǎ1߯7h6޲hU+ZX2lFxnknf+"ssmĀﵯve^ic<@So!D2GZ`L* |J,lXSWenɒ ^"`'c7s[$XM"cur[4A%Kbq &F-[q&#nXDsFt$-EɜY"\k Jue^U)hJ2&@91%dTMb:ka2fp"5 28Ц Ũb>?f9[/Z&epqj e9Ou-J$1(c@; Y0TUB[a g# W8gNF S,4˯N 2n%5Em]<ܤ8Š \L#@c, &]<ޒT -Ž"47=*7%2 |pyfp_# O,` s*I&Id߂G6.&1սZ--da70'Ip'!M(.CX)K޸Vs 56ePE|F%dQuL,Cf * "CKw"G I߬I#x"HC%k.~B6Y"\cG@P0ٺ W4qC "D Yӊ;̥Etز,ŀrN9xhdpJ T%FxSF =tjg9k\ 45τmn?T!MYV'Ե&tbn(+c}Zr LԂQx{Š ~c9qR}dSZed-ƃLT c NpFϡ XLw`$PPiǏA'M\{:,Sҟ\Nwy1Pɺ0GCĥ\\2=ӹt|.$K.T0>`M$!BzVh֍S*JUI`S;P;`Y؏U'`F0eߍ !Bj MRԲiSJ9.iUH7Rֽ\n;hjY #ߴJ:'sT6PtR@JXr߅2֪cb׍.Es4q5^E1$23MMYEQ䥒](, 6G/J[rٖ 5/qae*QFuy2i 7)WDZ 3~ݔ skݣ`0Zu!q[NʼA:B+kJF+%iKk6 omO<P Z4  D Ing*$Wӵh\Ʉ/c6?,@@pbĵGĈ¨h5N.IU\Z@dJ/x*_`pSΞx|+Vh9A@,B1rT!Y]CXpƥLr+'8gR.0O7&k_c sH9u BB'o+0袽y9;L ,5&Ƥw' }0Rsx!=萚H: .o\xW6Z[jA|N'x䵛 ]Dʐ>'ubNq 'mOW=͘K\(u)66n&HgUq8{wwFޣ(h)kwZ^YfvGEd-t69q!3X2=eX"7%Habwa#WSL`f[?pAO@Gpsy$GpNB`F1#d3g~XW3he A",]Z%Ne[(?/&$s٠ fb$m YsF&^ .GT2{:Cif>ns=Z?oS! CVdWN#~*2BUa+PqqB=>Uh#P$gz@E>pqTe$EwgPInBq+f-Op Nwvt|U%q$k#!/0c~$"2:M ׀ F7{eu`g]bix$[w H*6}E_7nH ꃏAȊQǃ8 6 @H* Q;h"B`LPPf0llieQ($2d  Hgt-i&i+E,>iiTv|`AxB1-g  I sG(PNqx<8Q#)ue:g83 )L&Nc ГcPVpCՆy@O3==Q1quK>!*ryXH  *hr8:#HPc)_ q%OK.UB6k:HTpOH{*.yVЧPF$f7W'2O OBD$Lع8־qrѕ6Jeٲb 4!ҫ2a ϞG,iIlOj Q4ɂ(eU8A5s􇆏LXUFIh+f &` B j R&6" ZhtUd/>ɆY> l @<+`2 " |L( lZ )#ݐǠ&TSY]ETamFM8x%]QȷR]S; ʃ!>!o5l(HT RGZ/θ3!`+PrBEȔIDPJqfBuM14!PxzHJ !QW$9Q.E{rR]=Cύ fyq&Ki %o &7PD:|Α''+H TU%! H[|kAÊ51P^0DI2e FS0w$biK] g7Щ4TV|E%B RW6R0ÏhuQd8klcccb?4ci*THeB`L%N.#k(ҟArL"= gi ؂dHée#>73,' aD #pEǰ^9rDʋ' [(Q$u"8T쪿8qT|npmi e( W3&hS% 3ŶI 2)F7P$d81|R5mw샜dE+]LhGhY`s1A 83MmÎ ),MUOe9xـMJRCf׺?CGIъ[L; m2KqɕPbu2dEw5G`0AL&!JEXfSdJRDp)P9cЄN(Irȼ!n vH`wQg@xLA pn]׊iTRR{8B i(Q|> z]*(}h_h_QUf@N6bx%g9p;hWU~IA!@Hk㘌ǣCoڐ< >YMD"VmF ŁF*dYG1hov`aV@<1Po!i6Ll^٢á\lgo6p]. 1+^;HD״ xg@\W%k@,;=I F;h7Q+*]UC{_q֚E [È$Z9 t潋jo:= `J>6řl w3Ej) oP! >2\&W[A˛Z V)/̪&p)ԡGb?v-cɒo*!4P47sn@C9'c"M(3лX]NȐ!wXd2*4b)pt(EkLbp XgJ㊯L$p!Qdw mLQ씕kvzg9㊥AU|*-[1Sڌ+'f!bR.Ǜg-@>|8&}Lsnu#PcugddJ4$Tz 2 ¬\CR@!yؗvPuRMŸ5W6;,=-t_qXL ^rC%Dw7Q9R %HBPbP|c'ņkYe0C!ex@&zF5>4ZP3: DP5)1H<5 G/^ |TqA1xJ8Y&iYxe.w P}g2UDgU8@g@``b~*`50flqLSEt<WY{{HY&"Q Y0j?@H!"yC#0xaYyB DtB$8;7"Ui}pD<~赉;0 b`\E!3$ֆ[Uő &5QG,7OCZkg3P}I+ &'WtDA"]%v3+g'baWۣ3F G~ƕ+`p;] 2`tDI2*g0"3aa:ڷB!-unъ89z2F"'O *dC 8Np_ESQA  V1u3Ugfd7Hs3aHץaXp,X0<6]Act0Ez)!chB;BQ@CE/IqT7P7Ő/C} [*Oca]1"i%(M1^@ ؓjeQ9g" )" o:\!SHt}ma<[5N!UNP-!,#OpC=#V )qgU~\3aV;r&k\r~Q0?t]v;2sH^x Kf+"@LgW{*k[F*(U( R  BDAmQ!kUOMyLMpУ(CE3kjpw$6&~S&HkR[y"bR5,M&9ڂ(k)GZT)y|Q%<)}:PW6":3Qw=j*--@W; >AP9irZhxYSkh+;f/"XU] ?a2UId^YKDS!jU<"yʹ<z ;cرufqa"a0/%bj'e{/?CxulQ)sҲ. j"mBE)cV^;r.J[,8hٍ!??l'aC!6I+E\RpbFvmK=7_'Fc@u L, :\!F;httrack-3.49.5/html/img/addurl5.gif0000644000175000017500000002267314336470674013774 00000000000000GIF87a^PεRR)!!ssk,^P@(0I8ͻ`("A1F[(0x@ Ԃ;Szt@QVuKi] b T[Ϋ,J&  /}  (34*4HTK]>S?cdgneknpkvzzvx 6҃}ڡ0%싊10% ,Sc݂M4Pd!{ĭĮ;xJHuMr @!H4͝@e$.IE)ӧNBen\HU ¿hVնbUKWn}Yd7හGd*'1bw2(L)8XIAe Ÿ̔=w6zh҆rUZT(nۻu~wy>vrȡ?N}u؁`ËOӫ_ϾxAO>wKd7429HP'J4M& x@> `C)> n ! p`J葀ǀ"6 6aX!<2ȡwJ8H䘤BXa͛vJ?'h %vrw)WZ$<%u28!曎喫e)무j뭸*^&+,yv抠"j,6Bejx%([(&" hKپ;Jz$xg6Xc2ߙ n&ʣNj\bF,~5֫) { : ,n$W j6`Z2-6΋ HUIl핬 m᧯~߯h_>]>3 82s '7 Rw+M`R=d!QLA(LEx/X #/R!]tCN}Nf8#|nzp, &VDP!!-z/,$V Q$+{> $%TQ& GwdcC.D p pȬPnH,!6;{!8ԢL )M+^&RZ򕰌%-(b 2a0!-cPf;;1@!*Є>P,;`(׃!h `ȬshR7mysnv,B;}IK~Ÿ 3sf2cFRCU@4A?BaѼD2~裏Xp|VH%RBTH f_~Ѥ2BP\9h]z.*9Y2#c/"?8o*UT&H j׌ |,S||:ɀx(}O5*%lΐ؆F -MFΔ^pվ,ha*\5caZkB3Hr+G^Zgų"]7a[Mr2K,ob o6-_8֗|]A\#x^6Jnw-rN}Эvwz-zXuyp֮u;^<=p2.x >7ݑa֝;2joY֘3Mp m`T+Z^ CCssлxs3ϼ%Yэn3NzΣ.u{S:ݭ^77.ۺpӿ>rp6 #ZzS27jh/x#)@bw)NZCH"Gr@ 1D%cNix!AUs瑧[QME-Zbz@,%(my_Dpù Ezg}[ؿ_{)ǘB9?? x:T! HO\< dP X PȴPP$=jG x  E@rE$t(,@J'N Gq>` dOtM7`N4@;X9#NR`OӃQOP؀ 8Dh6  1w8a={E #8,B&MW 2 h@p0KY@OYNqG% ^ H LXh \hLԅL&vLr%Sq Uؔ'DH'|WPEP`؅I  X*VuEWU&A?%GHujY`1HaQ$AB)uY3%HE[%8~RaJ0hJj%XI ZR/pA8Sa0iQD'Iu4AOxTKWShTA؍ A)aZ&`:SWHvdB`dYA77SLI\d\tY%jg\xI`*y[~[9V{ɗ\I}i٘ąR%HwF fĆ*Yz/ܓ'z!Jيᘽ5)\U ?9w kG9Y)YԉgZgםπoYs9$4ܹm2tV0!*Z"_A NBdƞŸ,?Ito`cyBeM<M`($A#I}b Z *-a*g)"S9˾>3Ĝ@|̹̿,<ŌL;0TH'i )Ytm&CADh_I[9e&!{H8CQ E IYZ`$9 !5Vo0E8 {8p4(!@Gnp2GmD$*CВ`ЍTQSaģ;Izq+C{z)hD27Hq@U*8KS0=DPb817tE@yRkQ6~?V7t3Ґh/ 0RGFX|ڨڪڬژ)B,5C4$ۘڵ͹MC۾ͳ۸ λ-`ww<]O Dl58ޝ1I -h K͈VTPL\(QՉc8 WLCq84EI k|4X;Z 4KdPS8hĔ -#WLdrF#ᆏ†~Ew qD<pN:>P9w"o'1O@į#SG=W;zOP%'ME  ~6^a1B=dWDh,:tqMcN>0ȇ3275mn݈ŤP->h1/^I{򋹗1~yR6NJ؀ ?ZXqPè0~@Qo]T#YFe1|m|M8N Tmo=7u?BiT[YWW^T[CyTBAJ1tYYf&% DiY搌J ѼjůwFulr[ $t1 ~>yD8oOZJzoVy+蟣ZXHÌ̈*aFkP0h-aQa!%TbXӃ19*s& ] fFiRhilH6pzc9R/5-Pp"Asv6`f!x7b8H10&ihTYs焄bz(h(';󪕫geK '2\-M}M n=lUEMLJ=mRs[;{von ={L&?9XçbƉ*>'޶jBv cK-T3fΙYnܩsMO?%ѝC*Q<>]3W Pz ذdVڵlۺ} 7ܹt΍H^MC x`|{†E8qdƃ?8d͘7{ EF@P1{huBӕKQm˵ g{/qX7.IT7ԧ[z>zieo<>MيLg uVvܴu%+N Zu z$Rh'5j"'zxyx'[/Gգ݁;FXG1B.id2i>CeV^eZF#ɖ^~ fbIffiz@n grIgvމgzg~ hJ a(h> iNJ餇Dni~ > Lj*hJk9*kʹ_:Kui f]ҨF,Jj%;gkxZЉh i mn ՞&Bn²9"ƫּZ\poJ{r.쨺j:,giZ_&ia0 :Z9:kl<  ֢V6kp|`m%<2` g0}2k2؛lT}æLVta=,N"&e2\|'hy#ӯfwz3߽*@ϱXTHou1_vC֬{i F'yeyU;Q0dۗnAF|Yӭ Q\TM'+k[X>؅lqnWCJN$[\G]bW/BI9X1s,a<@! #[d% bl]HR<O0vJ&^Ddj)4%?<|de5JZbhJN9<1<ys,'itsd xsO蜧=p>?Yc;&Q]bS[ʇE3tp"7qNJ9w@Eqj4 ە1족ZCavҡo n)4(`%Q5.S[beSq CU|'JJ5vT,c(! k^9kk ÛV1U%j_^Fƴ/;1Ew=ae. {葌:8篖^tS#+&*fp*-谊C Ab8͂N4`=hX"0]X" 3P;ob!Z!(SLn06'ÕvUKw^y]s}&|=tg:v?[|z;ߓ/|>nc+_ K>)k߼{ϋa|aӫ_~.=oO~<{o=މ>>wg ?w_/?=#> ~?Xӯ'oe?]Ͽ2ٿ~Go~('~ ~P'H' hm~H8 D3}Hc(8 7/gDC3-~6(@(2ey X+H8R$0{LKh=`85(V-ȆWr\X7\~0؆쇇BiD#&>VȂCxHx呀K}&e1ȆT ؁pUR@0 U5X~qhj(Hh8Ȍ苷G~|H7hOG+֨5Oh+RHN ōDt}hBq{fhO1+䈏Wzsf| yyiW9yɑx)~%ix$yw+x*qג1w0Ik77Iw62=v< CtBiVIYpHɔvO9 )5UɒT;y[)ZAٕa`IG9gfMmIl ¶siNiTyhxɗO~)Naɘ阏 )IiiJ )ɚM/V\15Riqɛ雿"I"Q 9ɜ(r7Wpf * y* i9Y2 b0 /1kٟi ^\8v ڝ91>marU 5a( 8[[0[UT!I |A4 Hʤ:%v?Cb)s4' 4/5mfvQ !B; bAHg1:|0ש'#f$X$iBq RyIfp( ;6Ѥ ʡ݁A|PUIR$ iz!aj+ @= `xU7!@4! jo Q]c: 6j1- zwШq!X `0Ƞ7̀&xYjJ~~YrƪI@L ` 2v\Ar 0 $'k)[+Kݚi Հ‰"皩Vnxy*8 @)7YJP/`,;GJDICJp:5)O>`k@J (@M|S$ G/Ͽ⽛袛+ӨS;ׇ:5[5س}}m|*(؋G:7{aX_>g$iMhdWE@aHfH7"Xg矀*TG衈&袌FfF*餔`;`.T b?fnR8ۧWO;%$w5_Z,Jށȗ%!\vHtw׋HnFfVNu[G ZX9PRQ' ?4pל` w=\`O|q  7@pk()먤*_>w¬\ppXO4(UEghzZmX }HqgUY-w[@%Et6~s.TXlm37x(N >]3=r|ȚAN馧ꪷN𫠂-}WA7OEؾ@w5ڸUoqHkWÕѾl;ߨsaag&o{蝍R`UOT4kT?8S{G}h4ɠ*t//) F?s9fXٟ,c6hzt}HDHL"推&:qnL|(RM9,z@M2H0)#aJ7p1bE`q8(㏀ IBL"F:򑐌$'IJZ\d.Nz e`dC 3aː,g9?B,;?vK9߄PEPL-l]b$D5m`M"ft8NQĈ5ᝥL%1ЀVʓ@[R:j G AQ8 9 w‡?eO iD$4?wؒƻ0zXP]'GO(~ 4{`j*yX54獾ߦ+7X2͆L 4' :PԧN[XϺַ{}h3f= FOwv|nj{ܺ-D2# {$r3n= >vQD3S>8SX>TN#ocE~3jr g[g?JW,v^8(twUd JtJODOt 0 8`KK*,  ݐIK3R!U ( fTLjxؘðN(TfHJnPOO& vXPH@hQyH @rAh҈IU}ؐYB}|IяGfobEbX&6|/ .FbYQS/(eB%76vdo'Se,o'!e=)@c2U&b2UVdS5Qe{p`iU!7eE"2'8 $)gG6-e>%@|7m76Q)=MOƑ%3#bxQF7 ,ed$#s!|y!#Tr$o-\qM&}iajzVy"ig'kcy%TUG$Rv¢j2n¤k})xh(WIVnoagWSXZ2;)3_Z&Jr\HB!gv՞>B(aŹcB+asaRS%yG 6f+{6&_z[Uzo"V%5Dks7WY9SVSJ]<h]9Y]Ub)zeJhr_VG٦[->k fhR| (x*gT".ZGZZ\⪕*$z[jh2 VL-: ҷ6۱ ";$[&{(*,۲.02;4[ZsX}rѱ:!sj6]@V6F<{M&Qˤ٦l?Yc<{-aYYkaC:Yg/rx:$aVe'e eT'+m#x|S%$1YkJ6<VV;Glg44Po&<+b@n-1ܲSoL@=3GY-">xa@sCr.k܂.U9;GulҮ[B;t滾b8lJ{uG:m$n S 2W!Z%r)p/Y6䋿|t1j[¨r+խTW-6m!e "`&˨y?!(w*,rpio"Ĺ @3G5f0o?r-23N|@lW|Ʀ+X0`'ZDI,lcnZwC)۫?G񮦖Ynrp< `\ c"Oק&SdTkWa+we.*sɠ|0d|G:#lLofñ5)oŸyQcC8\DxČƜ̼ά\|Ӝ֬ؼ\AgrL\ <\|W<\Хk] F2qj?_6‚T{X2ҁT[ѱ`+&ik L0Ѱ4 ݿ{U }iǐv'~X2Q,YLR&W"Wݙ}&_%$RbI5y2ڸI"<'ϛb`!q8Y3M: 0#52==*L} ](%@m؋r4G m]{٘=ٞM:ڤM},ڪ38HP0xHOA88]LjVT(XM^NWxwy2iaHDnnNk0(UPpP.^nS [LR>5ЈrMA>nq>؀e4®OӀK~ᐾ `QP ɸ2X fNuhPcH؅pYp3 6})o^x?m^h K. Q@Q~Cɘ>Q(R(u#?f|ayA?ΰI쌎N?P8@  QZAR1u )&Rs46H\栃[Ӝ-Doج?LjE_ڒF,mzQa[B_0/[[*{ctd5trCWr!pB#r۫)}/AB%k@c=*QC*>ÂU  dL#| @lvd̑QDh-'А!Uh. `:`!>ƹ5Dԩ:ӵ|bO"vaVbxxt&2E2$QT:J*ZUչ$̀ ubz,ڵ@:`jdR<'a8ɛ~܋6zxӇe1G#^twi`" 1s6Wނa3āӃM m F LjB#$Hc1)a#"O@&6!Hd(ThdJ.1\q<#VSӕZne^~ fbIf66򈙂'"i!_igzgbIC\.SW)4hlg9G!z$Dy~j'4D?sQD;?dzцg?Gi j> m2"p$0e)xLk$bA LKg'ZtHN"m˯h։$$F6Mo /BBpOLqj"FD!4 %AbH1C(̈́IltSaV3k.Z%!,->ia1]aߖX[,^Q ҍr,`qB!q'Am/ ֶ=$|v e+ ʃbB񉧈1PB$`#N?? VYHs鈈})f$LmLa瀹bPPKӔ^_AJЁhmC Q(8Dx: hD? Ґ:t00g8P4MPv"(OСSةQ>T~{34DX%u\*H2zud-+jiִuZ*[ ׸ɭr]$u|k" v-a*vmc Jve/jv-0!;Ίv-iOԪv-흦YDkZj4YLpRo .K:Z#yU tD=I &%Gak&+R2>qNL-.UȊB>+DfcCꈾPlݍN{,!ȣ`,_EnUȇ&{XNTd OؑI;B+Iӂ-(',}ax(ԼFzza[&R]4I.#?'#"w* CoV( eJg83@uǝ#]Z{KWYiU}LVиq7N 3vLpwt?p+xotXҕN;g0?I`m ccitG%7b+c%9ڳmLے'D{[n Y xwlny{eWm{ӺKj| nE舃Vǧ'9_䡏V#IoN֖$ȗ؎J@qY2Ȣо܄DAMҁS r>qD JFZ6kI}z_D4hkN!ոI}9f2qّUq`/g~ImSv uaCNCv9R&ݟ}B/턃na ]ާ~S.kĽ0<(Ia/GpT&k\ ~(/ {}ȫ>z@$WX[v7B %w/F$.c&X$sJq:$$zs s[{uPPj=@ 洂?&-pI q"J:APSX&HDLw".F% RTHUos98mey"hoHpT5PTjW*$&Q r+-':v<<&ᇎAZ!rc\(kzb[zn͗vKzy4A2]o] Ǹ*V8z)%Hvxhu'W۸%chHtI R! 4^bC ߂cp.#j]+D9E))@fi6~nS=#6B+6biEZ9Y# ᛊ#p( :Ql VU^AxR`R©]?R6Z&6Jen6 Т9Z5j&PhRFԓKHd>#a8.5T :HA&ֹh>jGgܒlBy&H )D)u ;7taT,G:vT,#9:8\)SSu Gt5JTm4jtj)耸Mn4Lt0dMDOgZO3GfҬ*CjguٺU$* PjJKܪ: ɅJWظj [k* o\ +Kx@ɰ7׆ D*7ұ5Aszjf}}W##%q'#&j5*374q9z{Z1v,;j1 r(J_6yZO˯Q[qSMr.g #GҶǵo[y{˷}{;g+ k˸鸏k˹빟 +Kk ;httrack-3.49.5/html/img/addurl3.gif0000644000175000017500000002444114336470674013765 00000000000000GIF87aƵε99JJB,@0I8ͻ`(g(a0BEZԄp9]A}cmXl:ШtJ앰uܰm m6s}_vxz~Bx7:CBC32, //(VNhvridstofmqzoxklɎ̐ʔҔ3227o߹y;HP^zC!n2>G;U;q͡L`(MʼH]Spbz2.8rӧPJJիXj:c@35sG%-ϗgqźtT_hM cÈ+^̸j!3z)V3l7g:+8ZCm(K^ͺ֐'c9|C{5|iL8+_μУ;g'!%xoړK_ϾA*?2YK ߾<db-hgR X aT`-(Xb5ӄ1 C5c-(!}g\7:>Rh"'ΐۙ7FJn9InQi;^@v^ bzdu9iRnͣRwNR9_aFIؠ-U&}~FLf[=_ R)yednyէƺ_YIY ZEkAjC,{*hu~æ& M֝$R'Zz*Kj7F+koLMoB>٢flI,R Be)F袩ٺV\x*϶%G.spWyn^.PwA=@B}b ~s*l`#5}Kdч FDhp @UrLy^=M77y4Q 6:ՏzIьGYzS rfbOK_DpH\sD _&qti$zqlL c렖Q'}sԨMZ|aHG0I ~(KHfR'Tv$B Hqud{Ȑ [@8?-;G2YV;V|,cIYڲidAIM:R%.oIa4 p)/i̞9 ˊr4/NiӬ4 e1)A VԀag|O_F26#Y@P8Ahx&A D@y&T NJϖc )S/ 6da]u)+Т u!a.`T"!MI#ɖv͜ v㷬ğ˶C]R] "ź~eh̴Ꮄj,n .PH5XQgkd'E:<%3,5YА8ޱo$&vFZ)nuUI$*E,b`Uq:|KW_ωJłloU‰W衙iI:qmuM061.8<_[((J4zјD X'xH Y7Bj#{|BLechp[/ZQPVp IJW%+hs&ǡc qvU&;9^Gd7kY Y L'ykQz˂qBPLtȔr8:dRbs9ֳ2Zdi>cVrUc1^У]U3{ڃ^暵hWmڰHF!*WΡYZL&ިV),i#/ 52?Jeui[[P.㮋ffxn1Jzm]ڳis׎7 rd=`X@&Sm'N :t7qjbtc o]WN/'1L`79k>:g::ut|=e$>䦋ReB Z~.7D/pN*5ZEd$ -:p% Gl"^%/ؐ7-<5O? gk@Sz N~Ut!g+NoqCճRp\tg/sWbzo<i2u-{ͼ೏}F7>y/k䳸~]?M_fGB_EH9! ¤w#vm$;]eI-~atV G䇀 ngXwi%I)Gfl/\IV3H$\5_NDHNxXVxXZN/`^cXdxi؆lnp8rXtNzkiy Xh7phTPUN `&gQ B),p)@/R%9QaTQ`OPPdS5u@%SOAuzS5FE KTTv&dQt G 4R$U KPR@JRm, SO8SSS T~ ITPi" F7[HP X9`xXS7(YSHP:UBhȏ Th(UVr,P,`Ux|[[@E9=BEcDFSmfAcWVI9>]W|SH]]V~oP?+}+gi҂wr,vw~5&pDH;z6VdutXG?YY嘈}ti!:Z:7xw8ע `FtT~3'aZ0f#a q9=!kqVbԮĦÕtif?GxXc-Vt>W k59ɬeVYTsgY9W۰$dZ*B+Al"ǚ%{m')+Kj7HޣEۢƦw6Ki1<;X˯;q68!RzF1 RT[ToY[b]_jZ LM{*wSkr{t۳vA[Ckjv|Mbvq۸! Խ9uvH|jc:Ͳlu 9l |q ݌zܥ@+:'3ʣsuBoQ'I0s!܉IAZg5govlv: *| ;J~:8vj$ÌK$dd~F\KdCbx-+5jqCˢ#8joR"")"]gAZȬcz %ڦ{kY|/챝wl{T{lJYrMv>-/]4B]hMChْؐ=ٔ]ٖk~Հzل}؆ G=i82I¨zLʓG*tӃU{|gde -|~]6 =܂|1ʧeB]-WӅݖlUWyeBձ]}pޢɍ-\}ޟM}rE}I Xwݻ=QrtսIG׍MtߥmPIa Sw ^"^6^w@y8pM7J/ĹVtGMޕvߥtQ&y;5IWja‘\nw$>d^w|c+bz4\KB~ݝ%IT9M$|Lǀ #I;=G=/L-/Q垮=NIނ-#N>>^>? ga>Vf[\)ׅVNӇ.} ?_ "$?&_(*,.)3/4#pz @(%OOeLOe(U3w69B\? `aHg MTǠJE%P%  Pa $iU%uQ-Q*ё8XR,%]fߊ`c/T$S@TmߏyT  uԀ3`XQ*pֈEp*YMPS Eώ]/%P(9PN+<Q"Q^$u+\ (E/ϿEZۢdN;޼Oр( eA(ɮ na``0ma <}>!Т#ZFNa2<}Ժu̥{Gqx(8bI33C 0d PdӖv굗e%%uJ'8(aaaiRIc-j .>N^n~. J?? m  Aq59qÈ'rzc];6xdCt Jr2e\t?T3gN~z)ϡJkGɠ=!ePݼeƫ+tR*m굠Pb] !Xuڽխ޸z%[toX|֕5߲F\6Z8~̗ӳhUʅ<9g}ŋ:uҋW~<0L ˮ`ʄLtZubxɝm\0kT[ZҊ⎮|yY͌WFjș}N_Om[fm+]yW}'d}!{]&_} F&tkbwٵ%K9vT6ވc:c>(ub̈́X}CJ56pЂe^~ fbIfffjfn\LiNu7CYVZr&\`FTeT~RJ^ini~ j"h?Y` ǤF9꯳j".l> m5%x(<`$vxldʯw dLhދo>Kj*KRV6Rו{XP6a?pql/rpmO)U=:n]?p QJ:sXݜ|θX-2ՖeU>OMuҊ,旌Y0K3!2Vvۘb%,{}AjMxl4CKu~e#2ڑ]!lB@nyTWwqS7sGVan{{[,./zҮ*ysH4NWtքM쪵n*=-tK}׿~_h5:Ͼ_<}+ u .# f3AvKNoA#s"}m|+_ 1 An{ dHX𩏂-t!F9lE{&< "D,an "PEF x >qQlcy$'wQ5JJ@#? "BH;F-!EsvX6ǹ!Ld%݈IN&z Jށ WwBTJXB^u9E V~# wRTy#UB$u tX,%B2 5ljSFq$FGtyiYL/ KVA1 b7**xj׻{, 'GK4T5xɈfrD 28g*}rzWHoL.QmNs^zZ3.v-[*7vUaͅbub`дoZ9ElS[eV`gvuUk-ed Zk$5nl> ߅{$|ءARra"Έ} ބiԞHE/;ܗ(2#96= =x4oRa%aXsmsKl[P xSpRW Q?+x>,mk% ^٣̯ 3y͍ݮ!Z%SU<].o,e ȑ925+:Y(wla# R &E%Y'>4ThEY3 &z?dpmf1E5T/>|tGsQs%dAvG:fawOʱ3LX);h]?)>µ`m×؝Tswlh/267g=[p)M]y􅱫Zڌ;-A[R OLJҰ%Q=~9PtXfp{ 곭=ΜEcc}ÛI|^9 N{L}d/ّj_~3ɑ{BmƎ{i_831w*j-m3JERxťmuZ?PU-#&;&R,z`:lD^c%DoZ?6O/t5w=y[wr&*35H7h9;~}MgzWbxwg,qvpQ2?p!wsPAg{kdLj.~HsCn}BrA&yhqzLal$̖kuW|p؇q1H`ȉ艟(HhȊ芦~m$hqJst%HhnjrXȌ茭mhՈQɨ"ژHǍ8∎税<Ә[츎Lgg8+kM#kǘ%#W%1oGP60 )Ii 0 7Fxie3vUY5~tV4Y~A(Qc!%JxIyRGyהKOQNYPiS)QB%k,9(|DS9K9E,3+Vb,cI1"OpBOVRd%1' ?)J.ĚtJZVzva-c,_]HdPOٙ-O+#kLtN%PNJ7+P$%x(QN4UP u~Yeeɘ I!Gb"K"MR(K /(Be)F1]ɆA#32[3HQE):Vh@9^PHx7JG|a7eJBO9,~J1NG']=@:8s29\"ib'Vv |([LGWg4҄1wJ ł|4y[$8b{n\gsE jV>v}ZDB+#~a M9a ZU7A(VbdJDa(k!!1Jɪr}:|BJ?az3cq.^I)A?\bJ7*_E|#=i;rM +Q\Dtb;ʹ;;[ۥP,Č)_S@2BGC K\1;2l̻aqq,DiLIzO#7Wbu;W2v$& Ld\+=1B;vr*EcrqX8IU<Аh 2P/ ,<;bi.YR˭z& 4)uȄ((4ӎɌyϬ@+ CQ._>^ܵ̎C>$8ll 8lʁ3=xXTx\?̐vlɜI͛8sɳOHʢ,HTʠe-zj9m|T(c`,%XT; m#J $=e\{mٹΎmjҲd6Bhdchu)Kh1CtY_x  ue2!=aC}{(V x U%+_μ9sV,p'zo{ߵ><{OO;7nMIJ @Wt %e5 C0jrY !%:8R!ѵ-Š@Z5"1 sDiHjFfeLPoS@X7QWZٞqi difQ;MZA0-ߎ鎘piyBK?*M y框9mgG+&`!aMWs&U"ԩ 'lJ袆Ɗ|:Nֽ^~vG%{~d ((=T밟_Jj}iͥ+k{6+ܳΚlȀc+XE&Vџ$F{JSV:B+,Az<ՂC2[J LkZ, OM&Σv[Yj&?&ʓ<yݫ&L&V(5/@9ٛP j}S/б$ =$Ɂ 4ZPdB#V <*hvo`XڠWBטM,nU~' w?R5e%R6T:Q3}p*sFg5dhE#Q RFѩ!6BqVsH$]1Rb Ib^Hp5ґ+y$݈zP)̤&7Nz?QC&JJ=&:Y .w^RC*Њb0qLeĈ4!g8/ (G9l"+Z؀4|` Z&̂;9_WerYLa e1@Lu:3C-|ЁN`AgXt`DO6l K hC尒/M'O,V0.{XmJJh .F̕Qr`+D)+ X!6ְ&34LJIJ*DJsJזBXX8:H_ XW+5^R޵>=;GZͬf78d!SWcU+ >;%&,"]Df7vaI. *Fv$ 2 E0)E]9 usvB랎R"ܬ̕|I|@=7NA}/~׿,AxwfF1Ǜǥ:8uNS%Ėl<Ą!j0 g' CeZ KGؿ'R֤TX踰WЂvt`ܓL[HMoU\VÚp,Z"brO&W/2[OSeU:`s\UkɍCC#]Y޲TGgy{=ծֆHf #dlw^v8Xɡ*q6OUv'nCz 6nzdWAMk"o l۴hb˾@>|W"Bg4zwފ_F$үh(p*}{[ZT_/vEwr_ &JÊ-9^>2^o IwOO[PP؀ϤP 0LM ~p Q&xQ5vng)|5N3`e\D DPNXX 8LIN8{L "XQ&243Qo`vHhtXtTPPL$ L4b'HP3qIy`v%nj]>A &kFU7"S`Y0nDkuCVR`tP7GC='SNsGggvAx?LHsBf2VyŶuE>{f5Xx蘎긎؎'o[;*xqeD!$B0v ِdq5j`(S$Xvc-!.: Y"VJADR4(:!!QQ"~a;. ?p4 e4Vp21):+Zײ_&f0xFde'1wҠdW W%F4xF*~!LTVv{#`%iy&2$gNQUeXrU2UeeIycFfTb9Yh5v&1^W{x=Whb\r0ȍƩ@ru$aݙwEۘըji7n9{՞D]H" #1,z+ CvGF"":yaL( J"ia).;p Rp#$Z3$>)w>[p+*#b[LiQ#R`/5@B:DZFzhfx6[%ۥ\Ӡ o[5([(f02a*u#AytjuriHen.u[9z)ݷiҩX'V)qLu؁2 ͲJhta%S-ϨVg+)jugIeZJ(ƨ#a,>J3;hYgTVS9d;l/*;B03fÙPvOiR\\Ŧbz?W3 ia4@Xa2d&KlK괣ڧ+t [c{w+`+ ~ f㕮qٴL7S^rظ:` 4 v;K{#$ P/#J|^;+Aײ/F4MrA1K{ 9^Ž^۽+㋾ߛ۽־^EkI U盿 <+Fx\ah|\͛#58\e!k"W65ñ Hg{pE< 9io'2]`ˤD dh8ĮVh~& r9L:^~IAaK>^~ $7r%⩻+$2N ?Pv:TK؀„Y.TOpuAP D$x) * 0#0HKWu9=XOUNs|_އ?XaNPN湐gM!Xɠo) (j04r>J@ODc>xMN0 ~n8W8~%؈cxT x/v.N~B8~NOhsÎ0SQzF..2A9AdQcOkn>?΀^UP(xP^^~^XQ>78>_m:xShqs*uv҄ԕ4f6v'w͡Mz3wx KكmÑM*/GL߬?kj﫡_7RΡ*¿ßOϹ_ռ?6O$]O?_זoo/! ߿Oh3D,oqu6.J6Ifʮ*Z󴗬C'a ĢL*̦ &)/*qh-# ;;ӺVv:Mb`-v9Bo@Xhx)9IYi8V"aPc%0b *bQjp7Si1pil`p,yX 9jL`k%7F7. Q{+c?3n -ڲ VHR!Ѕ"4ME*zPdYAA v#`EbV,PΕqipciw -Tg)]&pYpQq/Mr;d}@,;@i\4e<ROꢨ,\q ֥ q%aBz);L$Mh{yL9!^R" 6,Y$<JN-E8D(Y3D:5~!*agӦenBh }zdOEw\e&gxХeEYf4MFX1ލM5'h[(oe=܉ؕEra%{$A甍65K2ڈ#edC#=XJ29$<*Y!x=eOf%6pq(܊/rb*r3:9Jg~ (6Ioȡnʙb/,hJi^#VhAUk t&蜌&n@A)kJkފkk  h.{*ƶ)NKm^mꨚ- J.ʺ8n(mɮn+okoo*'۬ p& 1KqĜN,> -cLȆ(lq&1+验23p5Ls+ maym3l|0* uRqztL7<5[?]MuQs ׮`wXЮu`L}d tJCXa]kQ"``yqTg2~8A7GoUvtS)cܷ;CdKO cl>@]{' { dO~柿k,0?f2W@\v_[ҪZ u$>!p z$Gd Cyv?ފ Z(. 2. KTCQc3VC@*0h;9lC,jq\0qd,#G P~uAEtq[p`+ﭐWṛl0 _! C*2 P%: бq)b?@N7q[0֩Rut] 3CwäkL6Ill1Y_lA&d%md$'DlPoQζnTJ\jL 5uQUFUN̨W P [ m3O/ɘ uKiJ }JńhV_qH TqՀiZh;Ň~JQ굉jbhj5hh8u}fS=&C!,RV짱b $'r2 {P6u7 |u(U{WsiN-IINjԫnsЯmUQtחMZI)/7:x^7*^LUYRcaUhm/W۝ӠP~/Jˤḵ ˽/G9nUaA&lޟШc`[nUB3(f zaN7;Uۘ\/#q,Y]AdҾ0i %k6Zf,hV*Oc+N>xGήfN|fH@zЂ.4mBjrFw8ȟrDg9;ȍ.~ZнWB&u[.$Jf  Eѱe镱a"+ӡp ^z˛61͔7vk;k&vk+ q<ٻ5<F4fv#j^cv  Hkگp΁⻫>#,N w4$Ap9KKqirkPА=EkP8S Z!R)Iux#ҡsk&sXR^tzuF{+sg {MʎlO{׎nX1[u-u0rn@O|Հު [-žՖ2'6q+*׺Kx獽k/ϏoP}9@P(Hh m#yity'GЇXb36X3_1'h3L|)X/0a'/E1.HǃS|(RefCd2kՃQ=E;e7GY8pi241`x[p xԅvrS49r&:x2P]/AY1Wv0Ca}9 .49E1amS ~a04UaS/c}{{Ha}D1ՆsF$pE$?nq S; (0xT?p ﳏ9B#U;@{=W}]]9TT; IYȐyъ2PmJbilwCG`8o4+0.Ja|x FUXCڐ@@BW U;v']}'bsKԆ.sZRՏd`?ГH$c +b W(Av0Wzt,jCx!(zg--2_rvp'i3|MKOM|x[Դ] rFf7F]\iyFgKkH"l]W|I\n:R(y7XGimI8;gR)ùxtꦛ.W0dg#.QEwg ϙ:i1˙exɚۉ]syuɞ,2yIy^RW)79|iZ53+{ 4Lz*٠%j5&*s3uvtz1Tן"$*4z1(Z1v ;`@ڣ\31QD:K0L8jRxIWJ_NMZ,[ ɥ`bzl>ɢwwYuZ*nʤxgڢYxj'6C~z~Z:d)Ii>2Jjʩ言|hiRn5 ?uI:?5s)T3xfZf"Oǥ7wJ<ϊf*d+6,/>9zߺ4mImo4EqWQ뷄VZ[[*Qʸ\ԭjhKk+gd&C+<=[3Khȵ$۸EI{P ¹4z$,;"ڴoЫkç)뽖z+KzI{r7:z"{Y%iy즁{In˿ 2U'Ll C ;httrack-3.49.5/html/img/addurl1.gif0000644000175000017500000002272714336470674013770 00000000000000GIF87aƵνBBBB9,@0I8ͻ`(g0! @ ?ݮǤo@D:ШtJZski[p%^Z>o^Zfk|}Cj;D22(-.X9`mwpzvshxry}zuŊuC8͊2'(((O`; SPP1RX#;ZS@ 0U:pࡀi4͛8sɳϟ@B P_AvdElѴdTXCf]qBMWeM-RjKhJ$I/J=9錒X`17]wadyuԔpwap1d5擓e R4d_˓(D{1%yo :yVYV9%:'%6F+VkJmV$խ$DDaTW-x~) mP2j}Yѩl:o6< .Z} _:kk$g >,B-r4l8ל:;@mtHK'4AbTlua\w`-dMnӺm_YvZհb%id'_h`'Ӆ?UKs8n/c}uEq3)WبTbִhZ$κ⦩ȗ[n{6KMl;>;[,'˯|ͪUWfܪi?~{~{앺Sv> '@ܖWKYAˠuzdǥIouKj 6@^x@h9a )(-0I‚2$X*o:}Ŗ tvR[85oT#(:Y~bh>vg%T IB( agv9c$p(pp_,_%7YofU(pr&*x_7oxgcrR牭_#A1Z؋8XxȘ(EFqr gnD]7%!n>gs8r8Y^r63!'r#"m\B!,y!0b]!~ ADqq8ؘi UNDXBɔ7!DA ADa|P=W9]/]x(5U<Y=]!b@P1"Bg8bt2q \-WUI,•-yӕl2"&qT9)&DA=擊XeWƘ'XYQWsW+'Be%vC|kxy$;cT_rWpFrUi+%u-G֘CSYz8rnw&wiHRbI[]]d1C![Ug)c"sq8y\)Dbȋ }c荫B,.B\h!'i3d" 7+#N!#!+xY#24aAd ":$Z&J\RUdux[Ov*&2JZ7:Z9Z.EΆ.$u+Ј%4'GdOd y;JU>:`RQ%Tl'R{]!&hP,9k;E$bfo_:xZEgיQĉ'g_m'z%iRk me 8<L?:f'g(t>8I1 I$9={b:ez,DSc,fw:e_}W7r.qh:ʬ⬹zuڝXJ CY`?Ix5dXn6 z&:U[ƩmhʭϪ>*CzinF1ZmwYK/گ9$sVa#4Bj.ۢiH2J,cp\[]"^`;_[bkd{j c`۴Wr +eVshzq鶅Ʋ2;C[ZHy Ay;Ay^k] k{뚟 {;KK Q\۳*{{VDc[;wۼ;=A;gmEPѽtsDuS:cQ3T(59h! vC qjHD"+1Zs'db%f YѦmXs3 i!Im["C87$I!VqSS,! "C"X 5ȝU[ 8CX7cQ:`Q`1(.e anG]v4VLLk@+=+7:.9qkjc\'򾷈H&H.+Ŷ3S"˹7r“@W`䦛֓|ǴY-ąxƂ pHdsr@\s*j>(afUP̊F:?p~ pA8[/t;uU)wʽ s< 芛|9 LaT<α\i\\\ZAo<,kdA5]ҥ:|v\#CuaSǡ8w|{BURˌ| Տ ! =B+qEkAZUf @vsƍ&$FA {Ɉe3.T!uHWЊ(j+ZI}.K #-E;; <&*_.%ɞlNڙfWI<܇%z  `?E.[9.ir =7^K͵ٔ}ٖٜٛ؝-ǵ-I6wp_i-OͧB CÉ۾=]}ȝʽ}HDҽ]}֝ؽ=]=[ޒޏI]ߦ}$U Vȅ.NcjxU&}+0mH ᢔJN`htK .̀0x#DXӇLZDM^M@^ >$hN`Kdq Rޅ28,~Kg4Pj0 :4}-ЀH 'EMX8dPBIQO~P䲰t ]N|.f؃c 3vD} x*N0۴}9ME}L^bJDLhQJG{P |Ѱ486{􆞰4APFD~NHd}>W7t \鿰e|7(;i`C(pW_T~Th`>O18ƞOO2>D2L}(/)\rڥ`jkkljm2w8B?{ǰFҚ|_\wW[c3efO,04vW2^i44j4&WA8XrMco_q|_M/h/bLRvl_1H}{X4O/DGu4d'_4_Gv+l}h)5׻/ϝڿ?_u%!"Z#mZ: ;e>A\`ʽB &2"Kx" l{-˜m>kpzZ{n.ǀ:k/[/؆̰Lq.NL!^Eq5F" x`+̫.c ' .\ =>_҂? Dp \Ql`9Ks1{|tJ C ڇ|9pHAS.7^mí(JKMAw~wrh_yo.1Z\T@:qJխ/z߮>E  #ego{Q$OiJp/ jp9P2Pج-M%hNӒKl Th|ꡫ~ qB,"hDPM Rj,)]6LhESIm4lT!jbXF-Qb5DZ,)"FBu,H+x@qi\1Qxc,>>RkacIHArL4BQ##I°I\$'3 Wrc۫75J#I\ɲweoVe,B6: 2C792W f+is7 pt$pe'9Or/RQ%qfuORsnu!w*Wa8:)XE/^R]*MZتqjOjTHkX]fghN9 [;I֋V` IL'%s%~j[mlZ,oOU {"pFR=syZaBw^L"*ֺA˔ZeǛ0w'{ٖԫF_j*a_Dx0/l cx[u?8Y=6j1oLT@Co3ӆ tR}O,VYLX^wf!3 oXXCW(~Lp倐"rgEYG+"`r'Bu%FC9C3ht|)TrN372 jE*rB@9k 1XU_,oPpz%{IUJu`3diZ'G8N-/ 19N"&x(-2c=vkrz8ԑ[&#9d=X*hnvĄ^:rj֓MɕGvQ׋[ h]Dpu[w5L/f89>fuY0f$wxa)gqY9xg]rЇ^9jٗbI]ix)dOH8 x|Ywŗ73c%ixc)IO5k1#q&yٛ|vjiO) c9Wd ǝ x9"IiirIT rK9wy`nY)ɏȹ ݹDY J*qٞ}%Lbwp)+-ʢ/<Zzb#93ٍ8~(b}%HCOhٜ5#M_Q_rsөErGKɐ4K M*RjCpypCG T\cXHvRHGF4j B.R*pgKK53063_Z0>"PCEi{&mjwnlʤI9Xç23xz%pz wčr @ؒ )h%X!D@,E&c9jzs|H3|G(]A|( 1:yJhSByKZx/DG ʰb3@ Z`~hr-A + 3f76A{B!DCEGM!;;k9Wa+YjSa 'd\kzR۰k+ u{ʶy?Y-nm9$ٶ+3)p&[k zK9-YH\t +Kkt|;httrack-3.49.5/html/images/0000755000175000017500000000000014555203200012462 500000000000000httrack-3.49.5/html/images/screenshot_01.jpg0000644000175000017500000001363614336470674015614 00000000000000JFIFddDuckyAdobed##""'"!!"''.030.'>>AA>>AAAAAAAAAAAAAAA!!1!!$!!1>-''''->8;333;8AA>>AAAAAAAAAAAAAAAAA," !1AQS"2RsaqB„E#T3rCc$%R!Q1Aa2 ?뚹[2̬N)iApFa˽c:^bTaH zX[+Y0l}KVZjwң\G.KkTYfv2hh-0+_GXض'سZ&̱-o %xLgOyWsjO1׶>[~s#dh:aa]OiakJZD!ΤJ'%x1;l?s &o"s"wEhޞ/NH}/DXc=qczbp`&JنVOf XM0>cs[;ބ0\ fBg,Ϻk %hK bxNZ0KX o 4*i9-y񽷏̤7ø/ڧԟ/ڧym w2ޙ;z |-I|-N[t ?w2Yr|j Sj TH0Aswqs) ;vq(vġg S vrmIJ3ͳ[i-LJp9m 'g,g{gq) oj%ġg Sm-NKt JC9ڞ%ġg Sm-NKt Df;CIJ3YWq(vģg S vAm gm-LZ=p9- 'iWݲ+핻m-LZ=w%A-b^R-;LZ=wOWAlhR 7 JGSѝu>FُU[+_Rpirjyi_ %ŅƥgyJhp:ѳJѝ \ 5ybe!/:A[)`q >HkfX.]ᓃ|E_z 櫜,1a =,i;<8,֬V;ՅZklHC}zՇ&3DE؄ZeJ f3S`|i tZhfkM!7`ٳdgu]Yƥ`-[C͝& ;SDguɃGfy0ho2`ٳe4A ;6w[̘4vlMC͝& ;SDguɃGfy0ho2`ٳe4A ;6w[̘4vlMC͝& ;SDguɃGfy0ho2+Q/Kԭ*soϖ wğYhJetcҚܵ7-tW|x31++5.RG-#.?1R.ߊط90FݧBi}GKlz.>u_4"}JDME%/f詪s4HWmB =gGoVPM7`H1Q$D@\x>[$jZk;2FXL"ʪvWDtTE]7[4u+6zo6) !MD= Mٿ1R !cj*抴C[8c􂰈*H'8M\c$9h@um(6͸J\p(6".NR*g[ -{b&qAg9h6 ֫(s\0ZǎLrZڹ]5#,VjU3T"#:)3cR*4:@5lmo W66ŽV|ʭ?tr7Vjq4tAc#uomy[+A I+Hje`e7rHs#htcq*FxG9Xn#YSuMNYQ|<˟~YT zaW)grTiM`{4w _K4 bEj4ݼ_N5%g t|7X/l&-tU K t iW]bor >[$jQ5Ja4 F K[Q\.vU&դJ*KK2jne0 ܀pcK)zF[*B \pWUݍN?7cSXfA'񂛩sVI-Н7cSOє-VP&=kmFТֆր'@ݍN?7cSXd ƭ(M:7OQNjw}z))))QݍN -rS6FӠ9pIh`֗11rޠ""" *soYU:F;FMRռwl\J)?{4Hk MK]gAZnPQ{{Zmض7MŲ`6 Y6&ˡM eLR&uoTi)Q. +lkG F-&Ԕa]cmDD}|9 .~QRFS2ElZqkc3S,5 8T҃+ \`*]pr301V#1AΑ\~mZݝ˶qwfWYBpB Rω(&׵D#U%MX/#G2LehpF#~+h1Kf lq ! &$(S76of_o XvR]@RJZ`yn *u}+X6Z.$D]`UoZ U>N" """ ""PM7e$XoN _& BٌAQk5KըA1*x֘֕1&3OҢ3v?Zb?ZT\viVyg> 1 c:E./P% .Mdq?€}ueV|:[3 ϯG!]}|9 H԰C +E\:/9E1"ʶXD}k&}U'iS[:f؁az oE]j?,.3@0Aewgk\\`3` e10M,"ǤXAz|$]M\jϥN|kV1_v'oO~~ SRd]jGn|$]M\Al39uhʀ5*;3u7FHeP\|yTlkl%[z9+:Jb= j€}ueV|:[3 ϯG!]}|9 Hԉ ʳp,JC"=H@P%nm,j G(0YrJC"=H@Pe"=H@Pe"=H@PW~Z3Ү)[ K@R#sߺo+>;'oJ^"=AsM:mfK3N8y7–W"=H@PW~鿥ɃK@R#(겳U*2H R Dz( Dz(}ueV|:[3 ϯG!]}|9 HԈ*""" ""Έu,(Ԁ Y?jUMq'\.Xǡ1-qZjRU) F7iS4A 5٭6iƂA$I-bp g,@"G`ֶ" !SfL0).!r[)ǥ:rh $p˞ƶb] mƼKI-n6+21DAx1͌".T'i"mʴkENm'6k@L\I U6ԧJQ)}1\A XPKmYTPQN-[㙌/J)0RPMa1-$)*soYU:ﺿ@*{3" """ .~QWAs_-B5""ʈ VUo7΃?+ﺿ@-  or\xH" """ """ """ """ """ ""?Օ[Mn ⧻?+H""" "">[t?y()#R",}ueV|:[3 B  ϯG!]]|9 HԈ*""" """ """ """ """ """ *soYU: n$8k;_NiXAv4בDgkIyAv4בDgkI5QI5QI5QI5QI5QI5QI5QI5QI5QI5QI5QI5Q `Xf?ɉ0ӥyDTzj5@m;'t4-*ZItaoIyA,lbxbU G#<:Xzchttrack-3.49.5/html/images/screenshot_01b.jpg0000644000175000017500000002043114336470674015745 00000000000000JFIF``C 2!=,.$2I@LKG@FEPZsbPUmVEFdemw{N`}s~|C;!!;|SFS||||||||||||||||||||||||||||||||||||||||||||||||||," }!1AQa"q2#BR$3br %&'()*456789:CDEFGHIJSTUVWXYZcdefghijstuvwxyz w!1AQaq"2B #3Rbr $4%&'()*56789:CDEFGHIJSTUVWXYZcdefghijstuvwxyz ?nB26߽J/VS=}NW8 v3& & 9TV6zJ/2I=CG+t͂Fd_t?8?Ÿ_(mr(Z{?G-?𣕀ϛG >ip|޿ _NeZx(`7Qz)lQO(`>,0{b*B2VnR'lg(arj6ˁY:b淅ţd*P+ _h#yXRnƓV}]U%}O]QE@Rn|{Q]lŸ1r*}_Zl+#YIqo/md"ٰ?I$ڌvQn\5pJw6TEM:JH<@0=5g 'qVL:)"ۤ١I3p:},@f=2ke] W-R7ApOV4ĖTk~2lQ2>JlƐqax H Bļ!Ao+£2W>\ }h*q,U[?8\q Z" 9sG0tdzΖ6 3dy>#Ƕb(]>Tw= .`4# 3tOjT)QEQEQEc KFH*Ώx!s7k~oՕ&ju%}]#QEաk-bF m^\lh<81b ;kNO$eWLX*3M#\ ۛ2=sT0ћwa{.Ds0^1??E5A}P1fHx,zzSRGO켃JSP ??@3v ÞMOf7wI7g.xϯh)z>/ jq8x?şFB}Z a21O?Z7uĠo>untہj?o|Q쯮`H]72hP!'jG{!5z-YTG4 `s\zOm\h^<9Ϲ4j$ƤߊCHʠ¥!ES֟/YZ}/BjE٫+XtM\7/ѿ[75o(ΛͿjٷXO (aE 9SQ'6L{S)UI8$':Heu=RV$+TG}IPH'?>gW{SrH֤3mVRp=hPJ= E(j*w qH (ڝ@Š(GpppqpTʠg!n®1~hv}FF*LJZAҖ (7j??V/Yz}/Bj橸~>ERѿE](`YٷY:o~6b CAHmޡ''%S(zO4H (}+GNW;9ϰ_*hUٌ'a1)MfmH͕?0=k)o."eKlJ62us~]IRHy + y?ZТ9^"9  ؖlgQ[kK[YJT\mUkQ@ÆqZ*HJ ^O֦p3i֪-(?<ְW]D2n zZ`ViTz9ҖtV (7j??V/Y|Bj橸z>*>E[d *o+X NͿG6  CCɤE$$^39 3# ԁ%!scΜgӚ>.@Hg_ҕԈ%I_Q'Z(8&sj.R X!Td3KR E19`e R2QpEIkE}?܋?E?܋?QN$]Q}ZLE E0INȤ2`IECh}M1QPoSK-P1H0J(}#(jg̞c- )kl )kO}f_>W5ii~o՛&j.u-}]AEUgMfUm˺nj<MXIoc'9RIKLzӼʃnWjp09ARL. V[MDH*hKӜJ}nEJf%( ,snyMZ?4jGB:w$m1y`, lV\n]qyV>HoOϝۏ*D3Cgg<_Zj ggOs.MݸqЗRew|~jnڿ4}YFp"2VG?bex(sU[ TmwURsNOAzqOJn8`SC~ԴRQE`RSږq4qO^@ 9dSV$kP8Ð>Lghҗ!P~eȠ RVąQL Zߛ5f KO}f_>S5sThusFfn΢QE0,i1ZCN&b`gHu+ 1UF'r̝9ݜKf+C( /ryڣdTUPp"b8nN*J9e(bq)MlKKr}>h0(O:t*!^P3EEZߓ~OꋁV徕~O:#rT\ *t?ޓ:I}Sc UG?>\ UG?>h_`T-$.QL((|t)klHQE5sThwsFuKwsFuo(ΛͿ4aXzo~6b>QE(QEQEQEQEQEQEQEQETW?ZԵP*((JZAҖVąQL Zߛ5gꠛOաUL?W5MƋ7?toQT?toQV(,lް}G7??1[zoUSqQY ((((((((*+-RW?Z(QE`QEQEs- K]+bB(?_5^E٪?W5MƋ7?toQT_?toj*;!QT7??1[zoUo+jA rFw\74(k4}pvf_΋0.QTA:,ES_Ώ `\}tEEVXcfGMT>4߷E( ?`\Ե@/Kr$^X QEPQ@Q@KH:RJؐ)kO}f:tMW7j.5sThusFfn΢QE0,lpe9Vc֨ilӒT' c7I"2>j|t 9j: r.GQľNzuo%ڣyzyBE?>crM^%| ݷ?֓C5>k>Zϼ?!?:] ?[ϼ?+-҉<7G(dxG-U(8 3+k(%| |~gFZ%| GJ pB jA$,%J0zqV"*PHh*GjJI)P@Pd{zT[֍H AҖ~襮(?_j /T5O_OSq}]U-}]UvB ( :o~6b$ugYo~6bP 5=Ɗٰg93̃ٺNg]3.X#?۴Im"8k;6  8Ǯ}=e,Y Ww9>ژ9`} H(G=) cK nrx8H1$&q;{UZ`g-!J9=ct$i)4ij},?TPmZ-@?zI۞21ɎI[LmsJ-'{cҤ.Q^dHP:e蔬jKEES*QKE0i3R@oJ0} Ou/''ס?ңd( q>ҬG*p#+~eG\?Κw~襤)klHQEU S>5_E٫?UtM\7-ѿERѿE[d *o+Up,3.or7 EW-Aa4:(zOG?'oG:3&3ZBڀk6 SSCj#X\}EX##J[QUa9_`;+ΥS֐>Ag\쩬k?@w9G+*GZJKjOm4PƹO+Uf+Uf#:(zONU޹/+UfzO9`xtD"neP 4[(`ZE٫?UtMV i#.Qک,|I;Nr0~W5Mƍ[iL8QsQ YJ0N,ݻPNJ;q qg9A{ښ B3S&o@sQ RGwZ&fT'Tpzg0hrɞA[&ve.2T=piNj-RYy;cޒ=fN%%(GabOq)qר͗y'Ror'$ܟGaaN6_俘Ai4Ai4{F/?^z)?eK OO|ߴ= f˜K\O?~/'Gi4{F"̗xK61l~#hߴ= 6Pr"P}r)?$<*_OO|~#h,Dd>X~"~/'Gi4{F#:l`Ĥ{I/Oҥߴ????Əh>q>q} 'GAg4{FQS ? = ( )d?ƏH,??Əh~q} >q} w$ܟG$ܟGaaaa; ?O| ?O|0߰pBc8} w$ܟH ǰXۺP1\fl]&IQJq拍NmZT0T6= -"vVrl#u|9{赻8Sj9>k'WԡFdSo>w?httrack-3.49.5/html/images/header_title_4.gif0000644000175000017500000000370214336470674015771 00000000000000GIF89a"kk??_{{ ++AUU44NvvJJo-``!,!@I8ͻ`% $hlpAm m׸ۡ_MF ~rl:)pJ 2ӠP#jimq0 tA{ -}5t6kWb|:,; z j<R?MիXj'0`  $Cn T+R 2&r@@BM%Nha;F V=>&A  :T"˫Ed}% +:cPYc[PY!]m& \*C`9Ϝ&|L.HlPPgW#59rA+xV:vZ T Q{#0`r U$ 04Y`|# D)8p5"+EUR.4=Q@SP巕Ol(D+v%L9Fv`TViUH^e,R/ dœS5].E6QqԢ}dhM8Y>$0 H6R_@@+ 6!@`\ y㗻ڴĄUh TNcr4 ': =@]0x4 GkU1itA9>|s|ՕAwlp JVV2d# `'vb*r58l!1.f{U"!, ^0@(brг ɲCYS:뚆BB#"5l}TwEzq'XA\U{*+`,tUH*AH qWa\fG 1gbҌ;f ґ pxw2G`>a&ўKW%UaD~XB*-J1b598!0)a^+[#I|-)fx/6FP;^&Mmt 9T8TQ81+ Ũ*eD53MV! 9Frs_6Yϖjnj[XU LVU>4PZQ*F܂#MHaՌ6S]#B[ZV.1FzBx*@2Ny d&QIh$c A WR]Mt5 J%ҸNֲDnX[|VoJWMG6!\6]o/r m:T|ZX?T./2Z@⼖[Nj̀ UAEK,ꁴR/gX\{kXIF;httrack-3.49.5/html/images/bg_rings.gif0000644000175000017500000001021314336470674014702 00000000000000GIF87aݹ׾ڽ,@0I8ͻ`(dihlp,tm"!CpH,Ȥ8htJtvz0i-hBOn](@y=BM;wzO;MmCX$nxǗ4suУ+xwקA־{߿͇i$=ʑL< 9dP%$V^Owa[>ҢhY4gfmk^Et'qs֩'wW{B)"d}0B#ᣐFhVjR!fxC6ZDRԦS@ph>(:=.k;"`l#:,6b K""{`Ut!xgXn9+2f`! rݷ\IpSde p\qFq(Rv0-0qaoS9XMl$,.ߵsd@ 5d]5,We,!RHn-}5R- N%vgQ=lVͶ^FKu/97hkP}6w߂k7țxo"G\?= wǰvaR,hh+9a!ynXS2;ة ;n:G|)g+:E<4}eZ*LpO-O~d2tv=s!R齗ɳ3_y>O^Y>!{89[:( ^ &A iuHpCj!pTC;ɐT |u@ H"v. U cbxL`@P%aeQb$ܢvzQ*#xjZ4)-Rbc__C1D^x@:ʼn#X勊} }XE. $Iұ ҩF0D !X/ +KɁS]!$RVIز(d/$RR&EdLCf] '}YP3??lf?\)"z(?kzCNyp!DAvTϤWrmRI 2+!̝#5r A#XIEO "?Th%6V!2&)7S J% DaXC^JME%9-MP Uq0`3JtڐhZI͏̂ȬBP 5S'P:rV{͇\-wX`9ʄgmބk]Yo&ιl/i ekpVگzZhi*5i% ,!a7'[(SHk&ҢbmliBk .jur\ºI41.^kp}m>ݛMwb)Sy3^ymInY]TW'eb}c[T7iEwr|}hi0_yeJV>j#a*Qp;\ "PySz#3Jl'3ü:r*| %Eq\AY(^'TAX`qcvT$(6.rOfM f<)+lP0D%g HקPjq:,k6̜ƚPi*6[=}PZ[f_MMʚi`l}됺Z8@ lId@j?PsA".峱6Uub;`n/thݾa `ޠwo{${ ?%8MyƊ)|U+V[ϸ7{ GNriH߁'K~'?b f\D>܅ok 1xnj|t[pM)o+"# uk})uIt}O/;,˴oq#=°&OłQ5n4GwySX}ndtR<>_?mz͆nX%^Nf^my@XQ'?ؾ ,FK?uY [{7|{?~P?7w^69X:0y7oIBLxT\8s3&sxFZ旁3Z&%8\%ep( 2!d΀ x>?^bȂDGq&+r78 49 K?yu5D يC H2My }MMyDe%[$EgiFXPWqY=y6Ya)sy6Hȗ<9[{9}MCYNukZ_€BИ(YdוyZ5qcõGY_L&陑ś \Mi9  A&y (щ >VrIQ`Y `9L9p集gI%9(cE4lnENdϗ]՞@9NeYɩᝋLuCӉ4gٙ.k'V':ѢRC%DK5:XJz2D?xTQ@Pʤ_ĠA*E:*VXEK8*HegDb@a,fr,iz{q}~ @]ڣzQ>4q@O!l8W"&PBJ wzɧ*bz¨WQ{:z"{ӦNYqE+(rx.Z = <"'**: Ϻ5"]3UP,`^wോDq[3 v!"=xz5o=3fj+++A KŪnWA'/;YeaA(*oZA)PoS"+CcCJ5ĭ%30ijKa0!IU$>bK@fO[VSfU7 O˵ W֬c[fgk}8Kj^;([ o;`upj4FƷPQH{ [s}j[Qwk"!m['0+&p'($ÇN*uD`A4 Et{*eT#Z4[j˼l rQoKp%q˽q rKts=8˾~ tXG0 0ۿx|VtGVtһ hiKFs =\x@̳wZrruG0G+*,. o ;httrack-3.49.5/html/div/0000755000175000017500000000000014555203200011777 500000000000000httrack-3.49.5/html/div/search.sh0000644000175000017500000000274214336470674013547 00000000000000 #!/bin/sh # Simple indexing test using HTTrack # A "real" script/program would use advanced search, and # use dichotomy to find the word in the index.txt file # This script is really basic and NOT optimized, and # should not be used for professional purpose :) TESTSITE="http://localhost/" # Create an index if necessary if ! test -f "index.txt"; then echo "Building the index .." rm -rf test httrack --display "$TESTSITE" -%I -O test mv test/index.txt ./ fi # Convert crlf to lf if test "`head index.txt -n 1 | tr '\r' '#' | grep -c '#'`" = "1"; then echo "Converting index to Unix LF style (not CR/LF) .." mv -f index.txt index.txt.old cat index.txt.old|tr -d '\r' > index.txt fi keyword=- while test -n "$keyword"; do printf "Enter a keyword: " read keyword if test -n "$keyword"; then FOUNDK="`grep -niE \"^$keyword\" index.txt`" if test -n "$FOUNDK"; then if ! test `echo "$FOUNDK"|wc -l` = "1"; then # Multiple matches printf "Found multiple keywords: " echo "$FOUNDK"|cut -f2 -d':'|tr '\n' ' ' echo "" echo "Use keyword$ to find only one" else # One match N=`echo "$FOUNDK"|cut -f1 -d':'` PM=`tail +$N index.txt|grep -nE "\("|head -n 1` if ! echo "$PM"|grep "ignored">/dev/null; then M=`echo $PM|cut -f1 -d':'` echo "Found in:" cat index.txt | tail "+$N" | head -n "$M" | grep -E "[0-9]* " | cut -f2 -d' ' else echo "keyword ignored (too many hits)" fi fi else echo "not found" fi fi done httrack-3.49.5/lang.indexes0000644000175000017500000000026114555203160012477 00000000000000bg:27 es:3 cs:21 zh_tw:14 zh:13 hr:29 da:15 de:4 et:16 en:1 fi:28 fr:2 el:26 it:9 ja:19 mk:18 hu:11 nl:5 no:23 pl:6 pt_br:12 pt:7 ro:25 ru:8 sk:20 si:24 sv:17 tr:10 uk:22 uz:30 httrack-3.49.5/lang/0000755000175000017500000000000014555203177011207 500000000000000httrack-3.49.5/lang/Uzbek.txt0000644000175000017500000010614414360553245012754 00000000000000LANGUAGE_NAME Uzbek Latin LANGUAGE_FILE Uzbek LANGUAGE_ISO uz LANGUAGE_AUTHOR Shamsiddinov Zafar (zfrx94 at mail.ru) \r\n LANGUAGE_CHARSET windows-1251 LANGUAGE_WINDOWSID Uzbek Latin OK OK Cancel Bekor qilmoq Exit Chiqish Close Yopmoq Cancel changes Ozgarishlarni bekor qilmoq Click to confirm Tasdiqlamoq Click to get help! Yordam olmoq Click to return to previous screen Ortga qaytmoq Click to go to next screen Keyingi ekranga otish Hide password Parolni berkitmoq Save project Loyihani saqlamoq Close current project? Joriy loyiha yopilsinmi? Delete this project? Ushbu loyiha ochirilsinmi? Delete empty project %s? Bosh %s loyihasi ochirilsinmi? Action not yet implemented Hozircha tadbiq etilmagan Error deleting this project Loyihani ochirishda xatolik Select a rule for the filter Filtr turini tanlamoq Enter keywords for the filter Filtr uchun qiymat kiritish Cancel Bekor qilmoq Add this rule Bu shartni qoshmoq Please enter one or several keyword(s) for the rule Filtr shartini kiriting Add Scan Rule Filtr qoshmoq Criterion Turni tanlamoq: String Qiymat kiritish: Add Qoshmoq Scan Rules Filtrlar Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Niqobdan foydalanib siz bir necha manzillarni bira yola mustasno/yoqishingiz mumkin\nFiltrlarni ajratish uchun vergul yoki probeldan foydalaning.\nMasalan: +*.zip -www.*.com,-www.*.edu/cgi-bin/*.cgi Exclude links Mustasno qilmoq... Include link(s) Yoqmoq... Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) Maslahat: Agar hamma gif-fayllarni kochirib olmoqchi bolsangiz, unda +www.someweb.com/*.gif. filtrdan foydalaning.\n(+*.gif / -*.gif barcha gif-fayllarni barcha saytlardan, kochirib olishni ruxsat etadi/taqiqlaydi.) Save prefs Moslashtirishni saqlamoq Matching links will be excluded: , : Matching links will be included: , : Example: Masalan: gif\r\nWill match all GIF files gif\r\nHamma gif fayllarni aniqlaydi (yoki GIF) blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' blue\r\n'blue' nomi ostidagi hamma fayllarni topadi, masalan 'bluesky-small.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' bigfile.mov\r\n'bigfile.mov' faylini topadi, ammo 'bigfile2.mov' faylini emas cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\n'cgi' satriostidagilarni topadi, /cgi-bin/somecgi.cgi ga oxshash cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\n'cgi-bin' jildi tarkibidagi manzillarni tutib olmoq (lekin cgi-bin-2 emas, masalan) someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb.com\r\nwww.someweb.com, private.someweb.com v. b. shunga oxshash havolalarni tutib olmoq someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. someweb\r\n www.someweb.com, www.someweb.edu, private.someweb.otherweb.com ..\r\n www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.someweb.com\r\n , www.someweb.com/... ( , private.someweb.com/..) someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. someweb\r\n , www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html .. www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/someweb.html\r\n www.test.com/test/someweb.html. , - (www.xxx.yyy) (/test/someweb.html) All links will match Barcha havolarga ruxsat etilgan Add exclusion filter Mustasno filtrni qoshmoq Add inclusion filter Faol filtrni qoshmoq Existing filters Qoshimcha filtrlar Cancel changes Ozgarishlarni bekor qilmoq Save current preferences as default values Joriy sozlanmani odatiy tarzda saqlamoq Click to confirm Tasdiqlamoq No log files in %s! %s-da log fayl mavjud emas! No 'index.html' file in %s! %s-da index.html fayli mavjud emas! Click to quit WinHTTrack Website Copier WinHTTrack Website Copier dasturidan chiqish View log files Log fayllarni korish Browse HTML start page Boshlangich html sahifani namoyish etmoq End of mirror Kozgu yaratish bajarildi View log files Log fayllarni korish Browse Mirrored Website Kozguni korish New project... Yangi loyiha... View error and warning reports Xatolik va ogohlantirishlar haqidagi hisobotni korish View report Hisobotni korish Close the log file window Log oynasini yopish Info type: Malumot turi: Errors Xatolar Infos Malumot Find Izlash Find a word Sozni izlash Info log file Log-fayl haqida Warning/Errors log file Xatolar/Ogohlatirishlar log fayli Unable to initialize the OLE system OLE tizimiga kirib bolmadi WinHTTrack could not find any interrupted download file cache in the specified folder! WinHTTrack korsatilgan jilddan bekor qilingan yuklama keshini topa olmadi! Could not connect to provider Provayder bilan boglanishning imkoni yoq receive olindi request sorov connect bog'lanish search izlash ready tayyor error xatolik Receiving files.. Fayllar olinmoqda.. Parsing HTML file.. HTML fayli tahlil qilinmoqda... Purging files.. Fayllar ochirilmoqda... Loading cache in progress.. Keshni yuklash ketmoqda.. Parsing HTML file (testing links).. HTML fayli analizlanmoqda (havolalar tekshirilmoqda)... Pause - Toggle [Mirror]/[Pause download] to resume operation Toxtatildi (davomo etish uchun [Kozgu]ni/[Kochirishni toxtatib turish]ni tanlang) Finishing pending transfers - Select [Cancel] to stop now! Kochirishni kechiktirish tugatilmoqda - bekor qilish uchun, Cancelni bosing! scanning tekshirilmoqda Waiting for scheduled time.. Tayinlangan vaqt boshlanishu kutilmoqda.. Connecting to provider Provayder bilan boglanilmoqda [%d seconds] to go before start of operation Boshlanishiga [%d soniya] qoldi Site mirroring in progress [%s, %s bytes] Kozgu yaratilmoqda [%s, %s bayt] Site mirroring finished! Kozgu yaratish bajarildi! A problem occurred during the mirroring operation\n Kochirib olish jarayonida xatolik yuz berdi\n \nDuring:\n Davomida:\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! Agar, zarurat bolsa, log faylni koring.\n\nWinHTTrack chiqish uchun OKni bosing.\n\nWinHTTrackdan foydalanganligingiz uchun tashakkur! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! Kozgu yaratish bajarildi.\nDasturdan chiqish uchun OKni bosing.\nKochirib olish muvaffaqiyatli bajarilganligini korish uchun log fayl(lar)ni koring.\n\nWinHTTrackdan foydalanganligingiz uchun tashakkur! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * KOCHIRIB OLISH BEKOR QILINDI! * *\r\n , , , .\r\n, . , .\r\n( , hts-cache/new.]\r\n\r\n , , ? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * XATOLIK! * *\r\nJoriy kozgu - bosh. Agar yangilanadigan bolsa, oldingi kozgu tiklanadi.\r\nSababi: birinchi sahifa(lar) topilmadi yoki boglanib bolmadi.\r\n=> Veb-saytning mavjudligiga ishonch hosil qiling, /yoki proksi-serverning ornatilganligini tekshiring! <= \n\nTip: Click [View log file] to see warning or error messages \nMaslahat: Xatolik va ogohlantirishlar haqidagi xabarni korish uchun [log faylni korish]ni bosing. Error deleting a hts-cache/new.* file, please do it manually hts-cache/new.* faylini ochirishda xatolik, iltimos, uni ozingiz ochiring.\r\n Do you really want to quit WinHTTrack Website Copier? Siz haqiqatan ham WinHTTrackdan chiqishni xohlaysizmi? - Mirroring Mode -\n\nEnter address(es) in URL box - Kozgulashtirish rejimi -\n\nURL maydoniga manzil(lar)ni kiriting. - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - Interfaol rejimi - 'Wizard' uslubida kozgu yaratish (sorovlar bolishi mumkin) -\n\nURL maydoniga manzil(lar)ni kiriting. - File Download Mode -\n\nEnter file address(es) in URL box - Alohida fayllarni kochirib olish rejimi -\n\nURL maydoniga manzil(lar)ni kiriting. - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - Havolalarni sinash rejimi-\n\nSinab korishni xohlasangiz, URL'lari mavjud sahifa manzilini kiriting. - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Yangilash rejimi -\n\nURL maydonidagi manzil(lar)ni tekshiring, songra 'Keyingi' tugmasini bosing. - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Olding hosil qilingan kozguni davom etirish rejimi -\n\nURL maydonidagi manzil(lar)ni tekshiring, songra 'Keyingi' tugmasini bosing. Log files Path Log fayl yolagi Path Yolak - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror Royxatdan kozgu yaratish rejimi-\n\nKozgu yaratish uchun URL maydoniga manzil(lar), sahifa(lar)ni kiriting. New project / Import? Yangi loyiha / import qilinsinmi? Choose criterion Amalni tanlang Maximum link scanning depth Tekshirish maksimal teranligi Enter address(es) here Manzilni kiriting Define additional filtering rules Qoshimcha filtrni tayinlang Proxy Name (if needed) Proksi nomi, agar kerak bolsa Proxy Port Proksi-server porti raqami Define proxy settings Proksini ornatishni tayinlang Use standard HTTP proxy as FTP proxy HTTP proksini FTP proksiday ishlatish Path Yolak Select Path Yolakni tanlang Path Yolak Select Path Yolakni tanlang Quit WinHTTrack Website Copier WinHTTrack Website Copierdan chiqish About WinHTTrack WinHTTrack dasturi haqida Save current preferences as default values Joriy ornatishni odatiy qilib saqlamoq Click to continue Davom etirmoq Click to define options Kochirish parametrini belgilamoq Click to add a URL URL qoshmoq Load URL(s) from text file Matnli fayldan URL(lar)ni yuklamoq WinHTTrack preferences (*.opt)|*.opt|| WinHTTrack sozlanmalari (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| Manzillar royxati matnli fayli(*.txt)|*.txt|| File not found! Fayl topilmadi! Do you really want to change the project name/path? Loyiha/yolak nomini ozgartirishni xohlaysizmi? Load user-default options? Sukut boyicha ornatish yuklansinmi? Save user-default options? Sozlanmalar saqlansinmi? Reset all default options? Sukut boyicha barcha parametrlar qayta ornatilsinmi? Welcome to WinHTTrack! WinHTTrackga xush kelibsiz! Action: Faoliyatlar turi: Max Depth Maks. teranlik: Maximum external depth: Tashqi saytlarning maksimal teranligi: Filters (refuse/accept links) : Filtrlar (havolalarni yoqmoq/ochirib qoymoq) Paths Yolaklar Save prefs Sozlanmalarni saqlamoq Define.. Belgilamoq... Set options.. Parametrlarni moslamoq... Preferences and mirror options: Kochirib olish parametrlarini moslash: Project name Loyiha nomi Add a URL... URLga qoshmoq... Web Addresses: (URL) Veb manzil: (URL) Stop WinHTTrack? WinHTTrack toxtatilsinmi? No log files in %s! %s da log fayllar yoq! Pause Download? Kochirib olish toxtatib turilsinmi? Stop the mirroring operation Kochirib olishni toxtatish Minimize to System Tray Tizim treyiga berkitmoq Click to skip a link or stop parsing Havolani otkazib yuborish yoki fayl analizini toxtatish Click to skip a link Havolani otkazib yuborish Bytes saved Saqlangan bayt: Links scanned Tekshirilgan havolalar: Time: Vaqt: Connections: Boglanish: Running: Holati: Hide Berkitmoq Transfer rate Kochirib olish tezligi: SKIP OTKAZIB YUBORISH Information Ma'lumot Files written: Saqlangan fayllar: Files updated: Yangilangan fayllar: Errors: Xatoliklar: In progress: Prossesda: Follow external links Tashqi havoladan fayllarni olmoq Test all links in pages Sahifadangi barcha fayllarni tekshirmoq Try to ferret out all links Barcha havolalarni aniqlashga harakat qilmoq Download HTML files first (faster) Avval HTML-fayllarni kochirib olmoq (tez) Choose local site structure Saytning mahalliy strukturasini tanlamoq Set user-defined structure on disk Tayinlangan saytning mahalliy strukturasini ornatmoq Use a cache for updates and retries Do not update zero size or user-erased files , , Create a Start Page Boshlangich sahifani yaratmoq Create a word database of all html pages , html- Create error logging and report files Generate DOS 8-3 filenames ONLY DOS- 8.3 Generate ISO9660 filenames ONLY for CDROM medias ISO9660 CDROM Do not create HTML error pages html-xatoliklari fayllarini yozmaslik Select file types to be saved to disk Diskka saqlash uchun fayl turini tanlang Select parsing direction Select global parsing direction Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) () ( ) Max simultaneous connections File timeout Cancel all links from host if timeout occurs Minimum admissible transfer rate Cancel all links from host if too slow , , Maximum number of retries on non-fatal errors , . Maximum size for any single HTML file html- Maximum size for any single non-HTML file HTML- Maximum amount of bytes to retrieve from the Web , Make a pause after downloading this amount of bytes , Maximum duration time for the mirroring operation . Maximum transfer rate . Maximum connections/seconds (avoid server overload) . ( ) Maximum number of links that can be tested (not saved!) (, !) Browser identity ( User-Agent) Comment to be placed in each HTML file , HTML Back to starting page Boshlangich sahifaga otish Save current preferences as default values Click to continue Davom etmoq Click to cancel changes Ozgarishlarni bekor qilish Follow local robots rules on sites , Links to non-localised external pages will produce error pages ( ) Do not erase obsolete files after update Accept cookies? cookies? Check document type when unknown? , ? Parse java applets to retrieve included files that must be downloaded? - ? Store all files in cache instead of HTML only , HTML Log file type (if generated) log Maximum mirroring depth from root address . Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) / (0, .., , ) Create a debugging file Use non-standard requests to get round some server bugs , Use old HTTP/1.0 requests (limits engine power!) HTTP/1.0 ( !) Attempt to limit retransfers through several tricks (file size test..) ( ..) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) , (www.foo.com==foo.com, http=https ..) Write external links without login/password / Write internal links without query string ( ?) Get non-HTML files related to a link, eg external .ZIP or pictures html fayllarga yaqin bolmagan havolalarni kochirib olmaslik (msln.: tashqi .ZIP yoki graf. fayllar) Test all links (even forbidden ones) Barcha havolalarni sinab kormoq (hatto taqiqlanganlarini ham) Try to catch all URLs (even in unknown tags/code) URL' ( /) Get HTML files first! HTML ! Structure type (how links are saved) ( ) Use a cache for updates Do not re-download locally erased files Make an index Indeks yaratmoq Make a word database Soz bazasini yaratmoq Log files Log fayllar DOS names (8+3) DOS-fayllar formati (8+3) ISO9660 names (CDROM) ISO9660 standartidagi nomlar (CDROM) No error pages Xatosiz sahifalar Primary Scan Rule Asosiy filtr Travel mode Tekshirish rejimi Global travel mode Global tekshiruv rejimi These options should be modified only exceptionally , Activate Debugging Mode (winhttrack.log) Tuzatish rejimini yoqmoq (winhttrack.log) Rewrite links: internal / external Havolalarni qayta nomlamoq: ichki/tashqi Flow control Tekshrish yonalishi nazorati Limits Cheklovlar Identity Identifikator HTML footer Quyi HTML kolontitul N# connections N# boglanish Abandon host if error , Minimum transfer rate (B/s) (B/s) Abandon host if too slow , Configure Moslamoq Use proxy for ftp transfers ftp- TimeOut(s) Taym-out Persistent connections (Keep-Alive) (Keep-Alive) Reduce connection time and type lookup time using persistent connections Retries Size limit Max size of any HTML file (B) . html-: Max size of any non-HTML file . -html: Max site size . Max time . Save prefs Sozlanmani saqlash Max transfer rate . Follow robots.txt robots.txt No external pages Tashqi havolalarsiz Do not purge old files Accept cookies cookies Check document type Parse java files Store ALL files in cache Tolerant requests (for servers) ( ) Update hack (limit re-transfers) Update hack ( ) URL hacks (join similar URLs) URL ( URLs) Force old HTTP/1.0 requests (no 1.1) HTTP/1.0 ( 1.1) Max connections / seconds . /. Maximum number of links Pause after downloading.. ... Hide passwords Parollarni berkitmoq Hide query strings (, ?) Links Havolalar Build Experts Only Flow Control Limits Browser ID Scan Rules Spider Log, Index, Cache , . Proxy MIME Types MIME Types ( ) Do you really want to quit WinHTTrack Website Copier? ? Do not connect to a provider (already connected) ( ) Do not use remote access connection Schedule the mirroring operation Quit WinHTTrack Website Copier WinHTTrack Website Copier Back to starting page Click to start! Start! No saved password for this connection! Can not get remote connection settings Select a connection provider , Start Boshlamoq Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. , , Save settings only, do not launch download now. , . On hold Transfer scheduled for: (hh/mm/ss) : (hh/mm/ss) Start ! Connect to provider (RAS) (RAS) Connect to this provider Disconnect when finished Disconnect modem on completion \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n( )\r\n\r\n:\r\n (Windows): Xavier Roche\r\n (spider): Xavier Roche\r\n -: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for Russian translations to:\r\nAndrei Iliev (andreiiliev@mail.ru) About WinHTTrack Website Copier WinHTTrack Website Copier Please visit our Web page , - Wizard query Your answer: Javobingiz: Link detected.. .. Choose a rule Qoidani tanlang Ignore this link Ignore directory Ignore domain Catch this page only Mirror site Mirror domain Ignore all Wizard query NO YOQ File Fayl Options Tanlovlar Log Log Window Oyna Help Yordam Pause transfer Exit Chiqish Modify options View log Logni kormoq View error log Log xatolarni kormoq View file transfers Fayllarni uzatish prossesini kormoq Hide Berkitmoq About WinHTTrack Website Copier Dastur haqida... Check program updates... ... &Toolbar Uskunalar paneli &Status Bar Holat paneli S&plit Ajratmoq File Fayl Preferences Sozlanmalar Mirror Kozgu Log Log Window Help Exit Load default options Save default options Reset to default options Load options... ... Save options as... ... Language preference... Tilni tanlash Contents... Mundarija... About WinHTTrack... WinHTTrack haqida... New project\tCtrl+N Yangi loyiha\tCtrl+N &Open...\tCtrl+O &Ochmoq...\tCtrl+O &Save\tCtrl+S &Saqlamoq\tCtrl+S Save &As... Quyidagidek &saqlamoq... &Delete... &Ochirmoq... &Browse sites... &Saytlarni korish... User-defined structure %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\t (.: image)\r\n%N\t (.: image.gif)\r\n%t\t (.: gif)\r\n%p\t [ /] (.: /someimages)\r\n%h\t (.: www.someweb.com)\r\n%M\tURL MD5 (128 bits, 32 ascii bytes)\r\n%Q\tquery string MD5 (128 bits, 32 ascii bytes)\r\n%q\tsmall query string MD5 (16 bits, 4 ascii bytes)\r\n\r\n%s?\tDOS' (: %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Masalan:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Proxy settings Proksini moslash Proxy address: Proksi manzili: Proxy port: Port raqami: Authentication (only if needed) ( ) Login Login Password Parol Enter proxy address here Enter proxy port here Enter proxy login Enter proxy password Enter project name here Enter saving path here Select existing project to update , Click here to select path Select or create a new category name, to sort your mirrors in categories HTTrack Project Wizard... HTTrack loyiha yaratuvchisi... New project name: Yangi loyiha nomi: Existing project name: Mavjud loyiha nomi: Project name: Loyiha nomi: Base path: Jild: Project category: Loyiha kategoriyasi: C:\\My Web Sites C:\\Veb saytlarim Type a new project name, \r\nor select existing project to update/resume Yangi loyiha nomini kiriting, \r\nyoki mavjud loyihani yangilash/davom etirish uchun tanlang New project Yangi loyiha Insert URL URLni qoymoq URL: URL: Authentication (only if needed) Autentifikatsiya (agar kerak bolsa) Login Login: Password Parol: Forms or complex links: Murakkab havolalar: Capture URL... URL... Enter URL address(es) here URL manzilni kiriting Enter site login Enter site password Use this capture tool for links that can only be accessed through forms or javascript code URL (javascript, ..) Choose language according to preference Catch URL! URLni tuting! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. .\n, ( , ..) . This will send the desired link from your browser to WinHTTrack. HTTrack. ABORT Bekor qilmoq Copy/Paste the temporary proxy parameters here Vaqtinchalik proksi sozlamasini nusxalamoq/qoymoq Cancel Bekor qilmoq Unable to find Help files! ! Unable to save parameters! Parametrlarni saqlashning imkoni yoq! Please drag only one folder at a time Iltimos, faqat bitta jildni surib olib keling Please drag only folders, not files Iltimos, faqat fayllarni jildni surib olib keling, fayllarni emas Please drag folders only Iltimos, faqat jildlarni surib olib keling Select user-defined structure? ? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! , , , Do you really want to use a user-defined structure? ? Too manu URLs, cannot handle so many links!! URL', ! Not enough memory, fatal internal error.. Xotira yetarli emas, jiddiy ichki xatolik... Unknown operation! Noma'lum operatsiya Add this URL?\r\n Ushbu URL qoshilsinmi?\r\n Warning: main process is still not responding, cannot add URL(s).. Diqqat: sorovlarga javob bermayapti, URLlarni qoshishning imkoni yoq... Type/MIME associations (Type/MIME) File types: Fayl turlari: MIME identity: MIME identity Select or modify your file type(s) here Select or modify your MIME type(s) here Fayllar turini tanlamoq yoki ozgartirmoq Go up Yuqoriga Go down Pastga File download information Yuklab olingan fayl haqida Freeze Window Oynani qotirib qoymoq More information: Qoshimcha malumot: Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download WinHTTrack Website Copier!\n\n , \n\n- \n- File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS :\n , :\n :\n :\n :\n :\n , :\n :\n :\n :\n Show all\nHide debug\nHide infos\nHide debug and infos \n \n \n Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. ( )\nHtml/, / / /\nHtml/html, / / \nHtml/, / /\nHtml/, / /xxx, xxx - \nHtml, / /xxx\n www.domain.xxx/\nHtml site_name/ / site_name/ /\nHtml site_name/html, / site_name/ \nHtml site_name/, / site_name/\nHtml site_name/, / site_name/xxx\nHtml site_name/html, / site_name/xxx\n /, ( !)\n site_name/, ( !)\n ... Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first \n html \n html \n ( )\n html Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down \n ( )\n \n Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web ( )\n \n \n Never\nIf unknown (except /)\nIf unknown Hech qachon\nAgar noma'lum bolsa (/ dan boshqasi)\nAgar noma'lum bolsa no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules robots.txt\nrobots.txt \n robots.txt normal\nextended\ndebug Odatiy\nkengaytirilgan\ntuzatish Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download Sayt(lar)ni kochirib olish\nSayt(lar)ni kochirib olmoq +savollar\nAlohida fayllarni yuklab olmoq\nBarcha saytlarni sahifalari bilan kochirib olish (bir necha kozgu)\nHavolalarni sahifasi bilan sinamoq (xatchop testi)\n* Toxtatilganni davom etirmoq\n* Mavjud yuklamani yangilamoq Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL URI / URL ( )\n URL / URL\n URI / URL\n URL / URL Open Source offline browser Open Source offlayn brauzer Website Copier/Offline Browser. Copy remote websites to your computer. Free. Veb-saytlarni oluvchi/Offlayn brauzer. Kompyuteringizga veb-saytlarni kochirib beradi. Bepul. httrack, winhttrack, webhttrack, offline browser httrack, winhttrack, webhttrack, offline browser URL list (.txt) URLlar royxati (.txt) Previous Ortga Next Keyingi URLs URLs Warning Ogohlatirish Your browser does not currently support javascript. For better results, please use a javascript-aware browser. javascript . javascript. Thank you Rahmat You can now close this window Endi bu oynani yopsangiz boladi Server terminated Server terminated A fatal error has occurred during this mirror Joriy kochirish vaqtida jiddiy xatolik yuz berdi httrack-3.49.5/lang/Ukrainian.txt0000644000175000017500000010473214360553245013616 00000000000000LANGUAGE_NAME Ukrainian LANGUAGE_FILE Ukrainian LANGUAGE_ISO uk LANGUAGE_AUTHOR Andrij Shevchuk (http://programy.com.ua, http://vic-info.com.ua) \r\n LANGUAGE_CHARSET ISO-8859-5 LANGUAGE_WINDOWSID Ukrainian OK Cancel Exit Close Cancel changes Click to confirm ϳ Click to get help! Click to return to previous screen Click to go to next screen Hide password Save project Close current project? ? Delete this project? ? Delete empty project %s? %s? Action not yet implemented Error deleting this project Select a rule for the filter Enter keywords for the filter Cancel Add this rule Please enter one or several keyword(s) for the rule Add Scan Rule Criterion : String : Add Scan Rules Գ Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi / \n .\n: +*.zip -www.*.com,-www.*.edu/cgi-bin/*.cgi Exclude links ... Include link(s) ... Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) : gif-, , , +www.someweb.com/*.gif. \n(+*.gif / -*.gif / Ѳ gif- Ѳ ) Save prefs Matching links will be excluded: ˳, : Matching links will be included: ˳, : Example: : gif\r\nWill match all GIF files gif\r\n gif ( GIF) blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' blue\r\n, 'blue', 'bluesky-small.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' bigfile.mov\r\n'bigfile.mov', , , 'bigfile2.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\n , 'cgi', /cgi-bin/somecgi.cgi cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\n , 'cgi-bin' ( cgi-bin-2, ) someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb.com\r\n , www.someweb.com, private.someweb.com ... someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. someweb\r\n www.someweb.com, www.someweb.edu, private.someweb.otherweb.com ..\r\n www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.someweb.com\r\n , www.someweb.com/... ( , private.someweb.com/..) someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. someweb\r\n , www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html .. www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/someweb.html\r\n www.test.com/test/someweb.html. , - (www.xxx.yyy) (/test/someweb.html) All links will match Add exclusion filter , Add inclusion filter , Existing filters Cancel changes Save current preferences as default values Click to confirm ϳ No log files in %s! ³ %s! No 'index.html' file in %s! index.html %s! Click to quit WinHTTrack Website Copier WinHTTrack Website Copier View log files Browse HTML start page ³ html End of mirror View log files log Browse Mirrored Website New project... ... View error and warning reports View report Close the log file window Info type: Errors Infos Find Find a word Info log file - Warning/Errors log file / Unable to initialize the OLE system OLE WinHTTrack could not find any interrupted download file cache in the specified folder! WinHTTrack ! Could not connect to provider ' receive request connect ' search ready error Receiving files.. Parsing HTML file.. HTML ... Purging files.. ... Loading cache in progress.. Parsing HTML file (testing links).. HTML ( )... Pause - Toggle [Mirror]/[Pause download] to resume operation ( []/[ ] ) Finishing pending transfers - Select [Cancel] to stop now! - , ! scanning Waiting for scheduled time.. Connecting to provider ' [%d seconds] to go before start of operation [%d ] Site mirroring in progress [%s, %s bytes] [%s, %s ] Site mirroring finished! ! A problem occurred during the mirroring operation\n \n \nDuring:\n :\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! , .\n\n WinHTTrack OK.\n\n WinHTTrack! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! .\n OK.\n ().\n\n WinHTTrack! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * ! * *\r\n , , , .\r\n, . , .\r\n( , hts-cache/new.]\r\n\r\n , , ? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * ! * *\r\n - . , .\r\n: () , '.\r\n=> , , / -! <= \n\nTip: Click [View log file] to see warning or error messages \n: [ ] Error deleting a hts-cache/new.* file, please do it manually hts-cache/new.* , , .\r\n Do you really want to quit WinHTTrack Website Copier? WinHTTrack? - Mirroring Mode -\n\nEnter address(es) in URL box - -\n\n () URL. - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - - ( ) -\n\n () URL. - File Download Mode -\n\nEnter file address(es) in URL box - -\n\n () URL. - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - -\n\n () , URL', . - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - -\n\n () URL, '˲' . - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - -\n\n () URL, '˲' . Log files Path Path - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror -\n\n URL , URL', . New project / Import? / ? Choose criterion Maximum link scanning depth . Enter address(es) here Define additional filtering rules Proxy Name (if needed) , Proxy Port - Define proxy settings Use standard HTTP proxy as FTP proxy HTTP FTP Path Select Path Path Select Path Quit WinHTTrack Website Copier WinHTTrack Website Copier About WinHTTrack WinHTTrack Save current preferences as default values Click to continue Click to define options Click to add a URL URL Load URL(s) from text file URL() WinHTTrack preferences (*.opt)|*.opt|| WinHTTrack (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| (*.txt)|*.txt|| File not found! ! Do you really want to change the project name/path? /? Load user-default options? ? Save user-default options? ? Reset all default options? ? Welcome to WinHTTrack! WinHTTrack ! Action: : Max Depth . : Maximum external depth: : Filters (refuse/accept links) : Գ (/ ) Paths Save prefs Define.. ... Set options.. ... Preferences and mirror options: :: Project name Add a URL... URL ... Web Addresses: (URL) : (URL) Stop WinHTTrack? WinHTTrack? No log files in %s! %s! Pause Download? ? Stop the mirroring operation Minimize to System Tray Click to skip a link or stop parsing Click to skip a link Bytes saved : Links scanned : Time: : Connections: ': Running: : Hide Transfer rate : SKIP Information Files written: : Files updated: : Errors: : In progress: : Follow external links Test all links in pages Try to ferret out all links Download HTML files first (faster) HTML- () Choose local site structure Set user-defined structure on disk Use a cache for updates and retries Do not update zero size or user-erased files , , Create a Start Page Create a word database of all html pages html Create error logging and report files Generate DOS 8-3 filenames ONLY DOS- 8.3 Generate ISO9660 filenames ONLY for CDROM medias ISO9660 CDROM Do not create HTML error pages Generate ISO9660 filenames ONLY for CDROM medias Select file types to be saved to disk , Select parsing direction Select global parsing direction Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) Max simultaneous connections ' File timeout Cancel all links from host if timeout occurs Minimum admissible transfer rate ̳ Cancel all links from host if too slow , , Maximum number of retries on non-fatal errors , . Maximum size for any single HTML file - html- Maximum size for any single non-HTML file - HTML- Maximum amount of bytes to retrieve from the Web , Make a pause after downloading this amount of bytes ϳ , Maximum duration time for the mirroring operation . Maximum transfer rate . Maximum connections/seconds (avoid server overload) . ' ( ) Maximum number of links that can be tested (not saved!) , ( !) Browser identity ( User-Agent) Comment to be placed in each HTML file , HTML Back to starting page Save current preferences as default values Click to continue Click to cancel changes Follow local robots rules on sites ϳ , Links to non-localised external pages will produce error pages ( ) Do not erase obsolete files after update Accept cookies? cookies? Check document type when unknown? , ? Parse java applets to retrieve included files that must be downloaded? java- ? Store all files in cache instead of HTML only , HTML Log file type (if generated) log Maximum mirroring depth from root address . Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) / (0, , , -) Create a debugging file Use non-standard requests to get round some server bugs , Use old HTTP/1.0 requests (limits engine power!) HTTP/1.0 ( !) Attempt to limit retransfers through several tricks (file size test..) ( ..) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Write external links without login/password / Write internal links without query string ( ?) Get non-HTML files related to a link, eg external .ZIP or pictures -html (.: .ZIP . ) Test all links (even forbidden ones) ( ) Try to catch all URLs (even in unknown tags/code) URL' ( /) Get HTML files first! HTML ! Structure type (how links are saved) ( ) Use a cache for updates Do not re-download locally erased files Make an index Make a word database Log files Log DOS names (8+3) DOS (8+3) ISO9660 names (CDROM) ISO9660 (CDROM) No error pages Primary Scan Rule Travel mode Global travel mode These options should be modified only exceptionally , Activate Debugging Mode (winhttrack.log) (winhttrack.log) Rewrite links: internal / external : / Flow control Limits Identity HTML footer HTML N# connections N# ' Abandon host if error , Minimum transfer rate (B/s) ̳ (B/s) Abandon host if too slow , Configure Use proxy for ftp transfers ftp- TimeOut(s) - Persistent connections (Keep-Alive) Reduce connection time and type lookup time using persistent connections Retries Size limit Max size of any HTML file (B) . html-: Max size of any non-HTML file . -html: Max site size . Max time . Save prefs Max transfer rate . Follow robots.txt robots.txt No external pages Do not purge old files Accept cookies cookies Check document type Parse java files java Store ALL files in cache Ѳ Tolerant requests (for servers) ( ) Update hack (limit re-transfers) Update hack ( ) URL hacks (join similar URLs) Force old HTTP/1.0 requests (no 1.1) HTTP/1.0 ( 1.1) Max connections / seconds . '/. Maximum number of links Pause after downloading.. ... Hide passwords Hide query strings (, ?) Links ˳ Build Experts Only Flow Control Limits Browser ID Scan Rules Գ Spider Log, Index, Cache , . Proxy MIME Types Do you really want to quit WinHTTrack Website Copier? ? Do not connect to a provider (already connected) ' (' ) Do not use remote access connection ' Schedule the mirroring operation Quit WinHTTrack Website Copier WinHTTrack Website Copier Back to starting page Click to start! ! No saved password for this connection! ' Can not get remote connection settings ' Select a connection provider , ' Start Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. , , ' Save settings only, do not launch download now. ҳ , . On hold Transfer scheduled for: (hh/mm/ss) : (hh/mm/ss) Start ! Connect to provider (RAS) ' (RAS) Connect to this provider ' Disconnect when finished ³' Disconnect modem on completion ³' \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n( )\r\n\r\n:\r\n (Windows): Xavier Roche\r\n (spider): Xavier Roche\r\n java-: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for Ukrainian translations to:\r\nAndrij Shevchuk (andrijsh@mail.lviv.ua) http://programy.com.ua, http://vic-info.com.ua About WinHTTrack Website Copier WinHTTrack Website Copier Please visit our Web page , Wizard query Your answer: : Link detected.. Choose a rule Ignore this link Ignore directory Ignore domain Catch this page only Mirror site Mirror domain Ignore all Wizard query NO Ͳ File Options Log Window ³ Help Pause transfer Exit Modify options View log View error log View file transfers Hide About WinHTTrack Website Copier ... Check program updates... ... &Toolbar &Status Bar S&plit File Preferences Mirror Log Window ³ Help Exit Load default options Save default options Reset to default options Load options... ... Save options as... ... Language preference... Contents... ... About WinHTTrack... WinHTTrack... New project\tCtrl+N \tCtrl+N &Open...\tCtrl+O &³...\tCtrl+O &Save\tCtrl+S &\tCtrl+S Save &As... &... &Delete... &... &Browse sites... & ... User-defined structure %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\t (: image)\r\n%N\t (.: image.gif)\r\n%t\tҳ (.: gif)\r\n%p\t [ /] (.: /someimages)\r\n%h\t (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\t (: %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif :\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Proxy settings Proxy address: : Proxy port: : Authentication (only if needed) ii ( ) Login i Password Enter proxy address here Enter proxy port here Enter proxy login Enter proxy password Enter project name here ' Enter saving path here Select existing project to update , Click here to select path Select or create a new category name, to sort your mirrors in categories HTTrack Project Wizard... HTTrack... New project name: ' : Existing project name: ' : Project name: ' : Base path: : Project category: C:\\My Web Sites C:\\ Web Type a new project name, \r\nor select existing project to update/resume , \r\n / New project Insert URL URL URL: : Authentication (only if needed) ( ) Login : Password : Forms or complex links: : Capture URL... URL... Enter URL address(es) here URL Enter site login Enter site password Use this capture tool for links that can only be accessed through forms or javascript code URL (javascript, ..) Choose language according to preference Catch URL! ϳ URL! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. .\n, 䳿 ( , ..) . This will send the desired link from your browser to WinHTTrack. HTTrack. ABORT Copy/Paste the temporary proxy parameters here / Cancel Unable to find Help files! ! Unable to save parameters! ! Please drag only one folder at a time , Please drag only folders, not files , , Please drag folders only , Select user-defined structure? ? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! , , , Do you really want to use a user-defined structure? ? Too manu URLs, cannot handle so many links!! URL', ! Not enough memory, fatal internal error.. ', ... Unknown operation! Add this URL?\r\n URL?\r\n Warning: main process is still not responding, cannot add URL(s).. : , URL'... Type/MIME associations ³ (Type/MIME) File types: : MIME identity: MIME identity Select or modify your file type(s) here Select or modify your MIME type(s) here Go up Go down File download information Freeze Window More information: : Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download WinHTTrack Website Copier!\n\n- ˲ , \n\n- \n- File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS :\n , :\n :\n :\n :\n :\n , :\n :\n :\n :\n ˲ Show all\nHide debug\nHide infos\nHide debug and infos \n \n \n Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. ( )\nHtml/, / / /\nHtml/html, / / \nHtml/, / /\nHtml/, / /xxx, xxx - \nHtml, / /xxx\n www.domain.xxx/\nHtml site_name/ / site_name/ /\nHtml site_name/html, / site_name/ \nHtml site_name/, / site_name/\nHtml site_name/, / site_name/xxx\nHtml site_name/html, / site_name/xxx\n /, ( !)\n site_name/, ( !)\n ... Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first ҳ \n html \n html \n ( )\n html Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down \n ( )\n \n Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web ( )\n \n \n Never\nIf unknown (except /)\nIf unknown ͳ\n ( /)\n no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules robots.txt\nrobots.txt \n robots.txt normal\nextended\ndebug \n\n Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download ()\n () + \n \n \n \n* \n* Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL ³ URI / URL (default)\n URL / URL\n URI / URL\n URL / URL Open Source offline browser Website Copier/Offline Browser. Copy remote websites to your computer. Free. httrack, winhttrack, webhttrack, offline browser URL list (.txt) Previous Next URLs Warning Your browser does not currently support javascript. For better results, please use a javascript-aware browser. Thank you You can now close this window Server terminated A fatal error has occurred during this mirror httrack-3.49.5/lang/Turkish.txt0000644000175000017500000010576614360553245013336 00000000000000LANGUAGE_NAME Turkish LANGUAGE_FILE Turkish LANGUAGE_ISO tr LANGUAGE_AUTHOR Arman (Armish) Aksoy \r\n LANGUAGE_CHARSET ISO-8859-9 LANGUAGE_WINDOWSID Turkish OK Tamam Cancel Vazge Exit k Close Kapat Cancel changes Deiikleri Kaydetme Click to confirm Onaylamak iin Tklayn Click to get help! Yardm almak iin Tklayn Click to return to previous screen nceki ekrana dnmek iin tklayn Click to go to next screen Sonraki ekrana gitmek iin tklayn Hide password Parolay Gizle Save project Projeyi Kaydet Close current project? Ak proje kapatlsn m? Delete this project? Bu proje silinsin mi? Delete empty project %s? %s bo projesi silinsin mi? Action not yet implemented Eylem henz uygulanmad Error deleting this project Bu proje silinirken hata olutu Select a rule for the filter Filtre iin bir kural sein Enter keywords for the filter Filtre iin anahtar kelimeleri giriniz Cancel Vazge Add this rule Bu kural ekle Please enter one or several keyword(s) for the rule Ltfen bu kural iin bir veya daha fazla anahtar kelime giriniz Add Scan Rule Tarama Kural Ekle Criterion Kriter String Dizim Add Ekle Scan Rules Kurallar Tara Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Adresleri veya balantlar almak veya almamak iin zel sembolleri kullann.\n Bir satrda birden ok kelime kullanabilirsiniz.\nAyra olarak boluk kullann.\n\nrnek: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Exclude links Balantlar Alma Include link(s) Balantlar Al Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) pucu: Bir sitedeki tm GIF dosyalarn almak iin, +www.siteniz.com/*.gif benzeri birey kullanabilirsiniz. \n(+*.gif / -*.gif ile sitedeki GIF dosyalarnn alnp alnmayacan belirtebilirsiniz) Save prefs Ayarlar kaydet Matching links will be excluded: Eleen bu balantlar alnmayacaktr:: Matching links will be included: Eleen bu balantlar alnacaktr: Example: rnek: gif\r\nWill match all GIF files gif\r\nTm GIF dosyalarn eletirecektir blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' mavi\r\nTm kelimeleri ve ierdiklerini 'mavi' adl kelimeyle karlatracaktr, mesela 'mavigokyuzu.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' buyukdosya.mov\r\nBu aramada 'buyukdosya.mov' eleecektir fakat 'buyukdosya2.mov' elemeyecektir cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\n'cgi' kelimesiyle eleen tm balantlar bulacaktr, mesela '/cgi-bin/somecgi.cgi' cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\n'cgi-bin' ile eleen tm dizin balantlarn bulacaktr, fakat 'cgi-bin-2' gibi bir kelime bu aramada elemez someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. siteniz.com\r\n'siteniz.com' ieren tm balantlar bulacaktr, mesela 'www.siteniz.com', 'ozel.siteniz.com' someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. siteniz\r\n'siteniz' kelimesini ieren tm balantlar bulacaktr, mesela 'www.siteniz.com', 'ozel.siteniz.com', 'www.siteniz.edu' www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.siteniz.com\r\n'www.siteniz.com' ieren tm adresleri bulacaktr, ama mesela 'ozel.siteniz.com' bu aramada elemeyecektir someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. siteniz\r\n'siteniz' ile eleen tm alt ve ana balantlar bulacaktr, mesela www.siteniz.com/blabla, www.deneme.abc/sitenizden/, wwww.deneme.com/siteniz.html www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.deneme.com/deneme/adres.html\r\nSadece 'www.deneme.com/deneme/adres.html' dosyasnz bulur. Bunun iin tam adresi (Site adresi + site konumu) girmeniz gerektiini unutmaynz All links will match Btn balantlar eletirilecek Add exclusion filter Alnmayacaklar iin filtre ekle Add inclusion filter Alnacaklar iin filtre ekle Existing filters Filtreler Cancel changes Deiiklikleri kaydetme Save current preferences as default values uanki ayarlar ntanml ayarlar olarak ata Click to confirm Onaylamak iin tklayn No log files in %s! %s iinde kayt dosyas yok!! No 'index.html' file in %s! %s iinde 'index.html' yok! Click to quit WinHTTrack Website Copier WinHTTrack Website Copier'dan kmak iin tklayn View log files Kayt dosyalarn grntle Browse HTML start page HTML balang sayfasn tarat End of mirror Yans Sonu View log files Kayt Dosyalarn Gster Browse Mirrored Website Web Sitesinin Yanssn Tara New project... Yeni proje... View error and warning reports Hata ve uyar raporlarn gster View report Raporu gster Close the log file window Kayt Dosya Penceresini Kapat Info type: Bilgi tipi: Errors Hatalar Infos Bilgiler Find Bul Find a word Szck bul Info log file Bilgi kayt dosyas Warning/Errors log file Uyar/Hata kayt dosyas Unable to initialize the OLE system OLE sistemi yklenemiyor WinHTTrack could not find any interrupted download file cache in the specified folder! WinHTTrack belirtilen dizinde hi indirilirken kesilmi dosya kayd bulamad! Could not connect to provider Servis salaycsna balanlamyor receive al request iste connect balan search ara ready hazr error hata Receiving files.. Dosyalar alnyor.. Parsing HTML file.. HTML dosyas ayklanyorr.. Purging files.. Dosyalar temizleniyor.. Loading cache in progress.. nbellek ykleniyor.. Parsing HTML file (testing links).. HTML dosyas ayklanyor (balantlar kontrol ediliyor).. Pause - Toggle [Mirror]/[Pause download] to resume operation Duraklat - leme devam etmek iin [Yans]/[ndirmeyi duraklat]'a gein Finishing pending transfers - Select [Cancel] to stop now! Bekleyen transferler sonlandrlyor - Durdurmak iin [ptal]'i sein! scanning Waiting for scheduled time.. Planlanan zaman bekleniyor.. Connecting to provider Servis salaycya balanyor [%d seconds] to go before start of operation leme balamaya [%d saniye] Site mirroring in progress [%s, %s bytes] Sitenin yanss alnyor [%s, %s bayt] Site mirroring finished! Sitenin yanss alnd! A problem occurred during the mirroring operation\n Yans ilemi srasnda bir hata olutu\n \nDuring:\n \nSresince:\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! \nEer gerekliyse kayt dosyasna bakabilirsiniz.\n\nWinHTTrack Website Copier'den kmak iin BTR'e tklayn.\n\nWinHTTrack kullandnz iin teekkrler! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! Yans ilemi tamamland.\nWinHTTrac'dan kmak iin k'a tklayn.\nHereyin dzgn yapldndan emin olmak iin kayt dosyasna bakabilirsiniz.\n\nWinHTTrack kullandnz iin teekkrler! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * YANSI LEM PTAL EDLD! * *\r\nHerhangi bir gncelleme ilemi iin uanki geici kaytlar gereklidir ve bu kaytlar indirilen dosyalar tutarlar.\r\nBiimlendirilmi kayt daha fazla bilgi ierebilir; eer bu bilgiyi kaybetmek istemiyorsanz, bu kayd yedekleyebilir ve geici olann silebilirsiniz.\r\n[Not: Bu ilemi hts-cache/new.* dosyalarn silerek kolaylkla yapabilirsiniz]\r\n\rBiimlendirilmi kayd geri almak istiyor musunuz? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * YANSI LEM HATASI! * *\r\nHTTrack kullanlan yansnn bo olduunu tespit etti. Eer bu bir gncelleme ise, nceki yans geri alnabilir.\r\nNeden: balang sayfa(lar) bulunamad veya bir balant problemi olutu.\r\n=> Web sitesinin olup olmadn ve vekil sunucu ayarlarnz kontrol edin! <= \n\nTip: Click [View log file] to see warning or error messages \n\pucu: Hata ve uyar mesajlarn grmek iin [Kayt dosyasn gster]'e tklaynn Error deleting a hts-cache/new.* file, please do it manually hts-cache/new.* dosyalar silinirken hata olutu, ltfen bunu kendiniz yapn Do you really want to quit WinHTTrack Website Copier? WinHTTrack Website Copier'dan kmak istediine emin misiniz?? - Mirroring Mode -\n\nEnter address(es) in URL box - Yans Modu -\n\nAdresleri URL kutusuna giriniz - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - Etkileimli Sihirbaz Modu (sorular) -\n\nAdresleri URL kutusuna giriniz - File Download Mode -\n\nEnter file address(es) in URL box - Dosya ndirme Modu -\n\nAdresleri URL kutusuna giriniz - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - Link Test Modu -\n\nWeb adreslerini balantlarla birlikte test etmek iin URL kutusuna giriniz - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Gncelleme Modu -\n\nURL kutusundaki adresli onaylayn, eer gerekli ise parametreleri kontrol edip 'LER' tuuna tklayn - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Devam Modu (Kesilmi lem) -\n\n\URL kutusundaki adresli onaylayn, eer gerekli ise parametreleri kontrol edip 'LER' tuuna tklayn Log files Path Kay dosyalar konumu Path Konum - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror -Balant Listeleme Modu -\n\nYanslanacak sayfalarn adreslerini URL kutusuna giriniz New project / Import? Yeni Proje / Aktarlsn m? Choose criterion Kriter seiniz Maximum link scanning depth Maksimum balant arama derinlii Enter address(es) here Adresleri buraya giriniz Define additional filtering rules Ek filtre kurallar tanmla Proxy Name (if needed) Vekil Sunucu Ad (gerekli ise) Proxy Port Vekil Sunucu Portu Define proxy settings Vekil sunucu ayarlarn tanmlayn Use standard HTTP proxy as FTP proxy FTP Vekil sunucusu iin ntanml HTTP sunucusunu kullan Path Konum Select Path Konum Se Path Konum Select Path Konum Se Quit WinHTTrack Website Copier WinHTTrack Website Copier'den k About WinHTTrack WinHTTrack Hakknda Save current preferences as default values uanki ayarlar ntanml deerler olarak kaydet Click to continue Devam etmek iin tklayn Click to define options zellikleri tanmlamak iin tklayn Click to add a URL URL eklemek iin tklayn Load URL(s) from text file URLleri metin dosyasndan ykle WinHTTrack preferences (*.opt)|*.opt|| WinHTTrack ayarlar (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| Adres Listesi metin dosyas (*.txt)|*.txt|| File not found! Dosya bulunamad! Do you really want to change the project name/path? Proje adn/konumunu deitirmek istediinizden emin misiniz? Load user-default options? Kullanc-tanml ayarlar yklensin mi? Save user-default options? Kullanc-tanml ayarlar kaydedilsin mi? Reset all default options? ntanml ayarlar sfrlansn m? Welcome to WinHTTrack! WinHTTrack'a Hogeldiniz! Action: Eylem: Max Depth Max Derinlik Maximum external depth: Maximum harici derinlik: Filters (refuse/accept links) : Filtreler (red/kabul edilen balantlar) : Paths Konumlar Save prefs zellikleri Kaydet Define.. Tanmla.. Set options.. Ayarlar.. Preferences and mirror options: Ayarlar ve yans seenekleri: Project name Proje ad Add a URL... URL ekle... Web Addresses: (URL) Web Adresleri: (URL) Stop WinHTTrack? WinHTTrack Durdurulsun mu? No log files in %s! %s iinde kayt dosyas yok! Pause Download? ndirme duraklatlsn m? Stop the mirroring operation Yans ilemini durdur Minimize to System Tray Sistem ubuuna klt Click to skip a link or stop parsing Balanty gemek iin veya ayklamay durdurmak iin tklayn Click to skip a link Balanty atlamak iin tklayn Bytes saved Bayt kaydedildi Links scanned Link tarand Time: Zaman: Connections: Balantlar: Running: alyor: Hide Gizle Transfer rate Transfer hz SKIP ATLA Information Bilgi Files written: Yazlan dosyalar: Files updated: Gncellenen dosyalar: Errors: Hatalar: In progress: lerleme: Follow external links Alnmayan balantlar izle Test all links in pages Sayfadaki tm balantlar test et Try to ferret out all links Tm balantlar ortaya karmaya al Download HTML files first (faster) ncelikli olarak HTML dosyalarn indir (daha hzl) Choose local site structure Yerel site yaps se Set user-defined structure on disk Diskteki kullanc-tanml yapy ata Use a cache for updates and retries Denemeler ve gncellemer iin bir kayt kullan Do not update zero size or user-erased files Silinen veya bo olan dosyalar gncelleme Create a Start Page Balang Sayfas Yarat Create a word database of all html pages Tm html sayfalarndan bir kelime veritaban yarat Create error logging and report files Hata kayd ve rapor dosyalar yarat Generate DOS 8-3 filenames ONLY Yalnzca DOS 8-3 dosya adlar ret Generate ISO9660 filenames ONLY for CDROM medias Yalnz CDROM lar iin ISO9660 dosya adlar ret Do not create HTML error pages HTML hata sayfalar yaratma Select file types to be saved to disk Diske kaydedilecek dosya tiplerini sein Select parsing direction Ayklama ynlendirmesini sein Select global parsing direction Genel ayklama ynlendirmesini seinr Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) Alnan ve alnmayan dosyalar iin URLleri yeniden yazma amal kurallar hazrla Max simultaneous connections Max simule balant says File timeout Dosya zaman am Cancel all links from host if timeout occurs Eer zaman am yaanrsa sunucudaki tm balantlar iptal et Minimum admissible transfer rate Kabul edilebilen minimum ransfer hz Cancel all links from host if too slow Eer sunucu ok yavasa tm balantlar iptal et Maximum number of retries on non-fatal errors Hata durumunda maksimum dene says Maximum size for any single HTML file Bir HTML dosyas iin maksimum boyutt Maximum size for any single non-HTML file HTML olmayan dosyalar iin maksimum boyut Maximum amount of bytes to retrieve from the Web Web'den alnacak maksimum bayt miktar Make a pause after downloading this amount of bytes Bu miktarda bir indirme yaparsan durakla Maximum duration time for the mirroring operation Yanslama iin maksimum sreklilik Maximum transfer rate Maksimum transfer hz Maximum connections/seconds (avoid server overload) Maksimum balant/saniye (sunucuya fazla yklenmekten kanmak iin) Maximum number of links that can be tested (not saved!) Test edilebilecek maksimum balant says (kaydedilmeyen!) Browser identity Browser Kimlii Comment to be placed in each HTML file Her HTML sayfasnn ierisine yerletirilecek aklama Back to starting page Balang sayfasna dn Save current preferences as default values uanki zellikleri ntanml deerler olarak kaydet Click to continue Devam etmek iin tklayn Click to cancel changes Deiiklikleri iptal etmek iin tklayn Follow local robots rules on sites Sitelerde yerel robot kurallarn izle Links to non-localised external pages will produce error pages Alnmayan sayfalar gsteren balantlar hata sayfalarna ynlendirilsin Do not erase obsolete files after update Gncellemeden sonra eski dosyalar silme Accept cookies? erezler kabul edilsin mi? Check document type when unknown? Bilinmeyen dosya trleri kontrol edilsin mi? Parse java applets to retrieve included files that must be downloaded? ndirilmesi gereken java uygulamar ayklansn m? Store all files in cache instead of HTML only Sadece HTML sayfalar yerine bellekteki tm dosyalar geri al Log file type (if generated) Kayt dosyasnn tr (eer retilirse) Maximum mirroring depth from root address Yanslama ileminde ana adresten uzaklalacak maksimum derinlik Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) Alnmayan/yasak adreslerin yans ilemi iin maksimum derinlik (0, bahsedilen, none, ntanml deer) Create a debugging file Hata ayklama iin dosya yarat Use non-standard requests to get round some server bugs Baz sunucu hatalarndan kurtulmak iin standart olmayan istekler kullan Use old HTTP/1.0 requests (limits engine power!) Eski HTTP/1.0 isteklerini kullan (sistem gcn kstlar!) Attempt to limit retransfers through several tricks (file size test..) Tekrarlanan transferleri birka hile ile kstlandrmaya al (dosya boyutu testi...) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Write external links without login/password Alnmayan balantlar giri/parola istemeden yaz Write internal links without query string Sorgulama kelimesi olmadan alnan balantlar yaz Get non-HTML files related to a link, eg external .ZIP or pictures Bir balantyla alakal HTML trnde olmayan dosyalar da al, rnek .ZIP dosyalar ve resimler Test all links (even forbidden ones) Tm balantlar test et (yasak olanlar bile) Try to catch all URLs (even in unknown tags/code) Tm balantlar almaya al (bilinmeyen etiket/kod iinde olanlar bile)) Get HTML files first! ncelikle HTML dosyalarn al! Structure type (how links are saved) Yap tr (balantlarn nasl kaydedilecei) Use a cache for updates Gncellemeler iin nbellek kullan Do not re-download locally erased files Yerel olarak silinen dosyalar tekrar indirme Make an index Bir index yarat Make a word database Szck veritaban hazrla Log files Kayt dosyalar DOS names (8+3) DOS adlar (8+3) ISO9660 names (CDROM) ISO9660 adlar (CDROM) No error pages Hata sayfalarn alma Primary Scan Rule ncelikli Arama Kural Travel mode Gezi modu Global travel mode Genel gezi modu These options should be modified only exceptionally Bu ayarlar sadece kabul edilebildikleri zaman deitirilebilirler Activate Debugging Mode (winhttrack.log) Hata Ayklama Modunu Aktifletir (winhttrack.log) Rewrite links: internal / external Balantlar tekrar yaz: alnan / alnmayan Flow control Tama kontrol Limits Snrlar Identity Kimlik HTML footer HTML sayfa altl N# connections N# balant Abandon host if error Eer hata oluursa sunucuyu brak Minimum transfer rate (B/s) Minimum transfer hz (B/s) Abandon host if too slow Eer sunucu ok yavasa brak Configure Yaplandr Use proxy for ftp transfers FTP transfeleri iin vekil sunucu kullan TimeOut(s) Zaman Am(s) Persistent connections (Keep-Alive) Aktif tutulan balantlar (Srekli) Reduce connection time and type lookup time using persistent connections Balant sresini drn ve kalc balantlar kullanlarak yaplan arama sresini girin. Retries Tekrar Deneme Size limit Boyut snr Max size of any HTML file (B) HTML dosyalar iin maksimum boyut (B) Max size of any non-HTML file HTML olmayan dosyalar iin maksimum boyut) Max site size Max site boyutu Max time Max sre Save prefs Ayarlar kaydeti Max transfer rate Max transfer hz Follow robots.txt Robots.txt'i takip et No external pages Tm sayfalar alnsn Do not purge old files Eski dosyalar temizleme Accept cookies erezleri kabul et Check document type Belge trn kontrol et Parse java files Java dosyalarn aykla Store ALL files in cache Tm dosyalar nbellekte topla Tolerant requests (for servers) Tlerans istekleri (sunucular iin) Update hack (limit re-transfers) Gncelleme ince ayar (tekrar eden transferleri snrla) URL hacks (join similar URLs) Force old HTTP/1.0 requests (no 1.1) Eski HTTP/1.0 isteklerine zorla (no 1.1) Max connections / seconds Max balant / saniye Maximum number of links Maximum balant says Pause after downloading.. ndirme ileminden sonra beklee.. Hide passwords Parolalar gizle Hide query strings Sorgulama kelimelerini gizle Links Balantlar Build Kur Experts Only Yalnzca Uzmanlarn Flow Control Tama Kontrol Limits Snrlar Browser ID Tarayc ID Scan Rules Tarama Kurallar Spider A Log, Index, Cache Kayt, Indeks, nbellek Proxy Vekil Sunucu MIME Types MIME Trleri Do you really want to quit WinHTTrack Website Copier? WinHTTrack Website Copier'den kmak istediine emin misiniz? Do not connect to a provider (already connected) Sunucuya balanma (zaten bal) Do not use remote access connection Uzaktan eriim balantlar kullanma Schedule the mirroring operation Yansma ilemini zamanla Quit WinHTTrack Website Copier WinHTTrack Website Copier'dan k Back to starting page Balang sayfasna dn Click to start! Balamak iin tklayn! No saved password for this connection! Bu balant iin kaydedilmi parola yok! Can not get remote connection settings Uzaktan eriim ayarlar alnamyor Select a connection provider Bir balant sunucusu sein Start Balat Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. Ltfen eer gerekli ise balant parametrelerini belirtiniz,\ndaha sonra BALAT'a basarak yanslama ilemini balatabilirsiniz. Save settings only, do not launch download now. Sadece ayarlar kaydet, indirme ilemine balama. On hold Beklemede Transfer scheduled for: (hh/mm/ss) Transferin zaman: (hh/mm/ss) Start Balat Connect to provider (RAS) Sunucuya balan (RAS) Connect to this provider Bu sunucuya balan Disconnect when finished Bittiinde balanty kes Disconnect modem on completion lem tamamlandnda modemden balanty kopar \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n(Ltfen bize her trl hatay ve problemi aktarnz)\r\n\r\nGelitirme:\r\nArayz (Windows): Xavier Roche\r\nA: Xavier Roche\r\nJava Ayklama Snflar: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche ve dierleri\r\neviri ipular iin teekkrler: \r\nRobert Lagadec (rlagadec@yahoo.fr) About WinHTTrack Website Copier WinHTTrack Website Copier Hakknda Please visit our Web page Ltfen web sitemizi ziyaret edin Wizard query Sorgulama sihirbaz Your answer: Cevabnz: Link detected.. Bulunan balant.. Choose a rule Bir kural sein Ignore this link Bu balanty yoksay Ignore directory Bu dizini yoksay Ignore domain Bu alanadn yoksay Catch this page only Sasece bu sayfay nbellee al Mirror site Siteyi yansla Mirror domain Alanadn yansla Ignore all Tmn yoksay Wizard query Sorgulama sihirbaz NO Hayr File Dosya Options Seenekler Log Kayt Window Pencere Help Yardm Pause transfer Transferi duraklat Exit k Modify options Seenekleri deitir View log Kayd gster View error log Hata kaydn gster View file transfers Dosya transfelerini gster Hide Gizle About WinHTTrack Website Copier WinHTTrack Website Copier Hakknda Check program updates... Program gncellemelerini kontrol et... &Toolbar &Ara ubuu &Status Bar &Durum ubuu S&plit A&yr File Dosya Preferences Ayarlar Mirror Yans Log Kayt Window Pencere Help Yardm Exit k Load default options Varsaylan ayarlar ykle Save default options Varsaylan ayarlar kaydet Reset to default options Varsaylan ayarlara dn Load options... Ayarlar ykle... Save options as... Ayarlar farkl kaydett... Language preference... Dil seimi... Contents... erikler... About WinHTTrack... WinHTTrack Hakknda... New project\tCtrl+N Yeni Proje\tCtrl+N &Open...\tCtrl+O &A...\tCtrl+O &Save\tCtrl+S &Kaydet\tCtrl+S Save &As... &Farkl Kaydet... &Delete... &Sil... &Browse sites... &Siteleri tara... User-defined structure Kullanc tanml yap %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\tDosyann soneksiz ad (rn: resim)\r\n%N\tDosyann sonekli ad (rn: resim.gif)\r\n%t\tYalnz dosyann tr (rn: gif)\r\n%p\tKonum [/ ile bitmeyen] (rn: /resimler)\r\n%h\tSunucu ad (rn: www.siteniz.com)\r\n%M\tMD5 URL (128 bit, 32 ascii bayt)\r\n%Q\tMD5 sorgu kelimesi (128 bit, 32 ascii bayt)\r\n%q\tMD5 ksa arama kelimesi (16 bit, 4 ascii bayt)\r\n\r\n%s?\tKsa ad (rnek: %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif rnek:\t%h%p/%n%q.%t\n->\t\tc:\\yans\\www.siteniz.com\\resimler\\resim.gif Proxy settings Vekil sunucu ayarlar Proxy address: Vekil sunucu adresi: Proxy port: Vekil sunucu portu: Authentication (only if needed) Yetkilendirme (gerektiinde) Login Kullanc Password Parola Enter proxy address here Vekil sunucu adresini buraya girin Enter proxy port here Vekil sunucu portunu buraya girin Enter proxy login Vekil sunucu kullanc adnz girin Enter proxy password Vekil sunucu parolasn girin Enter project name here Proje adn buraya girin Enter saving path here Saklanacak konumu buraya girinr Select existing project to update Gncellenecek projeyi sein Click here to select path Konumu semek iin tklayn Select or create a new category name, to sort your mirrors in categories HTTrack Project Wizard... HTTrack Proje Sihirbaz... New project name: Yeni proje ad: Existing project name: Mevcut proje ad: Project name: Proje ad: Base path: Ana konum: Project category: C:\\My Web Sites C:\\Benim Web Sitem Type a new project name, \r\nor select existing project to update/resume Yeni bir proje ad yazn, \r\nveya devam edilecek/gncellenecek projeyi sein New project Yeni proje Insert URL URL ekle URL: URL: Authentication (only if needed) Yetkilendirme (gerekirse) Login Kullanc Password Parola Forms or complex links: Formlar veya karmak balantlar: Capture URL... URL yakala... Enter URL address(es) here URL Adres(ler)ini buraya girin Enter site login Site iin kullanc ad girin Enter site password Site iin parola girin Use this capture tool for links that can only be accessed through forms or javascript code Yalnzca formlarla veya javascript koduyla eriilebilen balantlar bu yakalama aracn kullanarak al Choose language according to preference Dili ayarlara gre se Catch URL! URL Yakala! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. Ltfen geici tarayc vekil sunucu ayarlarn bu deerlere gre ataynz (Vekil sunucu adresini ve portunu Kopyala/Yaptr yapabilirsiniz).\nDaha sonra taraycnzda formun GNDER (SUBMIT) tuuna veya almak istediiniz zel balantya tklaynz. This will send the desired link from your browser to WinHTTrack. Bu ilem istenilen balanty taraycnzdan WinHTTrack'e gnderecektir. ABORT PTAL ET Copy/Paste the temporary proxy parameters here Geici vekil sunucu parametrelerini buraya Kopyala/Yaptr yapnr Cancel Vazge Unable to find Help files! Yardm dosyalar bulunamad! Unable to save parameters! Parametreler kaydedilemedi! Please drag only one folder at a time Ltfen bir seferde yalnz bir klasr srkleyin Please drag only folders, not files Ltfen dosyalar yerine dizinleri srkleyin Please drag folders only Ltfen sadece dizinleri srkleyin Select user-defined structure? Kullanc tanml yap seilsin mi?? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! Ltfen kullanc tanml kelimenin doru olduundan emin olun,\nyoksa dosya adlar sahte olacaktr! Do you really want to use a user-defined structure? Kullanc tanml bir yap kullanmak istediinizden emin misiniz? Too manu URLs, cannot handle so many links!! ok fazla adres var, bu kadar fazla adres tutulamayacaktr!! Not enough memory, fatal internal error.. Yeterli hafza yok, lmcl i hata.. Unknown operation! Bilinmeyen ilem! Add this URL?\r\n Bu URL eklensin mi?\r\n Warning: main process is still not responding, cannot add URL(s).. Uyar: Ana sre hala cevap vermedi, URL eklenemedi.. Type/MIME associations Tr/MIME ilikileri File types: Dosya trleri: MIME identity: MIME kimlii: Select or modify your file type(s) here Buradan dosya trlerini sein ve deiitirin Select or modify your MIME type(s) here Buradan MIME trlerini sein ve deiitirin Go up Yukar Go down Aa File download information Dosya indirme bilgisi Freeze Window Pencereyi Dondur More information: Daha ok bilgi: Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download WinHTTrack Website Copier'a Hogeldiniz!\n\nLtfen yeni bir projeye balamak\nveya yarm kalm bir indirmeye devam etmek iin\nLER butonuna tklayn\n File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS Uzantlar ile birlikte dosya adlar:\nDosya adlar iinde:\nBu dosya ad:\nDizin adlar iinde:\nBu dizin ad:\nBu alan adndaki balantlar:\nAlan adlarndaki balantlar iinde:\nBu sunucudan balantlar:\nBalantlar iinde:\nBu balant:\nTM BALANTILAR Show all\nHide debug\nHide infos\nHide debug and infos Hepsini gster\nHata ayklamay gizle\nBilgileri gizle\nBilgileri ve hata ayklamay gizle Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. Site yaps (ntanml)\nweb/'de Html, web/resimler/ iinde resimler/dier dosyalar\nweb/html iinde Html, /web/resimler iinde resimler/dier dosyalar\nweb/ iinde Html, web/ iinde resimler/dier dosyalar\nweb/ iindeki resimler, web/xxx iindeki resimler/dier dosyalar, (Buradaki xxx dosya uzantsdr)\nweb/html iinde Html, web/xxx iinde resimler\nwww.alanadi.xxx/ olmadan site yaps\nsite_adi iinde Html, site_adi/resimler/ iinde resimler/dier dosyalar\nsite_adi/html iinde Html, site_adi/resimler iinde resimler/dieer dosyalar\nsite_adi iinde Html, site_adi/ iinde resimler/dier dosyalar\nsite_adi/ iinde html, site_adi/xxx iinde resimler/dier dosyalar\nsite_adi/html iinde Html, site_adi/xxx iinde resimler/dier dosyalar\nweb/ iindeki tm dosyalar, (rastgele adlarla!)\nsite_adi/ iindeki tm dosyalar (rastgele adlarla!)\nKullanc tanml yap.. Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first Sadece tara\nHtml dosyalarn al\nHtml trnde olmayan dosyalar al\nTm dosyalar al (ntanml)\nncelikli olarak html dosyalarn al Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down Ayn dizin iinde kal\nAlt dizinlere geilebilir /ntanml)\nst dizinlere geilebilir\nHem alt hem st dizinlere geilebilir Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web Ayn adreste kal (ntanml)\nAyn alan adnda kal\nAyn st seviye adresinde kal\nWeb'deki her yere git Never\nIf unknown (except /)\nIf unknown Asla\nBilinmiyorsa (/ hari)\nBilinmiyorsa no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules Robot.txt kurallar olmasn\nrobot.txt kurallar (sihirbaz hari)\nrobot.txt kurallarn uygula normal\nextended\ndebug normal\ngeniletilmi\nhata aykla Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download Web sitelerini indir\nWeb sitelerini + istekleri indir\nAyr dosyalar al\nSayfalardaki tm siteleri indir (oklu yans)\nSayfalardaki balantlar test et (sk kullanlanlar testi)\n* Tamamlanmam indirme ilemine devam et\n* ndirilmi sayfay gncelle Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL Benzer URI / Tam URL (ntanml)\nTam URL / Tam URL\nTam URI / Tam URL\nOrjinal URL / Orjinal URL Open Source offline browser Ak kaynak kodlu evrimd tarayc Website Copier/Offline Browser. Copy remote websites to your computer. Free. Web sitesi Kopyalc/evrimd Tarayc. Web sitelerini bilgisayarnza kopyalayn. Bedava. httrack, winhttrack, webhttrack, offline browser httrack, winhttrack, webhttrack, evrimd tarayc URL list (.txt) URL listesi (.txt) Previous Geri Next leri URLs URLler Warning Uyar Your browser does not currently support javascript. For better results, please use a javascript-aware browser. Taraycnz uanda javascript'i desteklemiyor. Daha iyi sonular iin, ltfen javascript destekli bir tarayc kullann. Thank you Teekkrler You can now close this window Bu pencereyi artk kapatabilirsiniz Server terminated Sunucu sonlandrd A fatal error has occurred during this mirror Bu yanslama ilemi srasnda lmcl bir hata olutu httrack-3.49.5/lang/Svenska.txt0000644000175000017500000010365414360553245013311 00000000000000LANGUAGE_NAME Svenska LANGUAGE_FILE Svenska LANGUAGE_ISO sv LANGUAGE_AUTHOR Staffan Strm (staffan at fam-strom.org) \r\n LANGUAGE_CHARSET ISO-8859-2 LANGUAGE_WINDOWSID Swedish OK OK Cancel Annulera Exit Avsluta Close Stng Cancel changes ngra ndringarna Click to confirm Klicka fr att bekrfta Click to get help! Klicka fr att f hjlp! Click to return to previous screen Klicka fr att g till fregende bild Click to go to next screen Klicka fr att se nsta bild Hide password Dlj lsenord Save project Spara projekt Close current project? Stng aktuellt projekt? Delete this project? Radera detta projekt? Delete empty project %s? Radera tomt projekt %s? Action not yet implemented Denna funktion r inte utvecklad nnu Error deleting this project Ett fel uppstod vid radering av detta projekt Select a rule for the filter Vlj vilken regel som skall glla fr detta filter Enter keywords for the filter Skriv in ett nyckelord fr detta filter Cancel Annulera Add this rule Lgg till denna regel Please enter one or several keyword(s) for the rule Skriv in en eller flera nykelord fr denna regel Add Scan Rule Lgg till en skregel Criterion Kriterie String Strng Add Lgg till Scan Rules Skregler Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Anvnd jokertecken (*) till att inkludera/exkludera URLer eller lnkar.\nDu kan anvnda flera skstrngar i samma rad.\nAnvnd mellanrum som separator.\n\nExempel: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Exclude links Uteslut lnk(ar) Include link(s) Inkludera lnk(ar) Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) Tips: Fr att f med ALLA GIF-filer, prova och anvnd: +www.someweb.com/*.gif. \n(+*.gif / -*.gif kommer att inkludera/exkludera ALLA GIF-filer frn ALLA webb-sajter) Save prefs Spara instllningar Matching links will be excluded: Matchande lnkar kommer att uteslutas: Matching links will be included: Matchande lnkar kommer att inkluderas: Example: Exempel: gif\r\nWill match all GIF files gif\r\n Kommer att matcha alla GIF-filer blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' blue\r\nKommer att hitta alla filer med en matchande textstrng. Skriver du ex. vis 'blue' medtages 'bluesky-small.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' bigfile.mov\r\nKommer att ta med filen 'bigfile.mov', men inte filen 'bigfile2.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\nKommer att hitta lnkar med mappnamn som matchar textstrngen 'cgi', t.ex. /cgi-bin/somecgi.cgi cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\nFinner lnkar med mappnamn som matchar hela 'cgi-bin' textstrngen (men inte cgi-bin-2, som ett exempel) someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb.com\r\nHittar lnkar med matchande sub-string t.ex. www.someweb.com, private.someweb.com etc. someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. someweb\r\nHittar lnkar med matchande mappnamn sub-string som t.ex. www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc.\r\n\r\n www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.someweb.com\r\nHittar lnkar som matchar hela strngen 'www.someweb.com' , (men INTE lnkar som: private.someweb.com/..) someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. someweb\r\nHittar mjliga lnkar med matchande text-strng som t.ex. www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc.\r\n www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/someweb.html\r\nHittar bara 'www.test.com/test/someweb.html' filen. Notera att du skall skriva den fullstndiga skvgen[URL + skvg] All links will match Alla lnkar kommer att matcha Add exclusion filter Lgg till exkluderings-filter Add inclusion filter Lgg till inkluderings-filter Existing filters Existerande filter Cancel changes Upphv ndringarna Save current preferences as default values Spara nuvarande instllningar som standardinstllning Click to confirm Klicka fr bekrfta No log files in %s! Det finns ingen log-fil i %s! No 'index.html' file in %s! Dettt finns ingen 'index.html'-fil i %s! Click to quit WinHTTrack Website Copier Klicka fr att avsluta WinHTTrack Website Copier View log files Granska log filer Browse HTML start page Granska HTML startsida End of mirror Kopieringen av denna webb r klar View log files Visa logfiler Browse Mirrored Website Granska kopierad Webb New project... Nytt projekt... View error and warning reports Granska fel/varnings-rapporten View report Granska rapporten Close the log file window Ls loggfils fnstret Info type: Informationstyp: Errors Fel Infos Information Find Sk Find a word Sk efter ett ord Info log file Info loggfil Warning/Errors log file Varning/Fel loggfil Unable to initialize the OLE system Kan inte starta OLE-systemet WinHTTrack could not find any interrupted download file cache in the specified folder! WinHTTrack kan inte hitta ngon avbruten download fil-cache i den angivna mappen!\r\n Could not connect to provider Kan inte ansluta till Internet receive motagit request anmodan connect ansluta search ska ready klar error fel Receiving files.. Tar emot filer... Parsing HTML file.. verfr HTML fil... Purging files.. Ta bort filer.. Loading cache in progress.. Parsing HTML file (testing links).. verfr HTML fil (testar lnkar).... Pause - Toggle [Mirror]/[Pause download] to resume operation Pause - Vlj frn menyn [Kopiera]/[Pause nerladdning] fr att teruppta verfringen Finishing pending transfers - Select [Cancel] to stop now! Avsluta pgende verfring - Vlj [Avbryt] fr att stoppa scanning skning Waiting for scheduled time.. Vnta p planlagd tidpunkt... Connecting to provider Ansluter till Internet [%d seconds] to go before start of operation [%d sekunder] kvar till start av denna operation Site mirroring in progress [%s, %s bytes] Webb kopieras nu [%s, %s bytes] Site mirroring finished! Kopieringen r avslutad ! A problem occurred during the mirroring operation\n Det uppstod ett problem under kopieringen \nDuring:\n \nUnder:\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! \nGranska eventuellt log filen.\n\nKlicka p AVSLUTA fr att stnga WinHTTrack Website Copier.\n\nTack fr att du anvnder WinHTTrack! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! Webb kopieringen r utfrd. \nKlicka OK fr att avsluta WinHTTrack.\nGranska log-fil(erna) fr att kontrollera att allt har fungerat.\n\nTack fr att du avnder WinHTTrack!\r\n * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * KOPIERINGEN R AVBRUTEN! * *\r\nDen nuvarnde cachen r obligatorisk fr alla uppdaterings operationer och innehller data frn senaste nerladdning med den aktuella avbrutna verfringen.\r\nDen tidigare cachen kan innehlla mera komplett information; on du nskar att spara den informationen, ska du terskapa den och radera den aktuella cachen.\r\n[Note: Detta kan lttast gras genom att radera samtliga 'hts-cache/new.* filer]\r\n\r\nTror du att den tidigare cache-fil eventuellt innehler mera komplett information, och vill du terstlla den? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * KOPIERINGSFEL! * *\r\nWinHTTrack har upptckt att den nuvarande webb-kopieringen r tom. Om det var en uppdatering du utfrde, har den gamla kopian terskapats.\r\nMjlig fel: Den frsta sidan kunde antingen inte hittas eller uppstod det ett problem med frbindelsen.\r\n=> Kontrollera att webbservern finns och/eller kontrollera Proxy-instllningen! <= \n\nTip: Click [View log file] to see warning or error messages \n\nTips: Klicka [Granska log fil] fr att granska varning/fel-meddelande Error deleting a hts-cache/new.* file, please do it manually Det uppstod ett fel vid radering av hts-cache/new.* file, radera filen manuellt. Do you really want to quit WinHTTrack Website Copier? Vill du verklingen avsluta WinHTTrack Website Copier? - Mirroring Mode -\n\nEnter address(es) in URL box - Kopiering av webb -\n\nSkriv webb-adressen i URL fltet - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - Interaktiv guide (frgor) -\n\nSkriv webb-adressen i URL fltet - File Download Mode -\n\nEnter file address(es) in URL box - Filverfring -\n\nSkriv webb-adressen i URL fltet - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - Lnk test -\n\nSkriv webb-adressen i URL fltet - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Uppdatering -\n\nBekrfta webb-adressen i URL fltet. Kontrollera ev. dina instllingar och klicka sedan p 'NSTA'. - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - teruppta kopiering (dr verfringen blev avbruten) -\n\nBekrfta webb-adressen i URL fltet. Kontrollera ev. dina instllingar och klicka sedan p 'NSTA'. Log files Path Skvg fr log-fil Path Skvg - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror - Lnklista- \n\nAnvnd URL fltet till att ange address(er) p sidor dr innehller lnkar som skall kopieras. New project / Import? Nytt projekt / Import? Choose criterion Vlj kriterier Maximum link scanning depth Max skdjup fr lnkar Enter address(es) here Skriv in webb-adress(er) hr Define additional filtering rules Definera ytterligare filtreringsregler Proxy Name (if needed) Proxy Namn (om det behvs) Proxy Port Proxy portnummer Define proxy settings Definera proxy-instllningar Use standard HTTP proxy as FTP proxy Anvnd standard HTTP proxy som FTP proxy Path Skvg Select Path vlj skvg Path Skvg Select Path Vlj skvg Quit WinHTTrack Website Copier Avsluta WinHTTrack Website Copier About WinHTTrack Om WinHTTrack Save current preferences as default values Spara nuvarande instllningar som standard Click to continue Klicka fr att fortstta Click to define options Klicka fr att definera instllingar Click to add a URL Klicka fr att lgga till URL Load URL(s) from text file Hmta URL frn text fil WinHTTrack preferences (*.opt)|*.opt|| WinHTTrack instllingar (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| Adresslista text fil (*.txt)|*.txt|| File not found! Filen hittades inte! Do you really want to change the project name/path? r du sker p att ndra projektnamn/skvg? Load user-default options? Ladda anvndardefinierade standardinstllningar? Save user-default options? Spara anvndardefinierade standardinstllningar? Reset all default options? Nollstll alla standardinstllningar? Welcome to WinHTTrack! Vlkommen till WinHTTrack Website Copier! Action: Handling: Max Depth Max djup: Maximum external depth: Max externt djup: Filters (refuse/accept links) : Filtrerings-regel (utan/med lnkar) Paths Skvg Save prefs Spara instllningar Define.. Definera... Set options.. Bestm instllningar... Preferences and mirror options: Instllningar och kopieringsval Project name Projektnamn Add a URL... Skriv URL... Web Addresses: (URL) Webb-adress (URL) Stop WinHTTrack? Stoppa WinHTTrack? No log files in %s! Ingen loggfil i %s! Pause Download? Paus i kopieringen? Stop the mirroring operation Stoppa kopieringen? Minimize to System Tray Minimera till verktygsfltet Click to skip a link or stop parsing Klicka fr att hoppa ver en lnk eller stoppa verfringen Click to skip a link Klicka fr att hoppa ver en lnk Bytes saved Bytes sparade: Links scanned Skta lnkar Time: Tid : Connections: Frbindelse: Running: I gng : Hide Gmma Transfer rate verfringshastighet SKIP Hoppa ver Information Information Files written: Filer skrivna: Files updated: Filer uppdaterade: Errors: Fel: In progress: Arbetar: Follow external links Flj externa lnkar Test all links in pages Testa alla lnkar p sidan Try to ferret out all links Prova att utvidga alla lnkar Download HTML files first (faster) Ladda HTML-filer frst (snabbast) Choose local site structure Vlj en lokal webb-struktur Set user-defined structure on disk Bestm anvndardefinerade instllningar fr lokal struktur Use a cache for updates and retries Anvnd cache till uppdateringar och uppdateringsfrsk Do not update zero size or user-erased files Uppdatera inte filer med noll-vrde eller filer som r raderade Create a Start Page Skapa en startsida Create a word database of all html pages Skapa en textbaserad databas ver alla HTML-sidor Create error logging and report files Skapa felloggning och rapport-filer Generate DOS 8-3 filenames ONLY Skapa ENDAST filnamn i DOS 8-3-format Generate ISO9660 filenames ONLY for CDROM medias Do not create HTML error pages Skapa inte sidor med HTML felrapporter Select file types to be saved to disk Vlj filtyp som ska sparas p disken Select parsing direction Vlj verfringsriktning Select global parsing direction Vlj global verfringsriktning Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) Regler fr hur verskrivning av URL skall ske fr interna (nerladdade) och externa (inte nerladdade) lnkar Max simultaneous connections Max antal samtidiga frbindelser File timeout Fil timeout Cancel all links from host if timeout occurs Annulera alla lnkar frn vrd om timeout intrffar Minimum admissible transfer rate Min aceptabla verfringshastighet Cancel all links from host if too slow Annulera alla lnkar nr kommunikationen r fr lngsam Maximum number of retries on non-fatal errors Max antal frsk efter icke-fatala fel Maximum size for any single HTML file Max storlek fr enskild HTML-fil Maximum size for any single non-HTML file Max storlek fr enskils icke HTML-fil Maximum amount of bytes to retrieve from the Web Max antal bytes som hmtas frn webben Make a pause after downloading this amount of bytes Gr paus efter att ha laddat ned denna mngd bytes Maximum duration time for the mirroring operation Max verfringstid fr kopieringen Maximum transfer rate Max verfringshastighet Maximum connections/seconds (avoid server overload) Max antal frbindelser/sekund (fr att undvika verbelastning p servern) Maximum number of links that can be tested (not saved!) Max antal lnkar som kan bli testade (inte sparat!) Browser identity Webblsare identitet Comment to be placed in each HTML file Kommentarer fr infogas i varje HTML fil Back to starting page Tillbaka till startsidan Save current preferences as default values Spara nuvarande instllning som standard Click to continue Klicka fr att fortstta Click to cancel changes Klicka fr att ngra ndringarna Follow local robots rules on sites Flj lokala skregler p webbsidan Links to non-localised external pages will produce error pages Lnkar till icke funna externa sidor kommer att skapa felsida Do not erase obsolete files after update Radera inte verfldiga filer efter uppdatering Accept cookies? Acceptera cookies? Check document type when unknown? Kontrollera dokumenttyp nr det r oknt? Parse java applets to retrieve included files that must be downloaded? verfra java applets tillsammans med inkluderade filer som skall laddas ned? Store all files in cache instead of HTML only Lagra alla filer i chchen istllet fr enbart HTML? Log file type (if generated) Logga filtyp (om det genereras) Maximum mirroring depth from root address Max kopieringsdjup frn root adressen Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) Max kopierngsdjup fr externa/frbjuden adress (0, betyder ingen, r standard) Create a debugging file Skapar en felskningsfil (debugg-fil) Use non-standard requests to get round some server bugs Anvnder icke-standard frfrgningar fr att kring serverfel Use old HTTP/1.0 requests (limits engine power!) Anvnder gamla HTTP/1.0 frfrgningar (begrnsar effektiviteten!) Attempt to limit retransfers through several tricks (file size test..) Frsker att begrnsa omsndningar genom att anvnda flera 'trick' (file size test..) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Write external links without login/password Skriver externa lnkar utan att anvnda login/lsenord Write internal links without query string Skriver interna lnkar utan frgesats Get non-HTML files related to a link, eg external .ZIP or pictures Hmtar icke-HTML filer relaterat till en lnk, t.ex. .ZIP eller bilder Test all links (even forbidden ones) Testar alla lnkar (ven frbjudna) Try to catch all URLs (even in unknown tags/code) Frsker att fnga alla URLer (ocks fr oknda tags/koder) Get HTML files first! Hmtar HTML filer frst! Structure type (how links are saved) Anger struktur (hur lnkar r sparade) Use a cache for updates Anvnd cache fr uppdatering Do not re-download locally erased files Hmta inte filer som r lokalt raderade Make an index Gr ett index Make a word database Gr en textbaserad databas Log files Log filer DOS names (8+3) DOS namn (8+3)*/ ISO9660 names (CDROM) No error pages Ingen felsida Primary Scan Rule Primr skregel Travel mode Skmetod Global travel mode Global skmetod These options should be modified only exceptionally Dessa instllningar skall endast ndras undantagsvis! Activate Debugging Mode (winhttrack.log) Aktivera felskningsloggen (winhttrack.log) Rewrite links: internal / external Skriv om lnkar: interna / externa Flow control Fldeskontroll Limits Begrnsningar Identity Identitet HTML footer HTML fot N# connections Antal frbindelser Abandon host if error Lmna vrd om det uppstr fel Minimum transfer rate (B/s) Min. verfringshastighet (B/s) Abandon host if too slow Lmna vrd om den r fr lngsam Configure Konfigurera Use proxy for ftp transfers Anvnd proxy fr FTP-verfringar TimeOut(s) TimeOut(s) Persistent connections (Keep-Alive) Reduce connection time and type lookup time using persistent connections Retries Antal frsk Size limit Storleksbegrnsning Max size of any HTML file (B) Max storlek fr HTML-fil (B) Max size of any non-HTML file Max storlek fr icke-HTML fil Max site size Max webbplats storlek Max time Max tid Save prefs Spara instllningar Max transfer rate Max verfringshastighet Follow robots.txt Flj reglerna i robots.txt No external pages Inga externa sidor Do not purge old files Radera inte gamla filer Accept cookies Acceptera cookies Check document type Kontrollera dokumenttypen Parse java files verfr javafiler Store ALL files in cache Lagra ALLA filer i cachen Tolerant requests (for servers) Acceptera frfrgningar (frn server) Update hack (limit re-transfers) Uppdatera avbrott (begrnsa omsndningar) URL hacks (join similar URLs) Force old HTTP/1.0 requests (no 1.1) Forcera gamla HTTP/1.0 frfrgningar (inte 1.1) Max connections / seconds Max frbindelser/sekunder Maximum number of links Max antal lnkar Pause after downloading.. Paus efter verfring... Hide passwords Dlj lsenord Hide query strings Dlj frgestrngar Links Lnkar Build Struktur Experts Only Instllningar fr experter Flow Control Fldeskontroll Limits Begrnsningar Browser ID Webblsare Identitet Scan Rules Skregler Spider Webbrobot Log, Index, Cache Log, Index, Cache Proxy Proxy MIME Types Do you really want to quit WinHTTrack Website Copier? Vill du verklingen avsluta WinHTTTrack Website Copier? Do not connect to a provider (already connected) Anslut inte till Internet (r redan ansluten) Do not use remote access connection Anvnd inte fjrranslutning (RAS) Schedule the mirroring operation Planlgg kopieringen Quit WinHTTrack Website Copier Sluta WinHTTTrack Website Copier Back to starting page ter startsida Click to start! Klicka fr att starta! No saved password for this connection! Det finns inget sparat lsenord fr denna frbindelse! Can not get remote connection settings Kan inte lsa vrdens inloggningsinstllningar Select a connection provider Vlj en Internetuppkoppling Start Start Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. Justera instllningarna fr frbindelsen, om ndvndigt\nKlicka p UTFR fr att starta kopieringen Save settings only, do not launch download now. Spara instllningarna, men starta inte verfringen nu. On hold Satt i vntan Transfer scheduled for: (hh/mm/ss) verfringen planlagd till :(hh/mm/ss) Start Starta Connect to provider (RAS) Koppla upp till leverantr (RAS) Connect to this provider Koppla upp till Internet Disconnect when finished Koppla ner frbindelsen nr verfringen r klar Disconnect modem on completion Koppla ned modemet efter avslutning \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n(Hittar du fel eller uppstr det problem, kontakta oss)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for Swedish translations to:\r\nStaffan Strm (staffan@fam-strom.org) About WinHTTrack Website Copier Om WinHTTrack Website Copier... Please visit our Web page Besk vr webb Wizard query Guidad frgeformulr Your answer: Ditt svar Link detected.. Lnk funnen Choose a rule Vlj en regel Ignore this link Ignorera denna lnk Ignore directory Ignorera denna mapp Ignore domain Ignorera domnen Catch this page only Hmta endast denna sida Mirror site Kopiera webbsidorna Mirror domain Kopiera domnen Ignore all Ignorera allt Wizard query Guidad frgeformulr NO Nej File Fil Options Instllningar Log Log Window Fnster Help Hjlp Pause transfer Pause verfring Exit Avsluta Modify options ndra instllningarna View log Visa loggen View error log Visa felloggen View file transfers Visa verfringsloggen Hide Dlj About WinHTTrack Website Copier Om WinHTTTrack Website Copier Check program updates... Kontrollera program uppdateringar... &Toolbar &Verktygsrad &Status Bar &Statusrad S&plit &Dela File Fil Preferences Instllningar Mirror Kopiera webbsidor Log Logg Window Fnster Help Hjlp Exit Avsluta Load default options Ladda in standardinstllningar Save default options Spara standard instllingar Reset to default options terstll till standardinstllningar Load options... Ladda instllingar... Save options as... Spara instllingar som... Language preference... Valt sprk... Contents... Innehll... About WinHTTrack... Om WinHTTrack... New project\tCtrl+N Nytt projekt\tCtrl+N &Open...\tCtrl+O &ppna...\tCtrl+O &Save\tCtrl+S &Spara\tCtrl+S Save &As... Spara &som... &Delete... &Radera... &Browse sites... &G igenom webbsidor User-defined structure Anvndardefinerad struktur %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\tFilnamn utan filtyp (ex: image)\r\n%N\tHela filnamnet inkl. filtyp (ex: image.gif)\r\n%t\tEnbart filtyp (ex: gif)\r\n%p\tSkvg [utan ndelsen /] (ex: /someimages)\r\n%h\tVrddator-namn (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 frgestrng (128 bits, 32 ascii bytes)\r\n%q\tMD5 kort frgestrng (16 bits, 4 ascii bytes)\r\n\r\n%s?\tKort namn (ex: %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Exempel:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Proxy settings Proxy instllningar Proxy address: Proxy adress Proxy port: Proxy port: Authentication (only if needed) Identifikation (om ndvndigt) Login Anvndarnamn Password Lsenord Enter proxy address here Skriv in proxy adressen hr Enter proxy port here Skriv in proxy portnummer hr Enter proxy login Skriv in proxy anvndarnamn/ login Enter proxy password Skriv in proxy lsenord Enter project name here Skriv in projektets namn hr Enter saving path here Skriv in skvgen dr projektet skall sparas Select existing project to update Vlj ett existerande projektnamn att uppdatera Click here to select path Klicka hr fr att vlja skvg Select or create a new category name, to sort your mirrors in categories HTTrack Project Wizard... HTTrack Projektassistent New project name: Nytt projektnamn: Existing project name: Existerande projektnamn: Project name: Projektnamn: Base path: Vlj en fast skvg till dina projekt: Project category: C:\\My Web Sites C:\\Mina webbsidor Type a new project name, \r\nor select existing project to update/resume Skriv namnet p ett nytt projekt\neller\nvlj att uppdatera ett existerande projekt New project Nytt projekt Insert URL Skriv in URL URL: URL: Authentication (only if needed) Identifikation (om ndvndigt) Login Anvndarnamn/ Login Password Lsenord Forms or complex links: Formulr eller komplexa lnkar: Capture URL... 'Fnga' URL Enter URL address(es) here Skriv in URL adress(er) hr Enter site login Skriv in webbsidornas Anvndarnamn Enter site password Skriv in websidornas Lsenord Use this capture tool for links that can only be accessed through forms or javascript code Anvnd detta verktyg fr att 'fnga' lnkar som endast kan ns via formulr eller javascript-kod Choose language according to preference Vlj ditt frvalda sprk Catch URL! 'Fnga' URL Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. Stt tillflligt webblsarens proxy till fljande vrden: (Kopiera/Klistra in Proxy Adress och Port).\nKlicka p Form SUBMIT knappen i din webblsare, eller klicka p den specifika lnk du nskar att hmta. This will send the desired link from your browser to WinHTTrack. Detta snder den nskade lnken frn din webblsare til WinHTTrack. ABORT AVBRYT Copy/Paste the temporary proxy parameters here Kopiera/Klistra in de temporra proxy parametrarna hr Cancel Annullera Unable to find Help files! Kan inte hitta Hjlpfilerna! Unable to save parameters! Kan inte spara parametrana! Please drag only one folder at a time Drag enbart en mapp t gngen! Please drag only folders, not files Drag enbart mappar, inte filer Please drag folders only Drag bara mappar Select user-defined structure? Vlj anvndardefinierad struktur? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! Var sker p att den anvndardefinierade strngen r korrekt\nImotsat fall kommer filnamnen att vara ogiltiga! Do you really want to use a user-defined structure? r du riktigt sker p att anvnda en anvndardefinierad struktur? Too manu URLs, cannot handle so many links!! Fr mnga URLer, WinHTTrack kan inte hantera s mnga lnkar!!! Not enough memory, fatal internal error.. Det finns inte tillrckligt med minne, allvarligt internt fel har uppsttt.. Unknown operation! Oknd handling! Add this URL?\r\n Addera denna URL?\r\n Warning: main process is still not responding, cannot add URL(s).. Varning: Processen svarar inte, URLen kan inte adderas.... Type/MIME associations Typ/MIME sammankoppling File types: Fil typer: MIME identity: MIME Identitet: Select or modify your file type(s) here Vlj eller ndra dina filtyp(er) hr Select or modify your MIME type(s) here Vlj eller ndra dina MIME typ(er) hr Go up G upp Go down G ned File download information Filverfringsinformation Freeze Window Frys fnstret More information: Mera information: Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download Vlkommen till WinHTTrack Website Copier!\n\Klicka p 'Nsta' fr att fr att\n-Starta ett nytt projekt\n-eller uppdatera ett existerande projekt. File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS Filnamn med filtillg:\nFilnamn som innehller:\nDetta filnamn:\nMappnamn som innehller:\nDetta mappnamn:\nLnkar p denna domn:\nLnkar p denna domn som innehller:\nLnkar frn denna vrd:\nLnkar som innehller:\nDenna Lnk:\nAlla Lnkar Show all\nHide debug\nHide infos\nHide debug and infos Visa alla\nGm felhantering\nGm information\nGm felhantering och information Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. Webbplats-struktur (Standard)\nHtml i webb/, Bilder/andra filer i webb/bilder/\nHtml i webb/html, Bilder och annat i webb/bilder\nHtml i webb/, Bilder och annat i webb/\nHtml i webb/, Bilder och annat i webb/xxx, med xxx dr Datatyp\nHtml i webb/html, Bilder och annat i webb/xxx\nWebbplats-struktur, utan www.domain.xxx/\nHtml i webbplats/, Bilder och andra i webbplats/images/\nHtml i webbplats/html, Bilder och andra i webbplats/images\nHtml i webbplats/, Bilder och andra i webbplats/\nHtml i webbplats/, Bilder och andra i webbplats/xxx\nHtml i webbplats/html, Bilder och andra i webbplats/xxx\nAlla filer i webbplats/, med slumpnamn \nAlla filer i webbplats/, med Slumpnamn \nAnvndardefinierad Struktur... Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first Bara sk\nSpara html filer\nSpara icke-html filer\nSpara alla filer (standard)\nSpara html filer frst Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down Bli kvar i samma mapp\nKan g ned(standard)\nKan g upp\nKan g bde upp och ned Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web Bli kvar p samma adress [standard]\nBli kvar p samma domn\nBli kvar p samma toppniv-domn\n G verallt p Internet. Never\nIf unknown (except /)\nIf unknown Aldrig\nOm oknt (undantaget /]\nOm oknt no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules Ingen robots.txt regel\nrobots.txt med undantag av guiden\nflj robots.txt reglerna normal\nextended\ndebug Normal\nutvidgat\nfelskning Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download Ladda ner webbplats(er)\nLadda ner webplats(er) + frgor\nHmta separata filer\nverfr alla sidor (multiple mirror)\nTesta lnkarna p sidorna (bookmark test)\n* Fortstt avbrutet projekt\n* Uppdatera tidigare projekt Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL Relativ URI / Fullstndig URL (default)\nFullstndig URL / Fullstndig URL\nFullstndig URI / Fullstndig URL\nUrsprunglig URL / Ursprunglig URL Open Source offline browser Website Copier/Offline Browser. Copy remote websites to your computer. Free. httrack, winhttrack, webhttrack, offline browser URL list (.txt) Previous Next URLs Warning Your browser does not currently support javascript. For better results, please use a javascript-aware browser. Thank you You can now close this window Server terminated A fatal error has occurred during this mirror httrack-3.49.5/lang/Slovenian.txt0000644000175000017500000010312714360553245013630 00000000000000LANGUAGE_NAME Slovenian LANGUAGE_FILE Slovenian LANGUAGE_ISO si LANGUAGE_AUTHOR Jadran Rudec,iur.\r\njrudec@email.si \r\n LANGUAGE_CHARSET ISO-8859-1 LANGUAGE_WINDOWSID Slovenian OK Vredu Cancel Opusti Exit Izhod Close Zapri Cancel changes Opusti spremembe Click to confirm Klikni za potrditev Click to get help! Klikni za pomo! Click to return to previous screen Klikni za vrnitev na prejnji zaslon Click to go to next screen Klikni za prehod na naslednji zaslon Hide password Skrij geslo Save project Shrani projekt Close current project? Zaprem tekoi projekt? Delete this project? Zbriem ta projekt? Delete empty project %s? Zbriem prazen projekt %s? Action not yet implemented Dogodek e ni predviden Error deleting this project Napaka med brisanjem tega projekta Select a rule for the filter Izberi pravilo za filtriranje Enter keywords for the filter Vpiite kljuno besedo filtriranja Cancel Opusti Add this rule Dodaj to pravilo Please enter one or several keyword(s) for the rule Vpiite eno individualno besedo kljuno besedo za pravilo Add Scan Rule Dodaj iskano besedo Criterion Pogoj String String Add Dodaj Scan Rules Ii pravila Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Uporabite joker za izkljuitev/vkljuitev URL-jev ali povezav.\nLahko vstavite posamien string v eni vrstici.\nUporabite presledke ali separatorje.\n\nPrimer: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Exclude links Izkljui povezave Include link(s) Vkljui povezave Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) Namig: Za vkljuitev vseh GIF datotek uporabite kot npr. +www.spletnastran.com/*.gif. \n(+*.gif / -*.gif bo vkljuil/izkljuil vseh GIF-e z vseh spletnih strani) Save prefs Shrani lastnosti Matching links will be excluded: Zadete povezave bodo izkljuene: Matching links will be included: Zadete povezave bodo vkljuene: Example: Primer: gif\r\nWill match all GIF files gif\r\nBo vseboval vse GIF datoteke blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' blue\r\nNael bo vse datoteke z zadetki 'modro' pod string kot 'bluesky-small.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' bigfile.mov\r\nBo zadel datoteko 'bigfile.mov' toda ne 'bigfile2.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\nNael bo povezave z mapo kot zadetek z imenom pod string 'cgi' kot /cgi-bin/poljubwencgi.cgi cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\nNael bopovezave z zadetim imenom mapeing v celoti 'cgi-bin' string (toda ne cgi-bin-2, kot primer) someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb.com\r\nNael bo povezave z zadetim pod stringom kot www.spletnastran.com, private.spletnastran.com itn. someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. someweb\r\nNael bo povezave z zadeto mapo podstringa kot www.spletnastran.com, www.semeweb.edu, private.someweb.otherweb.com etc. www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.someweb.com\r\nNael bo povezave zadete kot 'www.someweb.com' pod string (toda ne povezave kot so private.someweb.com/..) someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. someweb\r\nNael bo povezave zadetih pod stringom kot www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/someweb.html\r\nNael bo le povezave kot 'www.test.com/test/someweb.html' datoteko. Pazite, da boste vpisali popolno pot (URL + pot spletne strani) All links will match Vse povezave bodo zadete Add exclusion filter Dodaj izkljuitveni filter Add inclusion filter Dodaj vkljutveni filter Existing filters Obstojei filtri Cancel changes Opusti spremembe Save current preferences as default values Shrani tekoe lastnosti kot privzete vrednosti Click to confirm Kliknite za potrditev No log files in %s! Ni log datoteke znotraj %s! No 'index.html' file in %s! Ni 'index.html' datoteke znotraj %s! Click to quit WinHTTrack Website Copier Kliknite za konec dela z WinHTTrack Website Copierom View log files Preglej log datoteke Browse HTML start page Prebrskaj zaetno HTML stran End of mirror Konec zrcaljenja View log files Preglej log datoteke Browse Mirrored Website Prebrskaj zrcaljeno stran New project... Novi projekt... View error and warning reports Preglej napake in varnostna poroila View report Preglej poroilo Close the log file window Zapri okno z log datoteko Info type: Errors Napake Infos Informacije Find Poii Find a word Poii besedo Info log file Informacije o log datoteki Warning/Errors log file Napaka/Napaka log datoteke Unable to initialize the OLE system Omogoi inicializacijo OLE sistema WinHTTrack could not find any interrupted download file cache in the specified folder! WinHTTrack ne najde nobene prekinitve naloene datoteke v doloeni mapi! Could not connect to provider Ne morem se povezati z oskrbovalcem receive prejem request zahteva connect povezava search iskanje ready pripravljen error napaka Receiving files.. Prejete datoteke.. Parsing HTML file.. Razlenjujem HTML datoteko.. Purging files.. istim datoteke.. Loading cache in progress.. Parsing HTML file (testing links).. Razlenjujem HTML datoteko (preverjam povezave).. Pause - Toggle [Mirror]/[Pause download] to resume operation Pavza - Stikalo [Zrcaljenje]/[Pavza prenosa] za dokonanje opravila Finishing pending transfers - Select [Cancel] to stop now! Dokonanje prenosov - Izbor [Opusti] za takojnjo zavstavitev! scanning iskanje Waiting for scheduled time.. akanje na as razporejanja.. Connecting to provider Povezava z oskrbovalcem [%d seconds] to go before start of operation [%d sekund] pred prietkom opravila Site mirroring in progress [%s, %s bytes] Site mirroring finished! Zrcaljenje strani je dokonano! A problem occurred during the mirroring operation\n Prilo je do napake med zrcaljenjem strani\n \nDuring:\n \nmed:\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! \nPreberite log datoteko, e je potrebno.\n\nKliknite na gumb KONANO za konec dele z WinHTTrack Website Copier.\n\nZahvaljujemo se za to, da ste uporabljali WinHTTrack! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! Zrcaljenje je popolnoma dokonano.\nKliknite na gumb Izhod za konec dela s programom WinHTTrack.\nPreberite log datoteko(e), e se elite prepriati, da je bilo vse vredu.\n\nZahvaljujemo se za to, da ste uporabljali WinHTTrack! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * ZRCALJENJE JE PREKINJENO! * *\r\nTekoi zaasni predpomnilnik je bil zahtevan za kaktere koli postopke nadgradnje in vsebuje le preneene podatke znotraj prekinjene seje.\r\nOblikovani predpomnilnik vsebuje ve popolnih informacij; e ne elite izgubiti teh podatkov jih lahko obnovite in zbriete tekoi predpomnilnik.\r\n[Opomba: To lahko enostavneje storite, e boste rono zbrisali hts-cache/ nemudoma * datoteke]\r\n\r\nMislite, da oblikovani predpomnilnik vsebuje ve popolnih informacij in jih elite obnoviti? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * NAPAKA MED ZRCALJENJEM! * *\r\nHTTrack je ugotovil, da je aktivno zrcaljenje prazno. e je bilo nadgrajeno bo obnovljeno prejnje zrcaljenje.\r\nVzrok: prva stran ni bila najdena ali pa vsebuje napake.\r\n=> Prepriajte se ali spletna stran sploh obstaja in/ ali ste preverili vae nastavitve proxy strenika! <= \n\nTip: Click [View log file] to see warning or error messages \n\nNamig: Kliknite na [Preglej log datoteko] kjer boste lahko prebrali vsa opozorila in sporoila o napakah Error deleting a hts-cache/new.* file, please do it manually Napaka med brisanjem hts-cache/ je nastala.* datotek, storite to rono! Do you really want to quit WinHTTrack Website Copier? Zares elite konadi delo z WinHTTrack Website Copierom? - Mirroring Mode -\n\nEnter address(es) in URL box - Nain z zrcaljenjem -\n\nVpiite naslov(e) v URL okence - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - Nain z interaktivnim arovnikom (vpraanja) -\n\nVpiite naslov(e) v URL okence - File Download Mode -\n\nEnter file address(es) in URL box - Nain s prenosom datotek -\n\nVpiite naslov(e) v URL okence - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - Nain s preverjanjem povezav -\n\nVpiite spletni naslov(e) s povezavami za preverjanje znotraj URL okenca - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Nadgrajevalni nain -\n\nPreverite naslov(e) znotraj URL okenca, preverite parametre, e je to potrebno in kliknite na gumb 'NAPREJ' ! - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Strnjeni nain (Prekinjena opravila) -\n\nPreverite naslov(e) znotraj URL okenca, preverite parametre, e je to potrebno in kliknite na gumb 'NAPREJ' ! Log files Path Pot do log datotek Path Pot - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror - Nain z seznamom povezav -\n\nUporabite URL okence za vpis naslova (ov spletne (straneh) za povezovanje zrcaljenja New project / Import? Novi projekt / Uvoz? Choose criterion Izberite pogoj Maximum link scanning depth Najveja globina iskanja povezav Enter address(es) here Tukaj vpiite naslov(e) Define additional filtering rules Doloite dodatna pravila filtriranja Proxy Name (if needed) Ime Proxy strenika (e je potrebno) Proxy Port Vrata Proxy-ja Define proxy settings Doloi nastavitve za proxy Use standard HTTP proxy as FTP proxy Uporabi obiajni HTTP proxy kot FTP proxy Path Pot Select Path Izberite pot Path Pot Select Path Izberite pot Quit WinHTTrack Website Copier Konec dela z WinHTTrack Website Copier About WinHTTrack Vizitka Save current preferences as default values Shrani tekoe nastavitve kot privzete vrednosti Click to continue Kliknite za nadaljevanje Click to define options Kliknite za doloitev opcij Click to add a URL Kliknite za dodajanje URL naslova Load URL(s) from text file Naloi URL(je) iz besedilne datoteke WinHTTrack preferences (*.opt)|*.opt|| WinHTTrack nastavitve (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| Besedilna datoteka z seznamom naslovov (*.txt)|*.txt|| File not found! Ni datoteke! Do you really want to change the project name/path? Zares elite spremeniti ime projekta/pot? Load user-default options? Naj naloim privzete uporabnike nastavitve? Save user-default options? Naj shranim privzete uporabnike nastavitve? Reset all default options? Naj obnovim vse privzete nastavitve? Welcome to WinHTTrack! Dobrodoli pri delu z WinHTTrack! Action: Opravilo: Max Depth Najveja globina Maximum external depth: Najveja zunanja globina: Filters (refuse/accept links) : Filtri (zlitje/uvaevanje povezav) : Paths Poti Save prefs Shrani nastavitve Define.. Doloi.. Set options.. Nastavi opcije.. Preferences and mirror options: Opcije nastavitev in zrcaljenja: Project name Ime projekta Add a URL... Dodaj URL... Web Addresses: (URL) Spletni naslovi: (URL) Stop WinHTTrack? Naj ustavim WinHTTrack? No log files in %s! Ni log datotek v %s! Pause Download? Zasno zaustavim prenos? Stop the mirroring operation Ustavi postopek zrcaljenja Minimize to System Tray Pomanjaj v sistemsko programsko vrstico Click to skip a link or stop parsing Kliknite za preskok povezave ali zavstavitev razlenitve Click to skip a link Kliknite za preskok povezave Bytes saved Shranjenih Bytov Links scanned Preiskanih povezav Time: as: Connections: Povezave: Running: Poteka: Hide Skrij Transfer rate Prenosna hitrost SKIP PRESKOI Information Informacije Files written: Zapisanih datotek: Files updated: Nadgrajenih datotek: Errors: Napake: In progress: Poteka: Follow external links Sledi zunanjim povezavam Test all links in pages Preverjaj vse povezave znotraj strani Try to ferret out all links Poskusi zavrei vse skrite povezave Download HTML files first (faster) Najprej prenesi HTML datoteke (hitreje) Choose local site structure Izberi strukturo lokalne strani Set user-defined structure on disk Nastavi uporabniko strukturo na disk Use a cache for updates and retries Uporabi predpomnilnik za nadgraditev in ponovitve Do not update zero size or user-erased files Ne nadgrajuj strani z nielno velikostjo ali uporabniko zbrisanih datotek Create a Start Page Naredi Zaetno stran Create a word database of all html pages Naredi besedilno bazo podatkov vseh html strani Create error logging and report files Naredi zgodovino napak (log) in datoteke s poroili Generate DOS 8-3 filenames ONLY Generiraj LE DOS 8-3 imena datotek Generate ISO9660 filenames ONLY for CDROM medias Generiraj LE ISO9660 imena datotek za CDROM medije Do not create HTML error pages Ne pripravi HTML strani z napakami Select file types to be saved to disk Izberi tipe datotek, ki bodo shranjene na disk Select parsing direction Izberi smer razlenjevanja Select global parsing direction Izberi splono smer razlenjevanja Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) Namesti pravila URL ponovnega branja za notranje povezave (prenesi enkrat) in zunanje povezave (ne prenesi enkrat) Max simultaneous connections Najve soasnih prikljuitev/povezav File timeout Pretek asa za datoteko Cancel all links from host if timeout occurs Opusti vse povezave z gostiteljem, e je potekal as Minimum admissible transfer rate Najkraji sprejemljivi prenosni as Cancel all links from host if too slow Opusti vse povezave z gostiteljem, e je le-ta prepoasen Maximum number of retries on non-fatal errors Najveje tevilo ponovitev on obiajnih napakah (ne fatalnih) Maximum size for any single HTML file Najveja velikost posamezne HTML datoteke Maximum size for any single non-HTML file Najveja velikost posamezne ne-HTML datoteke Maximum amount of bytes to retrieve from the Web Najvea koliina bytov za obnovo z spleta Make a pause after downloading this amount of bytes Naredi pavzo po renosu te koliine bitov Maximum duration time for the mirroring operation Najdalji as trajanja zrcaljenja Maximum transfer rate Najveja hitrost prenosa Maximum connections/seconds (avoid server overload) Najve povezav/sekund (izogibanje preobremenitvam strenika) Maximum number of links that can be tested (not saved!) Najveje tevilo povezav, ki jih je mono preverjati (ne shranjenih!) Browser identity Istovetnost brskalnika Comment to be placed in each HTML file Opombe bodo vstavljene v HTML dattekah Back to starting page Pojdi na zaetno stran Save current preferences as default values Shrani tekoe nastavitve kot privzete vrednosti Click to continue Klikni za nadaljevanje Click to cancel changes Klikni za opustitev sprememb Follow local robots rules on sites Zasleduj lokalnim robotovim pravilom na straneh Links to non-localised external pages will produce error pages Povezave z ne lokaliziranimi zunanjimi stranmi bodo povzroile napake strani Do not erase obsolete files after update Ne brii zastarelih datotek po nadgradnji Accept cookies? Uveljavim pikote? Check document type when unknown? Preveri tip dokumenta, e je neznan? Parse java applets to retrieve included files that must be downloaded? Razlenjuj java applete za obnovo vklljuenih datotek kadar morajo biti le-te preneene? Store all files in cache instead of HTML only Shrani vse datoteke v predpomnilnik namesto le HTML dokumenta Log file type (if generated) Tip log datoteke (e je bila narejena) Maximum mirroring depth from root address Najveja globina zrcaljenja z korenskega naslova Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) Najveja globina zrcaljenja za zunanje/prepovedane naslove (0= da, ne = privzeto) Create a debugging file Naredi razhroevalno datoteko Use non-standard requests to get round some server bugs Uporabi neobiajne zahteve posaminih napak strenika Use old HTTP/1.0 requests (limits engine power!) Uporabi stareje HTTP/1.0 zahteve (omejuje mo naprav!) Attempt to limit retransfers through several tricks (file size test..) Opozori na omejitve ponovnega prenosa z naigi (preverjanje doline datotek..) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Write external links without login/password apii zunanje povezave brez prijave/gesla Write internal links without query string Zapii notranje povezave brez poizvedovalnih stringov Get non-HTML files related to a link, eg external .ZIP or pictures Vzemi ne-HTML datoteke pridruene s povezavo, npr. zunanje .ZIP ali sklike Test all links (even forbidden ones) Preverjaj vse povezave (prvi e prepovedane) Try to catch all URLs (even in unknown tags/code) Poskusi zgrabiti vse URL-je (z ne znanimi tagi/kodo) Get HTML files first! Najprej vzemi HTML datoteke! Structure type (how links are saved) Tip strukture (kako so shranjene povezave) Use a cache for updates Uporabi predpomnilnik za nadgradnje Do not re-download locally erased files Ne nalagaj ponovno lokalno zbrisanih datotek Make an index Naredi indeks Make a word database Naredi podatkovno bazo besed Log files Log datoteke DOS names (8+3) DOS imena (8+3) ISO9660 names (CDROM) ISO9660 imena (CDROM) No error pages Ni napak strani Primary Scan Rule Primarno pravilo iskanja Travel mode Prenosni nain Global travel mode Sploni prenosni nain These options should be modified only exceptionally Te nastavitve spreminjajte le izjemoma Activate Debugging Mode (winhttrack.log) Aktiviraj Razhroevalni nain (winhttrack.log) Rewrite links: internal / external Ponovno zapii povezave: notranje / zunanje Flow control Nadzor poteka Limits Omejitve Identity Istovetnost HTML footer Glava HTML dokumenta N# connections tevilo prikljuitev Abandon host if error Zapusti gostitelja v primeru napake Minimum transfer rate (B/s) Najmanja hitrost prenosa (B/s) Abandon host if too slow Zapusti gostitelja, e je prepoasen Configure Nastavi Use proxy for ftp transfers Uporabi proxy za ftp prenose TimeOut(s) Premorov Persistent connections (Keep-Alive) Reduce connection time and type lookup time using persistent connections Retries Ponovitev Size limit Omejitev velikosti Max size of any HTML file (B) Najveja velikost katere koli HTML datoteke (B) Max size of any non-HTML file Najveja velikost katere koli ne-HTML datoteke Max site size Najveja velikost strani Max time Najdalji as Save prefs Shrani lastnosti Max transfer rate Najveja hitrost prenosa Follow robots.txt Zasleduj robots.txt No external pages Ni zunanjih strani Do not purge old files Ne poisti stare datoteke Accept cookies Sprejmi pikote Check document type Prevarjaj tip dokumenta Parse java files Razlenjuj java datoteke Store ALL files in cache Shrani VSE datoteke v predpomnilnik Tolerant requests (for servers) Toleriraj zahteve (za strenike) Update hack (limit re-transfers) Nadgradi pokaljevanje (omejitev ponovnih prenosov) URL hacks (join similar URLs) Force old HTTP/1.0 requests (no 1.1) Vsili stareje HTTP/1.0 zahteve (ne 1.1) Max connections / seconds Najve prikljuitev / sekund Maximum number of links Najveje tevilo povezav Pause after downloading.. Odmor po konanem prenosu.. Hide passwords Skrij gesla Hide query strings Skrij poizvedovalne stringe Links Povezave Build Izgradnja Experts Only Le za eksperte Flow Control Nadzor poteka Limits Omejitve Browser ID ID brskalnika Scan Rules Iskanje pravil Spider Hitrost Log, Index, Cache Log, Indeks, predpomnilnik Proxy Proxy MIME Types Do you really want to quit WinHTTrack Website Copier? Zares elite konati delo z WinHTTrack Website Copier? Do not connect to a provider (already connected) Ne povei se oskrbovalcem (povezava je e vspostavljena) Do not use remote access connection Ne uporabi oddaljeni dostop povezave Schedule the mirroring operation Razporedi opravila zrcaljenja Quit WinHTTrack Website Copier Konec dela z WinHTTrack Website Copier Back to starting page Nazaj na zaetno stran Click to start! Kliknite za zaetek! No saved password for this connection! Ni shranjenih gesel za to povezavo! Can not get remote connection settings Ne morem prevzeti nastavitev oddaljene povezave Select a connection provider Izberite oskrbovalca povezave Start Zani Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. Prosimo, da izravnate parametre povezovanja, e je potrebno \nter pritisnite na gumb KONEC za zagon zrcaljenja. Save settings only, do not launch download now. Le shrani nastavitve, ne poeni takoj prenosa. On hold Ob pritisku Transfer scheduled for: (hh/mm/ss) Razpored prenosov za: (uu/mm/ss) Start Zani Connect to provider (RAS) Povei se z oskrbnikom (RAS) Connect to this provider Povei se zs tem oskrbnikom Disconnect when finished Prekini povezavo, ko bo konano Disconnect modem on completion Izkljui modem ob dokonanju \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n(Prosimo Vas, da nas obvestite o kakrnih koli teavah ali napakah)\r\n\r\nRazvoj:\r\nVmesnik (Okna): Xavier Roche\r\nHitrost: Xavier Roche\r\nJavaParserRazredi: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche in drugi sodelujoi\r\nVELIKA ZAHVALA za namige prevodov gre:\r\nRobertu Lagadecu (rlagadec@yahoo.fr) About WinHTTrack Website Copier O programu WinHTTrack Website Copier Please visit our Web page Prosimo, da obiete nao spletno stran Wizard query arovnik poizvedb Your answer: Va odgovor: Link detected.. Ugotovljena povezava.. Choose a rule Izberite pravilo Ignore this link Prezri to povezavo Ignore directory Prezri mapo Ignore domain Prezri domeno Catch this page only Zagrabi le to stran Mirror site Zrcaljena stran Mirror domain Zrcaljena domena Ignore all Prezri vse Wizard query arovnik poizvedb NO ne File Datoteka Options Monosti Log Log datoteka Window Okna Help Pomo Pause transfer Pavza med prenosom Exit Izhod Modify options Sprememba monosti View log Preglej zgodovino View error log Preglej zgodovino napak View file transfers View file transfers Hide Skrij About WinHTTrack Website Copier O programu WinHTTrack Website Copier Check program updates... Preveri monost nadgradnje programa... &Toolbar &Orodjarna &Status Bar &Statusna vrstica S&plit &Razdeli File Datoteka Preferences Nastavitve Mirror Zrcaljena stran Log Log datoteka Window Okno Help Pomo Exit Izhod Load default options Naloi privzete nastavitve Save default options Shrani privzete nastavitve Reset to default options Obnovi privzete nastavitve Load options... Naloi monosti... Save options as... Shrani monosti kot... Language preference... Jezikovne nastavitve... Contents... Vsebine... About WinHTTrack... Vizitka... New project\tCtrl+N Novi Projekt\tCtrl+N &Open...\tCtrl+O &Odpri...\tCtrl+O &Save\tCtrl+S &Shrani\tCtrl+S Save &As... Shrani &Kot... &Delete... &Zbrii... &Browse sites... &Prebrskaj spletne strani... User-defined structure Uporabniko doloena struktura %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\tIme datoteke brez konnice (npr.: slika)\r\n%N\tIme datoteko s konnico (npr: slika.gif)\r\n%t\tLe konnica datoteke (npr: gif)\r\n%p\tPot [brez zakljuka /] (primer: /poljubnaslika)\r\n%h\tIme gostitelja (npr: www.poljubnastran.com)\r\n%M\tMD5 URL (128 bitov, 32 ascii bytov)\r\n%Q\tMD5 poizvedovalni string (128 bitov, 32 ascii bytov)\r\n%q\tMD5 majhen poizvedovalni string (16 bitov, 4 ascii bytov)\r\n\r\n%s?\tKratko ime (Npr.: %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Proxy settings Proxy nastavitve Proxy address: Proxy naslovi: Proxy port: Proxy vrata: Authentication (only if needed) Ugotavljanje pristnosti (le, e je potrebno) Login Prijava Password Geslo Enter proxy address here Tukaj vpiite naslov proxy-ja Enter proxy port here Tukaj vpiite vrata proxy-ja Enter proxy login Vpiite prijavo za proxy Enter proxy password Vpiite geslo za proxy Enter project name here Tukaj vpiite ime projekta Enter saving path here Tukaj vpiite pot shranjevanja Select existing project to update Izberite obstojei projekt za nadgradnjo Click here to select path Tukaj kliknite za izbor poti Select or create a new category name, to sort your mirrors in categories HTTrack Project Wizard... arovnik HTTrack projektov... New project name: Novo ime projekta: Existing project name: Ime obstojeega projekta: Project name: Naziv projekta: Base path: Osnovna pot: Project category: C:\\My Web Sites C:\\Moje spletne strani Type a new project name, \r\nor select existing project to update/resume Vpiite novo ime projekta, \r\nali izberite obstojee za nadgradnjo/prevzem New project Novi projekt Insert URL Vpiite URL URL: URL: Authentication (only if needed) Ugotavljanje pristnosti(le, e je zahtevano) Login Prijava Password Geslo Forms or complex links: Obrazci ali kompleksne povezave: Capture URL... Zagrabi URL... Enter URL address(es) here Tukaj vnesite URL naslov(e) Enter site login Vpis prijava na spletno stran Enter site password Vpiite geslo Use this capture tool for links that can only be accessed through forms or javascript code Uporabite to orodje za grabe za povezave, ki lahko izbajajo obrazce ali javascript codo Choose language according to preference Izberite jezik za izbor lastnosti Catch URL! Zagrabi URL! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. Prosimo, da nastavte zaasne nastavitve proxy brskalnika z naslednjimi vrednostmi (Kopiraj/Prilepi vrata in naslove Proxy-ja).\nPotem kliknite na gumb Opusti obrazca znotraj vae spletne strani ali pa kliknite na doloeno povezavo, ki jo elite zagrabiti. This will send the desired link from your browser to WinHTTrack. To bo poslalo izbrano povezavo z vaega brskalnika k WinHTTrack. ABORT PREKINITEV Copy/Paste the temporary proxy parameters here Tukaj Kopiraj/Prilepi zaasne proxy parametre Cancel Opusti Unable to find Help files! Omogoi iskanje datotek s pomojo! Unable to save parameters! Omogoi shranjevanje parametrov! Please drag only one folder at a time Prosimo, da zagrabite istoasno le eno mapo Please drag only folders, not files Prosimo, da zagrabite le mape, ne pa datotek Please drag folders only Prosimo, da zagrabite le mape Select user-defined structure? Naj izberem uporabniko doloeno strukturo? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! Preverite pravilnost uporabniko doloenega stringa,\ ker bodo imena ponarejena! Do you really want to use a user-defined structure? Resnino elite uporabljati uporabniko doloeno strukturo? Too manu URLs, cannot handle so many links!! Preve URL-jev, ne morem rokovati s tem tevilom povezav!! Not enough memory, fatal internal error.. Ni dovolj pomnilnika, usodna notranja napaka... Unknown operation! Neznano opravilo! Add this URL?\r\n Dodaj ta URL?\r\n Warning: main process is still not responding, cannot add URL(s).. Opozorilo: glavni proces je nepremien in ne morem dodati URL(je).. Type/MIME associations Tip/MIME zdruevanja File types: Datoteni tipi: MIME identity: MIME pristnost: Select or modify your file type(s) here Tukaj izberite ali urejajte va tip datotek Select or modify your MIME type(s) here Tukaj izberite Izbor ali uredite vae MIME tipe Go up Pojdi gor Go down Pojdi dol File download information Informacije o naloeni datoteki Freeze Window Zmrzni Okna More information: Ve podatkov: Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download Dobrodoli pri delu z WinHTTrack Website Copierom!\n\nKliknite na gumb NAPREJ za\n\n- zaetek novega projekta\n- ali dokonanje posameznih prenosov File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS Datoteke z podaljkom:\nImena datotek vsebujejo:\nTo ime datoteke:\nVsebina map z imenom:\nTo ime mape:\nPovezava z domeno:\nVsebina povezave z domeno:\nPovezava s tem gostiteljem:\nVebina povezave:\nTa povezava:\nVSE POVEZAVE Show all\nHide debug\nHide infos\nHide debug and infos Prikai vse\nSkrij razhroevanje\nSkrij informacije\nSkrij razhroevanje in informacije Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web Never\nIf unknown (except /)\nIf unknown Nikoli\ne je neznan (uveljavi /)\ne je neznan no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules ni robots.txt pravil\nrobots.txt izloen arovnik\nzasleduj robots.txt pravila normal\nextended\ndebug obiajno\nrazirjeno\nrazhroevanje Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download Prenos spletne (nih) strani\nPrenos spletne (nih) strani) + vpraanja\nPrevzem posameznih datotek\nPrenos vseh posaminih strani (vekratno zrcaljenje)\nPreverjanje povezav znotraj strani (preverjanje zaznamkov)\n* Nadaljevanje prekinjenih prenosov\n* Nadgradnja obstojeih prenosov Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL Relativni URL / Absolutni URL (privzeto)\nAbsolutni URL / Absolutni URL\nAbsolutni URI / Absolutni URL\nOriginalni URL / Originalni URL Open Source offline browser Website Copier/Offline Browser. Copy remote websites to your computer. Free. httrack, winhttrack, webhttrack, offline browser URL list (.txt) Previous Next URLs Warning Your browser does not currently support javascript. For better results, please use a javascript-aware browser. Thank you You can now close this window Server terminated A fatal error has occurred during this mirror httrack-3.49.5/lang/Slovak.txt0000644000175000017500000010363214360553245013132 00000000000000LANGUAGE_NAME Slovak LANGUAGE_FILE Slovak LANGUAGE_ISO sk LANGUAGE_AUTHOR Dr. Martin Sereday (sereday at stonline.sk)\r\n LANGUAGE_CHARSET ISO-8859-2 LANGUAGE_WINDOWSID Slovak OK no Cancel Zrui Exit Ukoni Close Zatvori Cancel changes Zrui zmeny Click to confirm Potvrdi zmeny Click to get help! Pomoc Click to return to previous screen Predchdzajca obrazovka Click to go to next screen Nasledujca obrazovka Hide password Skry heslo Save project Uloi projekt Close current project? Zatvori projekt? Delete this project? Vymaza projekt? Delete empty project %s? Vymaza przdne projekty? Action not yet implemented Akcia zatia nebola zaraden Error deleting this project Chyba pri mazan projektu Select a rule for the filter Vybra pravidlo filtra Enter keywords for the filter Vloi kov slovo pre filter Cancel Zrui Add this rule Prida toto pravidlo Please enter one or several keyword(s) for the rule Vlo jedno alebo niekoko kovch slov pre pravidlo Add Scan Rule Pridaj previdlo pre vyhadvanie Criterion Kritri String Reazec Add Pridaj Scan Rules Pravidl pre vyhadvanie Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Poui masky na vylenie alebo doplnenie URL alebo linkov. n\Do jednho riadku mono vloi aj viac reazcov.\nAko oddeova poui medzeru.n\n\Napr.: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Exclude links Vyli linky Include link(s) Prida linky Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) Tip: Ak sa maj zaradi vetky GIFy, poui napr. *www.strnka.com/.gif.\n(+*.gif /-*.gif bude onsahova/vyli veetky GIFy zo vetkch strnok). Save prefs Uloi nastavenia Matching links will be excluded: Zodpovedajce linky bud vylen Matching links will be included: Zodpovedajce linky bud zaraden Example: Napr.: gif\r\nWill match all GIF files gif\r\nZodpoved vetkm GIF sborom blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' blue\r\nNjde vetky sbory obsahujce skupinu znakov 'blue' - napr. 'bluesky-small.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' bigfile.mov\r\nZodpoved sborom 'bigfile.mov', ale nie 'bigfile2.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\nVyhad vetky linky s nzvom adresra obsahujcim skupinu znakov 'cgi' - napr. /cgi-bin/somecgi.cgi cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\nVyhad vetky linky s nzvom adresra obsahujcim skupinu znakov 'cgi-bin' (ale u nie napr. cgi-bin-2) someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb.com\r\nVyhad vetky zhodn reazce napr.: www.someweb.com, private.someweb.com at. someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. someweb\r\nVyhad vetky adresre obsahujce reazec napr.: www.someweb.com, www.someweb.edu, private.someweb.otherweb.com at. www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.someweb.com\r\nVyhad vetky linky obsahujce pln reazec napr.: 'www.someweb.com' (ale nie linky napr.: private.someweb.com/..) someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. someweb\r\nVyhad vetky linky obsahujce reazec napr.: www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html at. www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/someweb.html\r\nVyhad iba sbor 'www.test.com/test/someweb.html'. POZOR!, mus sa napsa pln cesta (URL + cesta v rmci truktry) All links will match Vetky linky sa bud zhodova Add exclusion filter Zada filter pre vylenie Add inclusion filter Zada filter pre zalenenie Existing filters Existujce filtre Cancel changes Zrui zmeny Save current preferences as default values Uloi aktulne nastavenia ako zkladn hodnoty Click to confirm Potvrdi kliknutm No log files in %s! V %s neexistuje protokol! No 'index.html' file in %s! V %s neexistuje sbor 'index.html ! Click to quit WinHTTrack Website Copier Vystpi z WinHTTrack Website Copier View log files Zobrazi protokoly Browse HTML start page Prezrie vodn strnku HTML End of mirror Koniec sahovania View log files Zobrazi protokoly Browse Mirrored Website Prezrie stihnut strnku New project... Nov projekt ... View error and warning reports Prezrie chybov a varovn hlsenia View report Pozrie hlsenie Close the log file window Zavrie okno protokolu Info type: Typ informcie: Errors Chyby Infos Informcie Find Njs Find a word Njs slovo Info log file Protokol informci Warning/Errors log file Protokol chb / varovan Unable to initialize the OLE system Ned sa incializova OLE systm WinHTTrack could not find any interrupted download file cache in the specified folder! WinHTTrack nenaiel iaden cache preruenho sboru v pecifikovanom adresri\r\n Could not connect to provider Ned sa spoji s providerom receive Prijmanie request Poiadavka connect Spojenie search Hdanie ready Pripraven error Chyba Receiving files.. Prijmanie sborov Parsing HTML file.. Analza HTML sboru... Purging files.. Uvonenie sboru Loading cache in progress.. Prebieha napanie chache.. Parsing HTML file (testing links).. Analza HTML sboru (testovanie linkov) Pause - Toggle [Mirror]/[Pause download] to resume operation Pauza - Pokraova [Strnka - Kpia]/[Zastavi koprovanie] Finishing pending transfers - Select [Cancel] to stop now! Ukonenie prebiehajcich prenosov - Zvo [Zrui]! scanning Skenovanie Waiting for scheduled time.. akanie na plnovan as... Connecting to provider Pripjanie providera [%d seconds] to go before start of operation [%d seknd] chba do zaiatku opercie Site mirroring in progress [%s, %s bytes] Prebieha koprovanie strnky [%s, %s bytov] Site mirroring finished! Koprovanie strnky ukonen! A problem occurred during the mirroring operation\n Poas koprovania sa vyskytol problm\n \nDuring:\n \nPoas:\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! \nAk treba, pozrie protokol.\n\n\r\nKliknutm na KONIEC opusti WinHTTrack Website Copier.\n\nVaka za pouitie WinHTTrack!\r\n Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! Opercia koprovania ukonen.\nKliknutm na Exit opusti WinHTTrack.\nPozrie protokoly sbor(y), ak sa treba uisti, e vetkoje v poriadku.\n\nVaka za pouitie WinHTTrack!\r\n * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * KOPROVANIE PRERUEN! * *\r\nAktulna doasn cache je potrebn prevetky aktualizan opercie a obsahuje iba dta stiahnut poas tejto preruenej opercie\r\nPredchdzajca chache me obsahova kompletnejie informcie. Ak sa tieto informcie nemaj strati, treba ju obnovi a vymaza terajiu aktulnu cache.\r\n[Poznmka: D sa to urobi teraz vymazanm sborov hts-cache/new.* ]\r\n\r\nObsahuje predchdzajca cache obsahuje kompletnejiu informciu a m sa obnovi?\r\n * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * CHYBA KOPROVANIA! * *\r\nHTTrack zistil, e tto kpia je przdna. Ak mala by aktualizovan, predchdzajca kpia bola obnoven.\r\nDvod: vodn strnka bu nebola njden, alebo nastal problm so spojenm.\r\n=> Presvedi sa, i webstrnka ete existuje a/alebo skontrolova vlastn nastavenie proxy! <= \n\nTip: Click [View log file] to see warning or error messages \n\nTip: Klikn na [Zobrazi protokol] a pozrie na upozornania alebo chybov hlsenia Error deleting a hts-cache/new.* file, please do it manually Chyba pri mazan sborov hts-cache/new.* . Vymaza rune Do you really want to quit WinHTTrack Website Copier? Naozaj opusti WinHTTrack Website Copier?\r\n - Mirroring Mode -\n\nEnter address(es) in URL box - Md koprovania -\n\nUda adresu(y) do polka URL - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - Md interaktvneho pomocnka (otzky) -\n\nUda adresu(y) do polka URL - File Download Mode -\n\nEnter file address(es) in URL box - Md koprovania sboru -\n\nUda adresu(y) sboru do polka URL - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - Md testovania linkov -\n\nUda adresu(y) www s linkami na otestovanie do polka URL - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Md aktualizcie -\n\nOveri si adresu(y) v polku URL, ak je nutn, skontrolova parametre, potom klikn na 'Next' - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Md pokraovania (preruenej opercie) -\n\nOveri si adresu(y) v polku URL, ak je nutn, skontrolova parametre, potom klikn na 'Next' Log files Path Cesta k sborom s protokolmi Path Cesta - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror - Md zoznamu linkov -\n\nPoui polko URL na zadanie adresy (adries) sboru(ov) obsahujcich linky ku kpii\r\n New project / Import? Nov projekt / Import? Choose criterion Zvoli kritri Maximum link scanning depth Maximlna hbka skenovania linkov Enter address(es) here Sem zada adresu(y) Define additional filtering rules Definova dodaton pravidl filtrovania Proxy Name (if needed) Meno proxy (ak je potrebn) Proxy Port Port proxy Define proxy settings Definova nastavenie proxy Use standard HTTP proxy as FTP proxy Poui tandardn HTTP proxy ako FTP proxy Path Cesta Select Path Vybra cestu Path Cesta Select Path Vyba cestu Quit WinHTTrack Website Copier Ukoni WinHTTrack Website Copier About WinHTTrack O WinHTTrack... Save current preferences as default values Uloi aktulne nastavenia ako zkladn hodnoty Click to continue Kliknutm pokraova Click to define options Klikn a definova nastavenia Click to add a URL Klikuntm vlo URL Load URL(s) from text file Nata URL z textovho sboru WinHTTrack preferences (*.opt)|*.opt|| WinHTTrack - nastavenia (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| Textov sbor so zoznamom adries (*.txt)|*.txt|| File not found! Sbor nenjden! Do you really want to change the project name/path? Naozaj zmeni nzov/umiestnenie projektu? Load user-default options? Nata uvatesk - zkladn nastavenia? Save user-default options? Uloi uvatesk - zkladn nastavenia? Reset all default options? Obnovi vetky zkladn nastavenia? Welcome to WinHTTrack! Vitaj vo WinHTTrack! Action: Akcia: Max Depth Maximlna hbka: Maximum external depth: Maximlna extern hbka: Filters (refuse/accept links) : Filtre (odmietni/potvr linky): Paths Cesty Save prefs Uloi nastavenia Define.. Definova... Set options.. Nastavi nastavenia... Preferences and mirror options: Nastavenia a nastavenia kpie: Project name Nzov projektu Add a URL... Zadaj URL... Web Addresses: (URL) Adresa www: (URL) Stop WinHTTrack? Zastavi WinHTTrack? No log files in %s! iadne protokoly v %s! Pause Download? Pozastavi koprovanie? Stop the mirroring operation Zastavi operciu koprovania Minimize to System Tray Minimalizova na systmov litu Click to skip a link or stop parsing Klinutm preskoi link alebo zastavi analzu Click to skip a link Kliknutm preskoi link Bytes saved Uloen byty Links scanned Skenovan linky Time: as: Connections: Spojenia: Running: Prebieha: Hide Skry Transfer rate rove prenosu: SKIP PRESKOI Information Informcie Files written: Zapsan sbory: Files updated: Aktualizovan sbory: Errors: Chyby: In progress: Spracovva sa: Follow external links Prehada vonkajie linky Test all links in pages Testova vetky linky na strnkach Try to ferret out all links SKsi prehada vetky linky Download HTML files first (faster) Skoprova najprv sbory HTML (rchlejie) Choose local site structure Zvoli vntorn truktru strnky Set user-defined structure on disk Nastavi uvatesky definovn truktru na disku Use a cache for updates and retries Poui cache pre aktualizcie a obnovenia Do not update zero size or user-erased files Neaktualizova przdne sbory alebo sbory vymazan uvateom Create a Start Page Vytvori vodn strnku Create a word database of all html pages Vytvori databzu vetkch slov ako html strnky Create error logging and report files Vytvori protokoly chb a hlsen Generate DOS 8-3 filenames ONLY Vytvori LEN DOS-ovsk 8-3 nzvy sborov Generate ISO9660 filenames ONLY for CDROM medias Vytvor nzvy ISO9660 IBA PRE CD ROM. Do not create HTML error pages Nevytvra HTML chybov strnky Select file types to be saved to disk Vybra typy sborov, ktor maj by uloen na disk Select parsing direction Vybra poradie anaklzy Select global parsing direction Vybra globlnu analzu Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) Nastav URL prepsanm pravidiel pre vntorn linky (u skoprovan) a vonkajie linky (ete neskoprovan). Max simultaneous connections Maximum sasnch spojen File timeout Maximlna akacia doba pre sbory Cancel all links from host if timeout occurs Po vypran akacej doby zrui vetky spojenia Minimum admissible transfer rate Najniia prpustn rove prenosu Cancel all links from host if too slow Zrui vetky spojenia, ak je prenos prli pomal Maximum number of retries on non-fatal errors Maximlny poet pokusov pri nepodstatnch chybch Maximum size for any single HTML file Maximlna vekos jednotlivho HTML sboru Maximum size for any single non-HTML file Maximlna vekos pre jednotliv nie-HTML sbor Maximum amount of bytes to retrieve from the Web Maximlny poet bytov koprovanch z www Make a pause after downloading this amount of bytes Po skoprovan tohoto mnostva urobi pauzu Maximum duration time for the mirroring operation Maximlny as pre kokprovanie Maximum transfer rate Maximlna rove koprovania Maximum connections/seconds (avoid server overload) Maximum spojen za sekundu (predchdza preaeniu servera) Maximum number of links that can be tested (not saved!) Maximum linkov, ktor maj by testovan (nie uloen!) Browser identity Identifikcia prehliadaa Comment to be placed in each HTML file Komentr, ktor m by umiestnen do kadho HTML sboru Back to starting page Sp na vodn strnku Save current preferences as default values Uloi aktulne nastavenia ako zkladn hodnoty Click to continue Pokraova Click to cancel changes Zrui zmeny Follow local robots rules on sites Prija pravidl loklneho robota na strnkach Links to non-localised external pages will produce error pages Linky na nelokalizovan extern strnky vyprodukuj chybn strnky Do not erase obsolete files after update Po aktualizcii nevymazva prebyton strnky Accept cookies? Prija cookies ? Check document type when unknown? Kontrolova dokumenty, ak nie je znmy ich typ? Parse java applets to retrieve included files that must be downloaded? Analyzova Java applety, aby sa zistilo, ktor sbory musia by koprovan? Store all files in cache instead of HTML only Uloi vetky sbory v cache, nie iba v HTML Log file type (if generated) Typ protokolu (ak bol vytvoren) Maximum mirroring depth from root address Maximlny hbka koprovania od koreovej adresy Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) Maximlna hbka koprovania externch/zakzanch adries (0 znamen iadna - zkladn nastavenie) Create a debugging file Vytvori debugovac sbor Use non-standard requests to get round some server bugs Poui netandardn poiadavky na obdenie jednotlivch chb servera Use old HTTP/1.0 requests (limits engine power!) Poui star HTTP/1.0 pouadavky (obmdzuje pracovn tempo!) Attempt to limit retransfers through several tricks (file size test..) Poksi sa rznymi trikmi obmedzi opakovan transfry (test vekosti sborov). Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Write external links without login/password Zada vonkajie linky bez uvateskho mena/hesla Write internal links without query string Psa vntorn linky bez overovacch reazcov Get non-HTML files related to a link, eg external .ZIP or pictures Prebra in, ne HTML sbory svisiace s linkom, napr. extern ZIP sbory alebo obrzky Test all links (even forbidden ones) Testova vetky linky (aj zakzan) Try to catch all URLs (even in unknown tags/code) Poksi sa zachyti vetky URL (vrtane neznmych tagov/kdov) Get HTML files first! Prebra najprv HTML sbory! Structure type (how links are saved) Typ truktry (ako bud linky uloen) Use a cache for updates Na aktualiizciu poui cache Do not re-download locally erased files Nesahova znovu loklne vymazan sbory Make an index Vytvori index Make a word database Vytvori slovn databzu Log files Log sbory DOS names (8+3) DOS nzvy (8+3) ISO9660 names (CDROM) Nzvy ISO9660 (CD ROM) No error pages iadne chybov strnky Primary Scan Rule Zkladn skenovacie pravidl Travel mode Vyhadvac md Global travel mode Globlny vyhadvac md These options should be modified only exceptionally Tieto pravidl maj by upravovan iba vnimone Activate Debugging Mode (winhttrack.log) Aktivova md vyhadvania chb (winhttrack.log) Rewrite links: internal / external Prep linky: vntorn / vonkajie Flow control Kontrola toku Limits Limity Identity Identita HTML footer Pta HTML N# connections Poet spojen Abandon host if error V prpade chyby opusti zdroj Minimum transfer rate (B/s) Minimlna rove sahovania (B/s) Abandon host if too slow Opusti zdroj, ak je prenos prli pomal Configure Konfigurova Use proxy for ftp transfers Pre prenosy cez ftp poui proxy TimeOut(s) Interval(y) akania Persistent connections (Keep-Alive) Trval spojenie (Udra-iv) Reduce connection time and type lookup time using persistent connections Zn dobu pripojenia a zadaj as vyhadvania pri trvalch spojeniach Retries Optovn pokusy Size limit Limity vekosti Max size of any HTML file (B) Maximlna vekos jednotlivho HTML sboru (B) Max size of any non-HTML file Maximlna vekos inho ako HTML sboru Max site size Maximlna vekos strnky Max time Maximlny as Save prefs Uloi nastavenia Max transfer rate Maximlna rove prenosu Follow robots.txt Poui pravidl z robots.txt No external pages iadne extern strnky Do not purge old files Nevyprzdva star sbory Accept cookies Prija cookies Check document type Overi typ dokumentu Parse java files Analyzova sbory v Jave Store ALL files in cache Vetky sbory uloi do cahce Tolerant requests (for servers) Prpustn poiadavky (pre servery) Update hack (limit re-transfers) Trik pre aktualizciu (obmedzenie opakovanch prenosov) URL hacks (join similar URLs) Force old HTTP/1.0 requests (no 1.1) Poui star pravidl HTTP/1.0 (nie 1.1) Max connections / seconds Maximlny poet spojen Maximum number of links Maximlny poet linkov Pause after downloading.. Pauza po skoprovan Hide passwords Skry heslo Hide query strings Skry vyhadvacie reazce Links Linky Build Vytvori Experts Only Iba pre expertov Flow Control Kontrola toku Limits Limity Browser ID ID prehliadaa Scan Rules Pravidl skenovania Spider Pavk Log, Index, Cache Log, index, cache Proxy Proxy MIME Types Do you really want to quit WinHTTrack Website Copier? Naozaj chce ukoni WinHTTrack Website Copier? Do not connect to a provider (already connected) Nepripja providera (u je pripojen) Do not use remote access connection Nepouiva spojenie diakovho ovldania Schedule the mirroring operation Naplnova koprovanie Quit WinHTTrack Website Copier Ukoni WinHTTrack Website Copier Back to starting page Sp na tartovaciu strnku Click to start! Spusti! No saved password for this connection! Pre toto spojenie nie s uloen iadne hesl! Can not get remote connection settings Nemono zska nastavenia pre vzdialen spojenie Select a connection provider Vybra poskytovatea spojenia Start tart Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. V prpade potreby nastavi parametre spojenia,\npotom stlai DOKONI na spustenie koprovania. Save settings only, do not launch download now. Uloi nastvenia, nespa teraz koprovanie. On hold Zastavi Transfer scheduled for: (hh/mm/ss) Koprovanie naplnovan na: (hh/mm/ss) Start tart! Connect to provider (RAS) Spoji s poskytovateom (RAS) Connect to this provider Pripoji k tomuto poskytovateovi Disconnect when finished Odpoji, ak je koprovanie ukonen Disconnect modem on completion Odpoji modem po dokonen \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n(Oznm nm akkovek chybu alebo problm)\r\n\r\nVvoj:\r\nProstredie (Windows): Xavier Roche\r\nPavk: Xavier Roche\r\nKontrolr Javy: Yann Philippot\r\n\r\n(C)1998-2001 Xavier Roche a ostatn pomocnci\r\nVEK POAKOVANIE za preklady:\r\nDr. Martin Sereday (sereday@slovanet.sk) About WinHTTrack Website Copier O WinHTTrack Website Copier... Please visit our Web page Navtv nau web strnku Wizard query Otzky pomocnka Your answer: Tvoja odpove: Link detected.. Njden link. Choose a rule Zvoli pravidlo Ignore this link Ignoroav tento link Ignore directory Ignorova adresr Ignore domain Ignorova domnu Catch this page only Prebra iba tto stranu Mirror site Umiestnenie zrkadla Mirror domain Domna zrkadla Ignore all Ignorova vetky Wizard query Otzka pomocnka NO NIE File Sbor Options Voby Log Protokol Window Okno Help Pomoc Pause transfer Prestvka koprovania Exit Zavrie Modify options Upravi nastavenia View log Ukza protokol View error log Ukza protokol chb View file transfers Ukza prenosy sbporov Hide Skry About WinHTTrack Website Copier O WinHTTrack Website Copier... Check program updates... Skontrolova aktualizcie WinHTTrack... &Toolbar &Nstrojov lita &Status Bar &Stavov riadok S&plit R&ozdeli File Sbor Preferences Nastavenia Mirror Zrkadlo Log Protokol Window Okno Help Pomoc Exit Zavrie Load default options Nata povinn nastavenia Save default options Uloi povinn nastavenia Reset to default options Obnovi povinn nastavenia Load options... Nata nastavenia... Save options as... Uloi nastavenia ako... Language preference... Nastavenia jazyka... Contents... Obsah... About WinHTTrack... O Win HTTrack... New project\tCtrl+N Nov projekt\tCtrl+N &Open...\tCtrl+O &Otvori...\tCtrl+O &Save\tCtrl+S &Uloi\tCtrl+S Save &As... Uloi ako... &Delete... &Vymaza... &Browse sites... &Prezera strnky... User-defined structure truktra definovan uvateom %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\tNzov sboru bez udania typu (napr.: obrzok)\r\n%N\tNzov sboru vrtane typu (napr.: obrzok.gif)\r\n%t\tIba typ sboru (napr.: gif)\r\n%p\tCesta bez ukonenia /] (napr.: /obrzky)\r\n%h\tNzov zdroja (napr.: www.someweb.com)\r\n%M\tMD5 URL (128 bitov, 32 ascii bytov)\r\n%Q\tMD5 vyhadvac reazec (128 bitov, 32 ascii bytov)\r\n%q\tMD5 mal vyhadvac reazec (16 bitov, 4 ascii bytov)\r\n\r\n%s?\tKrtky nzov (napr.: %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Prklad:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Proxy settings Nastavenie proxy Proxy address: Adresa proxy Proxy port: Port proxy Authentication (only if needed) Autentifikcia (iba ak je potrebn) Login Login Password Heslo Enter proxy address here Sem vloi adresu proxy Enter proxy port here Sem vloi port proxy Enter proxy login Vloi login proxy Enter proxy password Vloi heslo proxy Enter project name here Sem vloi nzov projektu Enter saving path here Sem vloi cestu uloenia Select existing project to update Vybra existujci projekt, ktor m by aktualizovan Click here to select path Klikn sem a vybra cestu Select or create a new category name, to sort your mirrors in categories HTTrack Project Wizard... HTTrack Project Wizard... New project name: Nzov novho projektu: Existing project name: Nzov existujceho projektu: Project name: Nzov porjektu: Base path: Zkladn cesta: Project category: C:\\My Web Sites C:\\My Web Sites Type a new project name, \r\nor select existing project to update/resume Napsa nzov novho projektu, alebo zvoli existujci projekt, \r\nv ktorom sa m pokraova alebo aktualizova\r\n New project Nov projekt Insert URL Vloi URL URL: URL: Authentication (only if needed) Autentifikcia (iba ak je potrebn) Login Login Password Heslo Forms or complex links: Formulre alebo komplexn linky: Capture URL... Prebra URL... Enter URL address(es) here Sem vloi adresu(y) URL Enter site login Vloi login strnky Enter site password Vloi heslo strnky Use this capture tool for links that can only be accessed through forms or javascript code Poui tento snmac nstroj pre linky, ktor mu by prstupn iba cez formulre alebo java scripty Choose language according to preference Zvoli jazyk poda nastaven Catch URL! Prebra URL! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. Nastavi doasne nastavenia proxy prehliadaa na tieto hodnoty (Koprova/Vloi adresa a port proxy).\n\rPotom klikn na tlaidlo POLI na strnke prehliadaa, alebo klikn na konkrtny link, ktor sa m prevzia.\r\n This will send the desired link from your browser to WinHTTrack. Toto odole poadovan link z tvojho prehliadaa do WinHTTrack. ABORT PRERUI Copy/Paste the temporary proxy parameters here Koprova/Vloi sem doasn parametre proxy Cancel Zrui Unable to find Help files! Neviem njs sbory npovedy! Unable to save parameters! Nemem uloi parametre! Please drag only one folder at a time Sahova sasne iba jedin adresr Please drag only folders, not files Sahova iba adresre, nie sbory Please drag folders only Sahova iba adresre Select user-defined structure? Vybra truktru definovan uvateom? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! Presvedi sa, e uvateom definovan reazec je sprvny,\ninak bud nzvy sborov chybn! Do you really want to use a user-defined structure? Naozaj sa m poui uvateom definovan truktra? Too manu URLs, cannot handle so many links!! Prli vea URL, neviem zvldnu tak vea linkov! Not enough memory, fatal internal error.. Nedostatok pamti, zvan intern chyba... Unknown operation! Neznma opercia! Add this URL?\r\n Prida toto URL?\r\n Warning: main process is still not responding, cannot add URL(s).. Upozornenie: hlavn proces ete stle neodpoved, nemem prida URL.. Type/MIME associations Typ/MIME priradenia File types: Typ sborov: MIME identity: Identita MIME: Select or modify your file type(s) here Vybra alebo upravi typ sboru(ov) Select or modify your MIME type(s) here Vybera alebo upravi MIME sboru(ov) Go up Nahor Go down Nadol File download information Informcie pre koprovanie Freeze Window Fixova okno More information: Viac informci Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download Vitaj vo WinHTTrack Website Copier!\n\nKlikn na tlaidlo NEXT \n\n- a spusti nov projekt\n- alebo pokraova v iastone skoprovanom File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS Nzvy sborov s prponou:\nNzvy sborov obsahujcich:\nNzov tohoto sboru:\nNzvy adresrov obsahujcich:\nNzov tohoto adresra:\nLinky na tejto domne:\nLinky na domnach obsahujcich:\nLinky z tohoto hostu:\nLinky obsahujce:\nTento link:\nVETKY LINKY Show all\nHide debug\nHide infos\nHide debug and infos Ukza vetko\nSkry ladenie\nSkry informcie\nSkry ladenie a informcie Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. truktra strnky (default)\nHtml vo webe/, obrzky/in sbory vo webe/obrzky/\nHtml vo webe/html, obrzky/in vo webe/obrzky\nHtml vo webe/, obrzky/in vo webe/\nHtml vo webe/, obrzky/in vo webe/xxx, kde xxx je prpona sboru\nHtml vo webe/html, obrzky/in vo webe/xxx\ntruktra strnky, bez www.domna.xxx/\nHtml v nzve strnky/, obrzky/in sbory v nzve strnky/obrzky/\nHtml v nzve strnky/html, obrzky/in v nzve strnky/obrzky\nHtml v nzve strnky/, obrzky/in v nzve strnky/\nHtml v nzve strnky/, obrzky/in v nzve strnky/xxx\nHtml v nzve strnky/html, obrzky/in v nzve strnky/xxx\nVetky sbory vo webe/, s nhodnmi menami (gadget !)\nVetky sbory v nzve strnky/, s nhodnmi menami (gadget !)\nUvateom definovan truktra.. Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first Iba skenova\nUloi html sbory\nUloi nie-html sbory\nUloi vetky sbory (default)\nUloi najprv html sbory Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down Osta v tom istom adresri\nMono s niie (default)\nMono s vyie\nMono s niie aj vyie Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web Osta na tej istej adrese (default)\nOsta na tej istej domne\nOsta -//- najvyej rovne\ns hocikam na webe Never\nIf unknown (except /)\nIf unknown Nikdy\nAk nie je znme (s vnimkou/)\nAk nie je znme no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules Ignorova pravidl v robots.txt\nPrevza pravidl -//- okrem filtrov\nPrevzia vetky pravidl v -//- normal\nextended\ndebug normlny\nrozren\nladenie Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download Skopruj web strnku(y)\nSkopruj web strnku(y) + otzky\nPreber jednotliv sbory\nSkopruj vetky umiestnenia na stnkach (viacnsobn zrkadlo)\nOtestuj linky na strnkach (testuj zloky)\n* Pokrauj v preruenom koprovan\n* Aktualizuj existujce kpie Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL Relatvna URI / Absoltna URL (prednastaven)\nABsoltna URL / Absoltna URL\nAbsoltna URL\nPvodn URL / Pvodn URL Open Source offline browser Website Copier/Offline Browser. Copy remote websites to your computer. Free. httrack, winhttrack, webhttrack, offline browser URL list (.txt) Previous Next URLs Warning Your browser does not currently support javascript. For better results, please use a javascript-aware browser. Thank you You can now close this window Server terminated A fatal error has occurred during this mirror httrack-3.49.5/lang/Russian.txt0000644000175000017500000010641614360553245013322 00000000000000LANGUAGE_NAME Russian LANGUAGE_FILE Russian LANGUAGE_ISO ru LANGUAGE_AUTHOR Andrei Iliev (iliev at vitaplus.ru) \r\n LANGUAGE_CHARSET windows-1251 LANGUAGE_WINDOWSID Russian OK OK Cancel Exit Close Cancel changes Click to confirm Click to get help! Click to return to previous screen Click to go to next screen Hide password Save project Close current project? ? Delete this project? ? Delete empty project %s? %s? Action not yet implemented Error deleting this project Select a rule for the filter Enter keywords for the filter Cancel Add this rule Please enter one or several keyword(s) for the rule Add Scan Rule Criterion : String : Add Scan Rules Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi / \n .\n: +*.zip -www.*.com,-www.*.edu/cgi-bin/*.cgi Exclude links ... Include link(s) ... Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) : gif-, , , +www.someweb.com/*.gif. \n(+*.gif / -*.gif / gif- ) Save prefs Matching links will be excluded: , : Matching links will be included: , : Example: : gif\r\nWill match all GIF files gif\r\n gif ( GIF) blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' blue\r\n , 'blue', 'bluesky-small.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' bigfile.mov\r\n 'bigfile.mov', , , 'bigfile2.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\n , 'cgi', /cgi-bin/somecgi.cgi cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\n , 'cgi-bin' ( cgi-bin-2, ) someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb.com\r\n , www.someweb.com, private.someweb.com .. someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. someweb\r\n www.someweb.com, www.someweb.edu, private.someweb.otherweb.com ..\r\n www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.someweb.com\r\n , www.someweb.com/... ( , private.someweb.com/..) someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. someweb\r\n , www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html .. www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/someweb.html\r\n www.test.com/test/someweb.html. , - (www.xxx.yyy) (/test/someweb.html) All links will match Add exclusion filter Add inclusion filter Existing filters Cancel changes Save current preferences as default values Click to confirm No log files in %s! %s! No 'index.html' file in %s! index.html %s! Click to quit WinHTTrack Website Copier WinHTTrack Website Copier View log files Browse HTML start page html End of mirror View log files log Browse Mirrored Website New project... ... View error and warning reports View report Close the log file window Info type: Errors Infos Find Find a word Info log file - Warning/Errors log file / Unable to initialize the OLE system OLE WinHTTrack could not find any interrupted download file cache in the specified folder! WinHTTrack ! Could not connect to provider receive request connect search ready error Receiving files.. .. Parsing HTML file.. HTML ... Purging files.. ... Loading cache in progress.. .. Parsing HTML file (testing links).. HTML ( )... Pause - Toggle [Mirror]/[Pause download] to resume operation ( []/[ ]) Finishing pending transfers - Select [Cancel] to stop now! - , Cancel! scanning Waiting for scheduled time.. .. Connecting to provider [%d seconds] to go before start of operation [%d ] Site mirroring in progress [%s, %s bytes] [%s, %s ] Site mirroring finished! ! A problem occurred during the mirroring operation\n \n \nDuring:\n :\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! , .\n\n WinHTTrack OK.\n\n WinHTTrack! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! .\n OK.\n ().\n\n WinHTTrack! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * ! * *\r\n , , , .\r\n, . , .\r\n( , hts-cache/new.]\r\n\r\n , , ? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * ! * *\r\n - . , .\r\n: () , .\r\n=> , , / -! <= \n\nTip: Click [View log file] to see warning or error messages \n: [ ] Error deleting a hts-cache/new.* file, please do it manually hts-cache/new.* , , .\r\n Do you really want to quit WinHTTrack Website Copier? WinHTTrack? - Mirroring Mode -\n\nEnter address(es) in URL box - -\n\n () URL. - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - - ( ) -\n\n () URL. - File Download Mode -\n\nEnter file address(es) in URL box - -\n\n () URL. - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - -\n\n () , URL', . - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - -\n\n () URL, '' . - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - -\n\n () URL, '' . Log files Path Path - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror -\n\n URL () () . New project / Import? / ? Choose criterion Maximum link scanning depth . Enter address(es) here Define additional filtering rules Proxy Name (if needed) , Proxy Port - Define proxy settings Use standard HTTP proxy as FTP proxy HTTP FTP Path Select Path Path Select Path Quit WinHTTrack Website Copier WinHTTrack Website Copier About WinHTTrack WinHTTrack Save current preferences as default values Click to continue Click to define options Click to add a URL URL Load URL(s) from text file URL() WinHTTrack preferences (*.opt)|*.opt|| WinHTTrack (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| (*.txt)|*.txt|| File not found! ! Do you really want to change the project name/path? /? Load user-default options? ? Save user-default options? ? Reset all default options? ? Welcome to WinHTTrack! WinHTTrack ! Action: : Max Depth . : Maximum external depth: : Filters (refuse/accept links) : (/ ) Paths Save prefs Define.. ... Set options.. ... Preferences and mirror options: : Project name Add a URL... URL... Web Addresses: (URL) : (URL) Stop WinHTTrack? WinHTTrack? No log files in %s! %s! Pause Download? ? Stop the mirroring operation Minimize to System Tray Click to skip a link or stop parsing Click to skip a link Bytes saved : Links scanned : Time: : Connections: : Running: : Hide Transfer rate : SKIP Information Files written: : Files updated: : Errors: : In progress: : Follow external links Test all links in pages Try to ferret out all links Download HTML files first (faster) HTML- () Choose local site structure Set user-defined structure on disk Use a cache for updates and retries Do not update zero size or user-erased files , , Create a Start Page Create a word database of all html pages , html- Create error logging and report files Generate DOS 8-3 filenames ONLY DOS- 8.3 Generate ISO9660 filenames ONLY for CDROM medias ISO9660 CDROM Do not create HTML error pages html- Select file types to be saved to disk , Select parsing direction Select global parsing direction Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) () ( ) Max simultaneous connections File timeout Cancel all links from host if timeout occurs Minimum admissible transfer rate Cancel all links from host if too slow , , Maximum number of retries on non-fatal errors , . Maximum size for any single HTML file html- Maximum size for any single non-HTML file HTML- Maximum amount of bytes to retrieve from the Web , Make a pause after downloading this amount of bytes , Maximum duration time for the mirroring operation . Maximum transfer rate . Maximum connections/seconds (avoid server overload) . ( ) Maximum number of links that can be tested (not saved!) (, !) Browser identity ( User-Agent) Comment to be placed in each HTML file , HTML Back to starting page Save current preferences as default values Click to continue Click to cancel changes Follow local robots rules on sites , Links to non-localised external pages will produce error pages ( ) Do not erase obsolete files after update Accept cookies? cookies? Check document type when unknown? , ? Parse java applets to retrieve included files that must be downloaded? - ? Store all files in cache instead of HTML only , HTML Log file type (if generated) log Maximum mirroring depth from root address . Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) / (0, .., , ) Create a debugging file Use non-standard requests to get round some server bugs , Use old HTTP/1.0 requests (limits engine power!) HTTP/1.0 ( !) Attempt to limit retransfers through several tricks (file size test..) ( ..) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) , (www.foo.com==foo.com, http=https ..) Write external links without login/password / Write internal links without query string ( ?) Get non-HTML files related to a link, eg external .ZIP or pictures -html (.: .ZIP . ) Test all links (even forbidden ones) ( ) Try to catch all URLs (even in unknown tags/code) URL' ( /) Get HTML files first! HTML ! Structure type (how links are saved) ( ) Use a cache for updates Do not re-download locally erased files Make an index Make a word database Log files Log DOS names (8+3) DOS- (8+3) ISO9660 names (CDROM) ISO9660 (CDROM) No error pages Primary Scan Rule Travel mode Global travel mode These options should be modified only exceptionally , Activate Debugging Mode (winhttrack.log) (winhttrack.log) Rewrite links: internal / external : / Flow control Limits Identity HTML footer HTML N# connections N# Abandon host if error , Minimum transfer rate (B/s) (B/s) Abandon host if too slow , Configure Use proxy for ftp transfers ftp- TimeOut(s) - Persistent connections (Keep-Alive) (Keep-Alive) Reduce connection time and type lookup time using persistent connections Retries Size limit Max size of any HTML file (B) . html-: Max size of any non-HTML file . -html: Max site size . Max time . Save prefs Max transfer rate . Follow robots.txt robots.txt No external pages Do not purge old files Accept cookies cookies Check document type Parse java files Store ALL files in cache Tolerant requests (for servers) ( ) Update hack (limit re-transfers) Update hack ( ) URL hacks (join similar URLs) URL ( URLs) Force old HTTP/1.0 requests (no 1.1) HTTP/1.0 ( 1.1) Max connections / seconds . /. Maximum number of links Pause after downloading.. ... Hide passwords Hide query strings (, ?) Links Build Experts Only Flow Control Limits Browser ID Scan Rules Spider Log, Index, Cache , . Proxy MIME Types MIME Types ( ) Do you really want to quit WinHTTrack Website Copier? ? Do not connect to a provider (already connected) ( ) Do not use remote access connection Schedule the mirroring operation Quit WinHTTrack Website Copier WinHTTrack Website Copier Back to starting page Click to start! ! No saved password for this connection! Can not get remote connection settings Select a connection provider , Start Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. , , Save settings only, do not launch download now. , . On hold Transfer scheduled for: (hh/mm/ss) : (hh/mm/ss) Start ! Connect to provider (RAS) (RAS) Connect to this provider Disconnect when finished Disconnect modem on completion \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n( )\r\n\r\n:\r\n (Windows): Xavier Roche\r\n (spider): Xavier Roche\r\n -: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for Russian translations to:\r\nAndrei Iliev (andreiiliev@mail.ru) About WinHTTrack Website Copier WinHTTrack Website Copier Please visit our Web page , - Wizard query Your answer: : Link detected.. .. Choose a rule Ignore this link Ignore directory Ignore domain Catch this page only Mirror site Mirror domain Ignore all Wizard query NO File Options Log Window Help Pause transfer Exit Modify options View log View error log View file transfers Hide About WinHTTrack Website Copier ... Check program updates... ... &Toolbar &Status Bar S&plit File Preferences Mirror Log Window Help Exit Load default options Save default options Reset to default options Load options... ... Save options as... ... Language preference... Contents... ... About WinHTTrack... WinHTTrack... New project\tCtrl+N \tCtrl+N &Open...\tCtrl+O &...\tCtrl+O &Save\tCtrl+S &\tCtrl+S Save &As... &... &Delete... &... &Browse sites... & ... User-defined structure %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\t (.: image)\r\n%N\t (.: image.gif)\r\n%t\t (.: gif)\r\n%p\t [ /] (.: /someimages)\r\n%h\t (.: www.someweb.com)\r\n%M\tURL MD5 (128 bits, 32 ascii bytes)\r\n%Q\tquery string MD5 (128 bits, 32 ascii bytes)\r\n%q\tsmall query string MD5 (16 bits, 4 ascii bytes)\r\n\r\n%s?\tDOS' (: %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif :\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Proxy settings Proxy address: : Proxy port: : Authentication (only if needed) ( ) Login Password Enter proxy address here Enter proxy port here Enter proxy login Enter proxy password Enter project name here Enter saving path here Select existing project to update , Click here to select path Select or create a new category name, to sort your mirrors in categories HTTrack Project Wizard... HTTrack... New project name: : Existing project name: : Project name: : Base path: : Project category: : C:\\My Web Sites C:\\ Web Type a new project name, \r\nor select existing project to update/resume , \r\n / New project Insert URL URL URL: URL: Authentication (only if needed) ( ) Login : Password : Forms or complex links: : Capture URL... URL... Enter URL address(es) here URL Enter site login Enter site password Use this capture tool for links that can only be accessed through forms or javascript code URL (javascript, ..) Choose language according to preference Catch URL! URL! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. .\n, ( , ..) . This will send the desired link from your browser to WinHTTrack. HTTrack. ABORT Copy/Paste the temporary proxy parameters here / Cancel Unable to find Help files! ! Unable to save parameters! ! Please drag only one folder at a time , Please drag only folders, not files , , Please drag folders only , Select user-defined structure? ? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! , , , Do you really want to use a user-defined structure? ? Too manu URLs, cannot handle so many links!! URL', ! Not enough memory, fatal internal error.. , ... Unknown operation! Add this URL?\r\n URL?\r\n Warning: main process is still not responding, cannot add URL(s).. : , URL'... Type/MIME associations (Type/MIME) File types: : MIME identity: MIME identity Select or modify your file type(s) here Select or modify your MIME type(s) here Go up Go down File download information Freeze Window More information: : Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download WinHTTrack Website Copier!\n\n , \n\n- \n- File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS :\n , :\n :\n :\n :\n :\n , :\n :\n :\n :\n Show all\nHide debug\nHide infos\nHide debug and infos \n \n \n Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. ( )\nHtml/, / / /\nHtml/html, / / \nHtml/, / /\nHtml/, / /xxx, xxx - \nHtml, / /xxx\n www.domain.xxx/\nHtml site_name/ / site_name/ /\nHtml site_name/html, / site_name/ \nHtml site_name/, / site_name/\nHtml site_name/, / site_name/xxx\nHtml site_name/html, / site_name/xxx\n /, ( !)\n site_name/, ( !)\n ... Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first \n html \n html \n ( )\n html Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down \n ( )\n \n Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web ( )\n \n \n Never\nIf unknown (except /)\nIf unknown \n ( /)\n no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules robots.txt\nrobots.txt \n robots.txt normal\nextended\ndebug \n\n Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download ()\n () +\n \n ( )\n ( )\n* \n* Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL URI / URL ( )\n URL / URL\n URI / URL\n URL / URL Open Source offline browser Open Source Website Copier/Offline Browser. Copy remote websites to your computer. Free. / . . . httrack, winhttrack, webhttrack, offline browser httrack, winhttrack, webhttrack, offline browser URL list (.txt) URL' (.txt) Previous Next URLs URLs Warning Your browser does not currently support javascript. For better results, please use a javascript-aware browser. javascript . javascript. Thank you You can now close this window Server terminated Server terminated A fatal error has occurred during this mirror httrack-3.49.5/lang/Romanian.txt0000644000175000017500000011111714360553245013434 00000000000000LANGUAGE_NAME Romanian LANGUAGE_FILE Romanian LANGUAGE_ISO ro LANGUAGE_AUTHOR Alin Gheorghe Miron (miron.alin@personal.ro) LANGUAGE_CHARSET ISO-8859-1 LANGUAGE_WINDOWSID Romanian OK LANGUAGE_WINDOWSID Cancel Anuleaz Exit Ieire Close nchide Cancel changes Anuleaz schimbrile Click to confirm Click pentru confirmare. Click to get help! Click pentru ajutor! Click to return to previous screen Click pentru revenire la fereastra precedent Click to go to next screen Click pentru a trece la fereastra urmtoare! Hide password Ascunde parola Save project Salveaz proiect Close current project? nchid proiectul curent? Delete this project? terg acest proiect? Delete empty project %s? terg proiectul gol %s? Action not yet implemented Funcia nu este nc implementat Error deleting this project Eroare la tergerea acestui proiect Select a rule for the filter Selectai o regul pentru filtrare Enter keywords for the filter Introducei un cuvnt cheie pentru filtrare Cancel Anulare Add this rule Adaug aceast regul de filtrare Please enter one or several keyword(s) for the rule Introducei unul sau mai multe cuvinte cheie pentru regula de filtrare Add Scan Rule Adaug o regul de scanare Criterion Criteriu: String Cuvnt cheie Add Adaug Scan Rules Reguli de scanare Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Folosii ? sau *pentru a exclude sau include URL-uri sau linkuri.\r\nPutei pune mai multe adrese pe aceeai linie.\r\nFolosii spaiile ca separatori. \r\nExemplu +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Exclude links Exclude link(uri) Include link(s) Include link(uri) Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) Pentru a include toate fiierele GIF dintr-un singur site, folosii ceva de genul +www.nume_site.com/*.gif.\r\n(+*.gif / -*.gif va include/exclude toate fiierele GIF din toate siturile) Save prefs Salveaz preferinele Matching links will be excluded: Link-urile care se potrivesc acestei reguli vor fi excluse: Matching links will be included: Link-urile care se potrivesc acestei reguli vor fi incluse: Example: Exemplu: gif\r\nWill match all GIF files gif\r\nVa potrivi toate fiierele GIF blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' blue\r\nVa gsi toate fiierele care conin un subir 'blue' cum ar fi 'bluesky-small.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' bigfile.mov\r\nVa detecta numai fiierul 'bigfile.mov', dar nu i 'bigfile2.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\nVa gsi linkuri spre folderele n numele crora se gsete subirul "cgi" cum ar fi /cgi/bin/oricecgi,cgi cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\nVa gsi linkuri spre folderele n numele crora se gsete numai subirul 'cgi-bin' (dar nu i cgi-bin-2, de exemplu) someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb.com\r\nVa gsi linkuri ce conin acest subir cum ar fi www.someweb.com, private.someweb.com etc.\r\n someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. someweb\r\nVa gsi linkuri ce conin acest subir cum ar fi www.someweb.com,www.someweb.edu,private.someweb.otherweb.com etc. www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.someweb.com\r\nVa gsi linkurile care conin tot subirul 'www.someweb.com' ( dar nu i linkuri de genul private.someweb.com/..)\r\n someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. someweb\r\nVa gsi orice link ce conine subirul dat, de exemplu: www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc.\r\n www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/someweb.html\r\nVa gsi numai fiierul 'www.test.com/test/someweb.html' .Observai c trebuie s introducei calea complet (URL + site path) All links will match Toate linkurile vor fi cutate Add exclusion filter Adaug filtru de excludere Add inclusion filter Adaug un filtru de includere Existing filters Filtre existente Cancel changes Anulare schimbri Save current preferences as default values Salveaz preferinele curente ca valori implicite. Click to confirm Click pentru confirmare No log files in %s! Nu sunt fiiere jurnal (*.log) n %s! No 'index.html' file in %s! Nu exist fiier "index.html" n %s! Click to quit WinHTTrack Website Copier Click pentru ieire din WinHTTrack Website Copier View log files Vezi fiierul jurnal Browse HTML start page Rsfoiete pagina HTML de start End of mirror Copiere terminat View log files Vezi fisierul jurnal (log) Browse Mirrored Website Rsfoiete situl copiat. New project... Proiect nou... View error and warning reports Vezi raportul cu erori i avertismente View report Vezi raportul Close the log file window nchide fereastra fiierului jurnal Info type: Tipul informaiei Errors Erori Infos Informaii Find Caut Find a word Caut un cuvnt Info log file Raportul copierii Warning/Errors log file Fiierul jurnal cu avertismente/erori Unable to initialize the OLE system Imposibil de iniializat sistemul OLE WinHTTrack could not find any interrupted download file cache in the specified folder! WinHTTrack nu a putut gsi nici un fiier downloadat parial, n folderul specificat ! Could not connect to provider Nu m pot conecta la furnizor receive recepie request cerere connect conectare search cutare ready pregtit error eroare Receiving files.. Recepionez fiiere Parsing HTML file.. Analizez link-urile din pagin Purging files.. Curire fiiere Loading cache in progress.. ncarcare cache n desfurare... Parsing HTML file (testing links).. Testarea link-urilor de pe pagin Pause - Toggle [Mirror]/[Pause download] to resume operation Pauz - selectati 'Suspendare download' din meniul 'Clonare' pentru a continua download-ul Finishing pending transfers - Select [Cancel] to stop now! Terminare transferuri curente - Selectai [Cancel] pentru a opri acum scanning scanare in progres Waiting for scheduled time.. Atept timpul programat pentru a continua... Connecting to provider M conectez la furnizor [%d seconds] to go before start of operation Mai sunt (%d seconds) nainte de nceperea operaiei Site mirroring in progress [%s, %s bytes] Clonare sit n desfurare [%s %s octei] Site mirroring finished! Clonare site terminat! A problem occurred during the mirroring operation\n A survenit o eroare n timpul operaiei de clonare \nDuring:\n \nDureaz:\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! \nVezi jurnalul (log-ul) dac este necesar. \n\nClick TERMINARE pentru a iei din WinHTTrack Website Copier.\n\nV mulumim c folosii WinHTTrack! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! Operaia de clonare terminat. \nClick Ieire pentru a prsi WinHTTrack. \nVezi fiierele jurnal dac este necesar, pentru a v asigura c totul e OK. \n\nV mulumim c folosii WinHTTrack! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * *CLONARE NTRERUPT! * * \r\nCache-ul teporar este necesar pentru orice operaie de actualizare i nu conine dect datele descrcate n timpul sesiunii curente ntrerupte.\r\nCache-ul precedent poate conine informaia mai complet; dac nu dorii s pierdei aceste date, trebuie s restaurai i s tergei cache-ul curent\r\n(Not: Aceast operaie poate fi fcut cu uurin prin tergerea fiierelor hts-cache/new.*)\r\n\r\n Credei c vechiul cache poate conine mai multe informaii i dorii s le restaurai? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * EROARE CLONARE! * *\r\nHTTrack a detectat c, clona curent este goal. Dac a fost o actualizare, clona precedent a fost restaurat.\r\nMotivul: Fie prima(ele) pagin(i) nu pot(ate) fi gsit(e), fie a intervenit o problem de conectare.\r\n=>Asigurai-v c situl exist i/sau verificai setrile legate de proxy!<= \n\nTip: Click [View log file] to see warning or error messages \n\nSfat:Click [Vizualizeaz fiierul jurnal] pentru a vedea mesajele de avertizare sau eroare. Error deleting a hts-cache/new.* file, please do it manually Eroare la tergerea fisierului hts-cache/new.* , v rog tergei fiierul manual. Do you really want to quit WinHTTrack Website Copier? Chiar dorii s prsii WinHTTrack Website Copier? - Mirroring Mode -\n\nEnter address(es) in URL box - Faza de clonare (copiere automat) - \n\nIntroducei adresa(adresele) n caseta URL - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - Mod interactiv de copiere a siteurilor -\n\nIntroducei adresa(adresele) n caseta URL - File Download Mode -\n\nEnter file address(es) in URL box - Modul de descrcare a fiierelor - \n\nIntroducei adresa (adresele) n caseta URL - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - Modul de testare a link-urilor - \n\nIntroducei adresa (adresele) cu linkuri pentru testat. - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Modul de actualizare - \n\nVerificai adresa (adresele) n caseta URL, verificai opiunile necesare, apoi dai click pe "Next". - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Modul de recuperare (operaie ntrerupt) - \n\nVerificai adresa (adresele) n caseta URL, verificai opiunile necesare, apoi dai click pe "Next". Log files Path Calea fiierelor jurnal Path Calea - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror - Modul de copiere a site-urilor dup linkuri - \n\nFolosii caseta URL pentru a introduce adresa (adresele) paginii(lor) ce conin linkurile de copiat. New project / Import? Proiect nou / Import? Choose criterion Alegei tipul aciunii. Maximum link scanning depth Adncimea maxim de scanare a link-urilor. Enter address(es) here Introducei adresa (adresele) aici Define additional filtering rules Definire reguli de filtrare suplimentare Proxy Name (if needed) Nume server proxy (dac e necesar) Proxy Port Portul serverului proxy Define proxy settings Definii parametrii serverului proxy Use standard HTTP proxy as FTP proxy Folosete proxy-ul standard HTTP ca proxy FTP Path Calea Select Path Selecteaz calea Path Calea Select Path Selecteaz calea Quit WinHTTrack Website Copier Prsete WinHTTrack Website Copier About WinHTTrack Despre WinHTTrack Save current preferences as default values Salveaz setrile curente ca valori implicite. Click to continue Click pentru a continua Click to define options Click pentru a defini opiunile Click to add a URL Click pentru a asuga o adres URL Load URL(s) from text file ncarc adres(e) URL din fiierul text WinHTTrack preferences (*.opt)|*.opt|| Preferine WinHTTrack (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| Fiier text cu lista de adrese (*.txt)|*.txt|| File not found! Nu s-a gsit fiierul! Do you really want to change the project name/path? Chiar dorii s schimbai numele/calea proiectului? Load user-default options? ncarc configuraia personalizat implicit? Save user-default options? Salvez configuraia personalizat implicit? Reset all default options? Reetez toate opiunile implicite? Welcome to WinHTTrack! Bine ai venit n WinHTTrack! Action: Aciune: Max Depth Adncime maxim Maximum external depth: Adncime extern maxim (link-uri externe) : Filters (refuse/accept links) : Filtre (refuz/accept) linkuri: Paths Ci Save prefs Salveaz preferinele Define.. Definete... Set options.. Seteaz opiuni... Preferences and mirror options: Preferine i opiuni de clonare: Project name Numele proiectului Add a URL... Adaug o adres URL... Web Addresses: (URL) Adrese Web: (URL) Stop WinHTTrack? Opresc WinHTTrack? No log files in %s! Nici un fiier jurnal n %s! Pause Download? Pauz descrcare? Stop the mirroring operation Oprete operaia de clonare Minimize to System Tray Minimizeaz n Sistem Tray Click to skip a link or stop parsing Click pentru salt peste un link sau oprirea copierii lui Click to skip a link Click pentru a sri peste un link Bytes saved Octei salvai Links scanned Link- uri scanate Time: Timp: Connections: Conexiuni: Running: Ruleaz: Hide Ascunde Transfer rate Rat de transfer SKIP SALT Information Informaii Files written: Fiiere scrise: Files updated: Fiiere actualizate: Errors: Erori: In progress: n progres: Follow external links Recupereaz fiierele pn la linkurile externe Test all links in pages Testeaz toate link- urile care exist n pagini Try to ferret out all links ncearc reperarea tuturor link - urilor Download HTML files first (faster) Downloadeaz fiierele HTML nainte (mai rapid) Choose local site structure Alege structura local de fiiere a sitului Set user-defined structure on disk Definete parametrii structurii personalizate pe disk Use a cache for updates and retries Folosete un cache pentru actualizri i rencercri Do not update zero size or user-erased files Nu actualiza fiierele de mrime 0 sau fiierele terse de utilizator Create a Start Page Creaz o Pagin de Start Create a word database of all html pages Creeaz o baz de date semantic a tuturor paginilor html Create error logging and report files Creeaz fiiere jurnal pentru mesajele de eroare i fiiere raport Generate DOS 8-3 filenames ONLY Genereaz NUMAI nume de fiier de format 8.3 (DOS) Generate ISO9660 filenames ONLY for CDROM medias Genereaz NUMAI nume de fiier ISO9660 pentru mediile CDROM Do not create HTML error pages Nu genera fiiere de eroare HTML Select file types to be saved to disk Selecteaz tipurile de fiiere care vor fi salvate pe disk Select parsing direction Selectai modul de parcurgere a link-urilor pe site Select global parsing direction Limitele zonei globale de explorare Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) Setai regulile de rescriere a adreselor URL pentru linkurile interne (cele descrcate) i pentru linkurile externe (cele nedescrcate) Max simultaneous connections Numr maxim de conexiuni simultane File timeout Timp expirat (timeout) pentru fiier Cancel all links from host if timeout occurs Anuleaz toate link-urile de la gazd dac intervin timpi mori Minimum admissible transfer rate Rat de transfer minim admisibil Cancel all links from host if too slow Anuleaz toate link- urile de la gazd dac transferul e prea lent Maximum number of retries on non-fatal errors Numrul maxim de ncercri n cazul erorilor nefatale Maximum size for any single HTML file Mrimea maxim pentru un orice fiier HTML Maximum size for any single non-HTML file Mrimea maxim pentru orice fiier non HTML Maximum amount of bytes to retrieve from the Web Cantitatea maxim de octei de scos de pe site Make a pause after downloading this amount of bytes F o pauz dup descrcarea acestei cantiti de octei Maximum duration time for the mirroring operation Durata maxim a operaiei de copiere Maximum transfer rate Rata maxim de transfer Maximum connections/seconds (avoid server overload) Nr. maxim de conexiuni /secunde (evit suprancrcarea serverului) Maximum number of links that can be tested (not saved!) Numrul maxim de link-uri care pot fi testate (nu salvate!) Browser identity Identitatea browser-ului Comment to be placed in each HTML file Comentariu ce va fi plasat n fiecare fiier HTML Back to starting page napoi la pagina de start Save current preferences as default values Salveaz preferinele curente ca valori implicite Click to continue Click pentru continuare Click to cancel changes Click pentru anularea schimbrilor Follow local robots rules on sites Urmeaz regulile locale a roboilor de pe site Links to non-localised external pages will produce error pages Link-urile spre pagini externe nelocalizate vor produce pagini de erori Do not erase obsolete files after update Nu terge fiierele vechi, dup actualizare Accept cookies? S accept cookies-urile? Check document type when unknown? Verificai tipul documentului cnd acesta este necunoscut? Parse java applets to retrieve included files that must be downloaded? Analizez appleturile java pentru a recupera fiierele incluse ce trebuie descrcate? Store all files in cache instead of HTML only Stocheaz toate fiierele n cache, nu numai n HTML Log file type (if generated) Tipul fisierului jurnal (dac s-a generat) Maximum mirroring depth from root address Adncime maxim de clonare, plecnd de la adresa rdcin Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) Adres maxim de clonare pentru adresele externe/interzise (0= nici una, implicit) Create a debugging file Creeaz un fiier de depanare Use non-standard requests to get round some server bugs ncearc evitarea bugurilor de pe unele servere, folosind cereri nestandard Use old HTTP/1.0 requests (limits engine power!) Folosete vechile cereri HTTP/1.0 (limiteaz puterea!) Attempt to limit retransfers through several tricks (file size test..) ncearc s limitezi retransferurile prin folosirea unor trucuri (file size test...) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Write external links without login/password Scrie linkurile externe fr login/password Write internal links without query string Scrie link- urile interne fr sirul de interogare (query string) Get non-HTML files related to a link, eg external .ZIP or pictures Scoate fiierele non-HTML apropiate (i din link- uri), ex arhive sau imagini. Test all links (even forbidden ones) Testeaz toate linkurile (chiar i cele interzise) Try to catch all URLs (even in unknown tags/code) ncearc s detectezi toate adresele URL (chiar i tagurile/codul necunoscut(e)) Get HTML files first! Descarc nti fiierele HTML! Structure type (how links are saved) Tipul structurii (cum sunt salvate link-urile) Use a cache for updates Folosete un cache pentru actualizare Do not re-download locally erased files Nu redescrca fiierele terse local Make an index Construiete un index Make a word database Construiete o baz de date semantic Log files Fiiere jurnal DOS names (8+3) Nume DOS (8.3) ISO9660 names (CDROM) Nume ISO9660 (CDROM) No error pages Fr pagini de eroare Primary Scan Rule Regul de scanare principal Travel mode Mod de parcurgere Global travel mode Mod de parcurgere global These options should be modified only exceptionally Aceste opiuni nu se vor modifica dect n cazuri excepionale. Activate Debugging Mode (winhttrack.log) Activeaz modul de depanare Rewrite links: internal / external Rescrie link - uri: interne/externe Flow control Controlul fluxului Limits Limite Identity Identitate HTML footer Subsol HTML N# connections Numr de conexiuni Abandon host if error Abandoneaz gazd n caz de eroare Minimum transfer rate (B/s) Rat de transfer minim (B/s) Abandon host if too slow Abandoneaz gazda dac transferul este prea lent Configure Configureaz Use proxy for ftp transfers Folosete serverul proxy pentru transferurile FTP TimeOut(s) TimeOut(-uri) Persistent connections (Keep-Alive) Conexiuni persistente [menine active] Reduce connection time and type lookup time using persistent connections Redu timpul de conectare i timpul de cutare a tipului folosind conexiuni persistente. Retries ncercri Size limit Limit de dimensiune Max size of any HTML file (B) Dimensiune maxim a oricrui fiier HTML (B) Max size of any non-HTML file Dimensiunea maxim a oricrui fiier non-HTML Max site size Dimensiunea maxim a site-ului Max time Timp maxim Save prefs Salveaz preferinele Max transfer rate Rat maxim de transfer Follow robots.txt Urmeaz robots.txt No external pages Fr pagini externe Do not purge old files Nu elimina fiierele vechi Accept cookies Accept cookies-uri Check document type Verific tipul documentului Parse java files Analizeaz fiierele java Store ALL files in cache Stocheaz toate fiierele n cache Tolerant requests (for servers) Cereri tolerante (pentru servere) Update hack (limit re-transfers) Actualizare forat (limiteaz re-transferurile) URL hacks (join similar URLs) Force old HTTP/1.0 requests (no 1.1) Foreaz vechile cereri HTTP/1.0 (fr cereri HTTP/1.1) Max connections / seconds Numrul maxim de conexiuni/secund Maximum number of links Numrul maxim de link-uri Pause after downloading.. Pauz dup descarcarea... Hide passwords Ascunde parole Hide query strings Ascunde 'query string'-urile Links Link-uri Build Structureaz Experts Only Pentru experi Flow Control Controlul fluxului Limits Limite Browser ID Identific HTTrack Web Copier ca: Scan Rules Reguli de scanare: Spider Pianjen (spider) Log, Index, Cache Jurnal, Index, Cache Proxy Server proxy MIME Types Tipuri MIME Do you really want to quit WinHTTrack Website Copier? Chiar dorii s prsii WinHTTrack Website Copier ? Do not connect to a provider (already connected) Nu conecta la un furnizor (deja conectat) Do not use remote access connection Nu folosi conexiune cu acces la distan Schedule the mirroring operation Programeaz operaia de clonare (copiere) a site-ului Quit WinHTTrack Website Copier Ieire din WinHTTrack Website Copier Back to starting page napoi la pagina de start Click to start! Click pentru pornire! No saved password for this connection! Nici o parol salvat pentru aceast conexiune! Can not get remote connection settings Nu pot obine etrile conexiunii la distan Select a connection provider Alege un furnizor de conexiune Start Start Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. Ajustai parametrii conexiunii dac este necesar, \napoi apsai FINISH pentru a ncepe clonarea sit-ului Save settings only, do not launch download now. Salveaz setrile dar nu porni descrcarea acum. On hold n ateptare Transfer scheduled for: (hh/mm/ss) Transfer programat pentru:(hh/mm/ss) Start Start Connect to provider (RAS) Conecteaz la furnizorul de internet (RAS) Connect to this provider Conecteaz la acest furnizor de internet Disconnect when finished Deconecteaz a terminare Disconnect modem on completion Deconecteaz modemul la terminare \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) About WinHTTrack Website Copier Despre WinHTTrack Website Copier Please visit our Web page Vizitai pagina noastr Web Wizard query Vrjitor de interogare Your answer: Rspunsul d-voastr: Link detected.. S-a detectat un link. Choose a rule Alege o regul Ignore this link Ignor acest link Ignore directory Ignor director Ignore domain Ignor domeniu Catch this page only Captureaz doar aceast pagin Mirror site Cloneaz site Mirror domain Cloneaz domeniu Ignore all Ignor tot Wizard query Vrjitor de interogare NO NU File Fiier Options Opiuni Log Jurnal Window Fereastr Help Ajutor Pause transfer Suspend transfer Exit Ieire Modify options Modific opiuni View log Vezi fiierul jurnal. View error log Vezi fiierul jurnal cu erori View file transfers Vezi transferurile de fiiere Hide Ascunde About WinHTTrack Website Copier Despre WinHTTrack Website Copier Check program updates... Verific actualizrile pentru WinHTTrack... &Toolbar &Bara de instrumente &Status Bar Bara de &Stare S&plit m&parte File Fiier Preferences Preferine Mirror Clonare (copiere sit) Log Jurnal Window Fereastr Help Ajutor Exit Ieire Load default options ncarc opiunile implicite Save default options Salveaz optiunile implicite Reset to default options Reseteaz la opiunile implicite Load options... ncarc opiunile... Save options as... Salveaz opiunile ca... Language preference... Alegere Limb Contents... Coninut... About WinHTTrack... Despre WinHTTrack... New project\tCtrl+N Proiect nou\tCtrl+N &Open...\tCtrl+O &Deschide...\tCtrl+O &Save\tCtrl+S &Salveaz\tCtrl+S Save &As... Salveaz C&a... &Delete... t&erge... &Browse sites... &Rsfoire situri... User-defined structure Structur definit de utilizator %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\tNumele fiierului fr extensie (ex: image)\r\n%N\tNumele fiierului cu extensie (ex: image.gif)\r\n%t\tNumai tipul fiierului (extensia) (ex: gif)\r\n%p\tCalea [fr / la sfrit] (ex: /someimages)\r\n%h\tNumele Gazdei (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tDenumire scurt DOS (ex: %sN)\r\n Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Exemplu:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Proxy settings Setri ale serverului proxy: Proxy address: Adresa serverului proxy: Proxy port: Portul serverului proxy: Authentication (only if needed) Autentificare (numai dac este necesar) Login Nume utilizator (Login) Password Parola Enter proxy address here Introducei aici adresa serverului proxy Enter proxy port here Introducei aici portul serverului proxy Enter proxy login Introducei numele utilizatorului (login) serverului proxy Enter proxy password Introducei parola de conectare la serverul proxy Enter project name here Introducei numele proiectului aici Enter saving path here Introducei calea pentru salvarea proiectului Select existing project to update Selecteaz un proiect existent pentru actualizare Click here to select path Click aici pentru a selecta calea Select or create a new category name, to sort your mirrors in categories HTTrack Project Wizard... Vrjitor proiect HTTrack... New project name: Nume proiect nou: Existing project name: Numele proiectului existent: Project name: Nume proiect: Base path: Calea de baz: Project category: C:\\My Web Sites C:\\Siturile Mele Type a new project name, \r\nor select existing project to update/resume Introducei numele unui proiect nou,\r\nsau selectai un proiect existent pentru actiualizare/continuare New project Proiect nou Insert URL Introducei o adres URL URL: URL: Authentication (only if needed) Autentificare (doar dac e necesar) Login Nume utilizator (Login) : Password Parola Forms or complex links: Formulare sau link- uri complexe Capture URL... Captureaz URL... Enter URL address(es) here Introducei adresa (adresele) URL aici Enter site login Introducei numele de utilizator pentru site Enter site password Introducei parola pentru site Use this capture tool for links that can only be accessed through forms or javascript code Folosete aceast unealt de captur pentru link- uri care pot fi accesate numai prin formulare sau cod javascript Choose language according to preference Alege limba de aici... Catch URL! Captureaz aceast adres URL! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. Setai proprietile temporar serverului proxy a browserului vostru cu urmtoarele valori (Copy/Paste Adresa Proxy i Portul).\nApoi dai click pe butonul Trimite din formular, sau facei click pe un link specific, pe care dorii sa l capturai. This will send the desired link from your browser to WinHTTrack. Aceasta va trimite link-ul dorit, din browser ctre WinHTTrack. ABORT RENUN Copy/Paste the temporary proxy parameters here Copiaz/Lipete parametrii temporari ai serverului proxy aici Cancel Anulare Unable to find Help files! Nu gsesc fiierele de Ajutor! Unable to save parameters! Nu pot s salvez parametrii! Please drag only one folder at a time V rog tragei numai un fiier o dat Please drag only folders, not files Tragei numai dosare, nu fiiere Please drag folders only Tragei numai dosare Select user-defined structure? Alegei o structur definit de utilizator pentru copierea sit-ului ? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! Asigurai-v c irul definit de utilizator este corect,\n altfel numele fiierelor vor fi eronate ! Do you really want to use a user-defined structure? Chiar dorii s folosii o structur personalizat (user-defined)? Too manu URLs, cannot handle so many links!! Prea multe adrese URL, nu pot manipula aa multe link-uri Not enough memory, fatal internal error.. Memorie insuficient, eroare intern fatal... Unknown operation! Operaie necunoscut! Add this URL?\r\n Adaug aceast adres URL?\r\n Warning: main process is still not responding, cannot add URL(s).. ATENIE: Procesul principal tot nu rspunde, nu pot aduga adresa (adresele) URL.. Type/MIME associations Asocieri de tip/MIME File types: Tipuri de fiiere: MIME identity: Identitate MIME: Select or modify your file type(s) here Alege sau modific tip(urile) de fiier(e) aici Select or modify your MIME type(s) here Alege sau modific tipul (tipurile) MIME aici Go up Urc Go down Coboar File download information Informaii despre fiierele descrcate Freeze Window nghea fereastra More information: Mai multe informaii: Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download Bine ai venit la WinHTTrack Website Copier!\n\nClick pe butonul Next pentru\n\n- a ncepe un proiect nou\n- sau a continua o descrcare parial File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS Nume de fiier cu extensie:\nNume de fiiere ce conin:\nAcest nume de fiier:\nNume de directoare ce conin:\nAcest nume de director:\nLinkurile din acest domeniu:\nLinkurile din acest domeniu care conin:\nLink-urile de la aceast gazd:\nLink-urile care conin:\nAcest link:\nTOATE LINK-URILE Show all\nHide debug\nHide infos\nHide debug and infos Arat tot\nAscunde informaiile de depanare\nAscunde informaiile generale\nAscunde i informaiile de depanare i cele generale Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. Structura site-ului (implicit)\nHtml n web/, imagini/alte fiiere din web/imagini/\nHtml n web/html, imagini/altele n web/imagini\nHtml n web/, imagini/altele n web/\nHtml n web/, imagini/altele n web/xxx, unde xxx este extensia fiierului\nHtml n web/html, imagini/altele n web/xxx\nStructura-site, fr www.domeniu.xxx/\nHtml n numele_site-ului/, imagini/alte fiiere n numele_site-ului/imagini/\nHtml n numele_site-ului/html, imagini/altele n numele_site-ului/imagini\nHtml n site_name/, imagini/altele n numele_site-ului /\nHtml n numele_site-ului/, imagini/altele n numele_site-ului/xxx\nHtml n numele_site-ului/html, imagini/alte n numele_site-ului/xxx\nToate fiierele n web/, cu nume aleatoare (gadget !)\nToate fiierele n numele_site-ului/, cu nume aleatoare (gadget !)\nStructur personalizat (definit de utilizator ).. Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first Doar scaneaz\nStocheaz fiiere\nStocheaz fiiere non HTML\nStocheaz toate fiierele (implicit)\nStocheaz nti fiierele html Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down Rmi n acelai director\nCoborre permis\nUrcare permis\nUrcare i coborre permis Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web Rmi la aceeai adres (implicit)\nRmi pe acelai domeniu\nRmi la acelai domeniu de nivel superior\nMergi oriunde pe web Never\nIf unknown (except /)\nIf unknown Niciodat\nDac este necunoscut (excepie /)\nDac este necunoscut no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules Fr regulile robots.txt\nrobots.txt exceptnd filtrele\n urmeaz regulile din robots.txt normal\nextended\ndebug normal\nextins\ndepanare Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download Descarc site(-uri) web\nDescrcare interactiv site(-uri) web\nDescarc fiiere individuale\nDescarc toate ite-urile din pagini (clonri multiple)\nTesteaz linkurile din pagini (testeaz semnele de carte)\n* Continu o descrcare ntrerupt \n* Actualizeaz o descrcare existent Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL Adres URI relativ / Adres URL absolut (implicit)\nAdres URL absolut / Adres URL absolut\nAdres URI absolut / Adres URL absolut \n Adres URL original / Adres URL original Open Source offline browser Browser offline open source. Website Copier/Offline Browser. Copy remote websites to your computer. Free. Copiator de situri web/Browser offline. Copiaz situri web pe calculatorul dumneavoastr.Gratuit httrack, winhttrack, webhttrack, offline browser httrack, winhttrack, webhttrack, offline browser URL list (.txt) Lista URL (.txt) Previous Anterior Next Urmtor URLs URL- uri Warning Avertisment Your browser does not currently support javascript. For better results, please use a javascript-aware browser. Browserul dumneavoastr nu suport javascript. Pentru rezultate mai bune, v rugm sa folosii un browser ce suport javascript. Thank you V mulumim You can now close this window Acum putei nchide aceast fereastr. Server terminated Server terminat A fatal error has occurred during this mirror A survenit o eroare fatal n timpul acestei clonri. httrack-3.49.5/lang/Portugues.txt0000644000175000017500000010527714360553245013677 00000000000000LANGUAGE_NAME Portugus LANGUAGE_FILE Portugues LANGUAGE_ISO pt LANGUAGE_AUTHOR Rui Fernandes (CANTIC, ruiefe at mail.malhatlantica.pt) \r\nPedro T. Pinheiro (Universidade Nova de Lisboa-FCT, ptiago at mail.iupi.pt) \r\n LANGUAGE_CHARSET ISO-8859-1 LANGUAGE_WINDOWSID Portuguese (Portugal) OK OK Cancel Cancelar Exit Sair Close Fechar Cancel changes Cancelar alteraes Click to confirm Clique para confirmar Click to get help! Clique para obter ajuda Click to return to previous screen Clique para retroceder Click to go to next screen Clique para avanar Hide password Ocultar palavra-chave Save project Guardar projecto Close current project? Fechar o projecto em curso? Delete this project? Apagar este projecto? Delete empty project %s? Apagar o projecto vazio %s? Action not yet implemented Funo no disponvel Error deleting this project Erro ao apagar o projecto Select a rule for the filter Escolha uma regra para o filtro Enter keywords for the filter Introduza uma palavra-chave para o filtro Cancel Cancelar Add this rule Adicionar esta regra Please enter one or several keyword(s) for the rule Escreva uma ou mais palavras-chave para esta regra Add Scan Rule Adicionar filtro Criterion Escolha uma regra String Palavra-chave: Add Adicionar Scan Rules Filtros Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Usar * ou ? para excluir ou incluir vrios URL ou hiperligaes.\n Pode usar vrgulas ou espaos entre os filtros.\n\n Exemplo: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Exclude links Excluir hiperligaes Include link(s) Incluir hiperligaes Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) Sugesto: Para incluir todos os ficheiros GIF, use algo como +www.pagina.com/*.gif. \nPara incluir/excluir TODOS os ficheiros GIF de todos os sites utilize +*.gif ou -*.gif Save prefs Guardar preferncias Matching links will be excluded: As hiperligaes correspondentes a esta regra sero excludas Matching links will be included: As hiperligaes correspondentes a esta regra sero includas Example: Exemplo: gif\r\nWill match all GIF files gif\r\ndetectar todos os ficheiros GIF blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' blue\r\ndetectar todos os ficheiros contendo blue, tais como 'bluesky-small.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' bigfile.mov\r\ndetectar o ficheiro 'bigfile.mov' mas no 'bigfile2.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\ndetectar hiperligaes contendo 'cgi' tais como /cgi-bin/somecgi.cgi cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\ndetectar por exemplo hiperligaes com nomes contendo 'cgi-bin' mas no 'cgi-bin-2' someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb.com\r\ndetectar hiperligaes como www.someweb.com, private.someweb.com, etc. someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. someweb\r\ndetectar hiperligaes como www.someweb.com, www.someweb.edu, private.someweb.otherweb.com, etc. www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.someweb.com\r\ndetectar hiperligaes como www.someweb.com/... (mas no hiperligaes como private.someweb.com/...) someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. someweb\r\ndetectar hiperligaes como www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html, etc. www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/someweb.html\r\napenas detectar hiperligaes como www.test.com/test/someweb.html. Note que ter que digitar o endereo completo (URL + caminho do ficheiro) All links will match Todas as hiperligaes sero detectadas Add exclusion filter Acrescentar filtro de excluso Add inclusion filter Acrescentar filtro de incluso Existing filters Filtros existentes Cancel changes Anular alteraes Save current preferences as default values Guardar preferncias como opes padro Click to confirm Clique para confirmar No log files in %s! No h relatrios em %s! No 'index.html' file in %s! No existe index.html em %s Click to quit WinHTTrack Website Copier Clique para sair do WinHTTrack Website Copier View log files Ver relatrios Browse HTML start page Aceder pgina inicial End of mirror Cpia terminada View log files Ver relatrios Browse Mirrored Website Aceder Web New project... Novo projecto... View error and warning reports Ver relatrios de erros e avisos View report Ver informao do relatrio Close the log file window Fechar a janela do relatrio Info type: Tipo de informao: Errors Erros Infos Informaes Find Localizar Find a word Localizar uma palavra Info log file Relatrios de cpia Warning/Errors log file Relatrio de erros e avisos Unable to initialize the OLE system Impossvel iniciar o sistema OLE WinHTTrack could not find any interrupted download file cache in the specified folder! WinHTTrack no encontra nenhuma cpia completa ou parcial na pasta indicada Could not connect to provider Impossvel estabelecer a ligao receive recepo request pedido connect ligao search localizar ready pronto error erro Receiving files.. Recepo de ficheiros Parsing HTML file.. Anlise das hiperligaes da pgina Purging files.. Limpeza de ficheiros... Loading cache in progress.. Parsing HTML file (testing links).. Teste das hiperligaes da pgina Pause - Toggle [Mirror]/[Pause download] to resume operation Pausa - Escolha [Ficheiro]/[Interromper transferncia] para continuar Finishing pending transfers - Select [Cancel] to stop now! A concluir as transferncias em curso - Seleccione [Cancelar] para terminar agora! scanning analisando Waiting for scheduled time.. Aguardando hora programada para comear Connecting to provider Ligao ao fornecedor de acesso [%d seconds] to go before start of operation Cpia em espera (%d segundos) Site mirroring in progress [%s, %s bytes] A copiar (%s, %s Bytes) Site mirroring finished! Cpia terminada A problem occurred during the mirroring operation\n Ocorreu um problema durante a cpia\n \nDuring:\n Durante:\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! Veja o relatrio, se necessrio.\n\nClique TERMINAR para sair do WinHTTrack.\n\nObrigado por usar o WinHTTrack! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! Cpia terminada.\nClique OK para sair.\nVeja o relatrio para verificar se no h erros.\n\nObrigado por usar o WinHTTrack! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * CPIA INTERROMPIDA! * *\r\nA cache temporria actual necessria para actualizao e s contm os dados carregados durante a sesso em curso.\r\n possvel que a cache anterior contenha dados mais completos; para no perder esses dados, deve restaur-la e apagar a cache actual.\r\n[Nota: Esta operao pode ser facilmente executada aqui apagando os ficheiros hts-cache/new.*]\r\n\r\nPensa que a cache anterior pode conter informaes mais completas e quer restaur-la? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * ERRO DE CPIA! * *\r\nHTTrack detectou que a cpia actual est vazia. Se fez uma actualizao, a cpia anterior foi restaurada.\r\nRazo: a primeira pgina no foi encontrada ou ocorreu um problema na conexo.\r\n=> Certifique-se de que o site existe e confirme as configuraes do proxy! <= \n\nTip: Click [View log file] to see warning or error messages \nSugesto:Clique [Ver relatrio] para ver os avisos e as mensagens de erro Error deleting a hts-cache/new.* file, please do it manually Erro ao apagar hts-cache/new.*, apague manualmente Do you really want to quit WinHTTrack Website Copier? Quer realmente sair de WinHTTrack Website Copier? - Mirroring Mode -\n\nEnter address(es) in URL box - Modo de cpia automtica -\n\nIntroduza os endereos na caixa de dilogo. - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - Modo de cpia interactiva (perguntas) -\n\nIntroduza os endereos na caixa de dilogo. - File Download Mode -\n\nEnter file address(es) in URL box - Modo de download do ficheiro -\n\nIntroduza os endereos na caixa de dilogo. - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - Modo de teste de hiperligaes -\n\nIntroduza os endereos das pginas com hiperligaes para testar na caixa de dilogo. - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Modo de actualizao de cpia -\n\nVerifique os endereos na lista, verifique as opes, depois clique SEGUINTE. - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Modo de continuao de cpia -\n\nVerifique os endereos na lista, verifique as opes, depois clique SEGUINTE. Log files Path Caminho para os ficheiros de relatrio Path Caminho - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror Modo de cpia de hiperligaes -\n\nIntroduza os endereos a copiar na caixa de dilogo. New project / Import? Novo projecto / importar ? Choose criterion Escolha uma aco Maximum link scanning depth Profundidade mxima de anlise de hiperligaes Enter address(es) here Introduza os endereos aqui Define additional filtering rules Definir filtros adicionais Proxy Name (if needed) Nome do proxy (se necessrio) Proxy Port Porta do proxy Define proxy settings Definir as opes do proxy Use standard HTTP proxy as FTP proxy Utilizar o proxy HTTP padro como proxy FTP Path Caminho Select Path Escolha o caminho Path Caminho Select Path Escolha o caminho Quit WinHTTrack Website Copier Sair do WinHTTrack Website Copier About WinHTTrack Acerca do WinHTTrack Save current preferences as default values Guardar preferncias como opes padro Click to continue Clique para continuar Click to define options Clique para definir as opes Click to add a URL Clique para adicionar um endereo URL Load URL(s) from text file Importar endereos URL de um ficheiro de texto WinHTTrack preferences (*.opt)|*.opt|| Preferncias do WinHTTrack (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| Ficheiro de texto com lista de endereos (*.txt)|*.txt|| File not found! Ficheiro no encontrado! Do you really want to change the project name/path? Deseja realmente alterar o nome/caminho do projecto? Load user-default options? Carregar as opes padro (definidas pelo utilizador)? Save user-default options? Guardar as opes padro do utilizador? Reset all default options? Apagar todas as opes padro? Welcome to WinHTTrack! Bem-vindo ao WinHTTrack Website Copier Action: Aco: Max Depth Profundidade mxima: Maximum external depth: Profundidade externa mxima: Filters (refuse/accept links) : Filtros (incluir/excluir hiperligaes) Paths Caminhos Save prefs Guardar preferncias Define.. Definir... Set options.. Definir as opes... Preferences and mirror options: Parmetros de cpia do site Project name Nome do projecto Add a URL... Adicionar... Web Addresses: (URL) Endereo (URL): Stop WinHTTrack? Parar o WinHTTrack? No log files in %s! Nenhum relatrio em %s! Pause Download? Suspender a cpia do site? Stop the mirroring operation Parar a cpia do site? Minimize to System Tray Minimizar na barra de sistema Click to skip a link or stop parsing Clique para saltar uma ligao ou interromper a cpia Click to skip a link Clique para saltar a ligao Bytes saved Bytes guardados: Links scanned Hiperligaes processadas: Time: Tempo: Connections: Ligaes: Running: Em curso: Hide Minimizar Transfer rate Taxa de transferncia: SKIP SALTAR Information Informaes Files written: Ficheiros escritos: Files updated: Ficheiros actualizados: Errors: Erros: In progress: Em curso: Follow external links Copiar ficheiros mesmo em hiperligaes externas Test all links in pages Testar todas as hiperligaes nas pginas Try to ferret out all links A tentar detectar todas as hiperligaes Download HTML files first (faster) Transferir primeiro os ficheiros HTML (mais rpido) Choose local site structure Escolher a estrutura local de ficheiros Set user-defined structure on disk Definir os parmetros da estrutura personalizada Use a cache for updates and retries Utilizar chache para actualizaes e novas tentativas Do not update zero size or user-erased files No actualizar ficheiros com tamanho zero ou apagados pelo utilizador Create a Start Page Criar uma pgina inicial Create a word database of all html pages Criar base de dados de palavras de todas as pginas html Create error logging and report files Criar ficheiros para as mensagens de erro e avisos Generate DOS 8-3 filenames ONLY Gerar APENAS nomes de ficheiros DOS (8+3 caracteres) Generate ISO9660 filenames ONLY for CDROM medias Do not create HTML error pages No escrever ficheiros de erro HTML Select file types to be saved to disk Seleco dos tipos de ficheiros a guardar Select parsing direction Modo de percurso de hiperligaes no site Select global parsing direction Limites da zona global de explorao Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) Max simultaneous connections Numero mximo de conexes File timeout Tempo mximo de espera para um ficheiro Cancel all links from host if timeout occurs Cancelar todas as hiperligaes num domnio em caso de espera excessiva Minimum admissible transfer rate Taxa de transferncia mnima tolerada Cancel all links from host if too slow Cancelar todas as hiperligaes num domnio em caso de transferncia muito lenta Maximum number of retries on non-fatal errors Nmero mximo de tentativas em caso de erro no fatal Maximum size for any single HTML file Tamanho mximo para uma pgina HTML Maximum size for any single non-HTML file Tamanho mximo para cada ficheiro no HTML Maximum amount of bytes to retrieve from the Web Tamanho total mximo para cpia Make a pause after downloading this amount of bytes Fazer uma pausa depois de transferir esta quantidade de bytes Maximum duration time for the mirroring operation Tempo total mximo para cpia Maximum transfer rate Taxa de transferncia mxima Maximum connections/seconds (avoid server overload) Nmero mximo de conexes/segundos (limita sobrecarga dos servidores) Maximum number of links that can be tested (not saved!) Nmero mximo de hiperligaes que podem ser testadas (no gravadas!) Browser identity Identidade do browser Comment to be placed in each HTML file Nota de rodap em cada ficheiro HTML Back to starting page Voltar pgina inicial Save current preferences as default values Guardar as preferncias actuais como opes padro Click to continue Clique para continuar Click to cancel changes Clique para cancelar Follow local robots rules on sites Seguir as regras locais dos robots nos sites Links to non-localised external pages will produce error pages As hiperligaes fora do domnio de explorao geram mensagens de erro Do not erase obsolete files after update No apagar os ficheiros antigos depois da actualizao Accept cookies? Aceitar cookies? Check document type when unknown? Verificar o tipo de documento se desconhecido? Parse java applets to retrieve included files that must be downloaded? Analisar os applets Java para transferir os ficheiros includos? Store all files in cache instead of HTML only Armazenamento de TODOS os ficheiros em cache (em vez de s HTML) Log file type (if generated) Tipo de relatrio (se gerado) Maximum mirroring depth from root address Profundidade mxima da cpia desde o endereo inicial Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) Maximum mirroring depth for external/fodbidden addresses (0, that is, none, is the default) Create a debugging file Criar um ficheiro de debug Use non-standard requests to get round some server bugs Tentar evitar os bugs dos servidores usando chamadas no-standard Use old HTTP/1.0 requests (limits engine power!) A utilizao de chamadas antigas HTTP/1.0 limita as capacidades do motor de captura! Attempt to limit retransfers through several tricks (file size test..) Tentativa de limitar a retransferncia atravs de vrios mtodos (teste do tamanho do ficheiro...) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Write external links without login/password Guardar hiperligaes externas sem login/palavra-chave Write internal links without query string Guardar hiperligaes internas sem 'query string' Get non-HTML files related to a link, eg external .ZIP or pictures Capturar ficheiros no-HTML prximos (ex: ficheiros .ZIP situados no exterior) Test all links (even forbidden ones) Testar todas as hiperligaes (mesmo as excludas) Try to catch all URLs (even in unknown tags/code) Tentar detectar todas as hiperligaes (mesmo tag desconhecidos/cdigo javascript) Get HTML files first! Transferir ficheiros HTML primeiro! Structure type (how links are saved) Tipo de estrutura (modo como as hiperligaes so guardadas) Use a cache for updates Utilizar a cache para actulizaes Do not re-download locally erased files No voltar a transferir ficheiros apagados localmente Make an index Construir um ndice Make a word database Criar base de dados de palavras Log files Relatrios DOS names (8+3) Nomes DOS (8+3) ISO9660 names (CDROM) No error pages Sem pginas de erros Primary Scan Rule Filtro primrio Travel mode Modo de percurso Global travel mode Modo de percurso global These options should be modified only exceptionally Opes a modificar apenas excepcionalmente Activate Debugging Mode (winhttrack.log) Activar o modo de debug (winhttrack.log) Rewrite links: internal / external Flow control Controlo de fluxo Limits Limites Identity Identificao HTML footer Rodap HTML N# connections Nmero de conexes Abandon host if error Abandonar servidor em caso de erro Minimum transfer rate (B/s) Taxa de transferncia mnima (Bps) Abandon host if too slow Abandonar em caso de transferncia muito lenta Configure Configurar Use proxy for ftp transfers Utilizar o proxy para transferncias FTP TimeOut(s) Tempo excessivo Persistent connections (Keep-Alive) Reduce connection time and type lookup time using persistent connections Retries Tentativas Size limit Tamanho limite Max size of any HTML file (B) Tamanho mximo dos ficheiros HTML Max size of any non-HTML file Tamanho mximo dos outros ficheiros Max site size Tamanho mximo do site Max time Tempo mximo Save prefs Guardar as opes actuais Max transfer rate Taxa de transferncia mxima Follow robots.txt Seguir as regras no ficheiro robots.txt No external pages Sem pginas externas Do not purge old files No eliminar ficheiros antigos Accept cookies Aceitar cookies Check document type Verificar os tipos de documento Parse java files Analizar os ficheiros Java Store ALL files in cache Guardar TODOS os ficheiros na cache Tolerant requests (for servers) Chamadas tolerantes (para servidores) Update hack (limit re-transfers) Actualizao forada (limita retransferncias) URL hacks (join similar URLs) Force old HTTP/1.0 requests (no 1.1) Chamadas antigas HTTP/1.0 (no 1.1) Max connections / seconds Nmero mximo de conexes/segundos Maximum number of links Nmero mximo de hiperligaes Pause after downloading.. Suspender aps a cpia de... Hide passwords Ocultar palavra-chave Hide query strings Ocultar 'query strings' Links Hiperligaes Build Estrutura Experts Only S especialistas Flow Control Controlo de fluxo Limits Limites Browser ID Identidade do browser Scan Rules Filtros Spider Indexador Log, Index, Cache Relatrio, Indice, Cache Proxy Proxy MIME Types Do you really want to quit WinHTTrack Website Copier? Deseja realmente sair do WinHTTrack Website Copier? Do not connect to a provider (already connected) No ligar a um fornecedor de acesso (ligao j estabelecida) Do not use remote access connection No utilizar acesso remoto Schedule the mirroring operation Programar cpia do site Quit WinHTTrack Website Copier Sair do WinHTTrack Website Copier Back to starting page Voltar pgina inicial Click to start! Clique para comear! No saved password for this connection! No existem palavras-chave para esta conexo! Can not get remote connection settings Impossvel obter os parmetros de conexo Select a connection provider Seleccione o ISP Start Iniciar... Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. Defina as OPES de conexo se necessrio,\nem seguida clique Avanar para comear a cpia do site Save settings only, do not launch download now. Registar s as configuraes, no iniciar a transferncia. On hold Temporizao Transfer scheduled for: (hh/mm/ss) Esperar at s: (hh/mm/ss) Start INICIAR! Connect to provider (RAS) Fornecedor de acesso Connect to this provider Ligar a este fornecedor de acesso Disconnect when finished Desligar no fim da operao Disconnect modem on completion Desconectar o modem no final \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n(Por favor avise-nos acerca de erros ou problemas)\r\n\r\nDesenvolvimento:\r\nInterface (Windows): Xavier Roche\r\nMotor: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nAgradecimentos pela traduo para o Portugus para:\r\nRui Fernandes (CANTIC, ruiefe@mail.malhatlantica.pt) About WinHTTrack Website Copier Acerca do WinHTTrack Website Copier Please visit our Web page Visite a nossa pgina Web! Wizard query Pergunta do Assistente Your answer: A sua resposta: Link detected.. Foi detectada uma hiperligao Choose a rule Escolha uma regra: Ignore this link Ignorar esta hiperligao Ignore directory Ignorar esta pasta Ignore domain Ignorar este domnio Catch this page only Transferir APENAS esta pgina Mirror site Cpia do site Mirror domain Transferir todo o domnio Ignore all Ignorar tudo Wizard query Questo do Assistente NO NO File Ficheiro Options Opes Log Relatrio Window Janelas Help Ajuda Pause transfer Suspender a transferncia Exit Sair Modify options Modificar as opes View log Ver relatrio View error log Ver relatrio de erros View file transfers Ver ficheiros transferidos Hide Minimizar About WinHTTrack Website Copier Acerca do WINHTTrack Check program updates... Procurar actualizaes do WINHTTrack... &Toolbar Barra de ferramentas &Status Bar Barra de estado S&plit Dividir File Ficheiro Preferences Opes Mirror Cpia do site Log Relatrio Window Janelas Help Ajuda Exit Sair Load default options Carregar opes padro Save default options Guardar opes padro Reset to default options Apagar opes padro Load options... Carregar opes Save options as... Guardar opes como... Language preference... Preferncias de linguagem Contents... ndice... About WinHTTrack... Acerca do WinHTTrack Website Copier New project\tCtrl+N Novo projecto\tCtrl+N &Open...\tCtrl+O &Abrir...\tCtrl+O &Save\tCtrl+S &Guardar\tCtrl+S Save &As... Guardar &como... &Delete... A&pagar... &Browse sites... &Ver sites... User-defined structure Estrutura local de ficheiros %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\tNome do ficheiro sem extenso (ex: image)\r\n%N\tNome do ficheiro incluindo extenso (ex: image.gif)\r\n%t\tExtenso (ex: gif)\r\n%p\tCaminho (sem / final) (ex: /someimages)\r\n%h\tNome do servidor (ex: www.someweb.com)\r\n%M\tURL MD5 (128 bits, 32 ascii bytes)\r\n%Q\tquery string MD5 (128 bits, 32 ascii bytes)\r\n%q\tsmall query string MD5 (16 bits, 4 ascii bytes)\r\n\r\n%s?\tVerso curta DOS (ex: %sN ) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Exemplo:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Proxy settings Configurao do proxy Proxy address: Endereo do proxy Proxy port: Porta do proxy Authentication (only if needed) Identificao (se necessria) Login Login Password Palavra-chave Enter proxy address here Introduza o endereo do proxy Enter proxy port here Introduza a porta do proxy Enter proxy login Introduza o login do proxy Enter proxy password Introduza a palavra-chave do proxy Enter project name here Introduza o nome do projecto Enter saving path here Digite o caminho onde quer guardar o projecto Select existing project to update Selecione um projecto existente para actualizao Click here to select path Clique aqui para seleccionar o caminho Select or create a new category name, to sort your mirrors in categories HTTrack Project Wizard... Assistente de projectos do WinHTTrack New project name: Nome do novo projecto: Existing project name: Nome do projecto existente: Project name: Nome do projecto: Base path: Caminho base: Project category: C:\\My Web Sites C:\\Os meus Sites Type a new project name, \r\nor select existing project to update/resume Introduza o nome para um novo projecto,\nou escolha um projecto para continuar ou actualizar New project Novo projecto Insert URL Introduza endereo URL URL: Endereo URL Authentication (only if needed) Identificao (se necessria) Login Login Password Palavra-chave Forms or complex links: Formulrios ou hiperligaes complexos: Capture URL... Capturar URL... Enter URL address(es) here Introduza aqui o endereo URL Enter site login Digite o login do site Enter site password Digite a palavra-chave do site Use this capture tool for links that can only be accessed through forms or javascript code Use esta ferramenta para capturar as hiperligaes que apenas podem ser acedidas atravs de um formulrio ou script de Java Choose language according to preference Selecione o seu idioma aqui Catch URL! Capturar URL! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. Queira definir temporariamente as opes do proxy no seu browser para os valores abaixo (cortar/colar o endereo proxy e a porta).\n Depois, no browser, clique no boto SUBMIT do formulrio, ou clique na hiperligao especfica que quer capturar. This will send the desired link from your browser to WinHTTrack. Isto enviar a hiperligao pretendida do seu browser para o WinHTTrack. ABORT CANCELAR Copy/Paste the temporary proxy parameters here Copiar/colar as preferncias temporrias do proxy aqui Cancel Cancelar Unable to find Help files! Impossvel encontrar os ficheiros de ajuda! Unable to save parameters! Impossvel guardar os parmetros! Please drag only one folder at a time Arraste apenas uma pasta de cada vez Please drag only folders, not files Arraste apenas pastas, no ficheiros Please drag folders only Arraste apenas pastas Select user-defined structure? Seleccionar uma estrutura personalizada? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! Assegure-se que a cadeia personalizada est correctat\nSe no, os nomes dos ficheiros sero incorrectos! Do you really want to use a user-defined structure? Quer realmente utilizar uma estrutura personalizada? Too manu URLs, cannot handle so many links!! Demasiados URL, impossvel manusear tantas hiperligaes !! Not enough memory, fatal internal error.. Memria insuficiente, erro fatal interno... Unknown operation! Operao desconhecida!! Add this URL?\r\n Adicionar este endereo URL?\r\n Warning: main process is still not responding, cannot add URL(s).. Aviso: o processo principal ainda no responde, impossvel adicionar URL. Type/MIME associations Correspondncias tipo/MIME File types: Tipos de ficheiros: MIME identity: MIME identity Select or modify your file type(s) here Seleccione ou modifique os tipos de ficheiros aqui Select or modify your MIME type(s) here Seleccione ou altere os tipos MIME aqui Go up Para cima Go down Para baixo File download information Informaes sobre os ficheiros transferidos Freeze Window Fixar a janela More information: Mais informaes: Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download Benvindo ao WinHTTrack Website Copier!\n\nClique no boto Seguinte para\n\n- iniciar um novo projecto ou\n- retomar um projecto existente. File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS Ficheiros de tipo:\nFicheiros contendo:\nEste ficheiro:\nNomes de pastas contendo:\nEsta pasta:\nHiperligaes neste domnio:\nHiperligaes num domnio contendo:\nHiperligaes deste servidor:\nHiperligaes contendo:\nEsta hiperligao:\nTODAS AS HIPERLIGAES\r\n Show all\nHide debug\nHide infos\nHide debug and infos Mostrar tudo\nOcultar erros\nOcultar informaes\nOcultar erros e informaes Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. Estrutura do site (padro)\nHtml na web/, imagens/outros na web/imagens/\nHtml na web/html, imagens/outros na web/imagens\nHtml na web/, imagens/outros na web/\nHtml na web/, imagens/outros na web/xxx, quando xxx a extenso do ficheiro\nHtml na web/html, imagens/outros na web/xxx\nEstrutura do site, sem www.domnio.xxx/\nHtml no nome_do_site/, imagens/outros no nome_do_site/imagens/\nHtml no nome_do_site/html, imagens/outros no nome_do_site/imagens\nHtml no nome_do_site/, imagens/outros no nome_do_site/\nHtml no nome_do_site/, imagens/outros no nome_do_site/xxx\nHtml no nome_do_site/html, imagens/outros no nome_do_site/xxx\nTodos os ficheiros na web/, com nomes aleatrios (gadget !)\nTodos os arquivos no nome_do_site/, com nomes aleatrios (gadget !)\nEstrutura definida pelo utilizador.. Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first S anlise de hiperligaes\nGuardar ficheiros HTML\nGuardar ficheiros no HTML\nGuardar todos os ficheiros (padro)\nGuardar ficheiros HTML primeiro Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down Manter no mesmo directrio\nPode ir para baixo (padro)\nPode ir para acima\nPode ir para baixo & para cima Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web Manter no mesmo endereo (padro)\nManter no mesmo domnio\nManter no mesmo domnio de nvel superior\nPercurso livre na Web Never\nIf unknown (except /)\nIf unknown Nunca\nSe desconhecido (excepto /)\nSe desconhecido no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules sem regras robots.txt\regras robots.txt excepto filtros\nseguir as regras robots.txt normal\nextended\ndebug normal\nestendido\ncorrigir Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download Cpia automtica de sites Web\nCpia interactiva de sites Web (questes)\nTransferir ficheiros especficos\nTransferir todos os sites nas pginas (cpias mltiplas)\nTestar as hiperligaes nas pginas (testar indicador)\n* Retomar cpia interrompida\n* Actualizar uma cpia existente Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL Open Source offline browser Website Copier/Offline Browser. Copy remote websites to your computer. Free. httrack, winhttrack, webhttrack, offline browser URL list (.txt) Previous Next URLs Warning Your browser does not currently support javascript. For better results, please use a javascript-aware browser. Thank you You can now close this window Server terminated A fatal error has occurred during this mirror httrack-3.49.5/lang/Portugues-Brasil.txt0000644000175000017500000011363314360553245015104 00000000000000LANGUAGE_NAME Portugus-Brasil LANGUAGE_FILE Portugues-Brasil LANGUAGE_ISO pt_BR LANGUAGE_AUTHOR Paulo Neto (layoutbr at lexxa.com.br) \r\n LANGUAGE_CHARSET ISO-8859-1 LANGUAGE_WINDOWSID Portuguese (Brazil) OK OK Cancel Cancelar Exit Sair Close Fechar Cancel changes Cancelar alteraes Click to confirm Clique para confirmar Click to get help! Clique para obter ajuda Click to return to previous screen Clique para voltar Click to go to next screen Clique para prosseguir Hide password Ocultar senha Save project Salvar projeto Close current project? Fechar o projeto atual? Delete this project? Excluir este projeto? Delete empty project %s? Excluir o projeto vazio %s? Action not yet implemented Ao ainda no implementada Error deleting this project Erro ao excluir este projeto Select a rule for the filter Escolha uma regra para o filtro Enter keywords for the filter Digite aqui as palavras para filtrar Cancel Cancelar Add this rule Adicionar esta regra Please enter one or several keyword(s) for the rule Digite uma ou mais palavras para esta regra Add Scan Rule Adicionar filtro Criterion Escolha uma regra String Escolha uma senha Add Adicionar Scan Rules Regras de filtragem Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Pode-se excluir ou aceitar vrias URL's ou links, usando (*) ou (?)\n Pode-se usar vrgulas (,) ou espaos entre os filtros.\n\n Por Exemplo: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Exclude links Excluir links Include link(s) Incluir links Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) Dica: Se voc quiser incluir todos os gif's da web, usar algo como +www.algumacoisa.com/*.gif. \n(+*.gif / -*.gif ir incluir/excluir TODOS os gif's de todos os sites) Save prefs Salvar preferncias Matching links will be excluded: Estes links sero proibidos Matching links will be included: Estas regras sero incluidas Example: Exemplo: gif\r\nWill match all GIF files gif\r\nDetectar todos os arquivos gif (ou arquivos GIF) blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' verde\r\nDetectar todos os arquivos contendo verde, tais como 'verdepiscina.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' grande.mov\r\nDetectar o arquivo 'grande.mov', porm no 'grande2.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\nDetectar links em diretrios contendo 'cgi' tais como /cgi-bin/algumacoisa.cgi cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\nDetectar links (diretrios) com nomes 'cgi-bin (porm no cgi-bin-2, por exemplo) someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. algumacoisa.com\r\nDetectar todos os links como www.algumacosia.com, privado.algumacoisa.com etc. someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. algumsite\r\nDetectar links como www.algumsite.com, www.algumsite.edu, private.algumsite.outrosite.com, etc. www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) ww.algumsite.com\r\nDetectar todos os links como ww.algumsite.com/... (porm no links como private.algumsite.com/..) someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. algumsite\r\nDetectar todos os links como www.algumsite.com/.., www.teste.abc/dealgumsite/index.html, www.teste.abc/teste/algumsite.html etc. www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.teste.com/teste/algumsite.html\r\nApenas detectar links como www.teste.com/teste/algumsite.html. Note que voc ter que digitar ambos os endereos (www.xxx.yyy) e caminhos (/teste/algumsite.html) All links will match Todos os links sero detectados Add exclusion filter Adicionar filtro de excluso Add inclusion filter Adicionar filtro de incluso Existing filters Filtros existentes Cancel changes Cancelar alteraes Save current preferences as default values Salvar preferncias atuais como valores padro Click to confirm Clique para confirmar No log files in %s! No h relatrios em %s! No 'index.html' file in %s! No existe o arquivo index.html em %s! Click to quit WinHTTrack Website Copier Click para sair do Website WinHTTrack Copier View log files Visualizar relatrios Browse HTML start page Navegar para a pgina inicial End of mirror Cpia finalizada View log files Visualizar relatrios Browse Mirrored Website Explorar a cpia do site New project... Novo projeto... View error and warning reports Visualizar relatrios de erros e avisos View report Visualizar informaes do relatrio Close the log file window Fechar janela do relatrio Info type: Tipo de informao: Errors Erros Infos Informaes Find Localizar Find a word Localizar uma palavra Info log file Arquivo de registro de informaes Warning/Errors log file Aviso/Arquivo de registro de erros Unable to initialize the OLE system No foi possvel iniciar o sistema OLE WinHTTrack could not find any interrupted download file cache in the specified folder! O WinHTTrack no pode encontar nenhuma cpia finalizada na pasta especificada! Could not connect to provider No foi possvel conectar ao provedor receive receber request Solicitar connect Conectar search Localizar ready preparado error erro Receiving files.. Recebendo arquivos... Parsing HTML file.. Analisando arquivo HTML... Purging files.. Limpando arquivos... Loading cache in progress.. Carregando cache... Parsing HTML file (testing links).. Analizando arquivo HTML (testando links)... Pause - Toggle [Mirror]/[Pause download] to resume operation Pausa - Escolher [Cpia do site]/[Suspender download] para prosseguir operao Finishing pending transfers - Select [Cancel] to stop now! Finalizando transferncias pendentes - Selecione [Cancelar] para parar agora! scanning analisando Waiting for scheduled time.. Aguardando horrio agendado... Transferring data.. Transferindo dados.. Connecting to provider Conectando ao provedor [%d seconds] to go before start of operation [%d segundos] antes de iniciar a operao Site mirroring in progress [%s, %s bytes] Processo de recebimento [%s, %s bytes] Site mirroring finished! Cpia do site finalizada! A problem occurred during the mirroring operation\n Ocorreu um problema durante a operao de recebimento\n \nDuring:\n Durante:\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! Veja o relatrio se necessrio.\n\nClique OK para sair do WinHTTrack.\n\nObrigado por usar o WinHTTrack Website Copier! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! Cpia finalizada.\nClique OK para sair.\nVeja o relatrio para verificar se est tudo OK.\n\nObrigado por utilizar o WinHTTrack! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * CPIA INTERROMPIDA! * *\r\nO cache temporrio atual necessrio para qualquer operao de atualizao e somente contm dados carregados durante a presente sesso.\r\n possvel que o cache anterior contenha dados mais completas; se voc no quiser perder esses dados, voc deve restaur-lo e excluir o cache atual.\r\n[Nota: Esta operao pode ser facilmente executada aqui excluindo os arquivos hts-cache/novo.*]\r\n\r\nVoc acredita que o cache anterior pode conter informaes mais completas, e voc deseja restaur-lo? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * ERRO DE CPIA! * *\r\nO HTTrack detectou que a cpia atual est vazia. Se ela fosse uma atualizao, a cpia anterior teria sido restaurada.\r\nCausa: a primeira pgina no foi encontrada, ou um problema de conexo ocorreu.\r\n=> Assegure-se de que o website existe, e/ou verifique suas configuraes proxy! <= \n\nTip: Click [View log file] to see warning or error messages Dica: Clique [Ver relatrio] para visualizar avisos e as mensagens de erro Error deleting a hts-cache/new.* file, please do it manually Erro ao excluir o arquivo hts-cache/novo.*, por favor faa isto manualmente Do you really want to quit WinHTTrack Website Copier? Voc quer realmente sair do WinHTTrack Website? - Mirroring Mode -\n\nEnter address(es) in URL box - Mtodo da cpia automtica -\n\nIntroduza o(s) endereo(s) na caixa de URL's - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - Mtodo de cpia com assistente (faz perguntas) -\n\nDigite o(s) endereo(s) na caixa de URL's - File Download Mode -\n\nEnter file address(es) in URL box - Mtodo de download do arquivo -\n\nIntroduza o(s) endereo(s) do(s) arquivo(s) na caixa de URL. - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - Mtodo de teste dos Links -\n\nIntroduza o(s) endreo(s) da(s) pgina(s) contendo os links para testar na caixa de URL. - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Mtodo de atualizao -\n\nVerifique o(s) endereo(s) na caixa de URL's, verifique os parmetros se necessrio e ento clique o boto 'AVANAR'. - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Mtodo de continuao (Operao Interrompida) -\n\nVerifique o(s) endereo(s) na caixa de URL's, verifique os parmetros se necessrio e ento clique o boto 'AVANAR'. Log files Path Caminho do arquivo de relatrio Path Caminho - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror - Mtodo da lista de links -\n\nUtilize a caixa URL's para digitar o(s) endereo(s) da(s) pgina(s) contendo links para recebimento. New project / Import? Novo projeto / Importar? Choose criterion Escolher uma ao Maximum link scanning depth Profundidade mxima de rastreamento Enter address(es) here Digite o(s) endereo(s) aqui Define additional filtering rules Definir filtros adicionais Proxy Name (if needed) Nome do Proxy (se necessrio) Proxy Port Porta do servidor proxy Define proxy settings Definir configuraes do servidor proxy Use standard HTTP proxy as FTP proxy Utilizar proxy HTTP padro como proxy FTP Path Caminho Select Path Selecionar caminho Path Caminho Select Path Selecionar caminho Quit WinHTTrack Website Copier Sair do WinHTTrack Website Copier About WinHTTrack Sobre o WinHTTrack Save current preferences as default values Salvar preferncias atuais como valor padro Click to continue Clique para continuar Click to define options Clique para definir opes Click to add a URL Clique para adicionar uma URL Load URL(s) from text file Carregar URL's de um arquivo texto WinHTTrack preferences (*.opt)|*.opt|| Preferncias do WinHTTrack (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| Arquivo de texto da lista de endereos (*.txt)|*.txt|| File not found! Arquivo no encontrado! Do you really want to change the project name/path? Voc deseja realmente alterar o nome/caminho do projeto? Load user-default options? Carregar opes padro do usurio? Save user-default options? Salvar opes padro do usurio? Reset all default options? Refazer todas as opes padro? Welcome to WinHTTrack! Bem-vindo ao WinHTTrack Website Copier! Action: Ao: Max Depth Profundidade mxima: Maximum external depth: Mximo de profundidade externa: Filters (refuse/accept links) : Filtros (incluir/excluir links) Paths Caminhos Save prefs Salvar preferncias Define.. Definir... Set options.. Definir as opes... Preferences and mirror options: Parmetros e opes de cpia do site Project name Nome do projeto Add a URL... Adicionar URL... Web Addresses: (URL) Endereo Web: (URL) Stop WinHTTrack? Suspender o WinHTTrack? No log files in %s! Nenhum relatrio em %s! Pause Download? Suspender a cpia do site? Stop the mirroring operation Parar recebimento Minimize to System Tray Minimizar para barra de sistema Click to skip a link or stop parsing Clique para ignorar um link ou interromper a cpia Click to skip a link Clique para ignorar um link Bytes saved Bytes gravados: Links scanned Link(s) processado(s) Time: Tempo: Connections: Conexes: Running: Em execuo: Hide Minimizar Transfer rate Taxa de transferncia: SKIP IGNORAR Information Informaes Files written: Arquivos gravados: Files updated: Arquivos atualizados: Errors: Erros: In progress: Em progresso: Follow external links Copiar arquivos mesmo em links externos Test all links in pages Testar todos os links da pgina Try to ferret out all links Tentar detectar todos os links Download HTML files first (faster) Transferir primeiro os arquivos HTML (mais rpido) Choose local site structure Escolher estrutura local dos arquivos Set user-defined structure on disk Configurar estrutura definida pelo usurio no disco Use a cache for updates and retries Usar cache para atualizaes e novas tentativas Do not update zero size or user-erased files No atualizar arquivos presentes, com tamanho zero ou excludos pelo usurio Create a Start Page Criar uma pgina inicial Create a word database of all html pages Criar uma base de dados da palavra de todas pginas HTML Build a complete RFC822 mail (MHT/EML) archive of the mirror Criar arquivo de e-mail RFC822 completo (MHT/EML) do espelho Create error logging and report files Criar relatrios de erros e informaes Generate DOS 8-3 filenames ONLY Gerar SOMENTE nomes de arquivos DOS (8+3 caracteres) Generate ISO9660 filenames ONLY for CDROM medias Gerar nomes de arquivo ISO9660 SOMENTE para mdias de CDROM Do not create HTML error pages No criar pginas de erro HTML Select file types to be saved to disk Selecionar tipos de arquivos para salvar Select parsing direction Selecionar direo de navegao no site Select global parsing direction Selecionar direo geral do site Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) Configurar regras de substituio de URL para links internos (j recebidos) e links externos (ainda no recebidos) Max simultaneous connections Mximo de conexes simultneas File timeout Tempo limite de espera por um arquivo Cancel all links from host if timeout occurs Cancelar todos os links de um servidor se ocorrer 'excesso de tempo' Minimum admissible transfer rate Taxa mnima de transferncia Cancel all links from host if too slow Cancelar todos os links de um servidor se ele for demasiadamente lento Maximum number of retries on non-fatal errors Nmero mximo de tentativas se um erro no fatal ocorrer Maximum size for any single HTML file Tamanho mximo de cada pgina HTML Maximum size for any single non-HTML file Tamanho mximo de cada arquivo Maximum amount of bytes to retrieve from the Web Nmero mximo de bytes para copiar da Web Make a pause after downloading this amount of bytes Pausar aps fazer o download desta quantidade de bytes Maximum duration time for the mirroring operation Tempo mximo para efetuar a cpia Maximum transfer rate Taxa de transferncia mxima Maximum connections/seconds (avoid server overload) Mximo de conexes/segundos (para evitar sobrecarga dos servidores) Maximum number of links that can be tested (not saved!) Nmero de mximo de links que pode ser testado (no armazenado!) Browser identity Indentidade do navegador Comment to be placed in each HTML file Notas de rodap em cada arquivo HTML Languages accepted by the browser Idiomas aceitos pelo navegador Additional HTTP headers to be sent in each requests Cabealhos HTTP adicionais para serem enviados em cada solicitao HTTP referer to be sent for initial URLs Referenciador HTTP a ser enviado para URLs iniciais Back to starting page Voltar pgina inicial Save current preferences as default values Salvar preferncias atuais como valor padro Click to continue Clique para continuar Click to cancel changes Clique para cancelar alteraes Follow local robots rules on sites Seguir as regras de mecanismo local para o site Links to non-localised external pages will produce error pages Links para pginas externas no localizadas produziro pginas de erro Do not erase obsolete files after update No excluir arquivos obsoletos aps atualizao Accept cookies? Aceitar cookies? Check document type when unknown? Verificar tipo do documento se for desconhecido? Parse java applets to retrieve included files that must be downloaded? Analisar applets JAVA para incluir arquivos recuperados que devero ser recebidos? Store all files in cache instead of HTML only Armazenar todos os arquivos no cache em vez de somente HTML Log file type (if generated) Tipo de relatrio (se gerado) Maximum mirroring depth from root address Profundidade mxima de recebimento do endereo raiz Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) Mximo de profundidade de espelhamento externo/endereos proibidos (0, isto , nenhum, o padro) Create a debugging file Criar um arquivo de debug Use non-standard requests to get round some server bugs Tentar evitar alguns erros do servidor usando chamadas no padro Use old HTTP/1.0 requests (limits engine power!) Utilizar chamadas antigas HTTP/1.0 limita a capacidade de captura! Attempt to limit retransfers through several tricks (file size test..) Tentativa de limitar a retransferncia atravs de vrias maneiras (teste do tamanho do arquivo...) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Tentativas para limitar o nmero de links ignorando URLs similares (www.foo.com==foo.com, http=https ...) Write external links without login/password Gravar links externos sem login/senha Write internal links without query string Gravar links internos sem perguntar Get non-HTML files related to a link, eg external .ZIP or pictures Capturar arquivos no HTML prximo de um link (ex: arquivos .ZIP localizados no exterior) Test all links (even forbidden ones) Testar todos os links (mesmo os proibidos) Try to catch all URLs (even in unknown tags/code) Tentar detectar todas as URL's (mesmo que os cdigos sejam desconhecidos) Get HTML files first! Receber arquivos HTML primeiro! Structure type (how links are saved) Tipo de estrutura (como os links so gravados) Use a cache for updates Utilizar cache para atulizaes Do not re-download locally erased files No receber novamente arquivos excludos localmente Make an index Criar um ndice Make a word database Criar um banco de dados de palavras Build a mail archive Criar um arquivo de mensagens Log files Relatrios DOS names (8+3) Nomes DOS (8+3) ISO9660 names (CDROM) Nomes ISO9660 (CDROM) No error pages Sem pgina de erros Primary Scan Rule Filtro primrio Travel mode Mtodo de percurso Global travel mode Mtodo de percurso global These options should be modified only exceptionally Normalmente estas configuraes no devem ser alteradas! Activate Debugging Mode (winhttrack.log) Ativar mtodo de debug (winhttrack.log) Rewrite links: internal / external Links substitudos: interno / externo Flow control Controle de fluxo Limits Limites Identity Identificao HTML footer Rodap do HTML Languages Idiomas Additional HTTP Headers Cabealhos HTTP adicionais Default referer URL URL de referncia padro N# connections Nmero de conexes Abandon host if error Abandonar servidor em caso de erro Minimum transfer rate (B/s) Taxa de transferncia mnima (bps) Abandon host if too slow Abandonar site se for lento demais Configure Configurar Use proxy for ftp transfers usar servidor proxy para transferncias FTP TimeOut(s) Limite de tempo Persistent connections (Keep-Alive) Conexes persistentes (Manter Ativo) Reduce connection time and type lookup time using persistent connections Reduza o tempo de conexo e o tempo do tipo de pesquisa usando conexes persistentes Retries Tentativas Size limit Limite de tamanho Max size of any HTML file (B) Tamanho mximo dos arquivos html: Max size of any non-HTML file Tamanho mximo de outros arquivos: Max site size Tamanho mximo do site Max time Tempo mximo de captura Save prefs Salvar preferncias Max transfer rate Taxa de transferncia mxima Follow robots.txt Seguir regras do arquivo robots.txt No external pages Sem pginas externas Do not purge old files No excluir arquivos antigos Accept cookies Aceitar cookies Check document type Verificar tipos de documento Parse java files Analizar arquivos JAVA Store ALL files in cache Armazenar todos os arquivos no cache Tolerant requests (for servers) Requisio de tolerncia (para servidores) Update hack (limit re-transfers) Corte de atualizao (limite da retransferncia) URL hacks (join similar URLs) URL hacks (unir URLs similares) Force old HTTP/1.0 requests (no 1.1) Forar requisio HTTP/1.0 anterior (no 1.1) Max connections / seconds Nmero mximo de conexes/segundos Maximum number of links Nmero mximo de links Pause after downloading.. Suspender aps copiar... Hide passwords Ocultar senha Hide query strings Ocultar seqencia de perguntas Links Links Build Estrutura Experts Only Somente especialistas Flow Control Controle de fluxo Limits Limites Browser ID Identidade do navegador Scan Rules Filtros Spider Indexador Log, Index, Cache Relatrio, ndice, Cache Proxy Servidor proxy MIME Types Tipos MIME Do you really want to quit WinHTTrack Website Copier? Voc deseja realmente sair do WinHTTrack Website Copier? Do not connect to a provider (already connected) No conectar ao provedor (se j estabelecida) Do not use remote access connection No usar acesso remoto de conexo Schedule the mirroring operation Programar uma operao alternativa Quit WinHTTrack Website Copier Sair do WinHTTrack Website Copier Back to starting page Voltar pgina inicial Click to start! Clique para iniciar No saved password for this connection! No salvar senha para esta conexo! Can not get remote connection settings No foi possvel obter parmetros de conexo Select a connection provider Selecionar uma conexo ao provedor de acesso Start Iniciar Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. Favor ajustar os parmetros de conexo se necessrio,\nento pressione INICIAR para carregar a operao alternativa Save settings only, do not launch download now. Somente salvar configuraes, no carregar agora. On hold Espera Transfer scheduled for: (hh/mm/ss) Aguardar at s: (hh/mm/ss) Start Iniciar Connect to provider (RAS) Provedor de acesso (RAS) Connect to this provider Conectar a este provedor Disconnect when finished Desconectar ao finalizar Disconnect modem on completion Desconectar o modem ao finalizar \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n(por favor nos comunique sobre erros ou problemas)\r\n\r\nDesenvolvimento:\r\nInterface (Windows): Xavier Roche\r\nMotor: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche e outros colaboradores\r\nTraduzido para o Portugus-Brasil por :\r\nPaulo Neto (layoutbr@lexxa.com.br) About WinHTTrack Website Copier Sobre o WinHTTrack Website Copier Please visit our Web page Por favor visite nossa pgina da Web Wizard query Assistente de dvidas Your answer: Sua resposta: Link detected.. Um link foi detectado Choose a rule Escolha uma regra Ignore this link Ignorar este link Ignore directory Ignorar diretrio Ignore domain Ignorar domnio Catch this page only Capturar somente esta pgina Mirror site Cpia do site Mirror domain Cpia do domnio Ignore all Ignorar tudo Wizard query Dvida do assistente NO No File Arquivo Options Opes Log Relatrio Window Janelas Help Ajuda Pause transfer Suspender transferncia Exit Sair Modify options Alterar opes View log Visualizar relatrio View error log Visualizar relatrios de erros View file transfers Visualizar transferncia dos arquivos Hide Ocultar About WinHTTrack Website Copier Sobre o WinHTTrack Website Copier Check program updates... Verificar atualizaes do programa &Toolbar Barra de ferramentas &Status Bar Barra de status S&plit Dividir File Arquivo Preferences Opes Mirror Cpia do site Log Relatrio Window Janelas Help Ajuda Exit Sair Load default options Carregar opes padro Save default options Salvar opes padro Reset to default options Excluir opes padro Load options... Carregar opes Save options as... Salvar opes como... Language preference... Preferncias do idioma... Contents... Contedo... About WinHTTrack... Sobre o WiHTTrack Website Copier New project\tCtrl+N Novo projeto\tCtrl+N &Open...\tCtrl+O &Abrir...\tCtrl+O &Save\tCtrl+S &Salvar\tCtrl+S Save &As... Salvar &como... &Delete... &Excluir... &Browse sites... &Procurar sites... User-defined structure Estrutura definida pelo usurio %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\tNome do arquivo sem extenso (ex.: imagem)\r\n%N\tNome do arquivo com extenso (ex.: imagem.gif)\r\n%t\tExtenso (ex.: gif)\r\n%p\tCaminho (sem o / final) (ex.: /imagens)\r\n%h\tNome do servidor (ex.: www.algumsite.com)\r\n%M\tURL MD5 (128 bits, 32 ascii bytes)\r\n%Q\tsequncia de pesquisa MD5 (128 bits, 32 ascii bytes)\r\n%q\tpequena sequncia de pesquisa MD5 (16 bits, 4 ascii bytes)\r\n\r\n%s?\tNome curto (ex.: %sN ) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Exemplo:\t%h%p/%n%q.%t\n->\t\tc:\\alternativo\\www.algumsite.com\\algumasimagens\\imagem.gif Proxy settings Configurao do servidor proxy Proxy address: Endereo do servidor proxy: Proxy port: Porta do servidor proxy: Authentication (only if needed) Identificao (se necessrio) Login Nome do usurio (Login) Password Senha Enter proxy address here Digite o endereo proxy Enter proxy port here Digite a porta do proxy aqui Enter proxy login Digite o login do proxy Enter proxy password Digite a senha do proxy Enter project name here Digite o nome do projeto aqui Enter saving path here Digite o caminho para salvar o projeto aqui Select existing project to update Selecionar um projeto existente para atualizar Click here to select path Clique aqui para selecionar o caminho Select or create a new category name, to sort your mirrors in categories Selecionar ou criar uma nova categoria, para classificar seus espelhos nas categorias HTTrack Project Wizard... Assistente de projetos HTTrack... New project name: Nome do novo projeto: Existing project name: Nome do projeto existente: Project name: Nome do projeto: Base path: Caminho base: Project category: Categoria do projeto: C:\\My Web Sites C:\\Meus Sites Type a new project name, \r\nor select existing project to update/resume Digite um nome para o novo projeto, \r\nou escolha um projeto existente para continuar/atualizar. New project Novo projeto Insert URL Inserir URL URL: URL: Authentication (only if needed) Identificao (se necessria) Login Login: Password Senha: Forms or complex links: Formulrios ou links complexos: Capture URL... Capturar URL... Enter URL address(es) here Digite aqui o(s) endereo(s) URL Enter site login Digite o login do site Enter site password Digite a senha do site Use this capture tool for links that can only be accessed through forms or javascript code Use esta ferramenta para capturar os links que podem ser acessados atravs de um formulrio ou cdigo javascript Choose language according to preference Selecione o seu Idioma aqui Catch URL! Capturar URL! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. Favor configurar uma navegao proxy temporria no seu Navegador para os seguintes valores (Copiar/Colar Endereo Proxy e Porta).\n Ento clique no boto ENVIAR do formulrio em sua pgina do navegador, ou clique no link especfico que voc deseja capturar. This will send the desired link from your browser to WinHTTrack. Isto enviar o link pretendido do seu navegador para o WinHTTrack. ABORT ABORTAR Copy/Paste the temporary proxy parameters here Copiar/Colar os parmetros temporrias do proxy aqui Cancel Cancelar Unable to find Help files! No foi possvel encontrar os arquivos de ajuda! Unable to save parameters! No foi possvel salvar os parmetros! Please drag only one folder at a time Por favor arraste apenas uma pasta de cada vez Please drag only folders, not files Por favor arraste somente pastas, no arquivos Please drag folders only Por favor arraste somente pastas Select user-defined structure? Selecionar estrutura definida pelo usurio? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! Assegure-se que a sequncia definida pelo usurio est correta.\nDe outro modo, o nome dos arquivos sero incorretos! Do you really want to use a user-defined structure? Voc deseja realmente selecionar uma estrutura definida pelo usurio? Too manu URLs, cannot handle so many links!! Muitas URLs, no possivel manejar tantos links!! Not enough memory, fatal internal error.. Memria insuficiente, erro fatal interno... Unknown operation! Operao desconhecida! Add this URL?\r\n Adicionar esta URL?\r\n Warning: main process is still not responding, cannot add URL(s).. Ateno: o processo principal no est respondendo, no foi possivel adicionar URL(s). Type/MIME associations Associaes tipo/MIME File types: Tipos de arquivo: MIME identity: MIME identity Select or modify your file type(s) here Selecionar ou modificar seu(s) tipo(s) de arquivo(s) aqui Select or modify your MIME type(s) here Selecionar ou modificar seu(s) tipo(s) de arquivo(s) MIME aqui Go up Ir para cima Go down Ir para baixo File download information Informaes do(s) arquivo(s) recebido(s) Freeze Window Fixar janela More information: Mais informaes: Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download Bem-vindo ao WinHTTrack Website Copier!\n\nFavor clicar o boto AVANAR para\n\niniciar um novo projeto ou retomar o download parcial. File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS Tipos de arquivo:\nNomes de arquivo contendo:\nNome deste arquivo:\nNomes de pasta contendo:\nNome desta pasta:\nLinks deste domnio:\nLinks no domnio contendo:\nLinks deste servidor:\nLinks contendo:\nEste link:\nTODOS OS LINKS Show all\nHide debug\nHide infos\nHide debug and infos Exibir tudo\nOcultar erros\nOcultar informaes\nOcultar erros e informaes Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. Estrutura do site (padro)\nHtml na web/, imagens/outros arquivos na web/imagens/\nHtml na web/html, imagens/outros na web/imagens\nHtml na web/, imagens/outros na web/\nHtml na web/, imagens/outros na web/xxx, quando xxx a extenso do arquivo\nHtml na web/html, imagens/outros na web/xxx\nEstrutura do site, sem www.dominio.xxx/\nHtml no nome_do_site/, imagens/outros no nome_do_site/imagens/\nHtml no nome_do_site/html, imagens/outros no nome_do_site/imagens\nHtml no nome_do_site/, imagens/outros no nome_do_site/\nHtml no nome_do_site/, imagens/outros no nome_do_site/xxx\nHtml no nome_do_site/html, imagens/outros no nome_do_site/xxx\nTodos os arquivos na web/, com nomes aleatrios (gadget !)\nTodos os arquivos no nome_do_site/, com nomes aleatrios (gadget !)\nEstrutura definida pelo usurio.. Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first Somente analisar\nArmazenar arquivos html\nArmazenar arquivos no html\nAmazenar todos os arquivos (padro)\nArmazenar arquivos html primeiro Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down Permanecer no mesmo diretrio\nPermite ir para abaixo (padro)\nPermite ir para cima\nPermite ir para cima & para baixo Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web Permanecer no mesmo endereo (padro)\nPermanecer no mesmo domnio\nPermanecer no mesmo domnio do nvel acima\nIr para todos os lugares da Web Never\nIf unknown (except /)\nIf unknown Nunca\nSe desconhecido (exceto /)\nSe desconhecido no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules nenhuma regra para robots.txt\nregras robots.txt exceto assistente\nseguir regras robots.txt normal\nextended\ndebug normal\nextendido\ncorrigir Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download Copiar site(s) da Web\nCopiar site(s) interativos da Web (perguntas)\nReceber arquivos especficos\nCopiar todas as pginas do site (alternao mltipla)\nTestar links nas pginas (testar indicador)\n* Retomar download interrompido\n* Atualizar download existente Relative URL / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL URI Relativa / URL Absoluta (padro)\nURL Absoluta / URL Absoluta\nURI Absoluta / URL Absoluta\nURL Original / URL Original Open Source offline browser Abrir origem offline no navegador Website Copier/Offline Browser. Copy remote websites to your computer. Free. Copiador de website/Navegador Offline. Copia sites remotos para seu computador. Gratuito. httrack, winhttrack, webhttrack, offline browser httrack, winhttrack, webhttrack, navegador offline URL list (.txt) Lista de URL (.txt) Previous Anterior Next Prximo URLs URLs Warning Ateno Your browser does not currently support javascript. For better results, please use a javascript-aware browser. Seu Navegador atualmente no suporta javascript. Para melhores resultados, favor usar um navegador com javascript-aware. Thank you Obrigado You can now close this window Voc pode fechar esta janela agora Server terminated Servidor finalizado A fatal error has occurred during this mirror Um erro fatal ocorreu durante este espelho View Documentation Exibir documentao Go To HTTrack Website Ir Para o Site do HTTrack Go To HTTrack Forum Ir Para o Frum do HTTrack View License Exibir Licena Beware: you local browser might be unable to browse files with embedded filenames Cuidado: seu navegador local pode no conseguir procurar arquivos com nomes de arquivos incorporados Recreated HTTrack internal cached resources Recursos em cache internos do HTTrack recriados Could not create internal cached resources No foi possvel criar recursos em cache internos Could not get the system external storage directory No foi possvel obter o diretrio de armazenamento externo do sistema Could not write to: No foi possvel gravar em: Read-only media (SDCARD) Mdia somente leitura (SDCARD) No storage media (SDCARD) Nenhuma mdia de armazenamento (SDCARD) HTTrack may not be able to download websites until this problem is fixed O HTTrack pode no conseguir baixar sites at que esse problema seja corrigido HTTrack: mirror '%s' stopped! HTTrack: espelho '%s' interrompido! Click on this notification to restart the interrupted mirror Clique nesta notificao para reiniciar o espelho interrompido HTTrack: could not save profile for '%s'! HTTrack: no foi possvel salvar o perfil para '%s'! httrack-3.49.5/lang/Polski.txt0000644000175000017500000010714414360553245013136 00000000000000LANGUAGE_NAME Polski LANGUAGE_FILE Polski LANGUAGE_ISO pl LANGUAGE_AUTHOR Lukasz Jokiel (Opole University of Technology, Lukasz.Jokiel at po.opole.pl) \r\n LANGUAGE_CHARSET ISO-8859-2 LANGUAGE_WINDOWSID Polish OK OK Cancel Anuluj Exit Wyjcie Close Zamknij Cancel changes Cofnij zmiany Click to confirm Kliknij aby potwierdzi Click to get help! Kliknij aby uzyska pomoc Click to return to previous screen Kliknij aby wrci Click to go to next screen Kliknij aby kontynuowa Hide password Ukryj haso Save project Zachowaj projekt Close current project? Czy zamkn ten projekt ? Delete this project? Czy usun ten projekt ? Delete empty project %s? Czy usun pusty projekt %s? Action not yet implemented Funcja jeszcze nie zaimplementowana. Error deleting this project Wystpi bd podczas usuwania tego projektu. Select a rule for the filter Wybierz regu dla tego filtra Enter keywords for the filter Podaj sowa kluczowe dla filtra Cancel Anuluj Add this rule Dodaj ten filter Please enter one or several keyword(s) for the rule Prosz poda jedno lub wiele sw kluczowych dla tej reguy Add Scan Rule Dodaj filtr Criterion Wybierz regu String Podaj sowo kluczowe Add Dodaj Scan Rules Filtry Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Moesz teraz wykluczy lub zaakceptowa klika URLi lub aczy, dzieki uyciu wildcards.\nMoesz uy take spacji pomidzy filtrami.\nPrzykad: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Exclude links Wyklucz cza Include link(s) Zaakceptuj cza Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) Tip: Jeeli chcesz zaakceptowa wszystkie gify na stronie(nach) uyj czego w rodzaju +www.pewnastrona.com/*.gif.\n(+*.gif / -*.gif zaakceptuje/odrzuci WSZYSTKIE gify na WSZYSTKICH stornach) Save prefs Zapisz ustawienia Matching links will be excluded: cza objte t regu zostan zignorowane (odrzucone): Matching links will be included: cza objte t regu zostan zaakceptowane: Example: Przykad: gif\r\nWill match all GIF files gif\r\nZnajdzie wszystkie gify blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' niebieskie\r\nZnajdzie wszystkie pliki zawierajce czon 'niebieskie', takie jak 'niebieskieniebo-maly.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' duzyplik.mov\r\nZnajdzie plik 'duzyplik.mov', ale nie 'duzyplik.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\nZnajdzie cza z katalogiem zawierajcym 'cgi' takie jak '/cgi-bin/pewnecgi.cgi' cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\nZnajdzie cza z katalogiem zawierajcym 'cgi-bin', ale na przykad nie 'cgi-bin-2' someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. pewnastrona.com\r\nZnajdzie wszystkie cza takie jak www.pewnastrona.com, members.pewnastrona.com itd. someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. pewnastrona\r\nZnajdzie wszystkie cza takie jak www.pewnastrona.com, www.pewnastrona.pl, www.pewnastrona.innastrona.edu itd. www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.pewnastrona.com\r\nZnajdzie wszystkie cza takie jak www.pewnastrona.com/ ... (lecz nie takie jak members.pewnastrona.com/...) someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. pewnastrona\r\nZnajdzie wszystkie acza takie jak www.pewnastrona.com/.., www.test.abc/mojapewnastrona/index.html, www.test.abc/test/pewnastrona.html itd. www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/pewnastrona.html\r\nZnajdzie tylko cza typu www.test.com/test/pewnastrona.html. Zauwa, e naley wpisa zarwno adres (www.xxx.yyy), jak i ciek (/test/pewnastrona.html) All links will match Wszystkie acza bd akceptowane/ignorowane (odrzucone) Add exclusion filter Dodaj filtr, ktry bdzie ignorowa (odrzuca) Add inclusion filter Dodaj filtr, ktry bedzie akceptowa. Existing filters Dodatkowe filtry Cancel changes Anuluj zmiany Save current preferences as default values Zapisz domylne ustawienia Click to confirm Kliknij aby potwierdzi No log files in %s! Brak plikw z logami w %s! No 'index.html' file in %s! Brak pliku index.html w %s! Click to quit WinHTTrack Website Copier Kliknij aby opuci WinHTTrack Website Copier View log files Poka pliki z logami Browse HTML start page Poka stron startow html End of mirror Koniec tworzenia lustra (mirroru) View log files Poka logi Browse Mirrored Website Otwrz kopi strony Web New project... Nowy projekt View error and warning reports Poka raport o bdach i ostrzeeniach View report Poka raport informacyjny Close the log file window Zamkinj okno z raportami Info type: Typ informacji Errors Bdy Infos Informacje Find Szukaj Find a word Znajd sowo Info log file Raport informacyjny Warning/Errors log file Raport o bdach i osterzeniach Unable to initialize the OLE system Nie moge zainicjalizowac OLE WinHTTrack could not find any interrupted download file cache in the specified folder! W tym katalogu nie ma cache\r\nWinHTTrack nie moe znale adnego przerwanego lustra (mirroru) Could not connect to provider Poczenie z usugodawc byo niemoliwe receive odbieram request dam connect czenie search szuka ready gotw error bd Receiving files.. Pobieram pliki... Parsing HTML file.. Parsowanie pliku HTML Purging files.. Czyszcz pliki... Loading cache in progress.. Trwa wczytywanie cache... Parsing HTML file (testing links).. Parsowanie pliku HTML (testowanie cz) Pause - Toggle [Mirror]/[Pause download] to resume operation Pauzuj (wybierz Lustro/Pauzuj transfer) aby kontunuowa) Finishing pending transfers - Select [Cancel] to stop now! Zatrzymywanie transferw w trakcie realizacji - Wybierz [Anuluj] aby zatrzyma teraz! scanning skanuj Waiting for scheduled time.. Czekam na okrelon godzin aby wystartowa Connecting to provider cze si z usugodawc [%d seconds] to go before start of operation Lustro czeka (%d sekund()) aby wystartowa Site mirroring in progress [%s, %s bytes] Tworzenie lustra w toku (%s, %s bajtw) Site mirroring finished! Zakoczono tworzenie lustra (mirroru) A problem occurred during the mirroring operation\n Poajwi si problem podczas tworzenia lustra\r\n \nDuring:\n Podczas:\r\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! Jeeli jest to wymagane sprawd logi.\r\nKliknij OK aby wyj z WinHTTrack Website Copier.\r\nDzikujemy za uywanie HTTrack ! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! Zakoczono tworzenie lustra.\r\nKliknij OK aby wyj z WinHTTrack.\r\nSprawd logi, upewnij si, czy wszystko przebiego dobrze.\r\nDzikujemy za uywanie HTTrack ! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * TWORZENIE LUSTRA PRZERWANE! * *\r\nObecnie wykorzystywany cache, wymagany dla jakichkolwiek operacji uaktualniajcych zawiera jedynie dane z obecnej przerwanej sesji.\r\nPoprzedni cache moe zawiera bardziej kompletne dane; jeli nie chcesz ich straci, przywr je i usu obecny cache.\r\n[Uwaga: Moesz to atwo zrobi tutaj poprzez skasowanie htscache/new.* pliki]\r\nCzy uwaasz, e poprzedni cache moe zawiera bardziej kompletne informacje i czy przywrci go ? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * BD LUSTRA! * *\r\nHTtrack stwierdza ze obecne lustro jest puste. Jeli byo to uaktualnienie, to przywrcono poprzedni wersj lustra. Powd: Nie mona byo odczyta pierwszych stron lub wystpi bd poczenia.\r\n=> Upewnij si czy strona cigle istnieje, lub te sprawd ustawienia proxy! <= \n\nTip: Click [View log file] to see warning or error messages Tip: Kliknij (Poka logi) aby zobaczy informacje o bdach i ostrzeeniach Error deleting a hts-cache/new.* file, please do it manually Bd podczas kasowania hts-cache/new.* plik/w, prosz zrobi to rcznie Do you really want to quit WinHTTrack Website Copier? Czy naprawd chcesz wyj z HTTrack ? - Mirroring Mode -\n\nEnter address(es) in URL box - Tryb tworzenia lustra -\n\nPodaj adres(y) w miejscu na URL. - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - Tryb tworzenia lustra z kreatorem (zadaje pytania) -\n\nPodaj adres(y) w miejscu na URL. - File Download Mode -\n\nEnter file address(es) in URL box - Tryb pobierania plikw -\n\nPodaj adres(y) w miejscu na URL. - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - Tryb testowania cz -\n\nPodaj adres(y) stron zawierajcy cza do testowania w miejscu na URL. - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Uaktualnij/Kontunuuj tryb lustra -\n\nSprawd adres(y) w miejscu na URL, a nastpnie wcinij przycisk Nastpny' i sprawd parametry. - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Kontunuuj przerwany tryb lustra -\n\nSprawd adres(y) w miejscu na URL, a nastpnie wcinij przycisk Nastpny' i sprawd parametry. Log files Path cieka dla raportw Path cieka - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror Tryb listy lustra, podaj adres(y) stron zawierajce cza do lustra w miejscu na URL. New project / Import? Nowy projekt / importowa ? Choose criterion Wybierz dziaanie Maximum link scanning depth Maksymalna gboko cz do skanowania Enter address(es) here Tutaj podaj adres Define additional filtering rules Zdefiniuj dodatkowe filtry Proxy Name (if needed) Proxy (jeeli wymagane) Proxy Port Port proxy Define proxy settings Zdefiniuj ustawienia proxy Use standard HTTP proxy as FTP proxy Uyj standardowego proxy HTTP jako proxy FTP Path cieka Select Path Wybierz ciek Path cieka Select Path Wybierz ciek Quit WinHTTrack Website Copier Wyjcie z WinHTTrack Website Copier About WinHTTrack O... WinHTTrack Save current preferences as default values Zapisz domylne opcje Click to continue Kliknij, aby kontunowa Click to define options Kliknij, aby zdefiniowa opcj Click to add a URL Kliknij, aby doda URL Load URL(s) from text file Wczytaj URLe z pliku tekstowego WinHTTrack preferences (*.opt)|*.opt|| Opcje WinHTTrack (*.opt)|*.opt|\r\n Address List text file (*.txt)|*.txt|| Tekstowy plik z adresami (*.txt)|*.txt|| File not found! Nie odnaleziono pliku! Do you really want to change the project name/path? Czy naprawd chesz zmieni nazw projektu/ciek ? Load user-default options? Wczyta domylne opcje uytkownika ? Save user-default options? Zapisa domylne opcje uytkownika ? Reset all default options? Wyczyci wszystkie domylne opcje ? Welcome to WinHTTrack! Witamy w WinHTTrack Website Copier! Action: Dziaanie: Max Depth Maksymalna gboko Maximum external depth: Maksymalna gboko zewntrzna: Filters (refuse/accept links) : Filtry (odrzu/akceptuj acza): Paths cieki Save prefs Zapisz opcje Define.. Definiuj Set options.. Ustaw opcje Preferences and mirror options: Preferencje i opcje lustra Project name Nazwa projektu Add a URL... Dodaj URL... Web Addresses: (URL) Adres strony w Sieci: (URL) Stop WinHTTrack? Zatrzyma WinHTTrack? No log files in %s! Brak raportw w %s! Pause Download? Pauzowa transfer? Stop the mirroring operation Zatrzymaj tworzenie lustra Minimize to System Tray Schowaj to okno do paseka systemowego Click to skip a link or stop parsing Kliknij aby pomin cze lub przerwa parsowanie Click to skip a link Kliknij aby pomin cze Bytes saved Zapisanych bajtw: Links scanned Zeskanowanych cz: Time: Czas: Connections: Poczenia: Running: Uruchomione: Hide Schowaj Transfer rate Szybko transferu: SKIP POMI Information Informacje Files written: Zapisane pliki: Files updated: Zaktualizowane pliki: Errors: Bdy: In progress: Podczas: Follow external links Pobierz pliki nawet jeli maj obcy (zwentrzny) adres Test all links in pages Przetestuj wszystkie cza na stronach Try to ferret out all links Sprbuj znale (wykry) wszystkie cza Download HTML files first (faster) Najpeirw pobierz pliki HTML (szybsze dziaanie) Choose local site structure Wybierz struktur lokalnego serwisu Set user-defined structure on disk Ustaw zdefiniowan przez uytkownika struktur na dysku Use a cache for updates and retries Uyj cache dla uaktualnie i ponowie Do not update zero size or user-erased files Nie pobieraj plikw ju obecnych lokalnie, z zerow wielkoci albo wymazancyh przez uytkownika Create a Start Page Utwrz stron startow Create a word database of all html pages Utwrz baz sw wystpujcych we wszystkich stronach HTML Create error logging and report files Utwrz pliki z raportem o bdach i informacjach Generate DOS 8-3 filenames ONLY Twrz TYLKO pliki z nazw w formacie 8.3 Generate ISO9660 filenames ONLY for CDROM medias Stwrz nazyw plikw ISO9660 TYLKO dla CDROM Do not create HTML error pages Nie zapisuj stron html z informacj o bdzie Select file types to be saved to disk Wybierz typy plikw, ktre zostan zapisane na dysku Select parsing direction Wybierz katalog lustra w tym serwisie Select global parsing direction Wybierz globalny katalog lustra w tym serwisie Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) Ustaw metody przepisywania URL'i dla lczy dostpnych lokalnie (pobranych) oraz czy dostpnych przez Internet (niepobranych) Max simultaneous connections Maksymalna liczba pocze File timeout Maksymalna warto przekroczenia czasu oczekiwania dla pliku Cancel all links from host if timeout occurs Odwoaj wszelkie cza z hosta jeeli ma miejsce przekroczenie czasu oczekiwanie Minimum admissible transfer rate Maksymalna tolerowana prdko transferu Cancel all links from host if too slow Odwoaj wszelkie cza z hosta jeeli jest za wolny Maximum number of retries on non-fatal errors Maksymalna liczba ponowie jeeli wydarzy si nie-fatalny bd Maximum size for any single HTML file Maksymalny rozmiar strony html Maximum size for any single non-HTML file Maksymalna wielko pliku Maximum amount of bytes to retrieve from the Web Maksymalna ilo bajtw moliwych do transferu z Sieci Web Make a pause after downloading this amount of bytes Zrb pauz po sicgniciu takiej iloci bajtw Maximum duration time for the mirroring operation Maksymalny czas dla lustra Maximum transfer rate Maksymalna prdko transferu Maximum connections/seconds (avoid server overload) Maksymalna ilo pocze na sekund (zapobiwga przeceniu serwera) Maximum number of links that can be tested (not saved!) Maksymalna liczba cz jakie mog by przetestowane (zapisanych moe by wicej!) Browser identity Identyfikacja przegldarki Comment to be placed in each HTML file Stopka do umieszczenia w kadym pliku HTML Back to starting page Z powortem do strony startowej Save current preferences as default values Zapisz domylne opcje Click to continue Kliknij, aby kontynuowa Click to cancel changes Kliknij, aby anulowa zmiany Follow local robots rules on sites Dostosuj si do praw robotw (robots) na serwisie Links to non-localised external pages will produce error pages Strony zewntrzne (niepobrane) bd poczone do stron z bdami Do not erase obsolete files after update Nie wymazuj starych plikw po uaktualnieniu Accept cookies? Zaakceptowa wysane ciasteczka (cookies)? Check document type when unknown? Sprawdza typy dokumentw jeeli s nieznane? Parse java applets to retrieve included files that must be downloaded? Parsowa aplety Javy aby odnale zawarte w nich pliki do pobrania ? Store all files in cache instead of HTML only Zmu do zapisania plikw w cache a nie tylko w plikach HTML Log file type (if generated) Raportujj typ plikw jeeli zosta wygenerowany Maximum mirroring depth from root address Maksymalna gboko lustra od pierwszych adresw Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) Maksymalna gboko tworzenia lustra dla zewntrznych/zakazanych adresw Create a debugging file Utwrz plik dla debuggera Use non-standard requests to get round some server bugs Sprbuj omin pewne bdy (bugs) serwera dziki uyciu niestandardowych da Use old HTTP/1.0 requests (limits engine power!) Uyj trybu zgodnoci z starszym standardem HTTP/1.0 (ogranicza moc silnika programu) Attempt to limit retransfers through several tricks (file size test..) Prba ograniczenia powtrnych transferw dziki kilku trikom (test wielkoci pliku) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Sprbuj ogranicznyc ilosc lacz poprzez pomijanie podobnych URL'i (www.foo.com==foo.com, http=https ..) Write external links without login/password Zapisuj zewntrzne acza bez login/haso Write internal links without query string Zapisuj wewntrzne cza bez paska wyszukiwania Get non-HTML files related to a link, eg external .ZIP or pictures Pobierz pliki nie-html w pobliu cza Test all links (even forbidden ones) Testuj wszystkie cza (nawet zabronione) Try to catch all URLs (even in unknown tags/code) Prbuj pozyska wszystkie cza (nawet te w nieznaych tag'ach/kodzie) Get HTML files first! Pobierz najpierw pliki HTML Structure type (how links are saved) Typ struktury (sposb w jaki cza s zapisywane) Use a cache for updates Uyj cache dla uaktualnie Do not re-download locally erased files Nie pobieraj lokalnie usunitych plikw Make an index Utwrz indeks Make a word database Utwrz baz sw Log files Raportuj pobrane pliki DOS names (8+3) Nazwy DOSowe (8+3) ISO9660 names (CDROM) Nazwy ISO9660 (CDROM) No error pages Bez stron z bdami Primary Scan Rule Gwny filtr Travel mode Tryb podniczy (mirror) Global travel mode Globalny tryb podrniczy (mirror) These options should be modified only exceptionally Zwykle te opcje nie powinny by modyfikowane Activate Debugging Mode (winhttrack.log) Aktywacja trybu dla debuggera (winthhrack.log) Rewrite links: internal / external Przepisz cza: na dostpne lokalnie (pobierane i lokalne)/ na dostpne przez Internet (zewntrzne i niepobierane) Flow control Kontrola przepywu Limits Ograniczenia Identity Identyfikacja HTML footer Stopka HTML N# connections N# pocze Abandon host if error Gdy bd, porzu hosta Minimum transfer rate (B/s) Minimalna szybko transferu (B/s) Abandon host if too slow Anuluj poczenie gdy transfer zbyt wolny Configure Konfiguruj Use proxy for ftp transfers Uyj proxy dla transferu przez FTP TimeOut(s) Przekroczenie(a) czasu oczekiwania Persistent connections (Keep-Alive) Podtrzymywane połączenia (Keep-Alive) Reduce connection time and type lookup time using persistent connections Zmniejsz czas połączenia i czas sprawdzania typu dzięki użyciu podtrzymywanych połączeń Retries Ponowienia Size limit Ograniczenia wielkoci Max size of any HTML file (B) Maksymalna wielko html Max size of any non-HTML file Maksymalna wielko innych Max site size Maksymalna wielko serwisu Max time Maksymalny czas Save prefs Zapisz opcje Max transfer rate Maksymalna szybko transferu Follow robots.txt Akceptuj prawa robots.txt No external pages Bez stron zewntrznych Do not purge old files Nie wymazuj starych plikw Accept cookies Akceptuj ciasteczka (cookies) Check document type Sprawd typ dokumentu Parse java files Parsuj pliki Javy Store ALL files in cache Zapisz wszystkie pliki w cache Tolerant requests (for servers) Tolerujce dania (dla serwerw) Update hack (limit re-transfers) Dostrajanie uaktualnienia (limitowanie retransferw) URL hacks (join similar URLs) Triki URL Force old HTTP/1.0 requests (no 1.1) Uyj da HTTP/1.0 (BEZ HTTP/1.1) Max connections / seconds Maksymalna ilo pocze na sekund Maximum number of links Maksymalna liczba cz Pause after downloading.. Pauza po pobraniu Hide passwords Ukryj hasa Hide query strings Schowaj paski zapyta Links cza Build Struktura Experts Only Tryb eksperta Flow Control Kontrola przepywu Limits Ograniczenia Browser ID ID przegldarki Scan Rules Filtry Spider Poszukiwacz (Pajk) Log, Index, Cache Raport, indeks, cache Proxy Proxy MIME Types Typy MIME Do you really want to quit WinHTTrack Website Copier? Czy naprawd chcesz wyj z WinHTTrack Website Copier? Do not connect to a provider (already connected) Nie cz si z usugodawc (jestem ju poczony) Do not use remote access connection Nie uywaj poczenia zewntrznego Schedule the mirroring operation Zadania dla lustra (mirrora) Quit WinHTTrack Website Copier Wyjd z WinHTTrack Website Copier Back to starting page Z powrotem do strony startowej Click to start! Kliknij aby wystartowa! No saved password for this connection! Nie zapisuj hase dla tego poczenia! Can not get remote connection settings Nie mogem pobra zdalnego ustawienia poczenia Select a connection provider Wybierz usugodawc z ktrym chcesz si poczy Start Start Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. Moesz teraz uruchomni tworzenie lustra przez wcinicie przycisku FINISH lub te zdefiniowa wicej opcji poczenia Save settings only, do not launch download now. Zapisz jedynie wybrane opcje, nie pobieraj adnych plikw On hold Opnienie Transfer scheduled for: (hh/mm/ss) Czekam do: (hh/mm/ss/) Start Start Connect to provider (RAS) cz si z usugodawc Internetu Connect to this provider Pocz si z tym usugodawc Disconnect when finished Zakocz poczenie z usugodawc po pobraniu Disconnect modem on completion Po pobraniu rozcz modem \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n(prosz poinformowa nas o jakichkolwiek bdach w dziaaniu programu)\r\n\r\nTwrcy:\r\nInterfejs(Windows): Xavier Roche\r\nMotor: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nPolska wersja jzykowa: ukasz Jokiel (Opole University of Technology, Lukasz.Jokiel@po.opole.pl) About WinHTTrack Website Copier O... WinHTTrack Website Copier Please visit our Web page Prosimy o odwiedzenie naszej strony w Sieci Wizard query Pytania kreatora Your answer: Twoja odpowied: Link detected.. Wykryem cze Choose a rule Wybierz regu Ignore this link Ignoruj to cze Ignore directory Ignoruj katalog Ignore domain Ignoruj domen Catch this page only Pobierz tylko t stron Mirror site Lustro serwisu (mirror) Mirror domain Lustro domeny (mirror) Ignore all Ignoruj wszystko Wizard query Pytanie kreatora NO NIE File Plik Options Opcje Log Raport Window Okno Help Pomoc Pause transfer Pauzuj transfer Exit Wyjcie Modify options Modyfikacja opcji View log Poka raport View error log Poka raport bdw View file transfers Poka transfer plikw Hide Schowaj About WinHTTrack Website Copier O... WinHTTrack Website Copier Check program updates... Znajd nowsz wersj programu &Toolbar Pasek narzdziowy &Status Bar Pasek statusu S&plit Podzia File Plik Preferences Opcje Mirror Lustro Log Raport Window Okno Help Pomoc Exit Wyjcie Load default options Wczytaj domylne opcje Save default options Zapisz domylne opcje Reset to default options Wyczy domylne opcje Load options... Wczytaj opcje Save options as... Zapisz opcje jako... Language preference... Wybr jzyka Contents... Zawarto About WinHTTrack... O... WinHTTrack Website Copier New project\tCtrl+N Nowy projekt\tCtrl+N &Open...\tCtrl+O &Otwrz... \tCtrl+O &Save\tCtrl+S Zapis&z\tCtrl+S Save &As... Zapisz j&ako... &Delete... &Usu &Browse sites... &Przegldaj strony sieciowe... User-defined structure Struktura zdefiniowana przez uytkownika %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\r\nNazwa pliku bez typu pliku (np: image)\r\n%N\r\nNazwa wraz z typem pliku (np: image.gif)\r\n%t\r\nTyp pliku (np: .gif)\r\n%p\r\nScieka [bez kocowego /] (np: /pewneobrazki)\r\n%h\r\nNazwa hosta (np: www.pewnyhost.com)\r\n%s?\r\n%M\tURL MD5 (128 bits, 32 ascii bytes)\r\n%Q\tquery string MD5 (128 bits, 32 ascii bytes)\r\n%q\tsmall query string MD5 (16 bits, 4 ascii bytes)\r\n\r\nKrtka wersja dla DOS (np: %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Przykad:\r\n%h%p/%n%q.%t\r\n-> \t\tc:\\mirror\\www.pewienhost.com\\pewneobrazki\\obrazek.gif Proxy settings Ustawienia proxy Proxy address: Adres proxy Proxy port: Port proxy Authentication (only if needed) Autentykacja (jeeli wymagana) Login Login Password Haso (pass) Enter proxy address here Tutaj podaj adres proxy Enter proxy port here Tutaj podaj port proxy Enter proxy login Tutaj podaj login proxy Enter proxy password Tutaj podaj haso (pass) dla proxy Enter project name here Tutaj podaj nazw projektu Enter saving path here Tutaj podaj ciek pod ktr zostanie zapisany projekt Select existing project to update Tutaj wybierz istniejcy projekt przeznaczony do aktualizacji Click here to select path Kliknij tutaj aby wybra ciek Select or create a new category name, to sort your mirrors in categories Wybierz lub stwrz nowa kategorie, tak aby posortowac lustra w kategorie HTTrack Project Wizard... Kreator projektu HTTrack New project name: Nazwa nowego projektu: Existing project name: Nazwa istniejcego projektu: Project name: Nazwa projektu: Base path: cieka bazowa Project category: Projekt - kategoria: C:\\My Web Sites C:\\Moje Strony Web Type a new project name, \r\nor select existing project to update/resume Wpisz nazw nowego projektu,\r\nalbo wybierz istniejcy projekt, ktry chesz kontunuowa/uaktualni New project Nowy projekt Insert URL Wstaw URL URL: Adres URL: Authentication (only if needed) Autentykacja (jeeli wymagana) Login Login Password Haso (pass) Forms or complex links: Formularze lub skomplikowane cza: Capture URL... Pobierz (pochwy) URL Enter URL address(es) here Tutaj podaj adres URL Enter site login Podaj login serwisu Enter site password Podaj haso (pass) serwisu Use this capture tool for links that can only be accessed through forms or javascript code Uyj tego narzdzia aby pobra cza, ktre s dostpne tylko przez formularze lub cza z javascript'u Choose language according to preference Wybierz jzyk Catch URL! Pobierz URL! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. Prosz tymczasowo ustawi proxy w Twojej przegldarce (lub Ustawieniach Internetowych) na nastpujce: (wytnij/wstaw adres proxy oraz port).\r\nNastpnie w przegldarce, kliknij na formularzu lub kliknij cze, ktre chcesz pobra. This will send the desired link from your browser to WinHTTrack. Ta operacja przechwyci cze z Twojej przegldarki do HTTrack'a ABORT ANULUJ Copy/Paste the temporary proxy parameters here Wytnij/wstaw tutaj tymczasowe ustawienia proxy Cancel Anuluj Unable to find Help files! Nie mona znale plikw pomocy Unable to save parameters! Zapisanie opcji niemoliwe Please drag only one folder at a time Prosz przecign tylko jeden folder Please drag only folders, not files Prosz przecign folder, a nie plik Please drag folders only Prosz przecign folder Select user-defined structure? Wybra zdefiniowan przez uytkownika struktur ? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! Upewnij si czy zdefiniowane przez uytkownika cigi (strings) s poprawne\r\nJeli tego nie zrobisz to nazwy plikw bd wyglday bardzo dziwnie! Do you really want to use a user-defined structure? Czy naprawd chcesz wybra zdefiniowan przez uytkownika struktur? Too manu URLs, cannot handle so many links!! Zbyt duo URLi, nie mona obsuy tak wielu cz!! Not enough memory, fatal internal error.. Za mao pamici, fatalny bd wewntrzny... Unknown operation! Nieznana operacja! Add this URL?\r\n Doda ten URL?\r\n Warning: main process is still not responding, cannot add URL(s).. Ostrzeenie: gwny proces cigle nie odpowiada, nie mona doda URLi.. Type/MIME associations Typ/MIME Skojarzenia File types: Typy plikw: MIME identity: Tosamo MIME Select or modify your file type(s) here Wybierz lub zmodyfikuj tutaj swoje plik(i) Select or modify your MIME type(s) here Wybierz lub zmodyfikuj tutaj swoje typy MIME Go up Id w gr Go down Id w d File download information Informacje o transferze plikw Freeze Window Zachowaj ukad okien More information: Dodatkowe informacje: Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download Witamy w WinHTTrack Website Copier!\n\nProsz wcisn przycisk DALEJ aby\n\n- uruchomi nowy projekt\n- aby wznowi przerwany projekt File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS Nazwy plikw z rozszerzeniem:\nNazwy plikw zawierajce:\nTa nazwa pliku:\nNazwy folderw zawierajce:\nTa nazwa folderu:\ncza w tej domenie:\ncza w domenie zawierajce:\ncza z tego hosta:\ncza zawierajce:\nTo cze:\nWSZYSTKIE CZA Show all\nHide debug\nHide infos\nHide debug and infos Poka wszystko\nUkryj debugowanie\nUkryj informacje\nUkryj debugowanie i informacje Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. Struktura strony (domylnie))\nHtml w Web/, obrazki/inne pliki w Web/obrazki/\nHtml na web/html, obrazki/outros na web/imagens\nHtml na web/, imagens/outros na web/\nHtml na web/, imagens/outros na web/xxx, quando xxx a extenso do arquivo\nHtml na web/html, imagens/outros na web/xxx\nEstrutura do site, sem www.dominio.xxx/\nHtml no nome_do_site/, imagens/outros no nome_do_site/imagens/\nHtml no nome_do_site/html, imagens/outros no nome_do_site/imagens\nHtml no nome_do_site/, imagens/outros no nome_do_site/\nHtml no nome_do_site/, imagens/outros no nome_do_site/xxx\nHtml no nome_do_site/html, imagens/outros no nome_do_site/xxx\nTodos os arquivos na web/, com nomes aleatrios (gadget !)\nTodos os arquivos no nome_do_site/, com nomes aleatrios (gadget !)\nEstrutura definida pelo usurio.. Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first Skanuj\nZachowaj pliki html\nZachowaj pliki nie-html\nZachowaj wszystkie pliki (domylnie)\nNajpierw zachowaj pliki html Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down Pozosta w tym samym katalogu\nMoe i w d (domylnie)\nMoe i w gr\nMoe i w gr i w d Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web Pozosta na tym samym adresie (domylnie)\nPozosta na tej samej domenie\nPozosta na domenie nadrzdnej\nId po caej sieci Web Never\nIf unknown (except /)\nIf unknown Nigdy\nJeli nieznane (bez /)\nJeli nieznane no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules Ignoruj reguy robots.txt\nrobots.txt oprcz kreatora\npodaj za reguami robots.txt normal\nextended\ndebug normalny\nrozszerzony\ntestowy Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download Pobierz stron(y) Web\nPobierz stron(y) Web + pytania\npobierz oddzielne pliki\nPobierz strony Web w stronach (wiele luster)\nTestuj cza na stronach (test zakadek)\n* Wznw tworzenie lustra\n* Uaktualnij lustro Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL Relatywne URI / Absolutne URI (domylnie)\nAbsolutne RRL / Absolutne URL\nAbsolutne URI / Absolutne URL\nOriginalne URL / Oryginalne URL Open Source offline browser Przegladarka Offline Open Source Website Copier/Offline Browser. Copy remote websites to your computer. Free. Program kopiujacy strony/Przegladarka Offline. Kopiuje strony WWW z Internetu na Twoj komputer. Darmowy. httrack, winhttrack, webhttrack, offline browser httrack, winhttrack, webhttrack, przegladarka offline. URL list (.txt) Lista URL'i (.txt) Previous Poprzedni Next Nastepny URLs URL'e Warning Ostrzezenie Your browser does not currently support javascript. For better results, please use a javascript-aware browser. Twoja przegladarka nie obsluguje jeszcze JavaScript. Aby lepiej wyswietlac strony uzyj przegladarki z obsluga JavaScript. Thank you Dziekuje You can now close this window Mozesz teraz zamknac to okno. Server terminated Serwer zakonczyl prace A fatal error has occurred during this mirror Podczas tworzenia lustra wydarzyl sie fatalny blad. httrack-3.49.5/lang/Norsk.txt0000644000175000017500000010374214360553245012771 00000000000000LANGUAGE_NAME Norsk LANGUAGE_FILE Norsk LANGUAGE_ISO no LANGUAGE_AUTHOR Tobias "Spug" Langhoff (Dark Spug at hazardlabs.com )\r\n[ spug_enigma@hotmail.com ] \r\n LANGUAGE_CHARSET ISO-8859-1 LANGUAGE_WINDOWSID Norwegian (Nynorsk) OK OK Cancel Avbryt Exit Avslutt Close Lukk Cancel changes Angre endringer Click to confirm Klikk for bekrefte Click to get help! Klikk her for f hjelp! Click to return to previous screen Klikk for g tilbake til forrige skjerm Click to go to next screen Klikk for g til neste skjerm Hide password Skjul passord Save project Lagre prosjekt Close current project? Vil du lukke prosjektet? Delete this project? Vil du slette dette prosjektet? Delete empty project %s? Vil du slette det tomme prosjektet %s? Action not yet implemented Denne funksjonen er ikke utviklet enda Error deleting this project Kunne ikke slette prosjektet Select a rule for the filter Velg en regel for dette filteret Enter keywords for the filter Skriv inn nkkelord for dette filteret Cancel Avbryt Add this rule Legg til regel Please enter one or several keyword(s) for the rule Skriv inn et eller flere nkkelord for denne regelen Add Scan Rule Legg til skeregel Criterion Kriterier String Streng Add Legg til Scan Rules Skeregler Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Bruk jokertegn (* og ?) for ekskludere eller inkludere URLer eller linker.\nDu kan sette inn flere skeregler p samme linje.\nBruk mellomrom som separatortegn.\n\nEksempel: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Exclude links Ekskluder link(er) Include link(s) Inkluder link(er) Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) Tips: For inkludere ALLE GIF-filer, skriv noe snt som +www.someweb.com/*.gif. \n(+*.gif / -*.gif inkluderer/ekskluderer ALLE GIF-filer fra ALLE sider) Save prefs Lagre innstillinger Matching links will be excluded: Flgende matchende linker vil bli utelukket: Matching links will be included: Flgende matchende linker vil bli inkludert: Example: Eksempel: gif\r\nWill match all GIF files gif\r\nMatcher alle GIF-filer blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' blue\r\nFinner alle filer med matchende tekst. Skriver du f.eks. 'blue' lastes 'bluesky-small.jpeg' ned. bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' bigfile.mov\r\nFinner filen 'bigfile.mov', men ikke 'bigfile2.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\nFinner linker med mappenavn som matcher tekststrengen 'cgi', f.eks. /cgi-bin/somecgi.cgi cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\nFinner linker med mappenavn som matcher hele 'cgi-bin'-strengen (men ikke cgi-bin-2, for eksempel) someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb.com\r\nFinner linker med matchende tekststreng, som f.eks www.someweb.com, private.someweb.com osv. someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. someweb\r\nFinner linker med mappenavn som matcher tekststrengen 'someweb', for eksempel www.someweb.com, www.someweb.no, private.someweb.otherweb.com osv. www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.someweb.com\r\nFinner linker som matcher hele 'www.someweb.com'-strengen (men ikke linker som f.eks private.someweb.com/.. osv.) someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. someweb\r\nFinner alle linker med matchende tekststreng, som for eksempel www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html osv. www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/someweb.html\r\nFinner bare filen 'www.test.com/test/someweb.html'. Legg merke til at du m skrive hele adressen (URL + mappenavn) All links will match Alle linker matcher Add exclusion filter Legg til ekskluderingsfilter Add inclusion filter Legg til inkluderingsfilter Existing filters Eksisterende filtre Cancel changes Angre endringer Save current preferences as default values Lagre nvrende innstillinger som standardinnstillinger Click to confirm Klikk for bekrefte No log files in %s! Det finnes ingen logg-filer i %s! No 'index.html' file in %s! Det finnes ingen 'index.html'-fil i %s! Click to quit WinHTTrack Website Copier Klikk for avslutte WinHTTrack Website Copier View log files Vis logg-filer Browse HTML start page Vis HTML-startside End of mirror Kopieringen er fullfrt View log files Vis logg-filer Browse Mirrored Website Vis den kopierte websiden New project... Nytt prosjekt... View error and warning reports Vis feil- og advarselsrapporter View report Vis rapport Close the log file window Lukk loggvinduet Info type: Informasjonstype: Errors Feil Infos Informasjon Find Sk Find a word Sk etter et ord Info log file Informasjonslogg Warning/Errors log file Advarsels- og feillogg Unable to initialize the OLE system Kan ikke starte OLE-systemet WinHTTrack could not find any interrupted download file cache in the specified folder! WinHTTrack kunne ikke finne noen avbrutte nedlastninger i den angitte mappen! Could not connect to provider Kunne ikke koble til leverandr receive mottar request tillatelse connect kobler til search sker ready klar error feil Receiving files.. Mottar filer... Parsing HTML file.. Overfrer HTML-fil... Purging files.. Sletter filer... Loading cache in progress.. Parsing HTML file (testing links).. Overfrer HTML-fil (tester linker)... Pause - Toggle [Mirror]/[Pause download] to resume operation Pause - Velg [Kopier]/[Pause nedlasting] for fortsette nedlastingen Finishing pending transfers - Select [Cancel] to stop now! Avslutter aktive nedlastinger - velg [Avbryt] for avslutte n! scanning sker Waiting for scheduled time.. Venter p planlagt tidspunkt... Connecting to provider Kobler til leverandr [%d seconds] to go before start of operation [%d sekunder] til start Site mirroring in progress [%s, %s bytes] Kopiering pgr [%s, %s bytes] Site mirroring finished! Kopieringen er fullfrt! A problem occurred during the mirroring operation\n Et problem oppsto under kopieringen\n \nDuring:\n \nUnder:\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! \nVis loggen hvis ndvendig.\n\nKlikk p AVSLUTT for avslutte WinHTTrack Website Copier.\n\nTakk for at du brukte WinHTTrack! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! Kopieringen er fullfrt.\nKlikk AVSLUTT for avslutte WinHTTrack.\nVis loggfil(er) vis det er ndvendig, for sjekke at alt er OK.\n\nTakk for at du brukte WinHTTrack! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * KOPIERINGEN ER AVBRUTT! * *\r\nDen nvrende midlertidige cachen er obligatorisk for alle oppdateringsoperasjoner, og inneholder bare data fra den siste avbrutte kopieringsprosessen.\r\nDen tidligere cachen kan inneholde fyldigere informasjon; hvis du nsker beholde den informasjonen m du gjenopprette den og slette den aktuelle cachen.\r\n[OBS: Dette kan lettest gjres ved slette alle 'hts-cache/new.*'-filer]\r\n\r\nTror du den tidligere cache-filen kanskje inneholder fyldigere informasjon, og vil du gjenopprette den? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * KOPIERINGSFEIL! * *\r\nHttrack har oppdaget at den gjeldende websiden er tom. Hvis du var i gang med oppdatere enn kopi, vil det gamle innholdet bli gjenopprettet.\r\nMulig rsak: Den frste siden kunne enten ikke finnes, eller det oppstod et problem med forbindelsen.\r\n=> Kontroller at websiden fremdeles finnes, og/eller sjekk proxy-innstillingene dine! <= \n\nTip: Click [View log file] to see warning or error messages \n\nTips: Klikk p [Vis loggfil] for se advarsler og feilmeldinger Error deleting a hts-cache/new.* file, please do it manually Det oppstod en feil ved sletting av hts-cache/new.*-filen. Prv slett filen manuelt. Do you really want to quit WinHTTrack Website Copier? Vil du virkelig avslutte WinHTTrack Website Copier? - Mirroring Mode -\n\nEnter address(es) in URL box - Kopiering av webside -\n\nSkriv adressen(e) i URL-feltet - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - Interaktiv guide (sprsml) -\n\nSkriv inn adressen(e) i URL-feltet - File Download Mode -\n\nEnter file address(es) in URL box - Filnedlasting -\n\nSkriv inn filen(e)s adresse(r) i URL-feltet - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - Linktest -\n\nSkriv inn webadressen(e) du vil teste i URL-feltet - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Oppdatering -\n\nBekreft adressen(e) i URL-feltet, sjekk eventuelt om innstillingene er riktige og trykk deretter p 'NESTE' - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Fortsett kopiering (hvis kopieringen ble avbrutt) -\n\nBekreft adressen(e) i URL-feltet, sjekk eventuelt om innstillingene er riktige og trykk deretter p 'NESTE' Log files Path Plassering av loggfil Path Bane - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror - Linkliste -\n\nBruk URL-feltet til angi adresse(r) p sider som inneholder linker som skal kopieres. New project / Import? Nytt prosjekt / importer prosjekt? Choose criterion Velg kriterier Maximum link scanning depth Maximum skedybde p linker Enter address(es) here Skriv inn adressen(e) her Define additional filtering rules Velg ytterligere filtreringsregler Proxy Name (if needed) Proxy-navn (om ndvendig) Proxy Port Proxy-port Define proxy settings Velg proxy-innstillinger Use standard HTTP proxy as FTP proxy Bruk standard HTTP-proxy som FTP-proxy Path Bane Select Path Velg bane Path Bane Select Path Velg bane Quit WinHTTrack Website Copier Avslutt WinHTTrack Website Copier About WinHTTrack Om WinHTTrack Save current preferences as default values Lagre nvrende innstillinger som standardinnstillinger Click to continue Klikk for fortsette Click to define options Klikk for velge innstillinger Click to add a URL Klikk for legge til en URL Load URL(s) from text file Hent URL(er) fra tekstfil WinHTTrack preferences (*.opt)|*.opt|| WinHTTrack-innstillinger (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| Adresseliste (tekstfil) (*.txt)|*.txt|| File not found! Finner ikke filen! Do you really want to change the project name/path? Vil du virkelig endre prosjektets navn / plassering? Load user-default options? pne egendefinerte innstillinger? Save user-default options? Lagre egendefinerte innstillinger? Reset all default options? Nullstill alle standardinnstillinger? Welcome to WinHTTrack! Velkommen til WinHTTrack! Action: Handling: Max Depth Maksimum dybde Maximum external depth: Maksimum ekstern dybde: Filters (refuse/accept links) : Filtre (ekskluder/inkluder linker): Paths Baner Save prefs Lagre innstillinger Define.. Definer... Set options.. Velg innstillinger... Preferences and mirror options: Instillinger og kopieringsvalg: Project name Prosjektnavn Add a URL... Legg til en URL... Web Addresses: (URL) Webadresser: (URL) Stop WinHTTrack? Stopp WinHTTrack? No log files in %s! %s inneholder ingen loggfiler! Pause Download? Pause kopieringen? Stop the mirroring operation Stopp kopieringsprosessen Minimize to System Tray Minimer til systemlinjen Click to skip a link or stop parsing Klikk for hoppe over en link eller stoppe overfringen Click to skip a link Klikk for hoppe over en link Bytes saved Bytes nedlastet Links scanned Gjennomskte linker Time: Tid: Connections: Tilkoblinger: Running: Kjrer: Hide Minimer Transfer rate Overfringshastighet SKIP HOPP OVER Information Informasjon Files written: Kopierte filer: Files updated: Oppdaterte filer: Errors: Feil: In progress: Arbeider: Follow external links Flg eksterne linker Test all links in pages Test alle linker p siden Try to ferret out all links Prv utvide alle linker Download HTML files first (faster) Last ned HTML-filer frst (raskere) Choose local site structure Velg lokal sidestruktur Set user-defined structure on disk Velg brukerdefinert sidestruktur p disken Use a cache for updates and retries Bruk cache til oppdateringer og oppdateringsforsk Do not update zero size or user-erased files Ikke oppdater tomme filer eller filer slettet av bruker Create a Start Page Opprett en startside Create a word database of all html pages Opprett en ord-database over alle HTML-sider Create error logging and report files Opprett feillogging og rapporter Generate DOS 8-3 filenames ONLY Lag filnavn KUN i DOS 8-3-format Generate ISO9660 filenames ONLY for CDROM medias Lag filnavn i ISO9660-format KUN for CD-ROM Do not create HTML error pages Ikke opprett HTML-feilmeldinger Select file types to be saved to disk Velg filtyper som skal kopieres Select parsing direction Velg overfringsretning Select global parsing direction Velg global overfringsretning Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) Velg regler for omskrivning av URL for interne linker (nedlastede linker) og eksterne linker (ikke nedlastede) Max simultaneous connections Maksimum antall samtidige forbindelser File timeout Fil time-out Cancel all links from host if timeout occurs Avbryt alle linker fra vert hvis time-out oppstr Minimum admissible transfer rate Minimum akseptabel overfringshastighet Cancel all links from host if too slow Avbryt alle linker fra vert hvis overfringen er for langsom Maximum number of retries on non-fatal errors Maksimalt antall forsk p ikke-fatale feil Maximum size for any single HTML file Maksimum filstrrelse for en enkelt HTML-fil Maximum size for any single non-HTML file Maksimum filstrrelse for en enkelt ikke-HTML-fil Maximum amount of bytes to retrieve from the Web Maksimum antall bytes som hentes fra internett Make a pause after downloading this amount of bytes Pause kopieringen nr s mange bytes har blitt lastet ned: Maximum duration time for the mirroring operation Maksimal overfringstid p kopieringsprosessen Maximum transfer rate Maksimum overfringshastighet Maximum connections/seconds (avoid server overload) Maksimum antall forbindelser/sekunder (for unng overbelastning av serveren) Maximum number of links that can be tested (not saved!) Maksimalt antall linker som kan testes (ikke lagret!) Browser identity Nettleser-identitet Comment to be placed in each HTML file Sett inn kommentar i alle HTML-filer Back to starting page Tilbake til startside Save current preferences as default values Lagre nvrende innstillinger som standardinnstillinger Click to continue Klikk for fortsette Click to cancel changes Klikk for angre endringer Follow local robots rules on sites Flg lokale robots-regler p websiden Links to non-localised external pages will produce error pages Linker til eksterne sider som ikke finnes vil opprette en feilside Do not erase obsolete files after update Ikke slett undvendige filer etter oppdatering Accept cookies? Aksepter informasjonskapsler (cookies)? Check document type when unknown? Sjekk dokumenttypen hvis ukjent? Parse java applets to retrieve included files that must be downloaded? Overfr java-appleter sammen med inkluderte filer som skal lastes ned? Store all files in cache instead of HTML only Lagre alle filer i cache i stedet for bare HTML Log file type (if generated) Loggfiltype (hvis den opprettes) Maximum mirroring depth from root address Maksimum kopieringsdybde fra rotadressen (root) Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) Maksimum kopieringsdybde for eksterne/forbudte adresser (0, alts ingen, er standard) Create a debugging file Opprett en feilfinningsfil Use non-standard requests to get round some server bugs Bruk ikke-standarde foresprsler for unng serverfeil Use old HTTP/1.0 requests (limits engine power!) Bruk gamle HTTP/1.0-foresprsler (begrenser effektiviteten!) Attempt to limit retransfers through several tricks (file size test..) Prv begrense gjentakelser av samme overfring ved bruke spesielle 'triks' (f.eks teste filstrrelsen) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Write external links without login/password Skriv eksterne linker uten brukernavn/passord Write internal links without query string Skriv interne linker uten sprre Get non-HTML files related to a link, eg external .ZIP or pictures Hent ikke-HTML-filer relatert til linker, f.eks eksterne .ZIP-filer eller bilder Test all links (even forbidden ones) Test alle linker (ogs forbudte linker) Try to catch all URLs (even in unknown tags/code) Prv kopiere alle URLer (selv i ukjente tags / ukjent kode) Get HTML files first! Kopier HTML-filer frst! Structure type (how links are saved) Angi struktur (hvordan linker lagres) Use a cache for updates Bruk cache til oppdateringer Do not re-download locally erased files Ikke last ned filer som er slettet av bruker p nytt Make an index Opprett en forside Make a word database Opprett en ord-database Log files Loggfiler DOS names (8+3) DOS-filnavn (8+3) ISO9660 names (CDROM) ISO9660-filnavn (CD-ROM) No error pages Ingen feilsider Primary Scan Rule Primr skeregel Travel mode Skemetode Global travel mode Global reisemetode These options should be modified only exceptionally Disse innstillingene br bare endres hvis noe ikke virker, og kun av eksperter :) Activate Debugging Mode (winhttrack.log) Aktiver feilsking (winhttrack.log) Rewrite links: internal / external Skriv linker om igjen: internt / eksternt Flow control Flow-kontroll Limits Begrensninger Identity Identitet HTML footer HTML-fotnote N# connections Antall forbindelser Abandon host if error Forlat verten hvis det oppstr feil Minimum transfer rate (B/s) Minimum overfringshastighet (bytes per sekund) Abandon host if too slow Forlat verten hvis den er for langsom Configure Konfigurer Use proxy for ftp transfers Bruk proxy til FTP-overfringer TimeOut(s) Time-out(s) Persistent connections (Keep-Alive) Reduce connection time and type lookup time using persistent connections Retries Forsk Size limit Strrelsesbegrensning Max size of any HTML file (B) Maks. strrelse p hver HTML-fil (bytes) Max size of any non-HTML file Maks. strrelse p hver ikke-HTML-fil Max site size Maksimum websidestrrelse Max time Maksimum tid Save prefs Lagre innstillinger Max transfer rate Maksimum overfringshastighet Follow robots.txt Flg reglene i robots.txt No external pages Ingen eksterne websider Do not purge old files Ikke slett gamle filer Accept cookies Aksepter informasjonskapsler (cookies) Check document type Sjekk dokumenttype Parse java files Overfr java-filer Store ALL files in cache Lagre ALLE filer i cache Tolerant requests (for servers) Aksepter foresprsler (for servere) Update hack (limit re-transfers) Oppdater hack (begrens gjen-overfringer) URL hacks (join similar URLs) Force old HTTP/1.0 requests (no 1.1) Gjennomtving gamle HTTP/1.0-foresprsler (ikke 1.1) Max connections / seconds Maksimum antall forbindelser / sekunder Maximum number of links Maksimum antall linker Pause after downloading.. Pause etter nedlastning... Hide passwords Skjul passord Hide query strings Skjul foresprsels-strenger Links Linker Build Struktur Experts Only Kun for eksperter Flow Control Flow-kontroll Limits Begrensninger Browser ID Nettleser-ID Scan Rules Skeregler Spider Webrobot Log, Index, Cache Logg, forside, cache Proxy Proxy MIME Types Do you really want to quit WinHTTrack Website Copier? Vil du virkelig avslutte WinHTTrack Website Copier? Do not connect to a provider (already connected) Ikke opprett tilkobling til leverandr (er allerede tilkoblet) Do not use remote access connection Ikke bruk fjernoppringning Schedule the mirroring operation Planlegg kopieringen Quit WinHTTrack Website Copier Avslutt WinHTTrack Website Copier Back to starting page Tilbake til startside Click to start! Klikk for starte! No saved password for this connection! Ingen lagrede passord for denne tilkoblingen! Can not get remote connection settings Kan ikke lese oppringningsinnstillinger Select a connection provider Velg en internettleverandr Start Start Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. Vennligst endre tilkoblingsinnstillinger hvis det er ndvendig,\nog klikk p FULLFR for begynne kopieringsprosessen. Save settings only, do not launch download now. Bare lagre innstillingene, ikke begynn kopieringen. On hold Pause Transfer scheduled for: (hh/mm/ss) Kopiering planlagt p tidspunkt: (hh/mm/ss) Start Start Connect to provider (RAS) Koble til leverandr (RAS) Connect to this provider Koble til denne leverandren Disconnect when finished Koble fra nr fullfrt Disconnect modem on completion Koble fra modem nr fullfrt \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n(Vennligst fortell oss om feil eller problemer med programmet)\r\n\r\nUtvikling (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche og andre bidragsytere\r\n\r\nNorwegian translation:\r\nTobias "Spug" Langhoff ( spug_enigma@hotmail.com ) About WinHTTrack Website Copier Om WinHTTrack Website Copier Please visit our Web page Vennligst besk vr internettside Wizard query Guide-sprsml Your answer: Ditt svar: Link detected.. Link oppdaget... Choose a rule Velg en regel Ignore this link Ignorer denne linken Ignore directory Ignorer denne mappen Ignore domain Ignorer dette domenet Catch this page only Kopier bare denne siden Mirror site Kopier side Mirror domain Kopier domene Ignore all Ignorer alle Wizard query Guide-sprsml NO NEI File Fil Options Innstillinger Log Logg Window Vindu Help Hjelp Pause transfer Pause kopiering Exit Avslutt Modify options Endre innstillinger View log Vis logg View error log Vis feillogg View file transfers Vis filoverfringer Hide Minimer About WinHTTrack Website Copier Om WinHTTrack Website Copier Check program updates... Se etter programoppdateringer (krever internett-tilkobling)... &Toolbar &Verktylinje &Status Bar &Statuslinje S&plit &Del File Fil Preferences Innstillinger Mirror Kopier webside Log Logg Window Vindu Help Hjelp Exit Avslutt Load default options pne standardinnstillinger Save default options Lagre standardinnstillinger Reset to default options Tilbakestill til standardinnstillinger Load options... pne innstillinger... Save options as... Lagre innstillinger som... Language preference... Sprk... Contents... Hjelp (engelsk)... About WinHTTrack... Om WinHTTrack... New project\tCtrl+N &Nytt prosjekt\tCtrl+N &Open...\tCtrl+O &pne...\tCtrl+O &Save\tCtrl+S La&gre\tCtrl+S Save &As... Lagre &som... &Delete... Sl&ett... &Browse sites... Forhndsvis webside... User-defined structure Brukerdefinert struktur %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\tFilnavn uten filtype (f.eks bilde)\r\n%N\tFilnavn MED filtype (f.eks bilde.gif)\r\n%t\tBare filtype (f.eks gif)\r\n%p\tBane [uten slutt-/] (f.eks /bilder)\r\n%h\tVertsnavn (f.eks www.someweb.com)\r\n%M\tMD5-URL (128-biters, 32 ASCII-bytes)\r\n%Q\tMD5-foresprsels-streng (128-biters, 32 ASCII-bytes(\r\n%q\tKort MD5-foresprsels-streng (16-biters, 4 ASCII-bytes)\r\n\r\n%s?\tKort navn (f.eks %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Eksempel:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\bilder\\bilde.gif Proxy settings Proxyinnstillinger Proxy address: Proxyadresse: Proxy port: Proxyport: Authentication (only if needed) Identifikasjon (hvis ndvendig) Login Brukernavn Password Passord Enter proxy address here Skriv inn proxyadresse her Enter proxy port here Skriv inn proxyport her Enter proxy login Skriv inn proxybrukernavn Enter proxy password Skriv inn proxypassord Enter project name here Skriv inn prosjektnavn her Enter saving path here Skriv inn banen der filene skal lagres Select existing project to update Velg eksisterende prosjekt som skal oppdateres Click here to select path Klikk her for velge bane Select or create a new category name, to sort your mirrors in categories HTTrack Project Wizard... HTTrack prosjektguide... New project name: Nytt prosjektnavn: Existing project name: Eksisterende prosjektnavn: Project name: Prosjektnavn: Base path: Lagringsbane: Project category: C:\\My Web Sites C:\\Mine websider Type a new project name, \r\nor select existing project to update/resume Skriv inn et nytt prosjektnavn, \r\neller velg et eksisterende prosjekt du vil oppdatere/fortsette p New project Nytt prosjekt Insert URL Skriv inn URL URL: URL: Authentication (only if needed) Godkjennelse (bare hvis det trengs) Login Brukernavn Password Passord Forms or complex links: For skjemaer eller komplekse linker: Capture URL... 'Fang' URL... Enter URL address(es) here Skriv inn URL-adresse(r) her Enter site login Skriv inn websidens brukernavn Enter site password Skriv inn websidens passord Use this capture tool for links that can only be accessed through forms or javascript code Bruk dette verktyet for 'fange' linker som bare kan ns via skjemaer eller JavaScript-koder Choose language according to preference Velg sprket du vil bruke Catch URL! 'Fang' URL! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. Vennligst sett nettleserens midlertidige proxy-innstillinger til flgende verdi (kopier/lim inn proxy-adresse og port).\nKlikk s p OK-knappen i nettleseren din, eller klikk p linken du vil 'fange'. This will send the desired link from your browser to WinHTTrack. Dette vil sende linken fra nettleseren din til WinHTTrack. ABORT AVBRYT Copy/Paste the temporary proxy parameters here Kopier/lim inn de midlertidige proxy-innstillingene her Cancel Avbryt Unable to find Help files! Finner ikke hjelpefiler! Unable to save parameters! Kan ikke lagre parameterne! Please drag only one folder at a time Bare dra n mappe om gangen! Please drag only folders, not files Bare dra mapper, ikke filer! Please drag folders only Bare dra mapper! Select user-defined structure? Velg bruker-definert struktur? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! Pass p at den brukerdefinerte strengen stemmer,\nellers vil filnavnene vre ugyldige! Do you really want to use a user-defined structure? Vil du bruke en brukerdefinert struktur? Too manu URLs, cannot handle so many links!! For mange URLer, kan ikke hndtere s mange! Not enough memory, fatal internal error.. Ikke nok minne, fatal intern feil... Unknown operation! Ukjent kommando! Add this URL?\r\n Legg til denne URLen?\r\n Warning: main process is still not responding, cannot add URL(s).. Advarsel: hovedprosessen svarer fremdeles ikke, URLen(e) kan ikke legges til... Type/MIME associations Type/MIME-tilknytninger File types: Filtyper: MIME identity: MIME-identitet: Select or modify your file type(s) here Velg eller endre filtypen(e) dine her Select or modify your MIME type(s) here Velg eller endre MIME-typen(e) dine her Go up G opp Go down G ned File download information Nedlastningsinformasjon om fil Freeze Window Frys vinduet More information: Mer informasjon: Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download Velkommen til WinHTTrack Website Copier!\n\nVennligst klikk p NESTE-knappen for \n\n- starte et nytt prosjekt\n- eller fortsette en tidligere avbrutt kopiering File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS Filnavn med etternavn:\nFilnavn som inneholder:\nDette filnavnet:\nMappenavn som inneholder:\nDette mappenavnet:\nLinker i dette domenet:\nLinker i domener som inneholder:\nLinker fra denne verten:\nLinker som inneholder:\nDenne linken:\nALLE LINKER Show all\nHide debug\nHide infos\nHide debug and infos Vis alle\nSkjul filsking\nSkjul informasjon\nSkjul filsking og informasjon Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. Sidestruktur (standard)\nHTML i web/, bilder/andre filer i web/bilder/\nHTML i web/HTML, bilder/andre i web/bilder\nHTML i web/, bilder/andre i web/\nHTML i web/, bilder/andre i web/xxx, hvor xxx er filtypen\nHTML i web/HTML, bilder/andre i web/xxx\nSidestruktur, uten www.domene.xxx/\nHTML i side_navn/, bilder/andre filer i side_navn/bilder/\nHTML i side_navn/HTML, bilder/andre i side_navn/bilder\nHTML i side_navn/, bilder/andre i side_navn/\nHTML i side_navn/, bilder/andre i side_navn/xxx\nHTML i side_navn/HTML, bilder/andre i side_navn/xxx\mAlle filer p nettet/, med tilfeldige navn (gadget !)\nAlle filer i side_navn/, med tilfeldige navn (gadget !)\nBruker-definert struktur... Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first Bare sk\nLagre HTML-filer\nLagre ikke-HTML-filer\nLagre alle filer (standard)\nLagre HTML-filer frst Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down Bli i samme mappe\nKan g ned (standard)\nKan g opp\nKan g bde opp og ned Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web Bli p samme adresse (standard)\nBli p samme domene\nBli p samme toppniv-domene\nG hvor som helst p internett Never\nIf unknown (except /)\nIf unknown Aldri\nHvis ukjent (bortsett fra /)\nHvis ukjent no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules ingen robots.txt-regler\nrobots.txt bortsett fra guide\nflg robots.txt-regler normal\nextended\ndebug normal\nutvidet\nfeilsk Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download Last ned webside(r)\nLast ned webside(r) (spr meg)\nHent individuelle filer\nLast ned alle sidene (multiple mirror)\nTest linkene p sidene (bookmark test)\n* Fortsett avbrutt kopiering\n* Oppdater eksisterende kopi Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL Relativ URL / Fullstendig URL (standard)\nFullstendig URL / Fullstendig URL\nFullstendig URL / Fullstendig URL\nOriginal URL / Original URL Open Source offline browser Website Copier/Offline Browser. Copy remote websites to your computer. Free. httrack, winhttrack, webhttrack, offline browser URL list (.txt) Previous Next URLs Warning Your browser does not currently support javascript. For better results, please use a javascript-aware browser. Thank you You can now close this window Server terminated A fatal error has occurred during this mirror httrack-3.49.5/lang/Nederlands.txt0000644000175000017500000010621114360553245013746 00000000000000LANGUAGE_NAME Nederlands LANGUAGE_FILE Nederlands LANGUAGE_ISO nl LANGUAGE_AUTHOR Rudi Ferrari (Wyando at netcologne.de) \r\n LANGUAGE_CHARSET ISO-8859-1 LANGUAGE_WINDOWSID Dutch (Netherlands) OK OK Cancel Annuleren Exit Beindigen Close Sluiten Cancel changes Veranderingen annuleren Click to confirm Veranderingen bevestigen Click to get help! Klik hier voor help Click to return to previous screen Klik voor vorig scherm Click to go to next screen Klik voor volgend scherm Hide password Verberg wachtwoord Save project Project wegschrijven Close current project? Actueel project sluiten? Delete this project? Dit project wissen? Delete empty project %s? Leeg project %s wissen? Action not yet implemented Functie nog niet ter beschikking. Error deleting this project Fout bij het wissen van dit project. Select a rule for the filter Kies een regel voor de filter Enter keywords for the filter Geef hier de sleutelwoorden voor deze filter Cancel Annuleren Add this rule Deze regel toevoegen Please enter one or several keyword(s) for the rule En of meerdere sleutelwoord(en) voor deze regel in te geven Add Scan Rule Filter toevoegen Criterion Kies een regel: String Geef een sleutelwoord: Add Toevoegen Scan Rules Filter Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Je kunt verschillende URLs of links door gebruik van jokers uitsluiten of aanvaarden\nJe kunt ofwel een spatie tussen de filters gebruiken\n\nVoorbeeld: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Exclude links Links uitsluiten: Include link(s) Links aanvaarden Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) Raad: Indien je alle gif bestanden van een site wilt aanvaarden, probeer iets in de aard van +www.someweb.com/*.gif \n(+*.gif / -*.gif zal ALLE gifs aanvaarden/uitsluiten van ALLE sites) Save prefs Instellingen wegschrijven Matching links will be excluded: Links volgens deze regel worden uitgesloten: Matching links will be included: Links volgens deze regel worden aanvaard: Example: Voorbeeld: gif\r\nWill match all GIF files gif\r\nZal alle gif (of GIF) bestanden vinden blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' blue\r\nZal alle bestanden met blue vinden, zoals 'bluesky-small.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' bigfile.mov\r\nZal het bestand 'bigfile.mov' vinden, maar niet 'bigfile2.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\nZal links vinden met directories die 'cgi' bevatten, zoals /cgi-bin/somecgi.cgi cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\nZal links vinden met directory naam 'cgi-bin' (maar niet bevoorbeeld: cgi-bin-2) someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb.com\r\nZal alle links vinden zoals www.someweb.com, private.someweb.com etc. someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. someweb\r\nZal alle links vinden zoals www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.someweb.com\r\nZal alle links vinden zoals www.someweb.com/... (maar geen links zoals private.someweb.com/..) someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. someweb\r\nZal alle links vinden zoals www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/someweb.html\r\nZal enkel de link www.test.com/test/someweb.html vinden. Merk op dat je zowel het adres (www.xxx.yyy) alsook de pad (/test/someweb.html) All links will match Alle links zullen uitgesloten/aanvaard worden Add exclusion filter Toevoegen van een uitsluiten-filter Add inclusion filter Toevoegen van een aanvaarden-filter Existing filters Bijkomende filters Cancel changes Veranderingen annuleren Save current preferences as default values Instellingen als standaard wegschrijven Click to confirm Klik voor bevestiging No log files in %s! Geen protocolbestanden in %s! No 'index.html' file in %s! Geen index.html in %s! Click to quit WinHTTrack Website Copier Klik om WinHTTrack Website Copier te beindigen View log files Toon protocolbestanden Browse HTML start page Toon de html startpagina End of mirror Einde van de spiegeling View log files Toon protocolbestand Browse Mirrored Website Toon web New project... Nieuw project... View error and warning reports Toon fouten en mededelingen View report Toon protocolverslag Close the log file window Sluit het protocolvenster Info type: Type van informatie: Errors Fouten Infos Informaties Find Zoek Find a word Zoek een woord Info log file Info-protocolbestand Warning/Errors log file Waarschuwingen/Fouten-protocolbestand Unable to initialize the OLE system Onmogelijk het OLE systeem te initialiseren WinHTTrack could not find any interrupted download file cache in the specified folder! Er geen cache in de aangegeven directory\nWinHTTrack kan geen afgebroken spiegelingen vinden! Could not connect to provider Geen verbindung met de provider receive ontvangen request verzoek connect verbinden search zoeken ready klaar error fout Receiving files.. Ontvang bestanden. Parsing HTML file.. Doorlopen van het HTML bestand... Purging files.. Verwijder bestanden... Loading cache in progress.. Cache wordt geladen... Parsing HTML file (testing links).. Doorlopen van het HTML bestand (test links)... Pause - Toggle [Mirror]/[Pause download] to resume operation Gepauzeerd (Kies [Spiegeling]/[Pauzeer transfer] om verder te gaan) Finishing pending transfers - Select [Cancel] to stop now! Beindig lopende transfers - Kies [Cancel] om direkt te stoppen! scanning scanning Waiting for scheduled time.. Wacht op voorgegeven uur om te starten Connecting to provider Maak verbinding met de provider [%d seconds] to go before start of operation Spiegeling wachtend [%d seconden] Site mirroring in progress [%s, %s bytes] Spiegeling is bezig... [%s, %s bytes] Site mirroring finished! Spiegeling beindigd! A problem occurred during the mirroring operation\n Een probleem is opgetreden tijdens de spiegeling\n \nDuring:\n \r\n\nTijdens:\n\r\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! Indien noodzakelijk, zie in het protocolbestand.\n\nKlik OK om WinHTTrack Website Copier te beindigen.\n\nAlvast bedankt voor het gebruik van WinHTTrack! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! De spiegeling is uitgevoerd.\nKlik OK om WinHTTrack te beindigen.\nIndien nodig, zie protocolbestand(en) om zeker te gaan dat alles OK is\n\nAlvast bedankt voor het gebruik van WinHTTrack! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * SPIEGELING AFGEBROKEN! * *\r\nDe aktuele tijdelijke cache is noodzakelijk voor gelijkwelke update operatie en bevat enkel data gedownload gedurende de zoeven afgebroken sessie.\r\nDe eerste cache kan juistere informaties bevatten; indien je deze informatie niet wenst te verliezen, dan moet je deze restoren and de aktuele cache wissen.\r\n[Opmerking: Dit is het eenvoudigst door het wissen van de hts-cache/new.* bestanden]\r\n\r\nDenk je dat de eerste cache juistere informaties bevat, en wil je deze restoren? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * FOUT MET DE SPIEGELING * *\r\nHTTrack heeft vastgesteld dat de aktuele spiegeling leeg is. Indien het een update was, is de vorige copie terug actueel.\r\nReden: de eerste pagina(s) konden ofwel niet gevonden worden, of er was een probleem met de connectie.\r\n=> Verzeker je ervan, dat de website nog steeds bestaat en/of je proxy settings correct zijn! <= \n\nTip: Click [View log file] to see warning or error messages :\r\n\n\nTip: Klik [Toon protocolbestand] voor de fouten en mededelingen\r\n Error deleting a hts-cache/new.* file, please do it manually Het wissen van hts-cache/new.* bestanden is niet gelukt, gelieve dit manueel te doen Do you really want to quit WinHTTrack Website Copier? Wil je werkelijk WinHTTrack Website Copier beindigen? - Mirroring Mode -\n\nEnter address(es) in URL box - Spiegelmodus -\n\nVul de adressen in het URL venster in - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - Spielgelmodus met navraag -\n\nVul de adressen in het URL venster in - File Download Mode -\n\nEnter file address(es) in URL box - Haal-bestand-modus -\n\nVul de adressen in het URL venster in - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - Test-links-modus -\n\nVul de adressen van de paginas met links in het URL venster in - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Herzien/voortzetten van de spiegelmodus -\n\nKontroleer de adressen in het URL venster. Daarna klik 'VERDER' en konrtrolleer de parameters. - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Voortzetten van de spiegelmodus -\n\nKontroleer de adressen in het URL venster. Daarna klik 'VERDER' en konrtrolleer de parameters. Log files Path Protocoldirectory Path Pad - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror Spiegellijst-modus, vul de adressen van de paginas met links om te spiegelen in het URL venster in New project / Import? Nieuw project / import? Choose criterion Kies een actie Maximum link scanning depth Maximale linkdiepte om te scannen Enter address(es) here Vul hier de adressen in Define additional filtering rules Definier bijkomende filters Proxy Name (if needed) Proxy indien nodig Proxy Port Proxy poort Define proxy settings Definier proxy instellingen Use standard HTTP proxy as FTP proxy Gebruik de standaard HTTP proxy voor FTP proxy Path Pad Select Path Kies een pad Path Pad Select Path Kies een pad Quit WinHTTrack Website Copier WinHTTrack Website Copier beindigen About WinHTTrack Info's over WinHTTrack Save current preferences as default values Schrijf voorkeur weg als standaard waarden. Click to continue Klik om verder te gaan Click to define options Klik om instellingen te definieren. Click to add a URL Klik om een URL toetevoegen Load URL(s) from text file Lees URL(s) vanaf een tekstbestand WinHTTrack preferences (*.opt)|*.opt|| WinHTTrack voorkeursinstellingen (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| Tekstbestand met de lijst van adressen (*.txt)|*.txt|| File not found! Bestand niet gevonden! Do you really want to change the project name/path? Will je werkelijk de projectnaam/pad veranderen? Load user-default options? Standaard instellingen van de gebruiker laden? Save user-default options? Standaard instellingen van de gebruiker wegschrijven? Reset all default options? Alle standaard instellingen wissen? Welcome to WinHTTrack! Hartelijk welkom bij WinHTTrack Website Copier! Action: Acties: Max Depth Maximale diepte: Maximum external depth: Maximum externe diepte: Filters (refuse/accept links) : Filters (links uitsluiten/aanvaarden): Paths Paths Save prefs Instellingen wegschrijven Define.. Definiren... Set options.. Instellingen definiren... Preferences and mirror options: Voorkeur en instellingen van de spiegelingen: Project name Projectnaam Add a URL... Toevoegen van een URL... Web Addresses: (URL) Webadres: (URL) Stop WinHTTrack? Stoppen van WinHTTrack? No log files in %s! Geen protocolbestanden in %s! Pause Download? Transfer pauzeren? Stop the mirroring operation Stop de spiegeling. Minimize to System Tray Verberg dit venster onder de systeembalk Click to skip a link or stop parsing Klik om een link over te slaan of om de doorloop te onderbreken Click to skip a link Klik om een link over te slaan Bytes saved Bytes weggeschreven: Links scanned Links doorlopen: Time: Tijd: Connections: Verbindingen: Running: Lopende: Hide Verbergen Transfer rate Transfer snelheid: SKIP OVERSLAAN Information Informaties Files written: Geschreven bestanden: Files updated: Bijgewerkte bestanden: Errors: Fouten: In progress: Bezig: Follow external links Haal bestanden ook uit externe links Test all links in pages Test alle links in de paginas Try to ferret out all links Probeer alle links te vinden Download HTML files first (faster) Eerst HTML-bestanden downloaden (sneller) Choose local site structure Kies een struktuur voor de lokale bestanden Set user-defined structure on disk Definier de struktuur van een site op disk Use a cache for updates and retries Gebruik een cache voor updates en herhalingen Do not update zero size or user-erased files Geen bestanden herladen indien deze nul bytes groot of door de gebruiker gewist zijn Create a Start Page Startpagina aanmaken Create a word database of all html pages Kreer een woorden-gegevensbank van alle HTML paginas Create error logging and report files Aanmaken van Protokolbestanden voor fouten en mededelingen. Generate DOS 8-3 filenames ONLY Genereer enkel 8+3 bestandsnamen Generate ISO9660 filenames ONLY for CDROM medias Genereer ISO9660 bestandsnamen ENKEL voor CDROMs Do not create HTML error pages Schrijf geen html foutenpaginas Select file types to be saved to disk Kies de bestandtypes om weg te schrijven Select parsing direction Kies de doorlooprichting van de spiegeling Select global parsing direction Kies de globale doorlooprichting in de site Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) Instellingen voor het herschrijven van URLs voor interne (gedownloaded) en externe (niet gedownloaded) links Max simultaneous connections Maximum aantal connecties File timeout Maximum wachttijd voor een bestand Cancel all links from host if timeout occurs Annuleer alle links van een host bij een timeout Minimum admissible transfer rate Minimale transfer snelheid Cancel all links from host if too slow Annuleer alle links van een te langsame host Maximum number of retries on non-fatal errors Maximum aantal herhalingen indien een niet fatale fout gebeurt Maximum size for any single HTML file Maximale grootte voor een html pagina Maximum size for any single non-HTML file Maximale grootte voor een bestand Maximum amount of bytes to retrieve from the Web Maximaal aantal bytes voor de spiegeling Make a pause after downloading this amount of bytes Pauzeer na download van dit aantal bytes Maximum duration time for the mirroring operation Maximale tijd voor de spiegeling Maximum transfer rate Maximale transfer snelheid Maximum connections/seconds (avoid server overload) Maximale verbindingen/seconde (vermijd overbelasting van de server) Maximum number of links that can be tested (not saved!) Maximum aantal links dat kan getest worden (niet gesaved!) Browser identity Browser identiteit Comment to be placed in each HTML file Voetnoot in elk HTML bestand Back to starting page Terug naar de startpagina Save current preferences as default values Instellingen als standaard wegschrijven Click to continue Klick om verder te gaan Click to cancel changes Klik om veranderingen te annuleren Follow local robots rules on sites Volg de lokale robotregels van de site Links to non-localised external pages will produce error pages Externe paginas (niet opgenomen) linken naar foutenpaginas Do not erase obsolete files after update Geen oude bestanden wissen na update Accept cookies? Aangeboden cookies aanvaarden? Check document type when unknown? Onbekende document types testen? Parse java applets to retrieve included files that must be downloaded? Java applets doorzoeken naar inbegrepen bestanden Store all files in cache instead of HTML only Alle bestanden in cache wegschrijven in plaats van enkel de HTML bestanden Log file type (if generated) Type protocolbestand indien gegenereerd Maximum mirroring depth from root address Maximum diepte van de spiegeling vanaf het eerste adres Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) Maximum spiegelingdiepte voor externe/verboden adressen (0 is geen [default]) Create a debugging file Debug bestand aanmaken Use non-standard requests to get round some server bugs Probeer somige server bugs te vermijden door gebruik van niet gestandaardiseerde aanvragen Use old HTTP/1.0 requests (limits engine power!) Gebruik de oude HTTP/1.0 aanvragen (beperkt de zoekfunctie) Attempt to limit retransfers through several tricks (file size test..) Probeer, met verschillende trukjes, het aantal 're-transfers' te beperken (test grootte van het bestand...) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Write external links without login/password Schrijf externe links zonder login/wachtwoord Write internal links without query string Schrijf interne links zonder zoekaanvraag Get non-HTML files related to a link, eg external .ZIP or pictures Opnemen van niet HTML-bestanden dicht bij een link (bv. .ZIP of grafieken buitenuit geplaatst) Test all links (even forbidden ones) Test alle links (ook de niet toegelatenen) Try to catch all URLs (even in unknown tags/code) Probeer alle URLs te krijgen (ook in onbekende tags/code) Get HTML files first! Haalt eerst de HTML-bestanden! Structure type (how links are saved) Struktuurtype (hoe links weggeschreven worden) Use a cache for updates Gebruik een cache voor de updates Do not re-download locally erased files Lokaal gewiste bestanden niet nogmaals laden Make an index Maak een index Make a word database Kreer een woorden-gegevensbank Log files Protocolbestanden DOS names (8+3) DOS namen (8+3) ISO9660 names (CDROM) ISO9660 namen (CDROM) No error pages Geen fouten paginas Primary Scan Rule Hoofdfilter Travel mode Doorloopmodus Global travel mode Globale doorloopmodus These options should be modified only exceptionally Normaalgezien moeten deze instellingen niet aangepast worden Activate Debugging Mode (winhttrack.log) Aktiveer de debug modus (winhttrack.log) Rewrite links: internal / external Herschrijf links: intern / extern Flow control Stroom controle Limits Begrenzingen Identity Identiteit HTML footer HTML voetnota N# connections N# verbindingen Abandon host if error Verbinding afbreken indien fout Minimum transfer rate (B/s) Minimum transfer snelheid (B/s) Abandon host if too slow Verbinding afbreken indien te langzaam Configure Instellen Use proxy for ftp transfers Gebruik de proxy voor ftp transfers TimeOut(s) TimeOut(s) Persistent connections (Keep-Alive) Aanhoudende verbindingen (Keep-Alive) Reduce connection time and type lookup time using persistent connections Verbindingstijd en nakijktijd verminderen door konstante verbindung met de server Retries Herhalingen Size limit Berperking in grootte Max size of any HTML file (B) Maimale HTML grootte Max size of any non-HTML file Andere maximale grootte Max site size Maximale site grootte Max time Maximale tijd Save prefs Instellingen wegschrijven Max transfer rate Maximale transfer snelheid Follow robots.txt Volg de regels in robot.txt No external pages Geen externe pagina's Do not purge old files Geen oude pagina's wissen Accept cookies Cookies aanvaarden Check document type Kontroleer document type Parse java files Analiseren van JAVA bestanden Store ALL files in cache Alle bestanden in cache wegschrijven Tolerant requests (for servers) Tolerante aanvragen (voor servers) Update hack (limit re-transfers) Update hack (limiteert de re-transfers) URL hacks (join similar URLs) Force old HTTP/1.0 requests (no 1.1) Gebruik oude HTTP/1.0 verzoeken (geen 1.0) Max connections / seconds Max verbindingen / seconden Maximum number of links Maximum aantal links Pause after downloading.. Pauze na download... Hide passwords Wachtwoorden verbergen Hide query strings Verberg zoekaanvragen Links Links Build Struktuur Experts Only Expert Flow Control Stroomcontrole Limits Beperkingen Browser ID Browser ID Scan Rules Filters Spider Spider Log, Index, Cache Protocol, Index, Cache Proxy Proxy MIME Types MIME typen Do you really want to quit WinHTTrack Website Copier? Wil je werkelijk WinHTTrack Website Copier beindigen? Do not connect to a provider (already connected) Geen verbinding met een provider (reeds verbonden) Do not use remote access connection Geen gebruik van een remote verbinding Schedule the mirroring operation Programeer de spiegeling Quit WinHTTrack Website Copier Beeindige WinHTTrack Website Copier Back to starting page Terug naar startpagina Click to start! Klik om te starten! No saved password for this connection! Geen weggeschreven wachtwoord voor deze verbinding Can not get remote connection settings Krijg geen instelling van der remote verbinding Select a connection provider Kies hier een provider voor de verbinding Start Start Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. Je kan de spiegeling starten, als je de FINISH knop klikt of definier meer instellingen voor de verbinding Save settings only, do not launch download now. Enkel de instellingen wegschrijven, download nu niet lanceren On hold Vertragen Transfer scheduled for: (hh/mm/ss) Wachtend tot: (hh/mm/ss) Start START! Connect to provider (RAS) Verbind met de provider (RAS) Connect to this provider Verbind met deze provider Disconnect when finished Indien gedaan verbinding verbreken Disconnect modem on completion Indien gedaan modemverbinding verbreken \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n(Ons fouten en problemen mede te delen)\r\n\r\nOntwikkeling:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for Dutch translations to:\r\nRudi Ferrari (Wyando@netcologne.de) About WinHTTrack Website Copier Over WinHTTrack Website Copier Please visit our Web page Bezoek onze webpagina Wizard query Wizard vraagstelling Your answer: Je antwoord: Link detected.. Een link werd gevonden Choose a rule Kies een regel: Ignore this link Deze link uitsluiten Ignore directory Deze directory uitsluiten Ignore domain Deze domain uitsluiten Catch this page only Haal enkel deze pagina Mirror site Site-spiegeling Mirror domain Domain-spiegeling Ignore all Sluit alles uit Wizard query Wizard vraagstelling NO NEEN File Bestand Options Instellingen Log Protocol Window Venster Help Help Pause transfer Pauzeer transfer Exit Beindigen Modify options Instellingen veranderen View log Toon protocol View error log Toon foutenprotocol View file transfers Toon transfer van de bestanden Hide Verstoppen About WinHTTrack Website Copier Over WinHTTrack Website Copier Check program updates... Verifier programma updates... &Toolbar Toolmenu &Status Bar Statusmenu S&plit Verdeel File Bestand Preferences Instellingen Mirror Spiegeling Log Protocol Window Venster Help Help Exit Beindigen Load default options Standaard opties laden Save default options Standaard opties wegschrijven Reset to default options Standaard opties wissen Load options... Opties laden Save options as... Opties wegschrijven als... Language preference... Taalopties... Contents... Inhoud... About WinHTTrack... Over WinHTTrack Website Copier... New project\tCtrl+N Nieuw project\tCtrl+N &Open...\tCtrl+O &Open...\tCtrl+O &Save\tCtrl+S Weg&Schrijven\tCtrl+S Save &As... Wegschrijven &als... &Delete... &Wissen &Browse sites... We&bpaginas aantonen... User-defined structure Struktuur door de gebruiker gedefinierd %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\tNaam van het bestand zonder extensie (bv: image)\r\n%N\tNaam van het bestand met extensie (bv: image.gif)\r\n%t\tBestandstype (bv: gif)\r\n%p\tPath [zonder / op het einde] (bv: /someimages)\r\n%h\tHost naam (ex: www.someweb.com)\r\n%M\tURL MD5 (128 bits, 32 ascii bytes)\r\n%Q\tquery string MD5 (128 bits, 32 ascii bytes)\r\n%q\tsmall query string MD5 (16 bits, 4 ascii bytes)\r\n\r\n%s?\tkorte naam versie (ex: %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Voorbeeld:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Proxy settings Proxy instellingen Proxy address: Proxy adres Proxy port: Proxy poort Authentication (only if needed) Identificatie (enkel indien nodig) Login Login Password Wachtwoord Enter proxy address here Hier een proxy adres ingeven Enter proxy port here Hier proxy poort ingeven Enter proxy login Proxy login ingeven Enter proxy password Proxy wachtwoord ingeven Enter project name here Hier de projectnaam ingeven Enter saving path here Hier een pad voor het wegschrijven van het project ingeven Select existing project to update Kies hier een bestaand project voor update Click here to select path Klik hier om een pad te kiezen Select or create a new category name, to sort your mirrors in categories HTTrack Project Wizard... HTTrack project wizard New project name: Nieuw projectnaam: Existing project name: Bestaand projectnaam: Project name: Projectnaam: Base path: Basis pad Project category: C:\\My Web Sites C:\\Mijn Web paginas Type a new project name, \r\nor select existing project to update/resume Geef een nieuw projectnaam, \r\nof kies een bestaand project voor update/voortzetting\r\n New project Nieuw project Insert URL Toevoegen van een URL URL: URL: Authentication (only if needed) Identificatie (enkel indien nodig) Login Login: Password Password: Forms or complex links: Ingaveschermen of complexe links: Capture URL... Haal URL... Enter URL address(es) here Hier URL adres ingeven Enter site login Site login ingeven Enter site password Site wachtwoord ingeven Use this capture tool for links that can only be accessed through forms or javascript code Gebruik deze tool om links te halen die enkel via ingaveschermen of javascripts te krijgen zijn Choose language according to preference Kies je taal hier Catch URL! Haal de URL! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. Tijdelijk je proxyinstellingen in de browser op volgende waarden zetten: (knip/plak proxyadres en poort).\nDan, in de browser, klik op de verzendknop van het ingavescherm, of klik op de specifieke link die je wilt halen This will send the desired link from your browser to WinHTTrack. Dit haalt de gewenste link van je browser naar HTTrack. ABORT ANNULEREN Copy/Paste the temporary proxy parameters here Knip/plak hier de tijdelijke proxy-instellingen Cancel Annuleren Unable to find Help files! Hulpbestanden kunnen niet gevonden worden! Unable to save parameters! Onmogelijk de parameterers weg te schrijven! Please drag only one folder at a time Enkel 1 directory toevoegen Please drag only folders, not files Enkel een directory toe te voegen, geen bestanden Please drag folders only Enkel een directory toe te voegen Select user-defined structure? Gebruikersdefinieerde struktuur kiezen? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! Verzeker je ervan, dat de gebruikersdefinieerde struktuur correct is.\nIndien niet, zullen de bestandsnamen verkeerd zijn.\r\n Do you really want to use a user-defined structure? Wil je werkelijk de gebruikersdefinierde struktuur kiezen? Too manu URLs, cannot handle so many links!! Veel te veel URLs, onmogelijk zoveel links te behandelen!! Not enough memory, fatal internal error.. Niet genoeg geheugen, fatale interne fout... Unknown operation! Onbekende operatie! Add this URL?\r\n Deze URL toevoegen?\r Warning: main process is still not responding, cannot add URL(s).. Waarschuwing: hoofd proces antwoord niet, kann geen URLs toevoegen Type/MIME associations Associaties type/MIME File types: Bestandtype(s): MIME identity: MIME identiteit Select or modify your file type(s) here Kies of verander je bestandtype(s) hier Select or modify your MIME type(s) here Kies of verander je MIME type(s) hier Go up Omhoog Go down Omlaag File download information Informaties over de bestanden gedownload Freeze Window Venster invriezen More information: Bijkomende informaties Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download Welkom bij WinHTTrack Website Copier!\n\nGelieve NEXT te klikken om\n\n- een nieuw project te starten\n\n- of vervoledig een gedeeltelijke download File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS Bestandsnamen met extentie:\nBestandsnamen bevattend:\nDit bestandsnaam:\nDirectory-namen bevattend:\nDeze directory:\nLinks op dit domein:\nLinks op domein:\nLinks van deze host:\nLinks bevattend:\nDeze link:\nALLE LINKS Show all\nHide debug\nHide infos\nHide debug and infos Toon alles\nVerstop debug\nverstop informaties\nVerstop debug en informaties Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. Site-struktuur (default)\nHtml in web/, images/andere bestanden in web/images/\nHtml in web/html, images/andere in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, waarbij xxx de extentie is\nHtml in web/html, images/andere in web/xxx\nSite-struktuur, zonder www.domain.xxx/\nHtml in site_naam/, images/andere files in site_naam/images/\nHtml in site_naam/html, images/andere in site_naam/images\nHtml in site_naam, images/andere in site_name/\nHtml in site_naam/, images/andere in site_naam/xxx\nHtml in site_naam/html, images/andere in site_naam/xxx\nAlle bestenden in web/, met toevallige namen\nAlle bestanden in site_naam/, met toevallige namen\nGebruikers-gedefinierde struktuur... Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first Enkel scannen\nHtml-bestanden wegschrijven\nNiet-Html-bestanden wegschrijven\nAlle bestanden wegschrijven (default)\nEerst Html-bestanden wegschrijven Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down In dezelfde directory blijven\nKan dieper gaan (default)\nCan omhoog gaan\nKan zowel dieper als omhoog gaan Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web Op hetzelfde adres blijven (default)\nOp dezelfde domain blijven\nOp dezelfde top level domain blijven\nNaar overal in de web gaan Never\nIf unknown (except /)\nIf unknown Nooit\nIndien onbekend (uitgezonderd /)\nIndien onbekend no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules Geen robots.txt regels\nrobots.txt uitgezonderd wizard\nvolg robots.txt regels normal\nextended\ndebug normaal\nuitgebreid\ndebug Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download Download web site(s)\nDownload web site(s) + vragen\nHaal losse bestanden\nDownload alle sites in paginas (veelvuldige spiegeling)\nTest links in paginas (bookmark test)\n* onderbroken download verder doen\n* update bestaande download Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL Relative URI / Absolute URL (default)\n Absolute URL / Absolute URL\nAbsolute URI / Absolute URL\nURL van oorsprong / URL van oorsprong Open Source offline browser Open Source offline browser Website Copier/Offline Browser. Copy remote websites to your computer. Free. Website Copier/Offline Browser. Kopieer websites op je computer. Gratis. httrack, winhttrack, webhttrack, offline browser httrack, winhttrack, webhttrack, offline browser URL list (.txt) URL lijst (.txt) Previous Vorige Next Volgende URLs URLs Warning Opgelet Your browser does not currently support javascript. For better results, please use a javascript-aware browser. Je browser support momenteel geen javascript. Voor betere resultaten, gelieve een browser met javascript mogelijkheid gebruiken. Thank you Dankjewel You can now close this window Je kunt dit verster nu sluiten Server terminated Server beeindigd A fatal error has occurred during this mirror Een fatale fout is opgetreden tijdens deze spiegeling httrack-3.49.5/lang/Magyar.txt0000644000175000017500000010715114360553245013113 00000000000000LANGUAGE_NAME Magyar LANGUAGE_FILE Magyar LANGUAGE_ISO hu LANGUAGE_AUTHOR Jozsef Tamas Herczeg (hdodi at freemail.hu) \r\n LANGUAGE_CHARSET ISO-8859-2 LANGUAGE_WINDOWSID Hungarian OK OK Cancel Mgse Exit Kilps Close Bezrs Cancel changes Trli a mdostsokat Click to confirm Kattintson r a megerstshez Click to get help! Kattintson r segtsgrt! Click to return to previous screen Az elz kpernyhz visz vissza Click to go to next screen A kvetkez kpernyre visz Hide password Jelsz titkostsa Save project Projekt mentse Close current project? Bezrja az aktulis projektet? Delete this project? Trli ezt a projektet? Delete empty project %s? Trli a(z) %s res projektet? Action not yet implemented A mvelet mg nem hasznlhat Error deleting this project Hiba a projekt trlsekor Select a rule for the filter Jelljn ki szablyt a szrhz Enter keywords for the filter Itt rja be a szr kulcsszavait Cancel Mgse Add this rule Hozzadja ezt a szablyt Please enter one or several keyword(s) for the rule rjon be egy vagy tbb kulcsszt a szablyhoz Add Scan Rule Szr hozzadsa Criterion Vlasszon szablyt String Kulcssz bersa Add Hozzads Scan Rules Szrk Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Karakterhelyettestk hasznlatval kizrhat vagy elfogadhat URL-eket vagy hivatkozsokat.\nTegyen szkzt a szrk kz.\n\nPldul: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Exclude links Hivatkozs kizrsa Include link(s) Hivatkozs elfogadsa Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) Tipp: Ha a webrl minden gif fjlt fogadni akar, hasznljon ilyet +www.someweb.com/*.gif. \n(+*.gif / -*.gif elfogad/letilt MINDEN gifet MINDEN webhelyen) Save prefs Belltsok mentse Matching links will be excluded: A megegyez hivatkozsok kizrsra kerlnek: Matching links will be included: A megegyez hivatkozsokat tartalmazni fogja: Example: Pldul: gif\r\nWill match all GIF files gif\r\nKiszr minden GIF fjlt blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' blue\r\nMegkeres minden olyan fjlt, ami tartalmazza a 'blue' szveget, azaz 'bluesky-small.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' bigfile.mov\r\nKiszri a 'bigfile.mov' fjlt, viszont a 'bigfile2.mov' fjlt nem cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\nMegkeres minden olyan mappanv hivatkozst, ami tartalmazza a 'cgi' szveget, azaz /cgi-bin/somecgi.cgi cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\nMegkeres minden olyan mappanv hivatkozst, ami tartalmazza a teljes 'cgi-bin' szveget (de a cgi-bin-2 mr nem) someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb.com\r\nMegkeres minden olyan hivatkozst, ami tartalmazza a www.someweb.com, private.someweb.com stb. szveget someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. someweb\r\nMegkeres minden olyan hivatkozst, ami tartalmazza a www.someweb.com, www.someweb.edu, private.someweb.otherweb.com stb. mappanv szveget. www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.someweb.com\r\nMegkeres minden olyan hivatkozst, ami tartalmazza a teljes 'www.someweb.com' szveget (de nem olyan hivatkozsokat, mint a private.someweb.com/..) someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. someweb\r\nMegkeres minden olyan hivatkozst, ami tartalmazza a www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html stb. szvegeket. www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/someweb.html\r\nCsak a www.test.com/test/someweb.html fjlt keresi meg. Jegyezze meg, hogy be kell rnia a teljes tvonalat (URL + elrsi t) All links will match Minden hivatkozst egyeztet Add exclusion filter Kizrs szr hozzadsa Add inclusion filter Belefoglals szr hozzadsa Existing filters Ltez szrk Cancel changes Trli a mdostsokat Save current preferences as default values Az aktulis belltsok mentse alaprtelmezett rtkekknt Click to confirm Nyomja meg a megerstshez No log files in %s! %s nem tartalmaz naplfjlt! No 'index.html' file in %s! %s nem tartalmaz index.html fjlt Click to quit WinHTTrack Website Copier Kattintson r a WinHTTrack webhely msolbl val kilpshez View log files Naplfjlok megjelentse Browse HTML start page HTML kezdlap bngszse End of mirror Tkrzs vge View log files Naplfjlok megtekintse Browse Mirrored Website Tkrztt weblap bngsz New project... j projekt... View error and warning reports Hiba- s figyelmeztetsi jelentsek megtekintse View report Jelents megtekintse Close the log file window Naplfjl ablaknak bezrsa Info type: Adat tpusa: Errors Hibk Infos Adatok Find Keress Find a word Sz keresse Info log file Informcis naplfjl Warning/Errors log file Figyelmeztets/Hiba naplfjl Unable to initialize the OLE system Az OLE rendszer nem inicializlhat WinHTTrack could not find any interrupted download file cache in the specified folder! A WinHTTrack nem tallt megszakadt letltsi fjl gyorsttrat a megadott mappban! Could not connect to provider Nem lehet csatlakozni a szolgltathoz receive fogads request krs connect csatlakozs search keress ready ksz error hiba Receiving files.. Fjlok fogadsa Parsing HTML file.. HTML fjl elemzse Purging files.. Fjlok kirtse Loading cache in progress.. A gyorsttr betltse folyamatban.. Parsing HTML file (testing links).. HTML fjl elemzse (hivatkozsok tesztelse) Pause - Toggle [Mirror]/[Pause download] to resume operation Sznet - Kattintson a [Tkrzs]/[Letlts szneteltetse] parancsra a mvelet folytatshoz Finishing pending transfers - Select [Cancel] to stop now! Fggben lv tvitelek befejezse - Lellts a [Mgse] gombbal! scanning vizsglat Waiting for scheduled time.. Vrakozs az temezett idpontra Connecting to provider Csatlakozs a szolgltathoz [%d seconds] to go before start of operation [%d msodperc] van htra a mvelet megkezdshez Site mirroring in progress [%s, %s bytes] A tkrzs folyamatban [%s, %s bjt] Site mirroring finished! A webhely tkrzse befejezdtt A problem occurred during the mirroring operation\n A tkrzs kzben hiba trtnt\n \nDuring:\n \nKzben:\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! \nNzze meg a naplfjlt, ha szksges.\n\nKattintson a BEFEJEZS gombra a WinHTTrack webhely msolbl val kilpshez.\n\nKsznet a WinHTTrack hasznlatrt! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! A tkrzs befejezdtt.\nKattintson az OK gombra a WinHTTrack bezrshoz.\nNzze meg a naplfjl(oka)t, ha szksges, hogy meggyzdjn rla, minden rendben van-e.\n\nKsznet a WinHTTrack hasznlatrt! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * TKRZS MEGSZAKTVA! * *\r\nA frisstshez az aktulis ideiglenes gyorsttrra van szksg, s csak az imnt megszaktott mvelettel letlttt adatokat tartalmazza.\r\nA rgi gyorsttr bizonyra tbb informcit tartalmaz; ha nem akarja elveszteni azt az informcit, vissza kell lltania s trlnie a jelenlegi gyorsttrat.\r\n[Megjegyzs: Ez knnyen elvgezhet itt a hts-cache/new fjlok* trlsvel.]\r\n\r\ngy gondolja, hogy a rgi gyorsttr teljesebb informcit tartalmazhat, s vissza kvnja lltani? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * TKRZSI HIBA! * *\r\nA HTTrack felismerte, hogy az aktulis tkrzs res. Ha frissts volt, vissza lett lltva az elz tkrzs.\r\nOk: az els oldal(ak) vagy nem tallhatk, vagy csatlakozsi problma lpett fl.\r\n=> Nzze meg, hogy a webhely ltezik-e mg, s/vagy ellenrizze a proxy belltsokat! <= \n\nTip: Click [View log file] to see warning or error messages \nTipp: Kattintson a [Naplfjl megjelentse] menpontra a figyelmeztetsek vagy hibazenetek megtekintshez Error deleting a hts-cache/new.* file, please do it manually Hiba a hts-cache/new.* fjl trlskor, vgezze el kzzel Do you really want to quit WinHTTrack Website Copier? Valban ki kvn lpni a WinHTTrack webhely msolbl? - Mirroring Mode -\n\nEnter address(es) in URL box - Tkrzs md -\n\nrja be a cm(ek)et az URL mezbe - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - Interaktv Varzsl md (krdsek) -\n\nrja be a cm(ek)et az URL mezbe - File Download Mode -\n\nEnter file address(es) in URL box - Fjl letlts md -\n\nrja be a fjl(ok) cme(i)t az URL mezbe - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - Hivatkozs tesztelsi md -\n\nrja be a tesztelend hivatkozs(oka)t tartalmaz oldal(ak) cme(i)t az URL mezbe - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Frissts md -\n\nEllenrizze a cm(ek)et az URL mezben, s szksg esetn a paramtereket, majd kattintson a 'TOVBB' gombra. - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Folytats md (Megszakadt mvelet) -\n\nEllenrizze a cme(ke)t az URL mezben, s szksg esetn a paramtereket, majd kattintson a 'TOVBB' gombra. Log files Path Naplfjlok tvonala Path tvonal - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror - Hivatkozsjegyzk md -\n\nrja be az URL mezbe azon oldal(ak) cme(i)t, melyek tkrzend hivatkozsokat tartalmaznak New project / Import? j projekt / importls? Choose criterion Vlassza ki a felttelt Maximum link scanning depth Maximlis hivatkozsi mlysg Enter address(es) here Ide rja be a cme(ke)t Define additional filtering rules Kiegszt szrsi szablyok meghatrozsa Proxy Name (if needed) Proxy neve (ha szksges) Proxy Port Proxy port Define proxy settings Proxy belltsainak meghatrozsa Use standard HTTP proxy as FTP proxy A szabvnyos HTTP proxy FTP proxyknt val hasznlata Path tvonal Select Path tvonal kijellse Path tvonal Select Path tvonal kijellse Quit WinHTTrack Website Copier Kilps a WinHTTrack webhely msolbl About WinHTTrack WinHTTrack nvjegye Save current preferences as default values Aktulis belltsok mentse alaprtelemezett rtkekknt Click to continue Nyomja meg a folytatshoz Click to define options Nyomja meg az opcik meghatrozshoz Click to add a URL Nyomja meg URL hozzadshoz Load URL(s) from text file URL(-ek) betltse szvegfjlbl WinHTTrack preferences (*.opt)|*.opt|| WinHTTrack belltsok (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| Cmlista szvegfjl (*.txt)|*.txt|| File not found! A fjl nem tallhat! Do you really want to change the project name/path? Valban mdostani kvnja a projekt nevt/tvonalt? Load user-default options? Betlti a felhasznl-alaprtelmezett opcikat? Save user-default options? Menti a felhasznl-alaprtelmezett opcikat? Reset all default options? Visszallt minden alaprtelmezett opcit? Welcome to WinHTTrack! dvzli a WinHTTrack webhely msol! Action: Mvelet: Max Depth Max. mlysg: Maximum external depth: Maximlis kls mlysg: Filters (refuse/accept links) : Szrk (hivatkozsok kizrsa/belefoglalsa): Paths tvonalak Save prefs Belltsok mentse Define.. Meghatrozs... Set options.. Belltsok... Preferences and mirror options: Belltsok s tkrzsi opcik: Project name Projekt neve Add a URL... URL hozzadsa... Web Addresses: (URL) Webcmek (URL): Stop WinHTTrack? Lelltja a programot? No log files in %s! A(z) %s nem tartalmaz naplfjlt! Pause Download? Sznetelteti a letltst? Stop the mirroring operation Tkrzs lelltsa Minimize to System Tray Kis mretre zrs a tlcra Click to skip a link or stop parsing Nyomja meg hivatkozs kihagyshoz vagy az elemzs lelltshoz Click to skip a link Nyomja meg hivatkozs kihagyshoz Bytes saved Mentett bjt: Links scanned Vizsglt hivatkozs: Time: Id: Connections: Csatlakozs: Running: Futtats: Hide Elrejts Transfer rate tviteli sebessg SKIP KIHAGY Information Informci Files written: rott fjl: Files updated: Frisstett fjl: Errors: Hiba: In progress: Folyamatban: Follow external links Kls hivatkozsok kvetse Test all links in pages Az oldal(ak) sszes hivatkozsnak tesztelse Try to ferret out all links Felismer minden hivatkozst Download HTML files first (faster) Elbb a HTML-fjlokat tlti le (gyorsabb) Choose local site structure Weblap helyi szerkezetnek kivlasztsa Set user-defined structure on disk Felhasznli meghatrozs szerkezet belltsa a lemezen Use a cache for updates and retries Gyorsttr hasznlata a frisstsekhez s prbkhoz Do not update zero size or user-erased files Nem frissti a nulla mret vagy a felhasznl ltal trlt fjlokat Create a Start Page Kezdlap ltrehozsa Create a word database of all html pages Az sszes HTML oldal szadatbzisnak ltrehozsa Create error logging and report files Hibanapl- s jelentsfjl ltrehozsa Generate DOS 8-3 filenames ONLY CSAK 8-3 formtum DOS-fjlnv generlsa Generate ISO9660 filenames ONLY for CDROM medias ISO9660 fjlnevek generlsa CSAK CDROM adathordozhoz Do not create HTML error pages Nem hoz ltre HTML hibaoldalakat Select file types to be saved to disk Jellje ki a lemezre mentend fjltpusokat Select parsing direction Jellje ki az elemzs irnyt Select global parsing direction Jellje ki a globlis elemzsi irnyt Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) Szablyok alkotsa a bels (letlttt) hivatkozsok s a kls (nem letlttt) hivatkozsok trshoz Max simultaneous connections Egyidej kapcsolatok max. szma File timeout Fjl idtllps Cancel all links from host if timeout occurs Minden hivatkozs trlse a kiszolglrl idtllps esetn Minimum admissible transfer rate Minimlis engedlyezett tviteli szint Cancel all links from host if too slow Minden hivatkozs trlse a kiszolglrl, ha az tl lass Maximum number of retries on non-fatal errors Prblkozsok maximlis szma nem vgzetes hiba esetn Maximum size for any single HTML file Brmilyen egyszer HTML fjl maximlis mrete Maximum size for any single non-HTML file Brmilyen egyszer nem HTML-fjl maximlis mrete Maximum amount of bytes to retrieve from the Web A webrl letltend maximlis bjt mennyisg Make a pause after downloading this amount of bytes Szneteltets ennyi mennyisg bjt letltse utn Maximum duration time for the mirroring operation A tkrzs maximlis idtartama Maximum transfer rate Maximlis tviteli szint Maximum connections/seconds (avoid server overload) Max. csatlakozs/msodperc (a kiszolgl tlterheltsgnek cskkentsre) Maximum number of links that can be tested (not saved!) A tesztelhet hivatkozsok max. szma (nincs mentve!) Browser identity Bngsz beazonostsa Comment to be placed in each HTML file Mindegyik HTML fjlban elhelyezend megjegyzs Back to starting page Vissza a kezdlaphoz Save current preferences as default values Aktulis belltsok mentse alaprtkekknt Click to continue Nyomja meg a folytatshoz Click to cancel changes Nyomja meg a mdostsok trlshez Follow local robots rules on sites Helyi robotok szablyainak kvetse a webhelyeken Links to non-localised external pages will produce error pages Meghatrozatlan hely kls weblapokra mutat hivatkozsok hibaoldalakat eredmnyeznek Do not erase obsolete files after update Aktualizls utn nem trli a rgi fjlokat Accept cookies? Fogadja a stiket? Check document type when unknown? Ellenrzi a dokumentum tpust, ha ismeretlen? Parse java applets to retrieve included files that must be downloaded? Elemzi a Java appleteket a letltend fjlok kikeressnek szempontjbl? Store all files in cache instead of HTML only Minden fjlt csak a gyorsttrban trol a HTML helyett Log file type (if generated) Naplfjl tpusa (generls esetn) Maximum mirroring depth from root address Tkrzs maximlis mlysge a gykrcmtl Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) Maximum mirroring depth for external/fodbidden addresses (0, that is, none, is the default) Create a debugging file Hibakeres fjl ltrehozsa Use non-standard requests to get round some server bugs Nem szabvnyos krsek hasznlata bizonyos kiszolgl hibk elkerlshez Use old HTTP/1.0 requests (limits engine power!) Rgi HTTP/1.0 krsek hasznlata (korltozza a motor energijt!) Attempt to limit retransfers through several tricks (file size test..) Ismtelt tvitel korltozsa klnfle trkkkkel (fjlmret teszt...) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Write external links without login/password Kls hivatkozsok felhasznlnv/jelsz nlkli rsa Write internal links without query string Bels hivatkozsok rsa lekrdezsi szveg nlkl Get non-HTML files related to a link, eg external .ZIP or pictures Hivatkozshoz kapcsold nem HTML fjlok letltse, pl. kls ZIP vagy kpek Test all links (even forbidden ones) Minden hivatkozs tesztelse (a tiltottak is) Try to catch all URLs (even in unknown tags/code) Minden URL felfogsa (ismeretlen tagekben/kdban is) Get HTML files first! Elbb tltse le a HTML-fjlokat! Structure type (how links are saved) Szerkezet tpusa (a hivatkozsok mentsnek mdja) Use a cache for updates Gyorsttr hasznlata a frisstsekhez Do not re-download locally erased files Nem tlti le ismt a helyben trlt fjlokat Make an index Mutat ksztse Make a word database Szadatbzis ltrehozsa Log files Naplfjlok DOS names (8+3) DOS nevek (8+3) ISO9660 names (CDROM) ISO9660 nevek (CDROM) No error pages Nincs hibaoldal Primary Scan Rule F keressi szably Travel mode Kzlekedsi md Global travel mode Globlis kzlekedsi md These options should be modified only exceptionally Csak kivteles esetben mdostsa ezeket az opcikat Activate Debugging Mode (winhttrack.log) Hibakeres md aktivlsa (winhttrack.log) Rewrite links: internal / external Hivatkozsok trsa: bels / kls Flow control Forgalom szablyozs Limits Korltozsok Identity Azonosts HTML footer HTML lbjegyzet N# connections Csatlakozsok szma Abandon host if error Hiba esetn levlik a kiszolglrl Minimum transfer rate (B/s) Minimlis tviteli sebessg (B/s) Abandon host if too slow Levlik a kiszolglrl, ha tl lass Configure Bellts Use proxy for ftp transfers Proxy hasznlata FTP tvitelekhez TimeOut(s) Idtllps Persistent connections (Keep-Alive) Folytonos kapcsolatok (letben tarts) Reduce connection time and type lookup time using persistent connections A csatlakozsi id s tpus keressi id cskkentse folytonos kapcsolatokkal Retries Prbk szma Size limit Mrethatr Max size of any HTML file (B) Brmilyen HTML fjl (B) max. mrete Max size of any non-HTML file Brmilyen nem HTML-fjl max. mrete Max site size A webhely max. mrete Max time Max. idtartam Save prefs Belltsok mentse Max transfer rate Max. tviteli sebessg Follow robots.txt Robots.txt kvetse No external pages Nincs kls oldal Do not purge old files Nem rti ki a rgi fjlokat Accept cookies Stik fogadsa Check document type Dokumentum tpus ellenrzse Parse java files Java fjlok elemzse Store ALL files in cache MINDEN fjl trolsa a gyorsttrban Tolerant requests (for servers) Trelmes krsek (kiszolglk rszre) Update hack (limit re-transfers) Ismtelt tvitelek korltozsa URL hacks (join similar URLs) Force old HTTP/1.0 requests (no 1.1) Rgi HTTP/1.0 (1.1 nem) krsek alkalmazsa Max connections / seconds Max. csatlakozs/msodperc Maximum number of links Hivatkozsok max. szma Pause after downloading.. Sznet letlts utn Hide passwords Jelszavak elrejtse Hide query strings Lekrdezsi szvegek elrejtse Links Hivatkozsok Build Szerkezet Experts Only Csak szakembereknek Flow Control Forgalom szablyozs Limits Korltozsok Browser ID Bngsz beazonosts Scan Rules Keressi szablyok Spider Indexels Log, Index, Cache Napl, mutat, gyorsttr Proxy Proxy MIME Types MIME-tpusok Do you really want to quit WinHTTrack Website Copier? Biztos, hogy bezrja a programot? Do not connect to a provider (already connected) nem csatlakozik szolgltathoz (mr csatlakozott) Do not use remote access connection Nem hasznl tvoli elrs kapcsolatot Schedule the mirroring operation Tkrzs temezse Quit WinHTTrack Website Copier Kilps a WinHTTrack webhely msolbl Back to starting page Vissza a kezdlaphoz Click to start! Nyomja meg az indtshoz! No saved password for this connection! Nem mentette el a jelszt ehhez a kapcsolathoz! Can not get remote connection settings A tvoli kapcsolat belltsai nem hozzfrhetk Select a connection provider Vlassza ki a szolgltatt Start Indts Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. Szksg esetn lltsa be a kapcsolat tulajdonsgait,\nmajd nyomja meg a BEFEJEZS gombot a tkrzs megkezdshez. Save settings only, do not launch download now. Csak a belltsokat menti, nem indtja a letltst. On hold Vrakozs Transfer scheduled for: (hh/mm/ss) tvitel temezse: (/pp/mm) Start Indts Connect to provider (RAS) Csatlakozs a szolgltathoz Connect to this provider Csatlakozs ehhez a szolgltathoz Disconnect when finished Vonalbonts, ha ksz Disconnect modem on completion Modem levlasztsa, ha ksz \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n(Krjk, jelezzen neknk brmilyen hibt vagy problmt)\r\n\r\nFejleszts:\r\nKezelfellet (Windows): Xavier Roche\r\nIndexels: Xavier Roche\r\nJavaElemzOsztlyok: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nEZER KSZNET a magyar fordtsrt:\r\nHerczeg Jzsef Tamsnak (hdodi@freemail.hu) About WinHTTrack Website Copier WinHTTrack webhely msol nvjegye Please visit our Web page Keresse fel weblapunkat! Wizard query Varzsl krdse Your answer: Az n vlasza: Link detected.. Hivatkozs tallhat.. Choose a rule Vlasszon ki egy szablyt Ignore this link Kihagyja ezt a hivatkozst Ignore directory Mappa kihagysa Ignore domain Tartomny kihagysa Catch this page only Csak ezt az oldalt tlti le Mirror site Webhely tkrzse Mirror domain Tartomny tkrzse Ignore all Mindet kihagyja Wizard query Varzsl krdse NO NEM File Fjl Options Belltsok Log Napl Window Ablak Help Sg Pause transfer tvitel szneteltetse Exit Kilps Modify options Opcik mdostsa View log Napl megjelentse View error log Hibanapl megjelentse View file transfers Fjltvitelek megjelentse Hide Elrejts About WinHTTrack Website Copier Nvjegy Check program updates... j verzi keresse... &Toolbar &Eszkztr &Status Bar llapot&sor S&plit &Feloszts File Fjl Preferences Belltsok Mirror Tkrzs Log Napl Window Ablak Help Sg Exit Kilps Load default options Alaprtelmezett opcik betltse Save default options Alaprtelmezett opcik visszalltsa Reset to default options Alartelmezett opcik visszalltsa Load options... Opcik betltse... Save options as... Opcik mentse msknt... Language preference... Nyelv tvltsa... Contents... Tartalomjegyzk... About WinHTTrack... WinHTTrack nvjegye... New project\tCtrl+N j projekt\tCtrl+N &Open...\tCtrl+O M&egnyits...\tCtrl+O &Save\tCtrl+S &Ments\tCtrl+S Save &As... Ment&s msknt... &Delete... &Trls... &Browse sites... Webhelyek &bngszse... User-defined structure Felhasznli meghatrozs szerkezet %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\tFjlnv fjltpus nlkl (kiv: kp)\r\n%N\tFjlnv fjltpussal (kiv: kep.gif)\r\n%t\tCsak fjltpus (kiv: gif)\r\n%p\ttvonal [vg nlkl /] (kiv: /nehanykep)\r\n%h\tKiszolgl neve (kiv: www.someweb.com)\r\n%M\tMD5 URL (128 bit, 32 ascii bjt)\r\n%Q\tMD5 keresend szveg (128 bit, 32 ascii bjt)\r\n%q\tMD5 kis keressi szveg (16 bit, 4 ascii bjt)\r\n\r\n%s?\tRvid nv (kiv: %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Plda:\t%h%p/%n%q.%t\n->\t\tc:\\tukor\\www.someweb.com\\nehanykep\\kep.gif Proxy settings Proxy belltsok Proxy address: Proxy cme: Proxy port: Proxy port: Authentication (only if needed) Hitelests (csakszksg esetn) Login Felhasznl Password Jelsz Enter proxy address here Ide rja be a proxy cmt Enter proxy port here Ide rja be a proxy portot Enter proxy login Ide rja be a proxy felhasznljt Enter proxy password Ide rja be a proxy jelszavt Enter project name here Ide rja be a projekt nevt Enter saving path here Ide rja be a projekt mentsi tvonalt Select existing project to update Jelljn ki egy ltez, frisstend projektet Click here to select path Nyomja meg az tvonal kijellshez Select or create a new category name, to sort your mirrors in categories HTTrack Project Wizard... HTTrack Projekt Varzsl... New project name: Az j projekt neve: Existing project name: A ltez projekt neve: Project name: Projekt neve: Base path: tvonal: Project category: C:\\My Web Sites C:\\Letoltott weblapok Type a new project name, \r\nor select existing project to update/resume rja be az j projekt nevt, \r\nvagy jelljn ki ltez projektet a frisstshez/folytatshoz New project j projekt Insert URL URL beszrsa URL: URL: Authentication (only if needed) Hitelests (csak szksg esetn) Login Felhasznl Password Jelsz Forms or complex links: rlapok vagy sszetett hivatkozsok: Capture URL... URL tvtele... Enter URL address(es) here Ide rja be az URL-t Enter site login rja be a webhely felhasznlnevt Enter site password rja be a webhely jelszavt Use this capture tool for links that can only be accessed through forms or javascript code Ezt az tvtelt segt eszkzt olyan hivatkozsokhoz vegye ignybe, melyek csak rlapokon vagy JavaScript kdon keresztl hozzfrhetk Choose language according to preference Vlassza ki az n ltal beszlt nyelvet Catch URL! URL tvtele! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. Mdostsa ideiglenesen a bngsz proxy belltsait a kvetkez rtkekre (a proxy cm s port msolsval/beillesztsvel).\nEzutn kattintson a bngszben az rlap SUBMIT gombjra, vagy kattintson az tvenni kvnt hivatkozsra. This will send the desired link from your browser to WinHTTrack. Ez tkldi a bngszbl az hajtott hivatkozst a WinHTTrack programhoz. ABORT MGSE Copy/Paste the temporary proxy parameters here Az ideiglenes proxy belltsok msolsa/beillesztse itt Cancel Mgse Unable to find Help files! Nem tallhat a Sg! Unable to save parameters! A paramterek nem menthetk! Please drag only one folder at a time Egyszerre csak egy mappt hzzon t Please drag only folders, not files Csak mappt hzzon t, ne fjlt Please drag folders only Csak mappt hzzon t Select user-defined structure? Felhasznli meghatrozs szerkezetet jell ki? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! Ellenrizze, hogy a felhasznl ltal meghatrozott szveg megfelel-e,\nmert klnben a fjlnevek hamisak lesznek! Do you really want to use a user-defined structure? Valban felhasznl ltal meghatrozott szerkezetet kvn kijellni? Too manu URLs, cannot handle so many links!! Tl sok URL, ilyen sok hivatkozst nem lehet kezelni!! Not enough memory, fatal internal error.. Nincs elg memria, vgzetes bels hiba. Unknown operation! Ismeretlen mvelet! Add this URL?\r\n Hozzadja az URL-t?\r\n Warning: main process is still not responding, cannot add URL(s).. Figyelem! A f folyamat mg nem vlaszol, nem lehet URL-(eke)t hozzadni.. Type/MIME associations Tpus/MIME trstsok File types: Fjltpusok: MIME identity: MIME azonosts Select or modify your file type(s) here Itt jellje ki vagy mdostsa a fjltpus(oka)t Select or modify your MIME type(s) here Itt jellje ki vagy mdostsa a MIME tpus(oka)t Go up Fel Go down Le File download information Fjl letltsi informcik Freeze Window Ablak rgztse More information: Tovbbi informci: Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download dvzli a WinHTTrack webhely msol!\n\nNyomja meg a TOVBB gombot\n\n- j projekt indtshoz\n- vagy megkezdett letlts folytatshoz. File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS Fjlnv kiterjesztssel:\nFjlnv, tartalmazva:\nIlyen fjlnv:\nMappanv, tartalmazva:\nIlyen mappanv:\nHivatkozsok tartomnyokon:\nHivatkozsok tartomnyokon, tartalmazva:\nHivatkozsok errl a kiszolglrl:\nHivatkozsok, tartalmazva:\nIlyen hivatkozs:\nMINDEN HIVATKOZS Show all\nHide debug\nHide infos\nHide debug and infos Mind ltszik\nHibakeress elrejtse\nInfk elrejtse\nHibakeress s infk elrejtse Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. Hely-szerkezet (alaprtelmezett)\nHtml a web/, kpek/egyb fjlok a web/kepek/\nHtml a web/html, kpek/egyebek a web/kepek\nHtml a web/, kpek/egyebek a web/\nHtml a web/, kpek/egyebek a web/xxx, ahol xxx a fjlkiterjeszts\nHtml a web/html, kpek/egyebek a web/xxx\nHely-szerkezet, www.tartomany.xxx nlkl/\nHtml a hely_nev/, kpek/egyb fjlok a hely_nev/kepek/\nHtml a hely_nev/html, kpek/egyebek a hely_nev/kepek\nHtml a hely_nev/, kpek/egyebek a hely_nev/\nHtml a hely_nev/, kpek/egyebek a hely_nev/xxx\nHtml a hely_nev/html, kpek/egyebek a hely_nev/xxx\nMinden fjl a web/, vletlen nevekkel (bonyolult !)\nMinden fjl a hely_nev/, vletlen nevekkel (bonyolult !)\nFelhasznl ltal meghatrozott szerkezet... Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first Csak keress\nHTML fjlok trolsa\nNem HTML-fjlok trolsa\nMinden fjl trolsa (alaprtelmezett)\nElbb a HTML-fjlokat trolja Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down Ugyanabban a mappban marad\nLemehet (alaprtelmezett)\nFelmehet\nLe is, fel is mehet Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web Ugyanazon a cmen marad (alaprtelm.)\nUgyanazon a tartomnyon marad\nUgyanazon a felsszint tartomnyon m.\nMindenhova megy a weben Never\nIf unknown (except /)\nIf unknown Soha\nHa ismeretlen (kivve /)\nHa ismeretlen no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules nincs robot txt szably\nrobots.txt a varzsl kivtelvel\nrobots.txt szablyok kvetse normal\nextended\ndebug norml\nkiterjesztett\nhibakeress Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download Webhely(ek) letltse\nWebhely(ek) letltse + krdsek\nnll fjlok megszerzse\nMinden hely letltse oldalakban (tbbszrs tkrzs)\nHivatkozsok tesztelse az oldalakon (webcm teszt)\n* Megszakadt letlts folytatsa\n* Ltez letlts frisstrse Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL Relatv URL / Abszolt URL (alaprtelmezett)\nAbszolt URL / Abszolt URL\nAbszolt URL / Abszolt URL\nEredeti URL / Eredeti URL Open Source offline browser Nylt forrskd kapcsolat nlkli bngsz Website Copier/Offline Browser. Copy remote websites to your computer. Free. Weblapmsol/Kapcsolat nlkli bngsz. A tvoli webhelyek sajt szmtgpre msolshoz. Ingyenes. httrack, winhttrack, webhttrack, offline browser httrack, winhttrack, webhttrack, kapcsolat nlkli bngsz URL list (.txt) URL-lista (.txt) Previous Elz Next Kvetkez URLs URL-ek Warning Figyelmeztets Your browser does not currently support javascript. For better results, please use a javascript-aware browser. Az n bngszje jelenleg nem rendelkezik JavaScript tmogatssal. JavaScriptes bngsz hasznlatval jobb eredmnyt rhet el. Thank you Ksznjk You can now close this window Mostmr bezrhatja ezt az ablakot Server terminated A kiszolgl befejezte a kapcsolatot A fatal error has occurred during this mirror Vgzetes hiba trtnt a tkrzs kzben httrack-3.49.5/lang/Macedonian.txt0000644000175000017500000010744614360553245013740 00000000000000LANGUAGE_NAME Macedonian LANGUAGE_FILE Macedonian LANGUAGE_ISO mk LANGUAGE_AUTHOR (aleks@macedonia.eu.org) \r \n LANGUAGE_CHARSET ISO-8859-5 LANGUAGE_WINDOWSID FYRO Macedonian OK Cancel Exit Close Cancel changes Click to confirm Click to get help! Click to return to previous screen Click to go to next screen Hide password Save project Close current project? ? Delete this project? ? Delete empty project %s? %s? Action not yet implemented Error deleting this project Select a rule for the filter Enter keywords for the filter Cancel Add this rule Please enter one or several keyword(s) for the rule Add Scan Rule Scan Criterion String Add Scan Rules Scan Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi / URL . scan . \n .\n\n: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi\r\n Exclude links Include link(s) Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) : GIF , +www..com/*.gif. \n(+*.gif / -*.gif / GIF- ) Save prefs Matching links will be excluded: : Matching links will be included: : Example: : gif\r\nWill match all GIF files gif\r\n GIF blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' blue\r\n 'blue'- 'bluesky-small.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' bigfile.mov\r\n 'bigfile.mov', 'bigfile2.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\n - 'cgi' /cgi-bin/somecgi.cgi cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\ 'cgi-bin' ( cgi-bin-2, ) someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb.com\r\n www.someweb.com, private.someweb.com . someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. someweb\r\n www.someweb.com, www.someweb.edu, private.someweb.otherweb.com . www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.someweb.com\r\n 'www.someweb.com' ( private.someweb.com/..) someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. someweb\r\n www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html . www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/someweb.html\r\n 'www.test.com/test/someweb.html . path (URL + path) All links will match Add exclusion filter Add inclusion filter Existing filters Cancel changes Save current preferences as default values default Click to confirm No log files in %s! log %s! No 'index.html' file in %s! 'index.html' %s! Click to quit WinHTTrack Website Copier WinHTTrack Website Copier View log files log Browse HTML start page HTML start End of mirror (mirror) View log files log Browse Mirrored Website New project... ... View error and warning reports View report Close the log file window log Info type: Errors Infos Find Find a word Info log file log Warning/Errors log file Log Unable to initialize the OLE system OLE WinHTTrack could not find any interrupted download file cache in the specified folder! WinHTTrack download ke Could not connect to provider receive request connect search ready error Receiving files.. ... Parsing HTML file.. HTML ... Purging files.. ... Loading cache in progress.. .. Parsing HTML file (testing links).. HTML ( ).. Pause - Toggle [Mirror]/[Pause download] to resume operation - [Mirror]/[ ] Finishing pending transfers - Select [Cancel] to stop now! - [] ! scanning Waiting for scheduled time.. ... Connecting to provider [%d seconds] to go before start of operation [%d seconds] Site mirroring in progress [%s, %s bytes] [%s, %s ] Site mirroring finished! ! A problem occurred during the mirroring operation\n \n \nDuring:\n \n :\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! \n log .\n\n WinHTTrack Website Copier.\n\n WinHTTrack! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! .\n WinHTTrack.\n log .\n\n WinHTTrack! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? ** !**\r\n temporary update .\r\n ; , \r\n[: hts-cache/new.* ]\r\n\r\n , ? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= ** **\r\nHTTrack . update, .\r\n: , .\r\n=> , / proxy !<= \n\nTip: Click [View log file] to see warning or error messages n\n: [ log ] Error deleting a hts-cache/new.* file, please do it manually hts-cache/new.* , . Do you really want to quit WinHTTrack Website Copier? WinHTTrack Website Copier? - Mirroring Mode -\n\nEnter address(es) in URL box - -\n\n URL - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - wizard () -n\n URL - File Download Mode -\n\nEnter file address(es) in URL box - -n\n URL - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - -n\n URL - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - -n\n URL , , '' - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - ( ) -n\n URL , , '' Log files Path Path log Path - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror - -n\n URL . New project / Import? / ? Choose criterion Maximum link scanning depth Enter address(es) here Define additional filtering rules Proxy Name (if needed) Proxy ( ) Proxy Port Proxy Define proxy settings proxy Use standard HTTP proxy as FTP proxy HTTP proxy FTP proxy Path Select Path Path Path Select Path Path Quit WinHTTrack Website Copier WinHTTrack Website Copier About WinHTTrack WinHTTrack Save current preferences as default values default Click to continue Click to define options Click to add a URL URL Load URL(s) from text file URL- WinHTTrack preferences (*.opt)|*.opt|| WinHTTrack (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| (*.txt)|*.txt| File not found! ! Do you really want to change the project name/path? /path-? Load user-default options? user-default ? Save user-default options? user-default ? Reset all default options? default ? Welcome to WinHTTrack! WinHTTrack! Action: : Max Depth Maximum external depth: a: Filters (refuse/accept links) : (/ ) : Paths Path- Save prefs Define.. ... Set options.. ... Preferences and mirror options: Project name Add a URL... URL... Web Addresses: (URL) : (URL) Stop WinHTTrack? WinHTTrack? No log files in %s! log %s! Pause Download? ? Stop the mirroring operation ? Minimize to System Tray System Tray Click to skip a link or stop parsing Click to skip a link Bytes saved Links scanned Time: : Connections: : Running: : Hide Transfer rate SKIP Information Files written: : Files updated: Update- : Errors: : In progress: : Follow external links Test all links in pages Try to ferret out all links Download HTML files first (faster) HTML () Choose local site structure Set user-defined structure on disk user- Use a cache for updates and retries update retry Do not update zero size or user-erased files update Create a Start Page Create a word database of all html pages word html Create error logging and report files error logging Generate DOS 8-3 filenames ONLY DOS 8-3 Generate ISO9660 filenames ONLY for CDROM medias ISO9660 CDROM Do not create HTML error pages HTML Select file types to be saved to disk Select parsing direction Select global parsing direction Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) Max simultaneous connections File timeout Timeout Cancel all links from host if timeout occurs host- timeout Minimum admissible transfer rate Cancel all links from host if too slow host- Maximum number of retries on non-fatal errors retry - Maximum size for any single HTML file HTML Maximum size for any single non-HTML file -HTML Maximum amount of bytes to retrieve from the Web Make a pause after downloading this amount of bytes Maximum duration time for the mirroring operation - Maximum transfer rate Maximum connections/seconds (avoid server overload) / (༝ ) Maximum number of links that can be tested (not saved!) ( !) Browser identity Comment to be placed in each HTML file HTML Back to starting page Save current preferences as default values default Click to continue Click to cancel changes Follow local robots rules on sites Links to non-localised external pages will produce error pages - Do not erase obsolete files after update update- Accept cookies? (cookies)? Check document type when unknown? ? Parse java applets to retrieve included files that must be downloaded? Java ? Store all files in cache instead of HTML only HTML Log file type (if generated) log ( ) Maximum mirroring depth from root address root Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) / (0, , default) Create a debugging file debugging Use non-standard requests to get round some server bugs - Use old HTTP/1.0 requests (limits engine power!) HTML/1.0 ( ) Attempt to limit retransfers through several tricks (file size test..) ( ...) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Write external links without login/password login/password Write internal links without query string 'query string' Get non-HTML files related to a link, eg external .ZIP or pictures -HTML , , .ZIP Test all links (even forbidden ones) ( ) Try to catch all URLs (even in unknown tags/code) URL ( /) Get HTML files first! HTML ! Structure type (how links are saved) ( ) Use a cache for updates update- Do not re-download locally erased files Make an index Make a word database word Log files Log DOS names (8+3) DOS (8+3)*/ ISO9660 names (CDROM) ISO 9660 (CDROM) No error pages Primary Scan Rule Travel mode Global travel mode These options should be modified only exceptionally , Activate Debugging Mode (winhttrack.log) debug (winhttrack.log) Rewrite links: internal / external : / Flow control Flow Limits Identity HTML footer HTML N# connections Abandon host if error host- Minimum transfer rate (B/s) (/) Abandon host if too slow host- Configure Use proxy for ftp transfers proxy ftp TimeOut(s) () Persistent connections (Keep-Alive) (Keep-Alive) Reduce connection time and type lookup time using persistent connections Retries Retry Size limit Max size of any HTML file (B) HTML (B) Max size of any non-HTML file -HTML Max site size Max time Save prefs Max transfer rate Follow robots.txt robots.txt No external pages Do not purge old files Accept cookies (cookies) Check document type Parse java files Java Store ALL files in cache Tolerant requests (for servers) ( ) Update hack (limit re-transfers) Update hack ( ) URL hacks (join similar URLs) Force old HTTP/1.0 requests (no 1.1) HTTP/1.0 ( 1.1) Max connections / seconds / Maximum number of links Pause after downloading.. ... Hide passwords Hide query strings query Links Build Experts Only Flow Control Flow Limits Browser ID Scan Rules Spider Spider Log, Index, Cache Log, , Proxy MIME Types MIME Do you really want to quit WinHTTrack Website Copier? WinHTTrack Website Copier? Do not connect to a provider (already connected) ( ) Do not use remote access connection remote access Schedule the mirroring operation Quit WinHTTrack Website Copier WinHTTrack Website Copier Back to starting page Click to start! ! No saved password for this connection! ! Can not get remote connection settings remote Select a connection provider Start Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. ,\n Save settings only, do not launch download now. , . On hold Transfer scheduled for: (hh/mm/ss) : (hh\mm\ss) Start Connect to provider (RAS) (RAS) Connect to this provider Disconnect when finished Disconnect modem on completion \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\ )\r\n\r\nDevelopment:\r\n (Windows):Xavier Roche\r\nSpider:Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche \r\n :\r\n (aleks@macedonia.eu.org) About WinHTTrack Website Copier WinHTTrack Website Copier Please visit our Web page Wizard query Your answer: : Link detected.. ... Choose a rule Ignore this link Ignore directory Ignore domain Catch this page only Mirror site Mirror domain Ignore all Wizard query NO File Options Log Window Help Pause transfer Exit Modify options View log log- View error log log- View file transfers Hide About WinHTTrack Website Copier WinHTTrack Website Copier Check program updates... update ... &Toolbar Toolbar &Status Bar Statusbar S&plit File Preferences Mirror Log Window Help Exit Load default options default Save default options default Reset to default options default Load options... ... Save options as... ... Language preference... ... Contents... About WinHTTrack... WinHTTrack... New project\tCtrl+N \tCtrl+N &Open...\tCtrl+O &...\tCtrl+O &Save\tCtrl+S &\tCtrl+S Save &As... &... &Delete... &... &Browse sites... & ... User-defined structure %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\t (:image)\r\n%N\t (: image.gif)\r\n%t\t (: gif)\r\n%p\tPath [ /] (: /someimages)\r\n%h\t (: www.someweb.com)\r\n%M\tMD5 URL (128 , 32 ascii )\r\n%Q\tMD5 query (128 , 32 ascii )\r\n%q\tMD5 query (16 , 4 ascii )\r\n\r\n%s?\t (: %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif :\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Proxy settings Proxy Proxy address: Proxy : Proxy port: Proxy : Authentication (only if needed) ( ) Login Password Enter proxy address here proxy Enter proxy port here proxy Enter proxy login proxy Enter proxy password proxy Enter project name here Enter saving path here path- Select existing project to update update Click here to select path path Select or create a new category name, to sort your mirrors in categories HTTrack Project Wizard... HTTrack ... New project name: : Existing project name: : Project name: : Base path: path: Project category: C:\\My Web Sites C:\\ Type a new project name, \r\nor select existing project to update/resume , \r\n update/resume New project Insert URL URL URL: URL: Authentication (only if needed) ( ) Login Password Forms or complex links: : Capture URL... URL... Enter URL address(es) here URL Enter site login Enter site password Use this capture tool for links that can only be accessed through forms or javascript code capture javascript Choose language according to preference Catch URL! URL-to! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. temporary browser proxy (Copy/Paste Proxy ).\n 'submit' , . This will send the desired link from your browser to WinHTTrack. WinHTTrack. ABORT Copy/Paste the temporary proxy parameters here Copy/Paste temporary Cancel Unable to find Help files! Help ! Unable to save parameters! ! Please drag only one folder at a time Please drag only folders, not files , Please drag folders only Select user-defined structure? ? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! ,\n ! Do you really want to use a user-defined structure? ? Too manu URLs, cannot handle so many links!! URL, !! Not enough memory, fatal internal error.. , ... Unknown operation! ! Add this URL?\r\n URL?\r\n Warning: main process is still not responding, cannot add URL(s).. : , URL... Type/MIME associations (Type/MIME) File types: : MIME identity: MIME : Select or modify your file type(s) here Select or modify your MIME type(s) here MIME Go up Go down File download information Freeze Window More information: : Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download WinHTTrack Webiste Copier!\n\n '' \n\n- \n- File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS :\n :\n :\n :\n :\n :\n :\n :\n :\n :\n Show all\nHide debug\nHide infos\nHide debug and infos \n debug\n \n debug Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. ()\nHtml web/, /. web//\nHtml web/html, / web/\nHtml web/, / web/\nHtml web/, / web/xxx, xxx \nHtml web/html, / web/xxx\n , www.domain.xxx/\nHtml site_name/, /. site_name//\nHtml site_name/html, / site_name/\nHtml site_name/, / site_name/\nHtml site_name/, / site_name/xxx\nHtml site_name/html, / site_name/xxx\n web/, (gadget !)\n site_name/, (gadget !)\n .. Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first \n HTML \n -HTML \n (default) HTML Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down \n (default)\n \n Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web (default)\n \n top level \n Never\nIf unknown (except /)\nIf unknown \n (/)\n no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules robots.txt \nrobots.txt wizard\n robots.txt normal\nextended\ndebug \n\ndebug Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download \n + \n \n ( )\n (bookmark )\n* \n* update na English Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL URI / URL ()\n URL / URL\n URI / URL\n URL / URL Open Source offline browser Open Source offline Website Copier/Offline Browser. Copy remote websites to your computer. Free. /Offline . . . httrack, winhttrack, webhttrack, offline browser httrack, winhttrack, webhttrack, offline URL list (.txt) URL (.txt) Previous Next URLs URLs Warning Your browser does not currently support javascript. For better results, please use a javascript-aware browser. javascript. , javascript. Thank you You can now close this window Server terminated A fatal error has occurred during this mirror mirror httrack-3.49.5/lang/Japanese.txt0000644000175000017500000010312214360553245013413 00000000000000LANGUAGE_NAME Japanese LANGUAGE_FILE Japanese LANGUAGE_ISO ja LANGUAGE_AUTHOR TAPKAL\r\n LANGUAGE_CHARSET shift-jis LANGUAGE_WINDOWSID Japanese OK OK Cancel LZ Exit I Close ‚ Cancel changes ύXLZ Click to confirm NbNĊmF Click to get help! NbNăwv! Click to return to previous screen NbNđỎʂɖ߂ Click to go to next screen NbNĎ̉ʂ֐i Hide password pX[hB Save project vWFNgۑ Close current project? ݂̃vWFNgۑ܂? Delete this project? ̃vWFNg폜܂? Delete empty project %s? 󔒂̃vWFNg%s 폜܂? Action not yet implemented @\͂܂Ă܂ Error deleting this project ̃vWFNg̍폜Ɏs܂ Select a rule for the filter tB^̃[IĂ Enter keywords for the filter tB^ւ̃L[[h͂Ă Cancel LZ Add this rule ̃[̒lj Please enter one or several keyword(s) for the rule ̃[̂ЂƂA܂͂‚̃L[[h͂Ă Add Scan Rule XL[̒lj Criterion tB^̃[ String Add lj Scan Rules XL[ Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi URL܂߂A܂͏O邽߂ɃChJ[hgp܂B\n\n‚̃XL𓯂sɒuƂł܂B\nXy[Xi󔒁j𕪊̂߂ɎgpĂB\n: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Exclude links N̏O Include link(s) N܂߂ Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) Tipp: SĂGIFt@C܂߂邽߂ɂ́A+www.someweb.com/*.gif̂悤ɏ܂B \n(+*.gif / -*.gif őSẴTCg̑SĂGIF ܂/r ܂B) Save prefs ݒ̕ۑ Matching links will be excluded: }b`N͔r: Matching links will be included: }b`N͊܂܂: Example: : gif\r\nWill match all GIF files gif\r\nSĂGIFt@CɃ}b` blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' blue\r\nSĂ'blue'܂ރt@Ci'bluesky-small.jpeg'̂悤ȁjɃ}b` bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' bigfile.mov\r\n 'bigfile.mov' Ƀ}b`܂A 'bigfile2.mov' ɂ̓}b`܂B cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\n ͕ 'cgi' /cgi-bin/somecgi.cgi ̂悤ȃtH_Ƀ}b`郊N‚܂B cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\nFindet Links zu Ordnern namens 'cgi-bin'ƂSȕɃ}b`tH_ƒN‚܂(A'cgi-bin-2'̂悤Ȃ̂͏)B someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb.com\r\nwww.someweb.comprivate.someweb.comƂɃ}b`郊N‚܂B someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. someweb\r\nwww.someweb.comwww.someweb.edu, private.someweb.otherweb.comȂǂ̂悤ȕɃ}b`tH_ւ̃N‚܂B www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.someweb.com\r\nwww.someweb.com/...̂悤ȊSȕɃ}b`郊N‚܂(Aprivate.someweb.com/...̂悤Ȃ̂͏) someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. someweb\r\nFindet Links wie www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/someweb.html\r\n 'www.test.com/test/someweb.html'Ƃt@Ĉ݂‚܂B SȃpX (URLƃTCgpX)̗͂Ȃ΂ȂȂƂɒӂĂB All links will match SẴNɃ}b` Add exclusion filter rtB^lj Add inclusion filter ܂߂邽߂̃tB^lj Existing filters ̃tB^ Cancel changes ύX̃LZ Save current preferences as default values ݂̐ݒKlƂĕۑ Click to confirm NbNĊmF No log files in %s! %s ɂ̓Ot@C܂! No 'index.html' file in %s! %s ɂindex.html܂! Click to quit WinHTTrack Website Copier WinHTTrack Website Copier Iɂ͂NbNĂ View log files Ot@C Browse HTML start page HTML̃X^[gy[WuEY End of mirror Rs[i~[j̏I View log files Ot@C Browse Mirrored Website ~[ꂽTCg̃uEY New project... VKvWFNg... View error and warning reports G[ƌx̃O View report O Close the log file window Ot@C‚ Info type: ̎: Errors G[ Infos Find Find a word P̌ Info log file Ot@C Warning/Errors log file x/G[Ot@C Unable to initialize the OLE system OLE ł܂ WinHTTrack could not find any interrupted download file cache in the specified folder! WinHTTrack ́A肳ꂽtH_ɂ͒fꂽ_E[hLbV‚邱Ƃł܂ł! Could not connect to provider voC_Ɛڑł܂ receive M request NGXg connect ڑ search T[` ready error G[ Receiving files.. t@C󂯎Ă܂... Parsing HTML file.. HTML t@C̉͒... Purging files.. t@C̉͒... Loading cache in progress.. Parsing HTML file (testing links).. HTML t@C̉͒ (ÑeXg)... Pause - Toggle [Mirror]/[Pause download] to resume operation f - j[[~[]/[]𒆒f]NbNƍĊJ܂ Finishing pending transfers - Select [Cancel] to stop now! fꂽ]̏I - [LZ]łɒ~! scanning XL Waiting for scheduled time.. ݒ肳ꂽJnԂ҂Ă܂.. Connecting to provider voC_֐ڑ [%d seconds] to go before start of operation Jn܂[%d b] Site mirroring in progress [%s, %s bytes] TCg̃Rs[i~[jis [%s, %s bytes] Site mirroring finished! TCg̃Rs[i~[j A problem occurred during the mirroring operation\n Rs[i~[j̍ہA肪܂\n \nDuring:\n \r\n\nӏ:\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! \r\n\nKvȂ΃Ot@CɂȂĂB\n\n'I' NbN WinHTTrack Website Copier I܂B\n\n WinHTTrack p肪Ƃ܂! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! Rs[i~[j͊܂B\nuIv WinHTTrackI܂B\nKvȂSĂOKł邱ƂmF邽߂ɃOt@CɂȂĂB\n WinHTTrack p肪Ƃ܂! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * Rs[i~[jf܂! * *\r\n݂̈ꎞILbV͂XVƂɕKvŁA܂݂̒fꂽZbVɂf[^Ă܂B\r\nȑÕLbV͂ƊSȏĂ邩܂B; ȀȂꍇ́A𕜌iXgAjČ݂̃LbV폜Kv܂B\r\n[: hts-cache/new.* ł킳t@C폜邱ƂŊȒPɍsƂł܂]\r\n\r\nȑÕLbV葽Ăƍl܂?Ă𕜌Ǝv܂? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * Rs[i~[j̃G[! * *\r\nHTTrack݂͌̃Rs[i~[jłƊm܂BꂪXVłȂAȑÕRs[i~[j܂B\r\n:ŏ̃y[W‚ȂA܂͐ڑɖ肪܂B\r\n=> WebTCg܂݂邱ƁA܂̓vLV̐ݒmFĂB<= \n\nTip: Click [View log file] to see warning or error messages \r\n\n\nTipp: [O] NbNƌxƃG[邱Ƃł܂B Error deleting a hts-cache/new.* file, please do it manually hts-cache/new.* ̒̃t@C폜Ɏs܂B}jAł̍폜肢܂B Do you really want to quit WinHTTrack Website Copier? WinHTTrack Website Copier {ɏI܂? - Mirroring Mode -\n\nEnter address(es) in URL box - Rs[i~[j[h -\n\nAhX URL͗ɓ͂Ă - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - C^NeBuȃEBU[h[h -\n\nAhX URL͗ɓ͂Ă - File Download Mode -\n\nEnter file address(es) in URL box - t@C_E[h[h -\n\nDatei-Adresse(n) in das URL-Feld eingeben - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - NeXg[h -\n\nNƋWebAhXURLLɓ͂ĂB - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - XV[h -\n\n URL ͗̃AhXmFĂBKvȂ΃p[^`FbNāuցv{^NbNĂB - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - ĊJiW[j[h (fꂽ̍ĊJ) -\n\n URL͗̃AhXmFĂBKvȂp[^`FbNāuցv{^NbNĂB Log files Path Ot@C̃pX Path t@C̃pX - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror -NXg[h -\n\nURL ͗ɃRs[i~[j郊N܂ރTCg̃AhX͂ĂB New project / Import? VKvWFNg / ǂݍ? Choose criterion ̑I Maximum link scanning depth XL郊N̊Kw Enter address(es) here AhXɓ͂Ă Define additional filtering rules ljtB^[̒` Proxy Name (if needed) vLV (KvȂ) Proxy Port vLṼ|[g Define proxy settings vLV̐ݒ Use standard HTTP proxy as FTP proxy WHTTPvLVFTPvLVƂĎg Path pX Select Path IꂽpX Path pX Select Path IꂽpX Quit WinHTTrack Website Copier WinHTTrackI About WinHTTrack WinHTTrackɂ‚ Save current preferences as default values ݂̃IvVƂĕۑ Click to continue NbNđ܂ Click to define options NbNăIvVݒ肵܂ Click to add a URL NbN URL lj܂ Load URL(s) from text file eLXgt@CURLǂݍ݂܂ WinHTTrack preferences (*.opt)|*.opt|| WinHTTrack ݒ (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| AhXXg̃eLXgt@C (*.txt)|*.txt|| File not found! t@C‚܂! Do you really want to change the project name/path? {ɃvWFNg/pXύX܂? Load user-default options? ̃IvVǂݍ݂܂? Save user-default options? [U`̃IvVۑ܂? Reset all default options? SĂ̊̃IvVZbg܂? Welcome to WinHTTrack! WinHTTrackւ悤! Action: ANV: Max Depth őKw: Maximum external depth: őOKw: Filters (refuse/accept links) : tB^[ (܂/r N) : Paths pX Save prefs ۑݒ Define.. `... Set options.. IvVݒ... Preferences and mirror options: IvVƃRs[i~[jIvV: Project name vWFNg Add a URL... URL̒lj... Web Addresses: (URL) WebAhX (URL): Stop WinHTTrack? WinHTTrack~܂? No log files in %s! Ot@C %s ɂ͂܂! Pause Download? _E[h𒆒f܂? Stop the mirroring operation Rs[i~[j~ Minimize to System Tray VXegCɍŏ Click to skip a link or stop parsing NbNăN~A܂͉͂~ Click to skip a link NbNăNXLbv Bytes saved ۑoCg: Links scanned XLꂽN Time: oߎ: Connections: ڑ: Running: 쒆: Hide ŏ Transfer rate ڑ[g: SKIP XLbv Information Files written: t@C쐬: Files updated: t@CXV: Errors: G[: In progress: is: Follow external links ON̒ǐ Test all links in pages y[W̑SẴÑeXg Try to ferret out all links SẴNToƎ݂ Download HTML files first (faster) HTMLt@CŏɃ_E[h (葬) Choose local site structure [J̕ۑtH_̑I Set user-defined structure on disk fBXNɃ[U[`̃tH_ݒ肷 Use a cache for updates and retries XViAbvf[gjƃgCɃLbVgp Do not update zero size or user-erased files 0TCY܂̓[Ut@C̍XVsȂ Create a Start Page X^[gy[W̍쐬 Create a word database of all html pages SĂHTMLy[WɒPf[^x[X쐬 Create error logging and report files G[Oƃ|[gt@C쐬 Generate DOS 8-3 filenames ONLY DOSt@Cl[(8+3)̂ݍ쐬 Generate ISO9660 filenames ONLY for CDROM medias Do not create HTML error pages HTMLG[y[W쐬Ȃ Select file types to be saved to disk ۑt@C̎ނ̑I Select parsing direction ͂̑̕I Select global parsing direction O[oȉ͂̑̕I Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) Ni_E[hꂽ́jƊONi_E[hĂȂ́jւ̃[̍ď݂ݒ肷B Max simultaneous connections ő哯ڑ File timeout t@C^CAEg Cancel all links from host if timeout occurs ^CAEgꍇAzXg̑SẴNLZ Minimum admissible transfer rate ŏe][g Cancel all links from host if too slow ܂ɂxꍇAzXg̑SẴNLZ Maximum number of retries on non-fatal errors vIG[łȂꍇ̍őĎs Maximum size for any single HTML file PHTMLt@C̍őTCY Maximum size for any single non-HTML file P̔HTMLt@C̍őTCY Maximum amount of bytes to retrieve from the Web Web̍ő擾oCg Make a pause after downloading this amount of bytes _E[hẴoCgɂȂȂ璆f Maximum duration time for the mirroring operation Rs[i~[j̍őoߎ Maximum transfer rate ő][g Maximum connections/seconds (avoid server overload) ő̐ڑ/b (T[ỏߕׂ̉) Maximum number of links that can be tested (not saved!) eXgő僊Niۑ܂!) Browser identity uEUID Comment to be placed in each HTML file ǂHTMLt@Cɂ}Rg Back to starting page X^[gy[Wɖ߂ Save current preferences as default values ݂̐ݒƂĕۑ Click to continue NbNđ܂ Click to cancel changes NbNĕύXLZ Follow local robots rules on sites TCg̃{bgKɏ] Links to non-localised external pages will produce error pages [JRs[^ɕۑĂȂOy[Wւ̃N̓G[y[WƂ Do not erase obsolete files after update XVÂȂt@CȂ Accept cookies? NbL[‚܂? Check document type when unknown? s̃t@C^Cv`FbN܂? Parse java applets to retrieve included files that must be downloaded? _E[hׂt@Ĉ߂JavaAvbg͂܂? Store all files in cache instead of HTML only HTMLt@Cł͂ȂASẴLbṼt@Cۑ Log file type (if generated) t@C̎ނ̃O (VK쐬ꂽꍇ) Maximum mirroring depth from root address [gAhX̍ő̃Rs[i~[jKw Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) O/֎~ꂽAhXւ̍őRs[i~[jKw (0, Rs[݂Ȃ) Create a debugging file fobOt@C̍쐬n Use non-standard requests to get round some server bugs ‚̃T[õoO邽߂ɕWłȂNGXggp Use old HTTP/1.0 requests (limits engine power!) ȑO HTTP/1.0 NGXggp (ƃXs[h̐!) Attempt to limit retransfers through several tricks (file size test..) ‚̃gbNit@CTCYeXgȂǁjɂē]sĂ݂ Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Write external links without login/password OC/pX[hȂɊONo Write internal links without query string N͌Ȃɏo Get non-HTML files related to a link, eg external .ZIP or pictures HTMLt@CŃNɊ֘At@CAȂ킿OZIP摜t@C擾 Test all links (even forbidden ones) SẴÑeXg (֎~Ă̂ɂ‚Ă) Try to catch all URLs (even in unknown tags/code) SĂURL擾悤Ǝ݂ (sȃ^OƃXNvgɂ‚Ă) Get HTML files first! HTMLt@CɎ擾! Structure type (how links are saved) ۑtH_̐ݒ (N̕ۑ@) Use a cache for updates XVɃLbVgp Do not re-download locally erased files [Jō폜ꂽt@C͍ă_E[hȂ Make an index CfbNX̍쐬 Make a word database Pf[^x[X쐬 Log files Ot@C DOS names (8+3) DOS (8+3) ISO9660 names (CDROM) No error pages G[y[WȂ Primary Scan Rule D悳XL[ Travel mode T@ Global travel mode O[oȒT@ These options should be modified only exceptionally ̃IvV͕ʕύXׂł͂܂B Activate Debugging Mode (winhttrack.log) fobO[hg (winhttrack.log) Rewrite links: internal / external Nď݂ / O Flow control ڑRg[ Limits ~bg Identity ID HTML footer HTMLtb^ N# connections ڑ Abandon host if error G[̍ۂɂ̓zXg Minimum transfer rate (B/s) ŏ][g (B/s) Abandon host if too slow ܂ɂxꍇɂ̓zXg Configure RtBO Use proxy for ftp transfers FTP]ɃvLVgp TimeOut(s) ^CAEg Persistent connections (Keep-Alive) Reduce connection time and type lookup time using persistent connections Retries Ďs Size limit TCY̐ Max size of any HTML file (B) HTMLt@C̍őoCg Max size of any non-HTML file Cӂ̔HTMLt@C̍őoCg Max site size őTCgTCY Max time ő厞 Save prefs ݒ̕ۑ Max transfer rate ő][g Follow robots.txt robots.txt ǐՂ No external pages Oy[WȂ Do not purge old files ӂ邢t@CȂ Accept cookies NbL[󂯓 Check document type hLg̎ނ`FbN Parse java files JAVAt@C͂ Store ALL files in cache SẴt@CLbVɕۑ Tolerant requests (for servers) T[őeNGXg Update hack (limit re-transfers) XṼgbN (ē]) URL hacks (join similar URLs) Force old HTTP/1.0 requests (no 1.1) ȑO HTTP/1.0 NGXgv (1.1ł͂Ȃ) Max connections / seconds őڑ / b Maximum number of links N̍ő吔 Pause after downloading.. _E[ĥƂɒf... Hide passwords pX[hB Hide query strings B Links N Build rh Experts Only ㋉Ҍ Flow Control ڑRg[ Limits ڑ Browser ID uEU ID Scan Rules XL[ Spider XpC_[ Log, Index, Cache OACfbNXALbV Proxy vLV MIME Types Do you really want to quit WinHTTrack Website Copier? WinHTTrack{ɏI܂? Do not connect to a provider (already connected) voC_ƐڑȂ (łɐڑ) Do not use remote access connection [gANZXgȂ Schedule the mirroring operation Rs[i~[j̃XPW[ݒ Quit WinHTTrack Website Copier WinHTTrackI܂ Back to starting page X^[gy[Wɖ߂ Click to start! NbNĊJn܂! No saved password for this connection! ̐ڑɂ̓pX[hۑĂ܂! Can not get remote connection settings [gڑ̐ݒ擾ł܂ Select a connection provider ڑvoC_̑I Start Jn Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. KvȂΐڑp[^𒲐ĂA\nuvƃRs[i~[j͂܂܂B Save settings only, do not launch download now. ݒ݂̂ō̓_E[hJnȂ On hold f Transfer scheduled for: (hh/mm/ss) ]XPW[: (hh/mm/ss) Start Jn Connect to provider (RAS) voC_ւ̐ڑ (RAS) Connect to this provider ̃voC_ւ̐ڑ Disconnect when finished Iڑؒf Disconnect modem on completion 烂fƂ̐ڑؒf \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n(oO܂͖ɂ‚Ăɒm点Ă)\r\n\r\nDevelopment:\r\nInterface(Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nJapanese translation :TAPKAL(nakataka@mars.dti.ne.jp) About WinHTTrack Website Copier WinHTTrackɂ‚ Please visit our Web page ̃EFuy[WɂĂ! Wizard query EBU[h Your answer: Ȃ̂ Link detected.. Nm܂... Choose a rule [̑I Ignore this link ̃N̖ Ignore directory fBNg̖ Ignore domain hC𖳎 Catch this page only ̃y[Ŵݎ擾 Mirror site TCg̃Rs[i~[j Mirror domain hC̃Rs[i~[j Ignore all SĖ Wizard query EBU[h NO File t@C Options IvV Log O Window EBhE Help wv Pause transfer ]𒆒f Exit I Modify options IvVC View log O View error log G[O View file transfers t@C] Hide ŏ About WinHTTrack Website Copier WinHTTrack Website Copierɂ‚ Check program updates... vOXṼ`FbN... &Toolbar &c[o[ &Status Bar &Xe[^Xo[ S&plit & File t@C Preferences ݒ Mirror ~[ Log O Window EBhE Help wv Exit I Load default options K̃IvV̓ǂݍ Save default options K̃IvV̕ۑ Reset to default options K̃IvVɃZbg Load options... IvV̓ǂݍ... Save options as... IvV𖼑Otĕۑ... Language preference... ݒ... Contents... wṽRec... About WinHTTrack... WinHTTrackɂ‚... New project\tCtrl+N &VKvWFNg\tAlt+N &Open...\tCtrl+O &J...\tAlt+O &Save\tCtrl+S &ۑ\tAlt+S Save &As... Otĕۑ &O... &Delete... &폜... &Browse sites... &TCg̃uEY... User-defined structure [U`̃tH_ %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\tt@C̎ނȂŃt@Ĉ (: gazou)\r\n%N\tt@Cƃt@C̎ (: gazou.gif)\r\n%t\tt@C̎ (: gif)\r\n%p\tpX [Ō / Ȃ] (: /gazofile)\r\n%h\thC (: www.someweb.com)\r\n%M\tURL MD5 (128 Bits, 32 ASCII-Bytes)\r\n%Q\tMD5 NG[ (128 Bits, 32 ASCII-Bytes)\r\n%q\tX[MD5NG[ (16 Bits, 4 ASCII-Bytes)\r\n\r\n%s?\tDOSt@C(: %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif :\t%h%p/%n%q.%t\n->\t\tc:\\kagami\\www.someweb.com\\gazofile\\gazou.gif Proxy settings vLV̐ݒ Proxy address: vLṼAhX Proxy port: vLṼ|[g Authentication (only if needed) ݒ (Kv) Login OC Password pX[h Enter proxy address here vLṼAhXɓ Enter proxy port here vLṼ|[gɓ Enter proxy login vLṼOC̓ Enter proxy password vLṼpX[h̓ Enter project name here vWFNgɋLĂ Enter saving path here ۑpXɓ Select existing project to update XṼvWFNgI Click here to select path NbNăpX̑I Select or create a new category name, to sort your mirrors in categories HTTrack Project Wizard... HTTrack vWFNgEBU[h New project name: VKvWFNg Existing project name: ̃vWFNg Project name: vWFNg Base path: pX Project category: C:\\My Web Sites C:\\My Web Sites Type a new project name, \r\nor select existing project to update/resume VvWFNgLĂB \r\ñvWFNgAbvf[g/ĊJɂ͏̃XgIĂB New project VKvWFNg Insert URL URL̑} URL: URL: Authentication (only if needed) ݒ (Kv) Login OC Password pX[h Forms or complex links: tH[܂͕GȃN: Capture URL... URL擾Ă܂... Enter URL address(es) here URLɓ͂Ă Enter site login TCg̃OC̓ Enter site password TCg̃pX[h Use this capture tool for links that can only be accessed through forms or javascript code tH[܂Java-ScriptɂĂ̂݃ANZX”\ȃNÃc[gĎ擾 Choose language according to preference ݒɂČI Catch URL! URL̎擾! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. ݂̃uEŨvLVݒ̒lɓ͂Ă (vLṼAhXƃ|[gRs[/y[Xg܂j\nKlicken Sie dann im Browser auf den Schalter Submit/Absenden o. . des Formulars oder auf die spezielle VerknEfung, die Sie laden wollen. This will send the desired link from your browser to WinHTTrack. ɂĖ]܂NuEU WinHTTrack ɑ܂B ABORT f Copy/Paste the temporary proxy parameters here ݂̃vLṼp[^Rs[/y[Xgi݂݁j܂ Cancel LZ Unable to find Help files! wvt@C‚邱Ƃł܂! Unable to save parameters! p[^ۑł܂! Please drag only one folder at a time Pɂ͂ЂƂ‚̃tH_hbOĂ Please drag only folders, not files t@Cł͂ȂtH_݂̂hbOĂB Please drag folders only tH_݂̂hbOĂ Select user-defined structure? [U`̃tH_I܂? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! [U`̕񂪐ƂmFĂB \n łȂ΃t@C܂B Do you really want to use a user-defined structure? {Ƀ[U`̃tH_gp܂? Too manu URLs, cannot handle so many links!! URL܂! قǑ̃N͏ł܂! Not enough memory, fatal internal error.. \ȃ܂B vIG[... Unknown operation! sȃIy[V! Add this URL?\r\n URLlj܂?\r\n Warning: main process is still not responding, cannot add URL(s).. x: CvZX܂܂BURLljł܂.. Type/MIME associations t@C̎/MIME֘A File types: t@C̎ MIME identity: MIME Select or modify your file type(s) here łȂ̃t@C̎ނI܂͏CĂ Select or modify your MIME type(s) here łȂMIME̎ނI܂͏CĂ Go up Go down File download information t@C_E[h Freeze Window EBhĚŒ More information: [ Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download WinHTTrack Website Copierւ悤!\n\n VvWFNgJn邩\n ܂ _E[hĊJɂ\n u‚ցvNbNĂ File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS gqtt@C:\n܂ރt@C:\ñt@C:\n܂ރtH_:\ñtH_:\ñhC̃N:\n܂ރhC̃N:\ñzXg̃N:\n܂ރN:\ñN:\nSẴN Show all\nHide debug\nHide infos\nHide debug and infos SĂ\\nfobOB\nB\nfobOƏB Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. TCĝ܂܂̍Č()\nHtmlt@CtH_web/, 摜ق̃t@Cweb/images/\nHtmlt@CtH_/html, EFủ摜ق̃t@C/images\nHtmlt@C[gtH_/, 摜ق̃t@Cweb/\nHtmlt@Cweb/, 摜ق̃t@Cweb/xxx, xxx̓t@C̊gq\nHtmlt@Cweb/html, 摜ق̃t@Cweb/xxx\nwww.domain.xxx/ȂŃTCg̍Č\nHtmlt@Csite_name/, 摜ق̃t@Csite_name/images/\nHtmlt@Csite_name/html, 摜قsite_name/images\nHtmlt@Csite_name/, 摜قsite_name/\nHtmlt@C site_name/, f摜̂ق site_name/xxx\nHtmlt@C site_name/html, 摜̑ site_name/xxx\nSẴt@C web/Ƀ_ȖOt(KWFbg!)\nSẴt@C tH_site_name/Ƀ_ȖOt(KWFbg!)\n[U`̃tH_... Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first XL̂\nHTMLt@C̕ۑ\nHTMLt@C̕ۑ\nSẴt@C̕ۑ ()\nŏHTMLt@Cۑ Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down fBNgɂƂǂ܂\ñfBNgւ̈ړ ()\ñfBNgւ̈ړ\n㉺̃fBNgւ̈ړ Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web AhXɂƂǂ܂ ()\nhCɂƂǂ܂\ngbvx̃hCɂƂǂ܂\nWeb̂ǂւłs Never\nIf unknown (except /)\nIf unknown \nm̏ꍇ (/)\nm̏ꍇ no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules robots.txt ꍇ̃[\nEBU[hArobots.txt̃[ɏ]\nrobots.txt̃[ɏ] normal\nextended\ndebug \ng\nfobO Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download EFuTCg̎_E[h\nEFuTCg̎t_E[h\nt@C̎擾\ny[WSẴTCg̃_E[h (TCg̃Rs[(~[))\ny[W̃ÑeXg\n* fꂽ_E[ȟp\n* ̃_E[h̍XV Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL URI(URIꕔLq) / URL(URLtLq)()\nURL / URL\nURI / URL\nIWiURL / IWiURL Open Source offline browser Website Copier/Offline Browser. Copy remote websites to your computer. Free. httrack, winhttrack, webhttrack, offline browser URL list (.txt) Previous Next URLs Warning Your browser does not currently support javascript. For better results, please use a javascript-aware browser. Thank you You can now close this window Server terminated A fatal error has occurred during this mirror httrack-3.49.5/lang/Italiano.txt0000644000175000017500000010747314360553245013442 00000000000000LANGUAGE_NAME Italiano LANGUAGE_FILE Italiano LANGUAGE_ISO it LANGUAGE_AUTHOR Witold Krakowski (wkrakowski at libero.it)\r\n LANGUAGE_CHARSET ISO-8859-1 LANGUAGE_WINDOWSID Italian (Standard) OK Ok Cancel Annulla Exit Esci Close Chiudi Cancel changes Annulla modifiche Click to confirm Clicca per confermare Click to get help! Clicca qui per aiuto Click to return to previous screen Clicca per tornare indietro Click to go to next screen Clicca per passare allo schermo successivo Hide password Nascondi password Save project Salva il progetto Close current project? Chiudere il progetto corrente? Delete this project? Eliminare questo progetto? Delete empty project %s? Eliminare il progetto vuoto %s? Action not yet implemented Azione non ancora possibile Error deleting this project C' stato un errore durante l'eliminazione di questo progetto Select a rule for the filter Seleziona le regole per il filtro Enter keywords for the filter Inserisci le parole chiave per il filtro Cancel Annulla Add this rule Aggiungi questa regola Please enter one or several keyword(s) for the rule Inserisci una o pi parola(e) chiave Add Scan Rule Aggiungi un filtro Criterion Scegli una regola String Inderisci una parola chiave Add Aggiungi Scan Rules Filtri Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Puoi escludere o accettare diversi URL o collegamenti usando wildcards\nPuoi usare spazi tra i filtri.\n\nEsempio: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Exclude links Escludi i collegamenti Include link(s) Accetta i collegamenti Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) Suggerimento: Se vuoi accettare tutti i file gif sulle pagine web, usa qualcosa come +www.pagina.com/*.gif \n((+*.gif accetter/rifiuter TUTTI i file gif su TUTTE le pagine) Save prefs Salva impostazioni Matching links will be excluded: I collegamenti soggetti a questa regola verranno esclusi Matching links will be included: I collegamenti soggetti a questa regola verranno accettati Example: Esempio: gif\r\nWill match all GIF files gif\r\nTrover tutti i file gif blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' blue\r\nTrover tutti i file contenenti 'blue', es. 'bluesky-small.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' bigfile.mov\r\nTrover il file 'bigfile.mov', ma non 'bigfile2.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\nTrover i collegamenti con la cartella contenente 'cgi', es. /cgi-bin/somecgi.cgi cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\nTrover i collegamenti con la cartella contenente 'cgi-bin' (ma non cgi-bin-2, per esempio) someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb.com\r\nTrover tutti i collegamenti come www.someweb.com, private.someweb.com etc. someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. someweb\r\nTrover tutti i collegamenti come www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.someweb.com\r\nTrover tutti i collegamenti come www.someweb.com/... (ma non collegamenti come private.someweb.com/..) someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. someweb\r\nTrover tutti i collegamenti come www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/someweb.html\r\nTrover soltanto il collegamenti www.test.com/test/someweb.html. Nota che bisogna inserire sia l'indirizo (www.xxx.yyy), che il percorso (/test/someweb.html) All links will match Tutti i collegamenti verranno rifiutati/accettati Add exclusion filter Aggiungi il filtro per escludere Add inclusion filter Aggiungi il filtro per accettare Existing filters Filtri aggiuntivi Cancel changes Annulla modifiche Save current preferences as default values Salva impostazioni come valori di default Click to confirm Clicca per confermare No log files in %s! Non creare file di log in %s! No 'index.html' file in %s! Non creare il file index.html in%s! Click to quit WinHTTrack Website Copier Clicca per uscire da WinHTTrack Website Copier View log files Visualizza i file di log Browse HTML start page Visualizza la pagina HTML iniziale End of mirror Fine del mirror View log files Visualizza file di log Browse Mirrored Website Visualizza il Web New project... Nuovo progetto View error and warning reports Visualizza gli errori View report Visualizza le informazioni Close the log file window Chiudi la finestra dei log Info type: Tipo di informazione Errors Errori Infos Informazioni Find Cerca Find a word Trova una parola Info log file File di log Warning/Errors log file File di log degli errori Unable to initialize the OLE system Impossibile inizializzare il sistema OLE WinHTTrack could not find any interrupted download file cache in the specified folder! Non c' cache nella cartella indicata\nWinHTTracknon ha trovato nessun mirror interrotto! Could not connect to provider Impossibile stabilire la connessione con il provider receive ricezione request richiesta connect connessione search ricerca ready pronto error errore Receiving files.. Ricezione dei file.. Parsing HTML file.. Analisi file html.. Purging files.. Pulizia file.. Loading cache in progress.. Caricamento della cache in corso... Parsing HTML file (testing links).. Analisi file HTML (test dei collegamenti).. Pause - Toggle [Mirror]/[Pause download] to resume operation Pausa (seleziona [Aiuto]/[Pausa] per continuare) Finishing pending transfers - Select [Cancel] to stop now! Sto finendo i trasferimenti rimasti - Premi [Annulla] per terminare adesso! scanning Scansione Waiting for scheduled time.. Attesa dell'orario specificato per iniziare Connecting to provider Connesione al provider in corso [%d seconds] to go before start of operation Mirror in pausa [%d seconds] Site mirroring in progress [%s, %s bytes] Mirror in corso [%s, %s bytes] Site mirroring finished! Mirror del sito completato! A problem occurred during the mirroring operation\n C' stato un problema durante il mirror\n \nDuring:\n Durante:\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! Verifica il log se necessario.\n\nClicca OK per uscire da WinHTTrack.\n\nGrazie per aver usato WinHTTrack! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! Il mirror finito.\nClicca OK per uscire da WinHTTrack.\nGuarda i file log per assicurarti che tutto andato a buon fine.\n\nGrazie per aver usato WinHTTrack! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * MIRROR INTERROTTO! * *\r\nLa cache corrente necessaria per le operazioni di aggiornamento e contiene solo i dati scaricati durante questa sessione interrotta.\r\nLa cache precedente potrebbe contenere informazioni pi complete; se non vuoi perdere quelle informazioni, devi ripristinarla e cancellare la cache corrente.\r\n[Nota: per fare questo, cancella il contenuto della cartella hts-cache del mirror]\r\n\r\nPensi che la cache precedente possa contenere informazioni pi complete e vuoi ripristinarla? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * ERRORE NEL MIRROR! * *\r\nHTTrack ha stabilito che il mirror attuale vuoto. Se questo un aggiornamento, il mirror precedente stato ripristinato.\r\nMotivo: la prima pagina(e) non stata trovata oppure c' stato un problema durante la connessione\r\n=> Assicurati che il sito esista ancora, e/o verificate le vostre impostazioni del proxy! <= \n\nTip: Click [View log file] to see warning or error messages \nSuggerimento: Clicca [Visualizza filr di log] per vedere i messaggi di avvertimento o di errore Error deleting a hts-cache/new.* file, please do it manually Errore durante la cancellazione del contenuto della cartella hts-cache, necessario completare l'operazione manualmente Do you really want to quit WinHTTrack Website Copier? Vuoi veramente uscire da WinHTTrack? - Mirroring Mode -\n\nEnter address(es) in URL box - Modo mirror -\n\nInserisci l'indirizzo(i) URL nell'apposito spazio - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - Modo mirror con il wizard (con domande) -\n\nInserisci l'indirizzo(i) URL nell'apposito spazio - File Download Mode -\n\nEnter file address(es) in URL box - Modo di download dei file -\n\nInserisci l'indirizzo(i) URL dei file nell'apposito spazio - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - Modo di test dei collegamenti -\n\nInserisci l'indirizzo(i) URL delle pagine contenenti i collegamenti nell'apposito spazio - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Modo di aggiornameto/continuazione del mirror -\n\nVerifica l'indirizzo(i) nell'apposito spazio, quindi clicca sul pulsante AVANTI e verifica i parametri. - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Continuazione di un mirror interrotto -\n\nVerifica l'indirizzo(i) nell'apposito spazio, quindi clicca sul pulsante AVANTI e verifica i parametri. Log files Path Percorso dei file di log Path Percorso - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror Modo di lista di mirror, inserisci l'indirizzo(i) delle pagine contenenti i collegamenti New project / Import? Nuovo progetto / importare? Choose criterion Scegli l'azione Maximum link scanning depth Massima profondit dei link Enter address(es) here Inserisci gli indirizzi qui Define additional filtering rules Definisci filtri aggiuntivi Proxy Name (if needed) Proxy se necessario Proxy Port Port del proxy Define proxy settings Inserisci le impostazioni del proxy Use standard HTTP proxy as FTP proxy Utilizza il proxy HTTP standard come proxy FTP Path Percorso Select Path Seleziona percorso Path Percorso Select Path Seleziona percorso Quit WinHTTrack Website Copier Esci da WinHTTrack Website Copier About WinHTTrack Informazioni su WinHTTrack Save current preferences as default values Salva le impostazioni come valori di default Click to continue Clicca per continuare Click to define options Clicca per definire le opzioni Click to add a URL Clicca per aggiungere un indirizzo URL Load URL(s) from text file Carica gli URL da un file di testo WinHTTrack preferences (*.opt)|*.opt|| Impostazioni di Win HTTrack (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| File di testo con gli indirizzi (*.txt)|*.txt|| File not found! File non trovato! Do you really want to change the project name/path? Sei sicuro di voler cambiare il nome e/o il percorso del progetto? Load user-default options? Caricare opzioni di default dell'utente? Save user-default options? Salvare opzioni di default dell'utente? Reset all default options? Azzerare tutte le opzioni di default? Welcome to WinHTTrack! Benvenuto in WinHTTrack! Action: Azione: Max Depth Massima profondit: Maximum external depth: Massima profondit esterna: Filters (refuse/accept links) : Filtri (rifiutare/accettare i collegamenti) : Paths Percorsi Save prefs Salva impostazioni Define.. Definisci.. Set options.. Definisci le opzioni.. Preferences and mirror options: Impostazioni e opzioni del mirror: Project name Nome del progetto: Add a URL... Aggiungi URL... Web Addresses: (URL) Indirizzi Web: (URL) Stop WinHTTrack? Fermare WinHTTrack? No log files in %s! Non ci sono log in %s! Pause Download? Trasferimento in pausa? Stop the mirroring operation Interrompi il mirror Minimize to System Tray Nascondi questa finestra nel system tray Click to skip a link or stop parsing Clicca per saltare un collegamento oppure interrompere l'analisi Click to skip a link Clicca per saltare un collegamento Bytes saved Byte salvati Links scanned Collegamenti analizzati Time: Tempo: Connections: Connessioni: Running: In esecuzione: Hide Nascondi Transfer rate Velocit di trasferimento SKIP SALTA Information Informazioni Files written: File salvati : Files updated: File aggiornati : Errors: Errori : In progress: In corso : Follow external links Scarica i file anche dai collegamenti esterni Test all links in pages Verifica tutti i collegamenti nelle pagine Try to ferret out all links Cerca di trovare tutti i collegamenti Download HTML files first (faster) Scarica prima i file HTML (pi veloce) Choose local site structure Scegli la struttura del sito in locale Set user-defined structure on disk Definisci la struttura del sito sul disco Use a cache for updates and retries Usa la cache per aggiornamenti e per riprovare Do not update zero size or user-erased files Non scaricare nuovamente i file presenti localmente con dimensione nulla oppure cancellati dal utente Create a Start Page Crea la pagina iniziale Create a word database of all html pages Crea un database delle parole di tutte le pagine HTML Create error logging and report files Crea file di log per segnalare errori e informazioni Generate DOS 8-3 filenames ONLY Genera solo nomi di file in formato 8.3 Generate ISO 9660 filenames ONLY for CDROM medias Genera nomi di file in formato ISO9660 per i CDROM Do not create HTML error pages Non generare pagine d'errore HTML Select file types to be saved to disk Seleziona i tipi di file da scrivere sul disco Select parsing direction Seleziona la direzione di spostamento nel sito Select global parsing direction Seleziona la direzione globale dello spostamento nel sito Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) Regole per la riscrittura degli URL interni (collegamenti scaricati) ed esterni (collegamenti non scaricati) Max simultaneous connections Numero massimo di connessioni File timeout Massimo tempo d'attesa per un file Cancel all links from host if timeout occurs Annulla tutti i collegamenti dal host se c' timeout Minimum admissible transfer rate Minimo transfer rate ammesso Cancel all links from host if too slow Annulla tutti i collegamenti dal host se troppo lento Maximum number of retries on non-fatal errors Massimo numero di tentativi nel caso di un errore non fatale Maximum size for any single HTML file Massima dimensione per una pagina HTML Maximum size for any single non-HTML file La dimensione massima per un file Maximum amount of bytes to retrieve from the Web Massima dimensione del mirror Make a pause after downloading this amount of bytes Pausa dopo aver ricevuto questa quantit di byte Maximum duration time for the mirroring operation Tempo massimo del mirror Maximum transfer rate Transfer rate massimo Maximum connections/seconds (avoid server overload) Limite delle connessioni al secondo (per evitare il sovraccarico del server) Maximum number of links that can be tested (not saved!) Massimo numero di link che possono essere testati (non salvati!) Browser identity Identit del browser Comment to be placed in each HTML file Pi di pagina per ogni file HTML Back to starting page Torna alla pagina iniziale Save current preferences as default values Salva le impostazioni come valori di default Click to continue Clicca per continuare Click to cancel changes Clicca per annullare le modifiche Follow local robots rules on sites Segui le regole per i robot sui siti Links to non-localised external pages will produce error pages Pagine esterne (non prelevate) saranno collegate alle pagine d'errore Do not erase obsolete files after update Non cancellare i file vecchi dopo l'aggiornamento Accept cookies? Accettare i cookie spediti? Check document type when unknown? Verificare il tipo di documento se sconosciuto? Parse java applets to retrieve included files that must be downloaded? Analizzare gli applet java per ritrovare i file contenuti in essi? Store all files in cache instead of HTML only Tieni tutti i file nella cache, invece dei soli file HTML Log file type (if generated) Tieni il tipo di file nel log se generato Maximum mirroring depth from root address Massima profondit del mirror dai primi indirizzi Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) Massima profondit del mirror per indirizzi esterni/vietati (0, l'impostazione predefinita) Create a debugging file Crea un file di debug Use non-standard requests to get round some server bugs Cerca di evitare alcuni bug dei server usando richieste non standard Use old HTTP/1.0 requests (limits engine power!) Usa richieste HTTP/1.0, limita le capacit del motore! Attempt to limit retransfers through several tricks (file size test..) Tentativo di limitare il numero di ripetizioni dei trasferimenti, usando alcuni truchi (test della dimensione del file..) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Tentativo di limitare il numero di link, saltando URL simili (www.foo.com==foo.com, http=https ..) Write external links without login/password Salva link esterni senza login e password Write internal links without query string Salva i link interni senza stringa query Get non-HTML files related to a link, eg external .ZIP or pictures Scarica file non-HTML vicino ai collegamenti (es. .ZIP o immagini presenti all'esterno) Test all links (even forbidden ones) Verifica tutti i collegamenti (anche quelli vietati) Try to catch all URLs (even in unknown tags/code) Cerca di trovare tutti gli URL (anche quelli con tag/codice sconosciuto) Get HTML files first! Scarica prima i file HTML! Structure type (how links are saved) Tipo di struttura (come sono salvati i collegamenti) Use a cache for updates Usa la cache per gli aggiornamenti Do not re-download locally erased files Non scaricare nuovamente i file cancellati dal disco Make an index Crea un indice Make a word database Crea un database delle parole Log files File di log DOS names (8+3) Nomi DOS (8+3) ISO9660 names (CDROM) Nomi ISO 9660 (CDROM) No error pages Senza pagine d'errore Primary Scan Rule Filtro primario Travel mode Modo di spostamento Global travel mode Modo di spostamento globale These options should be modified only exceptionally Normalmente queste opzioni non devono essere modificate Activate Debugging Mode (winhttrack.log) Attiva il modo di debug (winhttrack.log) Rewrite links: internal / external Riscrittura collegamenti: interni /esterni Flow control Controllo di flusso Limits Limiti Identity Identit HTML footer Pi di pagina HTML N# connections N di connessioni Abandon host if error Abbandona il host nel caso di errore Minimum transfer rate (B/s) Transfer rate minimo (B/s) Abandon host if too slow Abbandona il host se troppo lento Configure Configurazione Use proxy for ftp transfers Usa proxy per trasferimenti ftp TimeOut(s) TimeOut Persistent connections (Keep-Alive) Connessioni persistenti (keep-alive) Reduce connection time and type lookup time using persistent connections Riduci tempo di connessione e il tempo di verifica del tipo usando la connessione persistente Retries Tentativi Size limit Limite di dimensione Max size of any HTML file (B) Dimensione massima html: Max size of any non-HTML file Dimensione massima altri file: Max site size Dimensione massima del sito Max time Tempo massimo Save prefs Salva impostazioni Max transfer rate Velocit di trasferimento massima Follow robots.txt Segui robots.txt No external pages Senza pagine esterne Do not purge old files Non cancellare file vecchi Accept cookies Accetta i cookie Check document type Verifica il tipo di file Parse java files Analizza i file java Store ALL files in cache Memoriza tutti i file nella cache Tolerant requests (for servers) Richieste toleranti (per i server) Update hack (limit re-transfers) Aggiorna hack (limita i ritrasferimenti) URL hacks (join similar URLs) Force old HTTP/1.0 requests (no 1.1) Forza richieste HTTP/1.0 (non 1.1) Max connections / seconds N massimo di connessioni al secondo Maximum number of links Massimo numero di link Pause after downloading.. Pausa dopo il download.. Hide passwords Nascondi password Hide query strings Nascondi le stringhe query Links Collegamenti Build Struttura Experts Only Esperto Flow Control Controllo di flusso Limits Limiti Browser ID Identit del browser Scan Rules Filtri Spider Spider Log, Index, Cache Log, Indice, Cache Proxy Proxy MIME Types Tipi MIME Do you really want to quit WinHTTrack Website Copier? Vuoi veramente uscire da WinHTTrack? Do not connect to a provider (already connected) Non effettuare la connessione al provider (gi connesso) Do not use remote access connection Non usare la connessione di accesso remoto Schedule the mirroring operation Programma il mirror Quit WinHTTrack Website Copier Esci da WinHTTrack Website Copier Back to starting page Torna alla pagina iniziale Click to start! Clicca per iniziare! No saved password for this connection! Non c' nessuna password salvata per questa connessione Can not get remote connection settings Impossibile ottenere i parametri della connessione Select a connection provider Seleziona il provider a cui connettersi Start Inizio Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. Puoi iniziare il mirror premendo il pulsante FINISH o definire altre opzioni per la connessione Save settings only, do not launch download now. Salva solo le impostazioni, non iniziare il download adesso. On hold Attesa Transfer scheduled for: (hh/mm/ss) Attesa fino a: (hh/mm/ss) Start Inizio Connect to provider (RAS) Connessione al provider (RAS) Connect to this provider Connessione a questo provider: Disconnect when finished Disconnetti alla fine Disconnect modem on completion Disconnetti il modem quando il mirror finito \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n(informateci degli errori o problemi)\r\n\rSviluppo:\r\nInterfacccia: Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for Italian translations to:\r\nWitold Krakowski (wkrakowski@libero.it) About WinHTTrack Website Copier Informazioni su WinHTTrack Website Copier Please visit our Web page Visita la nostra pagina Web Wizard query La domanda del wizard Your answer: La vostra risposta: Link detected.. stato trovato un collegamento Choose a rule Scegli una regola Ignore this link Ignora questo collegamento Ignore directory Ignora questa cartella Ignore domain Ignora questo dominio Catch this page only Scarica soltanto questa pagina Mirror site Mirror del sito Mirror domain Mirror del dominio Ignore all Ignora tutto Wizard query La domanda del wizard NO NO File File Options Opzioni Log Log Window Finestra Help Aiuto Pause transfer Pausa del trasferimento Exit Esci Modify options Modifica le opzioni View log Visualizza il log View error log Visualizza il log di errori View file transfers Visualizza trasferimenti dei file Hide Nascondi About WinHTTrack Website Copier Informazioni su WinHTTrack Website Copier Check program updates... Verifica gli aggiornamenti del programma... &Toolbar Toolbar &Status Bar Barra di stato S&plit Dividi File File Preferences Opzioni Mirror Aiuto Log Log Window Finestra Help Aiuto Exit Esci Load default options Carica le opzioni di default Save default options Salva le opzioni di default Reset to default options Azzera le opzioni di default Load options... Carica le opzioni... Save options as... Salva le opzioni come... Language preference... Preferenza di lingua... Contents... Indice... About WinHTTrack... Informazioni su WinHTTrack... New project\tCtrl+N Nuovo progetto\tCtrl+N &Open...\tCtrl+O &Apri...\tCtrl+O &Save\tCtrl+S &Salva\tCtrl+S Save &As... Salva &come... &Delete... &Elimina... &Browse sites... &Visita i siti... User-defined structure Struttura definita dall'utente %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\tNome del file senza il tipo (es.: immagine)\n%N\tNome del file, incluso il tipo (es.: immagine)\n%t\tTipo del file (es.: gif)\n%p\tPercorso [senza fine /] (es.: /immagini)\n%h\tIl nome del host (es.: www.someweb.com)\n\n%s?\tVersione corta per il DOS (es.: %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Esempio:\t%h%p/%n.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Proxy settings Preferenze del proxy Proxy address: Indirizzo del proxy Proxy port: Port del proxy Authentication (only if needed) Autenticazione (solo se necessaria) Login Login Password Password Enter proxy address here Inserisci qui il nuovo indirizzo del proxy Enter proxy port here Inserisci qui il port del proxy Enter proxy login Inserisci il login del proxy Enter proxy password Inserisci la password del proxy Enter project name here Inserisci qui il nome del progetto Enter saving path here Inserisci qui il percorso per salvare il progetto Select existing project to update Seleziona da qui un progetto esistente da aggiornare Click here to select path Clicca qui per selezionare il percorso Select or create a new category name, to sort your mirrors in categories Seleziona o crea una nuova categoria HTTrack Project Wizard... Wizard per progetto HTTrack... New project name: Il nome del nuovo progetto: Existing project name: Il nome di un progetto esistente: Project name: Il nome del progetto: Base path: Il percorso base: Project category: Categoria del progetto: C:\\My Web Sites C:\\Mie pagine Web Type a new project name, \r\nor select existing project to update/resume Inserisci il nome del nuovo progetto, \r\no seleziona un progetto esistente per aggiornare/continuare New project Nuovo progetto Insert URL Inserisci l'indirizzo URL: URL: Indirizzo URL: Authentication (only if needed) Identificazione (solo se necessaria) Login Login Password Password Forms or complex links: Formule o collegamenti complessi Capture URL... Preleva l'URL Enter URL address(es) here Inserisci qui l'indirizzo URL Enter site login Inserisci il login del sito Enter site password Inserisci la password del sito Use this capture tool for links that can only be accessed through forms or javascript code Usa questo tool per prelevare i collegamenti ai quali si pu accedere solo tramite formule o collegamenti javascript Choose language according to preference Seleziona la lingua Catch URL! Preleva l'URL! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. Temporaneamente inserisci le seguenti impostazioni per il proxy (copia/incolla l'indirizzo e il port del proxy).\nQuindi, nella tua pagina del browser clicca sul pulsante ok della form, oppure clicca sul collegamento specifico che vuoi prelevare. This will send the desired link from your browser to WinHTTrack. Questo prelever il coolegamento desiderato dal tuo browser a HTTrack. ABORT ANNULLA Copy/Paste the temporary proxy parameters here Copia/incolla qui le impostazioni temporanee del proxy Cancel Annulla Unable to find Help files! Impossibile trovare i file di aiuto Unable to save parameters! Impossibile salvare i parametri! Please drag only one folder at a time Trascina solo una cartella alla volta Please drag only folders, not files Trascina solo una cartella, non un file Please drag folders only Trascina solo una cartella Select user-defined structure? Selezionare la struttura definita dall'utente? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! Assicurati che la stringa definita dall'utente corretta\nSe non corretta, i nomi dei file saranno errati! Do you really want to use a user-defined structure? Vuoi veramente selezionare la struttura definita dall'utente? Too manu URLs, cannot handle so many links!! Troppi URL, il programma non pu servire cos tanti collegamenti! Not enough memory, fatal internal error.. Troppa poca memoria, errore interno fatale... Unknown operation! Operazione sconosciuta! Add this URL?\r\n Aggiungere questo URL?\r\n Warning: main process is still not responding, cannot add URL(s).. Attenzione: il processo principale non risponde, non possibile aggiungere URL. Type/MIME associations Corrispondenze tipo/MIME File types: Tipi di file MIME identity: Identit MIME Select or modify your file type(s) here Seleziona o modifica i tuoi tipi di file qui Select or modify your MIME type(s) here Seleziona o modifica i tuoi tipi MIME qui Go up Vai su Go down Vai gi File download information Informazioni sullo scaricamento dei file Freeze Window Congela la finestra More information: Pi informazioni: Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download Benvenuti nel WinHTTrack Website Copier!\n\nClicca sul pulsante NEXT per iniziare o continuare un progetto File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS Tipi di file con l'estensione:\nNomi di file contenenti:\nQuesto nome di file:\nNomi di cartella contenenti:\nQuesto nome cartella:\nCollegamenti in questo dominio:\nCollegamenti nei domini contenenti:\nCollegamenti da questo host:\nCollegamenti contenenti:\nQuesto collegamento:\nTUTTI I COLLEGAMENTI Show all\nHide debug\nHide infos\nHide debug and infos Mostra tutto\nNascondi il debug\nNascondi le informazioni\nNascondi il debug e le informazioni Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. Struttura del sito (default)\nHtml nel web, immagini/altri file nel web/immagini/\nHtml nel web/html, immagini/altro nel web/immagini\nHtml nel web/, immagini/altro nel web/\nHtml nel web/, immagini/altro nel web/xxx, dove xxx l'estensione del file\nHtml nel web/html, immagini/altro nel web/xxx\nStruttura del sito, senza www.dominio.xxx/\nHtml nel nome_del_sito/,immagini/altri file nel nome_del_sito/immagini/\nHtml nel nome_del_sito/html,immagini/altro nel nome_del file/immagini\nHtml nel nome_del_sito/,immagini/altro nel nome_del_sito/\nHtml nel nome_del_sito/,immagini/altro nel nome_del_sito/xxx\nHtml nel nome_del_sito/html,immagini/altro nel nome_del_sito/xxx\nTutti i file nel web/,con nomi casuali\nTutti i file nel nome_del_sito/,con nomi casuali\nStruttura definita dall'utente.. Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first Soltanto scanning\nSalva file html\nSalva file non-html\nSalva tutti i file (default)\nSalva prima i file HTML Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down Non uscire dalla directory\nPuoi andare gi nella struttura (default)\nPuoi salire\nPuoi sia scendere che salire Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web Rimani nell'indirizzo indicato (default)\nRimani nello stesso dominio\nRimani nello stesso dominio di livello superiore\nVai dovunque sia necessario nel web Never\nIf unknown (except /)\nIf unknown Mai\nSe sconosciuto (eccetto /)\nSe sconosciuto no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules Non seguire robots.txt\nrobots.txt eccetto wizard\nsegui le regole di robots.txt normal\nextended\ndebug normale\navanzato\ndebug Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download Scarica il sito(i) web\nScarica il sito(i) (con richieste)\nScarica file separati\nScarica tutti i siti nelle pagine (mirror multiplo)\nVerifica i collegamenti nelle pagine (test dei bookmark)\n* Continua un download interrotto\n* Aggiorna un download esistente Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL URL Relativo / URL Assoluto (default)\nURL Assoluto / URL Assoluto\nURL Assoluto / URL Assoluto\nURL Originale / URL Originale Open Source offline browser Browser offline open source Website Copier/Offline Browser. Copy remote websites to your computer. Free. Browser offline/programma per copiare i siti. Copia le pagine remote sul tuo computer. Free httrack, winhttrack, webhttrack, offline browser httrack, winhttrack, webhttrack, offline browser URL list (.txt) lista degli URL (.txt) Previous Precedente Next Successivo URLs URLs Warning Attenzione Your browser does not currently support javascript. For better results, please use a javascript-aware browser. Il tuo browser non supporta javascript. Per un risultato migliiore usa un browser con supporto javascript Thank you Grazie You can now close this window Puoi chiudere questa finestra adesso Server terminated Server disconnesso A fatal error has occurred during this mirror Si verificato un errore fatale durante la copia httrack-3.49.5/lang/Greek.txt0000644000175000017500000011172514360553245012732 00000000000000LANGUAGE_NAME Greek LANGUAGE_FILE Greek LANGUAGE_ISO el LANGUAGE_AUTHOR Michael Papadakis (mikepap at freemail dot gr)\r\n LANGUAGE_CHARSET ISO-8859-7 LANGUAGE_WINDOWSID Greek OK Cancel Exit Close Cancel changes Click to confirm Click to get help! ! Click to return to previous screen Click to go to next screen Hide password Save project Close current project? ; Delete this project? ; Delete empty project %s? %s; Action not yet implemented Error deleting this project Select a rule for the filter Enter keywords for the filter - Cancel Add this rule Please enter one or several keyword(s) for the rule - Add Scan Rule Criterion String Add Scan Rules Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi URLs links.\n .\n .\n\n: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Exclude links Links Include link(s) links Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) : GIF, +www.someweb.com/*.gif. \n(+*.gif / -*.gif / GIFs ) Save prefs Matching links will be excluded: links Matching links will be included: links Example: : gif\r\nWill match all GIF files gif\r\n GIF blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' blue\r\n 'blue' 'bluesky-small.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' bigfile.mov\r\n 'bigfile.mov', 'bigfile2.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\n links 'cgi', /cgi-bin/somecgi.cgi cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\n links 'cgi-bin', 'cgi-bin-2' someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb.com\r\n links , www.someweb.com, private.someweb.com . someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. someweb\r\n links , www.someweb.com, www.someweb.edu, private.someweb.otherweb.com . www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.someweb.com\r\n links 'www.someweb.com', 'private.someweb.com'. someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. someweb\r\n links URL, www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html . www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/someweb.html\r\n 'www.test.com/test/someweb.html'. . All links will match links Add exclusion filter Add inclusion filter Existing filters Cancel changes Save current preferences as default values Click to confirm No log files in %s! %s! No 'index.html' file in %s! 'index.html' %s! Click to quit WinHTTrack Website Copier WinHTTrack Website Copier View log files Browse HTML start page End of mirror View log files Browse Mirrored Website New project... ... View error and warning reports View report Close the log file window Info type: : Errors Infos Find Find a word Info log file Warning/Errors log file / Unable to initialize the OLE system OLE WinHTTrack could not find any interrupted download file cache in the specified folder! WinHTTrack cache ! Could not connect to provider receive request connect search ready error Receiving files.. .. Parsing HTML file.. HTML... Purging files.. .. Loading cache in progress.. cache ... Parsing HTML file (testing links).. HTML ( links)... Pause - Toggle [Mirror]/[Pause download] to resume operation - []/[ ] Finishing pending transfers - Select [Cancel] to stop now! - [] ! scanning Waiting for scheduled time.. ... Transferring data.. ... Connecting to provider [%d seconds] to go before start of operation [%d ] Site mirroring in progress [%s, %s bytes] [%s, %s bytes] Site mirroring finished! ! A problem occurred during the mirroring operation\n \n \nDuring:\n \n :\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! \n .\n\n WinHTTrack Website Copier.\n\n WinHTTrack! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! .\n WinHTTrack.\n , .\n\n WinHTTrack! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * ! * *\r\n cache .\r\n cache . , cache.\r\n[: hts-cache/new.*]\r\n\r\n cache ; * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * * *\r\n WinHTTrack . , .\r\n: () () .\r\n=> / proxy ! <= \n\nTip: Click [View log file] to see warning or error messages \n\n: [ ] Error deleting a hts-cache/new.* file, please do it manually hts-cache/new.* , Do you really want to quit WinHTTrack Website Copier? WinHTTrack Website Copier; - Mirroring Mode -\n\nEnter address(es) in URL box - -\n\n () URL - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - () --\n\n () URL - File Download Mode -\n\nEnter file address(es) in URL box - -\n\n () URL - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - link -\n\n () link(s) URL - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - -\n\n () () URL, '' - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - ( ) -\n\n () URL, ''. Log files Path Path - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror - links -\n\n URL () () () links . New project / Import? / ; Choose criterion Maximum link scanning depth link Enter address(es) here () Define additional filtering rules Proxy Name (if needed) Proxy ( ) Proxy Port Port proxy Define proxy settings proxy Use standard HTTP proxy as FTP proxy HTTP proxy, FTP proxy Path Select Path Path Select Path Quit WinHTTrack Website Copier WinHTTrack Website Copier About WinHTTrack WinHTTrack Save current preferences as default values Click to continue Click to define options Click to add a URL URL Load URL(s) from text file URL(s) WinHTTrack preferences (*.opt)|*.opt|| WinHTTrack (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| (*.txt)|*.txt|| File not found! ! Do you really want to change the project name/path? / ; Load user-default options? ; Save user-default options? ; Reset all default options? ; Welcome to WinHTTrack! WinHTTrack! Action: : Max Depth Maximum external depth: Filters (refuse/accept links) : (/ links) : Paths Save prefs Define.. ... Set options.. ... Preferences and mirror options: Project name Add a URL... URL... Web Addresses: (URL) Web: (URL) Stop WinHTTrack? WinHTTrack; No log files in %s! %s! Pause Download? ; Stop the mirroring operation Minimize to System Tray Click to skip a link or stop parsing link Click to skip a link link Bytes saved bytes Links scanned links Time: : Connections: : Running: Hide Transfer rate SKIP Information Files written: : Files updated: : Errors: : In progress: : Follow external links links Test all links in pages links Try to ferret out all links links Download HTML files first (faster) HTML () Choose local site structure Set user-defined structure on disk Use a cache for updates and retries cache Do not update zero size or user-erased files Create a Start Page Create a word database of all html pages html Create error logging and report files Generate DOS 8-3 filenames ONLY DOS 8-3 Generate ISO9660 filenames ONLY for CDROM medias ISO9660, CD Do not create HTML error pages HTML Select file types to be saved to disk Select parsing direction Select global parsing direction Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) URL links ( ) links ( ) Max simultaneous connections File timeout Cancel all links from host if timeout occurs links Minimum admissible transfer rate Cancel all links from host if too slow links Maximum number of retries on non-fatal errors Maximum size for any single HTML file HTML Maximum size for any single non-HTML file HTML Maximum amount of bytes to retrieve from the Web bytes Web Make a pause after downloading this amount of bytes bytes Maximum duration time for the mirroring operation Maximum transfer rate Maximum connections/seconds (avoid server overload) / ( ) Maximum number of links that can be tested (not saved!) links ( !) Browser identity Comment to be placed in each HTML file HTML Back to starting page Save current preferences as default values Click to continue Click to cancel changes Follow local robots rules on sites Links to non-localised external pages will produce error pages links Do not erase obsolete files after update Accept cookies? cookies Check document type when unknown? Parse java applets to retrieve included files that must be downloaded? java Store all files in cache instead of HTML only cache HTML Log file type (if generated) ( ) Maximum mirroring depth from root address Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) / (0, , ) Create a debugging file Use non-standard requests to get round some server bugs Use old HTTP/1.0 requests (limits engine power!) HTTP/1.0 ( !) Attempt to limit retransfers through several tricks (file size test..) ( ...) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) links (www.foo.com==foo.com, http=https ..) Write external links without login/password links / Write internal links without query string links Get non-HTML files related to a link, eg external .ZIP or pictures -HTML link, : .ZIP Test all links (even forbidden ones) links ( ) Try to catch all URLs (even in unknown tags/code) URLs ( tags/) Get HTML files first! HTML! Structure type (how links are saved) ( links) Use a cache for updates cache Do not re-download locally erased files Make an index Make a word database - Log files DOS names (8+3) DOS (8+3) ISO9660 names (CDROM) ISO9660 (CDROM) No error pages Primary Scan Rule Travel mode Global travel mode These options should be modified only exceptionally Activate Debugging Mode (winhttrack.log) (winhttrack.log) Rewrite links: internal / external links: / Flow control Limits Identity HTML footer HTML N# connections Abandon host if error Minimum transfer rate (B/s) Abandon host if too slow Configure Use proxy for ftp transfers proxy ftp TimeOut(s) Persistent connections (Keep-Alive) () Reduce connection time and type lookup time using persistent connections , Retries Size limit Max size of any HTML file (B) HTML Max size of any non-HTML file HTML Max site size Max time Save prefs Max transfer rate Follow robots.txt robots.txt No external pages Do not purge old files Accept cookies cookies Check document type Parse java files java Store ALL files in cache cache Tolerant requests (for servers) ( ) Update hack (limit re-transfers) ( ) URL hacks (join similar URLs) URLs ( ) Force old HTTP/1.0 requests (no 1.1) HTTP/1.0 ( 1.1) Max connections / seconds / Maximum number of links links Pause after downloading.. ... Hide passwords - Hide query strings Links Links Build Experts Only Flow Control Limits Browser ID Scan Rules Spider Log, Index, Cache , , Cache Proxy Proxy MIME Types MIME Do you really want to quit WinHTTrack Website Copier? WinHTTrack Website Copier; Do not connect to a provider (already connected) ( ) Do not use remote access connection Schedule the mirroring operation () Quit WinHTTrack Website Copier WinHTTrack Website Copier Back to starting page Click to start! ! No saved password for this connection! ! Can not get remote connection settings Select a connection provider Start Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. . Save settings only, do not launch download now. , . On hold Transfer scheduled for: (hh/mm/ss) : (hh/mm/ss) Start Connect to provider (RAS) Internet Connect to this provider Disconnect when finished Disconnect modem on completion modem \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n( bug)\r\n\r\n:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for Greek translations to:\r\nMichael Papadakis (mikepap at freemail dot gr) About WinHTTrack Website Copier WinHTTrack Website Copier Please visit our Web page Wizard query Your answer: : Link detected.. link. Choose a rule Ignore this link link Ignore directory Ignore domain domain Catch this page only Mirror site Mirror domain domain Ignore all Wizard query NO File Options Log Window Help Pause transfer Exit Modify options View log View error log View file transfers Hide About WinHTTrack Website Copier WinHTTrack Website Copier Check program updates... ... &Toolbar & &Status Bar & S&plit & File Preferences Mirror Log Window Help Exit Load default options Save default options Reset to default options Load options... ... Save options as... ... Language preference... ... Contents... ... About WinHTTrack... WinHTTrack... New project\tCtrl+N \tCtrl+N &Open...\tCtrl+O &...\tCtrl+O &Save\tCtrl+S &\tCtrl+S Save &As... &... &Delete... &... &Browse sites... & ... User-defined structure %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\t (: image)\r\n%N\t (: image.gif)\r\n%t\t (: gif)\r\n%p\t [ / ] (: /someimages)\r\n%h\t (: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 (128 bits, 32 ascii bytes)\r\n%q\tMD5 (16 bits, 4 ascii bytes)\r\n\r\n%s?\t DOS (: %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif :\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Proxy settings proxy Proxy address: proxy: Proxy port: Port proxy: Authentication (only if needed) ( ) Login Password Enter proxy address here proxy Enter proxy port here port proxy Enter proxy login proxy Enter proxy password proxy Enter project name here Enter saving path here Select existing project to update Click here to select path Select or create a new category name, to sort your mirrors in categories , HTTrack Project Wizard... HTTrack... New project name: : Existing project name: : Project name: : Base path: : Project category: : C:\\My Web Sites C:\\ Type a new project name, \r\nor select existing project to update/resume , \r\n / New project Insert URL URL URL: URL: Authentication (only if needed) ( ) Login Password Forms or complex links: links: Capture URL... URL... Enter URL address(es) here URL () Enter site login Enter site password Use this capture tool for links that can only be accessed through forms or javascript code links javascript Choose language according to preference Catch URL! URL! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. proxy browser (/ proxy port).\n , browser link . This will send the desired link from your browser to WinHTTrack. link browser WinHTTrack. ABORT Copy/Paste the temporary proxy parameters here / proxy Cancel Unable to find Help files! ! Unable to save parameters! ! Please drag only one folder at a time Please drag only folders, not files , Please drag folders only Select user-defined structure? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! ,\n ! Do you really want to use a user-defined structure? ; Too manu URLs, cannot handle so many links!! URLs, links! Not enough memory, fatal internal error.. , ... Unknown operation! ! Add this URL?\r\n URL;\r\n Warning: main process is still not responding, cannot add URL(s).. : process , URL(s)... Type/MIME associations /MIME File types: : MIME identity: MIME: Select or modify your file type(s) here () () Select or modify your MIME type(s) here () MIME () Go up Go down File download information Freeze Window More information: Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download WinHTTrack Website Copier!\n\n \n\n- \n- File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS :\n :\n :\n :\n :\nLinks domain:\nLinks domains :\nLinks :\nLinks :\n link:\n LINKS Show all\nHide debug\nHide infos\nHide debug and infos \n \n \n . . Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. ()\nHtml web/, / web/images/\nHtml web/html, / web/images/\nHtml web/, / web/\nHtml web/, / web/xxx/, xxx \nHtml web/html/, / web/xxx/\n , www.domain.xxx/\nHtml _/, / _/images/\nHtml _/html/, / _/images/\nHtml _/, / _/\nHtml _/, / _/xxx/\nHtml _/html/, / _/xxx/\n web/, (gadget !)\n _/, (gadget !)\n ... Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first \n html\n html\n ()\n html Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down \n ()\n \n Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web ()\n domain\n domain 1 \n Web Never\nIf unknown (except /)\nIf unknown \n ( /)\n no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules robots.txt\nrobots.txt \n robots.txt normal\nextended\ndebug \n\n Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download ()\n () + \n \n ( )\n links ( )\n* \n* Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL URI / URL ()\n URL / URL\n URI / URL\n URL / URL Open Source offline browser Website Copier/Offline Browser. Copy remote websites to your computer. Free. Website Copier/Offline Browser. . -. httrack, winhttrack, webhttrack, offline browser httrack, winhttrack, webhttrack, offline browser URL list (.txt) URL (.txt) Previous Next URLs URLs Warning Your browser does not currently support javascript. For better results, please use a javascript-aware browser. ( ) javascript. , javascript- . Thank you You can now close this window Server terminated A fatal error has occurred during this mirror httrack-3.49.5/lang/Francais.txt0000644000175000017500000011675014360553245013426 00000000000000LANGUAGE_NAME Franais LANGUAGE_FILE Francais LANGUAGE_ISO fr LANGUAGE_AUTHOR Xavier Roche (roche at httrack.com)\r\nRobert Lagadec (rlagadec at yahoo.fr) \r\n LANGUAGE_CHARSET ISO-8859-1 LANGUAGE_WINDOWSID French (Standard) OK Oui Cancel Annuler Exit Quitter Close Fermer Cancel changes Annuler les changements Click to confirm Cliquez pour confirmer Click to get help! Cliquez pour avoir de l'aide! Click to return to previous screen Pour revenir la fentre prcdente Click to go to next screen Pour passer la fentre suivante Hide password Masquer le mot de passe Save project Enregistrer le projet Close current project? Fermer le projet courant? Delete this project? Supprimer ce projet? Delete empty project %s? Supprimer le projet vide %s? Action not yet implemented Cette fonction n'est pas encore disponible Error deleting this project Erreur lors de l'effacement de ce projet Select a rule for the filter Choisissez un critre pour le filtrage Enter keywords for the filter Entrez ici un mot-cl pour le filtrage Cancel Annuler Add this rule Ajouter cette rgle de filtrage Please enter one or several keyword(s) for the rule Entrez un ou plusieurs mot(s)-cl(s) pour la rgle de filtrage Add Scan Rule Ajouter une rgle de filtrage Criterion Critre: String Mot-cl: Add Ajouter Scan Rules Rgles de filtrage Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Utilisez les jokers pour dfinir des critres d'exclusion ou d'inclusion portant sur plusieurs URLs ou liens.\nVous pouvez regrouper les mots-cls sur une mme ligne en les sparant par des espaces.\nExemple: +*.zip -www.*.com,-www.*.edu/cgi-bin/*.cgi Exclude links Liens exclure.. Include link(s) Liens inclure.. Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) Pour inclure tous les fichiers GIF d'un seul site, utilisez par exemple +www.monweb.com/*.gif.\nPour inclure tous les GIFs de tous les sites visits, utilisez +*.gif.\nPour les exclure tous, utilisez -*.gif. Save prefs Enregistrer les options Matching links will be excluded: Les liens rpondant cette rgle seront exclus Matching links will be included: Les liens rpondant cette rgle seront inclus Example: Exemple: gif\r\nWill match all GIF files gif\r\ndtectera tous les fichiers GIF blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' blue\r\ndtectera tous les fichiers contenant le mot blue, comme 'bluesky-small.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' bigfile.mov\r\ndtectera le fichier 'bigfile.mov', mais pas 'bigfile2.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\ndtectera des liens contenant 'cgi', comme /cgi-bin/somecgi.cgi cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\ndtectera par exemple des liens contenant 'cgi-bin', mais pas 'cgi-bin-2' someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb.com\r\ndtectera des liens comme www.someweb.com, private.someweb.com, etc. someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. someweb\r\ndtectera des liens comme www.someweb.com, www.someweb.edu, private.someweb.otherweb.com, etc. www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.someweb.com\r\ndtectera des liens comme www.someweb.com/... (mais pas ceux comme private.someweb.com/..) someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. someweb\r\ndtectera des liens comme www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/someweb.html\r\ndtectera uniquement www.test.com/test/someweb.html.\nNotez que vous avez taper l'adresse complte (URL + Chemin du fichier) All links will match Tous les liens seront dtects Add exclusion filter Ajouter une rgle d'exclusion Add inclusion filter Ajouter une rgle d'inclusion Existing filters Rgles de filtrage actuelles Cancel changes Annuler les changements Save current preferences as default values Enregistrer les rglages courants en tant que rglages par dfaut Click to confirm Cliquez pour confirmer No log files in %s! Aucun fichier journal dans %s! No 'index.html' file in %s! Aucun fichier 'index.html' dans %s! Click to quit WinHTTrack Website Copier Cliquez pour quitter WinHTTrack Website Copier View log files Voir le fichier journal Browse HTML start page Ouvrir l'Index WinHTTrack des sites copis End of mirror Fin de la copie du site View log files Voir le fichier journal Browse Mirrored Website Explorer la copie du site New project... Nouveau projet... View error and warning reports Voir messages d'erreur et d'avertissement View report Voir le rapport de copie Close the log file window Refermer le journal Info type: Entres du journal: Errors Erreurs Infos Infos Find Rechercher Find a word Rechercher un mot Info log file Rapports de copie Warning/Errors log file Journal d'erreurs Unable to initialize the OLE system Impossible d'initialiser le systme OLE WinHTTrack could not find any interrupted download file cache in the specified folder! WinHTTrack WebSite Copier n'a pu trouver aucune trace de copie complte ou partielle de site dans le dossier indiqu Could not connect to provider Impossible d'tablir la connexion receive rception request requte connect connexion search recherche ready prt error erreur Receiving files.. Rception des fichiers Parsing HTML file.. Analyse des liens de la page... Purging files.. Effacement des fichiers qui ne sont plus rpertoris... Loading cache in progress.. Chargement du cache enc cours.. Parsing HTML file (testing links).. Test des liens de la page Pause - Toggle [Mirror]/[Pause download] to resume operation Interruption - Dslectionnez la commande 'Suspendre les tlchargements' pour reprendre (menu 'Copie de site') Finishing pending transfers - Select [Cancel] to stop now! Fin des transferts en cours - Cliquez sur [Annuler] pour terminer immdiatement ! scanning parcours Waiting for scheduled time.. Attente de l'heure programme pour dmarrer Transferring data.. Transfert des donnes.. Connecting to provider Connexion au fournisseur d'accs [%d seconds] to go before start of operation Copie du site en attente (%d secondes) Site mirroring in progress [%s, %s bytes] Copie du site en cours (%s, %s octets) Site mirroring finished! Copie du site termine! A problem occurred during the mirroring operation\n Incident durant la copie du site\n \nDuring:\n Durant:\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! Voyez le fichier journal au besoin\n\nCliquez sur TERMINER pour quitter WinHTTrack\n\nMerci d'utiliser WinHTTrack! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! la copie du site est termine\nCliquez sur OK pour quitter WinHTTrack\nConsultez au besoin les fichiers journaux pour vrifier que tout s'est bien pass\n\nMerci d'utiliser WinHTTrack! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * COPIE INTERROMPUE! * *\r\nLe cache temporaire actuel est ncessaire pour toute mise jour et ne contient que les donnes tlcharges durant la prsente session interrompue.\r\nIl est possible que le cache prcdent contienne des donnes plus compltes; si vous ne voulez pas perdre ces donnes, vous devez le restaurer et effacer le cache actuel.\r\n[Note: Cette opration peut tre facilement effectue ici en effacant les fichiers hts-cache/new.*]\r\n\r\nPensez-vous que le cache prcdent pourrait contenir des informations plus compltes, et voulez-vous le restaurer? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * ERREUR DE COPIE! * *\r\nHTTrack a dtect que la copie courante tait vide. Si il s'agissait d'une mise jour, l'ancienne copie a t restaure.\r\nRaison: soit la (les) premire(s) page(s) n'ont pu tre tlcharges, soit un problme de connexion est survenu.\r\n=> Vrifiez que le site existe toujours, et/ou vrifiez les rglages du proxy! <= \n\nTip: Click [View log file] to see warning or error messages \nConseil: slectionnez la commande 'Voir le fichier journal' pour visionner les messages d'erreur et d'avertissement Error deleting a hts-cache/new.* file, please do it manually Erreur lors de l'effacement d'un fichier hts-cache/new.*, veuillez l'effacer manuellement Do you really want to quit WinHTTrack Website Copier? Voulez-vous vraiment quitter WinHTTrack Website Copier? - Mirroring Mode -\n\nEnter address(es) in URL box - Mode de copie de site automatique -\n\nUtilisez la bote de dialogue pour entrer vos adresses URLs. - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - Mode de copie de site interactive (questions) -\n\nUtilisez la bote de dialogue pour entrer vos adresses URLs. - File Download Mode -\n\nEnter file address(es) in URL box - Mode tlchargement de fichiers -\n\nUtilisez la bote de dialogue pour entrer vos adresses de fichiers. - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - Mode test de liens -\n\nUtilisez la bote de dialogue pour entrer les adresses des pages contenant les liens tester. - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Mode mise jour d'une copie de site -\n\nVrifiez les adresses URLs dans la liste, vrifiez les options au besoin, puis cliquez sur 'SUIVANT'. - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Mode reprise d'une copie de site interrompue -\n\nVrifiez les adresses URLs dans la liste, vrifiez les options au besoin, puis cliquez sur 'SUIVANT'. Log files Path Chemin des fichiers journaux Path Chemin - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror - Mode copie de sites depuis des liens -\n\nUtilisez la bote de dialogue pour entrer les adresses des pages contenant les liens aspirer. New project / Import? Nouveau projet / importer? Choose criterion Choisissez un type d'action Maximum link scanning depth Profondeur maximale pour l'analyse des liens Enter address(es) here Entrez les adresses ici Define additional filtering rules Dfinir des rgles de filtrage supplmentaires Proxy Name (if needed) Nom du serveur proxy si ncessaire Proxy Port Port du serveur proxy Define proxy settings Prciser les paramtres du serveur proxy Use standard HTTP proxy as FTP proxy Utiliser le serveur proxy HTTP standard comme serveur proxy FTP Path Chemin Select Path Choisissez le chemin Path Chemin Select Path Choisissez le chemin Quit WinHTTrack Website Copier Quittter WinHTTrack Website Copier About WinHTTrack A propos de WinHTTrack Save current preferences as default values Enregistrer ces rglages comme rglages par dfaut Click to continue Cliquez pour continuer Click to define options Cliquez pour dfinir les options Click to add a URL Cliquez pour ajouter une adresse URL Load URL(s) from text file Importer des adresses URL depuis un fichier texte WinHTTrack preferences (*.opt)|*.opt|| Options de rglage de WinHTTrack (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| Fichier texte avec liste d'adresses (*.txt)|*.txt|| File not found! Fichier introuvable! Do you really want to change the project name/path? Voulez-vous vraiment changer le nom/chemin du projet? Load user-default options? Charger la configuration personnalise par dfaut? Save user-default options? Enregistrer en tant que configuration personnalise par dfaut? Reset all default options? Effacer toutes les options par dfaut? Welcome to WinHTTrack! Bienvenue dans WinHTTrack Website Copier! Action: Action: Max Depth Profondeur maximale: Maximum external depth: Profondeur exterieure: Filters (refuse/accept links) : Rgles de filtrage (inclure/exclure des liens) : Paths Chemins Save prefs Enregistrer les options actuelles Define.. Dfinir... Set options.. Dfinir les options... Preferences and mirror options: Paramtres de la copie du site Project name Nom du projet Add a URL... Ajouter... Web Addresses: (URL) Adresse Web: (URL) Stop WinHTTrack? Stopper WinHTTrack? No log files in %s! Aucun fichier journal dans %s! Pause Download? Suspendre la copie du site? Stop the mirroring operation Arrter la copie du site? Minimize to System Tray Minimiser en barre systme Click to skip a link or stop parsing Cliquez pour sauter un lien ou interrompre sa copie Click to skip a link Cliquez pour sauter un lien Bytes saved Octets crits: Links scanned Liens parcourus: Time: Temps: Connections: Connexions: Running: En cours: Hide Minimiser Transfer rate Taux transfert: SKIP PASSER Information Informations Files written: Fichiers crits: Files updated: Fichiers mis jour: Errors: Erreurs: In progress: En cours: Follow external links Rcuprer les fichiers jusque sur les liens extrieurs Test all links in pages Tester tous les liens prsents dans les pages Try to ferret out all links Essayer de reprer tous les liens Download HTML files first (faster) Tlcharger d'abord les fichiers HTML (plus rapide) Choose local site structure Choisir la structure de site localis Set user-defined structure on disk Dfinir les paramtres de la structure personnalise Use a cache for updates and retries Utiliser un cache pour les mises jour et reprises Do not update zero size or user-erased files Ne pas rcuprer les fichiers dj prsents localement quand ils sont de taille nulle ou ont t effacs par l'utilisateur Create a Start Page Crer une page de dmarrage Create a word database of all html pages Crer une base smantique des pages html Create error logging and report files Crer des fichiers journaux pour les messages d'erreur et d'avertissement Generate DOS 8-3 filenames ONLY Ne crer QUE des noms de fichiers au format court 8-3 Generate ISO9660 filenames ONLY for CDROM medias Ne crer QUE des noms de fichiers au format ISO9660 poru les mdias type CDROM Do not create HTML error pages Ne pas crer les fichiers journaux d'erreur HTML Select file types to be saved to disk Slection des types de fichier aspirer Select parsing direction Mode de parcours des liens sur le site Select global parsing direction Limites de la zone globale d'exploration Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) Type de rcriture des URL pour les liens internes (ceux qui sont tlchargs) et les liens externes (ceux qui ne sont pas tlchargs) Max simultaneous connections Nombre maximal de connexions File timeout Attente maximale pour un fichier Cancel all links from host if timeout occurs Annuler tous les liens sur un domaine en cas d'attente excessive Minimum admissible transfer rate Taux de transfert minimal tolr Cancel all links from host if too slow Annuler tous les liens sur un domaine en cas de transfert trop lent Maximum number of retries on non-fatal errors Nombre maximum d'essais en cas d'erreur non fatale Maximum size for any single HTML file Taille maximale pour une page HTML Maximum size for any single non-HTML file Taille maximale pour un fichier non HTML Maximum amount of bytes to retrieve from the Web Taille totale maximale pour la copie locale du site Make a pause after downloading this amount of bytes Faire une pause aprs avoir tlcharg cette quantit de donnes Maximum duration time for the mirroring operation Temps total maximum pour une copie de site Maximum transfer rate Taux de transfert maximum Maximum connections/seconds (avoid server overload) Nombre max. de connexions/secondes (limite la surcharge des serveurs) Maximum number of links that can be tested (not saved!) Nombre maximum des liens qui peuvent tre tests (pas sauvs!) Browser identity Identifiants du Navigateur Internet Comment to be placed in each HTML file Commentaire de page plac dans chaque fichier HTML Languages accepted by the browser Langues accepte par le navigateur Additional HTTP headers to be sent in each requests En-ttes HTTP additionnels envoyer dans chaque requte Back to starting page Retour la page de dmarrage Save current preferences as default values Enregistrer les rglages courants comme paramtres par dfaut Click to continue Cliquez pour continuer Click to cancel changes Cliquez pour annuler Follow local robots rules on sites Suivi des rgles locales des robots sur les sites Links to non-localised external pages will produce error pages Les liens vers des pages hors du domaine d'exploration engendreront des pages locales avec message d'erreur Do not erase obsolete files after update Ne pas effacer les fichiers obsoltes aprs une mise jour Accept cookies? Accepter les cookies? Check document type when unknown? Vrifier le type du document quand il est inconnu? Parse java applets to retrieve included files that must be downloaded? Analyser les applets java pour rcuprer les fichiers rpondant aux critres de copie? Store all files in cache instead of HTML only Stockage de TOUS les fichiers en cache (et non pas uniquement les HTML) Log file type (if generated) Type du fichier journal (s'il est cr) Maximum mirroring depth from root address Profondeur maximale de la copie locale du site (mesure partir de l'adresse de dpart) Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) Profondeur maximale de la copie pour les adresse externes/interdites (0, soit aucune, par dfaut) Create a debugging file Crer un fichier de dbogage Use non-standard requests to get round some server bugs Essayer d'viter les bugs de certains serveurs en utilisant des requtes non standard Use old HTTP/1.0 requests (limits engine power!) L'utilisation des anciennes requtes HTTP/1.0 limite les capacits du moteur de capture! Attempt to limit retransfers through several tricks (file size test..) Essayer de limiter les retransferts via certains trucs (test de taille de fichier..) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Essayer de limiter le nombre de liens en ignorant les liens similaires (www.foo.com==foo.com, http=https ..) Write external links without login/password Ecrire les liens externes sans login/mot de passe Write internal links without query string Ecrire les liens internes sans 'query string' Get non-HTML files related to a link, eg external .ZIP or pictures Capturer les fichiers non HTML proches (ex: fichiers ZIP situs l'extrieur) Test all links (even forbidden ones) Tester tous les liens (mme ceux exclus par les rgles) Try to catch all URLs (even in unknown tags/code) Essayer de dtecter tous les liens (y compris tags inconnus/code javascript) Get HTML files first! Tlcharger les HTML en premier! Structure type (how links are saved) Type de structure locale (manire dont les liens sont enregistrs) Use a cache for updates Utiliser un cache pour les mises jour Do not re-download locally erased files Ne pas tenter de rcuprer les fichiers effacs localement Make an index Constituer un Index Make a word database Faire une base smantique Log files Fichiers journaux DOS names (8+3) Noms DOS (8+3) ISO9660 names (CDROM) Noms ISO9660 (CDROM) No error pages Pas de pages d'erreur Primary Scan Rule Rgle de filtrage principale Travel mode Mode de parcours Global travel mode Mode de parcours global These options should be modified only exceptionally Options ne modifier qu'exceptionnellement Activate Debugging Mode (winhttrack.log) Activer le mode de dbogage (winhttrack.log) Rewrite links: internal / external Rcriture des liens: internes / externes Flow control Contrle du flux Limits Limites Identity Identification HTML footer En-tte HTML Languages Langues Additional HTTP Headers En ttes HTTP additionnels N# connections Nombre de connexions Abandon host if error Abandon en cas d'erreur Minimum transfer rate (B/s) Taux de transfert minimum (octets/s) Abandon host if too slow Abandon en cas de transfert trop lent Configure Configurer Use proxy for ftp transfers Utiliser le serveur proxy pour les transferts FTP TimeOut(s) TimeOut(s) Persistent connections (Keep-Alive) Connexions persistantes (Keep-Alive) Reduce connection time and type lookup time using persistent connections Rduire les temps de connexion et de vrification de type en utilisant des connexions permanentes Retries Essais Size limit Limite en taille Max size of any HTML file (B) Taille maximale des fichiers HTML (B) Max size of any non-HTML file Taille maximale des autres fichiers Max site size Taille maximale du site Max time Temps de capture maximal Save prefs Enregistrer les options courantes Max transfer rate Taux maximal Follow robots.txt Suivre les rgles prsentes dans le fichier 'robots.txt' No external pages Pas de pages externes Do not purge old files Pas de purge des anciens fichiers Accept cookies Accepter les cookies Check document type Vrifier les types de document Parse java files Analyser les fichiers java Store ALL files in cache TOUT stocker en cache Tolerant requests (for servers) Requtes tolrantes (pour serveurs) Update hack (limit re-transfers) Mise jour force (limite les retransferts) URL hacks (join similar URLs) Fusion des liens (fusionner les liens similaires) Force old HTTP/1.0 requests (no 1.1) Anciennes requtes HTTP/1.0 (PAS de requtes HTTP/ 1.1) Max connections / seconds Nb. max connexions / secondes Maximum number of links Nombre max de liens Pause after downloading.. Suspendre aprs la copie de.. Hide passwords Masquer les mots de passe Hide query strings Cacher les 'query strings' Links Liens Build Structure Experts Only Pour Experts Flow Control Contrle du flux Limits Limites Browser ID Navigateur Internet Scan Rules Rgles de filtrage Spider Fouineur Log, Index, Cache Journal, Index, Cache Proxy Serveur proxy MIME Types Types MIME Do you really want to quit WinHTTrack Website Copier? Voulez-vous vraiment quitter WinHTTrack Website Copier? Do not connect to a provider (already connected) Pas de connexion un fournisseur d'accs (dja connect) Do not use remote access connection Ne pas utiliser l'accs distance Schedule the mirroring operation Programmer une copie du site Quit WinHTTrack Website Copier Quitter WinHTTrack Website Copier Back to starting page Retour la page de dmarrage Click to start! Cliquez pour dmarrer! No saved password for this connection! Pas de mot de passe enregistr pour cette connexion! Can not get remote connection settings Impossible d'obtenir les paramtres de connexion Select a connection provider Slectionnez ici un fournisseur d'accs auquel vous connecter Start Dmarrer... Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. Prcisez les OPTIONS de connexion si ncessaire,\npuis pressez TERMINER pour commencer la copie du site Save settings only, do not launch download now. Enregistrer uniquement les rglages, ne pas lancer le tlchargement maintenant. On hold Temporisation Transfer scheduled for: (hh/mm/ss) Attendre avant de commencer jusqu': (hh/mm/ss) Start DEMARRER! Connect to provider (RAS) Fournisseur d'accs Connect to this provider Se connecter ce fournisseur d'accs Disconnect when finished Dconnecter la fin de l'opration Disconnect modem on completion Dconnecter le modem lorsque l'opration sera finie \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n(signalez-nous tout bug ou problme)\r\n\r\nDveloppement:\r\nInterface (Windows): Xavier Roche\r\nMoteur: Xavier Roche\r\nParseurClassesJava: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMERCI pour la relecture :\r\nRobert Lagadec About WinHTTrack Website Copier A propos de WinHTTrack Website Copier Please visit our Web page Visitez notre site Web! Wizard query Question du Compagnon WinHTTrack Your answer: Votre rponse: Link detected.. Un lien a t dtect Choose a rule Choisir une rgle: Ignore this link Ignorer ce lien Ignore directory Ignorer ce dossier Ignore domain Ignorer ce domaine Catch this page only Ne capturer QUE cette page Mirror site Copie du site Mirror domain Copie du domaine entier Ignore all Tout ignorer Wizard query Question du Compagnon WinHTTrack NO NON File Fichier Options Options Log Fichier journal Window Fentres Help Aide Pause transfer Suspendre les tlchargements Exit Quitter Modify options Modifier les options View log Voir le fichier journal View error log Voir le fichier d'erreur View file transfers Voir les fichiers tlchargs Hide Minimiser About WinHTTrack Website Copier A propos... Check program updates... Rechercher les mises jour de WinHTTrack... &Toolbar Barre d'outils &Status Bar Barre d'tat S&plit Fractionner File Fichier Preferences Options Mirror Copie de site Log Journal Window Fentres Help Aide Exit Quitter Load default options Utiliser les options par dfaut Save default options Enregistrer en tant qu'options par dfaut Reset to default options Initialiser les options par dfaut Load options... Charger les options Save options as... Enregistrer les options sous... Language preference... Choix de la langue Contents... Index... About WinHTTrack... A propos de WinHTTrack Website Copier New project\tCtrl+N Nouveau projet\tCtrl+N &Open...\tCtrl+O &Ouvrir...\tCtrl+O &Save\tCtrl+S En®istrer\tCtrl+S Save &As... Enregistrer &sous... &Delete... &Effacer... &Browse sites... &Explorer sites... User-defined structure Dfinir une structure personnalise %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\tNom du fichier sans ext. (ex: image)\r\n%N\tNom du fichier avec extension (ex: image.gif)\r\n%t\tExtension (ex: gif)\r\n%p\tChemin [sans dernier /] (ex: /someimages)\r\n%h\tNom du serveur (ex: www.someweb.com)\r\n%M\tURL MD5 (128 bits, 32 ascii bytes)\r\n%Q\tquery string MD5 (128 bits, 32 ascii bytes)\r\n%q\tsmall query string MD5 (16 bits, 4 ascii bytes)\r\n\r\n%s?\tVersion courte DOS (ex: %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Exemple:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Proxy settings Options du serveur proxy Proxy address: Adresse du serveur proxy Proxy port: Port du serveur proxy Authentication (only if needed) Identification (si ncessaire) Login Nom d'utilisateur (Login) Password Mot de passe Enter proxy address here Entrez ici l'adresse du serveur proxy Enter proxy port here Entrez ici le port du serveur proxy Enter proxy login Entrez le nom d'utilisateur du serveur proxy Enter proxy password Entrez le mot de passe du serveur proxy Enter project name here Entrez ici le nom du projet Enter saving path here Entrez ici le chemin o vous voulez enregistrer le projet Select existing project to update Slectionnez ici le projet existant mettre jour Click here to select path Cliquez ici pour slectionner le chemin directement dans l'arborescence de votre disque dur Select or create a new category name, to sort your mirrors in categories Slectionnez ou crez une nouvelle catgorie, pour trier vos projets l'aide de catgories HTTrack Project Wizard... Compagnon du projet WinHTTrack New project name: Nom du nouveau projet: Existing project name: Nom du projet existant: Project name: Nom du projet: Base path: Chemin de base: Project category: Catgorie du projet: C:\\My Web Sites C:\\Mes Sites Web Type a new project name, \r\nor select existing project to update/resume Entrez le nom d'un nouveau projet, \r\nou slectionnez un projet existant pour le mettre jour/le reprendre New project Nouveau projet Insert URL Insrez une adresse URL URL: Adresse URL Authentication (only if needed) Identification (si ncessaire) Login Nom d'utilisateur (Login) Password Mot de passe Forms or complex links: Formulaires ou liens complexes: Capture URL... Capturer l'URL... Enter URL address(es) here Entrez ici l'adresse URL Enter site login Entrez votre nom d'utilisateur pour le site Enter site password Entrez votre mot de passe pour le site Use this capture tool for links that can only be accessed through forms or javascript code Utilisez cet outil pour capturer des liens accessibles uniquement via formulaires ou liens javascript Choose language according to preference Slectionnez votre langue ici Catch URL! Capturer cette adresse URL! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. Veuillez fixer temporairement les rglages proxy de votre navigateur sur les rglages ci-dessous (copiez/collez l'adresse proxy et le port).\nEnsuite, dans votre navigateur, cliquez sur le bouton 'submit' du formulaire, ou cliquez sur le lien spcifique que vous voulez aspirer. This will send the desired link from your browser to WinHTTrack. Cela enverra le lien concern de votre navigateur vers WinHTTrack ABORT ANNULER Copy/Paste the temporary proxy parameters here Copier/collez les rglages temporaires du proxy ici Cancel Annuler Unable to find Help files! Impossible de trouver les fichiers d'aide! Unable to save parameters! Impossible d'enregistrer les paramtres! Please drag only one folder at a time Veuillez ne dposer qu'un dossier la fois Please drag only folders, not files Veuillez dposer un dossier, pas un fichier Please drag folders only Ne dposez que des dossiers Select user-defined structure? Choisir une structure personnalise pour la copie du site? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! Vrifiez que la chane personnalise est correcte\nSi elle ne l'est pas, les noms de fichiers seront errons! Do you really want to use a user-defined structure? Voulez-vous vraiment slectionner une structure personnalise? Too manu URLs, cannot handle so many links!! Trop d'adresses URLs, impossible de prendre en charge autant de liens!! Not enough memory, fatal internal error.. Pas assez de mmoire, erreur interne fatale... Unknown operation! Opration inconnue! Add this URL?\r\n Ajouter cette adresse URL?\r\n Warning: main process is still not responding, cannot add URL(s).. Attention: le processus principal ne rpond toujours pas, impossible d'ajouter ces URLs... Type/MIME associations Correspondances type/MIME File types: Types de fichiers: MIME identity: Correspondance MIME: Select or modify your file type(s) here Slectionnez ou modifiez le(s) type(s) de fichiers ici Select or modify your MIME type(s) here Slectionnez ou modifiez les type(s) MIME correspondant(s) ici Go up Monter Go down Descendre File download information Informations sur les fichiers tlchargs Freeze Window Figer la fentre More information: Plus d'informations: Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download Bienvenue dans WinHTTrack Website Copier!\n\nVeuillez cliquer sur le bouton SUIVANT\n\n- pour dmarrer un nouveau projet\n- ou reprendre un projet existant File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS Fichiers de type:\nFichiers contenant:\nCe fichier:\nNoms de dossiers contenant:\nCe dossier:\nLiens sur ce domaine:\nLiens sur un domaine contenant:\nLiens de ce serveur:\nLiens contenant:\nCe lien:\nTOUS LES LIENS Show all\nHide debug\nHide infos\nHide debug and infos Tout montrer\nCacher infos de dbogage\nCacher infos gnrales\nCacher dbogage et infos Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. Structure du site (par dfaut)\nHtml dans web/, images/autres dans web/images/\nHtml dans web/html, images/autres dans web/images\nHtml dans web/, images/autres dans web/\nHtml dans web/, images/autres dans web/xxx, o xxx est le type\nHtml dans web/html, images/autres dans web/xxx\nStructure du site, sans www.domaine.xxx/\nHtml dans site_name/, images/autres dans nom_site/images/\nHtml dans nom_site/html, images/autres dans nom_site/images\nHtml dans site_name/, images/autres dans nom_site/\nHtml dans nom_site/, images/autres dans nom_site/xxx\nHtml dans nom_site/html, images/autres dans nom_site/xxx\nTous les fichiers dans web/, avec des noms alatoires (gadget !)\nTous les fichiers dans nom_site/, avec des noms alatoires (gadget !)\nStructure dfinie par l'utilisateur.. Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first Analyse des liens uniquement\nEnregistrer les fichiers HTML\nEnregistrer les fichiers non-HTML\nEnregistrer tous les fichiers (par dfaut)\nEnregistrer d'abord les fichiers HTML Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down Rester sur le mme rpertoire\nPeut descendre (dfaut)\nPeut monter\nPeut descendre & monter Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web Rester la mme adresse (par dfaut)\nRester sur le mme domaine\nRester sur le mme TLD\nParcours libre sur tout le Web Never\nIf unknown (except /)\nIf unknown Jamais\nSi inconnu (sauf /)\nSi inconnu no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules pas de rgles robots.txt\nrgles robots.txt sauf filtres\nsuivre les rgles robots.txt normal\nextended\ndebug normal\ntendu\ndbogage Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download Copie automatique de site(s) Web\nCopie interactive de site(s) Web (questions)\nTlcharger des fichiers spcifiques\nAspirer tous les sites dans les pages (miroirs multiples)\nTester les liens dans les pages (test de signet)\n* Reprendre une copie interrompue\n* Mettre jour une copie existante Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL URI relative / URL absolue (par dfaut)\nURL absolue / URL absolue\nURI absolue / URL absolue\nURL originale / URL originale Open Source offline browser Aspirateur de Sites Web Open Source Website Copier/Offline Browser. Copy remote websites to your computer. Free. Aspirateur de sites/Navigateur hors ligne. Copiez des sites web sur votre PC. Libre. httrack, winhttrack, webhttrack, offline browser httrack, winhttrack, webhttrack, aspirateur de sites web URL list (.txt) Liste d'URLs (.txt) Previous Prcdent Next Suivant URLs URLs Warning Attention Your browser does not currently support javascript. For better results, please use a javascript-aware browser. Votre navigateur ne comprend pas actuellement le javascript. Pour de meilleurs rsultats, utilisez un navigateur compatible avec le javascript. Thank you Merci You can now close this window Vous pouvez maintenant fermer cette fentre Server terminated Serveur arrt A fatal error has occurred during this mirror Une erreur critique est intervenue durant l'aspiration View Documentation Lire la documentation Go To HTTrack Website Visiter le site de HTTrack Go To HTTrack Forum Visiter le forum de HTTrack View License Lire la license Beware: you local browser might be unable to browse files with embedded filenames Attention: il se pourrait que votre navigateur soit incapable de lire les fichiers contenant des espaces Recreated HTTrack internal cached resources Cache des ressources interne recr Could not create internal cached resources Impossible de crer le cache des ressources interne Could not get the system external storage directory Impossible de localuser le systme de stockage externe Could not write to: Impossible d'crire dans: Read-only media (SDCARD) Mdia en lecture seule (SDCARD) No storage media (SDCARD) Pas de mdia (SDCARD) HTTrack may not be able to download websites until this problem is fixed Il se peut que HTTrack soit incapable de tlcharger des sites tant que ce problme n'est pas rgl HTTrack: mirror '%s' stopped! HTTrack: miroir '%s' stopp! Click on this notification to restart the interrupted mirror Cliquez sur cette notification pour redmarrer la copie interrompue HTTrack: could not save profile for '%s'! HTTrack: impossible de sauver le profil pour '%s' Build a complete RFC822 mail (MHT/EML) archive of the mirror Construire une archive email complte (MHT/EML) au format RFC822 HTTP referer to be sent for initial URLs Champ HTTP referer a envoyer pour les URL initiales Build a mail archive Construire une archive mail Default referer URL Champ referer par dfaut httrack-3.49.5/lang/Finnish.txt0000644000175000017500000010450114360553245013265 00000000000000LANGUAGE_NAME Finnish LANGUAGE_FILE Finnish LANGUAGE_ISO fi LANGUAGE_AUTHOR Mika Khknen (mika.kahkonen at mbnet.fi) LANGUAGE_CHARSET ISO-8859-1 LANGUAGE_WINDOWSID Finnish OK OK Cancel Peruuta Exit Poistu Close Sulje Cancel changes Peruuta muutokset Click to confirm Hyvksy Click to get help! Apua! Click to return to previous screen Palaa edelliseen ruutuun Click to go to next screen Mene seuraavaan ruutuun Hide password Ktke salasana Save project Tallenna projekti Close current project? Sulje nykyinen projekti? Delete this project? Poista projekti? Delete empty project %s? Poista tyhj projekti %s? Action not yet implemented Toimintoa ei toteutettu viel Error deleting this project Virhe poistettaessa projektia Select a rule for the filter Valitse suodattimen snt Enter keywords for the filter Kirjoita suodattimen avainsanat Cancel Peruuta Add this rule Lis snt Please enter one or several keyword(s) for the rule Valitse yksi tai useampi avainsana snnksi Add Scan Rule Lis lukusnt Criterion Kriteeri String Teksti Add Lis Scan Rules Lukusnnt Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Kyt jokerimerkkej sisllyttksesi URL:i tai linkkej.\nVoit kirjoittaa useita lukujonoja samalle riville.\nKyt vlilynti erottelijana.\n\nEsimerkki: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Exclude links Hylk linkkej Include link(s) Sisllyt linkkej Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) Vinkki: Saadaksesi KAIKKI gif-tiedostot, kirjoita thn tapaan: +www.jokin.fi/*.gif. \n(+*.gif / -*.gif sisllytt/hylk KAIKKi giffit kaikilta sivuilta) Save prefs Tallenna asetukset Matching links will be excluded: Sopivat linkit hyltn: Matching links will be included: Sopivat linkit sisllytetn: Example: Esimerkki: gif\r\nWill match all GIF files gif\r\nSopii kaikiin gif-tiedostoihin blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' sini\r\nLyt kaikki tiedostot, joissa on 'sini', mys sanan keskelt kuten 'sinitaivas_pieni.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' iso.mov\r\nSopii tiedostoon 'iso.mov', muttei tiedostoon 'iso2.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\nLyt linkit, joiden kansion nimi sislt tekstin 'cgi' kuten /cgi-bin/jokincgi.cgi cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\nLyt linkit, joiden kansion nimess on vain teksti 'cgi-bin' (mutta ei cgi-bin-2, esimerkiksi) someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. jokinnetti.fi\r\nLyt linkit, jotka sisltvt tekstin 'jokinnetti.fi', esimerkiksi www.jokinnetti.fi, yksityinen.jokinnetti.fi jne. someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. jokinnetti\r\nLyt linkit, joka sislt tmn tekstin, kuten www.jokinnetti.fi, www.jokinnetti.eu, yksityinen.jokinnetti.toinennetti.fi jne. www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.jokinnetti.fi\r\nLyt linkit, joissa on 'www.jokinnetti.fi' (mutta ei linkkej yksityinen.jokinnetti.fi/...) someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. jokinnetti\r\nLyt kaikki linkit, jotka sisltvt tmn tekstin, kuten www.jokinnetti.fi/..., www.testi.abc/fromjokinnetti/index.html, www.testi.abc/test/jokinnetti.html jne. www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.testi.com/test/jokinnetti.html\r\nLyt vain tiedoston 'www.testi.com/test/jokinnetti.html'. Huomaa, ett sinun pit kirjoittaa koko polku (URL + paikan polku) All links will match Kaikki linkit sopii Add exclusion filter Lis hylkv suodatin Add inclusion filter Lis sisllyttv suodatin Existing filters Suodattimet Cancel changes Peruuta muutokset Save current preferences as default values Tallenna nykyiset asetukset vakioarvoiksi Click to confirm Hyvksy No log files in %s! Ei lokitiedostoja: %s! No 'index.html' file in %s! Ei 'index.html'-tiedostoa: %s! Click to quit WinHTTrack Website Copier Poistu WinHTTrack Website Copierista View log files Nyt lokitiedostot Browse HTML start page Selaa HTML-alkusivua End of mirror Peilin loppu View log files Nyt lokitiedostot Browse Mirrored Website Selaa peilisivua New project... Uusi projekti... View error and warning reports Nyt virhe- ja varoitusraportit View report Nyt raportti Close the log file window Sulje lokitiedostoikkuna Info type: Infotyyppi: Errors Virheet Infos Infot Find Etsi Find a word Etsi sana Info log file Infolokitiedosto Warning/Errors log file Varoitukset/virheet -loki Unable to initialize the OLE system Ei voi alustaa OLE-jrjestelm WinHTTrack could not find any interrupted download file cache in the specified folder! WinHTTrack ei voi lyt keskeytetty latausta mritetyst kansiosta! Could not connect to provider Ei voi yhdist tarjoajaan receive vastaanota request kutsu connect yhdist search etsi ready valmis error virhe Receiving files.. Vastaanottaa tiedostoja... Parsing HTML file.. Parsii HTML-tiedostoa... Purging files.. Puhdistaa tiedostoja... Loading cache in progress.. Vlimuistin lataus kynniss... Parsing HTML file (testing links).. Parsii HTML-tiedostoa (testaa linkkej)... Pause - Toggle [Mirror]/[Pause download] to resume operation Pysytys - Vaihda [Peili]/[Pysyt lataus] jatkaaksesi operaatiota Finishing pending transfers - Select [Cancel] to stop now! Ptt avoimia siirtoja - Valitse [Peruuta] lopettaaksesi nyt! scanning lukee Waiting for scheduled time.. Odottaa ajoitettua hetke... Transferring data.. Siirt tietoa... Connecting to provider Yhdist tarjoajaan [%d seconds] to go before start of operation [%d sekuntia] operaation alkuun Site mirroring in progress [%s, %s bytes] Sivun peilaus kynniss [%s, %s tavua] Site mirroring finished! Sivun peilaus valmis! A problem occurred during the mirroring operation\n Ongelma peilausoperaation aikana\n \nDuring:\n \nAikana:\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! \nKatso lokitiedostoa tarvittaessa.\n\nPaina VALMIS poistuaksesi WinHTTrack Website Copierista.\n\nKiitoksia WinHTTrackin kytst! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! Peilausoperaatio valmis.\nPaina poistu sulkeaksesi WinHTTrackin.\nKatso lokitiedosto(j)a varmistaaksesi, ett kaikki on kunnossa.\n\nKiitoksia WinHTTrackin kytst! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * PEILI KESKEYTETTY! * *\r\nNykyist vlimuistia tarvitaan pivitysoperaatioihin ja se sislt tietoa vain sken keskeytetyst imuroinnista.\r\nAiempi vlimuisti saattaa sislt tydellisemp tietoa; jos et halua menett tt tietoa, sinun pit palauttaa se ja poistaa nykyinen vlimuisti.\r\n[Huomaa: Tmn voi helposti tehd nyt poistamalla hts-cache/new.*-tiedostot]\r\n\r\nLuuletko, ett edellinen vlimuisti sisltisi tydellisemp tietoa, ja ett haluat palauttaa sen? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * PEILIVIRHE! * *\r\nHTTrack huomasi, ett nykyinen peili on tyhj. Jos se oli pivitys, edellinen peli on palautettu.\r\nSyy: ensimmiset sivut eivt lytyneet tai tapahtui yhteysvirhe.\r\n=> Varmista ett nettisivu on yh olemassa ja tarkista vlityspalvelinasetuksesi! <= \n\nTip: Click [View log file] to see warning or error messages \n\nVinkki: Paina [Nyt lokitiedosto] nhdksesi varoitus- ja virheviestit Error deleting a hts-cache/new.* file, please do it manually Virhe hts-cache/new.* -tiedostojen poistamisessa, tee se itse. Do you really want to quit WinHTTrack Website Copier? Haluatko varmasti poistua WinHTTrack Website Copierista? - Mirroring Mode -\n\nEnter address(es) in URL box - Peilaustapa -\n\nKirjoita osoitteet URL-laatikkoon - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - Vuorovaikutteisen velhon tapa (kysymyksi) -\n\nKirjoita osoitteet URL-laatikkoon - File Download Mode -\n\nEnter file address(es) in URL box - Tiedoston lataus -tapa -\n\nKirjoita tiedostojen osoitteet URL-laatikkoon - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - Linkkien testaus -tapa -\n\nKirjoita nettiosoitteet ja testattavat linkit URL-laatikkoon - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Pivitystapa -\n\nTarkista URL-laatikon osoitteet, tarkista mritteet tarvittaessa ja paina 'SEURAAVA' - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Jatkamistapa (keskeytetyt operaatiot) -\n\nTarkista URL-laatikon osoitteet, tarkista mritteet tarvittaessa ja paina 'SEURAAVA' Log files Path Lokitiedostojen polku Path Polku - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror - Linkkilistatapa -\n\nKirjoita URL-laatikkoon sivujen osoitteet, joilla on linkkej peileihin New project / Import? Uusi projekti / Tuonti? Choose criterion Valitse kriteeri Maximum link scanning depth Linkkien lukemisen enimmissyvyys Enter address(es) here Kirjoita osoitteet thn Define additional filtering rules Mrit lissuodatinsnnt Proxy Name (if needed) Vlityspalvelimen nimi (tarvittaessa) Proxy Port Vlityspalvelimen portti Define proxy settings Mrit vlityspalvelinasetukset Use standard HTTP proxy as FTP proxy Kyt standardia HTTP-vlityspalvelinta FTP-vlityspalvelimena Path Polku Select Path Valitse polku Path Polku Select Path Valitse polku Quit WinHTTrack Website Copier Poistu WinHTTrack Website Copierista About WinHTTrack Tietoja WinHTTrack Save current preferences as default values Tallenna nykyiset asetukset vakioarvoiksi Click to continue Jatka Click to define options Mrit asetukset Click to add a URL Lis URL Load URL(s) from text file Lataa URL:t tekstitiedostosta WinHTTrack preferences (*.opt)|*.opt|| WinHTTrack-asetukset (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| Osoitelistaustekstitiedosto (*.txt)|*.txt|| File not found! Tiedostoa ei lydy! Do you really want to change the project name/path? Haluatko varmasti vaihtaa projektin nime tai polkua? Load user-default options? Ladataanko kyttjn vakioasetukset? Save user-default options? Tallennetaanko kyttjn vakioasetukset? Reset all default options? Palautetaanko kaikki vakioasetukset? Welcome to WinHTTrack! Tervetuloa WinHTTrackiin! Action: Toiminto: Max Depth Enimmissyvyys Maximum external depth: Ulkoinen enimmissyvyys: Filters (refuse/accept links) : Suodattimet (hylk/hyvksy linkit) : Paths Polut Save prefs Tallenna asetukset Define.. Mrit... Set options.. Asetukset... Preferences and mirror options: Asetukset ja peilivalinnat: Project name Projektin nimi Add a URL... Lis URL... Web Addresses: (URL) Nettiosoitteet: (URL) Stop WinHTTrack? Pysyt WinHTTrack? No log files in %s! Ei lokitiedostoja %s! Pause Download? Pysyt imurointi? Stop the mirroring operation Pysyt peilausoperaatio Minimize to System Tray Pienenn tehtvpalkkiin Click to skip a link or stop parsing Ohita linkki tai pysyt parsinta Click to skip a link Ohita linkki Bytes saved Tavuja tallennettu Links scanned Linkkej luettu Time: Aika: Connections: Yhteydet: Running: Menossa: Hide Piilota Transfer rate Siirtonopeus SKIP OHITA Information Tiedot Files written: Kirjoitetut tiedostot: Files updated: Pivitetyt tiedostot: Errors: Virheet: In progress: Kynniss: Follow external links Seuraa ulkoisia linkkej Test all links in pages Testaa kaikki sivujen linkit Try to ferret out all links Yrit nuuskia kaikki linkit Download HTML files first (faster) Lataa HTML-tiedostot ensin (nopeampi) Choose local site structure Valitse paikallisen sivun rakenne Set user-defined structure on disk Aseta kyttjn mrittelem rakenne levyll Use a cache for updates and retries Kyt vlimuistia pivityksiin ja uudelleenyrityksiin Do not update zero size or user-erased files l pivit tyhji tai kyttjn luomia tiedostoja Create a Start Page Luo aloitussivu Create a word database of all html pages Luo sanatietokanta kaikista html-sivuista Create error logging and report files Luo virheloki- ja raporttitiedostot Generate DOS 8-3 filenames ONLY Kehit VAIN DOSin 8-3 tiedostonimet Generate ISO9660 filenames ONLY for CDROM medias Kehit ISO9660-tiedostonimet VAIN cd-rom-medioille Do not create HTML error pages l luo HTML-virhesivuja Select file types to be saved to disk Valitse levylle tallennettavat tiedostotyypit Select parsing direction Valitse parsintasuunta Select global parsing direction Valitse yleinen parsintasuunta Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) Aseta URL-uudelleenkirjoitusssnnt sisisille (ladatut) ja ulkoisille (ei ladattu) linkeille Max simultaneous connections Yhtaikaisten yhteyksien enimmismr File timeout Tiedoston aikakatkaisu Cancel all links from host if timeout occurs Peruuta kaikki linkit isnnlt jos aikakatkaistaan Minimum admissible transfer rate Hyvksyttv vhimmissiirtonopeus Cancel all links from host if too slow Peruuta kaikki linkit isnnlt jos liian hidasta Maximum number of retries on non-fatal errors Uudelleenyrittmisten enimmismr vhemmn vakavissa virheiss Maximum size for any single HTML file Yksittisen HTML-tiedoston enimmiskoko Maximum size for any single non-HTML file Yksittisen tiedoston enimmiskoko (muu kuin HTML) Maximum amount of bytes to retrieve from the Web Netist ladattavien tavujen enimmismr Make a pause after downloading this amount of bytes Pysyt, kun on ladattu tmn verran tavuja Maximum duration time for the mirroring operation Peilausoperaation enimmiskesto Maximum transfer rate Enimmissiirtonopeus Maximum connections/seconds (avoid server overload) Enimmilln yhteyksi sekunnissa (vltt palvelimen ylikuormitusta) Maximum number of links that can be tested (not saved!) Testattavien linkkien enimmismr (ei tallennettujen!) Browser identity Esittydy selaimena Comment to be placed in each HTML file Jokaiseen HTML-tiedostoon pantava kommentti Back to starting page Palaa aloitussivulle Save current preferences as default values Tallenna nykyiset asetukset vakioarvoiksi Click to continue Paina jatkaaksesi Click to cancel changes Paina peruuttaaksesi muutokset Follow local robots rules on sites Noudata paikallisia robottisntj sivuilla Links to non-localised external pages will produce error pages Linkit paikallisoimattoimiin ulkoisiin sivuihin antavat virhesivuja Do not erase obsolete files after update l poista vanhentuneita tiedostoja pivityksen jlkeen Accept cookies? Hyvksytnk evsteet? Check document type when unknown? Tarkistetaanko dokumentin tuntematon tyyppi? Parse java applets to retrieve included files that must be downloaded? Parsitaanko java-apletit saadaksesi ladattua mys tarvittavat sisllytetyt tiedostot? Store all files in cache instead of HTML only Tallenna kaikki tiedostot vlimuistiin vain HTML-tiedostojen asemesta Log file type (if generated) Lokitiedoston tyyppi (jos luodaan) Maximum mirroring depth from root address Juuriosoitteesta peilauksen enimmissyvyys Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) Peilauksen enimmissyvyys ulkoisiin/kielletyihin osoitteisiin (0 eli ei mitn on vakiona) Create a debugging file Luo debuggaustiedosto Use non-standard requests to get round some server bugs Kyt epstandardeja pyyntj kiertksesi joitakin palvelinbugeja Use old HTTP/1.0 requests (limits engine power!) Kyt vanhoja HTTP/1.0-pyyntj (rajoittaa moottorin tehoa!) Attempt to limit retransfers through several tricks (file size test..) Yrit rajoittaa uudelleensiirtoja eri tempuilla (tiedostokoon testi, ...) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Yrit rajoittaa linkkien mr hylkmll samankaltaiset URL:t (www.foo.com==foo.com, http=https ...) Write external links without login/password Kirjoita ulkoiset linkit ilman tunnusta ja salasanaa Write internal links without query string Kirjoita sisiset linkit ilman kyselyteksti Get non-HTML files related to a link, eg external .ZIP or pictures Ota linkki koskevat muut kuin HTML-tiedostot, esimerkiksi ulkoiset zipit tai kuvat Test all links (even forbidden ones) Testaa kaikki linkit (kielletytkin) Try to catch all URLs (even in unknown tags/code) Yrit napata kaikki URL:t (jopa tuntemattomissa tageissa/koodeissa) Get HTML files first! Ota HTML-tiedostot ensin! Structure type (how links are saved) Rakenteen tyyppi (kuinka linkit tallennetaan) Use a cache for updates Kyt vlimuistia pivitykseen Do not re-download locally erased files l imuroi uudelleen paikallisesti poistettuja tiedostoja Make an index Tee indeksi Make a word database Tee sanatietokanta Log files Lokitiedostot DOS names (8+3) DOS-nimet (8+3) ISO9660 names (CDROM) ISO9660-nimet (CDROM) No error pages Ei virhesivuja Primary Scan Rule Plukusnt Travel mode Kulkutapa Global travel mode Yleinen kulkutapa These options should be modified only exceptionally Nm asetukset pitisi muuttaa poikkeustapauksissa Activate Debugging Mode (winhttrack.log) Aktivoi debuggaustapa (winhttrack.log) Rewrite links: internal / external Kirjoita linkit uudelleen: sisiset / ulkoiset Flow control Datavuon ohjaus Limits Rajoitukset Identity Esittydy HTML footer HTML-alatunniste N# connections Yhteyksi Abandon host if error Hylk isnt, jos virhe Minimum transfer rate (B/s) Vhimmissiirtonopeus (t/s) Abandon host if too slow Hylk isnt, jos liian hidas Configure Sd Use proxy for ftp transfers Kyt vlityspalvelinta ftp-siirtoihin TimeOut(s) Aikakatkaisut Persistent connections (Keep-Alive) Pysyvt yhteydet (herkistele) Reduce connection time and type lookup time using persistent connections Vhenn yhteysaikaa ja tyypintarkastusaikaa kyttmll pysyvi yhteyksi Retries Uudelleenyritykset Size limit Kokorajoitus Max size of any HTML file (B) HTML-tiedostojen enimmiskoko Max size of any non-HTML file Muiden kuin HTML:ien enimmiskoko Max site size Sivuston enimmiskoko Max time Enimmisaika Save prefs Tallenna asetukset Max transfer rate Enimmissiirtonopeus Follow robots.txt Noudata robots.txt:t No external pages Ei ulkoisia sivuja Do not purge old files l puhdista vanhoja tiedostoja Accept cookies Hyvksy evsteet Check document type Valitse dokumentin tyyppi Parse java files Parsi java-tiedostot Store ALL files in cache Tallenna KAIKKI tiedostot vlimuistiin Tolerant requests (for servers) Hyvksyvt pyynnt (palvelimille) Update hack (limit re-transfers) Pivityspilkeet (rajoita uudelleensiirtoja) URL hacks (join similar URLs) URL-pilkkeet (liit samanlaiset URL:t) Force old HTTP/1.0 requests (no 1.1) Pakota vanhat HTTP/1.0-pyynnt (ei 1.1) Max connections / seconds Yhteyksien enimmismr sekunnissa Maximum number of links Linkkien enimmismr Pause after downloading.. Pysyt, kun imuroitu... Hide passwords Ktke salasanat Hide query strings Ktke kyselytekstit Links Linkit Build Rakenna Experts Only Ammattilaisille Flow Control Datavuon ohjaus Limits Rajoitukset Browser ID Selaimen ID Scan Rules Lukusnnt Spider Nettirobotti Log, Index, Cache Loki, indeksi, vlimuisti Proxy Vlityspalvelin MIME Types MIME-tyypit Do you really want to quit WinHTTrack Website Copier? Haluatko varmasti poistua WinHTTrack Website Copierista? Do not connect to a provider (already connected) l yhdist tarjoajaan (on jo yhditetty) Do not use remote access connection l kyt etyhteytt Schedule the mirroring operation Ajoita peilausoperaatio Quit WinHTTrack Website Copier Poistu WinHTTrack Website Copierista Back to starting page Palaa aloitussivulle Click to start! Aloita! No saved password for this connection! Ei tallennettuja salasanoja tlle yhteydelle! Can not get remote connection settings Ei voi ottaa etyhteyden asetuksia Select a connection provider Valitse puhelinverkkoyhteys Start Aloita Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. Sd yhteysasetukset tarvittaessa,\nsen jlkeen paina VALMIS peilioperaation aloittamiseksi. Save settings only, do not launch download now. Tallenna vain asetukset, l aloita lataamista viel On hold Odottele Transfer scheduled for: (hh/mm/ss) Siirtminen ajastettu: (tt/mm/ss) Start Aloita Connect to provider (RAS) Yhdist tarjoajaan (RAS) Connect to this provider Yhdist thn tarjoajaan Disconnect when finished Katkaise yhteys, kun on valmista Disconnect modem on completion Katkaise modeemiyhteys, kun on valmista \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n(Kerro meille bugeista ja ongelmista)\r\n\r\nKehitys:\r\nKyttliittym (Windows): Xavier Roche\r\nNettirobotti: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C) 1998-2003 Xavier Roche ja muut avustajat\r\nSuomentanut Mika Khknen 22.-24.7.2005\r\nmika.kahkonen@mbnet.fi\r\nhttp://koti.mbnet.fi/kahoset About WinHTTrack Website Copier Tietoja WinHTTrack Website Copier Please visit our Web page Ky nettisivuillamme Wizard query Velhokysely Your answer: Vastauksesi: Link detected.. Linkki havaittu... Choose a rule Valitse snt Ignore this link Sivuuta tm linkki Ignore directory Sivuuta hakemisto Ignore domain Sivuuta verkkotunnus Catch this page only Huomioi vain tm sivu Mirror site Peilisivu Mirror domain Peiliverkkotunnus Ignore all Sivuuta kaikki Wizard query Velhokysely NO EI File &Tiedosto Options Valinnat Log &Loki Window &Ikkuna Help O&hje Pause transfer Pysyt siirto Exit Poistu Modify options &Muokkaa valintoja View log &Nyt loki View error log Nyt &virheloki View file transfers Nyt tiedostosiirrot Hide P&iilota About WinHTTrack Website Copier &Tietoja WinHTTrack Website Copier Check program updates... Tarkista ohjelman &pivitykset... &Toolbar &Tykalupalkki &Status Bar T&ilapalkki S&plit J&ako File &Tiedosto Preferences &Asetukset Mirror P&eili Log &Loki Window &Ikkuna Help Ohje Exit Poistu Load default options &Lataa vakioasetukset Save default options &Tallenna vakioasetukset Reset to default options &Palaa vakioasetuksiin Load options... Lataa &valinnat... Save options as... Tallenna valinnat &nimell... Language preference... &Kieliasetukset... Contents... &Ohjeen aiheet... About WinHTTrack... &Tietoja WinHTTrack... New project\tCtrl+N &Uusi projekti\tCtrl+N &Open...\tCtrl+O &Avaa...\tCtrl+O &Save\tCtrl+S &Tallenna\tCtrl+S Save &As... Tallenna &nimell... &Delete... P&oista... &Browse sites... S&elaa sivuja... User-defined structure Kyttjn mrittelem rakenne %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\tTiedostonimi ilman tyyppi (esim: kuva)\r\n%N\tTiedostonimi ja tyyppi (esim: kuva.png)\r\n%t\tVain tiedostotyyppi (esim: png)\r\n%p\tPolku [loppuun ei /] (esim: /kuvia)\r\n%h\tIsntnimi (esim: www.jokinnetti.fi)\r\n%M\tMD5-URL (128 bitti, 32 ascii-tavua)\r\n%Q\tMD5-kyselyjono (128 bitti, 32 ascii-tavua)\r\n%q\tPieni MD5-kyselyjono (16 bitti, 4 ascii-tavua)\r\n\r\n%s?\tLyhyt nimi(esim: %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Esimerkki:\t%h%p/%n%q.%t\n->\t\tc:\\peili\\www.jokinnetti.com\\jotainkuvia\\kuva.gif Proxy settings Vlityspalvelinasetukset Proxy address: Vlityspalvelimen osoite: Proxy port: Vlityspalvelimen portti: Authentication (only if needed) Autentisointi (vain tarvittaessa) Login Kirjaudu Password Salasana Enter proxy address here Vlityspalvelimen osoite Enter proxy port here Vlityspalvelimen portti Enter proxy login Vlityspalvelimen kirjautuminen Enter proxy password Vlityspalvelimen salasana Enter project name here Projektin nimi Enter saving path here Tallennuspolku Select existing project to update Valitse pivitettv projekti Click here to select path Valitse polku Select or create a new category name, to sort your mirrors in categories Valitse tai luo uusi luokka peilaustesi luokittelemiseen HTTrack Project Wizard... HTTrackin projektivelho... New project name: Uuden projektin nimi: Existing project name: Vanhan projektin nimi: Project name: Projektin nimi: Base path: Peruspolku: Project category: Projektin luokka: C:\\My Web Sites C:\\Nettisivuni Type a new project name, \r\nor select existing project to update/resume Kirjoita uuden projektin nimi, \r\tai valitse pivitettv tai jatkettava projekti New project Uusi projekti Insert URL Lis URL URL: URL: Authentication (only if needed) Autentisointi (vain tarvittaessa) Login Kirjaudu Password Salasana Forms or complex links: Lomakkeet tai monimutkaiset linkit: Capture URL... Kaappaa URL... Enter URL address(es) here Kirjoita URL-osoitteet thn Enter site login Kirjoita sivun tunnus Enter site password Kirjoita sivun salasana Use this capture tool for links that can only be accessed through forms or javascript code Kyt tt kaappaustykalua linkkeihin, joihin voi pst vain lomakkeiden tai javascript-koodien avulla Choose language according to preference Valitse asetettu kieli Catch URL! Nappaa URL! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. Aseta vliaikaisesti selaimen vlityspalvelinasetukset seuraavilla arvoilla (Kopioi osoite ja portti).\nSen jlkeen paina lomakkeen Lhet-painiketta selaimesi sivulla tai paina linkki, jonka haluat kaapata. This will send the desired link from your browser to WinHTTrack. Tm lhett halutun linkit selaimeltasi WinHTTrackiin. ABORT KESKEYT Copy/Paste the temporary proxy parameters here Kopioi ja liit vliaikaiset vlityspalvelinparametrit thn Cancel Peruuta Unable to find Help files! Ohje-tiedostoja ei lydy! Unable to save parameters! Ei voi tallentaa parametrej! Please drag only one folder at a time Raahaa vain yksi kansio kerrallaan Please drag only folders, not files Raahaa vain kansiot, ei tiedostoja Please drag folders only Raahaa vain kansiot Select user-defined structure? Valitse kyttjn mrittelem rakenne? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! Varmista, ett kyttjn mrittelem merkkijono on oikea,\nmuutoin tiedostonimist tulee roskaa! Do you really want to use a user-defined structure? Haluatko varmasti kytt kyttjn mrittelem rakennetta? Too manu URLs, cannot handle so many links!! Liian monta URL:, ei voi ksitell niin monta!!! Not enough memory, fatal internal error.. Ei tarpeeksi muistia, vakava sisinen virhe... Unknown operation! Tuntematon operaatio! Add this URL?\r\n Lis URL?\r\n Warning: main process is still not responding, cannot add URL(s).. Varoitus: pprosessi ei vielkn vastaa, ei voi list URL:i... Type/MIME associations Tyyppi/MIME-kytkennt File types: Tiedostotyypit: MIME identity: MIME-identiteetti: Select or modify your file type(s) here Valitse tai muokkaa tiedostotyyppejsi Select or modify your MIME type(s) here Valitse tai muokkaa MIME-tyyppejsi Go up Yls Go down Alas File download information Tiedoston imuroinnin tiedot Freeze Window Jdyt ikkuna More information: Listietoa: Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download Tervetuloa WinHTTrack Website Copieriin!\n\Paina seuraava\n\n- aloittaaksesi uuden projektin\n- tai jatkaaksesi keskeytynytt latausta File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS Tiedostonimet, joilla pte:\nTiedostonimet, joissa on:\nTm tiedostonimi:\nKansionimet, joissa on:\nTm kansionimi:\nTmn verkkotunnuksen linkit:\nLinkit verkkotunnuksissa, joissa on:\nLinkit tlt isnnlt:\nLinkit, joissa on:\nTm linkki:\nKAIKKI LINKIT Show all\nHide debug\nHide infos\nHide debug and infos Nyt kaikki\nKtke debug\nKtke infot\nKtke debug and infot Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. Sivuston rakenne (vakio)\nHtml:t kansioon web/, kuvat ja muut web/images/\nHtml:t kansioon web/html/, kuvat ja muut web/images/\nHtml:t kansioon web/, kuvat ja muut web/\nHtml:t kansioon web/, kuvat ja muut web/xxx/, miss xxx on tiedostopte\nHtml:t kansioon web/html/, kuvat ja muut web/xxx/\nSivuston rakenne, ilman www.domain.xxx/\nHtml:t kansioon sivuston_nimi/, kuvat ja muut sivuston_nimi/images/\nHtml:t kansioon sivuston_nimi/html/, kuvat ja muut sivuston_nimi/images/\nHtml:t kansioon sivuston_nimi/, kuvat ja muut sivuston_nimi/\nHtml:t kansioon sivuston_nimi/, kuvat ja muut sivuston_nimi/xxx/\nHtml:t kansioon sivuston_nimi/html/, kuvat ja muut sivuston_nimi/xxx/\nKaikki kansioon web/, luo satunnaiset nimet (!)\nKaikki kansioon sivuston_nimi/, luo satunnaiset nimet (!)\nKyttjn mrittelem rakenne... Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first Vain lue\nSil html-tiedostot\nSil muut kuin html-tiedostot\nSil kaikki tiedostot (vakio)\nSil html-tiedostot ensin Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down Pysy samassa hakemistossa\nVoi menn alas (vakio)\nVoi menn yls\nVoi menn sek yls ett alas Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web Pysy samassa osoitteessa (vakio)\nPysy samalla verkkotunnuksella\nPysy samalla ylimmn tason verkkotunnuksella\nMene kaikkialle nettiin Never\nIf unknown (except /)\nIf unknown Ei koskaan\nJos tuntematon (paitsi /)\nJos tuntematon no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules ei robots.txt-sntj\nrobots.txt paitsi velhoa\nnoudata robots.txt-sntj normal\nextended\ndebug normaali\nlaajennettu\ndebug Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download Imuroi nettisivut\nImuroi nettisivut ja kysymykset\nOta yksittiset tiedostot\nImuroi kaikki sivut sivustolla (useat peilit)\nTestaa sivujen linkit (kirjanmerkkitestaus)\n* Jatka keskeytynytt latausta\n* Pivit jo imuroitu Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL Suhteellinen URI / tarkka URL (vakio)\nTarkka URL / tarkka URL\nTarkka URI / tarkka URL\nAlkuperinen URL / alkuperinen URL Open Source offline browser Avoimen lhdekoodin yhteydetn selain Website Copier/Offline Browser. Copy remote websites to your computer. Free. Nettisivun lataaja/Offline-selain. Kopioi nettisivut koneellesi. Ilmainen. httrack, winhttrack, webhttrack, offline browser httrack, winhttrack, webhttrack, offline-selain URL list (.txt) URL-luettelo (.txt) Previous Edellinen Next Seuraava URLs URL:t Warning Varoitus Your browser does not currently support javascript. For better results, please use a javascript-aware browser. Selaimesi ei tue javascripti juuri nyt. Parempia tuloksia tulee javascripti kyttvll selaimella. Thank you Kiitos You can now close this window Voit nyt sulkea tmn ikkunan Server terminated Palvelin lopetettu A fatal error has occurred during this mirror Tll peilill tapahtui vakava virhe httrack-3.49.5/lang/English.txt0000644000175000017500000010563314360553245013267 00000000000000LANGUAGE_NAME English LANGUAGE_FILE English LANGUAGE_ISO en LANGUAGE_AUTHOR Xavier Roche (roche at httrack.com)\r\nRobert Lagadec (rlagadec at yahoo.fr) \r\n LANGUAGE_CHARSET ISO-8859-1 LANGUAGE_WINDOWSID English (United States) OK OK Cancel Cancel Exit Exit Close Close Cancel changes Cancel changes Click to confirm Click to confirm Click to get help! Click to get help! Click to return to previous screen Click to return to previous screen Click to go to next screen Click to go to next screen Hide password Hide password Save project Save project Close current project? Close current project? Delete this project? Delete this project? Delete empty project %s? Delete empty project %s? Action not yet implemented Action not yet implemented Error deleting this project Error deleting this project Select a rule for the filter Select a rule for the filter Enter keywords for the filter Enter keywords for the filter Cancel Cancel Add this rule Add this rule Please enter one or several keyword(s) for the rule Please enter one or several keyword(s) for the rule Add Scan Rule Add Scan Rule Criterion Criterion String String Add Add Scan Rules Scan Rules Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Exclude links Exclude links Include link(s) Include link(s) Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) Save prefs Save prefs Matching links will be excluded: Matching links will be excluded: Matching links will be included: Matching links will be included: Example: Example: gif\r\nWill match all GIF files gif\r\nWill match all GIF files blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) All links will match All links will match Add exclusion filter Add exclusion filter Add inclusion filter Add inclusion filter Existing filters Existing filters Cancel changes Cancel changes Save current preferences as default values Save current preferences as default values Click to confirm Click to confirm No log files in %s! No log files in %s! No 'index.html' file in %s! No 'index.html' file in %s! Click to quit WinHTTrack Website Copier Click to quit WinHTTrack Website Copier View log files View log files Browse HTML start page Browse HTML start page End of mirror End of mirror View log files View log files Browse Mirrored Website Browse Mirrored Website New project... New project... View error and warning reports View error and warning reports View report View report Close the log file window Close the log file window Info type: Info type: Errors Errors Infos Infos Find Find Find a word Find a word Info log file Info log file Warning/Errors log file Warning/Errors log file Unable to initialize the OLE system Unable to initialize the OLE system WinHTTrack could not find any interrupted download file cache in the specified folder! WinHTTrack could not find any interrupted download file cache in the specified folder! Could not connect to provider Could not connect to provider receive receive request request connect connect search search ready ready error error Receiving files.. Receiving files.. Parsing HTML file.. Parsing HTML file.. Purging files.. Purging files.. Loading cache in progress.. Loading cache in progress.. Parsing HTML file (testing links).. Parsing HTML file (testing links).. Pause - Toggle [Mirror]/[Pause download] to resume operation Pause - Toggle [Mirror]/[Pause download] to resume operation Finishing pending transfers - Select [Cancel] to stop now! Finishing pending transfers - Select [Cancel] to stop now! scanning scanning Waiting for scheduled time.. Waiting for scheduled time.. Transferring data.. Transferring data.. Connecting to provider Connecting to provider [%d seconds] to go before start of operation [%d seconds] to go before start of operation Site mirroring in progress [%s, %s bytes] Site mirroring in progress [%s, %s bytes] Site mirroring finished! Site mirroring finished! A problem occurred during the mirroring operation\n A problem occurred during the mirroring operation\n \nDuring:\n \nDuring:\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= \n\nTip: Click [View log file] to see warning or error messages \n\nTip: Click [View log file] to see warning or error messages Error deleting a hts-cache/new.* file, please do it manually Error deleting a hts-cache/new.* file, please do it manually Do you really want to quit WinHTTrack Website Copier? Do you really want to quit WinHTTrack Website Copier? - Mirroring Mode -\n\nEnter address(es) in URL box - Mirroring Mode -\n\nEnter address(es) in URL box - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - File Download Mode -\n\nEnter file address(es) in URL box - File Download Mode -\n\nEnter file address(es) in URL box - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button Log files Path Log files Path Path Path - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror New project / Import? New project / Import? Choose criterion Choose criterion Maximum link scanning depth Maximum link scanning depth Enter address(es) here Enter address(es) here Define additional filtering rules Define additional filtering rules Proxy Name (if needed) Proxy Name (if needed) Proxy Port Proxy Port Define proxy settings Define proxy settings Use standard HTTP proxy as FTP proxy Use standard HTTP proxy as FTP proxy Path Path Select Path Select Path Path Path Select Path Select Path Quit WinHTTrack Website Copier Quit WinHTTrack Website Copier About WinHTTrack About WinHTTrack Save current preferences as default values Save current preferences as default values Click to continue Click to continue Click to define options Click to define options Click to add a URL Click to add a URL Load URL(s) from text file Load URL(s) from text file WinHTTrack preferences (*.opt)|*.opt|| WinHTTrack preferences (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| Address List text file (*.txt)|*.txt|| File not found! File not found! Do you really want to change the project name/path? Do you really want to change the project name/path? Load user-default options? Load user-default options? Save user-default options? Save user-default options? Reset all default options? Reset all default options? Welcome to WinHTTrack! Welcome to WinHTTrack! Action: Action: Max Depth Max Depth Maximum external depth: Maximum external depth: Filters (refuse/accept links) : Filters (refuse/accept links) : Paths Paths Save prefs Save prefs Define.. Define.. Set options.. Set options.. Preferences and mirror options: Preferences and mirror options: Project name Project name Add a URL... Add a URL... Web Addresses: (URL) Web Addresses: (URL) Stop WinHTTrack? Stop WinHTTrack? No log files in %s! No log files in %s! Pause Download? Pause Download? Stop the mirroring operation Stop the mirroring operation Minimize to System Tray Minimize to System Tray Click to skip a link or stop parsing Click to skip a link or stop parsing Click to skip a link Click to skip a link Bytes saved Bytes saved Links scanned Links scanned Time: Time: Connections: Connections: Running: Running: Hide Hide Transfer rate Transfer rate SKIP SKIP Information Information Files written: Files written: Files updated: Files updated: Errors: Errors: In progress: In progress: Follow external links Follow external links Test all links in pages Test all links in pages Try to ferret out all links Try to ferret out all links Download HTML files first (faster) Download HTML files first (faster) Choose local site structure Choose local site structure Set user-defined structure on disk Set user-defined structure on disk Use a cache for updates and retries Use a cache for updates and retries Do not update zero size or user-erased files Do not update zero size or user-erased files Create a Start Page Create a Start Page Create a word database of all html pages Create a word database of all html pages Build a complete RFC822 mail (MHT/EML) archive of the mirror Build a complete RFC822 mail (MHT/EML) archive of the mirror Create error logging and report files Create error logging and report files Generate DOS 8-3 filenames ONLY Generate DOS 8-3 filenames ONLY Generate ISO9660 filenames ONLY for CDROM medias Generate ISO9660 filenames ONLY for CDROM medias Do not create HTML error pages Do not create HTML error pages Select file types to be saved to disk Select file types to be saved to disk Select parsing direction Select parsing direction Select global parsing direction Select global parsing direction Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) Max simultaneous connections Max simultaneous connections File timeout File timeout Cancel all links from host if timeout occurs Cancel all links from host if timeout occurs Minimum admissible transfer rate Minimum admissible transfer rate Cancel all links from host if too slow Cancel all links from host if too slow Maximum number of retries on non-fatal errors Maximum number of retries on non-fatal errors Maximum size for any single HTML file Maximum size for any single HTML file Maximum size for any single non-HTML file Maximum size for any single non-HTML file Maximum amount of bytes to retrieve from the Web Maximum amount of bytes to retrieve from the Web Make a pause after downloading this amount of bytes Make a pause after downloading this amount of bytes Maximum duration time for the mirroring operation Maximum duration time for the mirroring operation Maximum transfer rate Maximum transfer rate Maximum connections/seconds (avoid server overload) Maximum connections/seconds (avoid server overload) Maximum number of links that can be tested (not saved!) Maximum number of links that can be tested (not saved!) Browser identity Browser identity Comment to be placed in each HTML file Comment to be placed in each HTML file Languages accepted by the browser Languages accepted by the browser Additional HTTP headers to be sent in each requests Additional HTTP headers to be sent in each requests HTTP referer to be sent for initial URLs HTTP referer to be sent for initial URLs Back to starting page Back to starting page Save current preferences as default values Save current preferences as default values Click to continue Click to continue Click to cancel changes Click to cancel changes Follow local robots rules on sites Follow local robots rules on sites Links to non-localised external pages will produce error pages Links to non-localised external pages will produce error pages Do not erase obsolete files after update Do not erase obsolete files after update Accept cookies? Accept cookies? Check document type when unknown? Check document type when unknown? Parse java applets to retrieve included files that must be downloaded? Parse java applets to retrieve included files that must be downloaded? Store all files in cache instead of HTML only Store all files in cache instead of HTML only Log file type (if generated) Log file type (if generated) Maximum mirroring depth from root address Maximum mirroring depth from root address Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) Create a debugging file Create a debugging file Use non-standard requests to get round some server bugs Use non-standard requests to get round some server bugs Use old HTTP/1.0 requests (limits engine power!) Use old HTTP/1.0 requests (limits engine power!) Attempt to limit retransfers through several tricks (file size test..) Attempt to limit retransfers through several tricks (file size test..) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Write external links without login/password Write external links without login/password Write internal links without query string Write internal links without query string Get non-HTML files related to a link, eg external .ZIP or pictures Get non-HTML files related to a link, eg external .ZIP or pictures Test all links (even forbidden ones) Test all links (even forbidden ones) Try to catch all URLs (even in unknown tags/code) Try to catch all URLs (even in unknown tags/code) Get HTML files first! Get HTML files first! Structure type (how links are saved) Structure type (how links are saved) Use a cache for updates Use a cache for updates Do not re-download locally erased files Do not re-download locally erased files Make an index Make an index Make a word database Make a word database Build a mail archive Build a mail archive Log files Log files DOS names (8+3) DOS names (8+3) ISO9660 names (CDROM) ISO9660 names (CDROM) No error pages No error pages Primary Scan Rule Primary Scan Rule Travel mode Travel mode Global travel mode Global travel mode These options should be modified only exceptionally These options should be modified only exceptionally Activate Debugging Mode (winhttrack.log) Activate Debugging Mode (winhttrack.log) Rewrite links: internal / external Rewrite links: internal / external Flow control Flow control Limits Limits Identity Identity HTML footer HTML footer Languages Languages Additional HTTP Headers Additional HTTP Headers Default referer URL Default referer URL N# connections N# connections Abandon host if error Abandon host if error Minimum transfer rate (B/s) Minimum transfer rate (B/s) Abandon host if too slow Abandon host if too slow Configure Configure Use proxy for ftp transfers Use proxy for ftp transfers TimeOut(s) TimeOut(s) Persistent connections (Keep-Alive) Persistent connections (Keep-Alive) Reduce connection time and type lookup time using persistent connections Reduce connection time and type lookup time using persistent connections Retries Retries Size limit Size limit Max size of any HTML file (B) Max size of any HTML file (B) Max size of any non-HTML file Max size of any non-HTML file Max site size Max site size Max time Max time Save prefs Save prefs Max transfer rate Max transfer rate Follow robots.txt Follow robots.txt No external pages No external pages Do not purge old files Do not purge old files Accept cookies Accept cookies Check document type Check document type Parse java files Parse java files Store ALL files in cache Store ALL files in cache Tolerant requests (for servers) Tolerant requests (for servers) Update hack (limit re-transfers) Update hack (limit re-transfers) URL hacks (join similar URLs) URL hacks (join similar URLs) Force old HTTP/1.0 requests (no 1.1) Force old HTTP/1.0 requests (no 1.1) Max connections / seconds Max connections / seconds Maximum number of links Maximum number of links Pause after downloading.. Pause after downloading.. Hide passwords Hide passwords Hide query strings Hide query strings Links Links Build Build Experts Only Experts Only Flow Control Flow Control Limits Limits Browser ID Browser ID Scan Rules Scan Rules Spider Spider Log, Index, Cache Log, Index, Cache Proxy Proxy MIME Types MIME Types Do you really want to quit WinHTTrack Website Copier? Do you really want to quit WinHTTrack Website Copier? Do not connect to a provider (already connected) Do not connect to a provider (already connected) Do not use remote access connection Do not use remote access connection Schedule the mirroring operation Schedule the mirroring operation Quit WinHTTrack Website Copier Quit WinHTTrack Website Copier Back to starting page Back to starting page Click to start! Click to start! No saved password for this connection! No saved password for this connection! Can not get remote connection settings Can not get remote connection settings Select a connection provider Select a connection provider Start Start Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. Save settings only, do not launch download now. Save settings only, do not launch download now. On hold On hold Transfer scheduled for: (hh/mm/ss) Transfer scheduled for: (hh/mm/ss) Start Start Connect to provider (RAS) Connect to provider (RAS) Connect to this provider Connect to this provider Disconnect when finished Disconnect when finished Disconnect modem on completion Disconnect modem on completion \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) About WinHTTrack Website Copier About WinHTTrack Website Copier Please visit our Web page Please visit our Web page Wizard query Wizard query Your answer: Your answer: Link detected.. Link detected.. Choose a rule Choose a rule Ignore this link Ignore this link Ignore directory Ignore directory Ignore domain Ignore domain Catch this page only Catch this page only Mirror site Mirror site Mirror domain Mirror domain Ignore all Ignore all Wizard query Wizard query NO NO File File Options Options Log Log Window Window Help Help Pause transfer Pause transfer Exit Exit Modify options Modify options View log View log View error log View error log View file transfers View file transfers Hide Hide About WinHTTrack Website Copier About WinHTTrack Website Copier Check program updates... Check program updates... &Toolbar &Toolbar &Status Bar &Status Bar S&plit S&plit File File Preferences Preferences Mirror Mirror Log Log Window Window Help Help Exit Exit Load default options Load default options Save default options Save default options Reset to default options Reset to default options Load options... Load options... Save options as... Save options as... Language preference... Language preference... Contents... Contents... About WinHTTrack... About WinHTTrack... New project\tCtrl+N New project\tCtrl+N &Open...\tCtrl+O &Open...\tCtrl+O &Save\tCtrl+S &Save\tCtrl+S Save &As... Save &As... &Delete... &Delete... &Browse sites... &Browse sites... User-defined structure User-defined structure %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Proxy settings Proxy settings Proxy address: Proxy address: Proxy port: Proxy port: Authentication (only if needed) Authentication (only if needed) Login Login Password Password Enter proxy address here Enter proxy address here Enter proxy port here Enter proxy port here Enter proxy login Enter proxy login Enter proxy password Enter proxy password Enter project name here Enter project name here Enter saving path here Enter saving path here Select existing project to update Select existing project to update Click here to select path Click here to select path Select or create a new category name, to sort your mirrors in categories Select or create a new category name, to sort your mirrors in categories HTTrack Project Wizard... HTTrack Project Wizard... New project name: New project name: Existing project name: Existing project name: Project name: Project name: Base path: Base path: Project category: Project category: C:\\My Web Sites C:\\My Web Sites Type a new project name, \r\nor select existing project to update/resume Type a new project name, \r\nor select existing project to update/resume New project New project Insert URL Insert URL URL: URL: Authentication (only if needed) Authentication (only if needed) Login Login Password Password Forms or complex links: Forms or complex links: Capture URL... Capture URL... Enter URL address(es) here Enter URL address(es) here Enter site login Enter site login Enter site password Enter site password Use this capture tool for links that can only be accessed through forms or javascript code Use this capture tool for links that can only be accessed through forms or javascript code Choose language according to preference Choose language according to preference Catch URL! Catch URL! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. This will send the desired link from your browser to WinHTTrack. This will send the desired link from your browser to WinHTTrack. ABORT ABORT Copy/Paste the temporary proxy parameters here Copy/Paste the temporary proxy parameters here Cancel Cancel Unable to find Help files! Unable to find Help files! Unable to save parameters! Unable to save parameters! Please drag only one folder at a time Please drag only one folder at a time Please drag only folders, not files Please drag only folders, not files Please drag folders only Please drag folders only Select user-defined structure? Select user-defined structure? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! Do you really want to use a user-defined structure? Do you really want to use a user-defined structure? Too manu URLs, cannot handle so many links!! Too manu URLs, cannot handle so many links!! Not enough memory, fatal internal error.. Not enough memory, fatal internal error.. Unknown operation! Unknown operation! Add this URL?\r\n Add this URL?\r\n Warning: main process is still not responding, cannot add URL(s).. Warning: main process is still not responding, cannot add URL(s).. Type/MIME associations Type/MIME associations File types: File types: MIME identity: MIME identity: Select or modify your file type(s) here Select or modify your file type(s) here Select or modify your MIME type(s) here Select or modify your MIME type(s) here Go up Go up Go down Go down File download information File download information Freeze Window Freeze Window More information: More information: Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS Show all\nHide debug\nHide infos\nHide debug and infos Show all\nHide debug\nHide infos\nHide debug and infos Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web Never\nIf unknown (except /)\nIf unknown Never\nIf unknown (except /)\nIf unknown no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules normal\nextended\ndebug normal\nextended\ndebug Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL Open Source offline browser Open Source offline browser Website Copier/Offline Browser. Copy remote websites to your computer. Free. Website Copier/Offline Browser. Copy remote websites to your computer. Free. httrack, winhttrack, webhttrack, offline browser httrack, winhttrack, webhttrack, offline browser URL list (.txt) URL list (.txt) Previous Previous Next Next URLs URLs Warning Warning Your browser does not currently support javascript. For better results, please use a javascript-aware browser. Your browser does not currently support javascript. For better results, please use a javascript-aware browser. Thank you Thank you You can now close this window You can now close this window Server terminated Server terminated A fatal error has occurred during this mirror A fatal error has occurred during this mirror View Documentation View Documentation Go To HTTrack Website Go To HTTrack Website Go To HTTrack Forum Go To HTTrack Forum View License View License Beware: you local browser might be unable to browse files with embedded filenames Beware: you local browser might be unable to browse files with embedded filenames Recreated HTTrack internal cached resources Recreated HTTrack internal cached resources Could not create internal cached resources Could not create internal cached resources Could not get the system external storage directory Could not get the system external storage directory Could not write to: Could not write to: Read-only media (SDCARD) Read-only media (SDCARD) No storage media (SDCARD) No storage media (SDCARD) HTTrack may not be able to download websites until this problem is fixed HTTrack may not be able to download websites until this problem is fixed HTTrack: mirror '%s' stopped! HTTrack: mirror '%s' stopped! Click on this notification to restart the interrupted mirror Click on this notification to restart the interrupted mirror HTTrack: could not save profile for '%s'! HTTrack: could not save profile for '%s'! httrack-3.49.5/lang/Eesti.txt0000644000175000017500000010313514360553245012742 00000000000000LANGUAGE_NAME Eesti LANGUAGE_FILE Eesti LANGUAGE_ISO et LANGUAGE_AUTHOR Tnu Virma\r\n LANGUAGE_CHARSET ISO-8859-4 LANGUAGE_WINDOWSID Estonian OK OK Cancel Loobu Exit Vlju Close Sulge Cancel changes Loobu muudatuste tegemisest Click to confirm Kliki kinnitamiseks Click to get help! Kliki abi saamiseks! Click to return to previous screen Tagasi eelmisele ekraanile Click to go to next screen Edasi jrgmisele ekraanile Hide password Peida parool Save project Salvesta projekt Close current project? Kas sulgeda kesolev projekt? Delete this project? Kas kustutada see projekt? Delete empty project %s? Kas kustutada thi projekt %s? Action not yet implemented Tegevus ei ole veel lpetatud Error deleting this project Viga selle projekti kustutamisel Select a rule for the filter Vali filtreerimisreegel Enter keywords for the filter Sisesta mrksnad filtri jaoks Cancel Loobu Add this rule Lisa see reegel Please enter one or several keyword(s) for the rule Sisesta palun ks vi mitu mrksna reegli jaoks Add Scan Rule Lisa filtreerimisreegel Criterion Kriteerium: String Mrksna: Add Lisa Scan Rules Filtrid Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Kasuta asendajaid URL-ide vi linkide vlja- vi kaasaarvamiseks.\nhele reale vib panna mitu skaneerimisstringi.\nEraldajana kasuta thikuid.\n\nNiteks: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Exclude links Vlja arvata lingid Include link(s) Kaasa arvata lingid Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) Vihje: Et saada KIK GIF-failid kaasa arvatud, kasuta midagi taolist +www.someweb.com/*.gif. \n(+*.gif / -*.gif arvab kaasa/vlja KIK GIF-id KIKIDEST saitidest) Save prefs Salvesta hlestus Matching links will be excluded: Vastavad lingid tuleb vlja arvata: Matching links will be included: Vastavad lingid tuleb kaasa arvata: Example: Nidis: gif\r\nWill match all GIF files gif\r\nleiab kik GIF-failid blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' blue\r\nleiab kik failid, mis sisaldavad alamstringi 'blue', nagu 'bluesky-small.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' bigfile.mov\r\nleiab faili 'bigfile.mov', aga mitte 'bigfile2.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\nleiab lingid, mille kaustanimes sisaldub 'cgi' nagu /cgi-bin/somecgi.cgi cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\nleiab lingid, mille kaustanimeks on terve 'cgi-bin' string (aga mitte cgi-bin-2, niteks) someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb.com\r\nleiab seda alamstringi sisaldavad lingid, nagu www.someweb.com, private.someweb.com jne. someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. someweb\r\nleiab seda alamstringi sisaldavad lingid, nagu www.someweb.com, www.someweb.edu, private.someweb.otherweb.com jne. www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.someweb.com\r\nleiab lingid, mis vastavad alamstringile 'www.someweb.com' (aga mitte linke, nagu private.someweb.com/..) someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. someweb\r\nleiab kik seda alamstringi sisaldavad lingid, nagu www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html jne. www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/someweb.html\r\nleiab ainult faili 'www.test.com/test/someweb.html'. Sisestada tuleb tielik asukoht (URL + faili asukoht) All links will match Kik lingid leitakse Add exclusion filter Lisa vljaarvamisfilter Add inclusion filter Lisa kaasaarvamisfilter Existing filters Olemasolevad filtrid Cancel changes Loobu muudatustest Save current preferences as default values Salvesta praegune hlestus vaikevrtusena Click to confirm Kliki kinnituseks No log files in %s! %s ei ole htegi logifaili! No 'index.html' file in %s! %s ei ole faili 'index.html'! Click to quit WinHTTrack Website Copier Kliki WinHTTrack Website Copier'i sulgemiseks View log files Vaata logifaile Browse HTML start page Vaata HTML algusleheklge End of mirror Veebikopeerimine lpetatud View log files Vaata logifaile Browse Mirrored Website Sirvi kopeeritud veebisaiti New project... Uus projekt... View error and warning reports Vaata vea- ja hoiatusteraportit View report Vaata raportit Close the log file window Sulge logifaili aken Info type: Informatsiooni tp: Errors Vead Infos Info Find Otsi Find a word Otsi sna Info log file Info logifail Warning/Errors log file Hoiatuste ja vigade logifail Unable to initialize the OLE system OLE ssteemi ei saa kivitada WinHTTrack could not find any interrupted download file cache in the specified folder! WinHTTrack ei leidnud mratud kaustast htegi katkestatud tirimise cache-faili! Could not connect to provider Ei saa luua hendust receive vastuvtt request pring connect hendus search otsimine ready valmis error viga Receiving files.. Failide vastuvtmine... Parsing HTML file.. HTML faili analsimine... Purging files.. Failide hvitamine... Loading cache in progress.. Cache'i laadimine.. Parsing HTML file (testing links).. HTML faili analsimine (linkide testimine)... Pause - Toggle [Mirror]/[Pause download] to resume operation Paus - Jtkamiseks vali [Saidikopeerimine]/[Peata lekanne] Finishing pending transfers - Select [Cancel] to stop now! Pooleliolevate lekannete lpetamine - Kliki [Cancel], et lpetada kohe! scanning skaneerimine Waiting for scheduled time.. Etteantud aja ootamine... Connecting to provider hendusevtmine [%d seconds] to go before start of operation [%d sekundit] jnud operatsiooni alguseni Site mirroring in progress [%s, %s bytes] Saidi kopeerimine [%s, %s baiti] Site mirroring finished! Saidikopeerimine on lpetatud! A problem occurred during the mirroring operation\n Saidikopeerimise kigus tekkis probleem\n \nDuring:\n \nOperatsioonil:\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! \nVaata logifaili kui tarvis.\n\nKliki FINISH, et sulgeda WinHTTrack Website Copier.\n\nTnan WinHTTrack'i kasutamise eest! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! Kopeerimisoperatsioon on lpetatud.\nKliki Vlju, et sulgeda WinHTTrack.\nVaata logifaili veendumaks, et kik on korras.\n\nTnan WinHTTrack'i kasutamise eest! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * KOPEERIMINE KATKESTATUD! * *\r\nPraegune ajutine cache on vajalik igasuguse uuendamise jaoks ja sisaldab ainult kesoleva katkestatud seansi jooksul tiritud andmeid.\r\nEelmine cache vib sisaldada phjalikumat informatsiooni; kui sa ei taha seda informatsiooni kaotada, tuleb see taastada ja kustutada praegune cache.\r\n[Mrkus: Seda on siin lihtne teha, kustutades hts-cache/new.* failid]\r\n\r\nKas arvad, et eelmine cache vib sisaldada phjalikumat informatsiooni, ja kas tahad seda taastada? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * KOPEERIMISE VIGA! * *\r\nHTTrack leidis, et praegune veebikoopia on thi. Kui see on uuendus, taastatakse eelmine koopia.\r\nPhjus: esimest leheklge ei leitud, vi on henduse probleemid.\r\n=> Veendu, et veebisait ikka alles on, ja/vi kontrolli proxy seadistust! <= \n\nTip: Click [View log file] to see warning or error messages \n\nVihje: Hoiatuste ja veateadete ngemiseks kliki [Vaata logifaili] Error deleting a hts-cache/new.* file, please do it manually Viga hts-cache/new.* faili kustutamisel, palun tee seda ksitsi Do you really want to quit WinHTTrack Website Copier? Kas sa testi tahad lpetada WinHTTrack Website Copier'i kasutamise? - Mirroring Mode -\n\nEnter address(es) in URL box - Kopeerimine -\n\nSisesta aadress(id) URL-i kasti - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - Interaktiivne nustaja (ksimused) -\n\nSisesta aadress(id) URL-i kasti - File Download Mode -\n\nEnter file address(es) in URL box - Failide tirimine -\n\nSisesta faili(de) aadress(id) URL-i kasti - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - Linkide testimine -\n\nSisesta testitavaid linke sisaldava(te) leh(ted)e aadress(id) URL-i kasti - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Uuendamine -\n\nKontrolli aadressi URL-i kastis ja parameetreid kui tarvis, seejrel kliki nuppu 'NEXT' - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Jtkamine (katkestamise jrel) -\n\nKontrolli aadressi URL-i kastis ja parameetreid kui tarvis, seejrel kliki nuppu 'NEXT' Log files Path Logifailide asukoht Path Asukoht - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror - Linkide listi jrgi kopeerimine -\n\nSisesta URL-i kasti kopeeritavaid linke sisaldava(te) leh(ted)e aadress(id) New project / Import? Uus projekt / importida? Choose criterion Vali tegevus Maximum link scanning depth Linkide maksimaalne skaneerimissgavus Enter address(es) here Sisesta aadress(id) siia Define additional filtering rules Defineeri tiendavad filtreerimisreeglid Proxy Name (if needed) Proxy nimi (kui tarvis) Proxy Port Proxy port Define proxy settings Defineeri proxy seaded Use standard HTTP proxy as FTP proxy Kasuta standardset HTTP proxyt FTP proxyna Path Asukoht Select Path Vali asukoht Path Asukoht Select Path Vali asukoht Quit WinHTTrack Website Copier Lpeta WinHTTrack Website Copier'i kasutamine About WinHTTrack Info WinHTTrack'i kohta Save current preferences as default values Salvesta praegune hlestus vaikevrtusena Click to continue Kliki jtkamiseks Click to define options Kliki seadete defineerimiseks Click to add a URL Kliki URL-i lisamiseks Load URL(s) from text file Laadi URL(-id) tekstifailist WinHTTrack preferences (*.opt)|*.opt|| WinHTTrack'i hlestus (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| Addressinimekirja tekstifail (*.txt)|*.txt|| File not found! Faili ei leia! Do you really want to change the project name/path? Kas sa testi tahad muuta projekti nime/asukohta? Load user-default options? Kas laadida kasutaja vaikimisi seaded? Save user-default options? Kas salvestada kasutaja vaikimisi seaded? Reset all default options? Kas taastada kik vaikimisi seaded? Welcome to WinHTTrack! Tere tulemast WinHTTrack'i! Action: Tegevus: Max Depth Maksimaalne sgavus: Maximum external depth: Maksimaalne vline sgavus: Filters (refuse/accept links) : Filtrid (linkide vlja-/kaasaarvamiseks): Paths Asukohad Save prefs Salvesta seaded Define.. Defineeri... Set options.. Defineeri seaded... Preferences and mirror options: Kopeerimise hlestus: Project name Projekti nimi Add a URL... Lisa URL... Web Addresses: (URL) Veebiaadressid: (URL) Stop WinHTTrack? Kas peatada WinHTTrack? No log files in %s! %s ei ole htegi logifaili! Pause Download? Kas peatada tirimine? Stop the mirroring operation Peata kopeerimine Minimize to System Tray Minimeeri ssteemialasse Click to skip a link or stop parsing Kliki lingi vahelejtmiseks vi kopeerimise peatamiseks Click to skip a link Kliki lingi vahelejtmiseks Bytes saved Salvestatud baite: Links scanned Skaneeritud linke: Time: Aeg: Connections: hendusi: Running: Kimas on: Hide Peida Transfer rate lekandekiirus: SKIP Jta vahele Information Informatsioon Files written: Faile kirjutatud: Files updated: Faile uuendatud: Errors: Vigu: In progress: Tegevus: Follow external links Jrgi vlislinke Test all links in pages Testi kik lingid leheklgedel Try to ferret out all links Pa vlja nuhkida kik lingid Download HTML files first (faster) Tiri HTML-failid kigepealt (kiirem) Choose local site structure Vali kohaliku saidi struktuur Set user-defined structure on disk Defineeri oma saidistruktuur kettal Use a cache for updates and retries Kasuta cache'i uuenduste ja korduste tarvis Do not update zero size or user-erased files ra uuenda nullsuurusega vi kasutaja poolt kustutatud faile Create a Start Page Tee algusleheklg Create a word database of all html pages Loo kigi HTML-leheklgede snade andmebaas Create error logging and report files Tee vealogi ja raporti failid Generate DOS 8-3 filenames ONLY Genereeri AINULT DOS-i 8-3 failinimed Generate ISO9660 filenames ONLY for CDROM medias Genereeri AINULT ISO9660 failinimed CDROM-i jaoks Do not create HTML error pages ra genereeri HTML vealeheklgi Select file types to be saved to disk Vali kettale salvestatavad failitbid Select parsing direction Vali linkide jrgimise suund Select global parsing direction Vali globaalne linkide jrgimise suund Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) Mra URL-ide mberkirjutamise reeglid siselinkidele (mida tiritakse) ja vlislinkidele (mida ei tirita) Max simultaneous connections Maksimaalselt hendusi heaegselt File timeout Maksimaalne faili ooteaeg Cancel all links from host if timeout occurs Thista kik selle hosti lingid, kui ooteaeg lbi saab Minimum admissible transfer rate Minimaalne lubatav lekandekiirus Cancel all links from host if too slow Thista kik selle hosti lingid, kui on liiga aeglane Maximum number of retries on non-fatal errors Maksimaalne korduste arv mittefataalse vea korral Maximum size for any single HTML file he HTML-faili maksimaalne suurus Maximum size for any single non-HTML file he mitte-HTML faili maksimaalne suurus Maximum amount of bytes to retrieve from the Web Maksimaalne veebist vlja otsitav baitide kogus Make a pause after downloading this amount of bytes Tee paus prast selle baidikoguse tirimist Maximum duration time for the mirroring operation Kopeerimisoperatsiooni maksimaalne kestus Maximum transfer rate Maksimaalne lekandekiirus Maximum connections/seconds (avoid server overload) Maksimum hendusi sekundis (vltimaks serveri lekoormust) Maximum number of links that can be tested (not saved!) Maksimaalne testitavate (mitte salvestatavate!) linkide hulk Browser identity Brauseri identiteet Comment to be placed in each HTML file Kommentaar, mis lisatakse igale HTML-failile Back to starting page Tagasi alguslehele Save current preferences as default values Salvesta praegune hlestus vaikevrtusena Click to continue Kliki jtkamiseks Click to cancel changes Kliki muudatustest loobumiseks Follow local robots rules on sites Jrgi saitide kohalikke robotireegleid Links to non-localised external pages will produce error pages Lingid kopeerimata vlisleheklgedele tekitavad vealeheklgi Do not erase obsolete files after update ra kustuta vananenud faile peale uuendamist Accept cookies? Kas aktsepteerida kpsiseid? Check document type when unknown? Kas kontrollida dokumendi tpi, kui on tundmatu? Parse java applets to retrieve included files that must be downloaded? Kas analsida java aplette vajalike lisafailide vljaotsimiseks? Store all files in cache instead of HTML only Silitada kik failid cache'is, mitte ainult HTML-i kujul Log file type (if generated) Logifaili tp (kui on genereeritud) Maximum mirroring depth from root address Maksimaalne kopeerimissgavus algusaadressi suhtes Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) Vliste/keelatud aadresside maksimaalne kopeerimissgavus (vaikimisi 0, s.t. ldse mitte) Create a debugging file Tee veakontrollifail Use non-standard requests to get round some server bugs Kasuta mittestandardset pringut mnest serveri veast mdapsemiseks Use old HTTP/1.0 requests (limits engine power!) Kasuta vana HTTP/1.0 pringut (piirab mootori vimalusi!) Attempt to limit retransfers through several tricks (file size test..) Pa piirata korduvaid lekandeid mitmesuguste trikkidega (failisuuruse test..) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Write external links without login/password Kirjuta vlislingid ilma sisselogimise/paroolita Write internal links without query string Kirjuta siselingid ilma pringustringita Get non-HTML files related to a link, eg external .ZIP or pictures Tiri mitte-HTML failid, nt vlised ZIP-failid vi pildid Test all links (even forbidden ones) Testi kik lingid (ka keelatud) Try to catch all URLs (even in unknown tags/code) Pa ktte saada kik URL-id (ka tundmatud sildid/koodid) Get HTML files first! Tiri HTML-failid kigepealt! Structure type (how links are saved) Struktuuritp (kuidas lingid salvestatakse) Use a cache for updates Kasuta cache'i uuenduste jaoks Do not re-download locally erased files ra tiri uuesti kohalikke kustutatud faile Make an index Tee indeks Make a word database Tee snade andmebaas Log files Logifailid DOS names (8+3) DOS-i nimed (8+3) ISO9660 names (CDROM) ISO9660 nimed (CDROM) No error pages Ilma vealeheklgedeta Primary Scan Rule Peamine filter Travel mode Liikumisviis Global travel mode Globaalne liikumisviis These options should be modified only exceptionally Neid seadeid muuda ainult erandkorras Activate Debugging Mode (winhttrack.log) Aktiveeri veakontrolliolek (winhttrack.log) Rewrite links: internal / external Linkide muutmine: siselingid / vlislingid Flow control Vookontroll Limits Piirangud Identity Identiteet HTML footer HTML-i jalus N# connections henduste arv Abandon host if error Hlga host vea korral Minimum transfer rate (B/s) Minimaalne lekandekiirus Abandon host if too slow Hlga host, kui on liiga aeglane Configure Konfigureeri Use proxy for ftp transfers Kasuta FTP lekannete jaoks proxyt TimeOut(s) Ooteaeg Persistent connections (Keep-Alive) Psivad hendused Reduce connection time and type lookup time using persistent connections Vhenda henduse aega ja tbiotsingu aega, kasutades psivaid hendusi Retries Kordusi Size limit Suuruse piirang Max size of any HTML file (B) HTML-faili maksimaalne suurus Max size of any non-HTML file Mitte-HTML faili maksimaalne suurus Max site size Saidi maksimaalne suurus Max time Maksimaalne aeg Save prefs Salvesta hlestus Max transfer rate Maksimaalne lekandekiirus Follow robots.txt Jrgi robots.txt reegleid No external pages Ilma vlisleheklgedeta Do not purge old files ra hvita vanu faile Accept cookies Aktsepteeri kpsiseid Check document type Kontrolli dokumenditpe Parse java files Analsi Java faile Store ALL files in cache Silita KIK failid cache'is Tolerant requests (for servers) Tolerantsed pringud (serverite jaoks) Update hack (limit re-transfers) Update hack (piirab korduvaid lekandeid) URL hacks (join similar URLs) Force old HTTP/1.0 requests (no 1.1) Kasuta vana HTTP/1.0 pringut (mitte 1.1) Max connections / seconds Maksimaalselt hendusi sekundis Maximum number of links Maksimaalne linkide arv Pause after downloading.. Paus peale ... tirimist Hide passwords Peida paroolid Hide query strings Peida pringustringid Links Lingid Build Struktuur Experts Only Ekspertidele Flow Control Vookontroll Limits Piirangud Browser ID Brauser Scan Rules Filtrid Spider Spider Log, Index, Cache Logi, indeks, cache Proxy Proxy MIME Types Do you really want to quit WinHTTrack Website Copier? Kas sa testi tahad lpetada WinHTTrack Website Copier'i kasutamise? Do not connect to a provider (already connected) ra henda hendusepakkujaga (juba hendatud) Do not use remote access connection ra kasuta kaugjuurdepsuga hendust Schedule the mirroring operation Programmeeri kopeerimisoperatsioon Quit WinHTTrack Website Copier Lpeta WinHTTrack Website Copier'i kasutamine Back to starting page Tagasi alguslehekljele Click to start! Kliki kivitamiseks! No saved password for this connection! Selle henduse jaoks pole salvestatud parooli! Can not get remote connection settings Kaughenduse seadeid ei saa ktte Select a connection provider Vali hendusepakkuja Start Start Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. Palun tpsusta henduse parameetreid, kui tarvis,\nsiis vajuta FINISH kopeerimisoperatsiooni kivitamiseks. Save settings only, do not launch download now. Salvesta seaded ainult. ra alusta tirimist praegu. On hold Ootel Transfer scheduled for: (hh/mm/ss) lekanne on programmeeritud: (hh/mm/ss) Start Start Connect to provider (RAS) henda hendusepakkujaga (RAS) Connect to this provider henda selle hendusepakkujaga Disconnect when finished Lahuta hendus, kui on lpetatud Disconnect modem on completion Lahuta modem lpetamisel \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n(Palun teata meile igast veast vi probleemist)\r\n\r\nArendajad:\r\nKasutajaliides (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nEestikeelne tlge: Tnu Virma About WinHTTrack Website Copier Info WinHTTrack Website Copier'i kohta Please visit our Web page Klasta palun meie veebileheklge! Wizard query Nustaja pring Your answer: Sinu vastus: Link detected.. Leitud link... Choose a rule Vali reegel Ignore this link Ignoreeri seda linki Ignore directory Ignoreeri kausta Ignore domain Ignoreeri domeeni Catch this page only Vta ainult see leheklg Mirror site Saidi kopeerimine Mirror domain Domeeni kopeerimine Ignore all Ignoreeri kiki Wizard query Nustaja pring NO EI File Fail Options Seaded Log Logi Window Aken Help Abi Pause transfer Peata lekanne Exit Vlju Modify options Muuda seadeid View log Vaata logi View error log Vaata vealogi View file transfers Vaata faililekandeid Hide Peida About WinHTTrack Website Copier &WinHTTrack Website Copier'i info Check program updates... Leia &uuemat versiooni... &Toolbar &Nupuriba &Status Bar &Staatuseriba S&plit &Jaota File &Fail Preferences &Hlestus Mirror &Saidikopeerimine Log &Logi Window A&ken Help Abi Exit Vlju Load default options Laadi vaikimisi seaded Save default options Salvesta vaikimisi seaded Reset to default options Taasta vaikimisi seaded Load options... Laadi seaded... Save options as... Salvesta seaded faili... Language preference... Keele valik... Contents... Indeks About WinHTTrack... Info WinHTTrack'i kohta... New project\tCtrl+N &Uus projekt\tCtrl+N &Open...\tCtrl+O &Ava...\tCtrl+O &Save\tCtrl+S &Salvesta\tCtrl+S Save &As... Salvesta &failina... &Delete... &Kustuta... &Browse sites... Si&rvi saite... User-defined structure Kasutaja-defineeritud struktuur %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\tFaili nimi ilma laiendita (nt: image)\r\n%N\tFaili nimi koos laiendiga (nt: image.gif)\r\n%t\tFaili laiend ainult (nt: gif)\r\n%p\tAsukoht [ilma /-ta lpus] (nt: /someimages)\r\n%h\tHosti nimi (nt: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tDOS-i lhinimi (nt: %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Nidis:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Proxy settings Proxy seaded Proxy address: Proxy aadress: Proxy port: Proxy port: Authentication (only if needed) Identifitseerimine (vajaduse korral) Login Kasutajanimi Password Parool Enter proxy address here Sisesta proxy aadress siia Enter proxy port here Sisesta proxy port siia Enter proxy login Sisesta proxy kasutajanimi Enter proxy password Sisesta proxy parool Enter project name here Sisesta siia projekti nimi Enter saving path here Sisesta siia asukoht projekti salvestamiseks Select existing project to update Vali olemasolev projekt uuendamiseks Click here to select path Kliki siin asukoha valimiseks Select or create a new category name, to sort your mirrors in categories HTTrack Project Wizard... HTTrack'i projektinustaja New project name: Uue projekti nimi: Existing project name: Olemasoleva projekti nimi: Project name: Projekti nimi: Base path: Baas-asukoht: Project category: C:\\My Web Sites C:\\Minu veebisaidid Type a new project name, \r\nor select existing project to update/resume Sisesta uue projekti nimi, \r\nvi vali olemasolev projekt uuendamiseks/jtkamiseks New project Uus projekt Insert URL Sisesta URL URL: URL: Authentication (only if needed) Identifitseerimine (vajaduse korral) Login Kasutajanimi Password Parool Forms or complex links: Vormid vi keerulised lingid: Capture URL... Pa URL... Enter URL address(es) here Sisesta URL aadress(id) siia Enter site login Sisesta saidi kasutajanimi Enter site password Sisesta saidi parool Use this capture tool for links that can only be accessed through forms or javascript code Kasuta seda pdevahendit linkide korral, millele pseb ligi ainult vormide vi javascripti koodide kaudu Choose language according to preference Vali kasutuskeel Catch URL! Pa URL! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. Palun sea oma brauseri proxy hlestus ajutiselt jrgmistele vrtustele (kopeeri/kleebi proxy aadress ja port).\nSiis kliki vormi SUBMIT-nuppu brauseri lehekljel, vi kliki spetsiifilist linki, mida tahad pda. This will send the desired link from your browser to WinHTTrack. See saadab soovitud lingi sinu brauserist WinHTTrack'ile. ABORT LOOBU Copy/Paste the temporary proxy parameters here Kopeeri/kleebi ajutised proxy parameetrid siit Cancel Loobu Unable to find Help files! Abiinfo faile ei leia! Unable to save parameters! Parameetreid ei saa salvestada! Please drag only one folder at a time Palun lohista ainult ks kaust korraga Please drag only folders, not files Palun lohista ainult kaustu, mitte faile Please drag folders only Palun lohista ainult kaustu Select user-defined structure? Kas valida kasutaja-defineeritud struktuur? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! Palun veendu, et kasutaja defineeritud stringid on ikka korrektsed,\nvastasel juhul tulevad failinimed vigased! Do you really want to use a user-defined structure? Kas sa testi tahad valida kasutaja-defineeritud struktuuri? Too manu URLs, cannot handle so many links!! Liiga palju URL-e. Nii palju linke ei suuda ksitleda!! Not enough memory, fatal internal error.. Mlu ei ole piisavalt, fataalne sisemine viga... Unknown operation! Tundmatu operatsioon! Add this URL?\r\n Kas lisada see URL?\r\n Warning: main process is still not responding, cannot add URL(s).. Hoiatus: phiprotsess ei reageeri ikka veel, ei saa lisada URL-e... Type/MIME associations Tp/MIME seosed File types: Failitbid: MIME identity: MIME identiteet: Select or modify your file type(s) here Vali vi muuda oma failitpe siin Select or modify your MIME type(s) here Vali vi muuda oma MIME-tpe siin Go up Mine les Go down Mine alla File download information Failitirimise informatsioon Freeze Window Fikseeri aken More information: Tiendav informatsioon: Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download Tere tulemast WinHTTrack Website Copier'i!\n\nPalun kliki NEXT-nuppu, et\n\n- alustada uut projekti vi\n- jtkata pooleliolevat tirimist File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS Failinimed laiendiga:\nFailinimed, mis sisaldavad:\nSee failinimi:\nKaustanimed, mis sisaldavad:\nSee kaustanimi:\nLingid selles domeenis:\nLingid domeenides, mis sisaldavad:\nLingid sellest hostist:\nLingid, mis sisaldavad:\nSee link:\nKIK LINGID Show all\nHide debug\nHide infos\nHide debug and infos Nita kik\nPeida veakontroll\nPeida info\nPeida veakontroll ja info Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. Saidi struktuur (vaikimisi)\nHtml -> web/, pildid/teised failid -> web/images/\nHtml -> web/html/, pildid/teised -> web/images/\nHtml -> web/, pildid/teised -> web/\nHtml -> web/, pildid/teised -> web/xxx/ (kus xxx on faili laiend)\nHtml -> web/html/, pildid/teised -> web/xxx/\nSaidi struktuur, ilma www.domain.xxx/\nHtml -> saidi_nimi/, pildid/teised failid -> saidi_nimi/images/\nHtml -> saidi_nimi/html/, pildid/teised -> saidi_nimi/images/\nHtml -> saidi_nimi/, pildid/teised -> saidi_nimi/\nHtml -> saidi_nimi/, pildid/teised -> saidi_nimi/xxx/\nHtml -> saidi_nimi/html/, pildid/teised -> saidi_nimi/xxx/\nKik failid -> web/ (juhuslike nimedega)\nKik failid -> saidi_nimi/ (juhuslike nimedega)\nKasutaja defineeritud struktuur... Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first Skaneeri ainult\nSalvesta HTML-failid\nSalvesta mitte-HTML failid\nSalvesta kik failid (vaikimisi)\nSalvesta HTML-failid kigepealt Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down J samasse kausta\nVib minna alla (vaikimisi)\nVib minna les\nVib minna nii les kui alla Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web J samale aadressile (vaikimisi)\nJ samasse domeeni\nJ samasse ladomeeni\n Mine igale poole veebis Never\nIf unknown (except /)\nIf unknown Mitte kunagi\nKui on tundmatu (v.a. /)\nKui on tundmatu no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules ilma robots.txt reegliteta\nrobots.txt v.a. nustaja\njrgi robots.txt reegleid normal\nextended\ndebug normaalne\nlaiendatud\nveakontrolliga Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download Tiri veebisaidid\nTiri veebisaidid + ksimused\nTiri eraldi failid\nTiri kik saidid lehtedel (hulgikopeerimine)\nTesti lingid lehtedel (jrjehoidjate test)\n* Jtka katkestatud tirimist\n* Uuenda olemasolevat Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL Suhteline URI / Absoluutne URL (vaikimisi)\nAbsoluutne URL / Absoluutne URL\nAbsoluutne URI / Absoluutne URL\nAlgne URL / Algne URL Open Source offline browser Website Copier/Offline Browser. Copy remote websites to your computer. Free. httrack, winhttrack, webhttrack, offline browser URL list (.txt) Previous Next URLs Warning Your browser does not currently support javascript. For better results, please use a javascript-aware browser. Thank you You can now close this window Server terminated A fatal error has occurred during this mirror httrack-3.49.5/lang/Deutsch.txt0000644000175000017500000010713214360553245013271 00000000000000LANGUAGE_NAME Deutsch LANGUAGE_FILE Deutsch LANGUAGE_ISO de LANGUAGE_AUTHOR Rainer Klueting (rk-htt at centermail.net) \r\nBastian Gorke (bastiang at yahoo.com) \r\nRudi Ferrari (Wyando at netcologne.de) \r\nMarcus Gaza (MarcusGaza at t-online.de) \r\n LANGUAGE_CHARSET ISO-8859-1 LANGUAGE_WINDOWSID German (Standard) OK OK Cancel Abbrechen Exit Beenden Close Schlieen Cancel changes nderungen verwerfen Click to confirm nderungen bernehmen Click to get help! Hilfe aufrufen Click to return to previous screen Zurck zum letzten Schritt Click to go to next screen Weiter zum nchsten Schritt Hide password Passwort nicht anzeigen Save project Projekt speichern Close current project? Aktives Projekt schlieen? Delete this project? Dieses Projekt lschen? Delete empty project %s? Leeres Projekt %s lschen? Action not yet implemented Funktion noch nicht verfgbar Error deleting this project Fehler beim Lschen des Projekts Select a rule for the filter Whlen Sie eine Regel fr den Filter Enter keywords for the filter Schlsselwrter fr den Filter Cancel Abbrechen Add this rule Diese Regel hinzufgen Please enter one or several keyword(s) for the rule Ein oder mehrere Schlsselwrter fr die Regel eingeben Add Scan Rule Filterregel hinzufgen Criterion Filterregel: String Schlsselwort eingeben: Add Hinzufgen Scan Rules Filterregeln Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Verwenden Sie Platzhalter, um URLs oder verknpfte Seiten ein- oder auszuschlieen.\n\nMehrere Filterregeln hintereinander \nmssen durch Leerzeichen getrennt sein.\nBeispiel: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Exclude links Link(s) ausschlieen Include link(s) Link(s) einschlieen Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) Tipp: Um ALLE GIF-Dateien einzuschlieen, schreiben Sie z.B. +www.someweb.com/*.gif. \n(+*.gif / -*.gif schliet ALLE GIFs auf ALLEN Seiten ein/aus.) Save prefs Einstellungen speichern Matching links will be excluded: Auszuschlieende Links: Matching links will be included: Einzuschlieende Links: Example: Beispiel: gif\r\nWill match all GIF files gif\r\nFindet alle GIF-Dateien blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' blue\r\nFindet alle Dateien, die 'blue' enthalten, wie 'bluesky-small.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' bigfile.mov\r\nFindet 'bigfile.mov', aber nicht 'bigfile2.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\nFindet alle Links zu Ordnern, deren Name 'cgi' enthlt, wie /cgi-bin/somecgi.cgi cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\nFindet Links zu Ordnern namens 'cgi-bin' (aber z.B. nicht zu 'cgi-bin-2') someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb.com\r\nFindet Links wie www.someweb.com, private.someweb.com etc. someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. someweb\r\nFindet Links wie www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.someweb.com\r\nFindet Links wie www.someweb.com/... (aber nicht wie private.someweb.com/...) someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. someweb\r\nFindet Links wie www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/someweb.html\r\nFindet nur die Datei 'www.test.com/test/someweb.html'. Bitte beachten: Der Pfad muss vollstndig angegeben werden (URL und Pfadangabe). All links will match Alle Verknpfungen sind eingeschlossen Add exclusion filter Ausschlussfilter hinzufgen Add inclusion filter Einschlussfilter hinzufgen Existing filters Aktuelle Filterregeln Cancel changes nderungen verwerfen Save current preferences as default values Aktuelle Einstellungen als Standard speichern Click to confirm Zum Besttigen klicken No log files in %s! Keine Protokolldateien in %s! No 'index.html' file in %s! Keine Datei 'index.html' in %s! Click to quit WinHTTrack Website Copier Hier klicken, um WinHTTrack Website Copier zu beenden View log files Protokolldateien anzeigen Browse HTML start page HTML-Startseite anzeigen End of mirror Kopie der Web-Site abgeschlossen View log files Protokolldateien anzeigen Browse Mirrored Website Kopierte Seiten anzeigen New project... Neues Projekt... View error and warning reports Fehler- und Hinweisprotokoll zeigen View report Protokoll zeigen Close the log file window Protokollfenster schlieen Info type: Informationskategorie: Errors Fehler Infos Informationen Find Suchen Find a word Wort suchen Info log file Hinweisprotokoll Warning/Errors log file Fehler/Hinweise Unable to initialize the OLE system OLE System kann nicht gestartet werden WinHTTrack could not find any interrupted download file cache in the specified folder! WinHTTrack kann im angegebenen Ordner keine unterbrochene Site-Kopie finden! Could not connect to provider Keine Verbindung zum Provider receive empfangen request anfordern connect verbinden search suchen ready fertig error Fehler Receiving files.. Empfang der Dateien... Parsing HTML file.. Analysieren der HTML Datei... Purging files.. Dateien lschen... Loading cache in progress.. Zwischenspeicher wird geladen... Parsing HTML file (testing links).. Analysieren der HTML Datei (Links testen)... Pause - Toggle [Mirror]/[Pause download] to resume operation Pause - fortfahren mit Menbefehl [Site-Kopie]/[bertragung anhalten] Finishing pending transfers - Select [Cancel] to stop now! Laufende Ubertragungen werden abgeschlossen - Sofortiger Stopp mit [Abbrechen] scanning scannen Waiting for scheduled time.. Eingestellte Startzeit abwarten Connecting to provider Verbindung aufbauen [%d seconds] to go before start of operation [%d Sekunden] bis zum Start Site mirroring in progress [%s, %s bytes] Spiegelung der Website luft [%s, %s Byte] Site mirroring finished! Kopiervorgang beendet A problem occurred during the mirroring operation\n Beim Kopieren der Webseiten ist ein Problem aufgetreten\n \nDuring:\n \r\n\nWhrend:\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! \r\n\nNheres bei Bedarf im Protokoll.\n\n'Beenden' beendet WinHTTrack Website Copier.\n\nDanke, dass Sie WinHTTrack benutzt haben! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! Kopiervorgang abgeschlossen.\n'Beenden' beendet WinHTTrack.\nIn den Protokolldateien knnen Sie prfen, ob Probleme auftraten.\n\nDanke, dass Sie WinHTTrack benutzt haben! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * KOPIERVORGANG ABGEBROCHEN! * *\r\nDer aktuelle temporre Cache wird fr eine knftige Aktualisierung gebraucht. Er enthlt nur Daten, die whrend der soeben abgebrochenen Sitzung heruntergeladen wurden.\r\nEin frher angelegter Cache enthlt unter Umstnden vollstndigere Informationen; wenn Sie diese nicht verlieren wollen, mssen Sie sie wiederherstellen und den aktuellen Cache lschen.\r\n[Hinweis: Dazu werden einfach die Dateien hts-cache/new.* gelscht]\r\n\r\nWollen Sie den vor dieser Sitzung erzeugten Cache wiederherstellen? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * FEHLER BEIM KOPIEREN! * *\r\nDie aktuelle Webseitenkopie ist leer. Wenn es sich um eine Aktualisierung gehandelt hat, ist die letzte Kopie wiederhergestellt worden.\r\nMgliche Ursachen: Entweder wurde(n) die erste(n) Seite(n) nicht gefunden, oder es gab ein Problem mit der Verbindung.\r\n=> Vergewissern Sie sich, dass die Website noch existiert, und/oder berprfen Sie die Einstellungen fr den Proxy! <= \n\nTip: Click [View log file] to see warning or error messages \r\n\n\nTipp: Ein Klick auf [Protokoll zeigen] zeigt Warnungen und Fehlermeldungen an Error deleting a hts-cache/new.* file, please do it manually Fehler beim Lschen einer Datei hts-cache/new.*. Bitte lschen Sie von Hand. Do you really want to quit WinHTTrack Website Copier? WinHTTrack Website Copier beenden? - Mirroring Mode -\n\nEnter address(es) in URL box - Webseiten-Kopiermodus -\n\nAdresse(n) in das URL-Feld eingeben - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - Webseiten-Kopiermodus mit Rckfrage -\n\nAdresse(n) in das URL-Feld eingeben - File Download Mode -\n\nEnter file address(es) in URL box - Datei-Download-Modus -\n\nDatei-Adresse(n) in das URL-Feld eingeben - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - Link-Prfmodus -\n\nZu prfende Adresse(n) in das URL-Feld eingeben - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Aktualisierungs-Modus -\n\nBitte Adresse(n) im URL-Feld kontrollieren, bei Bedarf Parameter prfen, dann auf 'Weiter' klicken - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Fortsetzungs-Modus (nach Abbruch) -\n\nBitte Adresse(n) im URL-Feld kontrollieren, bei Bedarf Parameter prfen, dann auf 'Weiter' klicken Log files Path Protokollordner Path Pfad - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror - Link-Listen-Modus -\n\nBitte in das URL-Feld die Adressen der Seiten eintragen, deren Verknpfungen aufgelistet werden sollen. New project / Import? Neues Projekt / Importieren? Choose criterion Aktion auswhlen Maximum link scanning depth Maximale Verzweigungstiefe Enter address(es) here Adresse(n) hier eintragen Define additional filtering rules Weitere Filterregeln definieren Proxy Name (if needed) Proxy (wenn ntig) Proxy Port Proxy-Port Define proxy settings Proxy-Einstellungen festlegen Use standard HTTP proxy as FTP proxy Standard HTTP-Proxy als FTP-Proxy verwenden Path Pfad Select Path Pfad whlen Path Pfad Select Path Pfad whlen Quit WinHTTrack Website Copier WinHTTrack Website Copier beenden About WinHTTrack ber WinHTTrack Save current preferences as default values Aktuelle Einstellungen als Standard speichern Click to continue Hier klicken zum Weitermachen Click to define options Hier klicken, um Einstellungen vorzunehmen Click to add a URL Hier klicken, um URL hinzuzufgen Load URL(s) from text file URL(s) aus Textdatei laden WinHTTrack preferences (*.opt)|*.opt|| WinHTTrack Einstellungen (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| Textdatei mit Adressenliste (*.txt)|*.txt|| File not found! Datei nicht gefunden! Do you really want to change the project name/path? Wollen Sie Namen und Pfad des Projektes ndern? Load user-default options? Benutzer-Standardeinstellungen laden? Save user-default options? Benutzer-Standardeinstellungen speichern? Reset all default options? Alle Standardeinstellungen zurcksetzen? Welcome to WinHTTrack! Willkommen beim WinHTTrack Website Copier! Action: Aktion: Max Depth Maximale Tiefe: Maximum external depth: Maximale externe Tiefe: Filters (refuse/accept links) : Filterregel (Links ein-/ausschlieen) : Paths Pfade Save prefs Einstellungen speichern Define.. Festlegen... Set options.. Einstellungen... Preferences and mirror options: Einstellungen und Kopieroptionen: Project name Projektname Add a URL... URL hinzufgen... Web Addresses: (URL) Web-Adressen (URLs): Stop WinHTTrack? WinHTTrack beenden? No log files in %s! Keine Protokolldateien in %s! Pause Download? bertragung unterbrechen? Stop the mirroring operation Kopiervorgang stoppen Minimize to System Tray Ausblenden (Symbol in Taskleiste) Click to skip a link or stop parsing Anklicken berspringt Verknpfung oder stoppt den Vorgang Click to skip a link Anklicken berspringt Verknpfung Bytes saved Gespeicherte Bytes: Links scanned Bearbeitete Verknpfungen: Time: Zeit: Connections: Verbindungen: Running: Aktiv: Hide Minimieren Transfer rate bertragungsrate: SKIP AUSLASSEN Information Information Files written: Geschriebene Dateien: Files updated: Aktualisierte Dateien: Errors: Fehler: In progress: In Bearbeitung: Follow external links Externe Verknpfungen durchsuchen Test all links in pages Alle Verknpfungen prfen Try to ferret out all links Allen Verknpfungen zu folgen versuchen Download HTML files first (faster) HTML-Dateien zuerst laden (schneller) Choose local site structure Lokale Seitenstruktur whlen Set user-defined structure on disk Lokale Seitenstruktur selbst definieren Use a cache for updates and retries Zwischenspeicher fr Aktualisierungen und Wiederaufnahme nutzen Do not update zero size or user-erased files Vom Benutzer gelschte oder leere Dateien nicht aktualisieren Create a Start Page Startseite erstellen Create a word database of all html pages Liste mit allen Wrtern in den HTML-Seiten anlegen Create error logging and report files Fehlerprotokoll und Ablaufbericht erstellen Generate DOS 8-3 filenames ONLY NUR Namen im Format DOS 8+3 generieren Generate ISO9660 filenames ONLY for CDROM medias ISO9660-Dateinamen NUR fr CDROMs erzeugen Do not create HTML error pages Keine HTML-Fehlerseiten erstellen Select file types to be saved to disk Dateitypen whlen, die gespeichert werden sollen Select parsing direction Suchreihenfolge whlen Select global parsing direction Allgemeine Suchreihenfolge whlen Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) Einstellen der Regeln zum Anpassen von URLs fr interne (heruntergeladene) und externe (nicht heruntergeladene) Verknpfungen Max simultaneous connections Maximale Zahl der Verbindungen File timeout Maximale Wartezeit fr Dateien Cancel all links from host if timeout occurs Bei berschreiten der Wartezeit alle Verknpfungen zu diesem Host abbrechen Minimum admissible transfer rate Niedrigste geduldete bertragungsrate Cancel all links from host if too slow Alle Verknpfungen zu einem Host abbrechen, der zu langsam ist Maximum number of retries on non-fatal errors Maximale Zahl der Wiederholungsversuche bei nicht fatalem Fehler Maximum size for any single HTML file Maximale Gre einer HTML-Datei Maximum size for any single non-HTML file Maximale Gre einer Nicht-HTML-Datei Maximum amount of bytes to retrieve from the Web Maximalzahl der Bytes, die geholt werden sollen Make a pause after downloading this amount of bytes Pause einlegen, wenn die Anzahl heruntergeladener Bytes grer wird als Maximum duration time for the mirroring operation Hchstdauer des gesamten Kopiervorgangs Maximum transfer rate Maximale bertragungsrate Maximum connections/seconds (avoid server overload) Maximalzahl der Verbindungen pro Sek. (verhindert Server-berlastung) Maximum number of links that can be tested (not saved!) Wie viele Links sollen maximal geprft werden? (Kein Limit fr Speicherung!) Browser identity Browser-Kennung Comment to be placed in each HTML file Kommentar, einzufgen in jede HTML-Datei Back to starting page Zurck zur Startseite Save current preferences as default values Aktuelle Einstellungen als Standard speichern Click to continue Klicken, um fortzufahren Click to cancel changes Klicken, um nderungen rckgngig zu machen Follow local robots rules on sites Lokalen Robot-Regeln auf den Seiten Folge leisten Links to non-localised external pages will produce error pages Verknpfungen zu nicht kopierten externen Seiten fhren zu Fehlerseiten Do not erase obsolete files after update Nach Aktualisierung berflssige Dateien nicht lschen Accept cookies? Cookies annehmen? Check document type when unknown? Dokumenttyp prfen, wenn unbekannt? Parse java applets to retrieve included files that must be downloaded? Java-Applets nach Verknpfungen zu Dateien durchsuchen, die geladen werden mssen? Store all files in cache instead of HTML only Alle Dateien in Zwischenspeicher schreiben, nicht nur HTML-Dateien Log file type (if generated) Dateityp des Protokolls (falls generiert) Maximum mirroring depth from root address Maximale Suchtiefe ab der erste Adresse Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) Maximale Suchtiefe fr externe/verbotene Adressen. (Standard ist 0, also keine externe Suche.) Create a debugging file Datei fr Fehlersuche erstellen Use non-standard requests to get round some server bugs Nicht-standardisierte Anfragen erzeugen (umschifft einzelne Server-Fehler) Use old HTTP/1.0 requests (limits engine power!) Alten Standard HTTP/1.0 benutzen (begrenzt das Arbeitstempo!) Attempt to limit retransfers through several tricks (file size test..) Versuche, mit verschiedenen Tricks die Zahl der Re-Transfers zu begrenzen (Prfung der Dateigre...) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Write external links without login/password Externe Verknpfungen ohne Benutzername/Passwort eintragen Write internal links without query string Interne Verknpfungen ohne Abfragetext schreiben Get non-HTML files related to a link, eg external .ZIP or pictures Verknpfte Nicht-HTML-Dateien laden (Bsp: .ZIP oder Bilder von auerhalb) Test all links (even forbidden ones) Alle Verknpfungen testen (auch verbotene) Try to catch all URLs (even in unknown tags/code) Alle URLs zu finden versuchen (auch in unbekannten Tags und Scripts) Get HTML files first! HTML-Dateien zuerst laden! Structure type (how links are saved) Strukturtyp (Wie Verknpfungen gespeichert werden) Use a cache for updates Zwischenspeicher fr Aktualisierungen benutzen Do not re-download locally erased files Dateien nicht erneut laden, die lokal gelscht wurden Make an index Index erstellen Make a word database Wortliste anlegen Log files Protokolldateien DOS names (8+3) DOS-Namen (8+3) ISO9660 names (CDROM) ISO9660-Namen (CDROM) No error pages Keine Fehlerseiten Primary Scan Rule Haupt-Filterregel Travel mode Suchmethode Global travel mode Globale Suchmethode These options should be modified only exceptionally Normalerweise solten diese Einstellungen nicht gendert werden. Activate Debugging Mode (winhttrack.log) Fehlersuch-Modus aktivieren (winhttrack.log) Rewrite links: internal / external Adressbezge anpassen: intern / extern Flow control Flusskontrolle Limits Begrenzungen Identity Identitt HTML footer HTML-Fuzeile N# connections Anzahl Verbindungen Abandon host if error Host bei Fehler aufgeben Minimum transfer rate (B/s) Minimale bertragungsrate (B/s) Abandon host if too slow Host aufgeben, wenn zu langsam Configure Konfigurieren Use proxy for ftp transfers Proxy fr FTP-bertragungen nutzen TimeOut(s) Timeout(s) Persistent connections (Keep-Alive) Verbindungen halten (Keep-alive) Reduce connection time and type lookup time using persistent connections Offen gehaltene Verbindungen reduzieren Verbindungszeit und Zeit fr Typsuche Retries Wiederholungen Size limit Grenbegrenzung Max size of any HTML file (B) Max. Anzahl Bytes von HTML-Dateien Max size of any non-HTML file Max. Gre einer Nicht-HTML-Datei Max site size Max. Gre der Website Max time Maximale Zeit Save prefs Einstellungen speichern Max transfer rate Maximale bertragungsrate Follow robots.txt Regeln in robots.txt folgen No external pages Keine externen Seiten Do not purge old files Alte Dateien nicht lschen Accept cookies Cookies annehmen Check document type Dokumenttyp prfen Parse java files JAVA-Dateien analysieren Store ALL files in cache ALLE Dateien zwischenspeichern Tolerant requests (for servers) Tolerante Anfragen (fr Server) Update hack (limit re-transfers) Aktualisierungstrick (Re-Transfers begrenzen) URL hacks (join similar URLs) Force old HTTP/1.0 requests (no 1.1) Alte HTTP/1.0-Anfragen erzwingen (nicht 1.1) Max connections / seconds Max. Anzahl Verbindungen pro Sek. Maximum number of links Hchstzahl der Links Pause after downloading.. Nach dem Download warten... Hide passwords Passwrter verbergen Hide query strings Abfragetext nicht anzeigen Links Verknpfungen Build Struktur Experts Only Experten Flow Control Flusskontrolle Limits Grenzwerte Browser ID Browser ID Scan Rules Filterregeln Spider Spider Log, Index, Cache Protokoll, Index, Cache Proxy Proxy MIME Types MIME-Typen Do you really want to quit WinHTTrack Website Copier? WinHTTrack Website Copier beenden? Do not connect to a provider (already connected) Nicht mit Provider verbinden (schon verbunden) Do not use remote access connection Keine Remote-Access-Verbindung benutzen Schedule the mirroring operation Kopierzeitpunkt festlegen Quit WinHTTrack Website Copier WinHTTrack Website Copier beenden Back to starting page Zurck zur Startseite Click to start! Zum Starten klicken! No saved password for this connection! Kein gespeichertes Passwort fr diese Verbindung! Can not get remote connection settings Verbindungseinstellungen knnen nicht ermittelt werden Select a connection provider Verbindungsprovider auswhlen Start Start Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. Bitte korrigieren Sie die Verbindungseinstellungen, wenn ntig,\nund klicken Sie auf 'Fertig stellen', um den Kopiervorgang zu starten. Save settings only, do not launch download now. Nur Einstellungen speichern; Download jetzt nicht starten On hold Angehalten Transfer scheduled for: (hh/mm/ss) bertragung geplant fr: (hh/mm/ss) Start START Connect to provider (RAS) Mit Provider verbinden (RAS) Connect to this provider Mit diesem Provider verbinden Disconnect when finished Nach der Aktion Verbindung trennen Disconnect modem on completion Modemverbindung trennen, wenn fertig \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n(Bitte benachrichtigen Sie uns ber Fehler und Probleme)\r\n\r\nEntwicklung:\r\nOberflche (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for German translations to:\r\nRainer Klueting (rainer@klueting.de) About WinHTTrack Website Copier ber WinHTTrack Website Copier Please visit our Web page Besuchen Sie unsere Webseite! Wizard query Assistenten-Abfrage Your answer: Ihre Antwort: Link detected.. Verknpfung gefunden... Choose a rule Regel whlen Ignore this link Diesen Link ignorieren Ignore directory Ordner ignorieren Ignore domain Domain ignorieren Catch this page only Nur diese Seite holen Mirror site Webseiten-Kopie Mirror domain Domain-Kopie Ignore all Keine Links Wizard query Assistenten-Abfrage NO NEIN File Datei Options Optionen Log Protokoll Window Fenster Help Hilfe Pause transfer bertragung anhalten Exit Beenden Modify options Optionen ndern View log Protokoll anzeigen View error log Fehlerprotokoll anzeigen View file transfers Dateibertragung anzeigen Hide Minimieren About WinHTTrack Website Copier ber WinHTTrack Website Copier Check program updates... Nach neuer Version suchen... &Toolbar &Werkzeugleiste &Status Bar &Statusleiste S&plit &Teilen File Datei Preferences Optionen Mirror Site-Kopie Log Protokoll Window Fenster Help Hilfe Exit Beenden Load default options Standardeinstellungen laden Save default options Standardeinstellungen speichern Reset to default options Standardeinstellungen lschen Load options... Einstellungen laden... Save options as... Einstellungen speichern als... Language preference... Spracheinstellungen... Contents... Inhalt... About WinHTTrack... ber WinHTTrack Website Copier... New project\tCtrl+N &Neues Projekt\tStrg+N &Open...\tCtrl+O &ffnen...\tStrg+O &Save\tCtrl+S &Speichern\tStrg+S Save &As... Speichern &unter... &Delete... &Lschen... &Browse sites... &Webseiten anzeigen... User-defined structure Benutzerdefinierte Struktur %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\tName der Datei ohne Dateityp (Bsp: Bild)\r\n%N\tName der Datei, mit Dateityp (Bsp: Bild.gif)\r\n%t\tDateityp (Bsp: gif)\r\n%p\tPfad [ohne letzten /] (Bsp: /Bilder)\r\n%h\tDomainname (Bsp: www.someweb.com)\r\n%M\tURL MD5 (128 Bits, 32 ASCII-Bytes)\r\n%Q\tAbfragetext MD5 (128 Bits, 32 ASCII-Bytes)\r\n%q\tKurzer Abfragetext MD5 (16 Bits, 4 ASCII-Bytes)\r\n\r\n%s?\tKurzname DOS(ex: %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Beispiel:\t%h%p/%n%q.%t\n->\t\tc:\\Spiegelung\\www.someweb.com\\Bilder\\Bild.gif Proxy settings Proxy-Einstellungen Proxy address: Proxy-Adresse: Proxy port: Proxy-Port: Authentication (only if needed) Authentifizierung (nur wenn bentigt) Login Benutzername (Login) Password Passwort Enter proxy address here Proxy-Adresse hier eintragen Enter proxy port here Proxy-Port hier eintragen Enter proxy login Benutzernamen fr Proxy hier eintragen Enter proxy password Passwort fr Proxy hier eintragen Enter project name here Projektnamen hier eintragen Enter saving path here Hier den Pfad fr das Projekt eintragen Select existing project to update Vorhandenes Projekt zum Aktualisieren auswhlen Click here to select path Hier klicken, um einen Pfad auszuwhlen Select or create a new category name, to sort your mirrors in categories HTTrack Project Wizard... HTTrack Projektassistent New project name: Neuer Projektname: Existing project name: Existierender Projektname: Project name: Projektname: Base path: Basisverzeichnis: Project category: C:\\My Web Sites C:\\Meine Webseiten Type a new project name, \r\nor select existing project to update/resume Neuen Projektnamen eintragen, \r\noder existierendes Projekt zum Aktualisieren oder zur Wiederaufnahme auswhlen New project Neues Projekt Insert URL URL eintragen: URL: URL: Authentication (only if needed) Authentifikation (nur wenn bentigt) Login Benutzername (Login): Password Passwort: Forms or complex links: Formulare oder komplexe Links: Capture URL... Hole URL... Enter URL address(es) here URL hier eintragen Enter site login Benutzername fr Web-Site Enter site password Passwort fr Web-Site Use this capture tool for links that can only be accessed through forms or javascript code Verwenden Sie diese Funktion, um verknpfte Seiten zu holen, die nur ber Formulare oder JavaScript-Code zu erreichen sind. Choose language according to preference Sprache einstellen Catch URL! Diese URL holen! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. ndern Sie bitte die Proxy-Einstellungen des Browsers vorbergehend wie folgt: (Proxy-Adresse und -Port von hier kopieren)\nKlicken Sie dann im Browser auf den Schalter Submit/Absenden o.. des Formulars oder auf die spezielle Verknpfung, die Sie laden wollen. This will send the desired link from your browser to WinHTTrack. Dadurch wird die verknpfte Information vom Browser zu WinHTTrack bertragen. ABORT ABBRECHEN Copy/Paste the temporary proxy parameters here Die temporren Proxyeinstellungen von hier kopieren Cancel Abbrechen Unable to find Help files! Kann Hilfedateien nicht finden! Unable to save parameters! Kann Parameter nicht speichern! Please drag only one folder at a time Bitte immer nur einen Ordner einfgen Please drag only folders, not files Bitte nur Ordner einfgen, keine Dateien Please drag folders only Bitte nur Ordner einfgen Select user-defined structure? Benutzerdefinierte Struktur fr Site-Kopie whlen? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! Bitte prfen Sie, ob die benutzerdefinierte Zeichenkette korrekt ist.\nAndernfalls entstehen unsinnige Dateinamen. Do you really want to use a user-defined structure? Mchten Sie wirklich eine benutzerdefinierte Struktur whlen? Too manu URLs, cannot handle so many links!! Zu viele URLs! So viele Links knnen nicht bearbeitet werden! Not enough memory, fatal internal error.. Nicht genug Speicher. Kritischer interner Fehler... Unknown operation! Unbekannte Operation! Add this URL?\r\n Diese URL hinzufgen?\r\n Warning: main process is still not responding, cannot add URL(s).. Warnung: Hauptprozess antwortet nicht; kann keine URLs hinzufgen. Type/MIME associations Typ/MIME-Verknpfungen File types: Dateitypen: MIME identity: MIME-Entsprechung Select or modify your file type(s) here Dateityp(en) hier auswhlen oder ndern Select or modify your MIME type(s) here MIME-Entsprechung(en) hier auswhlen oder ndern Go up Nach oben Go down Nach unten File download information Informationen zum Datei-Download Freeze Window Fenster fixieren More information: Weitere Informationen: Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download Willkommen beim WinHTTrack Website Copier!\n\nBitte auf WEITER klicken,\n\n- um ein neues Projekt zu beginnen\n- oder einen unterbrochenen Kopiervorgang\n wieder aufzunehmen. File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS Dateityp:\nDateiname enthlt:\nDiese Datei:\nPfadname enthlt:\nDieser Pfad:\nLinks zu dieser Domain:\nDomainname enthlt:\nLinks zu diesem Server:\nLink enthlt:\nDieser Link:\nALLE LINKS Show all\nHide debug\nHide infos\nHide debug and infos Alles zeigen\nInfos fr Fehlersuche speichern\nAllgemeine Hinweise speichern\nFehler und Hinweise speichern Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. Site-Struktur (Standard)\nHtml in web/, Bilder und anderes in web/images/\nHtml in web/html, Bilder und anderes in web/images\nHtml in web/, Bilder und anderes in web/\nHtml in web/, Bilder und anderes in web/xxx, mit xxx wie Dateityp\nHtml in web/html, Bilder und anderes in web/xxx\nSite-Struktur, ohne www.domain.xxx/\nHtml in site_name/, Bilder und anderes in site_name/images/\nHtml in site_name/html, Bilder und anderes in site_name/images\nHtml in site_name/, Bilder und anderes in site_name/\nHtml in site_name/, Bilder und anderes in site_name/xxx\nHtml in site_name/html, Bilder und anderes in site_name/xxx\nAlle Dateien in web/, mit Zufallsnamen (Spielerei!)\nAlle Dateien in site_name/, mit Zufallsnamen (Spielerei!)\nBenutzerdefinierte Struktur... Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first Nur Verknpfungen analysieren\nHTML-Dateien speichern\nNicht-HTML-Dateien speichern\nAlle Dateien speichern (Standard)\nZuerst HTML-Dateien speichern Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down Im selben Ordner bleiben\nKann nach unten gehen (Standard)\nKann nach oben gehen\nKann nach oben und unten gehen Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web Bei Adresse bleiben (Standard)\nIn Domain bleiben\nIn Top-Level-Domain bleiben\nFreie Suche berall im Web Never\nIf unknown (except /)\nIf unknown Nie\nWenn unbekannt (ohne /)\nWenn unbekannt no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules Regeln in robots.txt ignorieren\nrobots.txt folgen, auer Filtern\nRegeln in robots.txt folgen normal\nextended\ndebug Normal\nErweitert\nFehlersuche Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download Automatische Web-Site-Kopie\nWeb-Site-Kopie mit Rckfrage\nSpezielle Dateien laden\nZu allen Links verzweigen (Kopie mehrerer Sites)\nLinks auf den Seiten testen (Lesezeichen prfen)\n* Unterbrochenen Kopiervorgang fortsetzen\n* Vorhandene Kopie aktualisieren Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL Relative URL / Absolute URL (Standard)\nAbsolute URL / Absolute URL\nAbsolute URL / Absolute URL\nUnvernderte URL / Unvernderte URL Open Source offline browser Open source Offline-Browser Website Copier/Offline Browser. Copy remote websites to your computer. Free. Webseiten-Kopierer/Offline-Browser. Kopien kompletter Internetangebote auf dem eigenen PC erstellen. Freeware httrack, winhttrack, webhttrack, offline browser httrack, winhttrack, webhttrack, offline browser URL list (.txt) URL Liste (.txt) Previous Zurck Next Weiter URLs URLs Warning Warnung Your browser does not currently support javascript. For better results, please use a javascript-aware browser. Ihr Browser untersttzt kein Javascript, oder es ist abgeschaltet. Eine bessere Darstellung erhalten Sie mit einem Javascript-fhigen Browser. Thank you Vielen Dank You can now close this window Sie knnen dieses Fenster jetzt schlieen Server terminated Der Server wurde beendet A fatal error has occurred during this mirror Fataler Fehler whrend der Webseiten-Kopie httrack-3.49.5/lang/Dansk.txt0000644000175000017500000010525314360553245012734 00000000000000LANGUAGE_NAME Dansk LANGUAGE_FILE Dansk LANGUAGE_ISO da LANGUAGE_AUTHOR Jesper Bramm (bramm@get2net.dk)\r\nscootergrisen\r\n LANGUAGE_CHARSET ISO-8859-1 LANGUAGE_WINDOWSID Danish OK OK Cancel Annullr Exit Afslut Close Luk Cancel changes Annullr ndringer Click to confirm Klik OK for at godkende Click to get help! Klik for at f hjlp! Click to return to previous screen Klik for at se den forrige skrm Click to go to next screen Klik for at se den nste skrm Hide password Skjul adgangskode Save project Gem projekt Close current project? Vil du lukke det aktuelle projekt ? Delete this project? Slette dette projekt ? Delete empty project %s? Vil du slette det tomme projekt med navnet: %s? Action not yet implemented Denne handling er endnu ikke implementeret Error deleting this project Der opstod fejl under sletningen af dette projekt Select a rule for the filter Vlg en regel til filteret Enter keywords for the filter Indtast ngleord til filteret Cancel Annullr Add this rule Tilfj denne regel Please enter one or several keyword(s) for the rule Indtast et eller flere ngleord for denne regel Add Scan Rule Tilfj en skanningsregel Criterion Kriterie: String Streng Add Tilfj Scan Rules Skanningsregler Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Brug 'Jokertegn' [ * ] til at udelukke eller medtage URL' er eller links.\nDu kan indstte flere skanningsstrenge i samme linje.\nBrug mellemrum som separatortegn.\n\nEksempel: +*.zip -www.*.dk -www.*.edu/cgi-bin/*.cgi Exclude links Udeluk link(s) Include link(s) Medtag link(s) Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) Tip: For at medtage ALLE GIF-filer, s prv at bruge: +www.eksempel.dk/*.gif. \n(+*.gif / -*.gif inkluderer/ekskluderer ALLE GIF-filer fra alle websteder) Save prefs Gem foretrukne indstillinger Matching links will be excluded: Matchende links udelukkes Matching links will be included: Matchende links medtages: Example: Eksempel: gif\r\nWill match all GIF files gif\r\nVil matche alle .GIF filer blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' gul\r\nMedtager alle filer med en matchende 'gul'-understreng, ssom 'gulsky-lille.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' storfil.mov\r\nVil medtage filen 'storfil.mov', men ikke filen 'storfil2.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\nvil finde links med mappenavne der matcher understrengen 'cgi', ssom /cgi-bin/nogetcgi.cgi cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\nvil finde links med mappenavne der matcher hele tekststrengen 'cgi-bin', men ikke 'cgi-bin-2' someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. eksempel.dk\r\nFinder links med matchende understreng, ssom www.eksempel.dk, privat.eksempel.dk osv. someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. eksempel\r\nFinder links med matchende mappe-understreng, ssom www.eksempel.dk, www.eksempel.edu, privat.eksempel.andetweb.dk osv. www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.eksempel.dk\r\nFinder links der matcher hele understrengen 'www.eksempel.dk' , (men IKKE links, ssom privat.eksempel.dk/..) someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. eksempel\r\nFinder ethvert link med matchende understreng, ssom www.eksempel.dk/.., www.test.abc/franogetweb/index.html, www.test.abc/test/eksempel.html osv. www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.dk/test/eksempel.html\r\nFinder kun 'www.test.dk/test/eksempel.html' file. Bemrk at du skal skrive den fulde sti [URL + webstedsti] All links will match Alle links vil matche Add exclusion filter Tilfj udelukkelses-filter Add inclusion filter Tilfj et inkluderings-filter Existing filters Eksisterende filtre Cancel changes Annullr ndringer Save current preferences as default values Gem nuvrende indstillinger som standardindstillinger Click to confirm Klik for at bekrfte No log files in %s! Der findes ingen logfil i %s! No 'index.html' file in %s! Der er ingen 'index.html'-fil i %s! Click to quit WinHTTrack Website Copier Klik for at afslutte WinHTTrack Website Copier View log files Vis logfiler Browse HTML start page Se HTML-startside End of mirror Kopieringen af websted er afsluttet View log files Vis logfiler Browse Mirrored Website Gennemse kopi-websted New project... Nyt projekt... View error and warning reports Vis rapport med fejl og advarsler View report Vis rapport Close the log file window Luk logfil vinduet Info type: Informationstype Errors Fejl Infos Information Find Sg Find a word Sg efter et ord Info log file Info logfil Warning/Errors log file Advarsel/fejl-logfil Unable to initialize the OLE system Kan ikke starte OLE-systemet WinHTTrack could not find any interrupted download file cache in the specified folder! WinHTTrack kunne ikke finde nogen afbrudte download filcache i den angivne mappe! Could not connect to provider Kunne ikke oprette forbindelse til udbyder receive modtager request anmoder connect opret forbindelse search sger ready klar error fejl Receiving files.. Modtager filer... Parsing HTML file.. Overfrer HTML-fil... Purging files.. Sletter filer... Loading cache in progress.. Indlser cache... Parsing HTML file (testing links).. Overfrer HTML-fil (tester links)... Pause - Toggle [Mirror]/[Pause download] to resume operation Pause - Vlg fra menuen [Kopir]/[Pause download] for at genoptage overfrslen Finishing pending transfers - Select [Cancel] to stop now! Afslutter igangvrende overfrsler - Vlg Annullr for at afslutte nu! scanning skanner Waiting for scheduled time.. Venter p planlagt tidspunkt... Connecting to provider Opretter forbindelse til udbyder [%d seconds] to go before start of operation [%d sekunder] inden denne handling starter Site mirroring in progress [%s, %s bytes] Websted kopieres nu [%s, %s byte] Site mirroring finished! Kopieringen af websted er afsluttet! A problem occurred during the mirroring operation\n Der opstod et problem under kopieringen af websted\n \nDuring:\n \nSamtidigt:\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! Se eventuelt logfilen.\n\nKlik AFSLUT for at lukke WinHTTrack Website Copier.\n\nTak for at du brugte WinHTTrack! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! Kopiering af websted fuldfrt.\nKlik OK for at afslutte WinHTTrack.\nSe logfil(erne) for at kontrollere at alt forlb OK.\n\nTak for at du brugte WinHTTrack!\r\n * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * KOPIERINGEN ER AFBRUDT! * *\r\nDen nuvrende cache er pkrvet for alle opdaterings operationer og indeholder kun data der er downloadet med den aktuelle afbrudte session.\r\nDen tidligere cache kan indeholde mere fyldestgrende information; hvis du nsker at bevare den information, skal du gendanne den og slette den aktuelle cache.\r\n[Note: Dette kan nemt gres ved at slette 'hts-cache/new.* files]\r\n\r\nTror du den tidligere cache-fil muligvis indeholder mere fyldestgrende information, og vil du gendanne denne? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * KOPIERINGS FEJL! * *\r\nWinHTTrack har opdaget at den igangvrende kopiering er tom. Hvis du var i gang med at opdatere en kopi, vil det tidligere indhold blive gendannet.\r\nMulig rsag: Den frste side kunne enten ikke findes eller der opstod et problem med forbindelsen.\r\n=> Kontroller at webstedet findes og/eller kontroller Proxy-indstillingerne! <= \n\nTip: Click [View log file] to see warning or error messages \n\nTip: Klik [Vis logfiler] for at se advarsels- og fejlmeddelelser Error deleting a hts-cache/new.* file, please do it manually Der opstod en fejl i forbindelse med sletningen af hts-cache/new.*filen. Slet venligst filen manuelt. Do you really want to quit WinHTTrack Website Copier? Vil du afslutte WinHTTrack Website Copier? - Mirroring Mode -\n\nEnter address(es) in URL box - Kopiering af websted -\n\nIndtast webadresse(r) i URL-feltet - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - Interaktiv guide-tilstand (sprgsml) -\n\nIndtast webadresse(r) i URL-feltet - File Download Mode -\n\nEnter file address(es) in URL box - Fil-download-tilstand-\n\nIndtast webadresse(r) i URL-feltet - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - Links test tilstand-\n\nIndtast webadresse(r) i URL-feltet - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Opdateringstilstand -\n\nBekrft webadresse(r) i URL-feltet. Kontroller eventuelt dine indstillinger og klik derefter p 'Nste'. - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Genoptag kopiering (hvis overfrslen blev afbrudt) -\n\nBekrft webadresse(r) i URL-feltet. Kontroller eventuelt dine indstillinger og klik derefter p 'Nste'. Log files Path Stinavn for logfil Path Sti - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror - Links liste -\n\nBrug URL-feltet til at angive adresse(r) p sider der indeholder links der skal kopieres. New project / Import? Nyt projekt / Importr? Choose criterion Vlg kriterier Maximum link scanning depth Maksimal skanningsdybde for links Enter address(es) here Indtast webadresse(r) her Define additional filtering rules Tilfj yderligere filtreringsregler Proxy Name (if needed) Proxy-navn (om ndvendigt) Proxy Port Proxy portnummer Define proxy settings Angiv proxy-indstillinger Use standard HTTP proxy as FTP proxy Brug standard HTTP proxy som FTP-proxy Path Sti Select Path Vlg sti Path Sti Select Path Vlg sti Quit WinHTTrack Website Copier Afslut WinHTTrack Website Copier About WinHTTrack Om WinHTTrack Save current preferences as default values Gem de nuvrende indstillinger som standardindstillinger Click to continue Klik for at fortstte Click to define options Klik for at definere indstillinger Click to add a URL Klik for at tilfje URL Load URL(s) from text file Hent URL(er) fra tekstfil WinHTTrack preferences (*.opt)|*.opt|| WinHTTrack indstillinger (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| Adresseliste-tekstfil (*.txt)|*.txt|| File not found! Filen blev ikke fundet! Do you really want to change the project name/path? Er du sikker p at ndre i projekt/sti-navnet ? Load user-default options? Indls brugerdefinerede standardindstillinger? Save user-default options? Gem brugerdefinerede standardindstillinger? Reset all default options? Nulstil alle standardindstillinger? Welcome to WinHTTrack! Velkommen til WinHTTrack Website Copier! Action: Handling: Max Depth Maksimal dybde: Maximum external depth: Maksimal ekstern dybde: Filters (refuse/accept links) : Filtrerings-regel (udeluk/medtag links) : Paths Sti Save prefs Gem indstillinger Define.. Angiv... Set options.. Angiv indstillinger... Preferences and mirror options: Indstillinger og muligheder: Project name Projektnavn Add a URL... Tilfj URL... Web Addresses: (URL) Webadresse: (URL) Stop WinHTTrack? Stop WinHTTrack? No log files in %s! Der er ingen logfiler i %s! Pause Download? Pause kopieringen? Stop the mirroring operation Stop kopiering af websted? Minimize to System Tray Minimr til proceslinjen Click to skip a link or stop parsing Klik for at springe et link over eller stoppe overfrslen Click to skip a link Klik for at springe et link over Bytes saved Byte gemt: Links scanned Links skannet: Time: Tid: Connections: Forbindelser: Running: Krer: Hide Minimr Transfer rate Overfr. hastighed SKIP Spring over Information Informationer Files written: Filer skrevet: Files updated: Opdaterede filer: Errors: Fejl: In progress: Arbejder: Follow external links Flg eksterne links Test all links in pages Test alle links p siderne Try to ferret out all links Prv at udvide alle links Download HTML files first (faster) Hent HTML-filer frst (hurtigere) Choose local site structure Vlg lokal websted-struktur Set user-defined structure on disk St brugerdefinerede indstillinger for den lokale struktur Use a cache for updates and retries Brug cache til opdateringer og opdateringsforsg Do not update zero size or user-erased files Opdater ikke filer med nul-vrdi eller filer som brugeren har slettet Create a Start Page Opret startside Create a word database of all html pages Opret ord-database fra alle html-sider Create error logging and report files Lav fejllog og rapport-filer Generate DOS 8-3 filenames ONLY Generr KUN DOS-8-3-filnavne Generate ISO9660 filenames ONLY for CDROM medias Generr KUN ISO9660-filnavne for CDROM-medier Do not create HTML error pages Opret ikke HTML-fejlsider Select file types to be saved to disk Vlg filtyper der skal gemmes p disken Select parsing direction Vlg overfrselsretning Select global parsing direction Vlg overordnet overfrselsretning Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) Opret URL-genskrivningsregel for interne links (downloadede links), og eksterne links (ikke downloadede) Max simultaneous connections Maks.antal samtidige forbindelser File timeout Fil time-out Cancel all links from host if timeout occurs Annullr alle links hvis time-out opstr hos vrt Minimum admissible transfer rate Mindste acceptable overfrselshastighed Cancel all links from host if too slow Annullr alle links hvis vrten er for langsom Maximum number of retries on non-fatal errors Maksimal antal forsg efter ikke-fatale fejl Maximum size for any single HTML file Maksimal strrelse for enkelte HTML-filer Maximum size for any single non-HTML file Maksimal strrelse for ikke-HTML-filer Maximum amount of bytes to retrieve from the Web Maksimal antal byte der m hentes p Web Make a pause after downloading this amount of bytes Hold pause efter download af denne mngde byte Maximum duration time for the mirroring operation Maksimal varighed for kopieringen af websted Maximum transfer rate Maksimal overfrselshastighed Maximum connections/seconds (avoid server overload) Maksimal antal forbindelser/sekunder (for at undg server overbelastning) Maximum number of links that can be tested (not saved!) Maksimal antal links der kan testes (ikke gemt!) Browser identity Browser-identitet Comment to be placed in each HTML file Kommentarer der indsttes i alle HTML-filer Back to starting page Tilbage til startsiden Save current preferences as default values Gem nuvrende indstillinger som standardindstillinger Click to continue Klik for at fortstte Click to cancel changes Klik for at annullere ndringerne Follow local robots rules on sites Flg lokale robot-regler p websteder Links to non-localised external pages will produce error pages Links til ikke-fundne eksterne sider, vil medfre fejlside(r) Do not erase obsolete files after update Slet ikke overfldige filer efter opdatering Accept cookies? Acceptr cookies? Check document type when unknown? Kontroller dokumenttypen hvis ukendt? Parse java applets to retrieve included files that must be downloaded? Overfr Java-applets sammen med inkluderede filer der skal downloades? Store all files in cache instead of HTML only Gem alle filer i cache fremfor kun HTML ? Log file type (if generated) Log filtype (hvis genereret) Maximum mirroring depth from root address Maksimal kopieringsdybde fra rod-adressen Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) Maksimal kopieringsdybde for eksterne/forbudte adresser(0, alts ingen, er standard) Create a debugging file Opret en fejlfindings-fil Use non-standard requests to get round some server bugs Brug ikke-standard foresprgsler for at omg server-fejl Use old HTTP/1.0 requests (limits engine power!) Brug gamle HTTP/1.0-type foresprgsler (begrnser effektiviteten!) Attempt to limit retransfers through several tricks (file size test..) Forsg at begrnse gen-overfrsler gennem brug af 'tricks' (test af filstrrelse...) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Forsg at begrnse antallet af links, ved at ignorer lignende URL'er (www.foo.dk==foo.dk, http=https ..) Write external links without login/password Skriv eksterne links uden brug af brugernavn/adgangskode Write internal links without query string Skriv interne links uden foresprgsels-streng Get non-HTML files related to a link, eg external .ZIP or pictures Hent ikke-HTML-filer relateret til et link, eksempelvis .ZIP -filer eller billeder Test all links (even forbidden ones) Test alle links (ogs forbudte links) Try to catch all URLs (even in unknown tags/code) Forsg at fange alle URL'er (ogs selvom html-tags eller kode er ukendt) Get HTML files first! Hent HTML-filer frst! Structure type (how links are saved) Angiv struktur (hvordan links skal gemmes) Use a cache for updates Brug cache for opdateringer Do not re-download locally erased files Hent ikke filer der er slettet lokalt Make an index Opret et indeks Make a word database Opret en ord-database Log files Logfiler DOS names (8+3) DOS-navne (8+3) ISO9660 names (CDROM) ISO9660-navne (CDROM) No error pages Ingen fejl-sider Primary Scan Rule Primr skanningsregel Travel mode Sgemetode Global travel mode Global sgemetode These options should be modified only exceptionally Disse indstillinger br kun ndres undtagelsesvist! Activate Debugging Mode (winhttrack.log) Aktivr fejlfindingstilstand (winhttrack.log) Rewrite links: internal / external Genskriv links: internt/eksternt Flow control Flow-kontrol Limits Begrnsninger Identity Identitet HTML footer HTML-sidefod N# connections Antal forbindelser Abandon host if error Forlad vrt hvis der opstr fejl Minimum transfer rate (B/s) Mindste overfrselshastighed (B/s) Abandon host if too slow Forlad vrten hvis denne er for langsom Configure Konfigurer Use proxy for ftp transfers Brug proxy til FTP-overfrsler TimeOut(s) Timeout(s) Persistent connections (Keep-Alive) Vedvarende forbindelser (Keep-Alive) Reduce connection time and type lookup time using persistent connections Reducr forbindelsestid og typeopslagstid, ved at anvende vedvarende forbindelser Retries Antal forsg Size limit Strrelsesbegrnsning Max size of any HTML file (B) Maksimal strrelse for HTML-filer (B) Max size of any non-HTML file Maksimal strrelse for ikke-HTML-filer Max site size Maksimal strrelse af websted Max time Maksimal tid Save prefs Gem indstillinger Max transfer rate Maksimal overfrselshastighed Follow robots.txt Flg robots.txt No external pages Ingen eksterne sider Do not purge old files Slet ikke gamle filer Accept cookies Acceptr cookies Check document type Kontroller dokumenttypen Parse java files Overfr Java-filer Store ALL files in cache Gem alle filer i cache Tolerant requests (for servers) Acceptr foresprgsler (for servere) Update hack (limit re-transfers) Opdatr hack (begrns gen-overfrsler) URL hacks (join similar URLs) URL-hacks (sammenfj ligende URL'er) Force old HTTP/1.0 requests (no 1.1) Gennemtving HTTP / 1.0-type foresprgsler (glder ikke ver. 1.1) Max connections / seconds Maks.forbindelser/sekunder Maximum number of links Maksimal antal links Pause after downloading.. Pause efter download... Hide passwords Skjul adgangskoder Hide query strings Skjul foresprgsels-streng Links Links Build Struktur Experts Only Kun eksperter Flow Control Flow-kontrol Limits Begrnsninger Browser ID Browser-ID Scan Rules Skanningsregler Spider Spider Log, Index, Cache Log, indeks, cache Proxy Proxy MIME Types MIME-typer Do you really want to quit WinHTTrack Website Copier? Vil du afslutte WinHTTrack Website Copier? Do not connect to a provider (already connected) Opret ikke forbindelse til en udbyder (er allerede forbundet) Do not use remote access connection Brug ikke en fjernadgangsforbindelse Schedule the mirroring operation Planlg kopieringen Quit WinHTTrack Website Copier Afslut WinHTTrack Website Copier Back to starting page Tilbage til startsiden Click to start! Klik for at starte No saved password for this connection! Der er ikke gemt en adgangskode for denne forbindelse Can not get remote connection settings Kan ikke hente fjernforbindelsesindstillinger Select a connection provider Vlg en forbindelsesudbyder Start Start Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. Justr venligst forbindelsesparameterne hvis det er ndvendigt.\nKlik p Udfr for at starte kopieringen. Save settings only, do not launch download now. Gem indstillingerne, men start ikke download endnu. On hold P hold Transfer scheduled for: (hh/mm/ss) Overfrslen planlagt til: (tt/mm/ss) Start Start Connect to provider (RAS) Forbind til en udbyder (RAS) Connect to this provider Forbind til denne udbyder Disconnect when finished Afbryd forbindelsen nr overfrslen er frdig Disconnect modem on completion Afbryd modem nr overfrslen er frdig \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n(finder du fejl eller opstr der problemer s kontakt os venligst)\r\n\r\nUdvikling:\r\nBrugerflade (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche og andre bidragydere\r\nMange tak for dansk oversttelse til:\r\nJesper Bramm (bramm@get2net.dk)\r\nscootergrisen About WinHTTrack Website Copier Om WinHTTrack Website Copier Please visit our Web page Besg vores webside Wizard query Guide-foresprgsel Your answer: Dit svar: Link detected.. Link fundet Choose a rule Vlg en regel Ignore this link Ignorer dette link Ignore directory Ignorer dette bibliotek (mappe) Ignore domain Ignorer domne Catch this page only Gem kun denne side Mirror site Kopir websted Mirror domain Kopir domne Ignore all Ignorer alt Wizard query Guide-foresprgsel NO Nej File Fil Options Indstillinger Log Log Window Vindue Help Hjlp Pause transfer Pause overfrsel Exit Afslut Modify options Rediger indstillinger View log Vis log View error log Vis fejllog View file transfers Vis filoverfrsler Hide Minimr About WinHTTrack Website Copier Om WinHTTrack Website Copier Check program updates... Sg efter opdateringer... &Toolbar &Vrktjslinje &Status Bar &Statuslinje S&plit &Opdel File Filer Preferences Indstillinger Mirror Kopir websted Log Log Window Vindue Help Hjlp Exit Afslut Load default options Indls standardindstillinger Save default options Gem standardindstillinger Reset to default options Nulstil standardindstillinger Load options... Indls indstillinger... Save options as... Gem indstillinger som... Language preference... Foretrukne sprog... Contents... Indhold... About WinHTTrack... Om WinHTTrack... New project\tCtrl+N Nyt projekt\tCtrl+N &Open...\tCtrl+O &bn...\tCtrl+O &Save\tCtrl+S &Gem\tCtrl+S Save &As... Gem &som... &Delete... &Slet... &Browse sites... &Gennemse websteder... User-defined structure Brugerdefineret struktur %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\tFilnavn uden type(eks: image)\r\n%N\tHele filnavnet inklusive filtype (eks: billede.gif)\r\n%t\tKun filtype (eks: gif)\r\n%p\tSti [uden endelsen /] (eks: /noglebilleder)\r\n%h\tVrts navn (eks: www.eksempel.dk)\r\n%M\tMD5 URL (128 bit, 32 ascii byte)\r\n%Q\tMD5 foresprgsel streng (128 bit, 32 ascii byte)\r\n%q\tMD5 kort foresprgselsstreng (16 bit, 4 ascii byte)\r\n\r\n%s?\tKort navn (eks: %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Eksempel:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.eksempel.dk\\noglebilleder\\billede.gif Proxy settings Proxy-indstillinger Proxy address: Proxy-adresse Proxy port: Proxy port Authentication (only if needed) Godkendelse (kun hvis det er ndvendigt) Login Brugernavn Password Adgangskode Enter proxy address here Indtast proxy-adressen her Enter proxy port here Indtast proxy portnummer her Enter proxy login Indtast proxy-brugernavn Enter proxy password Indtast proxy-adgangskode Enter project name here Indtast projektets navn her Enter saving path here Indtast stinavnet hvor projektet skal gemmes Select existing project to update Vlg et projektnavn at opdatere Click here to select path Klik her for at vlge en stil Select or create a new category name, to sort your mirrors in categories Vlg eller opret et nyt kategorinavn, for at sortere dine kopierede websteder i kategorier HTTrack Project Wizard... HTTrack-projektguide... New project name: Nyt projektnavn Existing project name: Eksisterende projektnavn: Project name: Projektnavn: Base path: Sti til projekt: Project category: Projektkategori: C:\\My Web Sites C:\\Mine websteder Type a new project name, \r\nor select existing project to update/resume Skriv navnet p et nyt projekt, \r\neller vlg at opdatere et eksisterende projekt New project Nyt projekt Insert URL Indtast URL URL: Adresse URL: Authentication (only if needed) Godkendelse (kun hvis det er ndvendigt) Login Brugernavn Password Adgangskode Forms or complex links: Formularer eller komplekse links: Capture URL... Fang URL... Enter URL address(es) here Indtast URL-adresse(r) her Enter site login Indtast websted-brugernavn Enter site password Indtast websted-adgangskode Use this capture tool for links that can only be accessed through forms or javascript code Brug dette vrktj til at 'fange' links der kun kan opns adgang til via formularer eller JavaScript-kode Choose language according to preference Vlg dit foretrukne sprog Catch URL! 'Fang' URL! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. St venligst browserens proxy indstillinger til flgende vrdier:(Kopir/Indst proxy-adresse og port).\nKlik p Form SUBMIT knappen p din browser-side, eller klik p specifikke link du nsker at hente.\r\n\r\n This will send the desired link from your browser to WinHTTrack. Dette vil sende det nskede link fra din browser til WinHTTrack. ABORT Annullr Copy/Paste the temporary proxy parameters here Kopir og indst de midlertidige proxy parametre her Cancel Annullr Unable to find Help files! Kan ikke finde Hjlpefilerne! Unable to save parameters! Kan ikke gemme parametrene! Please drag only one folder at a time Trk kun n mappe ad gangen Please drag only folders, not files Trk kun mapper, ikke filer Please drag folders only Trk kun mapper Select user-defined structure? Vlg brugerdefineret struktur ? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! Vr sikker p at den brugerdefinerede streng er korrekt\nI modsat fald vil filnavnene vre ugyldige! Do you really want to use a user-defined structure? Er du sikker p at ville bruge en brugerdefineret struktur ? Too manu URLs, cannot handle so many links!! For mange URL' er, WinHTTrack kan ikke hndtere s mange links!!! Not enough memory, fatal internal error.. Ikke nok hukommelse, fatal intern fejl... Unknown operation! Ukendt handling! Add this URL?\r\n Tilfj denne URL?\r\n Warning: main process is still not responding, cannot add URL(s).. Advarsel: Processen svarer stadigvk ikke ,URL'en kan ikke tilfjes... Type/MIME associations Type/MIME-tilknytning File types: Fil typer: MIME identity: MIME-identitet: Select or modify your file type(s) here Vlg eller ndrer dine filtype(r) her Select or modify your MIME type(s) here Vlg elle ndrer dine MIME-type(r) her Go up G op Go down G ned File download information Fil-downloadinformation Freeze Window Frys vindue More information: Mere information Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download Velkommen til WinHTTrack Website Copier!\n\nKlik p Nste for at for at\n\n-starte et nyt projekt\n-eller genoptage et delvist download. File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS Filnavne med 'efternavn':\nFilnavne der indeholder:\nDette filnavn:\nMappenavne der indeholder:\nDette mappenavn:\nLinks p dette domne:\nLinks p dette domne der indeholder:\nLinks fra denne vrt:\nLinks der indeholder:\nDette Link:\nAlle Links*/ Show all\nHide debug\nHide infos\nHide debug and infos Vis alle\nSkjul fejlfinding\nSkjul information\nSkjul fejlfinding og information Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. Websted-struktur (standard)\nHtml i web/, images/other-filer i web/images/\nHtml i web/html, images/other i web/images\nHtml i web/, images/other i web/\nHtml i web/, images/other i web/xxx, hvor xxx er filendelsen\nHtml i web/html, images/other i web/xxx\nWebsted-struktur, uden www.domne.xxx/\nHtml i webstednavn/, images/other-filer i webstednavn/images/\nHtml i webstednavn/html, images/other i webstednavn/images\nHtml i webstednavn/, images/other i webstednavn/\nHtml i webstednavn/, images/other i webstednavn/xxx\nHtml i webstednavn/html, images/other i webstednavn/xxx\nAlle filer in web/, med tilfldige navne (gadget !)\nAlle filer i webstednavn/, med tilfldige navne (gadget !)\nBrugerdefineret struktur... Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first ust skan\nGem html-filer\nGem ikke-html-filer\nGem alle filer (standard)\nGem html-filer frst Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down Bliv i det samme bibliotek\nKan g ned (standard]\nKan g op\nKan g bde op og ned Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web Bliv p den samme adresse[standard]\nBliv p p samme domne\nBliv p samme top level domne\n G overalt p internettet. Never\nIf unknown (except /)\nIf unknown Aldrig\nUkendt (undtaget /]\nhvis ukendt no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules Ingen robots.txt-regler\nrobots.txt med undtagelse af guiden\nflg reglerne i robots.txt normal\nextended\ndebug Normal\nUdvidet\nFejlfinding Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download Download websted(er)\nDownload websted(er) + sprgsml\nHent enkelte filer\nDownload alle websteder p sider (flere kopieret websteder)\nTest links p siderne (bogmrke test)\n* Fortst afbrudt projekt\n* Opdater tidligere projekt Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL Relativ URL / absolut URL (standard)\nAbsolut URL / absolut URL\nAbsolut URL / absolut URL\nOriginal URL / original URL Open Source offline browser Open source-offline-browser Website Copier/Offline Browser. Copy remote websites to your computer. Free. Webstedskopiering/offline-browser. Kopir fjern-websteder til din computer. Gratis. httrack, winhttrack, webhttrack, offline browser httrack, winhttrack, webhttrack, offline-browser URL list (.txt) URL-liste (.txt) Previous Forrige Next Nste URLs URL'er Warning Advarsel Your browser does not currently support javascript. For better results, please use a javascript-aware browser. Din browser understtter ikke JavaScript, p nuvrende tidspunkt. Brug venligst en browser som forstr JavaScript, for at f et bedre resultat. Thank you Tak You can now close this window Du kan nu lukke vinduet Server terminated Server lukket A fatal error has occurred during this mirror Det opstod en fatal fejl under kopieringen httrack-3.49.5/lang/Croatian.txt0000644000175000017500000011176614360553245013442 00000000000000LANGUAGE_NAME Hrvatski LANGUAGE_FILE Croatian LANGUAGE_ISO hr LANGUAGE_AUTHOR Dominko Adaji (domazd@mail.ru) \r\n LANGUAGE_CHARSET ISO-8859-2 LANGUAGE_WINDOWSID Croatian OK U redu Cancel Odustati Exit Svretak Close Zatvoriti Cancel changes Opozvati izmjene Click to confirm Preuzeti izmjene Click to get help! Kliknuti za pomo! Click to return to previous screen Kliknuti za povratak na prethodni prikaz Click to go to next screen Kliknuti za povratak na slijedei prikaz Hide password Sakriti lozinku Save project Pohraniti projekt Close current project? Zatvoriti tekui projekt? Delete this project? Izbrisati taj projekt? Delete empty project %s? Izbrisati prazni projekt %s? Action not yet implemented Funkcija jo nije raspoloiva Error deleting this project Pogreka tijekom brisanja tog projekta Select a rule for the filter Izaberite neko pravilo za taj filtar Enter keywords for the filter Unesite kljune rijei za taj filtar Cancel Odustati Add this rule Dodati to pravilo Please enter one or several keyword(s) for the rule Unesite molim jednu ili vie kljunih rijei za to pravilo Add Scan Rule Dodati pravilo filtriranja Criterion Pravilo filtra: String Unesite rije: Add Dodati Scan Rules Pravila filtriranja Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Koristite vieznanik za ukljuivanje ili iskljuivanje mrenih adresa ili poveznica.\nU isti redak moete staviti i nekoliko filtarskih pravila uzastopno.\nUpotrijebite praznine kao razdjelnike.\n\nPrimjerice: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Exclude links Izuzete poveznice Include link(s) Obuhvaene poveznice Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) Preporuka: Za obuhvaanje SVIH datoteka GIF, upotrijebite neto poput +www.neka-mrea.com/*.gif. \n(+*.gif / -*.gif e ukljuivat/iskljuivati SVE GIF-ove sa SVIH stranica) Save prefs Pohraniti postavke Matching links will be excluded: Shodne poveznice e biti izuzete: Matching links will be included: Shodne poveznice e biti obuhvaene: Example: Primjer: gif\r\nWill match all GIF files gif\r\nPronalazi sve datoteke GIF blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' blue\r\nPronalazi sve datoteke koje sadravaju 'blue' kao primjerice 'bluesky-small.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' bigfile.mov\r\Pronalazi sve datoteke 'bigfile.mov', ali ne i 'bigfile2.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\nPronalazi sve poveznice s mapama koje u nazivu sadre 'cgi' kao primjerice /cgi-bin/somecgi.cgi cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\nPronalazi poveznice prema mapama koje u nazivu sadre cijeli niz 'cgi-bin' (ali ne i primjerice cgi-bin-2) someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb.com\r\nPronalazi poveznice s pod-nizovima poput www.neka-mrea.com, privatno.neka-mrea.com itd. someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. someweb\r\nPronalazi poveznice sa shodnim pod-nizom poput www.neka-mrea.com, www.neka-mrea.edu, private.neka-mrea.druga-mrea.com itd. www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.someweb.com\r\nPronalazi poveznice koje u nazivu sadre cijeli pod-niz 'www.neka-mrea.com' (ali ne i poveznice poput privatno.neka-mrea.com/..) someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. someweb\r\nPronalazi bilo koju poveznicu sa shodnim pod-nizom poput www.neka-mrea.com/.., www.primjer.abc/s-neke-mree/kazalo.html, www.primjer.abc/primjer/neka-mrea.html itd. www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/someweb.html\r\nPronalazi samo datoteku 'www.primjer.com/primjer/neka-mrea.html'. Imajte na umu da morate unijeti potpunu putanju (URL + putanja do mrenog mjesta) All links will match Obuhvaene su sve poveznice Add exclusion filter Pridodati filtar izuzimanja Add inclusion filter Pridodati filtar obuhvaanja Existing filters Postojei filtri Cancel changes Opozvati izmjene Save current preferences as default values Tekue postavke pohraniti kao polazne vrijednosti Click to confirm Kliknite za potvrivanje No log files in %s! U %s nema datoteka zapisnika! No 'index.html' file in %s! U %s nema datoteke 'index.html'! Click to quit WinHTTrack Website Copier Kliknite za okonavanje rada s WinHTTrack Website Copierom View log files Prikazati zapisnike datoteke Browse HTML start page Prikazati poetnu stranicu HTML-a End of mirror Zrcaljenje sadraja je zavreno View log files Prikazati zapisnike datoteke Browse Mirrored Website Prikazati zrcaljene sadraje New project... Novi projekt... View error and warning reports Prikazati izvjea o pogrekama i upozorenjima View report Prikaz izvjea Close the log file window Zatvoriti okno zapisnike datoteke Info type: Vrsta informacija: Errors Pogreke Infos Informacije Find Pronai Find a word Pronai rije Info log file Zapisnika info-datoteka Warning/Errors log file Datoteka zapisa o upozorenjima/pogrekama Unable to initialize the OLE system Sustav OLE-a nije mogao biti pokrenut WinHTTrack could not find any interrupted download file cache in the specified folder! WinHTTrack u navedenoj mapi nije mogao pronai meupohranu nikakvog prekinutog preuzimanja datoteka! Could not connect to provider Povezivanje s dobavljaem nije uspjelo receive zaprimiti request zatraiti connect povezati search traiti ready gotovo error pogreka Receiving files.. Zaprimanje datoteka.. Parsing HTML file.. Ralanjivanje datoteke HTML-a.. Purging files.. ienje datoteka.. Loading cache in progress.. U tijeku je uitavanje meuspremnika.. Parsing HTML file (testing links).. Ralanjivanje datoteke HTML-a (provjeravanje poveznica).. Pause - Toggle [Mirror]/[Pause download] to resume operation Stanka - Nastavak putem izbornikih naredbi [Zrcaljenje]/[Stanka preuzimanja] Finishing pending transfers - Select [Cancel] to stop now! Zavravaju se tekui prijenosi - Trenutna obustava pomou [Odustati] scanning pregledavanje Waiting for scheduled time.. eka se zadano vrijeme.. Transferring data.. Prenoenje podataka.. Connecting to provider Povezivanje s dobavljaem [%d seconds] to go before start of operation [%d sekundi] do poetka radnje Site mirroring in progress [%s, %s bytes] Zrcaljenje sadraja je u tijeku [%s, %s bajta] Site mirroring finished! Zrcaljenje sadraja je zavreno! A problem occurred during the mirroring operation\n Tijekom zrcaljenja je nastao jedan problem\n \nDuring:\n \nTrajanje:\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! \nPojedinosti po potrebi pogledajte u zapisnikoj datoteci.\n\nKliknite na ZAVRITI za okonavanje rada WinHTTrack Website Copiera.\n\nHvala Vam na uporabi WinHTTracka! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! Zrcaljenje je dovreno.\nKliknite na Svretak za okonavanje rada s WinHTTrackom.\nPogledajte po potrebi u zapisnik(e) kako bi se uvjerili da je sve u redu.\n\nHvala Vam na uporabi WinHTTracka!! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * ZRCALJENJE JE PREKINUTO! * *\r\nTekui privremeni meuspremnik e biti potreban za neku buduu aktualizaciju i sadri samo podatke, koji su preuzeti tijekom upravo prekinutog zasjedanja.\r\nPrethodni meuspremnik moda sadri potpunije podatke; ukoliko te podatke ne elite izgubiti, morate ih ponovno uspostaviti i izbrisati tekui meuspremnik.\r\n[Napomena: To se jednostavno moe napraviti brisanjem datoteka hts-cache/new.*]\r\n\r\nMislite li da ovom zasjedanju prethodei meuspremnik moe sadravati potpunije podatke, i elite li ga ponovno uspostaviti? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * POGREKA PRI ZRCALJENJU! * *\r\nHTTrack je zapazio da je tekue zrcalo prazno. Ukoliko je to bila neka dogradnja, onda je prethodno zrcalo ponovno uspostavljeno.\r\nRazlog: ili prva stranica nije mogla biti pronaena, ili se pak pojavio neki problem.\r\n=> Uvjerite se da dotino mreno mjesto jo uvijek postoji, i/ili provjerite postavke Vaeg usmjerivaa! <= \n\nTip: Click [View log file] to see warning or error messages \n\nPreporuka: Kliknite na [Prikazati zapisnike datoteke], kako bi vidjeli upozorenja ili dojave pogreki Error deleting a hts-cache/new.* file, please do it manually Pogreka pri brisanju datoteke hts-cache/new.*, molim obavite to runo Do you really want to quit WinHTTrack Website Copier? Doista elite okonati rad s WinHTTrack Website Copierom? - Mirroring Mode -\n\nEnter address(es) in URL box - Stanje zrcaljenja -\n\nUnesite adresu(-e) u polje URL-a - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - Interaktivno stanje vodia s povratnim pitanjima -\n\nUnesite adresu(-e) u polje URL-a - File Download Mode -\n\nEnter file address(es) in URL box - Stanje preuzimanja datoteka -\n\nUnesite adresu(-e) datoteke u polje URL-a - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - Stanje provjere poveznica -\n\nUnesite spletnu adresu(-e) s poveznicama za provjeravanje u polje URL-a - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Stanje nadograivanja -\n\nOvjerite adresu(-e) u polje URL-a, provjerite po potrebi parametre a zatim kliknite na gumb 'SLIJEDEE' - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Stanje nadovezivanja (prekinute radnje) -\n\nOvjerite adresu(-e) u polje URL-a, provjerite po potrebi parametre a zatim kliknite na gumb 'SLIJEDEE' Log files Path Putanja zapisnikih datoteka Path Putanja - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror - Stanje nabrajanja poveznica -\n\nKoristite okvir URL-a za unos adrese(-a) stranice(-a) koje sadre dotine poveznice New project / Import? Novi projekat / Uvoz? Choose criterion Odaberite kriterij Maximum link scanning depth Maksimum dubine grananja poveznica Enter address(es) here Ovdje unijeti adresu(-e) Define additional filtering rules Odrediti dodatna pravila filtriranja Proxy Name (if needed) Naziv posrednikog raunalo (po potrebi) Proxy Port Posredniki port Define proxy settings Odredite postavke posrednika Use standard HTTP proxy as FTP proxy Koristiti standardni posrednik HTTP-a kao posrednik FTP-a Path Putanja Select Path Odabrati putanju Path Putanja Select Path Odabrati putanju Quit WinHTTrack Website Copier Okonati rad WinHTTrack Website Copiera About WinHTTrack O programu WinHTTrack Save current preferences as default values Tekue postavke pohraniti kao polazne vrijednosti Click to continue Kliknite ovdje za nastavak Click to define options Kliknite ovdje za odreivanje mogunosti Click to add a URL Kliknite ovdje za dodavanje URL-a Load URL(s) from text file URL(-e) uitati iz tekstualne datoteke WinHTTrack preferences (*.opt)|*.opt|| Postavke WinHTTracka (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| Tekstualna datoteka sa spiskom adresa (*.txt)|*.txt|| File not found! Datoteka nije pronaena! Do you really want to change the project name/path? Doista elite izmijeniti naziv i putanju projekta? Load user-default options? Uitati korisnikom zadane polazne mogunosti? Save user-default options? Pohraniti korisnikom zadane polazne mogunosti? Reset all default options? Sve mogunosti vratiti na polazno? Welcome to WinHTTrack! Dobrodoli u WinHTTrack! Action: Radnja: Max Depth Maksimum dubine Maximum external depth: Maksimum vanjske dubine: Filters (refuse/accept links) : Filtri (odbiti/pohraniti poveznice) : Paths Putanje Save prefs Postavke pohraniti Define.. Odrediti.. Set options.. Postaviti mogunosti.. Preferences and mirror options: Postavke i mogunosti zrcaljenja: Project name Naziv projekta Add a URL... Dodati mrenu adresu... Web Addresses: (URL) Mrene adrese: (URL) Stop WinHTTrack? Zaustaviti WinHTTrack? No log files in %s! U %s nema zapisnikih datoteka! Pause Download? Napraviti stanku preuzimanja? Stop the mirroring operation Zaustaviti postupak zrcaljenja Minimize to System Tray Minimizirati u sustavnu traku odlaganja Click to skip a link or stop parsing Kliknite za preskok poveznice ili zaustavljanje ralanjivanja Click to skip a link Kliknite za preskok poveznice Bytes saved Pohranjeno bajta Links scanned Obraene poveznice Time: Vrijeme: Connections: Veze: Running: Djelatno: Hide Sakriti Transfer rate Stopa prijenosa SKIP PRESKOITI Information Informacija Files written: Zapisano datoteka: Files updated: Aktualizirano datoteka: Errors: Pogreke: In progress: U tijeku: Follow external links Slijediti vanjske poveznice Test all links in pages Na stranicama provjeriti sve poveznice Try to ferret out all links Pokuati slijediti sve poveznice Download HTML files first (faster) Najprije preuzimati datoteke HTML-a (bre) Choose local site structure Odaberite mjesnu strukturu sadraja Set user-defined structure on disk Smi odredite strukturu na disku Use a cache for updates and retries Za dogradnje i ponavljanja koristiti meuspremnik Do not update zero size or user-erased files Ne nadopunjavati datoteke koje su prazne ili one koje je korisnik izbrisao Create a Start Page Napraviti poetnu stranicu Create a word database of all html pages Napraviti spisak rijei sa svih stranica HTML-a Create error logging and report files Napraviti datoteke zapisnika pogreaka i izvjea o tijeku postupka Generate DOS 8-3 filenames ONLY Generirati nazive datoteka SAMO sukladno DOS-u 8-3 Generate ISO9660 filenames ONLY for CDROM medias Generirati nazive datoteka SAMO sukladno ISO9660 za medije CDROM-a Do not create HTML error pages Ne stvarati stranice pogreaka HTML-a Select file types to be saved to disk Odaberite vrste datoteka, koje treba pohranjivati na disku Select parsing direction Odaberite smjer ralanjivanja Select global parsing direction Odaberite opi smjer ralanjivanja Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) Postavke pravila prilagoavanja URL-a za unutarnje (jednom ve preuzimane) i vanjske (ni jednom nisu preuzimane) poveznice Max simultaneous connections Maksimum istovremenih prikljuivanja/veza File timeout Vrijeme ekanja na datoteke Cancel all links from host if timeout occurs Pri prekoraenju vremena ekanja prekinuti sve poveznice prema dotinom raunalu Minimum admissible transfer rate Najnia podnoljiva stopa prijenosa Cancel all links from host if too slow Prekinuti sve poveznice prema ugostiteljskom raunalu ako je presporo Maximum number of retries on non-fatal errors Najvii broj pokuaja ponavljanja pri ne-fatalnim pogrekama Maximum size for any single HTML file Vrhunac veliine neke pojedinane datoteke HTML-a Maximum size for any single non-HTML file Vrhunac veliine neke pojedinane datoteke ne-HTML-a Maximum amount of bytes to retrieve from the Web Vrhunac iznosa u bajtima za dobaviti s mrenih mjesta Make a pause after downloading this amount of bytes Napraviti stanku nakon preuzimanja tog iznosa u bajtima Maximum duration time for the mirroring operation Vrhunac vremena trajanja za postupak zrcaljenja Maximum transfer rate Vrhunac stope prijenosa Maximum connections/seconds (avoid server overload) Najvii broj veza/sekundi (sprjeava preoptereivanje posluitelja) Maximum number of links that can be tested (not saved!) Najvii broj poveznica, koje mogu biti provjeravane (za pohranjivanje nema ogranienja!) Browser identity Pregledniko obiljeje Comment to be placed in each HTML file Komentar koji e biti smjeten u svakoj datoteci HTML-a Back to starting page Natrag na poetnu stranicu Save current preferences as default values Tekue postavke pohraniti kao polazne vrijednosti Click to continue Kliknite za nastavak Click to cancel changes Kliknuti za opoziv izmjena Follow local robots rules on sites Na mrenim mjestima slijediti pravila mjesnih robota Links to non-localised external pages will produce error pages Poveznice prema nepreslikanim vanjskim stranicama e stvarati stranice pogreki Do not erase obsolete files after update Nakon dogradnje ne brisati zastarjele datoteke Accept cookies? Prihvatiti kolai? Check document type when unknown? Provjeravati vrstu datoteke ukoliko je nepoznata? Parse java applets to retrieve included files that must be downloaded? Ralanjivati java applete radi pronalaenja obuhvaenih datoteka, koje jo moraju biti preuzete? Store all files in cache instead of HTML only Spremati sve datoteke u meuspremnik a ne samo one u HTML-u Log file type (if generated) Vrsta datoteke zapisnika (ukoliko je nainjen) Maximum mirroring depth from root address Najvea dubina zrcaljenja od prve adrese Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) Najvea dubina zrcaljenja za vanjske/zabranjene adrese (polazno je 0, tj. bez vanjskog preuzimanja) Create a debugging file Nainiti datoteku za traenje pogreaka Use non-standard requests to get round some server bugs Koristiti nestandardne zahtjeve, kako bi se zaobile neke posluiteljske pogreke Use old HTTP/1.0 requests (limits engine power!) Koristiti zahtjeve starog HTTP/1.0 (ograniava brzinu rada!) Attempt to limit retransfers through several tricks (file size test..) Raznim varkama pokuati ograniiti opetovanja prijenosa (provjera veliine datoteka..) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Preskakanjem slinih URL-a (www.foo.com==foo.com, http=https ..) pokuati ograniiti broj poveznica Write external links without login/password Vanjske poveznice zapisivati bez prijave/lozinke Write internal links without query string Unutarnje poveznice zapisivati bez teksta za upite Get non-HTML files related to a link, eg external .ZIP or pictures Dobavljati datoteke ne-HTML-a, zdruene s poveznicom (primjerice vanjski .ZIP ili slike) Test all links (even forbidden ones) Provjeravati sve poveznice (ak i one zabranjene) Try to catch all URLs (even in unknown tags/code) Pokuati pronai sve URL-e (ak i u nepoznatim oznakama/skriptama) Get HTML files first! Dobaviti najprije datoteke HTML-a! Structure type (how links are saved) Vrsta strukture (kako se pohranjuju poveznice) Use a cache for updates Za dogradnje koristiti meuspremnik Do not re-download locally erased files Ne preuzimati ponovno datoteke, koje su ve mjesno izbrisane Make an index Napraviti kazalo Make a word database Napraviti spisak rijei Log files Zapisnike datoteke DOS names (8+3) Nazivi sukladno DOS-u (8+3) ISO9660 names (CDROM) Nazivi prema ISO9660 (CDROM) No error pages Bez stranica pogreaka Primary Scan Rule Glavno pravilo filtra Travel mode Nain traenja Global travel mode Globalni nain traenja These options should be modified only exceptionally Ove mogunosti bi trebale biti preinaavane samo iznimno Activate Debugging Mode (winhttrack.log) Aktivirati postupak traenja pogreaka (winhttrack.log) Rewrite links: internal / external Prilagoditi poveznike adrese: unutarnje / vanjske Flow control Nadzor toka Limits Granice Identity Obiljeje HTML footer Podnoje HTML-a N# connections Broj veza Abandon host if error Pri pogrekama napustiti ugostitelja Minimum transfer rate (B/s) Minimum stope prijenosa (B/s) Abandon host if too slow Napustiti ugostitelja ukoliko je prespor Configure Prilagoditi Use proxy for ftp transfers Koristiti posrednika za prijenose putem FTP-a TimeOut(s) Vremenska ogranienja Persistent connections (Keep-Alive) Odravati veze (Keep-Alive) Reduce connection time and type lookup time using persistent connections Odravane veze smanjuju vrijeme povezivanja i vrijeme za traenje vrsta Retries Opetovanja Size limit Ogranienje veliine Max size of any HTML file (B) Najvii broj bajta u datotekama HTML-a Max size of any non-HTML file Najvea veliina datoteka ne-HTML-a Max site size Najvea veliina sadraja Max time Najdue vrijeme Save prefs Pohraniti postavke Max transfer rate Vrhunac stope prijenosa Follow robots.txt Slijediti robots.txt No external pages Bez vanjskih stranica Do not purge old files Ne brisati stare datoteke Accept cookies Prihvaati kolaie Check document type Provjeravati vrstu dokumenata Parse java files Ralanjivati datoteke Java Store ALL files in cache Spremati SVE datoteke u meuspremnik Tolerant requests (for servers) Snoljivi zahtjevi (za posluitelje) Update hack (limit re-transfers) Iznuda dogradnji (ograniava opetovane prijenose) URL hacks (join similar URLs) URL hacks (zdruuje sline URL-e) Force old HTTP/1.0 requests (no 1.1) Nametati zahtjeve starog HTTP/1.0 (ne 1.1) Max connections / seconds Najvii broj veza / sekundi Maximum number of links Najvii broj poveznica Pause after downloading.. ekati nakon preuzimanja.. Hide passwords Sakriti lozinke Hide query strings Sakriti tekst za upite Links Poveznice Build Graa Experts Only Samo za strunjake Flow Control Nadzor toka Limits Ogranienja Browser ID Pregledniki ID Scan Rules Pravila filtriranja Spider Pauk Log, Index, Cache Zapisnik, Kazalo, Meuspremnik Proxy Posrednik MIME Types Vrste MIME Do you really want to quit WinHTTrack Website Copier? Doista elite okonati rad WinHTTrack Website Copiera? Do not connect to a provider (already connected) Ne povezivati s dobaviteljem (ve je povezano) Do not use remote access connection Ne koristiti vezu daljinskog pristupa Schedule the mirroring operation Odrediti vrijeme zrcaljenja Quit WinHTTrack Website Copier Okonati rad WinHTTrack Website Copiera Back to starting page Natrag na poetnu stranicu Click to start! Kliknite za poetak! No saved password for this connection! Za tu vezu nema pohranjene lozinke! Can not get remote connection settings Ne mogu se dobiti postavke daljinske veze Select a connection provider Odaberite dobavitelja veze Start Zapoeti Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. Po potrebi prilagodite molim parametre veze,\na zatim stisnite ZAVRITI kako bi pokrenuli zrcaljenje. Save settings only, do not launch download now. Samo pohraniti postavke, preuzimanje ne pokretati sada. On hold Na ekanju Transfer scheduled for: (hh/mm/ss) Prijenos je predvien za: (hh/mm/ss) Start Zapoeti Connect to provider (RAS) Povezati s dobavljaem (RAS) Connect to this provider Povezati s tim dobavljaem Disconnect when finished Prekinuti vezu kada bude gotovo Disconnect modem on completion Po dovretku odvojiti modemsku vezu \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n(Molimo da nas obavijestite o svim pogrekama i potekoama)\r\n\r\nRazvoj:\r\nSuelje (Windows): Xavier Roche\r\nPauk: Xavier Roche\r\nRazrediRalanjivaaJave: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche i drugi suradnici\r\nPUNO HVALA za prijevodne preporuke upuujemo:\r\nRobert Lagadec (rlagadec@yahoo.fr) About WinHTTrack Website Copier O programu WinHTTrack Website Copier Please visit our Web page Molimo da posjetite nau spletnu stranicu Wizard query Upit vodia Your answer: Va odgovor: Link detected.. Pronaena je poveznica.. Choose a rule Birajte pravilo Ignore this link Zanemariti tu poveznicu Ignore directory Zanemariti mape Ignore domain Zanemariti domenu Catch this page only Dobaviti samo tu stranicu Mirror site Sadraj zrcaljenja Mirror domain Domena zrcaljenja Ignore all Bez poveznica Wizard query Upit vodia NO NE File Datoteka Options Mogunosti Log Zapisnik Window Okno Help Pomo Pause transfer Napraviti stanku prijenosa Exit Svretak Modify options Izmijeniti mogunosti View log Prikazati zapisnik View error log Prikazati zapisnik pogreaka View file transfers Prikazati prijenose datoteka Hide Sakriti About WinHTTrack Website Copier O programu WinHTTrack Website Copier Check program updates... Potraiti programske dogradnje... &Toolbar &Traka alatki &Status Bar &Traka stanja S&plit Raz&dijeliti File Datoteka Preferences Postavke Mirror Zrcalo Log Zapisnik Window Okno Help Pomo Exit Svretak Load default options Uitati polazne mogunosti Save default options Pohraniti polazne mogunosti Reset to default options Vratiti polazne mogunosti Load options... Uitati mogunosti... Save options as... Mogunosti pohraniti kao... Language preference... Jezine postavke... Contents... Sadraji... About WinHTTrack... O programu WinHTTrack... New project\tCtrl+N Novi projekat\tCtrl+N &Open...\tCtrl+O &Otvoriti...\tCtrl+O &Save\tCtrl+S &Pohraniti\tCtrl+S Save &As... Pohraniti &kao... &Delete... &Izbrisati... &Browse sites... &Pregledati sadraje... User-defined structure Korisnikom odreena struktura %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\tNaziv datoteke bez nastavka (npr. slika)\r\n%N\tNaziv datoteke s nastavkom (npr. slika.gif)\r\n%t\tSamo nastavak naziva datoteke (npr. gif)\r\n%p\tPutanja [bez svretka /] (npr. /nekeslike)\r\n%h\tNaziv ugostitelja (npr. www.nekisplet.com)\r\n%M\tMD5 URL (128 bita, 32 ascii bajta)\r\n%Q\tTekst upita MD5 (128 bita, 32 ascii bajta)\r\n%q\tKratki tekst upita MD5 (16 bita, 4 ascii bajta)\r\n\r\n%s?\tKratki naziv (npr. %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Primjerice:\t%h%p/%n%q.%t\n->\t\tc:\\zrcaljenje\\www.nekisplet.com\\nekeslike\\slika.gif Proxy settings Postavke posrednika Proxy address: Adresa posrednika: Proxy port: Port posrednika: Authentication (only if needed) Ovjeravanje (samo po potrebi) Login Prijava Password Lozinka Enter proxy address here Ovdje unesite adresu posrednika Enter proxy port here Ovdje unesite port posrednika Enter proxy login Unesite prijavu na posredniku Enter proxy password Unesite lozinku na posredniku Enter project name here Ovdje unesite naziv projekta Enter saving path here Ovdje unesite putanju za pohranjivanje Select existing project to update Birajte postojei projekt za dogradnju Click here to select path Ovdje kliknite za izbor putanje Select or create a new category name, to sort your mirrors in categories Odaberite ili nadjenite neki naziv novoj kategoriji, kako bi Vaa zrcaljenja svrstali u kategorije HTTrack Project Wizard... Pomonik za projekte HTTracka... New project name: Naziv novog projekta: Existing project name: Naziv postojeeg projekta: Project name: Naziv projekta: Base path: Osnovna putanja: Project category: Kategorija projekta: C:\\My Web Sites C:\\Moji spletni sadraji Type a new project name, \r\nor select existing project to update/resume Utipkajte naziv novog projekta, \r\nili odaberite postojei projekat za dograditi/nadovezati New project Novi projekat Insert URL Umetnite URL URL: URL: Authentication (only if needed) Ovjeravanje (samo ako je nuno) Login Prijava Password Lozinka Forms or complex links: Obrasci ili kompleksne poveznice: Capture URL... Zahvatiti URL... Enter URL address(es) here Ovdje unesite adresu(-e) URL-a Enter site login Unesite prijavu za to mreno mjesto Enter site password Unesite lozinku za to mreno mjesto Use this capture tool for links that can only be accessed through forms or javascript code Koristite ovu funkciju za dobavu povezanih sadraja, kojima se inae moe pristupiti samo putem obrazaca ili kda JavaScript Choose language according to preference Izaberite jezik Catch URL! Dobaviti URL! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. Molimo da privremeno izmijenite preglednikove postavke posrednikog posluitelja na slijedee vrijednosti (Adresu i port posrednika odavdje preslikati).\nKliknite zatim na stranici obrasca u Vaem pregledniku na gumb SUBMIT/POSLATI ili pak na odreenu poveznicu, koju elite dobaviti. This will send the desired link from your browser to WinHTTrack. Time e eljena poveznica iz Vaeg preglednika biti poslana u WinHTTrack. ABORT PREKINUTI Copy/Paste the temporary proxy parameters here Privremene postavke posrednikog posluitelja preslikati odavdje Cancel Odustati Unable to find Help files! Nije bilo mogue pronai datoteke Pomoi! Unable to save parameters! Nije bilo mogue pohraniti parametre! Please drag only one folder at a time Povucite miom molim samo jednu mapu istovremeno Please drag only folders, not files Povucite miom molim samo mape, ne datoteke Please drag folders only Povucite miom molim samo mape Select user-defined structure? Za preslik sadraja odabrati korisnikom odreenu strukturu? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! Provjerite molim je li korisnikom odreeni znakovni niz ispravan,\nu suprotnom e nastati iskrivljeni nazivi datoteka! Do you really want to use a user-defined structure? Doista elite koristiti korisnikom odreenu strukturu? Too manu URLs, cannot handle so many links!! Previe je URL-a, ne mogu obraivati toliko poveznica!! Not enough memory, fatal internal error.. Nema dovoljno spremnika, fatalna unutarnja pogreka.. Unknown operation! Nepoznata operacija! Add this URL?\r\n Dodati taj URL?\r\n Warning: main process is still not responding, cannot add URL(s).. Warning: main process is still not responding, cannot add URL(s).. Type/MIME associations Type/MIME associations File types: Vrste datoteka: MIME identity: Istovjetnost MIME: Select or modify your file type(s) here Ovdje birajte ili izmijenite Vae vrste datoteka Select or modify your MIME type(s) here Ovdje birajte ili izmijenite Vae vrste MIME Go up Na gore Go down Na dolje File download information Informacije o preuzimanju datoteka Freeze Window Uglaviti okno More information: Vie informacija: Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download Dobrodoli u program WinHTTrack Website Copier!\n\nKliknite molim na gumb SLIJEDEE kako bi\n\n- zapoeli novi projekat\n- ili nastavili nedovreno preuzimanje File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS Nazivi datoteka s proirenjem:\nNazivi datoteka sadravaju:\nTaj naziv datoteke:\nNazivi mapa sadravaju:\nTaj naziv mape:\nPoveznice u toj domeni:\nPoveznice u domenama sadravaju:\nPoveznice s tog ugostitelja:\nPoveznice sadravaju:\nTa poveznica:\nSVE POVEZNICE Show all\nHide debug\nHide infos\nHide debug and infos Prikazati sve\nSakriti debug\nSakriti informacije\nSakriti debug i informacije Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. Struktura sadraja (polazno)\nHTML u spletu/, slike/ostale datoteke u spletu/slike/\nHTML u spletu/html, slike/ostalo u spletu/slike\nHTML u spletu/, slike/ostalo u spletu/\nHTML u spletu/, slike/ostalo u spletu/xxx, pri emu je xxx proirenje naziva datoteke\nHTML u spletu/html, slike/ostalo u spletu/xxx\nStruktura sadraja, bez www.domena.xxx/\nHTML u naziv_sadraja/, slike/ostale datoteke u nazivu_sadraja/slike/\nHTML u naziv_sadraja/html, slike/ostalo u naziv_sadraja/slike\nHTML u naziv_sadraja/, slike/ostalo u naziv_sadraja/\nHTML u naziv_sadraja/, slike/ostalo u naziv_sadraja/xxx\nHTML u naziv_sadraja/html, slike/ostalo u naziv_sadraja/xxx\nSve datoteke u spletu/, s nasuminim nazivima (gadget !)\nSve datoteke u naziv_sadraja/, s nasuminim nazivima (gadget !)\nKorisnikom odreena struktura.. Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first Samo pregledati poveznice\nStpremiti datoteke HTML-a\nStpremiti datoteke ne-HTML-a\nSpremiti sve datoteke (polazno)\nSpremiti najprije datoteke HTML-a Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down Ostati u istoj mapi\nMoe ii dolje (polazno)\nMoe ii gore\nMoe ii i gore i dolje Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web Ostati na istoj adresi (polazno)\nOstati u istoj domeni\nOstati u istoj demeni vrne razine\nIi posvuda po spletu Never\nIf unknown (except /)\nIf unknown Nikada\nUkoliko je nepoznato (izuzev /)\nUkoliko je nepoznato no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules bez pravila iz robots.txt\nslijediti pravila iz robots.txt s izuzetkom pomonika\nslijediti pravila iz robots.txt normal\nextended\ndebug uobiajeno\nproireno\ndebug Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download Preuzimanje spletnih sadraja\nPreuzimanje spletnih sadraja + pitanja\nDobavljanje pojedinih datoteka\nPreuzimanje svih sadraja sa stranica (viestruko zrcaljenje)\nProvjeriti poveznice u stranicama (provjera poveznica)\n* Nastaviti prekinuto preuzimanje\n* Aktualizirati postojee preuzimanje Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL Relativni URI / Apsolutni URL (polazno)\nApsolutni URL / Apsolutni URL\nApsolutni URI / Apsolutni URL\nIzvorni URL / Izvorni URL Open Source offline browser Open Source offline browser Website Copier/Offline Browser. Copy remote websites to your computer. Free. Preslikavatelj spletnih sadraja/Preglednik mjesnih sadraja. Preslikavanje internetskih sadraja na Vae raunalo. Besplatno. httrack, winhttrack, webhttrack, offline browser httrack, winhttrack, webhttrack, offline browser URL list (.txt) Spisak URL-a (.txt) Previous Prethodno Next Slijedee URLs URL-i Warning Upozorenje Your browser does not currently support javascript. For better results, please use a javascript-aware browser. Va preglednik trenutno ne podrava JavaScript. Za bolje rezultate koristite molim preglednik koji ovladava JavaScript. Thank you Hvala Vam You can now close this window Sada moete zatvoriti ovo okno Server terminated Posluitelj je razrijeen A fatal error has occurred during this mirror Tijekom ovog zrcaljenja je nastala fatalna pogreka httrack-3.49.5/lang/Chinese-Simplified.txt0000644000175000017500000007020014360553245015326 00000000000000LANGUAGE_NAME Chinese-Simplified LANGUAGE_FILE Chinese-Simplified LANGUAGE_ISO zh LANGUAGE_AUTHOR Brook Qin (brookqwr at sina.com) \r\n LANGUAGE_CHARSET gb2312 LANGUAGE_WINDOWSID Chinese (PRC) OK ȷ Cancel ȡ Exit ˳ Close ر Cancel changes ȡ Click to confirm ȷ Click to get help! Իȡ! Click to return to previous screen ԷǰһĻ Click to go to next screen ԵһĻ Hide password ؿ Save project 湤 Close current project? Ƿرյǰ? Delete this project? ɾ˹? Delete empty project %s? ɾյĹ %s? Action not yet implemented δִ Error deleting this project ɾùʱ Select a rule for the filter Ϊѡȡ Enter keywords for the filter Ϊؼ Cancel ȡ Add this rule Ӹù Please enter one or several keyword(s) for the rule Ϊ˹һؼ Add Scan Rule ɨ Criterion ׼ String ַ Add Scan Rules ɨ Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi ʹͨ԰ųURLs.\n涨ɨַдͬһ.\nʹÿոΪָ.\n\nʾ: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Exclude links ų Include link(s) Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) ʾ: ijµGIFļ, +www.someweb.com/*.gif. \n(+*.gif / -*.gif /ųվGIFļ) Save prefs Matching links will be excluded: ƥӽų: Matching links will be included: ƥӽ: Example: ʾ: gif\r\nWill match all GIF files gif\r\nƥGIFļ blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' blue\r\nҵа'blue' ļ, 'bluesky-small.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' bigfile.mov\r\nƥļ 'bigfile.mov', 'bigfile2.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\nҵļڰ'cgi' , /cgi-bin/somecgi.cgi cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\nҵļڰ'cgi-bin' (cgi-bin-2 ) someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb.com\r\nҵwww.someweb.com, private.someweb.com ȵ someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. someweb\r\nҵwww.someweb.com, www.someweb.edu, private.someweb.otherweb.com ȵ www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.someweb.com\r\nҵ'www.someweb.com' (private.someweb.com/ ) someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. someweb\r\nҵκµ: www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/someweb.html\r\nҵ'www.test.com/test/someweb.html' ļ. ע·. All links will match еӶƥ Add exclusion filter Ϊų Add inclusion filter ΪӰ Existing filters ѶƵĹַ Cancel changes ȡ Save current preferences as default values ǰôΪȱʡֵ Click to confirm ȷ No log files in %s! %s ־ļ! No 'index.html' file in %s! %s 'index.html' ļ! Click to quit WinHTTrack Website Copier ˳WinHTTrack Website Copier View log files 쿴־ļ Browse HTML start page HTML ʼҳ End of mirror View log files 쿴־ļ Browse Mirrored Website Ѿվ New project... µĹ... View error and warning reports 쿴󼰾㱨 View report 쿴㱨 Close the log file window ر־ļ Info type: Ϣ: Errors Infos Ϣ Find Find a word һ Info log file Ϣ־ļ Warning/Errors log file /־ļ Unable to initialize the OLE system ޷ʼOLEϵͳ WinHTTrack could not find any interrupted download file cache in the specified folder! WinHTTrack δָļҵжϵļԤ! Could not connect to provider ޷ӵ receive request connect search Ѱ ready error Receiving files.. ļ.. Parsing HTML file.. HTMLļ.. Purging files.. ļ.. Loading cache in progress.. Parsing HTML file (testing links).. HTMLļ ().. Pause - Toggle [Mirror]/[Pause download] to resume operation ͣ - л[]/[ͣ]Լ Finishing pending transfers - Select [Cancel] to stop now! еĴ - ѡ[ȡ]ֹͣ scanning ɨ Waiting for scheduled time.. ȴԤʱ.. Connecting to provider [%d seconds] to go before start of operation ʼ[%d ] Site mirroring in progress [%s, %s bytes] վ㾵 [%s, %s ֽ] Site mirroring finished! վ㾵! A problem occurred during the mirroring operation\n ʱ\n \nDuring:\n \nڼ:\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! \nҪ뿴־ļ.\n\n''˳WinHTTrack Website Copier.\n\nллʹWinHTTrack! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! .\n'ȷ'˳WinHTTrack.\nҪ뿴־ļ, ȷһʧ.\n\nллʹWinHTTrack! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * ȡ! * *\r\nǰʱԤΪպ, д˴αжϵľڼص.\r\nԭԤܻи; 㲻ʧȥԭе, ָ֮, ɾǰԤ.\r\n[ע: ɾǰԤ, ɾļ: hts-cache/new.*]\r\n\r\nǷ϶ԭԤи, ϣָ֮? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * !* *\r\nHTTrack⵽ǰδκ. ʹõĸģʽ, ǰһξѱָ.\r\n=> ԭ: ҳδҵ, Ӵ.\r\nȷվ, /! <= \n\nTip: Click [View log file] to see warning or error messages \n\nʾ: [쿴־ļ] Բ쿴Ϣ Error deleting a hts-cache/new.* file, please do it manually ɾhts-cache/new.* ļʱ, ֹɾ Do you really want to quit WinHTTrack Website Copier? Ҫ˳WinHTTrack Website Copier ? - Mirroring Mode -\n\nEnter address(es) in URL box - ģʽ -\n\nURLַ - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - ģʽ () -\n\nURLַ - File Download Mode -\n\nEnter file address(es) in URL box - ļģʽ -\n\nURLļַ - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - Ӳģʽ -\n\nURL뺬ӵWebҳַ - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - ģʽ -\n\n˶URLĵַ, Ҫѡ, Ȼ'Next' - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - ģʽ (жϵIJ) -\n\n˶URLĵַ, Ҫѡ, Ȼ'Next' Log files Path ־ļ· Path · - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror - ӱģʽ -\n\nURLҳĵַ, ҳкӵб, бӾᱻ New project / Import? µĹ / ? Choose criterion ѡȡеIJ Maximum link scanning depth ɨ Enter address(es) here ڴַ Define additional filtering rules 帽ӹ Proxy Name (if needed) ַ(Ҫ) Proxy Port ˿ Define proxy settings Use standard HTTP proxy as FTP proxy ʹñ׼HTTPFTP Path · Select Path ѡ· Path · Select Path ѡ· Quit WinHTTrack Website Copier ˳WinHTTrack Website Copier About WinHTTrack WinHTTrack Save current preferences as default values 浱ǰΪȱʡֵ Click to continue Լ Click to define options 趨ѡ Click to add a URL URL Load URL(s) from text file ıļURL(s) WinHTTrack preferences (*.opt)|*.opt|| WinHTTrackļ (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| ַбıļ (*.txt)|*.txt|| File not found! ļδҵ! Do you really want to change the project name/path? Ҫı乤̵ƻ·? Load user-default options? ûȱʡѡֵ? Save user-default options? Ϊûȱʡѡֵ? Reset all default options? ѡָ趨? Welcome to WinHTTrack! ӭʹWinHTTrack! Action: : Max Depth Maximum external depth: ⲿ Filters (refuse/accept links) : (ų/): Paths · Save prefs Define.. .. Set options.. ѡ.. Preferences and mirror options: ѡ趨: Project name Add a URL... URL.. Web Addresses: (URL) Webַ: (URL) Stop WinHTTrack? ֹͣWinHTTrack? No log files in %s! %s ־ļ! Pause Download? ͣ? Stop the mirroring operation ֹͣ Minimize to System Tray Сϵͳ Click to skip a link or stop parsing һӻֹͣ Click to skip a link һ Bytes saved ѱֽ: Links scanned ɨ: Time: ʱ: Connections: : Running: : Hide Transfer rate : SKIP Information Ϣ Files written: Ѵļ: Files updated: Ѹļ: Errors: : In progress: : Follow external links ׷ⲿ Test all links in pages ҳе Try to ferret out all links ܲ Download HTML files first (faster) HTMLļ () Choose local site structure ѡ񱾵վṹ Set user-defined structure on disk ڴϵûԶṹ Use a cache for updates and retries ʹԤ, ڸº Do not update zero size or user-erased files ֽļûɾļ Create a Start Page һʼҳ Create a word database of all html pages ҳʹԴʻļ Create error logging and report files ¼㱨ļ Generate DOS 8-3 filenames ONLY DOSµ8-3ļʽ Generate ISO9660 filenames ONLY for CDROM medias Do not create HTML error pages HTMLҳ Select file types to be saved to disk ѡ񽫱̵ļ Select parsing direction ѡ Select global parsing direction ѡȫֽ Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) 趨ڲ()ⲿ()ַõĹ Max simultaneous connections ಢ File timeout ļʱ Cancel all links from host if timeout occurs ʱ, ȡ Minimum admissible transfer rate СĴ Cancel all links from host if too slow , ȡ Maximum number of retries on non-fatal errors Դ (ʱ) Maximum size for any single HTML file HTMLļߴ Maximum size for any single non-HTML file HTMLļߴ Maximum amount of bytes to retrieve from the Web Webյֽ Make a pause after downloading this amount of bytes ָֽͣ Maximum duration time for the mirroring operation ʱ Maximum transfer rate ƵĴ Maximum connections/seconds (avoid server overload) ÿಢ (ֹ) Maximum number of links that can be tested (not saved!) Ŀ(DZ!) Browser identity Comment to be placed in each HTML file ÿHTMLļӵע Back to starting page صʼҳ Save current preferences as default values ǰôΪȱʡֵ Click to continue Լ Click to cancel changes ȡĶ Follow local robots rules on sites վrobots Links to non-localised external pages will produce error pages δػⲿҳӽҳ Do not erase obsolete files after update ºɾļ Accept cookies? Ƿcookies? Check document type when unknown? Ƿδ֪ļ? Parse java applets to retrieve included files that must be downloaded? ǷjavaӦóȡаļ? Store all files in cache instead of HTML only ļԤ (HTML) Log file type (if generated) ־ļ () Maximum mirroring depth from root address ӵַʼľ Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) ⲿ/Ƿַ(ȱʡΪ0, ) Create a debugging file һļ Use non-standard requests to get round some server bugs ʹ÷DZ׼ԱijЩ Use old HTTP/1.0 requests (limits engine power!) ʹþɵ HTTP/1.0 (ƾ!) Attempt to limit retransfers through several tricks (file size test..) ֶٴ (ͨļС) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Write external links without login/password ʱк¶½/ Write internal links without query string дڲʱʾ˺Ϣ Get non-HTML files related to a link, eg external .ZIP or pictures ָHTMLļ, ⲿZIPļͼƬļ Test all links (even forbidden ones) (ʹֹ) Try to catch all URLs (even in unknown tags/code) ͼеURLs (ʹδ֪ıʶ) Get HTML files first! ȱHTMLļ! Structure type (how links are saved) ṹ (ӱķʽ) Use a cache for updates ʹԤԱպ Do not re-download locally erased files ڱѱɾļ Make an index һ index.html ļ Make a word database ʻ Log files ־ļ DOS names (8+3) DOS ļʽ (8+3) ISO9660 names (CDROM) No error pages ȥҳ Primary Scan Rule Ҫɨ Travel mode нģʽ Global travel mode ȫнģʽ These options should be modified only exceptionally ѡֻ޸ Activate Debugging Mode (winhttrack.log) ģʽ (winhttrack.log) Rewrite links: internal / external : ڲ / ⲿ Flow control Limits Identity HTML footer HTMLҳ N# connections Abandon host if error , Minimum transfer rate (B/s) С (ֽ/) Abandon host if too slow , Configure Use proxy for ftp transfers ʹôftp TimeOut(s) ʱ Persistent connections (Keep-Alive) Reduce connection time and type lookup time using persistent connections Retries Size limit С Max size of any HTML file (B) HTMLļߴ Max size of any non-HTML file HTMLļߴ Max site size վߴ Max time ʱ Save prefs Max transfer rate Follow robots.txt robots.txt No external pages ⲿҳ Do not purge old files ļ Accept cookies cookies Check document type ļ Parse java files javaļ Store ALL files in cache ļԤ Tolerant requests (for servers) ԷķǾȷ Update hack (limit re-transfers) ʱȡֶηֹظ URL hacks (join similar URLs) Force old HTTP/1.0 requests (no 1.1) ǿʹþɵHTTP/1.0 (1.1) Max connections / seconds ÿ Maximum number of links ɨ Pause after downloading.. ͣÿ.. Hide passwords ؿ Hide query strings ˺Ϣ Links Build Experts Only ߼ Flow Control Limits Browser ID ʶ Scan Rules ɨ Spider Ѱ Log, Index, Cache ־, , Ԥ Proxy MIME Types Do you really want to quit WinHTTrack Website Copier? Ҫ˳WinHTTrack Website Copier ? Do not connect to a provider (already connected) ӵ Do not use remote access connection ʹԶ Schedule the mirroring operation Ԥоʱ Quit WinHTTrack Website Copier ˳WinHTTrack Website Copier Back to starting page صʼҳ Click to start! Կʼ! No saved password for this connection! ȱѱ! Can not get remote connection settings ޷ȡԶӵ Select a connection provider ѡһ Start ʼ Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. Ҫ޸Ӳ,\nȻ '' ʼ Save settings only, do not launch download now. о, 浱ǰ On hold Transfer scheduled for: (hh/mm/ss) Ԥʼ: (//) Start ʼ Connect to provider (RAS) ӵ(Զӷ) Connect to this provider ʹø: Disconnect when finished ʱϵ Disconnect modem on completion ʱϵƽ \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n(κγϵ)\r\n\r\n:\r\n (Windows): Xavier Roche\r\n: Xavier Roche\r\nJava: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nл:\r\nRobert Lagadec (rlagadec@yahoo.fr) ṩ뼼 About WinHTTrack Website Copier WinHTTrack Website Copier Please visit our Web page ǵҳ Wizard query Your answer: Ĵ: Link detected.. ⵽.. Choose a rule ѡ Ignore this link Դ Ignore directory ԴĿ¼ Ignore domain Դ Catch this page only شҳ Mirror site վ Mirror domain Ignore all ȫ Wizard query NO File ļ Options ѡ Log ־ Window Help Pause transfer ͣ Exit ˳ Modify options ޸ѡ View log 쿴־ View error log 쿴־ View file transfers 쿴ļ Hide About WinHTTrack Website Copier WinHTTrack Website Copier Check program updates... 汾... &Toolbar &Status Bar ״̬ S&plit ָ File ļ Preferences Mirror Log ־ Window Help Exit ˳ Load default options Զȱʡѡ Save default options ΪԶȱʡѡ Reset to default options ָԭʼ趨 Load options... ѡ... Save options as... ѡ... Language preference... ... Contents... ... About WinHTTrack... WinHTTrack... New project\tCtrl+N µĹ\tCtrl+N &Open...\tCtrl+O &...\tCtrl+O &Save\tCtrl+S &\tCtrl+S Save &As... ѡ... &Delete... &ɾ... &Browse sites... &Ѿվ... User-defined structure ûԶṹ %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\tչļ(: image)\r\n%N\tչļ(: image.gif)\r\n%t\tչ(: gif)\r\n%p\t·[β'/'] (: /someimages)\r\n%h\t(: www.someweb.com)\r\n%M\tMD5 URL (128λ, 32 ascii ֽ)\r\n%Q\tMD5 query string (128λ, 32 ascii ֽ)\r\n%q\tMD5 small query string (16λ, 4 ascii ֽ)\r\n\r\n%s?\tļ(: %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif ʾ:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Proxy settings Proxy address: ַ: Proxy port: ˿: Authentication (only if needed) ֤ (Ҫ) Login ¼ Password Enter proxy address here ڴַ Enter proxy port here ڴ˿ Enter proxy login ¼Ϣ Enter proxy password Enter project name here ڴ빤 Enter saving path here ڴܱ· Select existing project to update ѡһеĹԸ Click here to select path ˴ѡ· Select or create a new category name, to sort your mirrors in categories HTTrack Project Wizard... HTTrack ... New project name: ¹̵: Existing project name: й̵: Project name: : Base path: ܱ·: Project category: C:\\My Web Sites C:\\My Websites Type a new project name, \r\nor select existing project to update/resume һµĹ, \r\nѡйԸ» New project µĹ Insert URL URL URL: URLַ: Authentication (only if needed) ֤ (Ҫ) Login ¼ Password Forms or complex links: : Capture URL... URLַ... Enter URL address(es) here ڴURLַ Enter site login վ¼ Enter site password վ½ Use this capture tool for links that can only be accessed through forms or javascript code ʹô˹ֻ߲ͨjavaʵ Choose language according to preference ݸϲѡ Catch URL! URLַ! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. ʱĴΪֵ(/ճַͶ˿).\nȻҳϱSUBMITť, Ҫ This will send the desired link from your browser to WinHTTrack. ӽWinHTTrack. ABORT Copy/Paste the temporary proxy parameters here ڴ˿/ճʱĴ Cancel ȡ Unable to find Help files! ޷ҵļ! Unable to save parameters! ޷! Please drag only one folder at a time ÿֻһļ Please drag only folders, not files 벻Ҫļ, ֻļ Please drag folders only ֻļ Select user-defined structure? ѡûԶṹ? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! ȷûַȷ,\nļʱܳ! Do you really want to use a user-defined structure? ҪʹûԶṹ? Too manu URLs, cannot handle so many links!! URLsַ, ޷!! Not enough memory, fatal internal error.. ڴ治, ڲ! Unknown operation! δ֪! Add this URL?\r\n ӴURL? Warning: main process is still not responding, cannot add URL(s).. : δӦ, URL(s).. Type/MIME associations ļ/չ File types: ļ: MIME identity: MIME identity Select or modify your file type(s) here ڴѡ޸ļ Select or modify your MIME type(s) here ڴѡ޸Ĺļ Go up Go down File download information ļϢ Freeze Window Ϣ More information: Ϣ: Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download ӭʹWinHTTrack Website Copier!\n\n'Next' \n\n- ʼһµĹ\n- ִһǰľ File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS ļаչ:\nļа:\nļ:\nļа:\nļ:\n:\nа:\n:\nа:\n:\n Show all\nHide debug\nHide infos\nHide debug and infos ʾȫ\nش\nϢ\nشϢ Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. վԭнṹ(ȱʡ)\nhtmlļweb/, ͼƬļweb/images/\nhtmlļweb/html, ͼƬļweb/images\nhtmlļweb/, ͼƬļҲweb/\nhtmlļweb/, ͼƬļweb/xxx, xxxΪļչ\nhtmlļweb/html, ͼƬļweb/xxx\nվԭнṹ(ȥwww.domain.xxx/)\nhtmlļsite_name/, ͼƬļsite_name/images/\nhtmlļsite_name/html, ͼƬļsite_name/images\nhtmlļsite_name/, ͼƬļҲsite_name/\nhtmlļsite_name/, ͼƬļsite_name/xxx\nhtmlļsite_name/html, ͼƬļsite_name/xxx\nļweb/, ļ\nļsite_name/, ļ\nûԶṹ.. Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first ֻɨ\nֻhtmlļ\nֻhtmlļ\nļ (ȱʡ)\nȱhtmlļ Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down ͣͬһĿ¼\n½ (ȱʡ)\nϽ\n¶ Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web ͣͬһַ (ȱʡ)\nͣͬһ\nͣͬһ\nκַ Never\nIf unknown (except /)\nIf unknown Ӳ\nδ֪ (/ )\nδ֪ no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules robots.txt\nعrobots.txt\nȫrobots.txt normal\nextended\ndebug ͨ־\nչ־\n־ Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download վ\nվ + \nظļ\nҳеվ ()\nҳе (ǩ)\n* жϵľ\n* о Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL Եַ / Եַ (ȱʡ)\nԵַ / Եַ\nԵַ / Եַ\nԭʼ ַ / ԭʼַ Open Source offline browser Website Copier/Offline Browser. Copy remote websites to your computer. Free. httrack, winhttrack, webhttrack, offline browser URL list (.txt) Previous Next URLs Warning Your browser does not currently support javascript. For better results, please use a javascript-aware browser. Thank you You can now close this window Server terminated A fatal error has occurred during this mirror httrack-3.49.5/lang/Chinese-BIG5.txt0000644000175000017500000007122214360553245013734 00000000000000LANGUAGE_NAME Chinese-BIG5 LANGUAGE_FILE Chinese-BIG5 LANGUAGE_ISO zh_TW LANGUAGE_AUTHOR David Hing Cheong Hung (DAVEHUNG@mtr.com.hk)\r\n LANGUAGE_CHARSET BIG5 LANGUAGE_WINDOWSID Chinese (Taiwan) OK Tw Cancel Exit } Close Cancel changes ܧ Click to confirm IHT{ Click to get help! IH! Click to return to previous screen IH^e@ Click to go to next screen IHFU@ Hide password ñKX Save project OsM Close current project? O_eM? Delete this project? RM? Delete empty project %s? RŪM %s? Action not yet implemented ާ@ Error deleting this project RӱM׮ɥX Select a rule for the filter LoWh Enter keywords for the filter LoJ Cancel Add this rule W[ӳWh Please enter one or several keyword(s) for the rule ЬWhJ@ܴX Add Scan Rule W[yWh Criterion ǫh String r Add W[ Scan Rules yWh Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi ϥθUΦrH]tαưURLs쵲.\nhӳWwyWhrigbP@.\nϥΪť@jŸ.\n\nҦp: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Exclude links ư쵲 Include link(s) ]t쵲 Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) : ]tYW٤UҦGIFɮ, iJ +www.someweb.com/*.gif. \n(+*.gif / -*.gif N]t/ưӦ۩ҦIGIFɮ) Save prefs Os]w Matching links will be excluded: ǰt쵲NQư: Matching links will be included: ǰt쵲NQ]t: Example: Ҧp: gif\r\nWill match all GIF files gif\r\nNǰtҦGIFɮ blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' blue\r\nNMҦ]t'blue' ɮ, Ѧp 'bluesky-small.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' bigfile.mov\r\nNǰtɮ 'bigfile.mov', ]A 'bigfile2.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\nNMɮקW]t'cgi' 쵲, Ѧp /cgi-bin/somecgi.cgi cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\nNMɮקW]t'cgi-bin' 쵲 (cgi-bin-2 ~) someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb.com\r\nNM]tѦpwww.someweb.com, private.someweb.com 쵲 someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. someweb\r\nNM]tѦpwww.someweb.com, www.someweb.edu, private.someweb.otherweb.com 쵲 www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.someweb.com\r\nNM]t'www.someweb.com' 쵲 (]Aprivate.someweb.com/ ) someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. someweb\r\nNMѦpHU쵲: www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/someweb.html\r\nNȴM'www.test.com/test/someweb.html' ɮ. `NпJ㪺|. All links will match Ҧ쵲Nǰt Add exclusion filter LoW[ưWh Add inclusion filter LoW[]tWh Existing filters wwLor Cancel changes ܧ Save current preferences as default values Ne]wsw] Click to confirm IHT{ No log files in %s! %s Lxɮ! No 'index.html' file in %s! %s L'index.html' ɮ! Click to quit WinHTTrack Website Copier IH}WinHTTrack Website Copier View log files dݤxɮ Browse HTML start page s HTML _l End of mirror 蹳 View log files dݤxɮ Browse Mirrored Website sw蹳 New project... sM... View error and warning reports dݿ~ĵii View report dݳi Close the log file window xɮ׵ Info type: T: Errors ~ Infos T Find M Find a word M@ӳ Info log file Txɮ Warning/Errors log file ĵi/~xɮ Unable to initialize the OLE system LklOLEt WinHTTrack could not find any interrupted download file cache in the specified folder! WinHTTrack bwɮקQ_ɮפUtemp! Could not connect to provider Lksu receive request nD connect su search M ready N error ~ Receiving files.. ɮ.. Parsing HTML file.. RHTMLɮ.. Purging files.. Mɮ.. Loading cache in progress.. ֨OJ.. Parsing HTML file (testing links).. RHTMLɮ (쵲).. Pause - Toggle [Mirror]/[Pause download] to resume operation 蹳Ȱ - [蹳]/[ȰU]H~ާ@ Finishing pending transfers - Select [Cancel] to stop now! Bzಾ - {b[]Ӱ scanning y Waiting for scheduled time.. ݹwwɶ.. Connecting to provider bsu [%d seconds] to go before start of operation ާ@}l٦[%d ] Site mirroring in progress [%s, %s bytes] I蹳i椤 [%s, %s byts] Site mirroring finished! I蹳! A problem occurred during the mirroring operation\n 蹳ɵoͿ~\n \nDuring:\n \noͦbHU:\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! \npݭnЬݤxɮ.\n\nI''H}WinHTTrack Website Copier.\n\n¨ϥWinHTTrack! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! 蹳.\nI'Tw'H}WinHTTrack.\npݭnЬݤxɮ, HTOUL@.\n\n¨ϥWinHTTrack! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * 蹳Q! * *\r\ne{ɪwsϬsһ, ȦsQ_蹳Uƾ.\r\nӭ즳wsϥi|s󧹾㪺e; pGAQh즳ƾ, Ы_, }Rews.\r\n[`: Rews, ȻݧRHUɮ: hts-cache/new.*]\r\n\r\nAO_֩w즳wsϦs󧹾㪺e, }Ʊ_? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * 蹳X!* *\r\nHTTrack˴e蹳xsƾ. YϥΪsҦ, he@蹳wQ_.\r\n]: , εoͳsu~.\r\n=> нTw蹳sb, }/ˬdproxy]w! <= \n\nTip: Click [View log file] to see warning or error messages \n\n: I [dݤxɮ] Hdĵiο~ Error deleting a hts-cache/new.* file, please do it manually Rhts-cache/new.* ɮ׮ɥX, ФuR Do you really want to quit WinHTTrack Website Copier? un}WinHTTrack Website Copier ? - Mirroring Mode -\n\nEnter address(es) in URL box - 蹳Ҧ -\n\nЦbURLؤJ} - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - 椬FҦ (o) -\n\nЦbURLؤJ} - File Download Mode -\n\nEnter file address(es) in URL box - ɮפUҦ -\n\nЦbURLؤJɮ׺} - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - 쵲ռҦ -\n\nЦbURLؤJt쵲Web} - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - sҦ -\n\nЮֹURLت}, pݭnˬdﶵ, MI'Next' - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - ~Ҧ (Q_ާ@) -\n\nЮֹURLت}, pݭnˬdﶵ, MI'Next' Log files Path xɮ׸| Path | - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror - 쵲Ҧ -\n\nЦbURLؤJ}, t쵲C, CҦ쵲|Q蹳 New project / Import? sM / ɤJ? Choose criterion Ni檺ާ@ Maximum link scanning depth ̤j쵲y` Enter address(es) here ЦbJ} Define additional filtering rules wq[LoWh Proxy Name (if needed) proxy}(pYݭn) Proxy Port proxys Define proxy settings wqproxyA]w Use standard HTTP proxy as FTP proxy ϥμзHTTP proxy N FTP proxy Path | Select Path ܸ| Path | Select Path ܸ| Quit WinHTTrack Website Copier }WinHTTrack Website Copier About WinHTTrack WinHTTrack Save current preferences as default values Ose]ww] Click to continue IH~ Click to define options IH]wﶵ Click to add a URL IHW[URL Load URL(s) from text file q奻ɮפJURL(s) WinHTTrack preferences (*.opt)|*.opt|| WinHTTrack]wɮ (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| }C奻ɮ (*.txt)|*.txt|| File not found! ɮץ! Do you really want to change the project name/path? unܱMתW٩θ|? Load user-default options? JϥΪ̩wqw]ﶵ? Save user-default options? sϥΪ̩wqw]ﶵ? Reset all default options? NҦﶵ_̪]w? Welcome to WinHTTrack! wϥWinHTTrack! Action: ާ@: Max Depth ̤j` Maximum external depth: ̤j~쵲` Filters (refuse/accept links) : Lo (ư/]t쵲): Paths | Save prefs Os]w Define.. wq.. Set options.. ﶵ.. Preferences and mirror options: ﶵ]w: Project name MצW Add a URL... W[URL.. Web Addresses: (URL) Web}: (URL) Stop WinHTTrack? WinHTTrack? No log files in %s! %s Lxɮ! Pause Download? ȰU? Stop the mirroring operation 蹳 Minimize to System Tray ̤pƦܨtΤuC Click to skip a link or stop parsing IHL@쵲ΰR Click to skip a link IHL@쵲 Bytes saved wOsbyts: Links scanned wy쵲: Time: ɶ: Connections: su: Running: B: Hide Transfer rate ǿtv: SKIP L Information T Files written: wxsɮ: Files updated: wsɮ: Errors: ~: In progress: i{: Follow external links H~쵲 Test all links in pages խҦ쵲 Try to ferret out all links ɥidXҦ쵲 Download HTML files first (faster) UHTMLɮ () Choose local site structure ܥaIc Set user-defined structure on disk ]wbϺФWϥΪ̦۩wc Use a cache for updates and retries ϥιws, ΩsM Do not update zero size or user-erased files ssbytsɮשΥѨϥΪ̧Rɮ Create a Start Page sW@Ӱ_l Create a word database of all html pages Ҧhtmlسy@Ӥrƾڮw Create error logging and report files sW~Oγiɮ Generate DOS 8-3 filenames ONLY ȲDOSU8-3ɮצW榡 Generate ISO9660 filenames ONLY for CDROM medias ȲͰŪХΪISO9660榡UɮצW Do not create HTML error pages sWHTML~ Select file types to be saved to disk ܱNQsɪɮ Select parsing direction ܤR Select global parsing direction ܥR Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) ]w쵲(wU)Υ~쵲(U)URLgWh Max simultaneous connections ̦hPɳsu File timeout ɮ׶W Cancel all links from host if timeout occurs YWɵo, ҦӦۥD쵲 Minimum admissible transfer rate ̤pҤ\ǿtv Cancel all links from host if too slow YǿLC, ҦӦۥD쵲 Maximum number of retries on non-fatal errors ̦hզ (oͫDPR~) Maximum size for any single HTML file HTMLɮשҤ\̤jsize Maximum size for any single non-HTML file ӫDHTMLɮשҤ\̤jsize Maximum amount of bytes to retrieve from the Web ̦hҤ\qWebbyts Make a pause after downloading this amount of bytes bUo줸նqȰ Maximum duration time for the mirroring operation 蹳L{Ҥ\̪ɶ Maximum transfer rate ̤jҭǿtv Maximum connections/seconds (avoid server overload) C̦hPɳs (AW) Maximum number of links that can be tested (not saved!) ̤j쵲ռ(Os!) Browser identity s Comment to be placed in each HTML file bCHTMLɮؼW[` Back to starting page ^_l Save current preferences as default values Ne]wsw] Click to continue IH~ Click to cancel changes IH Follow local robots rules on sites qrobotsWh Links to non-localised external pages will produce error pages aƪ~쵲NͿ~ Do not erase obsolete files after update sᤣRoɮ Accept cookies? O_cookies? Check document type when unknown? O_ˬdɮ? Parse java applets to retrieve included files that must be downloaded? O_Rjavaε{ǥH^䤤]tɮ? Store all files in cache instead of HTML only NҦɮ׶ȫOsbws (DHTML) Log file type (if generated) xɮ (Y) Maximum mirroring depth from root address q}ڳ}l̤j蹳` Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) Maximum mirroring depth for external/fodbidden addresses (0, that is, none, is the default) Create a debugging file sW@Ӱɮ Use non-standard requests to get round some server bugs ϥΫDзǭnDHקKYǦA~ Use old HTTP/1.0 requests (limits engine power!) ϥª HTTP/1.0 nD (N蹳O!) Attempt to limit retransfers through several tricks (file size test..) եHYzkAǰe (pqLɮפjp) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Write external links without login/password gJ~쵲ɤ]AnJ/KX Write internal links without query string gJ쵲ɤ]Adߦr Get non-HTML files related to a link, eg external .ZIP or pictures OsҦVDHTMLɮת쵲, Ҧp~ZIPɮשιϤɮ Test all links (even forbidden ones) թҦ쵲 (YϳQT) Try to catch all URLs (even in unknown tags/code) չϧҦURLs (YϦsb󥼪ñΥNX) Get HTML files first! OsHTMLɮ! Structure type (how links are saved) c (쵲Os覡) Use a cache for updates ϥιwsϥHKs Do not re-download locally erased files AUbawQRɮ Make an index sW@ index.html ɮ Make a word database سy@Ӥrƾڮw Log files xɮ DOS names (8+3) DOS ɮצW榡 (8+3) ISO9660 names (CDROM) ISO9660榡UɮצW(Ū) No error pages h~ Primary Scan Rule nyWh Travel mode iҦ Global travel mode iҦ These options should be modified only exceptionally HUﶵubSpUק Activate Debugging Mode (winhttrack.log) ҰʽոռҦ (sWwinhttrack.log) Rewrite links: internal / external g쵲 : /~ Flow control yq Limits Identity HTML footer HTML} N# connections su Abandon host if error YoͿ~, hMDsu Minimum transfer rate (B/s) ̤pǿv (byts/) Abandon host if too slow YǿLC, hMDsu Configure tm Use proxy for ftp transfers ϥproxyiftpǿ TimeOut(s) W Persistent connections (Keep-Alive) s(Oq) Reduce connection time and type lookup time using persistent connections sYusɶMJsdɶ Retries Size limit jp Max size of any HTML file (B) HTMLɮת̤jsize Max size of any non-HTML file ӫDHTMLɮת̤jsize Max site size 蹳I̤jsize Max time ̪ɶ Save prefs Os]w Max transfer rate ̤jǿtv Follow robots.txt u robots.txt Wh No external pages ͥ~ Do not purge old files Moɮ Accept cookies cookies Check document type ˬdɮ Parse java files Rjavaɮ Store ALL files in cache OsҦɮצbwsϤ Tolerant requests (for servers) \ADTnD Update hack (limit re-transfers) sɱĨLkƤU URL hacks (join similar URLs) Force old HTTP/1.0 requests (no 1.1) jϥªHTTP/1.0nD (ĥ1.1) Max connections / seconds C̦hsu Maximum number of links ̤j쵲 Pause after downloading.. CUȰ.. Hide passwords ñKX Hide query strings ìdߦr Links 쵲 Build cy Experts Only Flow Control yq Limits Browser ID s Scan Rules yWh Spider jM Log, Index, Cache x, , ws Proxy proxy MIME Types MIME Do you really want to quit WinHTTrack Website Copier? un}WinHTTrack Website Copier ? Do not connect to a provider (already connected) wsu Do not use remote access connection ϥλݳsu Schedule the mirroring operation wwi蹳ɶ Quit WinHTTrack Website Copier }WinHTTrack Website Copier Back to starting page ^_l Click to start! IH}l! No saved password for this connection! ӳsuʤ֤wOsKX! Can not get remote connection settings Lkݳsu]w Select a connection provider пܤ@ӳsu Start }l Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. pݭnЭקsuѼ,\nM '' }l蹳 Save settings only, do not launch download now. ߧYi蹳, ȫOse]w On hold _ Transfer scheduled for: (hh/mm/ss) ww蹳}l: (I//) Start }l Connect to provider (RAS) su(ݳsuA) Connect to this provider ϥθӳsu: Disconnect when finished ɤ_su Disconnect modem on completion ɤ_ƾھ \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n({ǿ~ΰDpڭ)\r\n\r\n}o:\r\nɭ]p (Windows): Xavier Roche\r\nR: Xavier Roche\r\nJavaR: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nP:\r\nDavid Hing Cheong Hung (DAVEHUNG@mtr.com.hk) ½Ķ About WinHTTrack Website Copier WinHTTrack Website Copier Please visit our Web page гXݧڭ̪ Wizard query F Your answer: A: Link detected.. ˴쵲.. Choose a rule пܳWh Ignore this link 쵲 Ignore directory ؿ Ignore domain W Catch this page only ȤU Mirror site 蹳I Mirror domain 蹳W Ignore all G Wizard query F NO _ File ɮ Options ﶵ Log x Window Help Pause transfer Ȱǿ Exit } Modify options קﶵ View log dݤx View error log dݿ~x View file transfers dɮ׶ǿ Hide About WinHTTrack Website Copier WinHTTrack Website Copier Check program updates... ˬds... &Toolbar u &Status Bar A S&plit File ɮ Preferences ]w Mirror 蹳 Log x Window Help Exit } Load default options J۩ww]ﶵ Save default options s۩ww]ﶵ Reset to default options _l]w Load options... Jﶵ... Save options as... Osﶵ... Language preference... ɭy]w... Contents... e... About WinHTTrack... WinHTTrack... New project\tCtrl+N sM\tCtrl+N &Open...\tCtrl+O &}...\tCtrl+O &Save\tCtrl+S &Os\tCtrl+S Save &As... Osﶵ... &Delete... &R... &Browse sites... &sw蹳I... User-defined structure ϥΪ̦۩wc %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\ttɦWɮצW(p: image)\r\n%N\ttɦWɮצW(p: image.gif)\r\n%t\tXiW(p: gif)\r\n%p\t|[LH'/'] (p: /someimages)\r\n%h\tDW(p: www.someweb.com)\r\n%M\tMD5 URL (128, 32 ascii byts)\r\n%Q\tMD5 query string (128, 32 ascii byts)\r\n%q\tMD5 small query string (16, 4 ascii byts)\r\n\r\n%s?\tuɮצW(p: %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Ҧp:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Proxy settings proxy]w Proxy address: proxy}: Proxy port: proxys: Authentication (only if needed) (pYݭn) Login n Password KX Enter proxy address here bJproxy} Enter proxy port here bJproxys Enter proxy login JproxyAnT Enter proxy password JproxyAһݱKX Enter project name here bJMצW Enter saving path here bJOs| Select existing project to update пܤ@ӤwMץHs Click here to select path IBHܸ| Select or create a new category name, to sort your mirrors in categories HTTrack Project Wizard... HTTrack M׺F... New project name: sMתW: Existing project name: {MתW: Project name: MצW: Base path: `sɸ|: Project category: C:\\My Web Sites C:\\My Websites Type a new project name, \r\nor select existing project to update/resume J@ӷsMצW, \r\nοܤwMץHs~ New project sM Insert URL JURL URL: URL}: Authentication (only if needed) (pYݭn) Login n Password KX Forms or complex links: δ_쵲: Capture URL... URL}... Enter URL address(es) here ЦbJURL} Enter site login пJInW Enter site password пJInKX Use this capture tool for links that can only be accessed through forms or javascript code ϥΦuuqLjavaNXXL쵲 Choose language according to preference ЮھڭӤHߦnܬɭy Catch URL! URL}! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. ХȮɱNsproxy]pUƭ(ƻs/KWproxy}Ms).\nMIsW檺SUBMITs, IQn쵲 This will send the desired link from your browser to WinHTTrack. һݪ쵲NqsQeWinHTTrack. ABORT Copy/Paste the temporary proxy parameters here bƻs/KWȮɪproxyѼ Cancel Unable to find Help files! Lk컡ɮ! Unable to save parameters! LkOsѼ! Please drag only one folder at a time ШCu즲@ɮק Please drag only folders, not files Фn즲ɮ, u즲ɮק Please drag folders only Хu즲ɮק Select user-defined structure? ܨϥΪ̦۩wc? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! нTOϥΪ̩wqrꪺT,\n_hɮצWɥiX! Do you really want to use a user-defined structure? unϥΨϥΪ̦۩wc? Too manu URLs, cannot handle so many links!! LhURL}, LkBz!! Not enough memory, fatal internal error.. O餣, oͭPR~! Unknown operation! ާ@! Add this URL?\r\n W[URL? Warning: main process is still not responding, cannot add URL(s).. ĵi: Di{^, W[URL(s).. Type/MIME associations /MIME pô File types: ɮ: MIME identity: MIME identity Select or modify your file type(s) here bo̿ܩέקAɮ Select or modify your MIME type(s) here bo̿ܩέקA MIME Go up W Go down U File download information ɮפUT Freeze Window wT More information: hT: Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download wϥ WinHTTrack !\n\nI'NEXT'sh\n\n-}l@ӷsM\n- ~@ӥU File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS ɮצW]tɦW:\nɮצW]t:\nɮצW:\nɮקW]t:\nɮקW:\nW:\nW٤]t:\nD:\n쵲]t:\n쵲:\nҦ쵲 Show all\nHide debug\nHide infos\nHide debug and infos ܥe\nÿ~\nî\nÿ~M Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. I즳c(w])\nhtmlɮצbweb/, ϤMLɮצbweb/images/\nhtmlɮצbweb/html, ϤMLɮצbweb/images\nhtmlɮצbweb/, ϤMLɮפ]bweb/\nhtmlɮצbweb/, ϤMLɮצbweb/xxx, xxxɮװɦW\nhtmlɮצbweb/html, ϤMLɮצbweb/xxx\nI즳c(hwww.domain.xxx/)\nhtmlɮצbsite_name/, ϤMLɮצbsite_name/images/\nhtmlɮצbsite_name/html, ϤMLɮצbsite_name/images\nhtmlɮצbsite_name/, ϤMLɮפ]bsite_name/\nhtmlɮצbsite_name/, ϤMLɮצbsite_name/xxx\nhtmlɮצbsite_name/html, ϤMLɮצbsite_name/xxx\nҦɮצbweb/, ɮצWN\nҦɮצbsite_name/, ɮצWN\nϥΪ̦۩wc.. Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first uy\nuOshtmlɮ\nuOsDhtmlɮ\nOsҦɮ (w])\nOshtmlɮ Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down dP@ؿ\n\Ui (w])\n\Wi\nWU\i Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web dP@} (w])\ndP@W\ndP@źW\n} Never\nIf unknown (except /)\nIf unknown q\npG (/ ~)\npG no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules urobots.txt\nuLourobots.txt\nurobots.txt normal\nextended\ndebug qx\nXRx\nx Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download U\nU + \nUӧOɮ\nUҦI (h蹳)\nխ쵲 (ñ)\n* ~Q_蹳\n* sw蹳 Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL ۹ URI / URL (w])\n URL / URL\n URI / URL\n쥻 URL / 쥻 URL Open Source offline browser }lu\ Website Copier/Offline Browser. Copy remote websites to your computer. Free. /u\,KOݺAq httrack, winhttrack, webhttrack, offline browser httrack, winhttrack, webhttrack, u\ URL list (.txt) URL (.txt) Previous W@B Next U@B URLs URLs Warning ĵi Your browser does not currently support javascript. For better results, please use a javascript-aware browser. A\{ɤ䴩 javascript.pݧήĪGХΤ䴩 javascript \ Thank you h You can now close this window A{biHo Server terminated Awפ A fatal error has occurred during this mirror o蹳oͤFi^_~ httrack-3.49.5/lang/Cesky.txt0000644000175000017500000010273714360553245012756 00000000000000LANGUAGE_NAME esky LANGUAGE_FILE Cesky LANGUAGE_ISO cs LANGUAGE_AUTHOR Antonn Matjk (matejcik@volny.cz) \r \n LANGUAGE_CHARSET WINDOWS-1250 LANGUAGE_WINDOWSID Czech OK Ano Cancel Zruit Exit Konec Close Zavt Cancel changes Zruit zmny Click to confirm Klikni pro potvrzen Click to get help! Klikni pro npovdu Click to return to previous screen Klikni pro nvrat do pedchozho okna Click to go to next screen Klikni pro pokraovn na nsledujcm okn Hide password Skrt heslo Save project Uloit projekt Close current project? Zavt aktuln projekt? Delete this project? Smazat tento projekt? Delete empty project %s? Smazat przdn projekt %s? Action not yet implemented Akce nen jet implementovna Error deleting this project Chyba pi mazn tohoto projektu Select a rule for the filter Vbr pravidla pro filtr Enter keywords for the filter Zadej klov slova pro filtr Cancel Zruit Add this rule Pidat toto pravidlo Please enter one or several keyword(s) for the rule Zadej jedno nebo nkolik klovch slov pro pravidlo Add Scan Rule Pidat filtr Criterion Kritrium filtru String etzec Add Pidat Scan Rules Filtry Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Pouvej zstupnch znak (wildcards) pro pidn nebo odebrn URL nebo odkaz. \nMe pout nkolik zstupnch znak na jedinm dku. \Pouvej mezery jako oddlovae. \n\nNapklad: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi */ Exclude links Vylouit odkaz(y) Include link(s) Zahrnout odkaz(y) Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) Tip: Pro zahrnut vech GIF soubor, pouij teba +www.someweb.com/*.gif. \n(+*.gif / -*.gif zahrne/vylou VECHNY GIF soubory ze vech strnek) Save prefs Uloit nastaven Matching links will be excluded: Shodn odkazy budou vyloueny: Matching links will be included: Shodn odkazy budou zahrnuty: Example: Pklad: gif\r\nWill match all GIF files gif\r\nZahrne vechny GIF soubory blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' modr\r\nZahrne vechny soubory obsahujc slova 'modr', nap. 'modr-obloha.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' bigfile.mov\r\nZahrne soubor 'bigfile.mov', ale ji ne 'bigfile2.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\nNajde odkazy s nzvem adrese obsahujc etzec 'cgi' jako teba /cgi-bin/somecgi.cgi cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\nNajde odkazy s nzvem adrese obsahujc cel 'cgi-bin' etzec (ale ji ne cgi-bin-2) someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb.com\r\nNajde odkazy obsahujc etzce www.someweb.com, private.someweb.com apod. someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. someweb\r\nNajde odkazy shodn s nzvem adrese obsahujc etzce www.someweb.com, www.someweb.edu, private.someweb.otherweb.com apod. www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.someweb.com\r\nNajde odkazy obsahujc cel 'www.someweb.com' etzec (ale ne etzce jako private.someweb.com/..) someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. someweb\r\nNajde jakkoliv odkazy obsahujc etzec jako www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html apod. www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/someweb.html\r\nNajde pouze soubor 'www.test.com/test/someweb.html'. Nezapome, e mus zadat celou cestu (URL + cesta ke strnce) All links will match Vechny odkazy se budou shodovat Add exclusion filter Pidat filtr pro vylouen Add inclusion filter Pidat filtr pro zahrnut Existing filters Definovan filtry Cancel changes Zruit zmny Save current preferences as default values Uloit aktuln nastaven jako vchoz Click to confirm Klikni pro potvrzen No log files in %s! Chyb protokoly v %s! No 'index.html' file in %s! Chyb 'index.html' soubor v %s! Click to quit WinHTTrack Website Copier Klikni pro ukonen programu WinHTTrack Website Copier View log files Zobrazit protokoly Browse HTML start page Prohldnout vodn HTML strnku End of mirror Konec stahovn View log files Zobrazit protokoly Browse Mirrored Website Prohldnout staen strnky New project... Nov projekt.. View error and warning reports Zobrazit chyby a upozornn View report Zobrazit hlen Close the log file window Zavt okno s protokolem Info type: Typ informace: Errors Chyby Infos Informace Find Najt Find a word Najt slovo Info log file Informan protokol Warning/Errors log file Protokol s chybami Unable to initialize the OLE system Inicializace OLE systmu selhala WinHTTrack could not find any interrupted download file cache in the specified folder! WinHTTrack neme nalzt dn staen soubory v cache pi peruen stahovn v urenm adresi! Could not connect to provider Spojen s poskytovatelem nenavzno receive pjem request poadavek connect spojen search hledn ready hotovo error chyba Receiving files.. Pjem soubor.. Parsing HTML file.. Analza HTML souboru.. Purging files.. Uvolnn soubor.. Loading cache in progress.. Parsing HTML file (testing links).. Analza HTML souboru (test odkaz).. Pause - Toggle [Mirror]/[Pause download] to resume operation Peruen - Pro pokraovn zvol [Stahovn]/[Peruit penos] Finishing pending transfers - Select [Cancel] to stop now! Dokonuj se zbvajc penosy - Zvol [Zruit] pro jejich zastaven scanning provovn Waiting for scheduled time.. ekn na naplnovan as.. Connecting to provider Pipojovn k poskytovateli [%d seconds] to go before start of operation [%d sekund] do startu Site mirroring in progress [%s, %s bytes] Probh stahovn strnek [%s, %s bajt] Site mirroring finished! Stahovn strnek skoneno! A problem occurred during the mirroring operation\n Pi stahovn se vyskytl problm\n \nDuring:\n \nBhem:\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! \nZobraz protokol.\n\nKlikni na Ukonit pro ukonen programu WinHTTrack Website Copier.\n\nDky za pouit programu WinHTTrack! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! Stahovn skoneno.\nKlikni na Konec pro ukonen programu WinHTTrack.\nZobraz si protokoly pro kontrolu chyb pi stahovn.\n\nDky za pouit programu WinHTTrack! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * STAHOVN ZRUENO! * *\r\nPro pokraovn stahovn je zapoteb lokln cache, obsahujc staen data.\r\nPedchoz cache me obsahovat vce informac. Pokud je nechce ztratit, mus ji obnovit a smazat aktuln cache.\r\n[Poznmka: To me bt provedeno te smaznm hts-cache/new.* soubor]\r\n\r\nMysl, e cache obsahuje vce informac a peje si ji obnovit? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * CHYBA PI STAHOVN! * *\r\nHTTrack zjistil, e se nesthla dn data. Pokud se jednalo o aktualizaci, pak pedel data byla obnovena.\r\nDvod: Nemohla bt nalezena prvn strnka nebo se vyskytl problm se spojenm.\r\n=>Prov zda zadan adresa existuje anebo zkontroluj nastaven proxy! <= \n\nTip: Click [View log file] to see warning or error messages \n\nTip: Klikni [Zobraz protokoly] pro zobrazen upozornn a chyb Error deleting a hts-cache/new.* file, please do it manually Chyba pi mazn hts-cache/new.* soubor, udlej to run Do you really want to quit WinHTTrack Website Copier? Opravdu ukonit WinHTTrack Website Copier? - Mirroring Mode -\n\nEnter address(es) in URL box - Md stahovn -\n\nZadej adresu(y) do URL dky - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - Interaktivn md (otzky) -\n\nZadej adresu(y) do URL dky - File Download Mode -\n\nEnter file address(es) in URL box - Md stahovn soubor -\n\nZadej adresu(y) do URL dky - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - Md kontroly odkaz -\n\nZadej Web adresu(y) s odkazy pro kontrolu do URL dky - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Md pro aktualizaci -\n\nZkontroluj adresu(y) v URL dce, ov znovu parametry (pokud je to nutn) a klikni na 'Dal' - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Md pro navzn (pi peruen) -\n\nZkontroluj adresu(y) v seznamu, ov znovu parametry (pokud je to nutn) a klikni na 'Dal' Log files Path Cesta k protokolm Path Cesta - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror - Md seznamu odkaz -\n\nDo URL dky zadej adresu(y) strnek obsahujc odkazy ke staen New project / Import? Nov projekt/Import? Choose criterion Vybrat kritrium Maximum link scanning depth Maximln hloubka provovn odkaz Enter address(es) here Zadej adresu(y) Define additional filtering rules Definice dodatench filtr Proxy Name (if needed) Jmno proxy (pokud to je nutn) Proxy Port Proxy port Define proxy settings Proxy nastaven Use standard HTTP proxy as FTP proxy Pout standardn proxy jako FTP proxy Path Cesta Select Path Vyber cestu Path Cesta Select Path Vyber cestu Quit WinHTTrack Website Copier Ukonit WinHTTrack Website Copier About WinHTTrack O programu WinHTTrack Website Copier Save current preferences as default values Uloit aktuln nastaven jako vchoz Click to continue Klikni pro pokraovn Click to define options Klikni pro nastaven Click to add a URL Klikni pro pidn URL adresy Load URL(s) from text file Nast URL adresu z textovho souboru WinHTTrack preferences (*.opt)|*.opt|| WinHTTrack nastaven (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| Soubor obsahujc seznam adres (*.txt)|*.txt|| File not found! Soubor nenalezen! Do you really want to change the project name/path? Opravdu chce zmnit nzev/cestu projektu? Load user-default options? Nast uivatelsky-vchoz nastaven? Save user-default options? Uloit uivatelsky-vchoz nastaven? Reset all default options? Obnovit vechna vchoz nastaven? Welcome to WinHTTrack! Vt Vs program WinHTTrack Website Copier! Action: Akce: Max Depth Maximln hloubka Maximum external depth: Maximln hloubka externho odkazu Filters (refuse/accept links) : Filtry (odmtnout/pijmout odkazy): Paths Cesty Save prefs Ulo nastaven Define.. Definice.. Set options.. Nastaven.. Preferences and mirror options: Pedvolby a nastaven stahovn: Project name Nzev projektu Add a URL... Pidat URL.. Web Addresses: (URL) Adresa WWW (URL): Stop WinHTTrack? Zastavit WinHTTrack? No log files in %s! Nenalezen dn protokol v %s! Pause Download? Peruit stahovn? Stop the mirroring operation Zastavit stahovn? Minimize to System Tray Minimalizace do systmov lity Click to skip a link or stop parsing Klikni pro peskoen odkazu nebo pro zastaven provovn odkazu Click to skip a link Klikni pro peskoen odkazu Bytes saved Bajt uloeno: Links scanned Odkaz proveno: Time: as: Connections: Spojen: Running: Zobrazit prbh Hide Skrt Transfer rate Penosov rychlost: SKIP PESKOIT Information Informace Files written: Zapsno soubor: Files updated: Zaktualizovno: Errors: Chyby: In progress: Zpracovv se: Follow external links Nsleduj extern odkazy Test all links in pages Vyzkouej vechny odkazy na strnce Try to ferret out all links Zkus prohledat vechny odkazy Download HTML files first (faster) Nejprve sthnout HTML strnky (rychlej) Choose local site structure Zvolit mstn strukturu strnky Set user-defined structure on disk Nastavit uivatelsky-definovanou strukturu na disku Use a cache for updates and retries Pout cache pro aktualizace a obnoven Do not update zero size or user-erased files Neaktualizovat soubory uivatelem smazan nebo s nulovou velikost Create a Start Page Vytvoit vodn strnku Create a word database of all html pages Vytvoit seznam slov ze vech HTML strnek Create error logging and report files Vytvoit protokol s chybami a hlenmi Generate DOS 8-3 filenames ONLY Vytvet nzvy soubor v DOS 8+3 Generate ISO9660 filenames ONLY for CDROM medias Do not create HTML error pages Nevytvet HTML strnky s chybami Select file types to be saved to disk Vyber typy soubor pro ukldn na disk Select parsing direction Vybrat smr analzy Select global parsing direction Vybrat globln smr analzy Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) Nastav pepis zsad URL pro intern odkazy (jednou ji staen) a extern odkazy (jet nestaen) Max simultaneous connections Maximln poet soubnch spojen File timeout Doba ekn pro soubory Cancel all links from host if timeout occurs Zru vechny odkazy pokud je pekroena doba ekn Minimum admissible transfer rate Minimln ppustn penosov rychlost Cancel all links from host if too slow Zru vechny odkazy pokud je penos pli pomal Maximum number of retries on non-fatal errors Maximln poet opakovn pi nepodstatnch chybch Maximum size for any single HTML file Maximln velikost jednoho HTML souboru Maximum size for any single non-HTML file Maximln velikost jednoho ne-HTML souboru Maximum amount of bytes to retrieve from the Web Maximln poet penesench bajt z Webu Make a pause after downloading this amount of bytes Pozastavit stahovn po penosu tohoto potu bajt Maximum duration time for the mirroring operation Maximln as trvn stahovn Maximum transfer rate Maximln penosov rychlost Maximum connections/seconds (avoid server overload) Maximln poet spojen/sekund (zabrnn peten serveru) Maximum number of links that can be tested (not saved!) Maximln poet odkaz, kter maj bt otestovny (ne uloeny) Browser identity Totonost prohlee Comment to be placed in each HTML file Koment vloen do kadho HTML souboru Back to starting page Zpt na vodn strnku Save current preferences as default values Uloit aktuln nastaven jako vchoz Click to continue Klikni pro pokraovn Click to cancel changes Klikni pro zruen zmn Follow local robots rules on sites Aplikuj lokln pravidla robot na strnkch Links to non-localised external pages will produce error pages Odkazy na nelokalizovan extern strnky zapiin vytvoen strnek s chybami Do not erase obsolete files after update Nesmazat star soubory po jejich aktualizaci Accept cookies? Pijmat cookies? Check document type when unknown? Provit typ dokumentu pokud je neznm? Parse java applets to retrieve included files that must be downloaded? Analyzovat java aplety kvli nalezen nutnch soubor pro staen Store all files in cache instead of HTML only Uloen vech soubor do cache msto jen do HTML Log file type (if generated) Typ protokolu (pokud je vytvoen) Maximum mirroring depth from root address Maximln hloubka stahovn z koenovho adrese Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) Maximln hloubka stahovn pro extern/zakzan adresy (0 - znamenajc dn - je vchoz) Create a debugging file Vytvoen souboru pro ladn Use non-standard requests to get round some server bugs Pout nestandardnch poadavk pro pedejit chyb serveru Use old HTTP/1.0 requests (limits engine power!) Pout star verze HTTP/1.0 poadavk (omezuje vkonost stroje) Attempt to limit retransfers through several tricks (file size test..) Pokus k zamezen optovnho penosu pomoc rznch zpsob (test velikosti souboru,..) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Write external links without login/password Zpis externch odkaz bez pihlen/hesla Write internal links without query string Zpis internch odkaz bez oven etzce Get non-HTML files related to a link, eg external .ZIP or pictures Sthnout soubory patc k odkazu v ne-HTML formtu, nap. extern .ZIP nebo obrzky Test all links (even forbidden ones) Kontrola vech odkaz (vetn zakzanch) Try to catch all URLs (even in unknown tags/code) Pokus o zskn vech URL (vetn tch v neznmch znacch nebo kdech) Get HTML files first! Sthnout nejprve HTML soubory! Structure type (how links are saved) Typ struktury (jak budou odkazy uloeny) Use a cache for updates Pout cache pro aktualizaci Do not re-download locally erased files Znovu nestahovat lokln smazan soubory Make an index Vytvoit rejstk Make a word database Vytvoit seznam slov Log files Protokoly DOS names (8+3) Jmna soubor v DOS (8+3) ISO9660 names (CDROM) No error pages dn chybov strnky Primary Scan Rule Primrn filtr Travel mode Md pro cestovn Global travel mode Globln md pro cestovn These options should be modified only exceptionally Tyto parametry by mli bt zmnny pouze vyjmen Activate Debugging Mode (winhttrack.log) Aktivuj md ladn (winhttrack.log) Rewrite links: internal / external Pepi odkazy: intern/extern Flow control Sledovn bhu Limits Limity Identity Identifikace HTML footer Zhlav HTML N# connections Poet spojen Abandon host if error Peruit spojen, pokud dojde k chyb serveru Minimum transfer rate (B/s) Minimln penosov rychlost (B/s) Abandon host if too slow Peruit spojen, pokud je penos pli pomal Configure Konfigurace Use proxy for ftp transfers Pout proxy pro FTP penos TimeOut(s) asov limity Persistent connections (Keep-Alive) Reduce connection time and type lookup time using persistent connections Retries Poet opakovn Size limit Omezen velikosti Max size of any HTML file (B) Maximln velikost HTML souboru Max size of any non-HTML file Maximln velikost ne-HTML souboru Max site size Maximln velikost strnky Max time Maximln as Save prefs Uloit nastaven Max transfer rate Maximln penososv rychlost Follow robots.txt i se podle robots.txt No external pages dn extern strnky Do not purge old files Neuvolnit star soubory Accept cookies Pjem cookies Check document type Kontrola typu dokumentu Parse java files Analyzovat java soubory Store ALL files in cache Ukldat VECHNY soubory do cache Tolerant requests (for servers) Ppustn poadavky (pro servery) Update hack (limit re-transfers) Aktualizovat chytrou obnovu (zabrn znovu penosu soubor) URL hacks (join similar URLs) Force old HTTP/1.0 requests (no 1.1) Pout pouze star HTTP/1.0 poadavky (ne HTTP/1.1) Max connections / seconds Maximln poet spojen/sekund Maximum number of links Maximln poet odkaz Pause after downloading.. Peruit po staen Hide passwords Skrt heslo Hide query strings Skrt ovovac znaky Links Odkazy Build Struktura Experts Only Pro odbornky Flow Control zen bhu Limits Limitn hodnoty Browser ID ID prohlee Scan Rules Filtry Spider Pavouk Log, Index, Cache Protokol, rejstk, cache Proxy Proxy MIME Types Do you really want to quit WinHTTrack Website Copier? Opravdu ukonit WinHTTrack Website Copier? Do not connect to a provider (already connected) Nepipojovat se k poskytovateli (ji spojeno) Do not use remote access connection Nepouvat vzdlenho pstupovho spojen Schedule the mirroring operation Naplnovat stahovn Quit WinHTTrack Website Copier Ukonit WinHTTrack Website Copier Back to starting page Zpt na vodn strnku Click to start! Klikni pro start No saved password for this connection! Nen uloeno heslo pro toto spojen! Can not get remote connection settings Nen pstup k nastaven vzdlenho spojen Select a connection provider Vyber poskytovatele Start Start Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. Pokud je to nutn, uprav parametry spojen,\npak klikni na DOKONIT pro zahjen stahovn Save settings only, do not launch download now. Pouze uloit nastaven, nezahjit stahovn. On hold Podret Transfer scheduled for: (hh/mm/ss) Nastaven asu stahovn v: (hh/mm/ss) Start Start Connect to provider (RAS) Spojen s poskytovatelem (RAS) Connect to this provider Spojit s tmto poskytovatelem spojen Disconnect when finished Odpojit po dokonen Disconnect modem on completion Odpojit modem po dokonen \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n(Prosme o podn hlen o jakchkoliv chybch)\r\n\r\nVvoj:\r\nRozhran (Windows): Xavier Roche\r\nPavouk: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche a ostatn, kdo pispli\r\nesk peklad:\r\nAntonn Matjk (matejcik@volny.cz) About WinHTTrack Website Copier O programu WinHTTrack Website Copier Please visit our Web page Nvtva na strnky Wizard query Otzky pro pomocnka Your answer: Tv odpov: Link detected.. Odkaz detekovn.. Choose a rule Vybrat filtr Ignore this link Ignorovat tento odkaz Ignore directory Ignorovat adres Ignore domain Ignorovat domnu Catch this page only Zskat pouze tuto strnku Mirror site Strnka pro stahovn Mirror domain Domna strnky pro stahovn Ignore all Ignoruj ve Wizard query Otzka pomocnka NO Ne File Soubor Options Nastaven Log Protokol Window Okno Help Npovda Pause transfer Peruit penos Exit Konec Modify options Zmna nastaven View log Zobrazit protokol View error log Zobrazit chybov protokol View file transfers Zobrazit penosy soubor Hide Do systmov lity About WinHTTrack Website Copier O programu WinHTTrack Website Copier Check program updates... Staen novj verze.. &Toolbar &Lita &Status Bar &Stavov lita S&plit R&ozdlit File Soubor Preferences Nastaven Mirror Stahovn Log Protokol Window Okno Help Npovda Exit Konec Load default options Nahrt vchoz nastaven Save default options Uloit vchoz nastaven Reset to default options Obnovit vchoz nastaven Load options... Nahrt nastaven.. Save options as... Uloit nastaven jako.. Language preference... Volba jazyka Contents... Obsah (Anglicky) About WinHTTrack... O programu WiHTTrack Website Copier New project\tCtrl+N Nov projekt\tCtrl+N &Open...\tCtrl+O &Otet..\tCtrl+O &Save\tCtrl+S &Uloit\tCtrl+S Save &As... Uloit &jako.. &Delete... &Smazat &Browse sites... &Prohldnout staen strnky.. User-defined structure Uivatelsky-definovan struktura %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\tNzev souboru bez ppony (nap. obr)\r\n%N\tNzev souboru vetn ppony (nap. obr.gif)\r\n%t\tPouze ppona (nap. gif)\r\n%p\tCesta [bez poslednho /] (nap. /obrzky)\r\n%h\tWeb adresa (nap. www.kdesi.com)\r\n%M\tMD5 URL (128 bit, 32 ascii bajt)\r\n%Q\tMD5 ovovac etzec (128 bit, 32 ascii bajt)\r\n%q\tMD5 mal ovovac etzec (16 bit, 4 ascii bajt)\r\n\r\n%s?\tZkratka (nap. %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Pklad:\t%h%p/%n%q.%t\n->\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Proxy settings Nastaven proxy Proxy address: Adresa Proxy: Proxy port: Port Proxy Authentication (only if needed) Oven (pouze kdy je vyadovno) Login Pihlen Password Heslo Enter proxy address here Vlo adresu proxy Enter proxy port here Vlo port proxy Enter proxy login Vlo pihlen k proxy Enter proxy password Vlo heslo proxy Enter project name here Napi nzev projektu Enter saving path here Vlo cestu pro uloen Select existing project to update Zvolt existujc projekt pro aktualizaci Click here to select path Klikni pro vbr cesty Select or create a new category name, to sort your mirrors in categories HTTrack Project Wizard... Pomocnk HTTrack projektu.. New project name: Nzev novho projektu: Existing project name: Existujc nzev projektu: Project name: Nzev projektu: Base path: Zkladn cesta: Project category: C:\\My Web Sites C:\\Temp\Projekty Type a new project name, \r\nor select existing project to update/resume Napi nov nzev projektu, \r\nnebo vyber projekt k aktualizaci New project Nov projekt Insert URL Vloit URL adresu URL: URL adresa: Authentication (only if needed) Oven (pouze pokud je teba) Login Pihlen Password Heslo Forms or complex links: Formule nebo souhrn odkazy: Capture URL... Zskat URL.. Enter URL address(es) here Vlo URL adresu(y) Enter site login Vlo pihlen na strnku Enter site password Vlo heslo pro strnku Use this capture tool for links that can only be accessed through forms or javascript code Pout tento nstroj pro zskn odkaz, kter mohou bt dostupn pouze pomoc formul nebo java skript Choose language according to preference Volba jazyka podle nastaven Catch URL! Zskej URL! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. Nastav doasn proxy pro tvj prohle na nsledujc hodnoty (zkoprovat/vloit adresu a port proxy).\nPak klikni na tlatko OK na formuli ve tvm prohlei nebo klikni na dan odkaz, kter chce zskat. This will send the desired link from your browser to WinHTTrack. Poadovan odkaz se odele z tvho prohlee do programu WinHTTrack. ABORT ZRUIT Copy/Paste the temporary proxy parameters here Zkoprovat/Vloit doasn proxy parametry Cancel Zruit Unable to find Help files! Nebylo mon nalzt soubory Npovdy! Unable to save parameters! Nebylo mon uloit parametry! Please drag only one folder at a time Prosm uchop do myi najednou pouze jeden adres Please drag only folders, not files Prosm uchopuj pouze adrese, ne soubory Please drag folders only Prosm uchopuj pouze adrese Select user-defined structure? Vybrat uivatelsky-definovanou strukturu? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! Prosm zajisti, e uivatelsky-definovan etzec je sprvn, jinak budou nzvy soubor patn pojmenovny! Do you really want to use a user-defined structure? Opravdu chce pout uivatelsky-definovanou strukturu? Too manu URLs, cannot handle so many links!! Pli mnoho URL adres, nen mon pracovat s takovm mnostvm! Not enough memory, fatal internal error.. Nedostatek pamti, vn vnitn chyba.. Unknown operation! Neznm operace! Add this URL?\r\n Pidat tuto URL adresu?\r\n Warning: main process is still not responding, cannot add URL(s).. Upozornn: hlavn proces jet nereaguje, nemon pidat URL adresu(y).. Type/MIME associations Type/MIME pidruen File types: Typy soubor: MIME identity: Identita MIME: Select or modify your file type(s) here Vybrat nebo zmnit typ(y) soubor Select or modify your MIME type(s) here Vybrat nebo zmnit typ(y) MIME soubor Go up Nahoru Go down Dol File download information Informace o staenm souboru Freeze Window Zamrznut okna More information: Dal informace: Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download Vtej v programu WinHTTrack!\n\nKlikni na tlatko Dal pro\n\n- vytvoen novho projektu\n nebo \n- nvrat k sten staenmu projektu File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS Nzvy soubor s pponami:\nNzvy soubor obsahujc:\n Tento nzev souboru:\nJmna adres obsahujc:\nTento nzev adrese:\nOdkazy v tto domn:\nOdkazy v domnch obsahujc:\nOdkazy z tohoto potae:\nOdkazy obsahujc:\nTento odkaz:\nVECHNY ODKAZY Show all\nHide debug\nHide infos\nHide debug and infos Zobraz ve\nSkryj ladn\nSkryj informace\nSkryj ladn a informace Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. Struktura strnky (vchoz)\nHtml ve web/, obrzky/ostatn soubory ve web/obrzky/\nHtml ve web/html, obrzky/ostatn ve web/obrzky\nHtml ve web/, obrzky/ostatn ve web/\nHtml ve web/, obrzky/ostatn ve web/xxx, kde xxx zna pponu souboru\nHtml ve web/html, obrzky/ostatn ve web/xxx\nStruktura strnky bez www.domna.xxx/\nHtml v nzev_strnky/, obrzky/ostatn soubory v nzev_strnky/obrzky/\nHtml v nzev_strnky/html, obrzky/ostatn v nzev_strnky/obrzky\nHtml v nzev_strnky/, obrzky/ostatn v nzev_strnky/\nHtml v nzev_strnky/, obrzky/ostatn v nzev_strnky/xxx\nHtml v nzev_strnky/html, obrzky/ostatn v nzev_strnky/xxx\nVechny soubory ve web/, s nhodnmi nzvy (vynlez!)\nVechny soubory v nzev_strnky/, s nhodnmi nzvy (vynlez!)\nUivatelsky-definovan struktura.. Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first Pouze provit\nUloit HTML soubory\nUloit ne-HTML soubory\nUloit vechny soubory (vchoz)\nUloit nejprve HTML soubory Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down Zstat ve stejnm adresi\nDol (vchoz)\nNahoru\nNahoru i dol Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web Zstat na stejn adrese (vchoz)\nZstat ve stejn domn\nZstat ve stejn domn nejvy. du\nJt na jakkoliv web Never\nIf unknown (except /)\nIf unknown Nikdy\nPokud nen znm (krom /)\nPokud nen znm no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules dn pravidla podle robot.txt\nrobot.txt krom pomocnka\naplikovat pravidla podle robot.txt normal\nextended\ndebug normln\nrozen\nladn Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download Staen web strnek\nStaen web strnek + otzky\nStaen soubor\nStaen vech strnek (vcensobn staen)\nKontrola odkaz na strnkch (test zloek)\n* Navzn peruenho stahovn\n* Aktualizace staench strnek Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL Relativn URI/Absolutn URL (vchoz)\nAbsolutn URL/Absolutn URL\nAbsolutn URI/Absolutn URL\nPvodn URL/Pvodn URL Open Source offline browser Website Copier/Offline Browser. Copy remote websites to your computer. Free. httrack, winhttrack, webhttrack, offline browser URL list (.txt) Previous Next URLs Warning Your browser does not currently support javascript. For better results, please use a javascript-aware browser. Thank you You can now close this window Server terminated A fatal error has occurred during this mirror httrack-3.49.5/lang/Castellano.txt0000644000175000017500000011126514360553245013761 00000000000000LANGUAGE_NAME Castellano LANGUAGE_FILE Castellano LANGUAGE_ISO es LANGUAGE_AUTHOR Juan Pablo Barrio Lera (Universidad de Len) \r\n LANGUAGE_CHARSET ISO-8859-1 LANGUAGE_WINDOWSID Spanish (Spain, Modern Sort) OK Ya Cancel Cancelar Exit Salir Close Cerrar Cancel changes Cancelar los cambios Click to confirm Haga click para confirmar Click to get help! Haga click para obtener ayuda Click to return to previous screen Haga click para volver atrs Click to go to next screen Haga click para pasar a la siguiente pantalla Hide password Ocultar palabra clave Save project Guardar proyecto Close current project? Cerrar el proyecto actual? Delete this project? Borrar este proyecto? Delete empty project %s? Borrar el proyecto vaco %s? Action not yet implemented Accin an no implementada Error deleting this project Error al borrar este proyecto Select a rule for the filter Escoja una regla para el filtro Enter keywords for the filter Escriba aqu una palabra clave para el filtro Cancel Cancelar Add this rule Aadir esta regla Please enter one or several keyword(s) for the rule Escriba una o ms palabras clave para la regla Add Scan Rule Aadir un filtro Criterion Escoger una regla String Escribir una palabra clave Add Aadir Scan Rules Filtros Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Puede excluir o aceptar varias URLs o enlaces, empleando los comodines\nSe pueden utilizar espacios entre los filtros\nEjemplo: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Exclude links Excluir enlaces Include link(s) Aceptar enlaces Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) Consejo: Si desea aceptar todos los ficheros GIF de un sitio, utilice algo similar a +www.monweb.com/*.gif\n(+*.gif / -*.gif autorizar TODOS los ficheros GIF en TODOS los sitios) Save prefs Guardar preferencias Matching links will be excluded: Los enlaces que sigan esta regla sern prohibidos Matching links will be included: Los lugares que sigan esta regla sern aceptados Example: Ejemplo: gif\r\nWill match all GIF files gif\r\nDetectar todos los ficheros gif (o ficheros GIF) blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' blue\r\nDetectar todos los ficheros que contengan la palabra blue, como 'bluesky-small.jpeg'\r\n bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' bigfile.mov\r\nDetectar el fichero 'bigfile.mov', pero no 'bigfile2.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\nDetectar los enlaces con nombre de ruta que incluya 'cgi', como /cgi-bin/somecgi.cgi\r\n cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\nDetectar los enlaces con nombre de ruta que incluya 'cgi-bin' (pero no cgi-bin-2, por ejemplo)\r\n someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb.com\r\nDetectar enlaces como www.someweb.com, private.someweb.com, etc.\r\n someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. someweb\r\nDetectar enlaces como www.someweb.com, www.someweb.edu, private.someweb.otherweb.com, etc.\r\n www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.someweb.com\r\nDetectar enlaces como www.someweb.com/... (pero no private.someweb.com/ y similares)\r\n someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. someweb\r\nDetectar enlaces como www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html, etc.\r\n www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/someweb.html\r\nDetectar nicamente www.test.com/test/someweb.html. Note que deber introducir a la vez la direccin (www.xxx.yyy) y la ruta (/test/someweb.html)\r\n All links will match Todos los enlaces sern autorizados/prohibidos Add exclusion filter Aadir un filtro de exclusin Add inclusion filter Aadir un filtro de inclusin Existing filters Filtros adicionales Cancel changes Cancelar los cambios Save current preferences as default values Guardar preferencias como valores por defecto Click to confirm Haga click para confirmar No log files in %s! No hay ficheros de auditora en %s! No 'index.html' file in %s! No hay fichero index.html en %s! Click to quit WinHTTrack Website Copier Haga click para salir de WinHTTrack Website Copier View log files Ver fichero de auditora Browse HTML start page Hojear la pgina inicial End of mirror Fin del volcado View log files Ver fichero de auditora Browse Mirrored Website Hojear la Web New project... Nuevo proyecto... View error and warning reports Ver errores y mensajes View report Ver informe de auditora Close the log file window Cerrar la ventana de auditora Info type: Tipo de informacin: Errors Errores Infos Informaciones Find Buscar Find a word Encontrar una palabra Info log file Fichero de auditora Warning/Errors log file Fichero de auditora de avisos/errores Unable to initialize the OLE system Imposible inicializar el sistema OLE WinHTTrack could not find any interrupted download file cache in the specified folder! No hay cach en el directorio indicado\nWinHTTrack no puede encontrar el volcado interrumpido Could not connect to provider Imposible establecer la conexin receive recepcin request peticin connect conexin search bsqueda ready listo error error Receiving files.. Recepcin de ficheros Parsing HTML file.. Recorriendo fichero HTML Purging files.. Vaciando ficheros.. Loading cache in progress.. Ejecutando la carga del cach.. Parsing HTML file (testing links).. Recorriendo fichero HTML (comprobando enlaces) Pause - Toggle [Mirror]/[Pause download] to resume operation En pausa (escoja [Fichero]/[Interrumpir transferencias] para continuar Finishing pending transfers - Select [Cancel] to stop now! Finalizando transferencias pendientes - Seleccione [Cancelar] para terminar ahora scanning recorriendo Waiting for scheduled time.. Esperando a la hora especificada para comenzar Connecting to provider Conexin con el proveedor [%d seconds] to go before start of operation Volcado en espera [%d segundos] Site mirroring in progress [%s, %s bytes] Volcado en ejecucin [%s, %s bytes] Site mirroring finished! Copia del sitio finalizada! A problem occurred during the mirroring operation\n Ha ocurrido un problema durante el volcado\n \nDuring:\n \nDurante:\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! Ver el fichero de auditora si es necesario.\n\nPulse OK para salir de WinHTTrack Website Copier.\n\nGracias por usar WinHTTrack! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! El volcado ha finalizado.\nPulse OK para salir de WinHTTrack\n\nConsulte los ficheros de auditora para verificar que todo ha salido bien\n\nGracias por utilizar WinHTTrack! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * COPIA INTERRUMPIDA! * *\r\nEs necesario el cache temporal actual para cualquier operacin de actualizacin y solamente contiene datos bajados durante la presente sesin abortada.\r\nEl antiguo cache puede contener datos ms completos; si vd. no desea perder dichos datos, deber que restaurarlo y excluir el cache actual.\r\n[Nota: Esto puede hacerse fcilmente aqu excluyendo el hts-cache/nuevo.* ficheros]\r\n\r\nCree que el antiguo cache puede contener datos ms completos, y desea restaurarlo? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * ERROR DE VOLCADO! * *\r\nHTTrack ha detectado que el volcado actual est vaco. Si se trataba de una actualizacin, el volcado anterior ha sido recuperado.\r\nRazn: no se ha(n) encontrado la(s) primera(s) pgina(s), o ha habido un problema de conexin.\r\n=> Asegrese de que el sitio web existe an, y/o compruebe los ajustes de su proxy! <= \n\nTip: Click [View log file] to see warning or error messages \n\nConsejo: Pulse [Ver ficheros auditora] para ver los errores y mensajes Error deleting a hts-cache/new.* file, please do it manually Error al excluir un hts-cache/nuevo.* fichero; por favor, hgalo manualmente Do you really want to quit WinHTTrack Website Copier? Desea realmente salir de WinHTTrack Website Copier? - Mirroring Mode -\n\nEnter address(es) in URL box - Modo de volcado -\n\nRellene la(s) direccion(es) en la lista de URLs. - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - Modo de volcado semiautomtico (con preguntas); rellene la(s) direccion(es) en la lista de URLs. - File Download Mode -\n\nEnter file address(es) in URL box - Modo de telecarga de ficheros; rellene la(s) direccion(es) de los ficheros en la lista de URLs. - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - Modo de comprobacin de enlaces -\n\nRellene la(s) direccion(es) de las pginas con enlaces a comprobar en el recuadro de URL. - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Modo de actualizacin/continuacin de volcado -\n\nVerifique la(s) direccion(es) de la lista de URLs, y luego pulse el botn 'SIGUIENTE' y verifique los parmetros. - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - Modo de continuacin de volcado -\n\nVerifique la(s) direccion(es) de la lista de URLs, y luego pulse el botn 'SIGUIENTE' y verifique los parmetros. Log files Path Ruta de ficheros log Path Ruta - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror Modo de volcado de enlaces; rellene las direcciones de las pginas que contengan los enlaces a volcar en la lista de URLs. New project / Import? Nuevo proyecto / importar ? Choose criterion Escoja una accin Maximum link scanning depth Profundidad mxima Enter address(es) here Escriba aqu las direcciones Define additional filtering rules Definir filtros adicionales Proxy Name (if needed) Proxy si es necesario Proxy Port Puerto del proxy Define proxy settings Definir las preferencias del proxy Use standard HTTP proxy as FTP proxy Usar el proxy HTTP estndar como proxy FTP Path Ruta Select Path Escoja ruta Path Ruta Select Path Escoja ruta Quit WinHTTrack Website Copier Salir de WinHTTrack Website Copier About WinHTTrack Acerca de WinHTTrack Save current preferences as default values Guardar preferencias como valores por defecto Click to continue Haga click para continuar Click to define options Haga click para definir las opciones Click to add a URL Haga click para aadir una URL Load URL(s) from text file Cargar URL(s) desde fichero de texto WinHTTrack preferences (*.opt)|*.opt|| Preferencias de WinHTTrack (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| Fichero de texto de Lista de Direcciones (*txt)|*.txt|| File not found! Fichero no encontrado! Do you really want to change the project name/path? Desea realmente cambiar el nombre/ruta del proyecto? Load user-default options? Cargar las opciones de usuario por defecto? Save user-default options? Guardar las opciones de usuario por defecto? Reset all default options? Pasar todas las opciones a sus valores por defecto? Welcome to WinHTTrack! Bienvenido a WinHTTrack Website Copier! Action: Accin Max Depth Profundidad mxima: Maximum external depth: Profundidad externa mxima: Filters (refuse/accept links) : Filtros (rehusar/aceptar enlaces) : Paths Rutas Save prefs Guardar prefs Define.. Definir... Set options.. Definir las opciones.. Preferences and mirror options: Definir las opciones.. Project name Nombre del proyecto Add a URL... Aadir... Web Addresses: (URL) Direccin Web: (URL) Stop WinHTTrack? Detener WinHTTrack? No log files in %s! No hay ficheros de auditora en %s! Pause Download? Poner en pausa la transferencia? Stop the mirroring operation Detener el volcado Minimize to System Tray Ocultar esta ventana tras la barra de sistema Click to skip a link or stop parsing Haga click para saltar un enlace o interrumpir el recorrido Click to skip a link Haga click para saltar un enlace Bytes saved Bytes guardados: Links scanned Enlaces recorridos: Time: Tiempo: Connections: Conexiones: Running: En ejecucin: Hide Ocultar Transfer rate Tasa de transferencia: SKIP SALTAR Information Informaciones Files written: Ficheros escritos: Files updated: Ficheros puestos al da: Errors: Errores: In progress: En progreso: Follow external links Recuperar ficheros incluso bajo enlaces externos Test all links in pages Comprobar todos los enlaces de las pginas Try to ferret out all links Intentar detectar todos los enlaces Download HTML files first (faster) Bajar ficheros HTML primero (ms rpido) Choose local site structure Escoger la estructura local de ficheros Set user-defined structure on disk Definir la estructura del sitio en el disco Use a cache for updates and retries Utilizar un cach para actualizaciones y reintentos Do not update zero size or user-erased files No volver a descargar ficheros ya existentes con tamao nulo o que hayan sido borrados por el usuario Create a Start Page Generar pgina de inicio Create a word database of all html pages Crear una base de datos de palabras de todas las pginas HTML Create error logging and report files Generar ficheros de auditora para los errores y mensajes Generate DOS 8-3 filenames ONLY Generar nicamente ficheros con nombres cortos 8-3 Generate ISO9660 filenames ONLY for CDROM medias Generar nombres de fichero ISO9660 SOLO para soportes CDROM Do not create HTML error pages No generar ficheros de error html Select file types to be saved to disk Seleccin de los tipos de fichero a guardar Select parsing direction Seleccin de la direccin del volcado Select global parsing direction Seleccin de la direccin global del volcado Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) Configurar reglas de regrabacin de URLs para enlaces internos (los bajados) y enlaces externos (los no bajados) Max simultaneous connections Nmero mximo de conexiones File timeout Tiempo muerto mximo para un fichero Cancel all links from host if timeout occurs Anular todos los enlaces de un dominio en caso de tiempo muerto Minimum admissible transfer rate Tasa de transferencia mnima tolerada Cancel all links from host if too slow Anular todos los enlaces de un dominio en caso de transferencia demasiado lenta Maximum number of retries on non-fatal errors Nmero mximo de reintentos en caso de error no fatal Maximum size for any single HTML file Tamao mximo para una pgina html Maximum size for any single non-HTML file Tamao mximo para un fichero Maximum amount of bytes to retrieve from the Web Tamao total mximo para el volcado Make a pause after downloading this amount of bytes Hacer una pausa antes de descargar esta cantidad de bytes Maximum duration time for the mirroring operation Tiempo total mximo para el volcado Maximum transfer rate Tasa de transferencia mxima Maximum connections/seconds (avoid server overload) N mximo de conexiones/segundo (evitar sobrecarga de servidor) Maximum number of links that can be tested (not saved!) Nmero mximo de enlaces que pueden ser comprobados (no grabados!) Browser identity Identidad del navegador Comment to be placed in each HTML file Pie de pgina colocado en cada fichero HTML Back to starting page Volver a la primera pgina Save current preferences as default values Guardar preferencias como valores por defecto Click to continue Haga click para continuar Click to cancel changes Haga click para cancelar Follow local robots rules on sites Seguir las reglas locales de los robots sobre los sitios Links to non-localised external pages will produce error pages Las pginas externas (no capturadas) apuntarn a pginas de error Do not erase obsolete files after update No borrar los ficheros antiguos tras una puesta al da Accept cookies? Aceptar las cookies enviadas? Check document type when unknown? Verificar el tipo de documento cuando es desconocido? Parse java applets to retrieve included files that must be downloaded? Analizar los applets Java para recuperar los ficheros incluidos? Store all files in cache instead of HTML only Forzar el almacenaje de todos los ficheros en el cache y no solamente los HTML Log file type (if generated) Tipo de fichero de auditora generado Maximum mirroring depth from root address Profundidad mxima de volcado desde las primeras direcciones Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) Maximum mirroring depth for external/fodbidden addresses (0, that is, none, is the default) Create a debugging file Crear un fichero de depuracin Use non-standard requests to get round some server bugs Intentar evitar los fallos de algunos servidores empleando peticiones no estandarizadas Use old HTTP/1.0 requests (limits engine power!) Usar peticiones del antiguo HTTP/1.0 (limita la potencia del motor!) Attempt to limit retransfers through several tricks (file size test..) Intentar limitar las retransferencias mediante varios trucos (comprobacin de tamao de ficheros, ...) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Intentar limitar el nmero de enlaces descartando URLs similares (www.foo.com==foo.com, http=https ..) Write external links without login/password Grabar enlaces externos sin login/password Write internal links without query string Grabar enlaces externos sin cadena de peticin Get non-HTML files related to a link, eg external .ZIP or pictures Capturar los ficheros no html prximos (ej: ficheros ZIP situados en el exterior) Test all links (even forbidden ones) Comprobar todos los enlaces (incluso los no permitidos) Try to catch all URLs (even in unknown tags/code) Intentar detectar todos los enlaces (incluso los tags desconocidos / cdigo javascript) Get HTML files first! Recibir ficheros HTML primero! Structure type (how links are saved) Tipo de estructura (forma en la que sern guardados los enlaces) Use a cache for updates Utilizar un cache para la puesta al da Do not re-download locally erased files No volver a descargar ficheros borrados localmente Make an index Hacer un ndice Make a word database Elaborar una base de datos de palabras Log files Ficheros auditora DOS names (8+3) Nombres DOS (8+3) ISO9660 names (CDROM) Nombres ISO9660 (CDROM) No error pages Sin pginas de error Primary Scan Rule Filtro primario Travel mode Modo de recorrido Global travel mode Modo de recorrido global These options should be modified only exceptionally Normalmente estas opciones no deberan ser modificadas Activate Debugging Mode (winhttrack.log) Activar el modo de depuracin (winhttrack.log) Rewrite links: internal / external Volver a grabar enlaces: internos / externos Flow control Control de flujo Limits Lmites Identity Identidad HTML footer Pie de pgina HTML N# connections N de conexiones Abandon host if error Abandonar host en caso de error Minimum transfer rate (B/s) Tasa de transferencia mnima (B/s) Abandon host if too slow Abandonar host si es muy lento Configure Configurar Use proxy for ftp transfers Usar el proxy para transferencias FTP TimeOut(s) Intervalo(s) Persistent connections (Keep-Alive) Conexiones persistentes (mantener activas) Reduce connection time and type lookup time using persistent connections Reduzca tiempo de conexin y bsqueda de tipos mediante las conexiones persistentes Retries Reintentos Size limit Lmite de tamao Max size of any HTML file (B) Tamao mximo html Max size of any non-HTML file Tamao mximo otro Max site size Tamao mximo del sitio Max time Tiempo mximo Save prefs Guardar preferencias Max transfer rate Velocidad mxima Follow robots.txt Seguir robots.txt No external pages Sin pginas externas Do not purge old files No eliminar ficheros antiguos Accept cookies Aceptar las cookies Check document type Verificar el tipo de documento Parse java files Analizar los ficheros Java Store ALL files in cache Forzar almacenaje de todos los ficheros en el cache Tolerant requests (for servers) Peticiones tolerantes (para servidores) Update hack (limit re-transfers) Update hack (limitar retransferencias) URL hacks (join similar URLs) Trucos para URLs (unir URLs similares) Force old HTTP/1.0 requests (no 1.1) Forzar peticiones HTTP/1.0 anterior (no 1.1) Max connections / seconds N mx. conexiones / segundos Maximum number of links Nmero mximo de enlaces Pause after downloading.. Suspender tras copiar... Hide passwords Ocultar palabra clave Hide query strings Ocultar cadenas de peticin Links Enlaces Build Estructura Experts Only Experto Flow Control Control de flujo Limits Lmites Browser ID Identidad Scan Rules Filtros Spider Araa (spider) Log, Index, Cache Auditora, ndice, Cache Proxy Proxy MIME Types Tipos MIME Do you really want to quit WinHTTrack Website Copier? Desea realmente salir de WinHTTrack Website Copier? Do not connect to a provider (already connected) no conectar con proveedor (conexin ya establecida) Do not use remote access connection No utilizar conexin de acceso remoto Schedule the mirroring operation Programar un volcado Quit WinHTTrack Website Copier Salir de WinHTTrack Website Copier Back to starting page Volver a la primera pgina Click to start! Haga click para comenzar No saved password for this connection! No hay palabra clave guardada para esta conexin! Can not get remote connection settings Imposible obtener los parmetros de conexin Select a connection provider Seleccione aqu un proveedor con el cual conectar Start COMENZAR Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. Puede comenzar el volcado pulsando la tecla COMENZAR,\no definir ms opciones de conexin Save settings only, do not launch download now. Grabar solamente configuraciones, no cargar o bajar ahora. On hold Retrasar Transfer scheduled for: (hh/mm/ss) Esperar hasta las: (hh/mm/ss) Start COMENZAR Connect to provider (RAS) Proveedor de Internet Connect to this provider Conectar con este proveedor Disconnect when finished Desconectar al terminar la operacin Disconnect modem on completion Desconectar el modem al terminar \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n(notifquenos fallos o problemas)\r\n\r\nDesarrollo:\r\nInterface (Windows): Xavier Roche\r\nMotor: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for Spanish translations to:\r\nJuan Pablo Barrio Lera (Universidad de Len) About WinHTTrack Website Copier Acerca de... Please visit our Web page Visite nuestra pgina Web! Wizard query Pregunta del asistente Your answer: Su respuesta: Link detected.. Se ha detectado un enlace Choose a rule Escoja una regla Ignore this link Ignorar este enlace Ignore directory Ignorar directorio Ignore domain Ignorar dominio Catch this page only Coger slo esta pgina Mirror site Volcar el sitio Mirror domain Volcar todo el dominio Ignore all Ignorar todo Wizard query Pregunta del asistente NO NO File Ficheros Options Opciones Log Auditora Window Ventanas Help Ayuda Pause transfer Poner en pausa Exit Salir Modify options Modificar las opciones View log Ver fichero de auditora View error log Ver fichero de error View file transfers Ver las transferencias de ficheros Hide Ocultar About WinHTTrack Website Copier Acerca de... Check program updates... Buscar actualizaciones de WinHTTrack... &Toolbar Barra de herramientas &Status Bar Barra de estado S&plit Dividir File Ficheros Preferences Opciones Mirror Copia del sitio Log Auditora Window Ventanas Help Ayuda Exit Salir Load default options Cargar opciones por defecto Save default options Guardar opciones por defecto Reset to default options Borrar opciones por defecto Load options... Cargar opciones... Save options as... Guardar opciones como... Language preference... Preferencias de idioma Contents... Indice.. About WinHTTrack... Acerca de WinHTTrack Website Copier New project\tCtrl+N Nuevo proyecto\tCtrl+N &Open...\tCtrl+O &Abrir...\tCtrl+O &Save\tCtrl+S &Guardar\tCtrl+S Save &As... Guardar &como... &Delete... &Borrar... &Browse sites... &Explorer sites... User-defined structure Estructura local de ficheros %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\tNombre de fichero sin ext. (ej: image)\r\n%N\tNombre de fichero con extensin (ej: image.gif)\r\n%t\tExtensin (ex: gif)\r\n%p\tRuta [sin / al final] (ej: /someimages)\r\n%h\tNombre del servidor (ej: www.someweb.com)\r\n%M\tURL MD5 (128 bits, 32 ascii bytes)\r\n%Q\tquery string MD5 (128 bits, 32 ascii bytes)\r\n%q\tsmall query string MD5 (16 bits, 4 ascii bytes)\r\n\r\n%s?\tVersin corta DOS (ej: %sN)\r\n Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Ejemplo:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif\r\n Proxy settings Preferencias del proxy Proxy address: Direccin del proxy Proxy port: Puerto del proxy Authentication (only if needed) Identificacin (si es necesaria) Login Login Password Pass Enter proxy address here Escriba aqu la direccin del proxy Enter proxy port here Escriba aqu el puerto del proxy Enter proxy login Escriba el nombre del usuario del proxy Enter proxy password Escriba la palabra clave de acceso al proxy Enter project name here Escriba aqu el nombre del proyecto Enter saving path here Escriba aqu la ruta donde ser grabado el proyecto Select existing project to update Seleccione aqu un proyecto existente para actualizarlo Click here to select path Haga click aqu para seleccionar la ruta Select or create a new category name, to sort your mirrors in categories Seleccionar o crear un nuevo nombre de categora, o clasificar los volcados en categoras HTTrack Project Wizard... Asistente para proyectos de HTTrack New project name: Nuevo nombre del proyecto: Existing project name: Nombre de proyecto existente: Project name: Nombre del proyecto: Base path: Ruta base: Project category: Categora del proyecto: C:\\My Web Sites C:\\Mis lugares Web Type a new project name, \r\nor select existing project to update/resume Escriba el nombre de un nuevo proyecto, \r\no seleccione un proyecto existente para ponerle al da o continuar\r\n\r\n New project Nuevo proyecto Insert URL Insertar direccin URL URL: Direccin URL Authentication (only if needed) Identificacin (si es necesaria) Login Login Password Pass Forms or complex links: Formularios o URL complejas: Capture URL... Capturar URL... Enter URL address(es) here Escriba aqu la direccin URL Enter site login Escriba el nombre de usuario del lugar Enter site password Escriba la palabra clave de acceso al lugar Use this capture tool for links that can only be accessed through forms or javascript code Use esta herramienta para capturar enlaves que solamente puedan ser accedidos a travs de formularios o enlaces javascript Choose language according to preference Seleccione aqu su idioma Catch URL! Capturar URL! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. Por favor, disponga temporalmente sus preferencias de proxy en el navegador en los siguientes valores (cortar/pegar la direccin y puerto del proxy). Luego, en el navegador, pulse el botn de envo del formulario o en el enlace concreto que quiera capturar. This will send the desired link from your browser to WinHTTrack. Esto capturar el enlace deseado desde su navegador hasta HTTrack. ABORT CANCELAR Copy/Paste the temporary proxy parameters here Copie y pegue aqu las preferencias temporales del proxy Cancel Cancelar Unable to find Help files! Imposible localizar ficheros de ayuda! Unable to save parameters! Imposible guardar los parmetros! Please drag only one folder at a time No deposite ms que una carpeta Please drag only folders, not files Deposite slo una carpeta, no un fichero Please drag folders only Deposite slo una carpeta Select user-defined structure? Seleccionar estructura definible por el usuario? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! Asegrese de que la cadena de usuario es correcta\nSi no lo es, los nombres de ficheros sern errneos!\r\n\r\n Do you really want to use a user-defined structure? Desea realmente seleccionar la estructura definible por el usuario? Too manu URLs, cannot handle so many links!! Demasiadas URLs. es imposible manejar tantos enlaces! Not enough memory, fatal internal error.. Memoria insuficiente; error interno crtico. Unknown operation! Operacin desconocida! Add this URL?\r\n Aadir esta URL?\r\n Warning: main process is still not responding, cannot add URL(s).. Aviso: el proceso principal no responde an; imposible aadir las URLs. Type/MIME associations Asociaciones de tipo/MIME File types: Tipos de fichero: MIME identity: MIME identity Select or modify your file type(s) here Seleccione o modifique sus tipos de fichero aqu Select or modify your MIME type(s) here Seleccione o modifique sus tipos MIME aqu Go up Ir ms arriba Go down Ir ms abajo File download information Informaciones sobre los ficheros bajados Freeze Window Congelar la ventana More information: Ms informaciones Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download Bienvenido al WinHTTrack Website Copier!\n\nPor favor, pulse el botn AVANZAR para\n\niniciar un nuevo proyecto o volver a un proyecto parcialmente realizado. File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS Nombres de fichero con extensin:\nNombres de fichero conteniendo:\nNombre de este fichero:\nNombres de carpeta conteniendo:\nNombre de esta carpeta:\nEnlaces de este domnio:\nEnlaces en domnios conteniendo:\nEnlaces de este servidor:\nEnlaces conteniendo:\nEste enlace:\nTODOS LOS ENLACES Show all\nHide debug\nHide infos\nHide debug and infos Mostrar todo\nOcultar errores\nOcultar informaciones\nOcultar errores e informaciones Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. Estructura del sitio (por defecto)\nHtml en la web/, imgenes/otros archivos en la web/imgenes/\nHtml en la web/html, imgenes/otros en la web/imgenes\nHtml en la web/, imgenes/otros en la web/\nHtml en la web/, imgenes/otros en la web/xxx, donde xxx es la extensin del fichero\nHtml en la web/html, imgenes/otros en la web/xxx\nEstructura del sitio, sin www.dominio.xxx/\nHtml en nombre_del_sitio/, imgenes/otros en nombre_del_sitio/imgenes/\nHtml en nombre_del_sitio/html, imgenes/otros en nombre_del_sitio/imgenes\nHtml en nombre_del_sitio/, imgenes/otros en nombre_del_sitio/\nHtml en nombre_del_sitio/, imgenes/otros en nombre_del_sitio/xxx\nHtml en nombre_del_sitio/html, imgenes/otros en nombre_del_sitio/xxx\nTodos los ficheros en la web/, con nombres aleatorios (gadget !)\nTodos los ficheros en nombre_del_sitio/, con nombres aleatorios (gadget !)\nEstructura definida por el usuario.. Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first Solamente analizar\nAlmacenar ficheroos html\nAlmacenar ficheros, no html\nAlmacenar todos los ficheros (por omisin)\nAlmacenar ficheros html primero Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down Permanecer en el mismo directorio\nPermite ir hacia abajo (por omisin)\nPermite ir hacia arriba\nPermite ir hacia arriba & hacia abajo Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web Permanecer en la misma direccin (por omisin)\nPermanecer en el mismo domnio\nPermanecer en el mismo domnio de nivel superior\nIr a todos los lugares de la Web Never\nIf unknown (except /)\nIf unknown Nunca\nSi es desconocido (excepto /)\nSi es desconocido no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules ninguna regla para robots.txt\nexcepto asistente robots.txt\nseguir reglas robots.txt normal\nextended\ndebug normal\nextendido\ncorregir Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download Copiar sitio(s) de la Web\nCopiar sitio(s) interactivos de la Web (preguntas)\nRecibir ficheros especficos\nCopiar todas las pginas del sitio (copia mltiple)\nComprobar enlaces en las pginas (probar marcadores)\n* Continuar proyecto interrumpido\n* Actualizar proyecto existente Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL URI relativa / URL absoluta (por omisin)\nURL Absoluta / URL absoluta\nURI absoluta / URL absoluta\nURL original / URL original Open Source offline browser Navegador offline Open Source Website Copier/Offline Browser. Copy remote websites to your computer. Free. Copiador de sitios Web/Browser Offline. Copia sitios web remotos en el ordenador. Gratuito. httrack, winhttrack, webhttrack, offline browser httrack, winhttrack, webhttrack, offline browser URL list (.txt) Lista de URLs (.txt) Previous Anterior Next Siguiente URLs URLs Warning Aviso Your browser does not currently support javascript. For better results, please use a javascript-aware browser. Su navegador no soporta javascript. Obtendr mejores resultados si usa un navegador que admita javascript. Thank you Gracias You can now close this window Ya puede cerrar esta ventana Server terminated Servidor desconectado A fatal error has occurred during this mirror Ha ocurrido un error fatal durante esta copia httrack-3.49.5/lang/Bulgarian.txt0000644000175000017500000011000114360553245013563 00000000000000LANGUAGE_NAME Bulgarian LANGUAGE_FILE Bulgarian LANGUAGE_ISO bg LANGUAGE_AUTHOR [ilia@infomat-bg.com]\r\n LANGUAGE_CHARSET windows-1251 LANGUAGE_WINDOWSID Bulgarian OK Cancel Exit Close Cancel changes Click to confirm Click to get help! Click to return to previous screen Click to go to next screen Hide password Save project Close current project? ? Delete this project? ? Delete empty project %s? %s? Action not yet implemented Error deleting this project Select a rule for the filter Enter keywords for the filter Cancel Add this rule Please enter one or several keyword(s) for the rule Add Scan Rule Criterion String Add Scan Rules Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi . URL .\n ,\n \n\n: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi Exclude links Include link(s) Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) : .GIF , +www.someweb.com/*.gif. \n(+*.gif / -*.gif, / .GIF Save prefs Matching links will be excluded: Matching links will be included: Example: : gif\r\nWill match all GIF files gif\r\n .GIF blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' blue\r\n 'blue' 'bluesky-small.jpeg' bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' bigfile.mov\r\n 'bigfile.mov', 'bigfile2.mov' cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi cgi\r\n 'cgi' /cgi-bin/somecgi.cgi cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) cgi-bin\r\n 'cgi-bin', cgi-bin-2, someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. someweb.com\r\n www.someweb.com, private.someweb.com .. someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. someweb.com\r\n www.someweb.com, www.someweb.edu, private.someweb.otherweb.com .. www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) www.someweb.com\r\n 'www.someweb.com', private.someweb.com/ someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. someweb\r\n www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html .. www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) www.test.com/test/someweb.html\r\n 'www.test.com/test/someweb.html'. , (URL + ) All links will match Add exclusion filter Add inclusion filter Existing filters Cancel changes Save current preferences as default values Click to confirm No log files in %s! %s log ! No 'index.html' file in %s! %s 'index.html'! Click to quit WinHTTrack Website Copier WinHTTrack Website Copier View log files log- Browse HTML start page HTML End of mirror View log files log- Browse Mirrored Website . New project... ... View error and warning reports View report Close the log file window log- Info type: : Errors Infos Find Find a word Info log file log- Warning/Errors log file . Unable to initialize the OLE system OLE WinHTTrack could not find any interrupted download file cache in the specified folder! WinHTTrack - ! Could not connect to provider receive request connect search ready error Receiving files.. ... Parsing HTML file.. HTML ... Purging files.. ... Loading cache in progress.. ... Parsing HTML file (testing links).. HTML ( )... Pause - Toggle [Mirror]/[Pause download] to resume operation - []/[ ] Finishing pending transfers - Select [Cancel] to stop now! - [] ! scanning Waiting for scheduled time.. ... Connecting to provider [%d seconds] to go before start of operation [%d ] Site mirroring in progress [%s, %s bytes] [%s, %s ] Site mirroring finished! ! A problem occurred during the mirroring operation\n \n \nDuring:\n \n :\n \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! \n log- .\n\n WinHTTrack Website Copier.\n\n, , WinHTTrack! Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! !\n WinHTTrack.\n log- , .\n\n, , WinHTTrack! * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? * * ! * *\r\n .\r\n - ; , .\r\n[: hts-cache/new.* ]\r\n\r\n , ? * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= * * ! * *\r\n . , .\r\n: () , .\r\n=> , / proxy ! <= \n\nTip: Click [View log file] to see warning or error messages \n\n: [ log-] Error deleting a hts-cache/new.* file, please do it manually hts-cache/new.* , Do you really want to quit WinHTTrack Website Copier? , WinHTTrack Website Copier? - Mirroring Mode -\n\nEnter address(es) in URL box - : -\n\n URL - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box - : () -\n\n URL - File Download Mode -\n\nEnter file address(es) in URL box - : -\n\n URL - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box - : -\n\n URL - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - : -\n\n URL , , '' - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button - : ( ) -\n\n URL , , '' Log files Path log- Path - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror - : -\n\n URL New project / Import? / Choose criterion Maximum link scanning depth Enter address(es) here Define additional filtering rules Proxy Name (if needed) Proxy ( ) Proxy Port Proxy Define proxy settings proxy Use standard HTTP proxy as FTP proxy HTTP proxy FTP proxy Path Select Path Path Select Path Quit WinHTTrack Website Copier WinHTTrack Website Copier About WinHTTrack WinHTTrack Save current preferences as default values Click to continue Click to define options Click to add a URL URL Load URL(s) from text file URL WinHTTrack preferences (*.opt)|*.opt|| WinHTTrack (*.opt)|*.opt|| Address List text file (*.txt)|*.txt|| (*.txt)|*.txt|| File not found! ! Do you really want to change the project name/path? , / ? Load user-default options? ? Save user-default options? ? Reset all default options? ? Welcome to WinHTTrack! WinHTTrack! Action: : Max Depth : Maximum external depth: . : Filters (refuse/accept links) : (/ ) : Paths Save prefs Define.. ... Set options.. ... Preferences and mirror options: . ... Project name Add a URL... URL... Web Addresses: (URL) : (URL) Stop WinHTTrack? WinHTTrack? No log files in %s! %s log-! Pause Download? ? Stop the mirroring operation ? Minimize to System Tray System Tray Click to skip a link or stop parsing Click to skip a link Bytes saved : Links scanned Time: : Connections: : Running: : Hide Transfer rate : SKIP Information Files written: : Files updated: : Errors: : In progress: : Follow external links Test all links in pages Try to ferret out all links Download HTML files first (faster) HTML (-) Choose local site structure Set user-defined structure on disk Use a cache for updates and retries Do not update zero size or user-erased files Create a Start Page Create a word database of all html pages html Create error logging and report files Generate DOS 8-3 filenames ONLY DOS (8-3) Generate ISO9660 filenames ONLY for CDROM medias ISO9660 CDROM Do not create HTML error pages HTML - Select file types to be saved to disk , Select parsing direction Select global parsing direction Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) URL ( ) ( ) Max simultaneous connections File timeout Cancel all links from host if timeout occurs . Minimum admissible transfer rate Cancel all links from host if too slow Maximum number of retries on non-fatal errors - Maximum size for any single HTML file HTML Maximum size for any single non-HTML file -HTML Maximum amount of bytes to retrieve from the Web , Make a pause after downloading this amount of bytes Maximum duration time for the mirroring operation Maximum transfer rate Maximum connections/seconds (avoid server overload) / ( ) Maximum number of links that can be tested (not saved!) , ( !) Browser identity Comment to be placed in each HTML file HTML Back to starting page Save current preferences as default values Click to continue Click to cancel changes Follow local robots rules on sites Links to non-localised external pages will produce error pages - Do not erase obsolete files after update Accept cookies? ''? Check document type when unknown? , ? Parse java applets to retrieve included files that must be downloaded? Java , ? Store all files in cache instead of HTML only , HTML Log file type (if generated) log- ( ) Maximum mirroring depth from root address Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) / (0 - , ) Create a debugging file debug- Use non-standard requests to get round some server bugs , Use old HTTP/1.0 requests (limits engine power!) HTTP/1.0 ( ) Attempt to limit retransfers through several tricks (file size test..) - ( ..) Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) Write external links without login/password / Write internal links without query string Get non-HTML files related to a link, eg external .ZIP or pictures -HTML , . .ZIP Test all links (even forbidden ones) ( ) Try to catch all URLs (even in unknown tags/code) URL ( /) Get HTML files first! HTML ! Structure type (how links are saved) ( ) Use a cache for updates Do not re-download locally erased files Make an index Make a word database Log files Log DOS names (8+3) DOS (8+3) ISO9660 names (CDROM) ISO9660 (CDROM) No error pages Primary Scan Rule Travel mode Global travel mode These options should be modified only exceptionally , Activate Debugging Mode (winhttrack.log) (winhttrack.log) Rewrite links: internal / external : (/) Flow control Limits Identity HTML footer HTML (footer) N# connections Abandon host if error Minimum transfer rate (B/s) . (/.) Abandon host if too slow Configure Use proxy for ftp transfers FTP TimeOut(s) () Persistent connections (Keep-Alive) (Keep-Alive) Reduce connection time and type lookup time using persistent connections Retries Size limit Max size of any HTML file (B) . HTML () Max size of any non-HTML file . -HTML () Max site size Max time Save prefs Max transfer rate Follow robots.txt robots.txt No external pages Do not purge old files Accept cookies '' Check document type Parse java files Java Store ALL files in cache Tolerant requests (for servers) ( ) Update hack (limit re-transfers) Update hack ( ) URL hacks (join similar URLs) Force old HTTP/1.0 requests (no 1.1) HTTP/1.0 ( 1.1) Max connections / seconds / Maximum number of links Pause after downloading.. .. Hide passwords Hide query strings Links Build Experts Only Flow Control Limits Browser ID Scan Rules Spider Log, Index, Cache Log, , Proxy MIME Types MIME Do you really want to quit WinHTTrack Website Copier? , WinHTTrack Website Copier? Do not connect to a provider (already connected) ( ) Do not use remote access connection Schedule the mirroring operation Quit WinHTTrack Website Copier WinHTTrack Website Copier Back to starting page Click to start! ! No saved password for this connection! ! Can not get remote connection settings Select a connection provider Start Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. , . ,\n . Save settings only, do not launch download now. ! ! On hold Transfer scheduled for: (hh/mm/ss) : (//) Start Connect to provider (RAS) ( ) Connect to this provider Disconnect when finished Disconnect modem on completion \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) \r\n( )\r\n\r\n:\r\n (Windows): Xavier Roche\r\n: Xavier Roche\r\nJava : Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche \r\n :\r\n (ilia@infomat-bg.com) About WinHTTrack Website Copier WinHTTrack Website Copier Please visit our Web page Wizard query Your answer: : Link detected.. .. Choose a rule Ignore this link Ignore directory Ignore domain Catch this page only Mirror site Mirror domain Ignore all Wizard query NO File Options Log Log Window Help Pause transfer Exit Modify options View log log- View error log log- View file transfers Hide About WinHTTrack Website Copier WinHTTrack Website Copier Check program updates... ... &Toolbar & &Status Bar & S&plit & File Preferences Mirror Log Log Window Help Exit Load default options Save default options Reset to default options Load options... ... Save options as... ... Language preference... ... Contents... About WinHTTrack... WinHTTrack... New project\tCtrl+N \tCtrl+N &Open...\tCtrl+O &...\tCtrl+O &Save\tCtrl+S &\tCtrl+S Save &As... &... &Delete... & &Browse sites... & ... User-defined structure %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) %n\t (.: image)\r\n%N\t (.: image.gif)\r\n%t\t ()(.: gif)\r\n%p\t [ '/' ](.: /someimages)\r\n%h\t (.: www.someweb.com)\r\n%M\tMD5 URL (128 , 32 ascii )\r\n%Q\tMD5 (128 , 32 ascii )\r\n%q\tMD5 (16 , 4 ascii )\r\n\r\n%s?\t (.: %sN) Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif :\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif Proxy settings Proxy address: : Proxy port: : Authentication (only if needed) ( ) Login Password Enter proxy address here Enter proxy port here Enter proxy login Enter proxy password Enter project name here Enter saving path here Select existing project to update Click here to select path Select or create a new category name, to sort your mirrors in categories HTTrack Project Wizard... HTTrack -... New project name: : Existing project name: : Project name: : Base path: : Project category: C:\\My Web Sites C:\\ Type a new project name, \r\nor select existing project to update/resume , \r\n / New project Insert URL URL URL: URL: Authentication (only if needed) Login Password Forms or complex links: : Capture URL... URL... Enter URL address(es) here URL () Enter site login Enter site password Use this capture tool for links that can only be accessed through forms or javascript code , JavaScript Choose language according to preference Catch URL! URL! Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. ('Copy/Paste' ).\n (SUBMIT) , . This will send the desired link from your browser to WinHTTrack. WinHTTrack. ABORT Copy/Paste the temporary proxy parameters here Copy/Paste Cancel Unable to find Help files! ! Unable to save parameters! ! Please drag only one folder at a time Please drag only folders, not files , Please drag folders only Select user-defined structure? ? Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! , ,\n ()! Do you really want to use a user-defined structure? , ? Too manu URLs, cannot handle so many links!! URL , ! Not enough memory, fatal internal error.. , ... Unknown operation! ! Add this URL?\r\n URL ?\r\n Warning: main process is still not responding, cannot add URL(s).. : . URL ... Type/MIME associations /MIME File types: : MIME identity: MIME : Select or modify your file type(s) here Select or modify your MIME type(s) here MIME Go up Go down File download information Freeze Window More information: : Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download WinHTTrack Website Copier!\n\n ''\n\n- \n\n- File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS :\n :\n :\n :\n :\n :\n :\n :\n :\n :\n Show all\nHide debug\nHide infos\nHide debug and infos \n debug\n \n debug Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. ( )\nHtml /, ./ /./\nHtml /html, ./ /.\nHtml /, ./ /\nHtml /, ./. /xxx, . \nHtml /html, ./ /xxx\n , www..xxx/\nHtml __/, ./ __/./\nHtml __/html, ./ __/.\nHtml __/, ./ __/\nHtml __/, ./ __/xxx\nHtml __/html, ./ __/\n /, (gadget !)\n __/, (gadget !)\n .. Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first \n html \n -html \n . ( )\n html Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down \n ( .)\n \n Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web ( .)\n \n (top level) \n Never\nIf unknown (except /)\nIf unknown \n ( /)\n no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules robots.txt \nrobots.txt \n robots.txt normal\nextended\ndebug \n\n Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download ()\n () + \n \n .( . )\n . ( )\n* \n* Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL . URI / . URL ( )\n URL / URL\n URI / URI\n URL / URL Open Source offline browser Offline Website Copier/Offline Browser. Copy remote websites to your computer. Free. /Offline . . . httrack, winhttrack, webhttrack, offline browser httrack, winhttrack, webhttrack, offline browser, offline URL list (.txt) URL (.txt) Previous Next URLs URL- Warning Your browser does not currently support javascript. For better results, please use a javascript-aware browser. JavaScript. - , JavaScript . Thank you You can now close this window Server terminated A fatal error has occurred during this mirror httrack-3.49.5/lang/Makefile.in0000644000175000017500000003742214555203173013200 00000000000000# Makefile.in generated by automake 1.16.5 from Makefile.am. # @configure_input@ # Copyright (C) 1994-2021 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ VPATH = @srcdir@ am__is_gnu_make = { \ if test -z '$(MAKELEVEL)'; then \ false; \ elif test -n '$(MAKE_HOST)'; then \ true; \ elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ true; \ else \ false; \ fi; \ } am__make_running_with_option = \ case $${target_option-} in \ ?) ;; \ *) echo "am__make_running_with_option: internal error: invalid" \ "target option '$${target_option-}' specified" >&2; \ exit 1;; \ esac; \ has_opt=no; \ sane_makeflags=$$MAKEFLAGS; \ if $(am__is_gnu_make); then \ sane_makeflags=$$MFLAGS; \ else \ case $$MAKEFLAGS in \ *\\[\ \ ]*) \ bs=\\; \ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ esac; \ fi; \ skip_next=no; \ strip_trailopt () \ { \ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ }; \ for flg in $$sane_makeflags; do \ test $$skip_next = yes && { skip_next=no; continue; }; \ case $$flg in \ *=*|--*) continue;; \ -*I) strip_trailopt 'I'; skip_next=yes;; \ -*I?*) strip_trailopt 'I';; \ -*O) strip_trailopt 'O'; skip_next=yes;; \ -*O?*) strip_trailopt 'O';; \ -*l) strip_trailopt 'l'; skip_next=yes;; \ -*l?*) strip_trailopt 'l';; \ -[dEDm]) skip_next=yes;; \ -[JT]) skip_next=yes;; \ esac; \ case $$flg in \ *$$target_option*) has_opt=yes; break;; \ esac; \ done; \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkglibexecdir = $(libexecdir)/@PACKAGE@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ subdir = lang ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/check_zlib.m4 \ $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/snprintf.m4 \ $(top_srcdir)/m4/visibility.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = AM_V_P = $(am__v_P_@AM_V@) am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) am__v_P_0 = false am__v_P_1 = : AM_V_GEN = $(am__v_GEN_@AM_V@) am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) am__v_GEN_0 = @echo " GEN " $@; am__v_GEN_1 = AM_V_at = $(am__v_at_@AM_V@) am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) am__v_at_0 = @ am__v_at_1 = SOURCES = DIST_SOURCES = am__can_run_installinfo = \ case $$AM_UPDATE_INFO_DIR in \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ *) f=$$p;; \ esac; am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; am__install_max = 40 am__nobase_strip_setup = \ srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` am__nobase_strip = \ for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" am__nobase_list = $(am__nobase_strip_setup); \ for p in $$list; do echo "$$p $$p"; done | \ sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ if (++n[$$2] == $(am__install_max)) \ { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ END { for (dir in files) print dir, files[dir] }' am__base_list = \ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' am__uninstall_files_from_dir = { \ test -z "$$files" \ || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ $(am__cd) "$$dir" && rm -f $$files; }; \ } am__installdirs = "$(DESTDIR)$(langdir)" "$(DESTDIR)$(langrootdir)" DATA = $(lang_DATA) $(langroot_DATA) am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) am__DIST_COMMON = $(srcdir)/Makefile.in DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AM_CFLAGS = @AM_CFLAGS@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CFLAGS_PIE = @CFLAGS_PIE@ CFLAG_VISIBILITY = @CFLAG_VISIBILITY@ CPPFLAGS = @CPPFLAGS@ CSCOPE = @CSCOPE@ CTAGS = @CTAGS@ CYGPATH_W = @CYGPATH_W@ DEFAULT_CFLAGS = @DEFAULT_CFLAGS@ DEFAULT_LDFLAGS = @DEFAULT_LDFLAGS@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DLLTOOL = @DLLTOOL@ DL_LIBS = @DL_LIBS@ DSYMUTIL = @DSYMUTIL@ DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ ETAGS = @ETAGS@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ FILECMD = @FILECMD@ GREP = @GREP@ HAVE_VISIBILITY = @HAVE_VISIBILITY@ HTTPS_SUPPORT = @HTTPS_SUPPORT@ ICONV_LIBS = @ICONV_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LD = @LD@ LDFLAGS = @LDFLAGS@ LDFLAGS_PIE = @LDFLAGS_PIE@ LFS_FLAG = @LFS_FLAG@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ LIPO = @LIPO@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ LT_CV_OBJDIR = @LT_CV_OBJDIR@ LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ MAINT = @MAINT@ MAKEINFO = @MAKEINFO@ MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ NM = @NM@ NMEDIT = @NMEDIT@ OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ ONLINE_UNIT_TESTS = @ONLINE_UNIT_TESTS@ OPENSSL_LIBS = @OPENSSL_LIBS@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ RANLIB = @RANLIB@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ SHLIBPATH_VAR = @SHLIBPATH_VAR@ SOCKET_LIBS = @SOCKET_LIBS@ STRIP = @STRIP@ THREADS_CFLAGS = @THREADS_CFLAGS@ THREADS_LIBS = @THREADS_LIBS@ V6_FLAG = @V6_FLAG@ VERSION = @VERSION@ VERSION_INFO = @VERSION_INFO@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ builddir = @builddir@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ runstatedir = @runstatedir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ langdir = $(datadir)/httrack/lang lang_DATA = *.txt langrootdir = $(datadir)/httrack langroot_DATA = ../lang.def ../lang.indexes EXTRA_DIST = $(lang_DATA) $(langroot_DATA) all: all-am .SUFFIXES: $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ && { if test -f $@; then exit 0; else break; fi; }; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu lang/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --gnu lang/Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(am__aclocal_m4_deps): mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs install-langDATA: $(lang_DATA) @$(NORMAL_INSTALL) @list='$(lang_DATA)'; test -n "$(langdir)" || list=; \ if test -n "$$list"; then \ echo " $(MKDIR_P) '$(DESTDIR)$(langdir)'"; \ $(MKDIR_P) "$(DESTDIR)$(langdir)" || exit 1; \ fi; \ for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; \ done | $(am__base_list) | \ while read files; do \ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(langdir)'"; \ $(INSTALL_DATA) $$files "$(DESTDIR)$(langdir)" || exit $$?; \ done uninstall-langDATA: @$(NORMAL_UNINSTALL) @list='$(lang_DATA)'; test -n "$(langdir)" || list=; \ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ dir='$(DESTDIR)$(langdir)'; $(am__uninstall_files_from_dir) install-langrootDATA: $(langroot_DATA) @$(NORMAL_INSTALL) @list='$(langroot_DATA)'; test -n "$(langrootdir)" || list=; \ if test -n "$$list"; then \ echo " $(MKDIR_P) '$(DESTDIR)$(langrootdir)'"; \ $(MKDIR_P) "$(DESTDIR)$(langrootdir)" || exit 1; \ fi; \ for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; \ done | $(am__base_list) | \ while read files; do \ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(langrootdir)'"; \ $(INSTALL_DATA) $$files "$(DESTDIR)$(langrootdir)" || exit $$?; \ done uninstall-langrootDATA: @$(NORMAL_UNINSTALL) @list='$(langroot_DATA)'; test -n "$(langrootdir)" || list=; \ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ dir='$(DESTDIR)$(langrootdir)'; $(am__uninstall_files_from_dir) tags TAGS: ctags CTAGS: cscope cscopelist: distdir: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) distdir-am distdir-am: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ dist_files=`for file in $$list; do echo $$file; done | \ sed -e "s|^$$srcdirstrip/||;t" \ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ case $$dist_files in \ */*) $(MKDIR_P) `echo "$$dist_files" | \ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ sort -u` ;; \ esac; \ for file in $$dist_files; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ if test -d $$d/$$file; then \ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ if test -d "$(distdir)/$$file"; then \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ else \ test -f "$(distdir)/$$file" \ || cp -p $$d/$$file "$(distdir)/$$file" \ || exit 1; \ fi; \ done check-am: all-am check: check-am all-am: Makefile $(DATA) installdirs: for dir in "$(DESTDIR)$(langdir)" "$(DESTDIR)$(langrootdir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-am install-strip: if test -z '$(STRIP)'; then \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ install; \ else \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ fi mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-generic clean-libtool mostlyclean-am distclean: distclean-am -rm -f Makefile distclean-am: clean-am distclean-generic dvi: dvi-am dvi-am: html: html-am html-am: info: info-am info-am: install-data-am: install-langDATA install-langrootDATA install-dvi: install-dvi-am install-dvi-am: install-exec-am: install-html: install-html-am install-html-am: install-info: install-info-am install-info-am: install-man: install-pdf: install-pdf-am install-pdf-am: install-ps: install-ps-am install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-am -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-generic mostlyclean-libtool pdf: pdf-am pdf-am: ps: ps-am ps-am: uninstall-am: uninstall-langDATA uninstall-langrootDATA .MAKE: install-am install-strip .PHONY: all all-am check check-am clean clean-generic clean-libtool \ cscopelist-am ctags-am distclean distclean-generic \ distclean-libtool distdir dvi dvi-am html html-am info info-am \ install install-am install-data install-data-am install-dvi \ install-dvi-am install-exec install-exec-am install-html \ install-html-am install-info install-info-am install-langDATA \ install-langrootDATA install-man install-pdf install-pdf-am \ install-ps install-ps-am install-strip installcheck \ installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-generic \ mostlyclean-libtool pdf pdf-am ps ps-am tags-am uninstall \ uninstall-am uninstall-langDATA uninstall-langrootDATA .PRECIOUS: Makefile #dist-hook: # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: httrack-3.49.5/lang/Makefile.am0000644000175000017500000000027314336470674013172 00000000000000 langdir = $(datadir)/httrack/lang lang_DATA = *.txt langrootdir = $(datadir)/httrack langroot_DATA = ../lang.def ../lang.indexes EXTRA_DIST = $(lang_DATA) $(langroot_DATA) #dist-hook: httrack-3.49.5/templates/0000755000175000017500000000000014555203177012264 500000000000000httrack-3.49.5/templates/topindex-bodycat.html0000644000175000017500000000004114336470674016347 00000000000000
%s httrack-3.49.5/templates/topindex-header.html0000644000175000017500000001005614336470674016161 00000000000000 List of available projects - HTTrack Website Copier %s
HTTrack Website Copier - Open Source offline browser

Index of locally available projects:

httrack-3.49.5/templates/topindex-body.html0000644000175000017500000000017414336470674015666 00000000000000 httrack-3.49.5/templates/index-footer.html0000644000175000017500000000114114336470674015477 00000000000000
· %s



Mirror and index made by HTTrack Website Copier [XR&CO'2008]
%s %s
httrack-3.49.5/templates/topindex-footer.html0000644000175000017500000000112014336470674016217 00000000000000
Mirror and index made by HTTrack Website Copier [XR&CO'2008]
%s
httrack-3.49.5/templates/index-header.html0000644000175000017500000001020714336470674015434 00000000000000 Local index - HTTrack Website Copier %s
HTTrack Website Copier - Open Source offline browser
Local index - HTTrack

Index of locally available sites:

httrack-3.49.5/templates/index-body.html0000644000175000017500000000016314336470674015141 00000000000000 httrack-3.49.5/templates/Makefile.in0000644000175000017500000003576114555203173014261 00000000000000# Makefile.in generated by automake 1.16.5 from Makefile.am. # @configure_input@ # Copyright (C) 1994-2021 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ VPATH = @srcdir@ am__is_gnu_make = { \ if test -z '$(MAKELEVEL)'; then \ false; \ elif test -n '$(MAKE_HOST)'; then \ true; \ elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ true; \ else \ false; \ fi; \ } am__make_running_with_option = \ case $${target_option-} in \ ?) ;; \ *) echo "am__make_running_with_option: internal error: invalid" \ "target option '$${target_option-}' specified" >&2; \ exit 1;; \ esac; \ has_opt=no; \ sane_makeflags=$$MAKEFLAGS; \ if $(am__is_gnu_make); then \ sane_makeflags=$$MFLAGS; \ else \ case $$MAKEFLAGS in \ *\\[\ \ ]*) \ bs=\\; \ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ esac; \ fi; \ skip_next=no; \ strip_trailopt () \ { \ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ }; \ for flg in $$sane_makeflags; do \ test $$skip_next = yes && { skip_next=no; continue; }; \ case $$flg in \ *=*|--*) continue;; \ -*I) strip_trailopt 'I'; skip_next=yes;; \ -*I?*) strip_trailopt 'I';; \ -*O) strip_trailopt 'O'; skip_next=yes;; \ -*O?*) strip_trailopt 'O';; \ -*l) strip_trailopt 'l'; skip_next=yes;; \ -*l?*) strip_trailopt 'l';; \ -[dEDm]) skip_next=yes;; \ -[JT]) skip_next=yes;; \ esac; \ case $$flg in \ *$$target_option*) has_opt=yes; break;; \ esac; \ done; \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkglibexecdir = $(libexecdir)/@PACKAGE@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ subdir = templates ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/check_zlib.m4 \ $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/snprintf.m4 \ $(top_srcdir)/m4/visibility.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = AM_V_P = $(am__v_P_@AM_V@) am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) am__v_P_0 = false am__v_P_1 = : AM_V_GEN = $(am__v_GEN_@AM_V@) am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) am__v_GEN_0 = @echo " GEN " $@; am__v_GEN_1 = AM_V_at = $(am__v_at_@AM_V@) am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) am__v_at_0 = @ am__v_at_1 = SOURCES = DIST_SOURCES = am__can_run_installinfo = \ case $$AM_UPDATE_INFO_DIR in \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ *) f=$$p;; \ esac; am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; am__install_max = 40 am__nobase_strip_setup = \ srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` am__nobase_strip = \ for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" am__nobase_list = $(am__nobase_strip_setup); \ for p in $$list; do echo "$$p $$p"; done | \ sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ if (++n[$$2] == $(am__install_max)) \ { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ END { for (dir in files) print dir, files[dir] }' am__base_list = \ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' am__uninstall_files_from_dir = { \ test -z "$$files" \ || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ $(am__cd) "$$dir" && rm -f $$files; }; \ } am__installdirs = "$(DESTDIR)$(templatesdir)" DATA = $(templates_DATA) am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) am__DIST_COMMON = $(srcdir)/Makefile.in DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AM_CFLAGS = @AM_CFLAGS@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CFLAGS_PIE = @CFLAGS_PIE@ CFLAG_VISIBILITY = @CFLAG_VISIBILITY@ CPPFLAGS = @CPPFLAGS@ CSCOPE = @CSCOPE@ CTAGS = @CTAGS@ CYGPATH_W = @CYGPATH_W@ DEFAULT_CFLAGS = @DEFAULT_CFLAGS@ DEFAULT_LDFLAGS = @DEFAULT_LDFLAGS@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DLLTOOL = @DLLTOOL@ DL_LIBS = @DL_LIBS@ DSYMUTIL = @DSYMUTIL@ DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ ETAGS = @ETAGS@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ FILECMD = @FILECMD@ GREP = @GREP@ HAVE_VISIBILITY = @HAVE_VISIBILITY@ HTTPS_SUPPORT = @HTTPS_SUPPORT@ ICONV_LIBS = @ICONV_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LD = @LD@ LDFLAGS = @LDFLAGS@ LDFLAGS_PIE = @LDFLAGS_PIE@ LFS_FLAG = @LFS_FLAG@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ LIPO = @LIPO@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ LT_CV_OBJDIR = @LT_CV_OBJDIR@ LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ MAINT = @MAINT@ MAKEINFO = @MAKEINFO@ MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ NM = @NM@ NMEDIT = @NMEDIT@ OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ ONLINE_UNIT_TESTS = @ONLINE_UNIT_TESTS@ OPENSSL_LIBS = @OPENSSL_LIBS@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ RANLIB = @RANLIB@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ SHLIBPATH_VAR = @SHLIBPATH_VAR@ SOCKET_LIBS = @SOCKET_LIBS@ STRIP = @STRIP@ THREADS_CFLAGS = @THREADS_CFLAGS@ THREADS_LIBS = @THREADS_LIBS@ V6_FLAG = @V6_FLAG@ VERSION = @VERSION@ VERSION_INFO = @VERSION_INFO@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ builddir = @builddir@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ runstatedir = @runstatedir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ templatesdir = $(datadir)/httrack/templates templates_DATA = index-body.html index-header.html topindex-footer.html \ index-footer.html topindex-body.html topindex-header.html \ topindex-bodycat.html EXTRA_DIST = $(templates_DATA) all: all-am .SUFFIXES: $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ && { if test -f $@; then exit 0; else break; fi; }; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu templates/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --gnu templates/Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(am__aclocal_m4_deps): mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs install-templatesDATA: $(templates_DATA) @$(NORMAL_INSTALL) @list='$(templates_DATA)'; test -n "$(templatesdir)" || list=; \ if test -n "$$list"; then \ echo " $(MKDIR_P) '$(DESTDIR)$(templatesdir)'"; \ $(MKDIR_P) "$(DESTDIR)$(templatesdir)" || exit 1; \ fi; \ for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; \ done | $(am__base_list) | \ while read files; do \ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(templatesdir)'"; \ $(INSTALL_DATA) $$files "$(DESTDIR)$(templatesdir)" || exit $$?; \ done uninstall-templatesDATA: @$(NORMAL_UNINSTALL) @list='$(templates_DATA)'; test -n "$(templatesdir)" || list=; \ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ dir='$(DESTDIR)$(templatesdir)'; $(am__uninstall_files_from_dir) tags TAGS: ctags CTAGS: cscope cscopelist: distdir: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) distdir-am distdir-am: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ dist_files=`for file in $$list; do echo $$file; done | \ sed -e "s|^$$srcdirstrip/||;t" \ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ case $$dist_files in \ */*) $(MKDIR_P) `echo "$$dist_files" | \ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ sort -u` ;; \ esac; \ for file in $$dist_files; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ if test -d $$d/$$file; then \ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ if test -d "$(distdir)/$$file"; then \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ else \ test -f "$(distdir)/$$file" \ || cp -p $$d/$$file "$(distdir)/$$file" \ || exit 1; \ fi; \ done check-am: all-am check: check-am all-am: Makefile $(DATA) installdirs: for dir in "$(DESTDIR)$(templatesdir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-am install-strip: if test -z '$(STRIP)'; then \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ install; \ else \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ fi mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-generic clean-libtool mostlyclean-am distclean: distclean-am -rm -f Makefile distclean-am: clean-am distclean-generic dvi: dvi-am dvi-am: html: html-am html-am: info: info-am info-am: install-data-am: install-templatesDATA install-dvi: install-dvi-am install-dvi-am: install-exec-am: install-html: install-html-am install-html-am: install-info: install-info-am install-info-am: install-man: install-pdf: install-pdf-am install-pdf-am: install-ps: install-ps-am install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-am -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-generic mostlyclean-libtool pdf: pdf-am pdf-am: ps: ps-am ps-am: uninstall-am: uninstall-templatesDATA .MAKE: install-am install-strip .PHONY: all all-am check check-am clean clean-generic clean-libtool \ cscopelist-am ctags-am distclean distclean-generic \ distclean-libtool distdir dvi dvi-am html html-am info info-am \ install install-am install-data install-data-am install-dvi \ install-dvi-am install-exec install-exec-am install-html \ install-html-am install-info install-info-am install-man \ install-pdf install-pdf-am install-ps install-ps-am \ install-strip install-templatesDATA installcheck \ installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-generic \ mostlyclean-libtool pdf pdf-am ps ps-am tags-am uninstall \ uninstall-am uninstall-templatesDATA .PRECIOUS: Makefile # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: httrack-3.49.5/templates/Makefile.am0000644000175000017500000000035314336470674014246 00000000000000 templatesdir = $(datadir)/httrack/templates templates_DATA = index-body.html index-header.html topindex-footer.html \ index-footer.html topindex-body.html topindex-header.html \ topindex-bodycat.html EXTRA_DIST = $(templates_DATA) httrack-3.49.5/libtest/0000755000175000017500000000000014555203177011734 500000000000000httrack-3.49.5/libtest/libtest.vcproj0000644000175000017500000001031014336470674014547 00000000000000 httrack-3.49.5/libtest/libtest.mak0000644000175000017500000000335314336470674014025 00000000000000# Makefile OBJDIR = ./Release/ PATH = $(DEVSTU)\vc\bin;$(DEVSTU)\sharedide\bin;$(PATH) INCLUDES = /I "." /I ".." /I "../src" /I "$(DEVSTU)\vc\include" /I"../../openssl-1.0.1j\include\openssl" LIB_FLAGS = /link /LIBPATH:"L:\HTTrack\httrack\src_win\libhttrack" /LIBPATH:"L:\HTTrack\httrack\libhttrack" COMMON_FLAGS = /W3 /O2 /Fo"$(OBJDIR)" /Fd"$(OBJDIR)" /Fa"$(OBJDIR)" $(INCLUDES) CPP_FLAGS = /LD $(COMMON_FLAGS) libhttrack.lib BIN_FLAGS = /link /LIBPATH:"C:\temp\Debuglib" all: cl $(CPP_FLAGS) \ callbacks-example-simple.c -Fe$(OBJDIR)callbacks-example-simple.dll \ $(LIB_FLAGS) cl $(CPP_FLAGS) \ callbacks-example-log.c -Fe$(OBJDIR)callbacks-example-log.dll \ $(LIB_FLAGS) cl $(CPP_FLAGS) \ callbacks-example-baselinks.c -Fe$(OBJDIR)callbacks-example-baselinks.dll \ $(LIB_FLAGS) cl $(CPP_FLAGS) \ callbacks-example-contentfilter.c -Fe$(OBJDIR)callbacks-example-contentfilter.dll \ $(LIB_FLAGS) cl $(CPP_FLAGS) \ callbacks-example-displayheader.c -Fe$(OBJDIR)callbacks-example-displayheader.dll \ $(LIB_FLAGS) cl $(CPP_FLAGS) \ callbacks-example-filename.c -Fe$(OBJDIR)callbacks-example-filename.dll \ $(LIB_FLAGS) cl $(CPP_FLAGS) \ callbacks-example-filename2.c -Fe$(OBJDIR)callbacks-example-filename2.dll \ $(LIB_FLAGS) cl $(CPP_FLAGS) \ callbacks-example-filenameiisbug.c -Fe$(OBJDIR)callbacks-example-filenameiisbug.dll \ $(LIB_FLAGS) cl $(CPP_FLAGS) \ callbacks-example-changecontent.c -Fe$(OBJDIR)callbacks-example-changecontent.dll \ $(LIB_FLAGS) cl $(CPP_FLAGS) \ callbacks-example-listlinks.c -Fe$(OBJDIR)callbacks-example-listlinks.dll \ $(LIB_FLAGS) cl $(COMMON_FLAGS) \ example.c wsock32.lib libhttrack.lib -Fe$(OBJDIR)example.exe \ $(BIN_FLAGS) httrack-3.49.5/libtest/readme.txt0000644000175000017500000000417214336470674013663 00000000000000HTTrack library example ----------------------- Here is an example of how to integrate HTTrack Website Copier into a project to use it as a "core library". Important Notice: ---------------- These sources are covered by the GNU General Public License (see below) (Projects based on these sources must follow the GPL, too) Copyright notice: ---------------- HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) Xavier Roche and other contributors This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ======================================================================== MAKEFILE PROJECT : libtest Project Overview ======================================================================== AppWizard has created this libtest project for you. This file contains a summary of what you will find in each of the files that make up your libtest project. libtest.vcproj This is the main project file for VC++ projects generated using an Application Wizard. It contains information about the version of Visual C++ that generated the file, and information about the platforms, configurations, and project features selected with the Application Wizard. This project allows you to build/clean/rebuild from within Visual Studio by calling the commands you have input in the wizard. The build command can be nmake or any other tool you use. This project does not contain any files, so there are none displayed in Solution Explorer. ///////////////////////////////////////////////////////////////////////////// httrack-3.49.5/libtest/example-main.h0000644000175000017500000001244214336470674014412 00000000000000/* HTTrack library example .h file */ #ifdef __WIN32 #define CDECL __cdecl #else #define CDECL #endif static void CDECL httrack_wrapper_init(t_hts_callbackarg * carg); static void CDECL httrack_wrapper_uninit(t_hts_callbackarg * carg); static int CDECL httrack_wrapper_start(t_hts_callbackarg * carg, httrackp * opt); static int CDECL httrack_wrapper_chopt(t_hts_callbackarg * carg, httrackp * opt); static int CDECL httrack_wrapper_end(t_hts_callbackarg * carg, httrackp * opt); static int CDECL httrack_wrapper_checkhtml(t_hts_callbackarg * carg, httrackp * opt, char *html, int len, const char *url_address, const char *url_file); static int CDECL httrack_wrapper_loop(t_hts_callbackarg * carg, httrackp * opt, void *_back, int back_max, int back_index, int lien_n, int lien_tot, int stat_time, hts_stat_struct * stats); static const char *CDECL httrack_wrapper_query(t_hts_callbackarg * carg, httrackp * opt, const char *question); static const char *CDECL httrack_wrapper_query2(t_hts_callbackarg * carg, httrackp * opt, const char *question); static const char *CDECL httrack_wrapper_query3(t_hts_callbackarg * carg, httrackp * opt, const char *question); static int CDECL httrack_wrapper_check(t_hts_callbackarg * carg, httrackp * opt, const char *adr, const char *fil, int status); static void CDECL httrack_wrapper_pause(t_hts_callbackarg * carg, httrackp * opt, const char *lockfile); static void CDECL httrack_wrapper_filesave(t_hts_callbackarg * carg, httrackp * opt, const char *file); static int CDECL httrack_wrapper_linkdetected(t_hts_callbackarg * carg, httrackp * opt, char *link); static int CDECL httrack_wrapper_xfrstatus(t_hts_callbackarg * carg, httrackp * opt, void *back); static int CDECL httrack_wrapper_preprocesshtml(t_hts_callbackarg * carg, httrackp * opt, char **html, int *len, const char *url_address, const char *url_file); static int CDECL httrack_wrapper_postprocesshtml(t_hts_callbackarg * carg, httrackp * opt, char **html, int *len, const char *url_address, const char *url_file); static int CDECL httrack_wrapper_check_mime(t_hts_callbackarg * carg, httrackp * opt, const char *adr, const char *fil, const char *mime, int status); static void CDECL httrack_wrapper_filesave2(t_hts_callbackarg * carg, httrackp * opt, const char *adr, const char *fil, const char *save, int is_new, int is_modified, int not_updated); static int CDECL httrack_wrapper_linkdetected2(t_hts_callbackarg * carg, httrackp * opt, char *link, const char *start_tag); static int CDECL httrack_wrapper_savename(t_hts_callbackarg * carg, httrackp * opt, const char *adr_complete, const char *fil_complete, const char *referer_adr, const char *referer_fil, char *save); static int CDECL httrack_wrapper_sendheader(t_hts_callbackarg * carg, httrackp * opt, char *buff, const char *adr, const char *fil, const char *referer_adr, const char *referer_fil, htsblk * outgoing); static int CDECL httrack_wrapper_receiveheader(t_hts_callbackarg * carg, httrackp * opt, char *buff, const char *adr, const char *fil, const char *referer_adr, const char *referer_fil, htsblk * incoming); httrack-3.49.5/libtest/example-main.c0000644000175000017500000002325614336470674014412 00000000000000/* HTTrack library example .c file Prerequisites: - install winhttrack - set the proper path in the project settings (especially for the httrack lib and dll) How to build: (callback.so or callback.dll) With GNU-GCC: gcc -I/usr/include/httrack -O -g3 -Wall -D_REENTRANT -o example example.c -lhttrack2 With MS-Visual C++: cl -nologo -W3 -Zi -Zp4 -DWIN32 -Fe"mycallback.exe" callbacks-example.c wsock32.lib libhttrack.lib */ #include #include #include #ifdef _WIN32 #include #endif /* Standard httrack module includes */ #include "httrack-library.h" #include "htsopt.h" #include "htsdefines.h" /* Local definitions */ #include "example-main.h" /* * Name: main * Description: main() function * Parameters: None * Should return: error status */ int main(void) { /* First, ask for an URL Note: For the test, option r2 (mirror max depth=1) and --testscan (no index, no cache, do not store, no log files) */ char _argv[][256] = { "httrack_test", "", "-r3", "--testscan", "" }; char *argv[] = { NULL, NULL, NULL, NULL, NULL }; int argc = 0; httrackp *opt; int ret; while(strlen(_argv[argc])) { argv[argc] = _argv[argc]; argc++; } argv[argc] = NULL; printf("HTTrackLib test program\n"); printf("Enter URL (example: www.foobar.com/index.html) :"); scanf("%s", argv[1]); printf("Test: 1 depth\n"); /* Initialize the library */ #ifdef _WIN32 { WORD wVersionRequested; // requested version WinSock API WSADATA wsadata; // Windows Sockets API data int stat; wVersionRequested = 0x0101; stat = WSAStartup(wVersionRequested, &wsadata); if (stat != 0) { printf("Winsock not found!\n"); return; } else if (LOBYTE(wsadata.wVersion) != 1 && HIBYTE(wsadata.wVersion) != 1) { printf("WINSOCK.DLL does not support version 1.1\n"); WSACleanup(); return; } } #endif hts_init(); /* Create option settings and set callbacks (wrappers) */ opt = hts_create_opt(); CHAIN_FUNCTION(opt, init, httrack_wrapper_init, NULL); CHAIN_FUNCTION(opt, uninit, httrack_wrapper_uninit, NULL); CHAIN_FUNCTION(opt, start, httrack_wrapper_start, NULL); CHAIN_FUNCTION(opt, end, httrack_wrapper_end, NULL); CHAIN_FUNCTION(opt, chopt, httrack_wrapper_chopt, NULL); CHAIN_FUNCTION(opt, preprocess, httrack_wrapper_preprocesshtml, NULL); CHAIN_FUNCTION(opt, postprocess, httrack_wrapper_postprocesshtml, NULL); CHAIN_FUNCTION(opt, check_html, httrack_wrapper_checkhtml, NULL); CHAIN_FUNCTION(opt, query, httrack_wrapper_query, NULL); CHAIN_FUNCTION(opt, query2, httrack_wrapper_query2, NULL); CHAIN_FUNCTION(opt, query3, httrack_wrapper_query3, NULL); CHAIN_FUNCTION(opt, loop, httrack_wrapper_loop, NULL); CHAIN_FUNCTION(opt, check_link, httrack_wrapper_check, NULL); CHAIN_FUNCTION(opt, check_mime, httrack_wrapper_check_mime, NULL); CHAIN_FUNCTION(opt, pause, httrack_wrapper_pause, NULL); CHAIN_FUNCTION(opt, filesave, httrack_wrapper_filesave, NULL); CHAIN_FUNCTION(opt, filesave2, httrack_wrapper_filesave2, NULL); CHAIN_FUNCTION(opt, linkdetected, httrack_wrapper_linkdetected, NULL); CHAIN_FUNCTION(opt, linkdetected2, httrack_wrapper_linkdetected2, NULL); CHAIN_FUNCTION(opt, xfrstatus, httrack_wrapper_xfrstatus, NULL); CHAIN_FUNCTION(opt, savename, httrack_wrapper_savename, NULL); CHAIN_FUNCTION(opt, sendhead, httrack_wrapper_sendheader, NULL); CHAIN_FUNCTION(opt, receivehead, httrack_wrapper_receiveheader, NULL); /* Then, launch the mirror */ ret = hts_main2(argc, argv, opt); /* Wait for a key */ printf("\nPress ENTER key to exit\n"); scanf("%s", argv[1]); /* Clear option state */ hts_free_opt(opt); hts_uninit(); #ifdef _WIN32 WSACleanup(); #endif /* That's all! */ return 0; } /* CALLBACK FUNCTIONS */ /* Initialize the Winsock */ static void CDECL httrack_wrapper_init(t_hts_callbackarg * carg) { printf("Engine started\n"); } static void CDECL httrack_wrapper_uninit(t_hts_callbackarg * carg) { printf("Engine exited\n"); } static int CDECL httrack_wrapper_start(t_hts_callbackarg * carg, httrackp * opt) { printf("Start of mirror\n"); return 1; } static int CDECL httrack_wrapper_chopt(t_hts_callbackarg * carg, httrackp * opt) { return 1; } static int CDECL httrack_wrapper_end(t_hts_callbackarg * carg, httrackp * opt) { printf("End of mirror\n"); return 1; } static int CDECL httrack_wrapper_checkhtml(t_hts_callbackarg * carg, httrackp * opt, char *html, int len, const char *url_address, const char *url_file) { printf("Parsing html file: http://%s%s\n", url_address, url_file); return 1; } static int CDECL httrack_wrapper_loop(t_hts_callbackarg * carg, httrackp * opt, void *_back, int back_max, int back_index, int lien_n, int lien_tot, int stat_time, hts_stat_struct * stats) { /* printf("..httrack_wrapper_loop called\n"); */ return 1; } static const char *CDECL httrack_wrapper_query(t_hts_callbackarg * carg, httrackp * opt, const char *question) { /* Answer is No */ return "N"; } static const char *CDECL httrack_wrapper_query2(t_hts_callbackarg * carg, httrackp * opt, const char *question) { /* Answer is No */ return "N"; } static const char *CDECL httrack_wrapper_query3(t_hts_callbackarg * carg, httrackp * opt, const char *question) { /* Answer is "" */ return ""; } static int CDECL httrack_wrapper_check(t_hts_callbackarg * carg, httrackp * opt, const char *adr, const char *fil, int status) { printf("Link status tested: http://%s%s\n", adr, fil); return -1; } static void CDECL httrack_wrapper_pause(t_hts_callbackarg * carg, httrackp * opt, const char *lockfile) { /* Wait until lockfile is removed.. */ } static void CDECL httrack_wrapper_filesave(t_hts_callbackarg * carg, httrackp * opt, const char *file) { } static int CDECL httrack_wrapper_linkdetected(t_hts_callbackarg * carg, httrackp * opt, char *link) { printf("Link detected: %s\n", link); return 1; } static int CDECL httrack_wrapper_xfrstatus(t_hts_callbackarg * carg, httrackp * opt, void *back) { return 1; } static int CDECL httrack_wrapper_preprocesshtml(t_hts_callbackarg * carg, httrackp * opt, char **html, int *len, const char *url_address, const char *url_file) { return 1; } static int CDECL httrack_wrapper_postprocesshtml(t_hts_callbackarg * carg, httrackp * opt, char **html, int *len, const char *url_address, const char *url_file) { return 1; } static int CDECL httrack_wrapper_check_mime(t_hts_callbackarg * carg, httrackp * opt, const char *adr, const char *fil, const char *mime, int status) { return -1; } static void CDECL httrack_wrapper_filesave2(t_hts_callbackarg * carg, httrackp * opt, const char *adr, const char *fil, const char *save, int is_new, int is_modified, int not_updated) { } static int CDECL httrack_wrapper_linkdetected2(t_hts_callbackarg * carg, httrackp * opt, char *link, const char *start_tag) { return 1; } static int CDECL httrack_wrapper_savename(t_hts_callbackarg * carg, httrackp * opt, const char *adr_complete, const char *fil_complete, const char *referer_adr, const char *referer_fil, char *save) { return 1; } static int CDECL httrack_wrapper_sendheader(t_hts_callbackarg * carg, httrackp * opt, char *buff, const char *adr, const char *fil, const char *referer_adr, const char *referer_fil, htsblk * outgoing) { return 1; } static int CDECL httrack_wrapper_receiveheader(t_hts_callbackarg * carg, httrackp * opt, char *buff, const char *adr, const char *fil, const char *referer_adr, const char *referer_fil, htsblk * incoming) { return 1; } httrack-3.49.5/libtest/callbacks-example-simple.c0000644000175000017500000000670514336470674016674 00000000000000/* HTTrack external callbacks example : print all downloaded html documents How to build: (callback.so or callback.dll) With GNU-GCC: gcc -O -g3 -Wall -D_REENTRANT -shared -o mycallback.so callbacks-example.c -lhttrack2 With MS-Visual C++: cl -LD -nologo -W3 -Zi -Zp4 -DWIN32 -Fe"mycallback.dll" callbacks-example.c libhttrack.lib Note: the httrack library linker option is only necessary when using libhttrack's functions inside the callback How to use: httrack --wrapper mycallback .. */ /* system includes */ #include #include #include /* standard httrack module includes */ #include "httrack-library.h" #include "htsopt.h" #include "htsdefines.h" /* external functions */ EXTERNAL_FUNCTION int hts_plug(httrackp * opt, const char *argv); EXTERNAL_FUNCTION int hts_unplug(httrackp * opt); /* local function called as "check_html" callback */ static int process_file(t_hts_callbackarg /*the carg structure, holding various information */ * carg, /*the option settings */ httrackp * opt, /*other parameters are callback-specific */ char *html, int len, const char *url_address, const char *url_file) { void *ourDummyArg = (void *) CALLBACKARG_USERDEF(carg); /*optional user-defined arg */ (void) ourDummyArg; /* call parent functions if multiple callbacks are chained. you can skip this part, if you don't want previous callbacks to be called. */ if (CALLBACKARG_PREV_FUN(carg, check_html) != NULL) { if (!CALLBACKARG_PREV_FUN(carg, check_html) (CALLBACKARG_PREV_CARG(carg), opt, html, len, url_address, url_file)) { return 0; /* abort */ } } printf("file %s%s content: %s\n", url_address, url_file, html); return 1; /* success */ } /* local function called as "end" callback */ static int end_of_mirror(t_hts_callbackarg /*the carg structure, holding various information */ * carg, /*the option settings */ httrackp * opt) { void *ourDummyArg = (void *) CALLBACKARG_USERDEF(carg); /*optional user-defined arg */ (void) ourDummyArg; /* processing */ fprintf(stderr, "That's all, folks!\n"); /* call parent functions if multiple callbacks are chained. you can skip this part, if you don't want previous callbacks to be called. */ if (CALLBACKARG_PREV_FUN(carg, end) != NULL) { /* status is ok on our side, return other callabck's status */ return CALLBACKARG_PREV_FUN(carg, end) (CALLBACKARG_PREV_CARG(carg), opt); } return 1; /* success */ } /* module entry point the function name and prototype MUST match this prototype */ EXTERNAL_FUNCTION int hts_plug(httrackp * opt, const char *argv) { /* optional argument passed in the commandline we won't be using here */ const char *arg = strchr(argv, ','); if (arg != NULL) arg++; /* plug callback functions */ CHAIN_FUNCTION(opt, check_html, process_file, /*optional user-defined arg */ NULL); CHAIN_FUNCTION(opt, end, end_of_mirror, /*optional user-defined arg */ NULL); return 1; /* success */ } /* module exit point the function name and prototype MUST match this prototype */ EXTERNAL_FUNCTION int hts_unplug(httrackp * opt) { fprintf(stderr, "Module unplugged"); return 1; /* success */ } httrack-3.49.5/libtest/callbacks-example-log.c0000644000175000017500000001010014336470674016144 00000000000000/* HTTrack external callbacks example : dumy plugin, aimed to log for debugging purpose How to build: (callback.so or callback.dll) With GNU-GCC: gcc -O -g3 -Wall -D_REENTRANT -shared -o mycallback.so callbacks-example.c -lhttrack2 With MS-Visual C++: cl -LD -nologo -W3 -Zi -Zp4 -DWIN32 -Fe"mycallback.dll" callbacks-example.c libhttrack.lib Note: the httrack library linker option is only necessary when using libhttrack's functions inside the callback How to use: httrack --wrapper mycallback .. */ /* system includes */ #include #include #include /* standard httrack module includes */ #include "httrack-library.h" #include "htsopt.h" #include "htsdefines.h" /* external functions */ EXTERNAL_FUNCTION int hts_plug(httrackp * opt, const char *argv); EXTERNAL_FUNCTION int hts_unplug(httrackp * opt); /* local function called as "check_html" callback */ static int process_file(t_hts_callbackarg * carg, httrackp * opt, char *html, int len, const char *url_address, const char *url_file) { void *ourDummyArg = (void *) CALLBACKARG_USERDEF(carg); /*optional user-defined arg */ char *fmt; (void) ourDummyArg; /* call parent functions if multiple callbacks are chained. you can skip this part, if you don't want previous callbacks to be called. */ if (CALLBACKARG_PREV_FUN(carg, check_html) != NULL) { if (!CALLBACKARG_PREV_FUN(carg, check_html) (CALLBACKARG_PREV_CARG(carg), opt, html, len, url_address, url_file)) { return 0; /* abort */ } } /* log */ fprintf(stderr, "* parsing file %s%s\n", url_address, url_file); fmt = malloc(strlen(url_address) + strlen(url_file) + 128); sprintf(fmt, " parsing file %s%s", url_address, url_file); hts_log(opt, "log-wrapper-info", fmt); free(fmt); return 1; /* success */ } static int start_of_mirror(t_hts_callbackarg * carg, httrackp * opt) { const char *arginfo = (char *) CALLBACKARG_USERDEF(carg); fprintf(stderr, "* mirror start\n"); hts_log(opt, arginfo, "mirror started"); /* call parent functions if multiple callbacks are chained. you can skip this part, if you don't want previous callbacks to be called. */ if (CALLBACKARG_PREV_FUN(carg, end) != NULL) { /* status is ok on our side, return other callabck's status */ return CALLBACKARG_PREV_FUN(carg, start) (CALLBACKARG_PREV_CARG(carg), opt); } return 1; /* success */ } /* local function called as "end" callback */ static int end_of_mirror(t_hts_callbackarg * carg, httrackp * opt) { const char *arginfo = (char *) CALLBACKARG_USERDEF(carg); fprintf(stderr, "* mirror end\n"); hts_log(opt, arginfo, "mirror ended"); /* call parent functions if multiple callbacks are chained. you can skip this part, if you don't want previous callbacks to be called. */ if (CALLBACKARG_PREV_FUN(carg, end) != NULL) { /* status is ok on our side, return other callabck's status */ return CALLBACKARG_PREV_FUN(carg, end) (CALLBACKARG_PREV_CARG(carg), opt); } return 1; /* success */ } /* module entry point the function name and prototype MUST match this prototype */ EXTERNAL_FUNCTION int hts_plug(httrackp * opt, const char *argv) { /* optional argument passed in the commandline we won't be using here */ const char *arg = strchr(argv, ','); if (arg != NULL) arg++; /* plug callback functions */ if (arg == NULL) arg = "log-wrapper-info"; hts_log(opt, arg, "* plugging functions"); CHAIN_FUNCTION(opt, check_html, process_file, (void *) (uintptr_t) arg); CHAIN_FUNCTION(opt, start, start_of_mirror, (void *) (uintptr_t) arg); CHAIN_FUNCTION(opt, end, end_of_mirror, (void *) (uintptr_t) arg); hts_log(opt, arg, "* module successfully plugged"); return 1; /* success */ } /* module exit point the function name and prototype MUST match this prototype */ EXTERNAL_FUNCTION int hts_unplug(httrackp * opt) { hts_log(opt, "log-wrapper-info", "* module successfully unplugged"); return 1; } httrack-3.49.5/libtest/callbacks-example-listlinks.c0000644000175000017500000001153514336470674017414 00000000000000/* HTTrack external callbacks example .c file How to build: (callback.so or callback.dll) With GNU-GCC: gcc -O -g3 -Wall -D_REENTRANT -shared -o mycallback.so callbacks-example.c -lhttrack2 With MS-Visual C++: cl -LD -nologo -W3 -Zi -Zp4 -DWIN32 -Fe"mycallback.dll" callbacks-example.c libhttrack.lib Note: the httrack library linker option is only necessary when using libhttrack's functions inside the callback How to use: httrack --wrapper mycallback .. */ #include #include #include /* Standard httrack module includes */ #include "httrack-library.h" #include "htsopt.h" #include "htsdefines.h" /* Function definitions */ static int process_file(t_hts_callbackarg * carg, httrackp * opt, char *html, int len, const char *url_address, const char *url_file); static int check_detectedlink(t_hts_callbackarg * carg, httrackp * opt, char *link); static int check_loop(t_hts_callbackarg * carg, httrackp * opt, lien_back *back, int back_max, int back_index, int lien_tot, int lien_ntot, int stat_time, hts_stat_struct * stats); static int end(t_hts_callbackarg * carg, httrackp * opt); /* external functions */ EXTERNAL_FUNCTION int hts_plug(httrackp * opt, const char *argv); /* This sample just lists all links in documents with the parent link: -> This sample can be improved, for example, to make a map of a website. */ typedef struct t_my_userdef { char currentURLBeingParsed[2048]; } t_my_userdef; /* module entry point */ EXTERNAL_FUNCTION int hts_plug(httrackp * opt, const char *argv) { t_my_userdef *userdef; /* */ const char *arg = strchr(argv, ','); if (arg != NULL) arg++; /* Create user-defined structure */ userdef = (t_my_userdef *) malloc(sizeof(t_my_userdef)); /* userdef */ userdef->currentURLBeingParsed[0] = '\0'; /* Plug callback functions */ CHAIN_FUNCTION(opt, check_html, process_file, userdef); CHAIN_FUNCTION(opt, end, end, userdef); CHAIN_FUNCTION(opt, linkdetected, check_detectedlink, userdef); CHAIN_FUNCTION(opt, loop, check_loop, userdef); return 1; /* success */ } static int process_file(t_hts_callbackarg * carg, httrackp * opt, char *html, int len, const char *url_address, const char *url_file) { t_my_userdef *userdef = (t_my_userdef *) CALLBACKARG_USERDEF(carg); char *const currentURLBeingParsed = userdef->currentURLBeingParsed; /* Call parent functions if multiple callbacks are chained. */ if (CALLBACKARG_PREV_FUN(carg, check_html) != NULL) { if (!CALLBACKARG_PREV_FUN(carg, check_html) (CALLBACKARG_PREV_CARG(carg), opt, html, len, url_address, url_file)) { return 0; /* Abort */ } } /* Process */ printf("now parsing %s%s..\n", url_address, url_file); strcpy(currentURLBeingParsed, url_address); strcat(currentURLBeingParsed, url_file); return 1; /* success */ } static int check_detectedlink(t_hts_callbackarg * carg, httrackp * opt, char *link) { t_my_userdef *userdef = (t_my_userdef *) CALLBACKARG_USERDEF(carg); char *const currentURLBeingParsed = userdef->currentURLBeingParsed; /* Call parent functions if multiple callbacks are chained. */ if (CALLBACKARG_PREV_FUN(carg, linkdetected) != NULL) { if (!CALLBACKARG_PREV_FUN(carg, linkdetected) (CALLBACKARG_PREV_CARG(carg), opt, link)) { return 0; /* Abort */ } } /* Process */ printf("[%s] -> [%s]\n", currentURLBeingParsed, link); return 1; /* success */ } static int check_loop(t_hts_callbackarg * carg, httrackp * opt, lien_back *back, int back_max, int back_index, int lien_tot, int lien_ntot, int stat_time, hts_stat_struct * stats) { static int fun_animation = 0; /* Call parent functions if multiple callbacks are chained. */ if (CALLBACKARG_PREV_FUN(carg, loop) != NULL) { if (!CALLBACKARG_PREV_FUN(carg, loop) (CALLBACKARG_PREV_CARG(carg), opt, back, back_max, back_index, lien_tot, lien_ntot, stat_time, stats)) { return 0; /* Abort */ } } /* Process */ printf("%c\r", "/-\\|"[(fun_animation++) % 4]); return 1; } static int end(t_hts_callbackarg * carg, httrackp * opt) { t_my_userdef *userdef = (t_my_userdef *) CALLBACKARG_USERDEF(carg); fprintf(stderr, "** info: wrapper_exit() called!\n"); if (userdef != NULL) { free(userdef); userdef = NULL; } /* Call parent functions if multiple callbacks are chained. */ if (CALLBACKARG_PREV_FUN(carg, end) != NULL) { return CALLBACKARG_PREV_FUN(carg, end) (CALLBACKARG_PREV_CARG(carg), opt); } return 1; /* success */ } httrack-3.49.5/libtest/callbacks-example-filenameiisbug.c0000644000175000017500000000514314336470674020361 00000000000000/* HTTrack external callbacks example : changing folder names ending with ".com" with ".c0m" as a workaround of IIS bug (see KB 275601) How to build: (callback.so or callback.dll) With GNU-GCC: gcc -O -g3 -Wall -D_REENTRANT -shared -o mycallback.so callbacks-example.c -lhttrack2 With MS-Visual C++: cl -LD -nologo -W3 -Zi -Zp4 -DWIN32 -Fe"mycallback.dll" callbacks-example.c libhttrack.lib Note: the httrack library linker option is only necessary when using libhttrack's functions inside the callback */ #include #include #include /* Standard httrack module includes */ #include "httrack-library.h" #include "htsopt.h" #include "htsdefines.h" /* Function definitions */ static int mysavename(t_hts_callbackarg * carg, httrackp * opt, const char *adr_complete, const char *fil_complete, const char *referer_adr, const char *referer_fil, char *save); /* external functions */ EXTERNAL_FUNCTION int hts_plug(httrackp * opt, const char *argv); /* module entry point */ EXTERNAL_FUNCTION int hts_plug(httrackp * opt, const char *argv) { const char *arg = strchr(argv, ','); if (arg != NULL) arg++; CHAIN_FUNCTION(opt, savename, mysavename, NULL); return 1; /* success */ } /* Replaces all "offending" IIS extensions (exe, dll..) with "nice" ones */ static int mysavename(t_hts_callbackarg * carg, httrackp * opt, const char *adr_complete, const char *fil_complete, const char *referer_adr, const char *referer_fil, char *save) { static const char *iisBogus[] = { ".com", ".exe", ".dll", ".sh", NULL }; static const char *iisBogusReplace[] = { ".c0m", ".ex3", ".dl1", ".5h", NULL }; /* MUST be the same sizes */ char *a; /* Call parent functions if multiple callbacks are chained. */ if (CALLBACKARG_PREV_FUN(carg, savename) != NULL) { if (!CALLBACKARG_PREV_FUN(carg, savename) (CALLBACKARG_PREV_CARG(carg), opt, adr_complete, fil_complete, referer_adr, referer_fil, save)) { return 0; /* Abort */ } } /* Process */ for(a = save; *a != '\0'; a++) { int i; for(i = 0; iisBogus[i] != NULL; i++) { int j; for(j = 0; iisBogus[i][j] == a[j] && iisBogus[i][j] != '\0'; j++) ; if (iisBogus[i][j] == '\0' && (a[j] == '\0' || a[j] == '/' || a[j] == '\\')) { strncpy(a, iisBogusReplace[i], strlen(iisBogusReplace[i])); break; } } } return 1; /* success */ } httrack-3.49.5/libtest/callbacks-example-filename2.c0000644000175000017500000001076614336470674017247 00000000000000/* How to build: (callback.so or callback.dll) With GNU-GCC: gcc -O -g3 -Wall -D_REENTRANT -shared -o mycallback.so callbacks-example.c -lhttrack2 With MS-Visual C++: cl -LD -nologo -W3 -Zi -Zp4 -DWIN32 -Fe"mycallback.dll" callbacks-example.c libhttrack.lib Note: the httrack library linker option is only necessary when using libhttrack's functions inside the callback How to use: httrack --wrapper mycallback,string1,string2 .. */ #include #include #include /* Standard httrack module includes */ #include "httrack-library.h" #include "htsopt.h" #include "htsdefines.h" /* Function definitions */ static int mysavename(t_hts_callbackarg * carg, httrackp * opt, const char *adr_complete, const char *fil_complete, const char *referer_adr, const char *referer_fil, char *save); static int myend(t_hts_callbackarg * carg, httrackp * opt); /* external functions */ EXTERNAL_FUNCTION int hts_plug(httrackp * opt, const char *argv); /* TOLOWER */ #define TOLOWER_(a) (a >= 'A' && a <= 'Z') ? (a + ('a' - 'A')) : a #define TOLOWER(a) ( TOLOWER_( (a) ) ) /* This sample just replaces all occurences of "string1" into "string2" string1 and string2 are passed in the callback string: httrack --wrapper save-name=callback:mysavename,string1,string2 .. */ typedef struct t_my_userdef { char string1[256]; char string2[256]; } t_my_userdef; /* module entry point */ EXTERNAL_FUNCTION int hts_plug(httrackp * opt, const char *argv) { const char *arg = strchr(argv, ','); if (arg != NULL) arg++; /* Check args */ if (arg == NULL || *arg == '\0' || strchr(arg, ',') == NULL) { fprintf(stderr, "** callback error: arguments expected or bad arguments\n"); fprintf(stderr, "usage: httrack --wrapper save-name=callback:mysavename,string1,string2\n"); fprintf(stderr, "example: httrack --wrapper save-name=callback:mysavename,foo,bar\n"); return 0; /* failed */ } else { char *pos = strchr(arg, ','); t_my_userdef *userdef = (t_my_userdef *) malloc(sizeof(t_my_userdef)); char *const string1 = userdef->string1; char *const string2 = userdef->string2; /* Split args */ fprintf(stderr, "** info: wrapper_init(%s) called!\n", arg); fprintf(stderr, "** callback example: changing destination filename word by another one\n"); string1[0] = string1[1] = '\0'; strncat(string1, arg, pos - arg); strcpy(string2, pos + 1); fprintf(stderr, "** callback info: will replace %s by %s in filenames!\n", string1, string2); /* Plug callback functions */ CHAIN_FUNCTION(opt, savename, mysavename, userdef); CHAIN_FUNCTION(opt, end, myend, userdef); } return 1; /* success */ } static int myend(t_hts_callbackarg * carg, httrackp * opt) { t_my_userdef *userdef = (t_my_userdef *) CALLBACKARG_USERDEF(carg); fprintf(stderr, "** info: wrapper_exit() called!\n"); if (userdef != NULL) { free(userdef); userdef = NULL; } /* Call parent functions if multiple callbacks are chained. */ if (CALLBACKARG_PREV_FUN(carg, end) != NULL) { return CALLBACKARG_PREV_FUN(carg, end) (CALLBACKARG_PREV_CARG(carg), opt); } return 1; /* success */ } static int mysavename(t_hts_callbackarg * carg, httrackp * opt, const char *adr_complete, const char *fil_complete, const char *referer_adr, const char *referer_fil, char *save) { t_my_userdef *userdef = (t_my_userdef *) CALLBACKARG_USERDEF(carg); char *const string1 = userdef->string1; char *const string2 = userdef->string2; /* */ char *buff, *a, *b; /* Call parent functions if multiple callbacks are chained. */ if (CALLBACKARG_PREV_FUN(carg, savename) != NULL) { if (!CALLBACKARG_PREV_FUN(carg, savename) (CALLBACKARG_PREV_CARG(carg), opt, adr_complete, fil_complete, referer_adr, referer_fil, save)) { return 0; /* Abort */ } } /* Process */ buff = strdup(save); a = buff; b = save; *b = '\0'; /* the "save" variable points to a buffer with "sufficient" space */ while(*a) { if (strncmp(a, string1, (int) strlen(string1)) == 0) { strcat(b, string2); b += strlen(b); a += strlen(string1); } else { *b++ = *a++; *b = '\0'; } } free(buff); return 1; /* success */ } httrack-3.49.5/libtest/callbacks-example-filename.c0000644000175000017500000000507614336470674017163 00000000000000/* HTTrack external callbacks example : changing the destination filename .c file How to build: (callback.so or callback.dll) With GNU-GCC: gcc -O -g3 -Wall -D_REENTRANT -shared -o mycallback.so callbacks-example.c -lhttrack2 With MS-Visual C++: cl -LD -nologo -W3 -Zi -Zp4 -DWIN32 -Fe"mycallback.dll" callbacks-example.c libhttrack.lib Note: the httrack library linker option is only necessary when using libhttrack's functions inside the callback How to use: httrack --wrapper mycallback .. */ #include #include #include /* Standard httrack module includes */ #include "httrack-library.h" #include "htsopt.h" #include "htsdefines.h" /* Local function definitions */ static int mysavename(t_hts_callbackarg * carg, httrackp * opt, const char *adr_complete, const char *fil_complete, const char *referer_adr, const char *referer_fil, char *save); /* external functions */ EXTERNAL_FUNCTION int hts_plug(httrackp * opt, const char *argv); /* Options settings */ #include "htsopt.h" /* TOLOWER */ #define TOLOWER_(a) (a >= 'A' && a <= 'Z') ? (a + ('a' - 'A')) : a #define TOLOWER(a) ( TOLOWER_( (a) ) ) /* This sample just changes the destination filenames to ROT-13 equivalent ; that is, a -> n b -> o c -> p d -> q .. n -> a o -> b .. -> This sample can be improved, for example, to make a map of a website. */ /* module entry point */ EXTERNAL_FUNCTION int hts_plug(httrackp * opt, const char *argv) { const char *arg = strchr(argv, ','); if (arg != NULL) arg++; /* Plug callback functions */ CHAIN_FUNCTION(opt, savename, mysavename, NULL); return 1; /* success */ } static int mysavename(t_hts_callbackarg * carg, httrackp * opt, const char *adr_complete, const char *fil_complete, const char *referer_adr, const char *referer_fil, char *save) { char *a; /* Call parent functions if multiple callbacks are chained. */ if (CALLBACKARG_PREV_FUN(carg, savename) != NULL) { if (!CALLBACKARG_PREV_FUN(carg, savename) (CALLBACKARG_PREV_CARG(carg), opt, adr_complete, fil_complete, referer_adr, referer_fil, save)) { return 0; /* Abort */ } } /* Process */ for(a = save; *a != 0; a++) { char c = TOLOWER(*a); if (c >= 'a' && c <= 'z') *a = (((c - 'a') + 13) % 26) + 'a'; // ROT-13 } return 1; /* success */ } httrack-3.49.5/libtest/callbacks-example-displayheader.c0000644000175000017500000000407614336470674020220 00000000000000/* HTTrack external callbacks example : display all incoming request headers Example of _init and _exit call (httrack >> 3.31) .c file How to build: (callback.so or callback.dll) With GNU-GCC: gcc -O -g3 -Wall -D_REENTRANT -shared -o mycallback.so callbacks-example.c -lhttrack2 With MS-Visual C++: cl -LD -nologo -W3 -Zi -Zp4 -DWIN32 -Fe"mycallback.dll" callbacks-example.c libhttrack.lib Note: the httrack library linker option is only necessary when using libhttrack's functions inside the callback How to use: httrack --wrapper mycallback .. */ #include #include #include /* Standard httrack module includes */ #include "httrack-library.h" #include "htsopt.h" #include "htsdefines.h" /* Local function definitions */ static int process(t_hts_callbackarg * carg, httrackp * opt, char *buff, const char *adr, const char *fil, const char *referer_adr, const char *referer_fil, htsblk * incoming); /* external functions */ EXTERNAL_FUNCTION int hts_plug(httrackp * opt, const char *argv); /* module entry point */ EXTERNAL_FUNCTION int hts_plug(httrackp * opt, const char *argv) { const char *arg = strchr(argv, ','); if (arg != NULL) arg++; /* Plug callback functions */ CHAIN_FUNCTION(opt, receivehead, process, NULL); return 1; /* success */ } static int process(t_hts_callbackarg * carg, httrackp * opt, char *buff, const char *adr, const char *fil, const char *referer_adr, const char *referer_fil, htsblk * incoming) { /* Call parent functions if multiple callbacks are chained. */ if (CALLBACKARG_PREV_FUN(carg, receivehead) != NULL) { if (!CALLBACKARG_PREV_FUN(carg, receivehead) (CALLBACKARG_PREV_CARG(carg), opt, buff, adr, fil, referer_adr, referer_fil, incoming)) { return 0; /* Abort */ } } /* Process */ printf("[ %s%s ]\n%s\n", adr, fil, buff); return 1; /* success */ } httrack-3.49.5/libtest/callbacks-example-contentfilter.c0000644000175000017500000001205614336470674020257 00000000000000/* HTTrack external callbacks example : crawling html pages depending on content Example of _init and _exit call (httrack >> 3.31) .c file How to build: (callback.so or callback.dll) With GNU-GCC: gcc -O -g3 -Wall -D_REENTRANT -shared -o mycallback.so callbacks-example.c -lhttrack2 With MS-Visual C++: cl -LD -nologo -W3 -Zi -Zp4 -DWIN32 -Fe"mycallback.dll" callbacks-example.c libhttrack.lib Note: the httrack library linker option is only necessary when using libhttrack's functions inside the callback How to use: httrack --wrapper mycallback,stringtofind,stringtofind.. .. */ #include #include #include /* Standard httrack module includes */ #include "httrack-library.h" #include "htsopt.h" #include "htsdefines.h" /* Local function definitions */ static int process(t_hts_callbackarg * carg, httrackp * opt, char *html, int len, const char *address, const char *filename); static int end(t_hts_callbackarg * carg, httrackp * opt); /* external functions */ EXTERNAL_FUNCTION int hts_plug(httrackp * opt, const char *argv); /* TOLOWER */ #define TOLOWER_(a) (a >= 'A' && a <= 'Z') ? (a + ('a' - 'A')) : a #define TOLOWER(a) ( TOLOWER_( (a) ) ) /* This sample just crawls pages that contains certain keywords, and skips the other ones */ typedef struct t_my_userdef { char stringfilter[8192]; char *stringfilters[128]; } t_my_userdef; /* module entry point */ EXTERNAL_FUNCTION int hts_plug(httrackp * opt, const char *argv) { const char *arg = strchr(argv, ','); if (arg != NULL) arg++; /* Check args */ if (arg == NULL || *arg == '\0') { fprintf(stderr, "** callback error: arguments expected or bad arguments\n"); fprintf(stderr, "usage: httrack --wrapper callback,stringtofind,stringtofind..\n"); fprintf(stderr, "example: httrack --wrapper callback,apple,orange,lemon\n"); return 0; } else { t_my_userdef *userdef = (t_my_userdef *) malloc(sizeof(t_my_userdef)); /* userdef */ char *const stringfilter = userdef->stringfilter; char **const stringfilters = userdef->stringfilters; /* */ char *a = stringfilter; int i = 0; fprintf(stderr, "** info: wrapper_init(%s) called!\n", arg); fprintf(stderr, "** callback example: crawling pages only if specific keywords are found\n"); /* stringfilters = split(arg, ','); */ strcpy(stringfilter, arg); while(a != NULL) { stringfilters[i] = a; a = strchr(a, ','); if (a != NULL) { *a = '\0'; a++; } fprintf(stderr, "** callback info: will crawl pages with '%s' in them\n", stringfilters[i]); i++; } stringfilters[i++] = NULL; /* Plug callback functions */ CHAIN_FUNCTION(opt, check_html, process, userdef); CHAIN_FUNCTION(opt, end, end, userdef); } return 1; /* success */ } static int process(t_hts_callbackarg * carg, httrackp * opt, char *html, int len, const char *address, const char *filename) { t_my_userdef *userdef = (t_my_userdef *) CALLBACKARG_USERDEF(carg); /*char * const stringfilter = userdef->stringfilter; */ char **const stringfilters = userdef->stringfilters; /* */ int i = 0; int getIt = 0; char *pos; /* Call parent functions if multiple callbacks are chained. */ if (CALLBACKARG_PREV_FUN(carg, check_html) != NULL) { if (!CALLBACKARG_PREV_FUN(carg, check_html) (CALLBACKARG_PREV_CARG(carg), opt, html, len, address, filename)) { return 0; /* Abort */ } } /* Process */ if (strcmp(address, "primary") == 0 && strcmp(filename, "/primary") == 0) /* primary page (list of links) */ return 1; while(stringfilters[i] != NULL && !getIt) { if ((pos = strstr(html, stringfilters[i])) != NULL) { int j; getIt = 1; fprintf(stderr, "** callback info: found '%s' keyword in '%s%s', crawling this page!\n", stringfilters[i], address, filename); fprintf(stderr, "** details:\n(..)"); for(j = 0; j < 72 && pos[j]; j++) { if (pos[j] > 32) fprintf(stderr, "%c", pos[j]); else fprintf(stderr, "?"); } fprintf(stderr, "(..)\n"); } i++; } if (getIt) { return 1; /* success */ } else { fprintf(stderr, "** callback info: won't parse '%s%s' (no specified keywords found)\n", address, filename); return 0; /* this page sucks, don't parse it */ } } static int end(t_hts_callbackarg * carg, httrackp * opt) { t_my_userdef *userdef = (t_my_userdef *) CALLBACKARG_USERDEF(carg); fprintf(stderr, "** info: wrapper_exit() called!\n"); if (userdef != NULL) { free(userdef); userdef = NULL; } /* Call parent functions if multiple callbacks are chained. */ if (CALLBACKARG_PREV_FUN(carg, end) != NULL) { return CALLBACKARG_PREV_FUN(carg, end) (CALLBACKARG_PREV_CARG(carg), opt); } return 1; /* success */ } httrack-3.49.5/libtest/callbacks-example-changecontent.c0000644000175000017500000000370014336470674020213 00000000000000/* HTTrack external callbacks example : display all incoming request headers Example of _init and _exit call (httrack >> 3.31) .c file How to build: (callback.so or callback.dll) With GNU-GCC: gcc -O -g3 -Wall -D_REENTRANT -shared -o mycallback.so callbacks-example.c -lhttrack2 With MS-Visual C++: cl -LD -nologo -W3 -Zi -Zp4 -DWIN32 -Fe"mycallback.dll" callbacks-example.c libhttrack.lib Note: the httrack library linker option is only necessary when using libhttrack's functions inside the callback How to use: httrack --wrapper mycallback .. */ #include #include #include /* Standard httrack module includes */ #include "httrack-library.h" #include "htsopt.h" #include "htsdefines.h" /* Local function definitions */ static int postprocess(t_hts_callbackarg * carg, httrackp * opt, char **html, int *len, const char *url_address, const char *url_file); /* external functions */ EXTERNAL_FUNCTION int hts_plug(httrackp * opt, const char *argv); /* module entry point */ EXTERNAL_FUNCTION int hts_plug(httrackp * opt, const char *argv) { const char *arg = strchr(argv, ','); if (arg != NULL) arg++; /* Plug callback functions */ CHAIN_FUNCTION(opt, postprocess, postprocess, NULL); return 1; /* success */ } static int postprocess(t_hts_callbackarg * carg, httrackp * opt, char **html, int *len, const char *url_address, const char *url_file) { char *old = *html; /* Call parent functions if multiple callbacks are chained. */ if (CALLBACKARG_PREV_FUN(carg, postprocess) != NULL) { if (CALLBACKARG_PREV_FUN(carg, postprocess) (CALLBACKARG_PREV_CARG(carg), opt, html, len, url_address, url_file)) { /* Modified *html */ old = *html; } } /* Process */ *html = strdup(*html); hts_free(old); return 1; } httrack-3.49.5/libtest/callbacks-example-baselinks.c0000644000175000017500000001023014336470674017342 00000000000000/* HTTrack external callbacks example : enforce a constant base href Can be useful to make copies of site's archives using site's URL base href as root reference .c file How to build: (callback.so or callback.dll) With GNU-GCC: gcc -O -g3 -Wall -D_REENTRANT -shared -o mycallback.so callbacks-example.c -lhttrack2 With MS-Visual C++: cl -LD -nologo -W3 -Zi -Zp4 -DWIN32 -Fe"mycallback.dll" callbacks-example.c libhttrack.lib Note: the httrack library linker option is only necessary when using libhttrack's functions inside the callback How to use: httrack --wrapper mycallback .. */ #include #include #include /* Standard httrack module includes */ #include "httrack-library.h" #include "htsopt.h" #include "htsdefines.h" /* Local function definitions */ static int process_file(t_hts_callbackarg * carg, httrackp * opt, char *html, int len, const char *url_address, const char *url_file); static int check_detectedlink(t_hts_callbackarg * carg, httrackp * opt, char *link); static int check_detectedlink_end(t_hts_callbackarg * carg, httrackp * opt); /* external functions */ EXTERNAL_FUNCTION int hts_plug(httrackp * opt, const char *argv); /* module entry point */ EXTERNAL_FUNCTION int hts_plug(httrackp * opt, const char *argv) { const char *arg = strchr(argv, ','); if (arg != NULL) arg++; /* Check args */ fprintf(stderr, "Plugged..\n"); if (arg == NULL || *arg == '\0' || strlen(arg) >= HTS_URLMAXSIZE / 2) { fprintf(stderr, "** callback error: arguments expected or bad arguments\n"); fprintf(stderr, "usage: httrack --wrapper modulename,base\n"); fprintf(stderr, "example: httrack --wrapper callback,http://www.example.com/\n"); return 0; /* failed */ } else { char *callbacks_userdef = strdup(arg); /* userdef */ /* Plug callback functions */ CHAIN_FUNCTION(opt, check_html, process_file, callbacks_userdef); CHAIN_FUNCTION(opt, linkdetected, check_detectedlink, callbacks_userdef); CHAIN_FUNCTION(opt, end, check_detectedlink_end, callbacks_userdef); fprintf(stderr, "Using root '%s'\n", callbacks_userdef); } return 1; /* success */ } static int process_file(t_hts_callbackarg * carg, httrackp * opt, char *html, int len, const char *url_address, const char *url_file) { char *prevBase; /* Call parent functions if multiple callbacks are chained. */ if (CALLBACKARG_PREV_FUN(carg, check_html) != NULL) { if (!CALLBACKARG_PREV_FUN(carg, check_html) (CALLBACKARG_PREV_CARG(carg), opt, html, len, url_address, url_file)) { return 0; /* Abort */ } } /* Disable base href, if any */ if ((prevBase = strstr(html, "&2; \ exit 1;; \ esac; \ has_opt=no; \ sane_makeflags=$$MAKEFLAGS; \ if $(am__is_gnu_make); then \ sane_makeflags=$$MFLAGS; \ else \ case $$MAKEFLAGS in \ *\\[\ \ ]*) \ bs=\\; \ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ esac; \ fi; \ skip_next=no; \ strip_trailopt () \ { \ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ }; \ for flg in $$sane_makeflags; do \ test $$skip_next = yes && { skip_next=no; continue; }; \ case $$flg in \ *=*|--*) continue;; \ -*I) strip_trailopt 'I'; skip_next=yes;; \ -*I?*) strip_trailopt 'I';; \ -*O) strip_trailopt 'O'; skip_next=yes;; \ -*O?*) strip_trailopt 'O';; \ -*l) strip_trailopt 'l'; skip_next=yes;; \ -*l?*) strip_trailopt 'l';; \ -[dEDm]) skip_next=yes;; \ -[JT]) skip_next=yes;; \ esac; \ case $$flg in \ *$$target_option*) has_opt=yes; break;; \ esac; \ done; \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkglibexecdir = $(libexecdir)/@PACKAGE@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ subdir = libtest ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/check_zlib.m4 \ $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/snprintf.m4 \ $(top_srcdir)/m4/visibility.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ *) f=$$p;; \ esac; am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; am__install_max = 40 am__nobase_strip_setup = \ srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` am__nobase_strip = \ for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" am__nobase_list = $(am__nobase_strip_setup); \ for p in $$list; do echo "$$p $$p"; done | \ sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ if (++n[$$2] == $(am__install_max)) \ { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ END { for (dir in files) print dir, files[dir] }' am__base_list = \ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' am__uninstall_files_from_dir = { \ test -z "$$files" \ || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ $(am__cd) "$$dir" && rm -f $$files; }; \ } am__installdirs = "$(DESTDIR)$(pkglibdir)" "$(DESTDIR)$(exemplesdir)" LTLIBRARIES = $(pkglib_LTLIBRARIES) am__DEPENDENCIES_1 = libbaselinks_la_DEPENDENCIES = $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) $(top_builddir)/src/libhttrack.la am_libbaselinks_la_OBJECTS = callbacks-example-baselinks.lo libbaselinks_la_OBJECTS = $(am_libbaselinks_la_OBJECTS) AM_V_lt = $(am__v_lt_@AM_V@) am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) am__v_lt_0 = --silent am__v_lt_1 = libbaselinks_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \ $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \ $(AM_CFLAGS) $(CFLAGS) $(libbaselinks_la_LDFLAGS) $(LDFLAGS) \ -o $@ libchangecontent_la_DEPENDENCIES = $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) $(top_builddir)/src/libhttrack.la am_libchangecontent_la_OBJECTS = callbacks-example-changecontent.lo libchangecontent_la_OBJECTS = $(am_libchangecontent_la_OBJECTS) libchangecontent_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \ $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \ $(AM_CFLAGS) $(CFLAGS) $(libchangecontent_la_LDFLAGS) \ $(LDFLAGS) -o $@ libcontentfilter_la_DEPENDENCIES = $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) $(top_builddir)/src/libhttrack.la am_libcontentfilter_la_OBJECTS = callbacks-example-contentfilter.lo libcontentfilter_la_OBJECTS = $(am_libcontentfilter_la_OBJECTS) libcontentfilter_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \ $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \ $(AM_CFLAGS) $(CFLAGS) $(libcontentfilter_la_LDFLAGS) \ $(LDFLAGS) -o $@ libdisplayheader_la_DEPENDENCIES = $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) $(top_builddir)/src/libhttrack.la am_libdisplayheader_la_OBJECTS = callbacks-example-displayheader.lo libdisplayheader_la_OBJECTS = $(am_libdisplayheader_la_OBJECTS) libdisplayheader_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \ $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \ $(AM_CFLAGS) $(CFLAGS) $(libdisplayheader_la_LDFLAGS) \ $(LDFLAGS) -o $@ libfilename_la_DEPENDENCIES = $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) $(top_builddir)/src/libhttrack.la am_libfilename_la_OBJECTS = callbacks-example-filename.lo libfilename_la_OBJECTS = $(am_libfilename_la_OBJECTS) libfilename_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \ $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \ $(AM_CFLAGS) $(CFLAGS) $(libfilename_la_LDFLAGS) $(LDFLAGS) -o \ $@ libfilename2_la_DEPENDENCIES = $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) $(top_builddir)/src/libhttrack.la am_libfilename2_la_OBJECTS = callbacks-example-filename2.lo libfilename2_la_OBJECTS = $(am_libfilename2_la_OBJECTS) libfilename2_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \ $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \ $(AM_CFLAGS) $(CFLAGS) $(libfilename2_la_LDFLAGS) $(LDFLAGS) \ -o $@ libfilenameiisbug_la_DEPENDENCIES = $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) $(top_builddir)/src/libhttrack.la am_libfilenameiisbug_la_OBJECTS = callbacks-example-filenameiisbug.lo libfilenameiisbug_la_OBJECTS = $(am_libfilenameiisbug_la_OBJECTS) libfilenameiisbug_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \ $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \ $(AM_CFLAGS) $(CFLAGS) $(libfilenameiisbug_la_LDFLAGS) \ $(LDFLAGS) -o $@ liblistlinks_la_DEPENDENCIES = $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) $(top_builddir)/src/libhttrack.la am_liblistlinks_la_OBJECTS = callbacks-example-listlinks.lo liblistlinks_la_OBJECTS = $(am_liblistlinks_la_OBJECTS) liblistlinks_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \ $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \ $(AM_CFLAGS) $(CFLAGS) $(liblistlinks_la_LDFLAGS) $(LDFLAGS) \ -o $@ liblog_la_DEPENDENCIES = $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ $(top_builddir)/src/libhttrack.la am_liblog_la_OBJECTS = callbacks-example-log.lo liblog_la_OBJECTS = $(am_liblog_la_OBJECTS) liblog_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ $(liblog_la_LDFLAGS) $(LDFLAGS) -o $@ libsimple_la_DEPENDENCIES = $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) $(top_builddir)/src/libhttrack.la am_libsimple_la_OBJECTS = callbacks-example-simple.lo libsimple_la_OBJECTS = $(am_libsimple_la_OBJECTS) libsimple_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ $(libsimple_la_LDFLAGS) $(LDFLAGS) -o $@ AM_V_P = $(am__v_P_@AM_V@) am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) am__v_P_0 = false am__v_P_1 = : AM_V_GEN = $(am__v_GEN_@AM_V@) am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) am__v_GEN_0 = @echo " GEN " $@; am__v_GEN_1 = AM_V_at = $(am__v_at_@AM_V@) am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) am__v_at_0 = @ am__v_at_1 = DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) depcomp = $(SHELL) $(top_srcdir)/depcomp am__maybe_remake_depfiles = depfiles am__depfiles_remade = ./$(DEPDIR)/callbacks-example-baselinks.Plo \ ./$(DEPDIR)/callbacks-example-changecontent.Plo \ ./$(DEPDIR)/callbacks-example-contentfilter.Plo \ ./$(DEPDIR)/callbacks-example-displayheader.Plo \ ./$(DEPDIR)/callbacks-example-filename.Plo \ ./$(DEPDIR)/callbacks-example-filename2.Plo \ ./$(DEPDIR)/callbacks-example-filenameiisbug.Plo \ ./$(DEPDIR)/callbacks-example-listlinks.Plo \ ./$(DEPDIR)/callbacks-example-log.Plo \ ./$(DEPDIR)/callbacks-example-simple.Plo am__mv = mv -f COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ $(AM_CFLAGS) $(CFLAGS) AM_V_CC = $(am__v_CC_@AM_V@) am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) am__v_CC_0 = @echo " CC " $@; am__v_CC_1 = CCLD = $(CC) LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ $(AM_LDFLAGS) $(LDFLAGS) -o $@ AM_V_CCLD = $(am__v_CCLD_@AM_V@) am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) am__v_CCLD_0 = @echo " CCLD " $@; am__v_CCLD_1 = SOURCES = $(libbaselinks_la_SOURCES) $(libchangecontent_la_SOURCES) \ $(libcontentfilter_la_SOURCES) $(libdisplayheader_la_SOURCES) \ $(libfilename_la_SOURCES) $(libfilename2_la_SOURCES) \ $(libfilenameiisbug_la_SOURCES) $(liblistlinks_la_SOURCES) \ $(liblog_la_SOURCES) $(libsimple_la_SOURCES) DIST_SOURCES = $(libbaselinks_la_SOURCES) \ $(libchangecontent_la_SOURCES) $(libcontentfilter_la_SOURCES) \ $(libdisplayheader_la_SOURCES) $(libfilename_la_SOURCES) \ $(libfilename2_la_SOURCES) $(libfilenameiisbug_la_SOURCES) \ $(liblistlinks_la_SOURCES) $(liblog_la_SOURCES) \ $(libsimple_la_SOURCES) am__can_run_installinfo = \ case $$AM_UPDATE_INFO_DIR in \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac DATA = $(exemples_DATA) am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) # Read a list of newline-separated strings from the standard input, # and print each of them once, without duplicates. Input order is # *not* preserved. am__uniquify_input = $(AWK) '\ BEGIN { nonempty = 0; } \ { items[$$0] = 1; nonempty = 1; } \ END { if (nonempty) { for (i in items) print i; }; } \ ' # Make sure the list of sources is unique. This is necessary because, # e.g., the same source file might be shared among _SOURCES variables # for different programs/libraries. am__define_uniq_tagged_files = \ list='$(am__tagged_files)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | $(am__uniquify_input)` am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depcomp DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AM_CFLAGS = @AM_CFLAGS@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CFLAGS_PIE = @CFLAGS_PIE@ CFLAG_VISIBILITY = @CFLAG_VISIBILITY@ CPPFLAGS = @CPPFLAGS@ CSCOPE = @CSCOPE@ CTAGS = @CTAGS@ CYGPATH_W = @CYGPATH_W@ DEFAULT_CFLAGS = @DEFAULT_CFLAGS@ DEFAULT_LDFLAGS = @DEFAULT_LDFLAGS@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DLLTOOL = @DLLTOOL@ DL_LIBS = @DL_LIBS@ DSYMUTIL = @DSYMUTIL@ DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ ETAGS = @ETAGS@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ FILECMD = @FILECMD@ GREP = @GREP@ HAVE_VISIBILITY = @HAVE_VISIBILITY@ HTTPS_SUPPORT = @HTTPS_SUPPORT@ ICONV_LIBS = @ICONV_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LD = @LD@ LDFLAGS = @LDFLAGS@ LDFLAGS_PIE = @LDFLAGS_PIE@ LFS_FLAG = @LFS_FLAG@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ LIPO = @LIPO@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ LT_CV_OBJDIR = @LT_CV_OBJDIR@ LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ MAINT = @MAINT@ MAKEINFO = @MAKEINFO@ MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ NM = @NM@ NMEDIT = @NMEDIT@ OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ ONLINE_UNIT_TESTS = @ONLINE_UNIT_TESTS@ OPENSSL_LIBS = @OPENSSL_LIBS@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ RANLIB = @RANLIB@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ SHLIBPATH_VAR = @SHLIBPATH_VAR@ SOCKET_LIBS = @SOCKET_LIBS@ STRIP = @STRIP@ THREADS_CFLAGS = @THREADS_CFLAGS@ THREADS_LIBS = @THREADS_LIBS@ V6_FLAG = @V6_FLAG@ VERSION = @VERSION@ VERSION_INFO = @VERSION_INFO@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ builddir = @builddir@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ runstatedir = @runstatedir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ exemplesdir = $(datadir)/httrack/libtest exemples_DATA = *.c *.h *.txt EXTRA_DIST = $(exemples_DATA) libtest.mak libtest.vcproj AM_CPPFLAGS = @DEFAULT_CFLAGS@ @THREADS_CFLAGS@ @V6_FLAG@ @LFS_FLAG@ \ -DPREFIX=\""$(prefix)"\" -DSYSCONFDIR=\""$(sysconfdir)"\" \ -DDATADIR=\""$(datadir)"\" -DLIBDIR=\""$(libdir)"\" -I../src AM_LDFLAGS = \ @DEFAULT_LDFLAGS@ \ -L../src # Examples libbaselinks_la_SOURCES = callbacks-example-baselinks.c libbaselinks_la_LIBADD = $(THREADS_LIBS) $(SOCKET_LIBS) $(top_builddir)/src/libhttrack.la libbaselinks_la_LDFLAGS = $(AM_LDFLAGS) -version-info 1:0:0 libchangecontent_la_SOURCES = callbacks-example-changecontent.c libchangecontent_la_LIBADD = $(THREADS_LIBS) $(SOCKET_LIBS) $(top_builddir)/src/libhttrack.la libchangecontent_la_LDFLAGS = $(AM_LDFLAGS) -version-info 1:0:0 libcontentfilter_la_SOURCES = callbacks-example-contentfilter.c libcontentfilter_la_LIBADD = $(THREADS_LIBS) $(SOCKET_LIBS) $(top_builddir)/src/libhttrack.la libcontentfilter_la_LDFLAGS = $(AM_LDFLAGS) -version-info 1:0:0 libdisplayheader_la_SOURCES = callbacks-example-displayheader.c libdisplayheader_la_LIBADD = $(THREADS_LIBS) $(SOCKET_LIBS) $(top_builddir)/src/libhttrack.la libdisplayheader_la_LDFLAGS = $(AM_LDFLAGS) -version-info 1:0:0 libfilename2_la_SOURCES = callbacks-example-filename2.c libfilename2_la_LIBADD = $(THREADS_LIBS) $(SOCKET_LIBS) $(top_builddir)/src/libhttrack.la libfilename2_la_LDFLAGS = $(AM_LDFLAGS) -version-info 1:0:0 libfilename_la_SOURCES = callbacks-example-filename.c libfilename_la_LIBADD = $(THREADS_LIBS) $(SOCKET_LIBS) $(top_builddir)/src/libhttrack.la libfilename_la_LDFLAGS = $(AM_LDFLAGS) -version-info 1:0:0 libfilenameiisbug_la_SOURCES = callbacks-example-filenameiisbug.c libfilenameiisbug_la_LIBADD = $(THREADS_LIBS) $(SOCKET_LIBS) $(top_builddir)/src/libhttrack.la libfilenameiisbug_la_LDFLAGS = $(AM_LDFLAGS) -version-info 1:0:0 liblistlinks_la_SOURCES = callbacks-example-listlinks.c liblistlinks_la_LIBADD = $(THREADS_LIBS) $(SOCKET_LIBS) $(top_builddir)/src/libhttrack.la liblistlinks_la_LDFLAGS = $(AM_LDFLAGS) -version-info 1:0:0 liblog_la_SOURCES = callbacks-example-log.c liblog_la_LIBADD = $(THREADS_LIBS) $(SOCKET_LIBS) $(top_builddir)/src/libhttrack.la liblog_la_LDFLAGS = $(AM_LDFLAGS) -version-info 1:0:0 libsimple_la_SOURCES = callbacks-example-simple.c libsimple_la_LIBADD = $(THREADS_LIBS) $(SOCKET_LIBS) $(top_builddir)/src/libhttrack.la libsimple_la_LDFLAGS = $(AM_LDFLAGS) -version-info 1:0:0 pkglib_LTLIBRARIES = libbaselinks.la libchangecontent.la libcontentfilter.la libdisplayheader.la libfilename2.la libfilename.la libfilenameiisbug.la liblistlinks.la liblog.la libsimple.la all: all-am .SUFFIXES: .SUFFIXES: .c .lo .o .obj $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ && { if test -f $@; then exit 0; else break; fi; }; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu libtest/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --gnu libtest/Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(am__aclocal_m4_deps): install-pkglibLTLIBRARIES: $(pkglib_LTLIBRARIES) @$(NORMAL_INSTALL) @list='$(pkglib_LTLIBRARIES)'; test -n "$(pkglibdir)" || list=; \ list2=; for p in $$list; do \ if test -f $$p; then \ list2="$$list2 $$p"; \ else :; fi; \ done; \ test -z "$$list2" || { \ echo " $(MKDIR_P) '$(DESTDIR)$(pkglibdir)'"; \ $(MKDIR_P) "$(DESTDIR)$(pkglibdir)" || exit 1; \ echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(pkglibdir)'"; \ $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(pkglibdir)"; \ } uninstall-pkglibLTLIBRARIES: @$(NORMAL_UNINSTALL) @list='$(pkglib_LTLIBRARIES)'; test -n "$(pkglibdir)" || list=; \ for p in $$list; do \ $(am__strip_dir) \ echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(pkglibdir)/$$f'"; \ $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(pkglibdir)/$$f"; \ done clean-pkglibLTLIBRARIES: -test -z "$(pkglib_LTLIBRARIES)" || rm -f $(pkglib_LTLIBRARIES) @list='$(pkglib_LTLIBRARIES)'; \ locs=`for p in $$list; do echo $$p; done | \ sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ sort -u`; \ test -z "$$locs" || { \ echo rm -f $${locs}; \ rm -f $${locs}; \ } libbaselinks.la: $(libbaselinks_la_OBJECTS) $(libbaselinks_la_DEPENDENCIES) $(EXTRA_libbaselinks_la_DEPENDENCIES) $(AM_V_CCLD)$(libbaselinks_la_LINK) -rpath $(pkglibdir) $(libbaselinks_la_OBJECTS) $(libbaselinks_la_LIBADD) $(LIBS) libchangecontent.la: $(libchangecontent_la_OBJECTS) $(libchangecontent_la_DEPENDENCIES) $(EXTRA_libchangecontent_la_DEPENDENCIES) $(AM_V_CCLD)$(libchangecontent_la_LINK) -rpath $(pkglibdir) $(libchangecontent_la_OBJECTS) $(libchangecontent_la_LIBADD) $(LIBS) libcontentfilter.la: $(libcontentfilter_la_OBJECTS) $(libcontentfilter_la_DEPENDENCIES) $(EXTRA_libcontentfilter_la_DEPENDENCIES) $(AM_V_CCLD)$(libcontentfilter_la_LINK) -rpath $(pkglibdir) $(libcontentfilter_la_OBJECTS) $(libcontentfilter_la_LIBADD) $(LIBS) libdisplayheader.la: $(libdisplayheader_la_OBJECTS) $(libdisplayheader_la_DEPENDENCIES) $(EXTRA_libdisplayheader_la_DEPENDENCIES) $(AM_V_CCLD)$(libdisplayheader_la_LINK) -rpath $(pkglibdir) $(libdisplayheader_la_OBJECTS) $(libdisplayheader_la_LIBADD) $(LIBS) libfilename.la: $(libfilename_la_OBJECTS) $(libfilename_la_DEPENDENCIES) $(EXTRA_libfilename_la_DEPENDENCIES) $(AM_V_CCLD)$(libfilename_la_LINK) -rpath $(pkglibdir) $(libfilename_la_OBJECTS) $(libfilename_la_LIBADD) $(LIBS) libfilename2.la: $(libfilename2_la_OBJECTS) $(libfilename2_la_DEPENDENCIES) $(EXTRA_libfilename2_la_DEPENDENCIES) $(AM_V_CCLD)$(libfilename2_la_LINK) -rpath $(pkglibdir) $(libfilename2_la_OBJECTS) $(libfilename2_la_LIBADD) $(LIBS) libfilenameiisbug.la: $(libfilenameiisbug_la_OBJECTS) $(libfilenameiisbug_la_DEPENDENCIES) $(EXTRA_libfilenameiisbug_la_DEPENDENCIES) $(AM_V_CCLD)$(libfilenameiisbug_la_LINK) -rpath $(pkglibdir) $(libfilenameiisbug_la_OBJECTS) $(libfilenameiisbug_la_LIBADD) $(LIBS) liblistlinks.la: $(liblistlinks_la_OBJECTS) $(liblistlinks_la_DEPENDENCIES) $(EXTRA_liblistlinks_la_DEPENDENCIES) $(AM_V_CCLD)$(liblistlinks_la_LINK) -rpath $(pkglibdir) $(liblistlinks_la_OBJECTS) $(liblistlinks_la_LIBADD) $(LIBS) liblog.la: $(liblog_la_OBJECTS) $(liblog_la_DEPENDENCIES) $(EXTRA_liblog_la_DEPENDENCIES) $(AM_V_CCLD)$(liblog_la_LINK) -rpath $(pkglibdir) $(liblog_la_OBJECTS) $(liblog_la_LIBADD) $(LIBS) libsimple.la: $(libsimple_la_OBJECTS) $(libsimple_la_DEPENDENCIES) $(EXTRA_libsimple_la_DEPENDENCIES) $(AM_V_CCLD)$(libsimple_la_LINK) -rpath $(pkglibdir) $(libsimple_la_OBJECTS) $(libsimple_la_LIBADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) distclean-compile: -rm -f *.tab.c @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/callbacks-example-baselinks.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/callbacks-example-changecontent.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/callbacks-example-contentfilter.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/callbacks-example-displayheader.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/callbacks-example-filename.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/callbacks-example-filename2.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/callbacks-example-filenameiisbug.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/callbacks-example-listlinks.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/callbacks-example-log.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/callbacks-example-simple.Plo@am__quote@ # am--include-marker $(am__depfiles_remade): @$(MKDIR_P) $(@D) @echo '# dummy' >$@-t && $(am__mv) $@-t $@ am--depfiles: $(am__depfiles_remade) .c.o: @am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.o$$||'`;\ @am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\ @am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< .c.obj: @am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.obj$$||'`;\ @am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ `$(CYGPATH_W) '$<'` &&\ @am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` .c.lo: @am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.lo$$||'`;\ @am__fastdepCC_TRUE@ $(LTCOMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\ @am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs install-exemplesDATA: $(exemples_DATA) @$(NORMAL_INSTALL) @list='$(exemples_DATA)'; test -n "$(exemplesdir)" || list=; \ if test -n "$$list"; then \ echo " $(MKDIR_P) '$(DESTDIR)$(exemplesdir)'"; \ $(MKDIR_P) "$(DESTDIR)$(exemplesdir)" || exit 1; \ fi; \ for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; \ done | $(am__base_list) | \ while read files; do \ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(exemplesdir)'"; \ $(INSTALL_DATA) $$files "$(DESTDIR)$(exemplesdir)" || exit $$?; \ done uninstall-exemplesDATA: @$(NORMAL_UNINSTALL) @list='$(exemples_DATA)'; test -n "$(exemplesdir)" || list=; \ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ dir='$(DESTDIR)$(exemplesdir)'; $(am__uninstall_files_from_dir) ID: $(am__tagged_files) $(am__define_uniq_tagged_files); mkid -fID $$unique tags: tags-am TAGS: tags tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ if test $$# -gt 0; then \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ "$$@" $$unique; \ else \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$unique; \ fi; \ fi ctags: ctags-am CTAGS: ctags ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" cscopelist: cscopelist-am cscopelist-am: $(am__tagged_files) list='$(am__tagged_files)'; \ case "$(srcdir)" in \ [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ *) sdir=$(subdir)/$(srcdir) ;; \ esac; \ for i in $$list; do \ if test -f "$$i"; then \ echo "$(subdir)/$$i"; \ else \ echo "$$sdir/$$i"; \ fi; \ done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags distdir: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) distdir-am distdir-am: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ dist_files=`for file in $$list; do echo $$file; done | \ sed -e "s|^$$srcdirstrip/||;t" \ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ case $$dist_files in \ */*) $(MKDIR_P) `echo "$$dist_files" | \ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ sort -u` ;; \ esac; \ for file in $$dist_files; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ if test -d $$d/$$file; then \ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ if test -d "$(distdir)/$$file"; then \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ else \ test -f "$(distdir)/$$file" \ || cp -p $$d/$$file "$(distdir)/$$file" \ || exit 1; \ fi; \ done check-am: all-am check: check-am all-am: Makefile $(LTLIBRARIES) $(DATA) installdirs: for dir in "$(DESTDIR)$(pkglibdir)" "$(DESTDIR)$(exemplesdir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-am install-strip: if test -z '$(STRIP)'; then \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ install; \ else \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ fi mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-generic clean-libtool clean-pkglibLTLIBRARIES \ mostlyclean-am distclean: distclean-am -rm -f ./$(DEPDIR)/callbacks-example-baselinks.Plo -rm -f ./$(DEPDIR)/callbacks-example-changecontent.Plo -rm -f ./$(DEPDIR)/callbacks-example-contentfilter.Plo -rm -f ./$(DEPDIR)/callbacks-example-displayheader.Plo -rm -f ./$(DEPDIR)/callbacks-example-filename.Plo -rm -f ./$(DEPDIR)/callbacks-example-filename2.Plo -rm -f ./$(DEPDIR)/callbacks-example-filenameiisbug.Plo -rm -f ./$(DEPDIR)/callbacks-example-listlinks.Plo -rm -f ./$(DEPDIR)/callbacks-example-log.Plo -rm -f ./$(DEPDIR)/callbacks-example-simple.Plo -rm -f Makefile distclean-am: clean-am distclean-compile distclean-generic \ distclean-tags dvi: dvi-am dvi-am: html: html-am html-am: info: info-am info-am: install-data-am: install-exemplesDATA install-dvi: install-dvi-am install-dvi-am: install-exec-am: install-pkglibLTLIBRARIES install-html: install-html-am install-html-am: install-info: install-info-am install-info-am: install-man: install-pdf: install-pdf-am install-pdf-am: install-ps: install-ps-am install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-am -rm -f ./$(DEPDIR)/callbacks-example-baselinks.Plo -rm -f ./$(DEPDIR)/callbacks-example-changecontent.Plo -rm -f ./$(DEPDIR)/callbacks-example-contentfilter.Plo -rm -f ./$(DEPDIR)/callbacks-example-displayheader.Plo -rm -f ./$(DEPDIR)/callbacks-example-filename.Plo -rm -f ./$(DEPDIR)/callbacks-example-filename2.Plo -rm -f ./$(DEPDIR)/callbacks-example-filenameiisbug.Plo -rm -f ./$(DEPDIR)/callbacks-example-listlinks.Plo -rm -f ./$(DEPDIR)/callbacks-example-log.Plo -rm -f ./$(DEPDIR)/callbacks-example-simple.Plo -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am pdf-am: ps: ps-am ps-am: uninstall-am: uninstall-exemplesDATA uninstall-pkglibLTLIBRARIES .MAKE: install-am install-strip .PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-am clean \ clean-generic clean-libtool clean-pkglibLTLIBRARIES \ cscopelist-am ctags ctags-am distclean distclean-compile \ distclean-generic distclean-libtool distclean-tags distdir dvi \ dvi-am html html-am info info-am install install-am \ install-data install-data-am install-dvi install-dvi-am \ install-exec install-exec-am install-exemplesDATA install-html \ install-html-am install-info install-info-am install-man \ install-pdf install-pdf-am install-pkglibLTLIBRARIES \ install-ps install-ps-am install-strip installcheck \ installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-compile \ mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ tags tags-am uninstall uninstall-am uninstall-exemplesDATA \ uninstall-pkglibLTLIBRARIES .PRECIOUS: Makefile # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: httrack-3.49.5/libtest/Makefile.am0000644000175000017500000000521614360536104013705 00000000000000 exemplesdir = $(datadir)/httrack/libtest exemples_DATA = *.c *.h *.txt EXTRA_DIST = $(exemples_DATA) libtest.mak libtest.vcproj AM_CPPFLAGS = \ @DEFAULT_CFLAGS@ \ @THREADS_CFLAGS@ \ @V6_FLAG@ \ @LFS_FLAG@ \ -DPREFIX=\""$(prefix)"\" \ -DSYSCONFDIR=\""$(sysconfdir)"\" \ -DDATADIR=\""$(datadir)"\" \ -DLIBDIR=\""$(libdir)"\" AM_CPPFLAGS += -I../src AM_LDFLAGS = \ @DEFAULT_LDFLAGS@ \ -L../src # Examples libbaselinks_la_SOURCES = callbacks-example-baselinks.c libbaselinks_la_LIBADD = $(THREADS_LIBS) $(SOCKET_LIBS) $(top_builddir)/src/libhttrack.la libbaselinks_la_LDFLAGS = $(AM_LDFLAGS) -version-info 1:0:0 libchangecontent_la_SOURCES = callbacks-example-changecontent.c libchangecontent_la_LIBADD = $(THREADS_LIBS) $(SOCKET_LIBS) $(top_builddir)/src/libhttrack.la libchangecontent_la_LDFLAGS = $(AM_LDFLAGS) -version-info 1:0:0 libcontentfilter_la_SOURCES = callbacks-example-contentfilter.c libcontentfilter_la_LIBADD = $(THREADS_LIBS) $(SOCKET_LIBS) $(top_builddir)/src/libhttrack.la libcontentfilter_la_LDFLAGS = $(AM_LDFLAGS) -version-info 1:0:0 libdisplayheader_la_SOURCES = callbacks-example-displayheader.c libdisplayheader_la_LIBADD = $(THREADS_LIBS) $(SOCKET_LIBS) $(top_builddir)/src/libhttrack.la libdisplayheader_la_LDFLAGS = $(AM_LDFLAGS) -version-info 1:0:0 libfilename2_la_SOURCES = callbacks-example-filename2.c libfilename2_la_LIBADD = $(THREADS_LIBS) $(SOCKET_LIBS) $(top_builddir)/src/libhttrack.la libfilename2_la_LDFLAGS = $(AM_LDFLAGS) -version-info 1:0:0 libfilename_la_SOURCES = callbacks-example-filename.c libfilename_la_LIBADD = $(THREADS_LIBS) $(SOCKET_LIBS) $(top_builddir)/src/libhttrack.la libfilename_la_LDFLAGS = $(AM_LDFLAGS) -version-info 1:0:0 libfilenameiisbug_la_SOURCES = callbacks-example-filenameiisbug.c libfilenameiisbug_la_LIBADD = $(THREADS_LIBS) $(SOCKET_LIBS) $(top_builddir)/src/libhttrack.la libfilenameiisbug_la_LDFLAGS = $(AM_LDFLAGS) -version-info 1:0:0 liblistlinks_la_SOURCES = callbacks-example-listlinks.c liblistlinks_la_LIBADD = $(THREADS_LIBS) $(SOCKET_LIBS) $(top_builddir)/src/libhttrack.la liblistlinks_la_LDFLAGS = $(AM_LDFLAGS) -version-info 1:0:0 liblog_la_SOURCES = callbacks-example-log.c liblog_la_LIBADD = $(THREADS_LIBS) $(SOCKET_LIBS) $(top_builddir)/src/libhttrack.la liblog_la_LDFLAGS = $(AM_LDFLAGS) -version-info 1:0:0 libsimple_la_SOURCES = callbacks-example-simple.c libsimple_la_LIBADD = $(THREADS_LIBS) $(SOCKET_LIBS) $(top_builddir)/src/libhttrack.la libsimple_la_LDFLAGS = $(AM_LDFLAGS) -version-info 1:0:0 pkglib_LTLIBRARIES = libbaselinks.la libchangecontent.la libcontentfilter.la libdisplayheader.la libfilename2.la libfilename.la libfilenameiisbug.la liblistlinks.la liblog.la libsimple.la httrack-3.49.5/man/0000755000175000017500000000000014555203177011041 500000000000000httrack-3.49.5/man/proxytrack.10000644000175000017500000000421514336470674013260 00000000000000.\" Process this file with .\" groff -man -Tascii proxytrack.1 .\" .TH proxytrack 1 "Mar 2003" "httrack website copier" .SH NAME proxytrack \- proxy to serve content archived by httrack website copier .SH SYNOPSIS .B proxytrack proxy_address:proxy_port icp_address:icp_port [ httrack_cache_filename_1 [ httrack_cache_filename_2 .. ] ] .B .SH DESCRIPTION .B proxytrack this program allows you to create a proxy to deliver content already archived by .BR httrack (1) , a website copier. .SH EXAMPLES .TP .B proxytrack proxy:8080 localhost:3130 /home/archives/example.com/hts-cache/new.zip will launch the proxytrack proxy, listening to :8080, to deliver content archived in the /home/archives/example.com/hts-cache/new.zip cache .SH ENVIRONMENT .SH DIAGNOSTICS Errors/Warnings are reported the console and standard error .SH BUGS Please reports bugs to .B . Include a complete, self-contained example that will allow the bug to be reproduced, and say which version of (web)httrack you are using. Do not forget to detail options used, OS version, and any other information you deem necessary. .SH COPYRIGHT Copyright (C) 1998-2013 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . .SH AVAILABILITY The most recent released version of (web)httrack can be found at: .B http://www.httrack.com .SH AUTHOR Xavier Roche .SH "SEE ALSO" The .B HTML documentation (available online at .B http://www.httrack.com/html/ ) contains more detailed information. Please also refer to the .B httrack FAQ (available online at .B http://www.httrack.com/html/faq.html ) httrack-3.49.5/man/htsserver.10000644000175000017500000000420214336470674013073 00000000000000.\" Process this file with .\" groff -man -Tascii htsserver.1 .\" .TH htsserver 1 "Mar 2003" "httrack website copier" .SH NAME htsserver \- offline browser server : copy websites to a local directory .SH SYNOPSIS .B htsserver [ path/ ] [ keyword value [ keyword value .. ] ] .B .SH DESCRIPTION .B htsserver this program is a web frontend server to .BR httrack (1). , a website copier, used by .BR webhttrack (1). .SH EXAMPLES .TP .B htsserver /usr/share/httrack/ path "$HOME/websites" lang 1 then, browse http://localhost:8080/ .SH FILES .I /etc/httrack.conf .RS The system wide configuration file. .SH ENVIRONMENT .IP HOME Is being used if you defined in /etc/httrack.conf the line .I path ~/websites/# .SH DIAGNOSTICS Errors/Warnings are reported to .I hts-log.txt located in the destination directory. .SH BUGS Please reports bugs to .B . Include a complete, self-contained example that will allow the bug to be reproduced, and say which version of (web)httrack you are using. Do not forget to detail options used, OS version, and any other information you deem necessary. .SH COPYRIGHT Copyright (C) 1998-2013 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . .SH AVAILABILITY The most recent released version of (web)httrack can be found at: .B http://www.httrack.com .SH AUTHOR Xavier Roche .SH "SEE ALSO" The .B HTML documentation (available online at .B http://www.httrack.com/html/ ) contains more detailed information. Please also refer to the .B httrack FAQ (available online at .B http://www.httrack.com/html/faq.html ) httrack-3.49.5/man/webhttrack.10000644000175000017500000000422514336470674013211 00000000000000.\" Process this file with .\" groff -man -Tascii webhttrack.1 .\" .TH webhttrack 1 "Mar 2003" "httrack website copier" .SH NAME webhttrack \- offline browser : copy websites to a local directory .SH SYNOPSIS .B webhttrack [ keyword value [ keyword value .. ] ] .B .SH DESCRIPTION .B webhttrack this program is a script frontend to .BR httrack (1) and .BR htsserver (1) , a website copier. .SH EXAMPLES .TP .B webhttrack lang 1 will launch the webhttrack server frontend, and the default system browser, with "lang" set to "english" (language #1) .SH FILES .I /etc/httrack.conf .RS The system wide configuration file. .SH ENVIRONMENT .IP HOME Is being used if you defined in /etc/httrack.conf the line .I path ~/websites/# .SH DIAGNOSTICS Errors/Warnings are reported to .I hts-log.txt located in the destination directory. .SH BUGS Please reports bugs to .B . Include a complete, self-contained example that will allow the bug to be reproduced, and say which version of (web)httrack you are using. Do not forget to detail options used, OS version, and any other information you deem necessary. .SH COPYRIGHT Copyright (C) 1998-2013 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . .SH AVAILABILITY The most recent released version of (web)httrack can be found at: .B http://www.httrack.com .SH AUTHOR Xavier Roche .SH "SEE ALSO" The .B HTML documentation (available online at .B http://www.httrack.com/html/ ) contains more detailed information. Please also refer to the .B httrack FAQ (available online at .B http://www.httrack.com/html/faq.html ) httrack-3.49.5/man/httrack.10000644000175000017500000004702314555203113012477 00000000000000.\" Process this file with .\" groff -man -Tascii httrack.1 .\" .TH httrack 1 "27 January 2024" "httrack website copier" .SH NAME httrack \- offline browser : copy websites to a local directory .SH SYNOPSIS .B httrack [ url ]... [ \-filter ]... [ +filter ]... [ .B \-O, \-\-path ] [ .B \-w, \-\-mirror ] [ .B \-W, \-\-mirror\-wizard ] [ .B \-g, \-\-get\-files ] [ .B \-i, \-\-continue ] [ .B \-Y, \-\-mirrorlinks ] [ .B \-P, \-\-proxy ] [ .B \-%f, \-\-httpproxy\-ftp[=N] ] [ .B \-%b, \-\-bind ] [ .B \-rN, \-\-depth[=N] ] [ .B \-%eN, \-\-ext\-depth[=N] ] [ .B \-mN, \-\-max\-files[=N] ] [ .B \-MN, \-\-max\-size[=N] ] [ .B \-EN, \-\-max\-time[=N] ] [ .B \-AN, \-\-max\-rate[=N] ] [ .B \-%cN, \-\-connection\-per\-second[=N] ] [ .B \-GN, \-\-max\-pause[=N] ] [ .B \-cN, \-\-sockets[=N] ] [ .B \-TN, \-\-timeout[=N] ] [ .B \-RN, \-\-retries[=N] ] [ .B \-JN, \-\-min\-rate[=N] ] [ .B \-HN, \-\-host\-control[=N] ] [ .B \-%P, \-\-extended\-parsing[=N] ] [ .B \-n, \-\-near ] [ .B \-t, \-\-test ] [ .B \-%L, \-\-list ] [ .B \-%S, \-\-urllist ] [ .B \-NN, \-\-structure[=N] ] [ .B \-%D, \-\-cached\-delayed\-type\-check ] [ .B \-%M, \-\-mime\-html ] [ .B \-LN, \-\-long\-names[=N] ] [ .B \-KN, \-\-keep\-links[=N] ] [ .B \-x, \-\-replace\-external ] [ .B \-%x, \-\-disable\-passwords ] [ .B \-%q, \-\-include\-query\-string ] [ .B \-o, \-\-generate\-errors ] [ .B \-X, \-\-purge\-old[=N] ] [ .B \-%p, \-\-preserve ] [ .B \-%T, \-\-utf8\-conversion ] [ .B \-bN, \-\-cookies[=N] ] [ .B \-u, \-\-check\-type[=N] ] [ .B \-j, \-\-parse\-java[=N] ] [ .B \-sN, \-\-robots[=N] ] [ .B \-%h, \-\-http\-10 ] [ .B \-%k, \-\-keep\-alive ] [ .B \-%B, \-\-tolerant ] [ .B \-%s, \-\-updatehack ] [ .B \-%u, \-\-urlhack ] [ .B \-%A, \-\-assume ] [ .B \-@iN, \-\-protocol[=N] ] [ .B \-%w, \-\-disable\-module ] [ .B \-F, \-\-user\-agent ] [ .B \-%R, \-\-referer ] [ .B \-%E, \-\-from ] [ .B \-%F, \-\-footer ] [ .B \-%l, \-\-language ] [ .B \-%a, \-\-accept ] [ .B \-%X, \-\-headers ] [ .B \-C, \-\-cache[=N] ] [ .B \-k, \-\-store\-all\-in\-cache ] [ .B \-%n, \-\-do\-not\-recatch ] [ .B \-%v, \-\-display ] [ .B \-Q, \-\-do\-not\-log ] [ .B \-q, \-\-quiet ] [ .B \-z, \-\-extra\-log ] [ .B \-Z, \-\-debug\-log ] [ .B \-v, \-\-verbose ] [ .B \-f, \-\-file\-log ] [ .B \-f2, \-\-single\-log ] [ .B \-I, \-\-index ] [ .B \-%i, \-\-build\-top\-index ] [ .B \-%I, \-\-search\-index ] [ .B \-pN, \-\-priority[=N] ] [ .B \-S, \-\-stay\-on\-same\-dir ] [ .B \-D, \-\-can\-go\-down ] [ .B \-U, \-\-can\-go\-up ] [ .B \-B, \-\-can\-go\-up\-and\-down ] [ .B \-a, \-\-stay\-on\-same\-address ] [ .B \-d, \-\-stay\-on\-same\-domain ] [ .B \-l, \-\-stay\-on\-same\-tld ] [ .B \-e, \-\-go\-everywhere ] [ .B \-%H, \-\-debug\-headers ] [ .B \-%!, \-\-disable\-security\-limits ] [ .B \-V, \-\-userdef\-cmd ] [ .B \-%W, \-\-callback ] [ .B \-K, \-\-keep\-links[=N] ] [ .B .SH DESCRIPTION .B httrack allows you to download a World Wide Web site from the Internet to a local directory, building recursively all directories, getting HTML, images, and other files from the server to your computer. HTTrack arranges the original site's relative link-structure. Simply open a page of the "mirrored" website in your browser, and you can browse the site from link to link, as if you were viewing it online. HTTrack can also update an existing mirrored site, and resume interrupted downloads. .SH EXAMPLES .TP .B httrack www.someweb.com/bob/ mirror site www.someweb.com/bob/ and only this site .TP .B httrack www.someweb.com/bob/ www.anothertest.com/mike/ +*.com/*.jpg \-mime:application/* mirror the two sites together (with shared links) and accept any .jpg files on .com sites .TP .B httrack www.someweb.com/bob/bobby.html +* \-r6 means get all files starting from bobby.html, with 6 link\-depth, and possibility of going everywhere on the web .TP .B httrack www.someweb.com/bob/bobby.html \-\-spider \-P proxy.myhost.com:8080 runs the spider on www.someweb.com/bob/bobby.html using a proxy .TP .B httrack \-\-update updates a mirror in the current folder .TP .B httrack will bring you to the interactive mode .TP .B httrack \-\-continue continues a mirror in the current folder .SH OPTIONS .SS General options: .IP \-O path for mirror/logfiles+cache (\-O path mirror[,path cache and logfiles]) (\-\-path ) .SS Action options: .IP \-w *mirror web sites (\-\-mirror) .IP \-W mirror web sites, semi\-automatic (asks questions) (\-\-mirror\-wizard) .IP \-g just get files (saved in the current directory) (\-\-get\-files) .IP \-i continue an interrupted mirror using the cache (\-\-continue) .IP \-Y mirror ALL links located in the first level pages (mirror links) (\-\-mirrorlinks) .SS Proxy options: .IP \-P proxy use (\-P proxy:port or \-P user:pass@proxy:port) (\-\-proxy ) .IP \-%f *use proxy for ftp (f0 don t use) (\-\-httpproxy\-ftp[=N]) .IP \-%b use this local hostname to make/send requests (\-%b hostname) (\-\-bind ) .SS Limits options: .IP \-rN set the mirror depth to N (* r9999) (\-\-depth[=N]) .IP \-%eN set the external links depth to N (* %e0) (\-\-ext\-depth[=N]) .IP \-mN maximum file length for a non\-html file (\-\-max\-files[=N]) .IP \-mN,N2 maximum file length for non html (N) and html (N2) .IP \-MN maximum overall size that can be uploaded/scanned (\-\-max\-size[=N]) .IP \-EN maximum mirror time in seconds (60=1 minute, 3600=1 hour) (\-\-max\-time[=N]) .IP \-AN maximum transfer rate in bytes/seconds (1000=1KB/s max) (\-\-max\-rate[=N]) .IP \-%cN maximum number of connections/seconds (*%c10) (\-\-connection\-per\-second[=N]) .IP \-GN pause transfer if N bytes reached, and wait until lock file is deleted (\-\-max\-pause[=N]) .SS Flow control: .IP \-cN number of multiple connections (*c8) (\-\-sockets[=N]) .IP \-TN timeout, number of seconds after a non\-responding link is shutdown (\-\-timeout[=N]) .IP \-RN number of retries, in case of timeout or non\-fatal errors (*R1) (\-\-retries[=N]) .IP \-JN traffic jam control, minimum transfert rate (bytes/seconds) tolerated for a link (\-\-min\-rate[=N]) .IP \-HN host is abandoned if: 0=never, 1=timeout, 2=slow, 3=timeout or slow (\-\-host\-control[=N]) .SS Links options: .IP \-%P *extended parsing, attempt to parse all links, even in unknown tags or Javascript (%P0 don t use) (\-\-extended\-parsing[=N]) .IP \-n get non\-html files near an html file (ex: an image located outside) (\-\-near) .IP \-t test all URLs (even forbidden ones) (\-\-test) .IP \-%L add all URL located in this text file (one URL per line) (\-\-list ) .IP \-%S add all scan rules located in this text file (one scan rule per line) (\-\-urllist ) .SS Build options: .IP \-NN structure type (0 *original structure, 1+: see below) (\-\-structure[=N]) .IP \-or user defined structure (\-N "%h%p/%n%q.%t") .IP \-%N delayed type check, don t make any link test but wait for files download to start instead (experimental) (%N0 don t use, %N1 use for unknown extensions, * %N2 always use) .IP \-%D cached delayed type check, don t wait for remote type during updates, to speedup them (%D0 wait, * %D1 don t wait) (\-\-cached\-delayed\-type\-check) .IP \-%M generate a RFC MIME\-encapsulated full\-archive (.mht) (\-\-mime\-html) .IP \-LN long names (L1 *long names / L0 8\-3 conversion / L2 ISO9660 compatible) (\-\-long\-names[=N]) .IP \-KN keep original links (e.g. http://www.adr/link) (K0 *relative link, K absolute links, K4 original links, K3 absolute URI links, K5 transparent proxy link) (\-\-keep\-links[=N]) .IP \-x replace external html links by error pages (\-\-replace\-external) .IP \-%x do not include any password for external password protected websites (%x0 include) (\-\-disable\-passwords) .IP \-%q *include query string for local files (useless, for information purpose only) (%q0 don t include) (\-\-include\-query\-string) .IP \-o *generate output html file in case of error (404..) (o0 don t generate) (\-\-generate\-errors) .IP \-X *purge old files after update (X0 keep delete) (\-\-purge\-old[=N]) .IP \-%p preserve html files as is (identical to \-K4 \-%F "" ) (\-\-preserve) .IP \-%T links conversion to UTF\-8 (\-\-utf8\-conversion) .SS Spider options: .IP \-bN accept cookies in cookies.txt (0=do not accept,* 1=accept) (\-\-cookies[=N]) .IP \-u check document type if unknown (cgi,asp..) (u0 don t check, * u1 check but /, u2 check always) (\-\-check\-type[=N]) .IP \-j *parse Java Classes (j0 don t parse, bitmask: |1 parse default, |2 don t parse .class |4 don t parse .js |8 don t be aggressive) (\-\-parse\-java[=N]) .IP \-sN follow robots.txt and meta robots tags (0=never,1=sometimes,* 2=always, 3=always (even strict rules)) (\-\-robots[=N]) .IP \-%h force HTTP/1.0 requests (reduce update features, only for old servers or proxies) (\-\-http\-10) .IP \-%k use keep\-alive if possible, greately reducing latency for small files and test requests (%k0 don t use) (\-\-keep\-alive) .IP \-%B tolerant requests (accept bogus responses on some servers, but not standard!) (\-\-tolerant) .IP \-%s update hacks: various hacks to limit re\-transfers when updating (identical size, bogus response..) (\-\-updatehack) .IP \-%u url hacks: various hacks to limit duplicate URLs (strip //, www.foo.com==foo.com..) (\-\-urlhack) .IP \-%A assume that a type (cgi,asp..) is always linked with a mime type (\-%A php3,cgi=text/html;dat,bin=application/x\-zip) (\-\-assume ) .IP \-can also be used to force a specific file type: \-\-assume foo.cgi=text/html .IP \-@iN internet protocol (0=both ipv6+ipv4, 4=ipv4 only, 6=ipv6 only) (\-\-protocol[=N]) .IP \-%w disable a specific external mime module (\-%w htsswf \-%w htsjava) (\-\-disable\-module ) .SS Browser ID: .IP \-F user\-agent field sent in HTTP headers (\-F "user\-agent name") (\-\-user\-agent ) .IP \-%R default referer field sent in HTTP headers (\-\-referer ) .IP \-%E from email address sent in HTTP headers (\-\-from ) .IP \-%F footer string in Html code (\-%F "Mirrored [from host %s [file %s [at %s]]]" (\-\-footer ) .IP \-%l preffered language (\-%l "fr, en, jp, *" (\-\-language ) .IP \-%a accepted formats (\-%a "text/html,image/png;q=0.9,*/*;q=0.1" (\-\-accept ) .IP \-%X additional HTTP header line (\-%X "X\-Magic: 42" (\-\-headers ) .SS Log, index, cache .IP \-C create/use a cache for updates and retries (C0 no cache,C1 cache is prioritary,* C2 test update before) (\-\-cache[=N]) .IP \-k store all files in cache (not useful if files on disk) (\-\-store\-all\-in\-cache) .IP \-%n do not re\-download locally erased files (\-\-do\-not\-recatch) .IP \-%v display on screen filenames downloaded (in realtime) \- * %v1 short version \- %v2 full animation (\-\-display) .IP \-Q no log \- quiet mode (\-\-do\-not\-log) .IP \-q no questions \- quiet mode (\-\-quiet) .IP \-z log \- extra infos (\-\-extra\-log) .IP \-Z log \- debug (\-\-debug\-log) .IP \-v log on screen (\-\-verbose) .IP \-f *log in files (\-\-file\-log) .IP \-f2 one single log file (\-\-single\-log) .IP \-I *make an index (I0 don t make) (\-\-index) .IP \-%i make a top index for a project folder (* %i0 don t make) (\-\-build\-top\-index) .IP \-%I make an searchable index for this mirror (* %I0 don t make) (\-\-search\-index) .SS Expert options: .IP \-pN priority mode: (* p3) (\-\-priority[=N]) .IP \-p0 just scan, don t save anything (for checking links) .IP \-p1 save only html files .IP \-p2 save only non html files .IP \-*p3 save all files .IP \-p7 get html files before, then treat other files .IP \-S stay on the same directory (\-\-stay\-on\-same\-dir) .IP \-D *can only go down into subdirs (\-\-can\-go\-down) .IP \-U can only go to upper directories (\-\-can\-go\-up) .IP \-B can both go up&down into the directory structure (\-\-can\-go\-up\-and\-down) .IP \-a *stay on the same address (\-\-stay\-on\-same\-address) .IP \-d stay on the same principal domain (\-\-stay\-on\-same\-domain) .IP \-l stay on the same TLD (eg: .com) (\-\-stay\-on\-same\-tld) .IP \-e go everywhere on the web (\-\-go\-everywhere) .IP \-%H debug HTTP headers in logfile (\-\-debug\-headers) .SS Guru options: (do NOT use if possible) .IP \-#X *use optimized engine (limited memory boundary checks) (\-\-fast\-engine) .IP \-#0 filter test (\-#0 *.gif www.bar.com/foo.gif ) (\-\-debug\-testfilters ) .IP \-#1 simplify test (\-#1 ./foo/bar/../foobar) .IP \-#2 type test (\-#2 /foo/bar.php) .IP \-#C cache list (\-#C *.com/spider*.gif (\-\-debug\-cache ) .IP \-#R cache repair (damaged cache) (\-\-repair\-cache) .IP \-#d debug parser (\-\-debug\-parsing) .IP \-#E extract new.zip cache meta\-data in meta.zip .IP \-#f always flush log files (\-\-advanced\-flushlogs) .IP \-#FN maximum number of filters (\-\-advanced\-maxfilters[=N]) .IP \-#h version info (\-\-version) .IP \-#K scan stdin (debug) (\-\-debug\-scanstdin) .IP \-#L maximum number of links (\-#L1000000) (\-\-advanced\-maxlinks[=N]) .IP \-#p display ugly progress information (\-\-advanced\-progressinfo) .IP \-#P catch URL (\-\-catch\-url) .IP \-#R old FTP routines (debug) (\-\-repair\-cache) .IP \-#T generate transfer ops. log every minutes (\-\-debug\-xfrstats) .IP \-#u wait time (\-\-advanced\-wait) .IP \-#Z generate transfer rate statistics every minutes (\-\-debug\-ratestats) .SS Dangerous options: (do NOT use unless you exactly know what you are doing) .IP \-%! bypass built\-in security limits aimed to avoid bandwidth abuses (bandwidth, simultaneous connections) (\-\-disable\-security\-limits) .IP \-IMPORTANT NOTE: DANGEROUS OPTION, ONLY SUITABLE FOR EXPERTS .IP \-USE IT WITH EXTREME CARE .SS Command\-line specific options: .IP \-V execute system command after each files ($0 is the filename: \-V "rm \\$0") (\-\-userdef\-cmd ) .IP \-%W use an external library function as a wrapper (\-%W myfoo.so[,myparameters]) (\-\-callback ) .SS Details: Option N .IP \-N0 Site\-structure (default) .IP \-N1 HTML in web/, images/other files in web/images/ .IP \-N2 HTML in web/HTML, images/other in web/images .IP \-N3 HTML in web/, images/other in web/ .IP \-N4 HTML in web/, images/other in web/xxx, where xxx is the file extension (all gif will be placed onto web/gif, for example) .IP \-N5 Images/other in web/xxx and HTML in web/HTML .IP \-N99 All files in web/, with random names (gadget !) .IP \-N100 Site\-structure, without www.domain.xxx/ .IP \-N101 Identical to N1 except that "web" is replaced by the site s name .IP \-N102 Identical to N2 except that "web" is replaced by the site s name .IP \-N103 Identical to N3 except that "web" is replaced by the site s name .IP \-N104 Identical to N4 except that "web" is replaced by the site s name .IP \-N105 Identical to N5 except that "web" is replaced by the site s name .IP \-N199 Identical to N99 except that "web" is replaced by the site s name .IP \-N1001 Identical to N1 except that there is no "web" directory .IP \-N1002 Identical to N2 except that there is no "web" directory .IP \-N1003 Identical to N3 except that there is no "web" directory (option set for g option) .IP \-N1004 Identical to N4 except that there is no "web" directory .IP \-N1005 Identical to N5 except that there is no "web" directory .IP \-N1099 Identical to N99 except that there is no "web" directory .SS Details: User\-defined option N %n Name of file without file type (ex: image) %N Name of file, including file type (ex: image.gif) %t File type (ex: gif) %p Path [without ending /] (ex: /someimages) %h Host name (ex: www.someweb.com) %M URL MD5 (128 bits, 32 ascii bytes) %Q query string MD5 (128 bits, 32 ascii bytes) %k full query string %r protocol name (ex: http) %q small query string MD5 (16 bits, 4 ascii bytes) %s? Short name version (ex: %sN) %[param] param variable in query string %[param:before:after:empty:notfound] advanced variable extraction .SS Details: User\-defined option N and advanced variable extraction %[param:before:after:empty:notfound] .IP \-param : parameter name .IP \-before : string to prepend if the parameter was found .IP \-after : string to append if the parameter was found .IP \-notfound : string replacement if the parameter could not be found .IP \-empty : string replacement if the parameter was empty .IP \-all fields, except the first one (the parameter name), can be empty .SS Details: Option K .IP \-K0 foo.cgi?q=45 \-> foo4B54.html?q=45 (relative URI, default) .IP \-K \-> http://www.foobar.com/folder/foo.cgi?q=45 (absolute URL) (\-\-keep\-links[=N]) .IP \-K3 \-> /folder/foo.cgi?q=45 (absolute URI) .IP \-K4 \-> foo.cgi?q=45 (original URL) .IP \-K5 \-> http://www.foobar.com/folder/foo4B54.html?q=45 (transparent proxy URL) .SS Shortcuts: .IP \-\-mirror *make a mirror of site(s) (default) .IP \-\-get get the files indicated, do not seek other URLs (\-qg) .IP \-\-list add all URL located in this text file (\-%L) .IP \-\-mirrorlinks mirror all links in 1st level pages (\-Y) .IP \-\-testlinks test links in pages (\-r1p0C0I0t) .IP \-\-spider spider site(s), to test links: reports Errors & Warnings (\-p0C0I0t) .IP \-\-testsite identical to \-\-spider .IP \-\-skeleton make a mirror, but gets only html files (\-p1) .IP \-\-update update a mirror, without confirmation (\-iC2) .IP \-\-continue continue a mirror, without confirmation (\-iC1) .IP \-\-catchurl create a temporary proxy to capture an URL or a form post URL .IP \-\-clean erase cache & log files .IP \-\-http10 force http/1.0 requests (\-%h) .SS Details: Option %W: External callbacks prototypes .SS see htsdefines.h .SH FILES .I /etc/httrack.conf .RS The system wide configuration file. .SH ENVIRONMENT .IP HOME Is being used if you defined in /etc/httrack.conf the line .I path ~/websites/# .SH DIAGNOSTICS Errors/Warnings are reported to .I hts\-log.txt by default, or to stderr if the .I -v option was specified. .SH LIMITS These are the principals limits of HTTrack for that moment. Note that we did not heard about any other utility that would have solved them. .SM - Several scripts generating complex filenames may not find them (ex: img.src='image'+a+Mobj.dst+'.gif') .SM - Some java classes may not find some files on them (class included) .SM - Cgi-bin links may not work properly in some cases (parameters needed). To avoid them: use filters like -*cgi-bin* .SH BUGS Please reports bugs to .B . Include a complete, self-contained example that will allow the bug to be reproduced, and say which version of httrack you are using. Do not forget to detail options used, OS version, and any other information you deem necessary. .SH COPYRIGHT Copyright (C) 1998-2024 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . .SH AVAILABILITY The most recent released version of httrack can be found at: .B http://www.httrack.com .SH AUTHOR Xavier Roche .SH "SEE ALSO" The .B HTML documentation (available online at .B http://www.httrack.com/html/ ) contains more detailed information. Please also refer to the .B httrack FAQ (available online at .B http://www.httrack.com/html/faq.html ) httrack-3.49.5/man/Makefile.in0000644000175000017500000003724214555203173013032 00000000000000# Makefile.in generated by automake 1.16.5 from Makefile.am. # @configure_input@ # Copyright (C) 1994-2021 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ VPATH = @srcdir@ am__is_gnu_make = { \ if test -z '$(MAKELEVEL)'; then \ false; \ elif test -n '$(MAKE_HOST)'; then \ true; \ elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ true; \ else \ false; \ fi; \ } am__make_running_with_option = \ case $${target_option-} in \ ?) ;; \ *) echo "am__make_running_with_option: internal error: invalid" \ "target option '$${target_option-}' specified" >&2; \ exit 1;; \ esac; \ has_opt=no; \ sane_makeflags=$$MAKEFLAGS; \ if $(am__is_gnu_make); then \ sane_makeflags=$$MFLAGS; \ else \ case $$MAKEFLAGS in \ *\\[\ \ ]*) \ bs=\\; \ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ esac; \ fi; \ skip_next=no; \ strip_trailopt () \ { \ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ }; \ for flg in $$sane_makeflags; do \ test $$skip_next = yes && { skip_next=no; continue; }; \ case $$flg in \ *=*|--*) continue;; \ -*I) strip_trailopt 'I'; skip_next=yes;; \ -*I?*) strip_trailopt 'I';; \ -*O) strip_trailopt 'O'; skip_next=yes;; \ -*O?*) strip_trailopt 'O';; \ -*l) strip_trailopt 'l'; skip_next=yes;; \ -*l?*) strip_trailopt 'l';; \ -[dEDm]) skip_next=yes;; \ -[JT]) skip_next=yes;; \ esac; \ case $$flg in \ *$$target_option*) has_opt=yes; break;; \ esac; \ done; \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkglibexecdir = $(libexecdir)/@PACKAGE@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ subdir = man ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/check_zlib.m4 \ $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/snprintf.m4 \ $(top_srcdir)/m4/visibility.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = AM_V_P = $(am__v_P_@AM_V@) am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) am__v_P_0 = false am__v_P_1 = : AM_V_GEN = $(am__v_GEN_@AM_V@) am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) am__v_GEN_0 = @echo " GEN " $@; am__v_GEN_1 = AM_V_at = $(am__v_at_@AM_V@) am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) am__v_at_0 = @ am__v_at_1 = SOURCES = DIST_SOURCES = am__can_run_installinfo = \ case $$AM_UPDATE_INFO_DIR in \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ *) f=$$p;; \ esac; am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; am__install_max = 40 am__nobase_strip_setup = \ srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` am__nobase_strip = \ for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" am__nobase_list = $(am__nobase_strip_setup); \ for p in $$list; do echo "$$p $$p"; done | \ sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ if (++n[$$2] == $(am__install_max)) \ { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ END { for (dir in files) print dir, files[dir] }' am__base_list = \ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' am__uninstall_files_from_dir = { \ test -z "$$files" \ || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ $(am__cd) "$$dir" && rm -f $$files; }; \ } man1dir = $(mandir)/man1 am__installdirs = "$(DESTDIR)$(man1dir)" NROFF = nroff MANS = $(man_MANS) am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) am__DIST_COMMON = $(srcdir)/Makefile.in DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AM_CFLAGS = @AM_CFLAGS@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CFLAGS_PIE = @CFLAGS_PIE@ CFLAG_VISIBILITY = @CFLAG_VISIBILITY@ CPPFLAGS = @CPPFLAGS@ CSCOPE = @CSCOPE@ CTAGS = @CTAGS@ CYGPATH_W = @CYGPATH_W@ DEFAULT_CFLAGS = @DEFAULT_CFLAGS@ DEFAULT_LDFLAGS = @DEFAULT_LDFLAGS@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DLLTOOL = @DLLTOOL@ DL_LIBS = @DL_LIBS@ DSYMUTIL = @DSYMUTIL@ DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ ETAGS = @ETAGS@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ FILECMD = @FILECMD@ GREP = @GREP@ HAVE_VISIBILITY = @HAVE_VISIBILITY@ HTTPS_SUPPORT = @HTTPS_SUPPORT@ ICONV_LIBS = @ICONV_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LD = @LD@ LDFLAGS = @LDFLAGS@ LDFLAGS_PIE = @LDFLAGS_PIE@ LFS_FLAG = @LFS_FLAG@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ LIPO = @LIPO@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ LT_CV_OBJDIR = @LT_CV_OBJDIR@ LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ MAINT = @MAINT@ MAKEINFO = @MAKEINFO@ MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ NM = @NM@ NMEDIT = @NMEDIT@ OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ ONLINE_UNIT_TESTS = @ONLINE_UNIT_TESTS@ OPENSSL_LIBS = @OPENSSL_LIBS@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ RANLIB = @RANLIB@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ SHLIBPATH_VAR = @SHLIBPATH_VAR@ SOCKET_LIBS = @SOCKET_LIBS@ STRIP = @STRIP@ THREADS_CFLAGS = @THREADS_CFLAGS@ THREADS_LIBS = @THREADS_LIBS@ V6_FLAG = @V6_FLAG@ VERSION = @VERSION@ VERSION_INFO = @VERSION_INFO@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ builddir = @builddir@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ runstatedir = @runstatedir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ # man_MANS = httrack.1 man_MANS = httrack.1 webhttrack.1 htsserver.1 proxytrack.1 EXTRA_DIST = $(man_MANS) all: all-am .SUFFIXES: $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ && { if test -f $@; then exit 0; else break; fi; }; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu man/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --gnu man/Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(am__aclocal_m4_deps): mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs install-man1: $(man_MANS) @$(NORMAL_INSTALL) @list1=''; \ list2='$(man_MANS)'; \ test -n "$(man1dir)" \ && test -n "`echo $$list1$$list2`" \ || exit 0; \ echo " $(MKDIR_P) '$(DESTDIR)$(man1dir)'"; \ $(MKDIR_P) "$(DESTDIR)$(man1dir)" || exit 1; \ { for i in $$list1; do echo "$$i"; done; \ if test -n "$$list2"; then \ for i in $$list2; do echo "$$i"; done \ | sed -n '/\.1[a-z]*$$/p'; \ fi; \ } | while read p; do \ if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; echo "$$p"; \ done | \ sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \ sed 'N;N;s,\n, ,g' | { \ list=; while read file base inst; do \ if test "$$base" = "$$inst"; then list="$$list $$file"; else \ echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man1dir)/$$inst'"; \ $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man1dir)/$$inst" || exit $$?; \ fi; \ done; \ for i in $$list; do echo "$$i"; done | $(am__base_list) | \ while read files; do \ test -z "$$files" || { \ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man1dir)'"; \ $(INSTALL_DATA) $$files "$(DESTDIR)$(man1dir)" || exit $$?; }; \ done; } uninstall-man1: @$(NORMAL_UNINSTALL) @list=''; test -n "$(man1dir)" || exit 0; \ files=`{ for i in $$list; do echo "$$i"; done; \ l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ sed -n '/\.1[a-z]*$$/p'; \ } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ dir='$(DESTDIR)$(man1dir)'; $(am__uninstall_files_from_dir) tags TAGS: ctags CTAGS: cscope cscopelist: distdir: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) distdir-am distdir-am: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ dist_files=`for file in $$list; do echo $$file; done | \ sed -e "s|^$$srcdirstrip/||;t" \ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ case $$dist_files in \ */*) $(MKDIR_P) `echo "$$dist_files" | \ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ sort -u` ;; \ esac; \ for file in $$dist_files; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ if test -d $$d/$$file; then \ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ if test -d "$(distdir)/$$file"; then \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ else \ test -f "$(distdir)/$$file" \ || cp -p $$d/$$file "$(distdir)/$$file" \ || exit 1; \ fi; \ done check-am: all-am check: check-am all-am: Makefile $(MANS) installdirs: for dir in "$(DESTDIR)$(man1dir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-am install-strip: if test -z '$(STRIP)'; then \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ install; \ else \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ fi mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-generic clean-libtool mostlyclean-am distclean: distclean-am -rm -f Makefile distclean-am: clean-am distclean-generic dvi: dvi-am dvi-am: html: html-am html-am: info: info-am info-am: install-data-am: install-man install-dvi: install-dvi-am install-dvi-am: install-exec-am: install-html: install-html-am install-html-am: install-info: install-info-am install-info-am: install-man: install-man1 install-pdf: install-pdf-am install-pdf-am: install-ps: install-ps-am install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-am -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-generic mostlyclean-libtool pdf: pdf-am pdf-am: ps: ps-am ps-am: uninstall-am: uninstall-man uninstall-man: uninstall-man1 .MAKE: install-am install-strip .PHONY: all all-am check check-am clean clean-generic clean-libtool \ cscopelist-am ctags-am distclean distclean-generic \ distclean-libtool distdir dvi dvi-am html html-am info info-am \ install install-am install-data install-data-am install-dvi \ install-dvi-am install-exec install-exec-am install-html \ install-html-am install-info install-info-am install-man \ install-man1 install-pdf install-pdf-am install-ps \ install-ps-am install-strip installcheck installcheck-am \ installdirs maintainer-clean maintainer-clean-generic \ mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \ ps ps-am tags-am uninstall uninstall-am uninstall-man \ uninstall-man1 .PRECIOUS: Makefile # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: httrack-3.49.5/man/Makefile.am0000644000175000017500000000015514336470674013023 00000000000000 # man_MANS = httrack.1 man_MANS = httrack.1 webhttrack.1 htsserver.1 proxytrack.1 EXTRA_DIST = $(man_MANS) httrack-3.49.5/src/0000755000175000017500000000000014555203177011055 500000000000000httrack-3.49.5/src/webhttrack.vcproj0000644000175000017500000002606014336470674014371 00000000000000 httrack-3.49.5/src/libhttrack.vcproj0000644000175000017500000014027714336470674014371 00000000000000 httrack-3.49.5/src/httrack.vcproj0000644000175000017500000004204314336470674013672 00000000000000 httrack-3.49.5/src/htsjava.vcproj0000644000175000017500000002061614336470674013674 00000000000000 httrack-3.49.5/src/webhttrack.dsp0000644000175000017500000001110314336470674013644 00000000000000# Microsoft Developer Studio Project File - Name="webhttrack" - Package Owner=<4> # Microsoft Developer Studio Generated Build File, Format Version 6.00 # ** DO NOT EDIT ** # TARGTYPE "Win32 (x86) Console Application" 0x0103 CFG=webhttrack - Win32 Debug !MESSAGE This is not a valid makefile. To build this project using NMAKE, !MESSAGE use the Export Makefile command and run !MESSAGE !MESSAGE NMAKE /f "webhttrack.mak". !MESSAGE !MESSAGE You can specify a configuration when running NMAKE !MESSAGE by defining the macro CFG on the command line. For example: !MESSAGE !MESSAGE NMAKE /f "webhttrack.mak" CFG="webhttrack - Win32 Debug" !MESSAGE !MESSAGE Possible choices for configuration are: !MESSAGE !MESSAGE "webhttrack - Win32 Release" (based on "Win32 (x86) Console Application") !MESSAGE "webhttrack - Win32 Debug" (based on "Win32 (x86) Console Application") !MESSAGE # Begin Project # PROP AllowPerConfigDependencies 0 # PROP Scc_ProjName "" # PROP Scc_LocalPath "" CPP=cl.exe RSC=rc.exe !IF "$(CFG)" == "webhttrack - Win32 Release" # PROP BASE Use_MFC 0 # PROP BASE Use_Debug_Libraries 0 # PROP BASE Output_Dir "Release" # PROP BASE Intermediate_Dir "Release" # PROP BASE Target_Dir "" # PROP Use_MFC 0 # PROP Use_Debug_Libraries 0 # PROP Output_Dir "Release" # PROP Intermediate_Dir "Release" # PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /Yu"stdafx.h" /FD /c # ADD CPP /nologo /MD /W3 /GX /O2 /I "C:\Dev\\" /I "C:\Dev\IPv6Kit\inc\\" /I "C:\Dev\zlib\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FR /FD /c # SUBTRACT CPP /YX /Yc /Yu # ADD BASE RSC /l 0x40c /d "NDEBUG" # ADD RSC /l 0x40c /d "NDEBUG" BSC32=bscmake.exe # ADD BASE BSC32 /nologo # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386 # ADD LINK32 wsock32.lib libhttrack.lib /nologo /subsystem:console /pdb:none /machine:I386 /force /out:"L:\HTTrack\httrack\webhttrack.exe" /libpath:"C:\Dev\openssl\lib" /libpath:"C:\Dev\zlib\dll32" /libpath:"C:\Dev\openssl\lib\out32dll" /libpath:"C:\temp\Releaselib" !ELSEIF "$(CFG)" == "webhttrack - Win32 Debug" # PROP BASE Use_MFC 0 # PROP BASE Use_Debug_Libraries 1 # PROP BASE Output_Dir "Debug" # PROP BASE Intermediate_Dir "Debug" # PROP BASE Target_Dir "" # PROP Use_MFC 0 # PROP Use_Debug_Libraries 1 # PROP Output_Dir "Debug" # PROP Intermediate_Dir "Debug" # PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /Yu"stdafx.h" /FD /GZ /c # ADD CPP /nologo /MDd /W3 /Gm /GR /GX /ZI /Od /I "C:\Dev\\" /I "C:\Dev\IPv6Kit\inc\\" /I "C:\Dev\zlib\\" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FAcs /FR /FD /GZ /c # SUBTRACT CPP /YX /Yc /Yu # ADD BASE RSC /l 0x40c /d "_DEBUG" # ADD RSC /l 0x40c /d "_DEBUG" BSC32=bscmake.exe # ADD BASE BSC32 /nologo # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept # ADD LINK32 wsock32.lib libhttrack.lib /nologo /subsystem:console /debug /machine:I386 /out:"C:\temp\webhttrack.exe" /pdbtype:sept /libpath:"C:\Dev\openssl\lib" /libpath:"C:\Dev\zlib\dll32" /libpath:"C:\Dev\openssl\lib\out32dll" /libpath:"C:\temp\Releaselib" !ENDIF # Begin Target # Name "webhttrack - Win32 Release" # Name "webhttrack - Win32 Debug" # Begin Group "Source Files" # PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" # Begin Source File SOURCE=.\htsserver.c # End Source File # Begin Source File SOURCE=.\htsweb.c # End Source File # End Group # Begin Group "Header Files" # PROP Default_Filter "h;hpp;hxx;hm;inl" # Begin Source File SOURCE=.\htsserver.h # End Source File # Begin Source File SOURCE=.\htsweb.h # End Source File # End Group # Begin Group "Resource Files" # PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe" # End Group # Begin Source File SOURCE=.\ReadMe.txt # End Source File # End Target # End Project httrack-3.49.5/src/libhttrack.dsp0000644000175000017500000002046514336470674013650 00000000000000# Microsoft Developer Studio Project File - Name="libhttrack" - Package Owner=<4> # Microsoft Developer Studio Generated Build File, Format Version 6.00 # ** DO NOT EDIT ** # TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102 CFG=libhttrack - Win32 Debug !MESSAGE This is not a valid makefile. To build this project using NMAKE, !MESSAGE use the Export Makefile command and run !MESSAGE !MESSAGE NMAKE /f "libhttrack.mak". !MESSAGE !MESSAGE You can specify a configuration when running NMAKE !MESSAGE by defining the macro CFG on the command line. For example: !MESSAGE !MESSAGE NMAKE /f "libhttrack.mak" CFG="libhttrack - Win32 Debug" !MESSAGE !MESSAGE Possible choices for configuration are: !MESSAGE !MESSAGE "libhttrack - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library") !MESSAGE "libhttrack - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library") !MESSAGE # Begin Project # PROP AllowPerConfigDependencies 0 # PROP Scc_ProjName "" # PROP Scc_LocalPath "" CPP=cl.exe MTL=midl.exe RSC=rc.exe !IF "$(CFG)" == "libhttrack - Win32 Release" # PROP BASE Use_MFC 0 # PROP BASE Use_Debug_Libraries 0 # PROP BASE Output_Dir "Release" # PROP BASE Intermediate_Dir "Release" # PROP BASE Target_Dir "" # PROP Use_MFC 0 # PROP Use_Debug_Libraries 0 # PROP Output_Dir "C:\temp\Releaselib" # PROP Intermediate_Dir "C:\temp\Releaselib" # PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LIBHTTRACK_EXPORTS" /Yu"stdafx.h" /FD /c # ADD CPP /nologo /MD /W3 /GX /O2 /Ob2 /I "C:\Dev\IPv6Kit\inc" /I "C:\Dev\zlib\include" /D "NDEBUG" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LIBHTTRACK_EXPORTS" /D "ZLIB_DLL" /FD /c # SUBTRACT CPP /YX /Yc /Yu # ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32 # ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32 # ADD BASE RSC /l 0x40c /d "NDEBUG" # ADD RSC /l 0x40c /d "NDEBUG" BSC32=bscmake.exe # ADD BASE BSC32 /nologo # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 # ADD LINK32 wsock32.lib zdll.lib /nologo /dll /map /machine:I386 /out:"L:\HTTrack\httrack\libhttrack.dll" /libpath:"C:\Dev\zlib\lib" # SUBTRACT LINK32 /pdb:none !ELSEIF "$(CFG)" == "libhttrack - Win32 Debug" # PROP BASE Use_MFC 0 # PROP BASE Use_Debug_Libraries 1 # PROP BASE Output_Dir "Debug" # PROP BASE Intermediate_Dir "Debug" # PROP BASE Target_Dir "" # PROP Use_MFC 0 # PROP Use_Debug_Libraries 1 # PROP Output_Dir "C:\temp\Debuglib" # PROP Intermediate_Dir "C:\temp\Debuglib" # PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LIBHTTRACK_EXPORTS" /Yu"stdafx.h" /FD /GZ /c # ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "C:\Dev\IPv6Kit\inc" /I "C:\Dev\zlib\include" /D "_DEBUG" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LIBHTTRACK_EXPORTS" /D "ZLIB_DLL" /FD /GZ /c # SUBTRACT CPP /YX /Yc /Yu # ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32 # ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 # ADD BASE RSC /l 0x40c /d "_DEBUG" # ADD RSC /l 0x40c /d "_DEBUG" BSC32=bscmake.exe # ADD BASE BSC32 /nologo # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept # ADD LINK32 wsock32.lib zdll.lib /nologo /dll /map /debug /machine:I386 /out:"C:\temp\libhttrack.dll" /pdbtype:sept /libpath:"C:\Dev\zlib\lib" # SUBTRACT LINK32 /pdb:none !ENDIF # Begin Target # Name "libhttrack - Win32 Release" # Name "libhttrack - Win32 Debug" # Begin Group "Source Files" # PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" # Begin Source File SOURCE=minizip\crypt.h # End Source File # Begin Source File SOURCE="hts-indextmpl.h" # End Source File # Begin Source File SOURCE=htsalias.c # End Source File # Begin Source File SOURCE=htsalias.h # End Source File # Begin Source File SOURCE=htsback.c # End Source File # Begin Source File SOURCE=htsback.h # End Source File # Begin Source File SOURCE=htsbase.h # End Source File # Begin Source File SOURCE=htsbasenet.h # End Source File # Begin Source File SOURCE=htsbauth.c # End Source File # Begin Source File SOURCE=htsbauth.h # End Source File # Begin Source File SOURCE=htscache.c # End Source File # Begin Source File SOURCE=htscache.h # End Source File # Begin Source File SOURCE=htscatchurl.c # End Source File # Begin Source File SOURCE=htscatchurl.h # End Source File # Begin Source File SOURCE=htsconfig.h # End Source File # Begin Source File SOURCE=htscore.c # End Source File # Begin Source File SOURCE=htscore.h # End Source File # Begin Source File SOURCE=htscoremain.c # End Source File # Begin Source File SOURCE=htscoremain.h # End Source File # Begin Source File SOURCE=htsdefines.h # End Source File # Begin Source File SOURCE=htsfilters.c # End Source File # Begin Source File SOURCE=htsfilters.h # End Source File # Begin Source File SOURCE=htsftp.c # End Source File # Begin Source File SOURCE=htsftp.h # End Source File # Begin Source File SOURCE=htsglobal.h # End Source File # Begin Source File SOURCE=htshash.c # End Source File # Begin Source File SOURCE=htshash.h # End Source File # Begin Source File SOURCE=htshelp.c # End Source File # Begin Source File SOURCE=htshelp.h # End Source File # Begin Source File SOURCE=htsindex.c # End Source File # Begin Source File SOURCE=htsindex.h # End Source File # Begin Source File SOURCE=htsinthash.c # End Source File # Begin Source File SOURCE=htsjava.c # End Source File # Begin Source File SOURCE=htsjava.h # End Source File # Begin Source File SOURCE=htslib.c # End Source File # Begin Source File SOURCE=htslib.h # End Source File # Begin Source File SOURCE=htsmd5.c # End Source File # Begin Source File SOURCE=htsmd5.h # End Source File # Begin Source File SOURCE=htsmodules.c # End Source File # Begin Source File SOURCE=htsmodules.h # End Source File # Begin Source File SOURCE=htsname.c # End Source File # Begin Source File SOURCE=htsname.h # End Source File # Begin Source File SOURCE=htsnet.h # End Source File # Begin Source File SOURCE=htsnostatic.c # End Source File # Begin Source File SOURCE=htsnostatic.h # End Source File # Begin Source File SOURCE=htsopt.h # End Source File # Begin Source File SOURCE=htsparse.c # End Source File # Begin Source File SOURCE=htsparse.h # End Source File # Begin Source File SOURCE=htsrobots.c # End Source File # Begin Source File SOURCE=htsrobots.h # End Source File # Begin Source File SOURCE=htsstrings.h # End Source File # Begin Source File SOURCE=htssystem.h # End Source File # Begin Source File SOURCE=htsthread.c # End Source File # Begin Source File SOURCE=htsthread.h # End Source File # Begin Source File SOURCE=htstools.c # End Source File # Begin Source File SOURCE=htstools.h # End Source File # Begin Source File SOURCE=htswizard.c # End Source File # Begin Source File SOURCE=htswizard.h # End Source File # Begin Source File SOURCE=htswrap.c # End Source File # Begin Source File SOURCE=htswrap.h # End Source File # Begin Source File SOURCE=htszlib.c # End Source File # Begin Source File SOURCE=htszlib.h # End Source File # Begin Source File SOURCE=minizip\ioapi.c # End Source File # Begin Source File SOURCE=minizip\ioapi.h # End Source File # Begin Source File SOURCE=minizip\iowin32.c # End Source File # Begin Source File SOURCE=minizip\iowin32.h # End Source File # Begin Source File SOURCE=md5.c # End Source File # Begin Source File SOURCE=md5.h # End Source File # Begin Source File SOURCE=minizip\mztools.c # End Source File # Begin Source File SOURCE=minizip\mztools.h # End Source File # Begin Source File SOURCE=minizip\unzip.c # End Source File # Begin Source File SOURCE=minizip\unzip.h # End Source File # Begin Source File SOURCE=minizip\zip.c # End Source File # Begin Source File SOURCE=minizip\zip.h # End Source File # End Group # Begin Group "Header Files" # PROP Default_Filter "h;hpp;hxx;hm;inl" # Begin Source File # PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe" # End Group # Begin Source File SOURCE=.\ReadMe.txt # End Source File # End Target # End Project httrack-3.49.5/src/httrack.dsp0000644000175000017500000001265714336470674013165 00000000000000# Microsoft Developer Studio Project File - Name="httrack" - Package Owner=<4> # Microsoft Developer Studio Generated Build File, Format Version 6.00 # ** DO NOT EDIT ** # TARGTYPE "Win32 (x86) Console Application" 0x0103 CFG=httrack - Win32 Debug !MESSAGE This is not a valid makefile. To build this project using NMAKE, !MESSAGE use the Export Makefile command and run !MESSAGE !MESSAGE NMAKE /f "httrack.mak". !MESSAGE !MESSAGE You can specify a configuration when running NMAKE !MESSAGE by defining the macro CFG on the command line. For example: !MESSAGE !MESSAGE NMAKE /f "httrack.mak" CFG="httrack - Win32 Debug" !MESSAGE !MESSAGE Possible choices for configuration are: !MESSAGE !MESSAGE "httrack - Win32 Release" (based on "Win32 (x86) Console Application") !MESSAGE "httrack - Win32 Debug" (based on "Win32 (x86) Console Application") !MESSAGE "httrack - Win32 Release avec debug" (based on "Win32 (x86) Console Application") !MESSAGE # Begin Project # PROP AllowPerConfigDependencies 0 # PROP Scc_ProjName "" # PROP Scc_LocalPath "" CPP=cl.exe RSC=rc.exe !IF "$(CFG)" == "httrack - Win32 Release" # PROP BASE Use_MFC 0 # PROP BASE Use_Debug_Libraries 0 # PROP BASE Output_Dir "Release" # PROP BASE Intermediate_Dir "Release" # PROP BASE Target_Dir "" # PROP Use_MFC 0 # PROP Use_Debug_Libraries 0 # PROP Output_Dir "Release" # PROP Intermediate_Dir "c:\temp\vcpp" # PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c # ADD CPP /nologo /MD /W3 /Gi /O2 /Op /Ob2 /I "C:\Dev\IPv6Kit\inc\\" /I "C:\Dev\zlib\\" /I "C:\Dev\openssl\include" /I "C:\Dev\Winhttrack" /D "NDEBUG" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /D "HTS_ANALYSTE_CONSOLE" /YX /FD /Zm200 /c # SUBTRACT CPP /Fr # ADD BASE RSC /l 0x40c /d "NDEBUG" # ADD RSC /l 0x409 /d "NDEBUG" BSC32=bscmake.exe # ADD BASE BSC32 /nologo # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386 # ADD LINK32 wsock32.lib libhttrack.lib /nologo /subsystem:console /machine:I386 /out:"L:\HTTrack\httrack\httrack.exe" /libpath:"C:\Dev\openssl\lib" /libpath:"C:\Dev\zlib\dll32" /libpath:"C:\Dev\openssl\lib\out32dll" /libpath:"C:\temp\Releaselib" # SUBTRACT LINK32 /verbose !ELSEIF "$(CFG)" == "httrack - Win32 Debug" # PROP BASE Use_MFC 0 # PROP BASE Use_Debug_Libraries 1 # PROP BASE Output_Dir "Debug" # PROP BASE Intermediate_Dir "Debug" # PROP BASE Target_Dir "" # PROP Use_MFC 0 # PROP Use_Debug_Libraries 1 # PROP Output_Dir "Debug" # PROP Intermediate_Dir "c:\temp\vcpp" # PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c # ADD CPP /nologo /MDd /W3 /Gm /GR /ZI /Od /I "C:\Dev\IPv6Kit\inc\\" /I "C:\Dev\zlib\\" /I "C:\Dev\openssl\include" /I "C:\Dev\Winhttrack" /D "_DEBUG" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /D "HTS_ANALYSTE_CONSOLE" /FAcs /Fr /FD /Zm200 /c # ADD BASE RSC /l 0x40c /d "_DEBUG" # ADD RSC /l 0x409 /d "_DEBUG" BSC32=bscmake.exe # ADD BASE BSC32 /nologo # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept # ADD LINK32 wsock32.lib libhttrack.lib /nologo /subsystem:console /debug /debugtype:both /machine:I386 /out:"C:\temp\httrack.exe" /pdbtype:sept /libpath:"C:\Dev\openssl\lib" /libpath:"C:\Dev\zlib\dll32" /libpath:"C:\Dev\openssl\lib\out32dll" /libpath:"C:\temp\Debuglib" # SUBTRACT LINK32 /profile /map !ELSEIF "$(CFG)" == "httrack - Win32 Release avec debug" # PROP BASE Use_MFC 0 # PROP BASE Use_Debug_Libraries 0 # PROP BASE Output_Dir "httrack___Win32_Release_avec_debug" # PROP BASE Intermediate_Dir "httrack___Win32_Release_avec_debug" # PROP BASE Ignore_Export_Lib 0 # PROP BASE Target_Dir "" # PROP Use_MFC 0 # PROP Use_Debug_Libraries 0 # PROP Output_Dir "Release_avec_debug" # PROP Intermediate_Dir "c:\temp\vcpp" # PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /MT /W3 /GX /Ot /Oi /Oy /Ob2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c # SUBTRACT BASE CPP /Ox /Oa /Ow /Og /Os # ADD CPP /nologo /MD /W3 /GX /Zi /Ot /Oi /Oy /Ob2 /I "C:\Dev\IPv6Kit\inc\\" /I "C:\Dev\zlib\\" /I "C:\Dev\openssl\include" /I "C:\Dev\Winhttrack" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /D "HTS_ANALYSTE_CONSOLE" /FAcs /FR /YX /FD /Zm200 /c # ADD BASE RSC /l 0x409 /d "NDEBUG" # ADD RSC /l 0x409 /d "NDEBUG" BSC32=bscmake.exe # ADD BASE BSC32 /nologo # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 wsock32.lib /nologo /subsystem:console /machine:I386 /out:"c:\temp\httrack.exe" # SUBTRACT BASE LINK32 /verbose # ADD LINK32 wsock32.lib libhttrack.lib /nologo /subsystem:console /debug /machine:I386 /out:"L:\HTTrack\httrack\httrack.exe" /libpath:"C:\Dev\openssl\lib" /libpath:"C:\Dev\zlib\dll32" /libpath:"C:\Dev\openssl\lib\out32dll" # SUBTRACT LINK32 /verbose !ENDIF # Begin Target # Name "httrack - Win32 Release" # Name "httrack - Win32 Debug" # Name "httrack - Win32 Release avec debug" # Begin Source File SOURCE=httrack.c # End Source File # Begin Source File SOURCE=httrack.h # End Source File # End Target # End Project httrack-3.49.5/src/webhttrack.dsw0000644000175000017500000000151114336470674013655 00000000000000Microsoft Developer Studio Workspace File, Format Version 6.00 # WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE! ############################################################################### Project: "libhttrack"=..\libhttrack\libhttrack.dsp - Package Owner=<4> Package=<5> {{{ }}} Package=<4> {{{ }}} ############################################################################### Project: "webhttrack"=.\webhttrack.dsp - Package Owner=<4> Package=<5> {{{ }}} Package=<4> {{{ Begin Project Dependency Project_Dep_Name libhttrack End Project Dependency }}} ############################################################################### Global: Package=<5> {{{ }}} Package=<3> {{{ }}} ############################################################################### httrack-3.49.5/src/libhttrack.dsw0000644000175000017500000000100214336470674013641 00000000000000Microsoft Developer Studio Workspace File, Format Version 6.00 # WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE! ############################################################################### Project: "libhttrack"=.\libhttrack.dsp - Package Owner=<4> Package=<5> {{{ }}} Package=<4> {{{ }}} ############################################################################### Global: Package=<5> {{{ }}} Package=<3> {{{ }}} ############################################################################### httrack-3.49.5/src/httrack.dsw0000644000175000017500000000150214336470674013157 00000000000000Microsoft Developer Studio Workspace File, Format Version 6.00 # WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE! ############################################################################### Project: "httrack"=.\httrack.dsp - Package Owner=<4> Package=<5> {{{ }}} Package=<4> {{{ Begin Project Dependency Project_Dep_Name libhttrack End Project Dependency }}} ############################################################################### Project: "libhttrack"=.\libhttrack\libhttrack.dsp - Package Owner=<4> Package=<5> {{{ }}} Package=<4> {{{ }}} ############################################################################### Global: Package=<5> {{{ }}} Package=<3> {{{ }}} ############################################################################### httrack-3.49.5/src/webhttrack0000755000175000017500000001120714360540772013061 00000000000000#!/bin/bash # # WebHTTrack launcher script # Initializes the htsserver GUI frontend and launch the default browser BROWSEREXE= SRCHBROWSEREXE="x-www-browser www-browser iceape mozilla firefox-developer-edition firefox icecat iceweasel abrowser firebird galeon konqueror midori opera google-chrome chrome chromium chromium-browser netscape firefox-developer-edition" if test -n "${BROWSER}"; then # sensible-browser will f up if BROWSER is not set SRCHBROWSEREXE="xdg-open sensible-browser ${SRCHBROWSEREXE}" fi # Patch for Darwin/Mac by Ross Williams if test "`uname -s`" == "Darwin"; then # Darwin/Mac OS X uses a system 'open' command to find # the default browser. The -W flag causes it to wait for # the browser to exit BROWSEREXE="/usr/bin/open -W" fi BINWD=`dirname "$0"` SRCHPATH="$BINWD /usr/local/bin /usr/share/bin /usr/bin /usr/lib/httrack /usr/local/lib/httrack /usr/local/share/httrack /opt/local/bin /sw/bin ${HOME}/usr/bin ${HOME}/bin" SRCHPATH="$SRCHPATH "`echo $PATH | tr ":" " "` SRCHDISTPATH="$BINWD/../share $BINWD/.. /usr/share /usr/local /usr /local /usr/local/share ${HOME}/usr ${HOME}/usr/share /opt/local/share /sw ${HOME}/usr/local ${HOME}/usr/share" ### # And now some famous cuisine function log { echo "$0($$): $@" >&2 return 0 } function launch_browser { log "Launching $1" browser=$1 url=$2 log "Spawning browser.." ${browser} "${url}" # note: browser can hiddenly use the -remote feature of # mozilla and therefore return immediately log "Browser (or helper) exited" } # First ensure that we can launch the server BINPATH= for i in ${SRCHPATH}; do ! test -n "${BINPATH}" && test -x ${i}/htsserver && BINPATH=${i} done for i in ${SRCHDISTPATH}; do ! test -n "${DISTPATH}" && test -f "${i}/httrack/lang.def" && DISTPATH="${i}/httrack" done test -n "${BINPATH}" || ! log "Could not find htsserver" || exit 1 test -n "${DISTPATH}" || ! log "Could not find httrack directory" || exit 1 test -f ${DISTPATH}/lang.def || ! log "Could not find ${DISTPATH}/lang.def" || exit 1 test -f ${DISTPATH}/lang.indexes || ! log "Could not find ${DISTPATH}/lang.indexes" || exit 1 test -d ${DISTPATH}/lang || ! log "Could not find ${DISTPATH}/lang" || exit 1 test -d ${DISTPATH}/html || ! log "Could not find ${DISTPATH}/html" || exit 1 # Locale HTSLANG="${LC_MESSAGES}" ! test -n "${HTSLANG}" && HTSLANG="${LC_ALL}" ! test -n "${HTSLANG}" && HTSLANG="${LANG}" HTSLANG="`echo $LANG | cut -f1 -d'.' | cut -f1 -d'_'`" LANGN=`grep -E "^${HTSLANG}:" ${DISTPATH}/lang.indexes | cut -f2 -d':'` ! test -n "${LANGN}" && LANGN=1 # Find the browser # note: not all systems have sensible-browser or www-browser alternative # thefeore, we have to find a bit more if sensible-browser could not be found for i in ${SRCHBROWSEREXE}; do for j in ${SRCHPATH}; do if test -x ${j}/${i}; then BROWSEREXE=${j}/${i} fi test -n "$BROWSEREXE" && break done test -n "$BROWSEREXE" && break done test -n "$BROWSEREXE" || ! log "Could not find any suitable browser" || exit 1 # "browse" command if test "$1" = "browse"; then if test -f "${HOME}/.httrack.ini"; then INDEXF=`cat ${HOME}/.httrack.ini | tr '\r' '\n' | grep -E "^path=" | cut -f2- -d'='` if test -n "${INDEXF}" -a -d "${INDEXF}" -a -f "${INDEXF}/index.html"; then INDEXF="${INDEXF}/index.html" else INDEXF="" fi fi if ! test -n "$INDEXF"; then INDEXF="${HOME}/websites/index.html" fi launch_browser "${BROWSEREXE}" "file://${INDEXF}" exit $? fi # Create a temporary filename TMPSRVFILE="$(mktemp ${TMPDIR:-/tmp}/.webhttrack.XXXXXXXX)" || ! log "Could not create the temporary file ${TMPSRVFILE}" || exit 1 # Launch htsserver binary and setup the server (${BINPATH}/htsserver "${DISTPATH}/" --ppid "$$" path "${HOME}/websites" lang "${LANGN}" $@; echo SRVURL=error) > ${TMPSRVFILE}& # Find the generated SRVURL SRVURL= MAXCOUNT=60 while ! test -n "$SRVURL"; do MAXCOUNT=$[$MAXCOUNT - 1] test $MAXCOUNT -gt 0 || exit 1 test $MAXCOUNT -lt 50 && echo "waiting for server to reply.." SRVURL=`grep -E URL= ${TMPSRVFILE} | cut -f2- -d=` test ! "$SRVURL" = "error" || ! log "Could not spawn htsserver" || exit 1 test -n "$SRVURL" || sleep 1 done # Cleanup function function cleanup { test -n "$1" && log "Nasty signal caught, cleaning up.." # Do not kill if browser exited (chrome bug issue) ; server will die itself test -n "$1" && test -f ${TMPSRVFILE} && SRVPID=`grep -E PID= ${TMPSRVFILE} | cut -f2- -d=` test -n "${SRVPID}" && kill -9 ${SRVPID} test -f ${TMPSRVFILE} && rm ${TMPSRVFILE} test -n "$1" && log "..Done" return 0 } # Cleanup in case of emergency trap "cleanup now; exit" 1 2 3 4 5 6 7 8 9 11 13 14 15 16 19 24 25 # Got SRVURL, launch browser launch_browser "${BROWSEREXE}" "${SRVURL}" # That's all, folks! trap "" 1 2 3 4 5 6 7 8 9 11 13 14 15 16 19 24 25 cleanup exit 0 httrack-3.49.5/src/httrack.h0000644000175000017500000000473114336470674012620 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: htsshow.c console progress info */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTSTOOLS_DEFH #define HTSTOOLS_DEFH #include "htsglobal.h" #include "htscore.h" #include "htssafe.h" #ifndef HTS_DEF_FWSTRUCT_t_StatsBuffer #define HTS_DEF_FWSTRUCT_t_StatsBuffer typedef struct t_StatsBuffer t_StatsBuffer; #endif struct t_StatsBuffer { char name[1024]; char file[1024]; char state[256]; char BIGSTK url_sav[HTS_URLMAXSIZE * 2]; // pour cancel char BIGSTK url_adr[HTS_URLMAXSIZE * 2]; char BIGSTK url_fil[HTS_URLMAXSIZE * 2]; LLint size; LLint sizetot; int offset; // int back; // int actived; // pour disabled }; #ifndef HTS_DEF_FWSTRUCT_t_InpInfo #define HTS_DEF_FWSTRUCT_t_InpInfo typedef struct t_InpInfo t_InpInfo; #endif struct t_InpInfo { int ask_refresh; int refresh; LLint stat_bytes; int stat_time; int lien_n; int lien_tot; int stat_nsocket; int rate; int irate; int ft; LLint stat_written; int stat_updated; int stat_errors; int stat_warnings; int stat_infos; TStamp stat_timestart; int stat_back; }; int main(int argc, char **argv); #endif extern HTSEXT_API hts_stat_struct HTS_STAT; extern int _DEBUG_HEAD; extern FILE *ioinfo; httrack-3.49.5/src/httrack.c0000644000175000017500000010257614360534067012613 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: htsshow.c console progress info */ /* Only used on Linux & FreeBSD versions */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef _WIN32 #ifndef Sleep #define Sleep(a) { if (((a)*1000)%1000000) usleep(((a)*1000)%1000000); if (((a)*1000)/1000000) sleep(((a)*1000)/1000000); } #endif #endif #include "httrack-library.h" #include "htsglobal.h" #include "htsbase.h" #include "htsopt.h" #include "htsdefines.h" #include "httrack.h" #include "htslib.h" /* Static definitions */ static int fexist(const char *s); static int linput(FILE * fp, char *s, int max); // htswrap_add #include "htswrap.h" /* specific definitions */ //#include "htsbase.h" #include #include #include #include #ifdef HAVE_SYS_TYPES_H #include #endif #ifdef HAVE_SYS_STAT_H #include #endif #ifdef HAVE_UNISTD_H #include #endif #include #if (defined(__linux) && defined(HAVE_EXECINFO_H)) #include #define USES_BACKTRACE #endif /* END specific definitions */ static void __cdecl htsshow_init(t_hts_callbackarg * carg); static void __cdecl htsshow_uninit(t_hts_callbackarg * carg); static int __cdecl htsshow_start(t_hts_callbackarg * carg, httrackp * opt); static int __cdecl htsshow_chopt(t_hts_callbackarg * carg, httrackp * opt); static int __cdecl htsshow_end(t_hts_callbackarg * carg, httrackp * opt); static int __cdecl htsshow_preprocesshtml(t_hts_callbackarg * carg, httrackp * opt, char **html, int *len, const char *url_address, const char *url_file); static int __cdecl htsshow_postprocesshtml(t_hts_callbackarg * carg, httrackp * opt, char **html, int *len, const char *url_address, const char *url_file); static int __cdecl htsshow_checkhtml(t_hts_callbackarg * carg, httrackp * opt, char *html, int len, const char *url_address, const char *url_file); static int __cdecl htsshow_loop(t_hts_callbackarg * carg, httrackp * opt, lien_back * back, int back_max, int back_index, int lien_n, int lien_tot, int stat_time, hts_stat_struct * stats); static const char *__cdecl htsshow_query(t_hts_callbackarg * carg, httrackp * opt, const char *question); static const char *__cdecl htsshow_query2(t_hts_callbackarg * carg, httrackp * opt, const char *question); static const char *__cdecl htsshow_query3(t_hts_callbackarg * carg, httrackp * opt, const char *question); static int __cdecl htsshow_check(t_hts_callbackarg * carg, httrackp * opt, const char *adr, const char *fil, int status); static int __cdecl htsshow_check_mime(t_hts_callbackarg * carg, httrackp * opt, const char *adr, const char *fil, const char *mime, int status); static void __cdecl htsshow_pause(t_hts_callbackarg * carg, httrackp * opt, const char *lockfile); static void __cdecl htsshow_filesave(t_hts_callbackarg * carg, httrackp * opt, const char *file); static void __cdecl htsshow_filesave2(t_hts_callbackarg * carg, httrackp * opt, const char *adr, const char *fil, const char *save, int is_new, int is_modified, int not_updated); static int __cdecl htsshow_linkdetected(t_hts_callbackarg * carg, httrackp * opt, char *link); static int __cdecl htsshow_linkdetected2(t_hts_callbackarg * carg, httrackp * opt, char *link, const char *start_tag); static int __cdecl htsshow_xfrstatus(t_hts_callbackarg * carg, httrackp * opt, lien_back * back); static int __cdecl htsshow_savename(t_hts_callbackarg * carg, httrackp * opt, const char *adr_complete, const char *fil_complete, const char *referer_adr, const char *referer_fil, char *save); static int __cdecl htsshow_sendheader(t_hts_callbackarg * carg, httrackp * opt, char *buff, const char *adr, const char *fil, const char *referer_adr, const char *referer_fil, htsblk * outgoing); static int __cdecl htsshow_receiveheader(t_hts_callbackarg * carg, httrackp * opt, char *buff, const char *adr, const char *fil, const char *referer_adr, const char *referer_fil, htsblk * incoming); static void vt_clear(void); static void vt_home(void); // ISO VT100/220 definitions #define VT_COL_TEXT_BLACK "30" #define VT_COL_TEXT_RED "31" #define VT_COL_TEXT_GREEN "32" #define VT_COL_TEXT_YELLOW "33" #define VT_COL_TEXT_BLUE "34" #define VT_COL_TEXT_MAGENTA "35" #define VT_COL_TEXT_CYAN "36" #define VT_COL_TEXT_WHITE "37" #define VT_COL_BACK_BLACK "40" #define VT_COL_BACK_RED "41" #define VT_COL_BACK_GREEN "42" #define VT_COL_BACK_YELLOW "43" #define VT_COL_BACK_BLUE "44" #define VT_COL_BACK_MAGENTA "45" #define VT_COL_BACK_CYAN "46" #define VT_COL_BACK_WHITE "47" // #define VT_GOTOXY(X,Y) "\33["Y";"X"f" #define VT_COLOR(C) "\33["C"m" #define VT_RESET "\33[m" #define VT_REVERSE "\33[7m" #define VT_UNREVERSE "\33[27m" #define VT_BOLD "\33[1m" #define VT_UNBOLD "\33[22m" #define VT_BLINK "\33[5m" #define VT_UNBLINK "\33[25m" // #define VT_CLREOL "\33[K" #define VT_CLRSOL "\33[1K" #define VT_CLRLIN "\33[2K" #define VT_CLREOS "\33[J" #define VT_CLRSOS "\33[1J" #define VT_CLRSCR "\33[2J" // #define csi(X) printf(s_csi( X )); static void vt_clear(void) { printf("%s%s%s", VT_RESET, VT_CLRSCR, VT_GOTOXY("1", "0")); } static void vt_home(void) { printf("%s%s", VT_RESET, VT_GOTOXY("1", "0")); } // /* #define STYLE_STATVALUES VT_COLOR(VT_COL_TEXT_BLACK) #define STYLE_STATTEXT VT_COLOR(VT_COL_TEXT_BLUE) */ #define STYLE_STATVALUES VT_BOLD #define STYLE_STATTEXT VT_UNBOLD #define STYLE_STATRESET VT_UNBOLD #define NStatsBuffer 14 #define MAX_LEN_INPROGRESS 40 static int use_show; static httrackp *global_opt = NULL; static void signal_handlers(void); int main(int argc, char **argv) { int ret = 0; httrackp *opt; #ifdef _WIN32 { WORD wVersionRequested; // requested version WinSock API WSADATA wsadata; // Windows Sockets API data int stat; wVersionRequested = 0x0101; stat = WSAStartup(wVersionRequested, &wsadata); if (stat != 0) { printf("Winsock not found!\n"); return; } else if (LOBYTE(wsadata.wVersion) != 1 && HIBYTE(wsadata.wVersion) != 1) { printf("WINSOCK.DLL does not support version 1.1\n"); WSACleanup(); return; } } #endif signal_handlers(); hts_init(); // Check version compatibility if (hts_sizeof_opt() != sizeof(httrackp)) { fprintf(stderr, "incompatible current httrack library version %s, expected version %s", hts_version(), HTTRACK_VERSIONID); abortLog("incompatible httrack library version, please update both httrack and its library"); } opt = global_opt = hts_create_opt(); assert(opt->size_httrackp == sizeof(httrackp)); CHAIN_FUNCTION(opt, init, htsshow_init, NULL); CHAIN_FUNCTION(opt, uninit, htsshow_uninit, NULL); CHAIN_FUNCTION(opt, start, htsshow_start, NULL); CHAIN_FUNCTION(opt, end, htsshow_end, NULL); CHAIN_FUNCTION(opt, chopt, htsshow_chopt, NULL); CHAIN_FUNCTION(opt, preprocess, htsshow_preprocesshtml, NULL); CHAIN_FUNCTION(opt, postprocess, htsshow_postprocesshtml, NULL); CHAIN_FUNCTION(opt, check_html, htsshow_checkhtml, NULL); CHAIN_FUNCTION(opt, query, htsshow_query, NULL); CHAIN_FUNCTION(opt, query2, htsshow_query2, NULL); CHAIN_FUNCTION(opt, query3, htsshow_query3, NULL); CHAIN_FUNCTION(opt, loop, htsshow_loop, NULL); CHAIN_FUNCTION(opt, check_link, htsshow_check, NULL); CHAIN_FUNCTION(opt, check_mime, htsshow_check_mime, NULL); CHAIN_FUNCTION(opt, pause, htsshow_pause, NULL); CHAIN_FUNCTION(opt, filesave, htsshow_filesave, NULL); CHAIN_FUNCTION(opt, filesave2, htsshow_filesave2, NULL); CHAIN_FUNCTION(opt, linkdetected, htsshow_linkdetected, NULL); CHAIN_FUNCTION(opt, linkdetected2, htsshow_linkdetected2, NULL); CHAIN_FUNCTION(opt, xfrstatus, htsshow_xfrstatus, NULL); CHAIN_FUNCTION(opt, savename, htsshow_savename, NULL); CHAIN_FUNCTION(opt, sendhead, htsshow_sendheader, NULL); CHAIN_FUNCTION(opt, receivehead, htsshow_receiveheader, NULL); ret = hts_main2(argc, argv, opt); if (ret) { fprintf(stderr, "* %s\n", hts_errmsg(opt)); } global_opt = NULL; hts_free_opt(opt); htsthread_wait(); /* wait for pending threads */ hts_uninit(); #ifdef _WIN32 WSACleanup(); #endif return ret; } /* CALLBACK FUNCTIONS */ /* Initialize the Winsock */ static void __cdecl htsshow_init(t_hts_callbackarg * carg) { } static void __cdecl htsshow_uninit(t_hts_callbackarg * carg) { } static int __cdecl htsshow_start(t_hts_callbackarg * carg, httrackp * opt) { use_show = 0; if (opt->verbosedisplay == 2) { use_show = 1; vt_clear(); } return 1; } static int __cdecl htsshow_chopt(t_hts_callbackarg * carg, httrackp * opt) { return htsshow_start(carg, opt); } static int __cdecl htsshow_end(t_hts_callbackarg * carg, httrackp * opt) { return 1; } static int __cdecl htsshow_preprocesshtml(t_hts_callbackarg * carg, httrackp * opt, char **html, int *len, const char *url_address, const char *url_file) { return 1; } static int __cdecl htsshow_postprocesshtml(t_hts_callbackarg * carg, httrackp * opt, char **html, int *len, const char *url_address, const char *url_file) { return 1; } static int __cdecl htsshow_checkhtml(t_hts_callbackarg * carg, httrackp * opt, char *html, int len, const char *url_address, const char *url_file) { return 1; } static int __cdecl htsshow_loop(t_hts_callbackarg * carg, httrackp * opt, lien_back * back, int back_max, int back_index, int lien_n, int lien_tot, int stat_time, hts_stat_struct * stats) { // appelé à chaque boucle de HTTrack static TStamp prev_mytime = 0; /* ok */ static t_InpInfo SInfo; /* ok */ // TStamp mytime; long int rate = 0; char st[256]; // int stat_written = -1; int stat_updated = -1; int stat_errors = -1; int stat_warnings = -1; int stat_infos = -1; int nbk = -1; int stat_nsocket = -1; LLint stat_bytes = -1; LLint stat_bytes_recv = -1; int irate = -1; if (stats) { stat_written = stats->stat_files; stat_updated = stats->stat_updated_files; stat_errors = stats->stat_errors; stat_warnings = stats->stat_warnings; stat_infos = stats->stat_infos; nbk = stats->nbk; stat_nsocket = stats->stat_nsocket; irate = (int) stats->rate; stat_bytes = stats->nb; stat_bytes_recv = stats->HTS_TOTAL_RECV; } if (!use_show) return 1; mytime = mtime_local(); if ((stat_time > 0) && (stat_bytes_recv > 0)) rate = (int) (stat_bytes_recv / stat_time); else rate = 0; // pas d'infos /* Infos */ if (stat_bytes >= 0) SInfo.stat_bytes = stat_bytes; // bytes if (stat_time >= 0) SInfo.stat_time = stat_time; // time if (lien_tot >= 0) SInfo.lien_tot = lien_tot; // nb liens if (lien_n >= 0) SInfo.lien_n = lien_n; // scanned SInfo.stat_nsocket = stat_nsocket; // socks if (rate > 0) SInfo.rate = rate; // rate if (irate >= 0) SInfo.irate = irate; // irate if (SInfo.irate < 0) SInfo.irate = SInfo.rate; if (nbk >= 0) SInfo.stat_back = nbk; if (stat_written >= 0) SInfo.stat_written = stat_written; if (stat_updated >= 0) SInfo.stat_updated = stat_updated; if (stat_errors >= 0) SInfo.stat_errors = stat_errors; if (stat_warnings >= 0) SInfo.stat_warnings = stat_warnings; if (stat_infos >= 0) SInfo.stat_infos = stat_infos; if (((mytime - prev_mytime) > 100) || ((mytime - prev_mytime) < 0)) { strc_int2bytes2 strc, strc2, strc3; prev_mytime = mytime; st[0] = '\0'; qsec2str(st, stat_time); vt_home(); printf(VT_GOTOXY("1", "1") VT_CLREOL STYLE_STATTEXT "Bytes saved:" STYLE_STATVALUES " \t%s" "\t" VT_CLREOL VT_GOTOXY("40", "1") STYLE_STATTEXT "Links scanned:" STYLE_STATVALUES " \t%d/%d (+%d)" VT_CLREOL "\n" VT_CLREOL VT_GOTOXY("1", "2") STYLE_STATTEXT "Time:" " \t" STYLE_STATVALUES "%s" "\t" VT_CLREOL VT_GOTOXY("40", "2") STYLE_STATTEXT "Files written:" " \t" STYLE_STATVALUES "%d" VT_CLREOL "\n" VT_CLREOL VT_GOTOXY("1", "3") STYLE_STATTEXT "Transfer rate:" " \t" STYLE_STATVALUES "%s (%s)" "\t" VT_CLREOL VT_GOTOXY("40", "3") STYLE_STATTEXT "Files updated:" " \t" STYLE_STATVALUES "%d" VT_CLREOL "\n" VT_CLREOL VT_GOTOXY("1", "4") STYLE_STATTEXT "Active connections:" " \t" STYLE_STATVALUES "%d" "\t" VT_CLREOL VT_GOTOXY("40", "4") STYLE_STATTEXT "Errors:" STYLE_STATVALUES " \t" STYLE_STATVALUES "%d" VT_CLREOL "\n" STYLE_STATRESET, /* */ (char *) int2bytes(&strc, SInfo.stat_bytes), (int) lien_n, (int) SInfo.lien_tot, (int) nbk, (char *) st, (int) SInfo.stat_written, (char *) int2bytessec(&strc2, SInfo.irate), (char *) int2bytessec(&strc3, SInfo.rate), (int) SInfo.stat_updated, (int) SInfo.stat_nsocket, (int) SInfo.stat_errors /* */ ); // parcourir registre des liens if (back_index >= 0) { // seulement si index passé int j, k; int index = 0; int ok = 0; // idem int l; // idem // t_StatsBuffer StatsBuffer[NStatsBuffer]; { int i; for(i = 0; i < NStatsBuffer; i++) { strcpybuff(StatsBuffer[i].state, ""); strcpybuff(StatsBuffer[i].name, ""); strcpybuff(StatsBuffer[i].file, ""); strcpybuff(StatsBuffer[i].url_sav, ""); StatsBuffer[i].back = 0; StatsBuffer[i].size = 0; StatsBuffer[i].sizetot = 0; } } for(k = 0; k < 2; k++) { // 0: lien en cours 1: autres liens for(j = 0; (j < 3) && (index < NStatsBuffer); j++) { // passe de priorité int _i; for(_i = 0 + k; (_i < max(back_max * k, 1)) && (index < NStatsBuffer); _i++) { // no lien int i = (back_index + _i) % back_max; // commencer par le "premier" (l'actuel) if (back[i].status >= 0) { // signifie "lien actif" // int ok=0; // OPTI ok = 0; switch (j) { case 0: // prioritaire if ((back[i].status > 0) && (back[i].status < 99)) { strcpybuff(StatsBuffer[index].state, "receive"); ok = 1; } break; case 1: if (back[i].status == STATUS_WAIT_HEADERS) { strcpybuff(StatsBuffer[index].state, "request"); ok = 1; } else if (back[i].status == STATUS_CONNECTING) { strcpybuff(StatsBuffer[index].state, "connect"); ok = 1; } else if (back[i].status == STATUS_WAIT_DNS) { strcpybuff(StatsBuffer[index].state, "search"); ok = 1; } else if (back[i].status == STATUS_FTP_TRANSFER) { // ohh le beau ftp snprintf(StatsBuffer[index].state, sizeof(StatsBuffer[index].state), "ftp: %s", back[i].info); ok = 1; } break; default: if (back[i].status == STATUS_READY) { // prêt if (back[i].r.statuscode == 200) { strcpybuff(StatsBuffer[index].state, "ready"); ok = 1; } else if (back[i].r.statuscode >= 100 && back[i].r.statuscode <= 599) { char tempo[256]; tempo[0] = '\0'; infostatuscode(tempo, back[i].r.statuscode); strcpybuff(StatsBuffer[index].state, tempo); ok = 1; } else { strcpybuff(StatsBuffer[index].state, "error"); ok = 1; } } break; } if (ok) { char BIGSTK s[HTS_URLMAXSIZE * 2]; // StatsBuffer[index].back = i; // index pour + d'infos // s[0] = '\0'; strcpybuff(StatsBuffer[index].url_sav, back[i].url_sav); // pour cancel if (strcmp(back[i].url_adr, "file://")) strcatbuff(s, back[i].url_adr); else strcatbuff(s, "localhost"); if (back[i].url_fil[0] != '/') strcatbuff(s, "/"); strcatbuff(s, back[i].url_fil); StatsBuffer[index].file[0] = '\0'; { char *a = strrchr(s, '/'); if (a) { strncatbuff(StatsBuffer[index].file, a, 200); *a = '\0'; } } if ((l = (int) strlen(s)) < MAX_LEN_INPROGRESS) strcpybuff(StatsBuffer[index].name, s); else { // couper StatsBuffer[index].name[0] = '\0'; strncatbuff(StatsBuffer[index].name, s, MAX_LEN_INPROGRESS / 2 - 2); strcatbuff(StatsBuffer[index].name, "..."); strcatbuff(StatsBuffer[index].name, s + l - MAX_LEN_INPROGRESS / 2 + 2); } if (back[i].r.totalsize >= 0) { // taille prédéfinie StatsBuffer[index].sizetot = back[i].r.totalsize; StatsBuffer[index].size = back[i].r.size; } else { // pas de taille prédéfinie if (back[i].status == STATUS_READY) { // prêt StatsBuffer[index].sizetot = back[i].r.size; StatsBuffer[index].size = back[i].r.size; } else { StatsBuffer[index].sizetot = 8192; StatsBuffer[index].size = (back[i].r.size % 8192); } } index++; } } } } } /* LF */ printf("%s\n", VT_CLREOL); /* Display current job */ { int parsing = 0; printf("Current job: "); if (!(parsing = hts_is_parsing(opt, -1))) printf("receiving files"); else { switch (hts_is_testing(opt)) { case 0: printf("parsing HTML file (%d%%)", parsing); break; case 1: printf("parsing HTML file: testing links (%d%%)", parsing); break; case 2: printf("purging files"); break; case 3: printf("loading cache"); break; case 4: printf("waiting (scheduler)"); break; case 5: printf("waiting (throttle)"); break; } } printf("%s\n", VT_CLREOL); } /* Display background jobs */ { int i; for(i = 0; i < NStatsBuffer; i++) { if (strnotempty(StatsBuffer[i].state)) { printf(VT_CLREOL " %s - \t%s%s \t%s / \t%s", StatsBuffer[i].state, StatsBuffer[i].name, StatsBuffer[i].file, int2bytes(&strc, StatsBuffer [i]. size), int2bytes(&strc2, StatsBuffer[i].sizetot) ); } printf("%s\n", VT_CLREOL); } } } } return 1; } static const char *__cdecl htsshow_query(t_hts_callbackarg * carg, httrackp * opt, const char *question) { static char s[12] = ""; /* ok */ printf("%s\nPress to confirm, to abort\n", question); io_flush; linput(stdin, s, 4); return s; } static const char *__cdecl htsshow_query2(t_hts_callbackarg * carg, httrackp * opt, const char *question) { static char s[12] = ""; /* ok */ printf("%s\nPress to confirm, to abort\n", question); io_flush; linput(stdin, s, 4); return s; } static const char *__cdecl htsshow_query3(t_hts_callbackarg * carg, httrackp * opt, const char *question) { static char line[256]; /* ok */ printf("\n" "A link, %s, is located beyond this mirror scope.\n" "What should I do? (type in the choice + enter)\n\n" "* Ignore all further links and do not ask any more questions\n" "0 Ignore this link (default if empty entry)\n" "1 Ignore directory and lower structures\n" "2 Ignore all domain\n" "\n" "4 Get only this page/link, but not links inside this page\n" "5 Mirror this link (useful)\n" "6 Mirror all links located on the same domain as this link\n" "\n", question); do { printf(">> "); io_flush; linput(stdin, line, 200); } while(!strnotempty(line)); printf("ok..\n"); return line; } static int __cdecl htsshow_check(t_hts_callbackarg * carg, httrackp * opt, const char *adr, const char *fil, int status) { return -1; } static int __cdecl htsshow_check_mime(t_hts_callbackarg * carg, httrackp * opt, const char *adr, const char *fil, const char *mime, int status) { return -1; } static void __cdecl htsshow_pause(t_hts_callbackarg * carg, httrackp * opt, const char *lockfile) { while(fexist(lockfile)) { Sleep(1000); } } static void __cdecl htsshow_filesave(t_hts_callbackarg * carg, httrackp * opt, const char *file) { } static void __cdecl htsshow_filesave2(t_hts_callbackarg * carg, httrackp * opt, const char *adr, const char *fil, const char *save, int is_new, int is_modified, int not_updated) { } static int __cdecl htsshow_linkdetected(t_hts_callbackarg * carg, httrackp * opt, char *link) { return 1; } static int __cdecl htsshow_linkdetected2(t_hts_callbackarg * carg, httrackp * opt, char *link, const char *start_tag) { return 1; } static int __cdecl htsshow_xfrstatus(t_hts_callbackarg * carg, httrackp * opt, lien_back * back) { return 1; } static int __cdecl htsshow_savename(t_hts_callbackarg * carg, httrackp * opt, const char *adr_complete, const char *fil_complete, const char *referer_adr, const char *referer_fil, char *save) { return 1; } static int __cdecl htsshow_sendheader(t_hts_callbackarg * carg, httrackp * opt, char *buff, const char *adr, const char *fil, const char *referer_adr, const char *referer_fil, htsblk * outgoing) { return 1; } static int __cdecl htsshow_receiveheader(t_hts_callbackarg * carg, httrackp * opt, char *buff, const char *adr, const char *fil, const char *referer_adr, const char *referer_fil, htsblk * incoming) { return 1; } /* *** Various functions *** */ static int fexist(const char *s) { struct stat st; memset(&st, 0, sizeof(st)); if (stat(s, &st) == 0) { if (S_ISREG(st.st_mode)) { return 1; } } return 0; } static int linput(FILE * fp, char *s, int max) { int c; int j = 0; do { c = fgetc(fp); if (c != EOF) { switch (c) { case 13: break; // sauter CR case 10: c = -1; break; case 9: case 12: break; // sauter ces caractères default: s[j++] = (char) c; break; } } } while((c != -1) && (c != EOF) && (j < (max - 1))); s[j] = '\0'; return j; } // routines de détournement de SIGHUP & co (Unix) // static void sig_ignore(int code) { // ignorer signal } static void sig_term(int code) { // quitter brutalement fprintf(stderr, "\nProgram terminated (signal %d)\n", code); exit(0); } static void sig_finish(int code) { // finir et quitter signal(code, sig_term); // quitter si encore if (global_opt != NULL) { global_opt->state.exit_xh = 1; } fprintf(stderr, "\nExit requested to engine (signal %d)\n", code); } #ifdef _WIN32 #if 0 static void sig_ask(int code) { // demander char s[256]; signal(code, sig_term); // quitter si encore printf("\nQuit program/Interrupt/Cancel? (Q/I/C) "); fflush(stdout); scanf("%s", s); if ((s[0] == 'y') || (s[0] == 'Y') || (s[0] == 'o') || (s[0] == 'O') || (s[0] == 'q') || (s[0] == 'Q')) exit(0); // quitter else if ((s[0] == 'i') || (s[0] == 'I')) { if (global_opt != NULL) { // ask for stop global_opt->state.stop = 1; } } signal(code, sig_ask); // remettre signal } #endif #else static void sig_doback(int blind); static void sig_back(int code) { // ignorer et mettre en backing if (global_opt != NULL && !global_opt->background_on_suspend) { signal(SIGTSTP, SIG_DFL); // ^Z printf("\nInterrupting the program.\n"); fflush(stdout); kill(getpid(), SIGTSTP); } else { // Background the process. signal(code, sig_ignore); sig_doback(0); } } #if 0 static void sig_ask(int code) { // demander char s[256]; signal(code, sig_term); // quitter si encore printf ("\nQuit program/Interrupt/Background/bLind background/Cancel? (Q/I/B/L/C) "); fflush(stdout); scanf("%s", s); if ((s[0] == 'y') || (s[0] == 'Y') || (s[0] == 'o') || (s[0] == 'O') || (s[0] == 'q') || (s[0] == 'Q')) exit(0); // quitter else if ((s[0] == 'b') || (s[0] == 'B') || (s[0] == 'a') || (s[0] == 'A')) sig_doback(0); // arrière plan else if ((s[0] == 'l') || (s[0] == 'L')) sig_doback(1); // arrière plan else if ((s[0] == 'i') || (s[0] == 'I')) { if (global_opt != NULL) { // ask for stop printf("finishing pending transfers.. please wait\n"); global_opt->state.stop = 1; } signal(code, sig_ask); // remettre signal } else { printf("cancel..\n"); signal(code, sig_ask); // remettre signal } } #endif static void sig_brpipe(int code) { // treat if necessary signal(code, sig_brpipe); } static void sig_doback(int blind) { // mettre en backing int out = -1; // printf("\nMoving into background to complete the mirror...\n"); fflush(stdout); if (global_opt != NULL) { // suppress logging and asking lousy questions global_opt->quiet = 1; global_opt->verbosedisplay = 0; } if (!blind) out = open("hts-nohup.out", O_CREAT | O_WRONLY, S_IRUSR | S_IWUSR); if (out == -1) out = open("/dev/null", O_WRONLY, S_IRUSR | S_IWUSR); dup2(out, 0); dup2(out, 1); dup2(out, 2); // switch (fork()) { case 0: break; case -1: fprintf(stderr, "Error: can not fork process\n"); break; default: // pere _exit(0); break; } } #endif #undef FD_ERR #define FD_ERR 2 static void print_backtrace(void) { #ifdef USES_BACKTRACE void *stack[256]; const int size = backtrace(stack, sizeof(stack)/sizeof(stack[0])); if (size != 0) { backtrace_symbols_fd(stack, size, FD_ERR); } #else const char msg[] = "No stack trace available on this OS :(\n"; if (write(FD_ERR, msg, sizeof(msg) - 1) != sizeof(msg) - 1) { /* sorry GCC */ } #endif } static size_t print_num(char *buffer, int num) { size_t i, j; if (num < 0) { *(buffer++) = '-'; num = -num; } for(i = 0 ; num != 0 || i == 0 ; i++, num /= 10) { buffer[i] = '0' + ( num % 10 ); } for(j = 0 ; j < i ; j++) { const char c = buffer[i - j - 1]; buffer[i - j - 1] = buffer[j]; buffer[j] = c; } buffer[i] = '\0'; return i; } static void sig_fatal(int code) { const char msg[] = "\nCaught signal "; const char msgreport[] = "\nPlease report the problem at http://forum.httrack.com\n"; char buffer[256]; size_t size; signal(code, SIG_DFL); signal(SIGABRT, SIG_DFL); memcpy(buffer, msg, sizeof(msg) - 1); size = sizeof(msg) - 1; size += print_num(&buffer[size], code); buffer[size++] = '\n'; (void) (write(FD_ERR, buffer, size) == size); print_backtrace(); (void) (write(FD_ERR, msgreport, sizeof(msgreport) - 1) == sizeof(msgreport) - 1); abort(); } #undef FD_ERR static void sig_leave(int code) { if (global_opt != NULL && global_opt->state._hts_in_mirror) { signal(code, sig_term); // quitter si encore printf("\n** Finishing pending transfers.. press again ^C to quit.\n"); if (global_opt != NULL) { // ask for stop hts_log_print(global_opt, LOG_ERROR, "Exit requested by shell or user"); global_opt->state.stop = 1; } } else { sig_term(code); } } static void signal_handlers(void) { #ifdef _WIN32 #if 0 /* BUG366763 */ signal(SIGINT, sig_ask); // ^C #else signal(SIGINT, sig_leave); // ^C #endif signal(SIGTERM, sig_finish); // kill #else #if 0 /* BUG366763 */ signal(SIGHUP, sig_back); // close window #endif signal(SIGTSTP, sig_back); // ^Z signal(SIGTERM, sig_finish); // kill #if 0 /* BUG366763 */ signal(SIGINT, sig_ask); // ^C #else signal(SIGINT, sig_leave); // ^C #endif signal(SIGPIPE, sig_brpipe); // broken pipe (write into non-opened socket) signal(SIGCHLD, sig_ignore); // child change status #endif #ifdef SIGABRT signal(SIGABRT, sig_fatal); // abort #endif #ifdef SIGBUS signal(SIGBUS, sig_fatal); // bus error #endif #ifdef SIGILL signal(SIGILL, sig_fatal); // illegal instruction #endif #ifdef SIGSEGV signal(SIGSEGV, sig_fatal); // segmentation violation #endif #ifdef SIGSTKFLT signal(SIGSTKFLT, sig_fatal); // stack fault #endif } // fin routines de détournement de SIGHUP & co httrack-3.49.5/src/htsweb.h0000644000175000017500000001375014336470674012455 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: webhttrack.c routines */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef WEBHTTRACK_WBC #define WEBHTTRACK_WBC #include "htsglobal.h" #include "htscore.h" #define NStatsBuffer 14 #define MAX_LEN_INPROGRESS 40 typedef struct t_StatsBuffer { char name[1024]; char file[1024]; char state[256]; char url_sav[HTS_URLMAXSIZE * 2]; // pour cancel char url_adr[HTS_URLMAXSIZE * 2]; char url_fil[HTS_URLMAXSIZE * 2]; LLint size; LLint sizetot; int offset; // int back; // int actived; // pour disabled } t_StatsBuffer; typedef struct t_InpInfo { int ask_refresh; int refresh; LLint stat_bytes; int stat_time; int lien_n; int lien_tot; int stat_nsocket; int rate; int irate; int ft; LLint stat_written; int stat_updated; int stat_errors; int stat_warnings; int stat_infos; TStamp stat_timestart; int stat_back; } t_InpInfo; // wrappers void __cdecl htsshow_init(t_hts_callbackarg * carg); void __cdecl htsshow_uninit(t_hts_callbackarg * carg); int __cdecl htsshow_start(t_hts_callbackarg * carg, httrackp * opt); int __cdecl htsshow_chopt(t_hts_callbackarg * carg, httrackp * opt); int __cdecl htsshow_end(t_hts_callbackarg * carg, httrackp * opt); int __cdecl htsshow_preprocesshtml(t_hts_callbackarg * carg, httrackp * opt, char **html, int *len, const char *url_address, const char *url_file); int __cdecl htsshow_postprocesshtml(t_hts_callbackarg * carg, httrackp * opt, char **html, int *len, const char *url_address, const char *url_file); int __cdecl htsshow_checkhtml(t_hts_callbackarg * carg, httrackp * opt, char *html, int len, const char *url_address, const char *url_file); int __cdecl htsshow_loop(t_hts_callbackarg * carg, httrackp * opt, lien_back * back, int back_max, int back_index, int lien_n, int lien_tot, int stat_time, hts_stat_struct * stats); const char *__cdecl htsshow_query(t_hts_callbackarg * carg, httrackp * opt, const char *question); const char *__cdecl htsshow_query2(t_hts_callbackarg * carg, httrackp * opt, const char *question); const char *__cdecl htsshow_query3(t_hts_callbackarg * carg, httrackp * opt, const char *question); int __cdecl htsshow_check(t_hts_callbackarg * carg, httrackp * opt, const char *adr, const char *fil, int status); int __cdecl htsshow_check_mime(t_hts_callbackarg * carg, httrackp * opt, const char *adr, const char *fil, const char *mime, int status); void __cdecl htsshow_pause(t_hts_callbackarg * carg, httrackp * opt, const char *lockfile); void __cdecl htsshow_filesave(t_hts_callbackarg * carg, httrackp * opt, const char *file); void __cdecl htsshow_filesave2(t_hts_callbackarg * carg, httrackp * opt, const char *adr, const char *fil, const char *save, int is_new, int is_modified, int not_updated); int __cdecl htsshow_linkdetected(t_hts_callbackarg * carg, httrackp * opt, char *link); int __cdecl htsshow_linkdetected2(t_hts_callbackarg * carg, httrackp * opt, char *link, const char *start_tag); int __cdecl htsshow_xfrstatus(t_hts_callbackarg * carg, httrackp * opt, lien_back * back); int __cdecl htsshow_savename(t_hts_callbackarg * carg, httrackp * opt, const char *adr_complete, const char *fil_complete, const char *referer_adr, const char *referer_fil, char *save); int __cdecl htsshow_sendheader(t_hts_callbackarg * carg, httrackp * opt, char *buff, const char *adr, const char *fil, const char *referer_adr, const char *referer_fil, htsblk * outgoing); int __cdecl htsshow_receiveheader(t_hts_callbackarg * carg, httrackp * opt, char *buff, const char *adr, const char *fil, const char *referer_adr, const char *referer_fil, htsblk * incoming); int main(int argc, char **argv); void webhttrack_main(char *cmd); void webhttrack_lock(void); void webhttrack_release(void); #endif httrack-3.49.5/src/htsweb.c0000644000175000017500000006565014360553245012447 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: webhttrack.c routines */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #include #include #include #include #ifdef HAVE_SYS_TYPES_H #include #endif #ifdef HAVE_SYS_STAT_H #include #endif #ifdef HAVE_UNISTD_H #include #endif #include #ifndef _WIN32 #include #endif // htswrap_add #include "htsglobal.h" #include "htsbasenet.h" #include "htswrap.h" #include "httrack-library.h" #include "htsdefines.h" /* Threads */ #include "htsthread.h" /* External modules */ #include "coucal.c" #include "htsmd5.c" #include "md5.c" #include "htsserver.h" #include "htsweb.h" #if USE_BEGINTHREAD==0 #error fatal: no threads support #endif #ifdef _WIN32 #ifndef __cplusplus // DOS #include /* _beginthread, _endthread */ #endif #else #endif #undef DEBUG #if 0 #define DEBUG(A) do { A; } while(0) #else #define DEBUG(A) do {} while(0) #endif static htsmutex refreshMutex = HTSMUTEX_INIT; static int help_server(char *dest_path, int defaultPort); extern int commandRunning; extern int commandEnd; extern int commandReturn; extern int commandEndRequested; extern char *commandReturnMsg; extern char *commandReturnCmdl; static void htsweb_sig_brpipe(int code) { /* ignore */ } /* Number of background threads */ static int background_threads = 0; /* Server/client ping handling */ static htsmutex pingMutex = HTSMUTEX_INIT; static unsigned int pingId = 0; static unsigned int getPingId(void) { unsigned int id; hts_mutexlock(&pingMutex); id = pingId; hts_mutexrelease(&pingMutex); return id; } static void ping(void) { hts_mutexlock(&pingMutex); pingId++; hts_mutexrelease(&pingMutex); } static void client_ping(void *pP) { #ifndef _WIN32 /* Timeout to 120s ; normally client pings every 30 second */ static int timeout = 120; /* Wait for parent to die (legacy browser mode). */ const pid_t ppid = (pid_t) (uintptr_t) pP; while (!kill(ppid, 0)) { sleep(1); } /* Parent (webhttrack script) is dead: is client pinging ? */ for(;;) { unsigned int id = getPingId(); sleep(timeout); if (getPingId() == id) { break; } } /* Die! */ fprintf(stderr, "Parent process %d died, and client did not ping for %ds: exiting!\n", (int) ppid, timeout); exit(EXIT_FAILURE); #endif } static void pingHandler(void*arg) { ping(); } int main(int argc, char *argv[]) { int i; int ret = 0; int defaultPort = 0; int parentPid = 0; printf("Initializing the server..\n"); #ifdef _WIN32 { WORD wVersionRequested; // requested version WinSock API WSADATA wsadata; // Windows Sockets API data int stat; wVersionRequested = 0x0101; stat = WSAStartup(wVersionRequested, &wsadata); if (stat != 0) { fprintf(stderr, "Winsock not found!\n"); return -1; } else if (LOBYTE(wsadata.wVersion) != 1 && HIBYTE(wsadata.wVersion) != 1) { fprintf(stderr, "WINSOCK.DLL does not support version 1.1\n"); WSACleanup(); return -1; } } #endif if (argc < 2 || (argc % 2) != 0) { fprintf(stderr, "** Warning: use the webhttrack frontend if available\n"); fprintf(stderr, "usage: %s [--port ] [--ppid parent-pid] [key value [key value]..]\n", argv[0]); fprintf(stderr, "example: %s /usr/share/httrack/\n", argv[0]); return 1; } /* init and launch */ hts_init(); htslang_init(); /* set general keys */ #ifdef HTS_ETCPATH smallserver_setkey("ETCPATH", HTS_ETCPATH); #endif #ifdef HTS_BINPATH smallserver_setkey("BINPATH", HTS_BINPATH); #endif #ifdef HTS_LIBPATH smallserver_setkey("LIBPATH", HTS_LIBPATH); #endif #ifdef HTS_PREFIX smallserver_setkey("PREFIX", HTS_PREFIX); #endif #ifdef HTS_HTTRACKCNF smallserver_setkey("HTTRACKCNF", HTS_HTTRACKCNF); #endif #ifdef HTS_HTTRACKDIR smallserver_setkey("HTTRACKDIR", HTS_HTTRACKDIR); #endif #ifdef HTS_INET6 smallserver_setkey("INET6", "1"); #endif #ifdef HTS_USEOPENSSL smallserver_setkey("USEOPENSSL", "1"); #endif #ifdef HTS_DLOPEN smallserver_setkey("DLOPEN", "1"); #endif #ifdef HTS_USESWF smallserver_setkey("USESWF", "1"); #endif #ifdef HTS_USEZLIB smallserver_setkey("USEZLIB", "1"); #endif #ifdef _WIN32 smallserver_setkey("WIN32", "1"); #endif smallserver_setkey("HTTRACK_VERSION", HTTRACK_VERSION); smallserver_setkey("HTTRACK_VERSIONID", HTTRACK_VERSIONID); smallserver_setkey("HTTRACK_AFF_VERSION", HTTRACK_AFF_VERSION); { char tmp[32]; snprintf(tmp, sizeof(tmp), "%d", -1); smallserver_setkey("HTS_PLATFORM", tmp); } smallserver_setkey("HTTRACK_WEB", HTTRACK_WEB); /* Check version compatibility */ if (hts_sizeof_opt() != sizeof(httrackp)) { fprintf(stderr, "** CRITICAL: incompatible current httrack library version %s, expected version %s", hts_version(), HTTRACK_VERSIONID); smallserver_setkey("HTTRACK_INCOMPATIBLE_VERSIONID", hts_version()); } /* protected session-id */ { char buff[1024]; char digest[32 + 2]; srand((unsigned int) time(NULL)); snprintf(buff, sizeof(buff), "%d-%d", (int) time(NULL), (int) rand()); domd5mem(buff, strlen(buff), digest, 1); smallserver_setkey("sid", digest); smallserver_setkey("_sid", digest); } /* set commandline keys */ for(i = 2; i < argc; i += 2) { if (strcmp(argv[i], "--port") == 0 && i + 1 < argc) { if (sscanf(argv[i + 1], "%d", &defaultPort) != 1 || defaultPort < 0 || defaultPort >= 65535) { fprintf(stderr, "couldn't set the port number to %s\n", argv[i + 1]); return -1; } } else if (strcmp(argv[i], "--ppid") == 0 && i + 1 < argc) { if (sscanf(argv[i + 1], "%u", &parentPid) != 1) { fprintf(stderr, "couldn't set the parent PID to %s\n", argv[i + 1]); return -1; } } else if (i + 1 < argc) { smallserver_setkey(argv[i], argv[i + 1]); } else { fprintf(stderr, "Error in commandline!\n"); return -1; } } /* sigpipe */ #ifndef _WIN32 signal(SIGPIPE, htsweb_sig_brpipe); // broken pipe (write into non-opened socket) #endif /* pinger */ if (parentPid > 0) { hts_newthread(client_ping, (void *) (uintptr_t) parentPid); background_threads++; /* Do not wait for this thread! */ smallserver_setpinghandler(pingHandler, NULL); } /* launch */ ret = help_server(argv[1], defaultPort); htsthread_wait_n(background_threads - 1); hts_uninit(); #ifdef _WIN32 WSACleanup(); #endif return ret; } static int webhttrack_runmain(httrackp * opt, int argc, char **argv); static void back_launch_cmd(void *pP) { char *cmd = (char *) pP; char **argv = (char **) malloct(1024 * sizeof(char *)); int argc = 0; int i = 0; int g = 0; // httrackp *opt; /* copy commandline */ if (commandReturnCmdl) free(commandReturnCmdl); commandReturnCmdl = strdup(cmd); /* split */ argv[0] = strdup("webhttrack"); argv[1] = cmd; argc++; i = 0; while(cmd[i]) { if (cmd[i] == '\t' || cmd[i] == '\r' || cmd[i] == '\n') { cmd[i] = ' '; } i++; } i = 0; while(cmd[i]) { if (cmd[i] == '\"') g = !g; if (cmd[i] == ' ') { if (!g) { cmd[i] = '\0'; argv[argc++] = cmd + i + 1; } } i++; } /* init */ hts_init(); global_opt = opt = hts_create_opt(); assert(opt->size_httrackp == sizeof(httrackp)); /* run */ commandReturn = webhttrack_runmain(opt, argc, argv); if (commandReturn) { if (commandReturnMsg) free(commandReturnMsg); commandReturnMsg = strdup(hts_errmsg(opt)); } /* free */ global_opt = NULL; hts_free_opt(opt); hts_uninit(); /* okay */ commandRunning = 0; /* finished */ commandEnd = 1; DEBUG(fprintf(stderr, "commandEnd=1\n")); /* free */ free(cmd); freet(argv); return; } void webhttrack_main(char *cmd) { commandRunning = 1; DEBUG(fprintf(stderr, "commandRunning=1\n")); hts_newthread(back_launch_cmd, (void *) strdup(cmd)); background_threads++; /* Do not wait for this thread! */ } void webhttrack_lock(void) { hts_mutexlock(&refreshMutex); } void webhttrack_release(void) { hts_mutexrelease(&refreshMutex); } static int webhttrack_runmain(httrackp * opt, int argc, char **argv) { int ret; CHAIN_FUNCTION(opt, init, htsshow_init, NULL); CHAIN_FUNCTION(opt, uninit, htsshow_uninit, NULL); CHAIN_FUNCTION(opt, start, htsshow_start, NULL); CHAIN_FUNCTION(opt, end, htsshow_end, NULL); CHAIN_FUNCTION(opt, chopt, htsshow_chopt, NULL); CHAIN_FUNCTION(opt, preprocess, htsshow_preprocesshtml, NULL); CHAIN_FUNCTION(opt, postprocess, htsshow_postprocesshtml, NULL); CHAIN_FUNCTION(opt, check_html, htsshow_checkhtml, NULL); CHAIN_FUNCTION(opt, query, htsshow_query, NULL); CHAIN_FUNCTION(opt, query2, htsshow_query2, NULL); CHAIN_FUNCTION(opt, query3, htsshow_query3, NULL); CHAIN_FUNCTION(opt, loop, htsshow_loop, NULL); CHAIN_FUNCTION(opt, check_link, htsshow_check, NULL); CHAIN_FUNCTION(opt, check_mime, htsshow_check_mime, NULL); CHAIN_FUNCTION(opt, pause, htsshow_pause, NULL); CHAIN_FUNCTION(opt, filesave, htsshow_filesave, NULL); CHAIN_FUNCTION(opt, filesave2, htsshow_filesave2, NULL); CHAIN_FUNCTION(opt, linkdetected, htsshow_linkdetected, NULL); CHAIN_FUNCTION(opt, linkdetected2, htsshow_linkdetected2, NULL); CHAIN_FUNCTION(opt, xfrstatus, htsshow_xfrstatus, NULL); CHAIN_FUNCTION(opt, savename, htsshow_savename, NULL); CHAIN_FUNCTION(opt, sendhead, htsshow_sendheader, NULL); CHAIN_FUNCTION(opt, receivehead, htsshow_receiveheader, NULL); /* Rock'in! */ ret = hts_main2(argc, argv, opt); /* Wait for pending threads to finish */ htsthread_wait_n(background_threads); return ret; } static int help_server(char *dest_path, int defaultPort) { int returncode = 0; char adr_prox[HTS_URLMAXSIZE * 2]; int port_prox; T_SOC soc = smallserver_init_std(&port_prox, adr_prox, defaultPort); if (soc != INVALID_SOCKET) { char url[HTS_URLMAXSIZE * 2]; char method[32]; char data[32768]; url[0] = method[0] = data[0] = '\0'; // printf("Okay, temporary server installed.\nThe URL is:\n"); printf("URL=http://%s:%d/\n", adr_prox, port_prox); #ifndef _WIN32 { pid_t pid = getpid(); printf("PID=%d\n", (int) pid); } #endif fflush(stdout); fflush(stderr); // if (!smallserver(soc, url, method, data, dest_path)) { int last_errno = errno; fprintf(stderr, "Unable to create the server: %s\n", strerror(last_errno)); #ifdef _WIN32 closesocket(soc); #else close(soc); #endif printf("Done\n"); returncode = 1; } else { returncode = 0; } } else { fprintf(stderr, "Unable to initialize a temporary server (no remaining port)\n"); returncode = 1; } printf("EXITED\n"); fflush(stdout); fflush(stderr); return returncode; } /* CALLBACK FUNCTIONS */ /* Initialize the Winsock */ void __cdecl htsshow_init(t_hts_callbackarg * carg) { } void __cdecl htsshow_uninit(t_hts_callbackarg * carg) { } int __cdecl htsshow_start(t_hts_callbackarg * carg, httrackp * opt) { DEBUG(fprintf(stderr, "htsshow_start()\n")); return 1; } int __cdecl htsshow_chopt(t_hts_callbackarg * carg, httrackp * opt) { return htsshow_start(carg, opt); } int __cdecl htsshow_end(t_hts_callbackarg * carg, httrackp * opt) { DEBUG(fprintf(stderr, "htsshow_end()\n")); return 1; } int __cdecl htsshow_preprocesshtml(t_hts_callbackarg * carg, httrackp * opt, char **html, int *len, const char *url_address, const char *url_file) { return 1; } int __cdecl htsshow_postprocesshtml(t_hts_callbackarg * carg, httrackp * opt, char **html, int *len, const char *url_address, const char *url_file) { return 1; } int __cdecl htsshow_checkhtml(t_hts_callbackarg * carg, httrackp * opt, char *html, int len, const char *url_address, const char *url_file) { return 1; } int __cdecl htsshow_loop(t_hts_callbackarg * carg, httrackp * opt, lien_back * back, int back_max, int back_index, int lien_n, int lien_tot, int stat_time, hts_stat_struct * stats) { // appelé à chaque boucle de HTTrack static TStamp prev_mytime = 0; /* ok */ static t_InpInfo SInfo; /* ok */ // TStamp mytime; long int rate = 0; // int stat_written = -1; int stat_updated = -1; int stat_errors = -1; int stat_warnings = -1; int stat_infos = -1; int nbk = -1; int stat_nsocket = -1; LLint stat_bytes = -1; LLint stat_bytes_recv = -1; int irate = -1; // char st[256]; /* Exit now */ if (commandEndRequested == 2) return 0; /* Lock */ webhttrack_lock(); if (stats) { stat_written = stats->stat_files; stat_updated = stats->stat_updated_files; stat_errors = stats->stat_errors; stat_warnings = stats->stat_warnings; stat_infos = stats->stat_infos; nbk = stats->nbk; stat_nsocket = stats->stat_nsocket; irate = (int) stats->rate; stat_bytes = stats->nb; stat_bytes_recv = stats->HTS_TOTAL_RECV; } mytime = mtime_local(); if ((stat_time > 0) && (stat_bytes_recv > 0)) rate = (int) (stat_bytes_recv / stat_time); else rate = 0; // pas d'infos /* Infos */ if (stat_bytes >= 0) SInfo.stat_bytes = stat_bytes; // bytes if (stat_time >= 0) SInfo.stat_time = stat_time; // time if (lien_tot >= 0) SInfo.lien_tot = lien_tot; // nb liens if (lien_n >= 0) SInfo.lien_n = lien_n; // scanned SInfo.stat_nsocket = stat_nsocket; // socks if (rate > 0) SInfo.rate = rate; // rate if (irate >= 0) SInfo.irate = irate; // irate if (SInfo.irate < 0) SInfo.irate = SInfo.rate; if (nbk >= 0) SInfo.stat_back = nbk; if (stat_written >= 0) SInfo.stat_written = stat_written; if (stat_updated >= 0) SInfo.stat_updated = stat_updated; if (stat_errors >= 0) SInfo.stat_errors = stat_errors; if (stat_warnings >= 0) SInfo.stat_warnings = stat_warnings; if (stat_infos >= 0) SInfo.stat_infos = stat_infos; st[0] = '\0'; qsec2str(st, stat_time); /* Set keys */ smallserver_setkeyint("info.stat_bytes", SInfo.stat_bytes); smallserver_setkeyint("info.stat_time", SInfo.stat_time); smallserver_setkeyint("info.lien_tot", SInfo.lien_tot); smallserver_setkeyint("info.lien_n", SInfo.lien_n); smallserver_setkeyint("info.stat_nsocket", SInfo.stat_nsocket); smallserver_setkeyint("info.rate", SInfo.rate); smallserver_setkeyint("info.irate", SInfo.irate); smallserver_setkeyint("info.stat_back", SInfo.stat_back); smallserver_setkeyint("info.stat_written", SInfo.stat_written); smallserver_setkeyint("info.stat_updated", SInfo.stat_updated); smallserver_setkeyint("info.stat_errors", SInfo.stat_errors); smallserver_setkeyint("info.stat_warnings", SInfo.stat_warnings); smallserver_setkeyint("info.stat_infos", SInfo.stat_infos); /* */ smallserver_setkey("info.stat_time_str", st); if (((mytime - prev_mytime) > 100) || ((mytime - prev_mytime) < 0)) { prev_mytime = mytime; // parcourir registre des liens if (back_index >= 0 && back_max > 0) { // seulement si index passé int j, k; int index = 0; int ok = 0; // idem int l; // idem // t_StatsBuffer StatsBuffer[NStatsBuffer]; { int i; for(i = 0; i < NStatsBuffer; i++) { strcpybuff(StatsBuffer[i].state, ""); strcpybuff(StatsBuffer[i].name, ""); strcpybuff(StatsBuffer[i].file, ""); strcpybuff(StatsBuffer[i].url_sav, ""); StatsBuffer[i].back = 0; StatsBuffer[i].size = 0; StatsBuffer[i].sizetot = 0; } } for(k = 0; k < 2; k++) { // 0: lien en cours 1: autres liens for(j = 0; (j < 3) && (index < NStatsBuffer); j++) { // passe de priorité int _i; for(_i = 0 + k; (_i < max(back_max * k, 1)) && (index < NStatsBuffer); _i++) { // no lien int i = (back_index + _i) % back_max; // commencer par le "premier" (l'actuel) if (back[i].status >= 0) { // signifie "lien actif" // int ok=0; // OPTI ok = 0; switch (j) { case 0: // prioritaire if ((back[i].status > 0) && (back[i].status < 99)) { strcpybuff(StatsBuffer[index].state, "receive"); ok = 1; } break; case 1: if (back[i].status == STATUS_WAIT_HEADERS) { strcpybuff(StatsBuffer[index].state, "request"); ok = 1; } else if (back[i].status == STATUS_CONNECTING) { strcpybuff(StatsBuffer[index].state, "connect"); ok = 1; } else if (back[i].status == STATUS_WAIT_DNS) { strcpybuff(StatsBuffer[index].state, "search"); ok = 1; } else if (back[i].status == STATUS_FTP_TRANSFER) { // ohh le beau ftp char proto[] = "ftp"; if (back[i].url_adr[0]) { char *ep = strchr(back[i].url_adr, ':'); char *eps = strchr(back[i].url_adr, '/'); int count; if (ep != NULL && ep < eps && (count = (int) (ep - back[i].url_adr)) < 4) { proto[0] = '\0'; strncat(proto, back[i].url_adr, count); } } snprintf(StatsBuffer[index].state, sizeof(StatsBuffer[index].state), "%s: %s", proto, back[i].info); ok = 1; } break; default: if (back[i].status == STATUS_READY) { // prêt if (back[i].r.statuscode == HTTP_OK) { strcpybuff(StatsBuffer[index].state, "ready"); ok = 1; } else if (back[i].r.statuscode >= 100 && back[i].r.statuscode <= 599) { char tempo[256]; tempo[0] = '\0'; infostatuscode(tempo, back[i].r.statuscode); strcpybuff(StatsBuffer[index].state, tempo); ok = 1; } else { strcpybuff(StatsBuffer[index].state, "error"); ok = 1; } } break; } if (ok) { char s[HTS_URLMAXSIZE * 2]; // StatsBuffer[index].back = i; // index pour + d'infos // s[0] = '\0'; strcpybuff(StatsBuffer[index].url_sav, back[i].url_sav); // pour cancel if (strcmp(back[i].url_adr, "file://")) strcatbuff(s, back[i].url_adr); else strcatbuff(s, "localhost"); if (back[i].url_fil[0] != '/') strcatbuff(s, "/"); strcatbuff(s, back[i].url_fil); StatsBuffer[index].file[0] = '\0'; { char *a = strrchr(s, '/'); if (a) { strncatbuff(StatsBuffer[index].file, a, 200); *a = '\0'; } } if ((l = (int) strlen(s)) < MAX_LEN_INPROGRESS) strcpybuff(StatsBuffer[index].name, s); else { // couper StatsBuffer[index].name[0] = '\0'; strncatbuff(StatsBuffer[index].name, s, MAX_LEN_INPROGRESS / 2 - 2); strcatbuff(StatsBuffer[index].name, "..."); strcatbuff(StatsBuffer[index].name, s + l - MAX_LEN_INPROGRESS / 2 + 2); } if (back[i].r.totalsize > 0) { // taille prédéfinie StatsBuffer[index].sizetot = back[i].r.totalsize; StatsBuffer[index].size = back[i].r.size; } else { // pas de taille prédéfinie if (back[i].status == STATUS_READY) { // prêt StatsBuffer[index].sizetot = back[i].r.size; StatsBuffer[index].size = back[i].r.size; } else { StatsBuffer[index].sizetot = 8192; StatsBuffer[index].size = (back[i].r.size % 8192); } } index++; } } } } } /* Display current job */ { int parsing = 0; if (commandEndRequested) smallserver_setkey("info.currentjob", "finishing pending transfers - Select [Cancel] to stop now!"); else if (!(parsing = hts_is_parsing(opt, -1))) smallserver_setkey("info.currentjob", "receiving files"); else { char tmp[1024]; tmp[0] = '\0'; switch (hts_is_testing(opt)) { case 0: snprintf(tmp, sizeof(tmp), "parsing HTML file (%d%%)", parsing); break; case 1: snprintf(tmp, sizeof(tmp), "parsing HTML file: testing links (%d%%)", parsing); break; case 2: snprintf(tmp, sizeof(tmp), "purging files"); break; case 3: snprintf(tmp, sizeof(tmp), "loading cache"); break; case 4: snprintf(tmp, sizeof(tmp), "waiting (scheduler)"); break; case 5: snprintf(tmp, sizeof(tmp), "waiting (throttle)"); break; } smallserver_setkey("info.currentjob", tmp); } } /* Display background jobs */ { int i; for(i = 0; i < NStatsBuffer; i++) { if (strnotempty(StatsBuffer[i].state)) { strc_int2bytes2 strc; smallserver_setkeyarr("info.state[", i, "]", StatsBuffer[i].state); smallserver_setkeyarr("info.name[", i, "]", StatsBuffer[i].name); smallserver_setkeyarr("info.file[", i, "]", StatsBuffer[i].file); smallserver_setkeyarr("info.size[", i, "]", int2bytes(&strc, StatsBuffer[i].size)); smallserver_setkeyarr("info.sizetot[", i, "]", int2bytes(&strc, StatsBuffer[i].sizetot)); smallserver_setkeyarr("info.url_adr[", i, "]", StatsBuffer[i].url_adr); smallserver_setkeyarr("info.url_fil[", i, "]", StatsBuffer[i].url_fil); smallserver_setkeyarr("info.url_sav[", i, "]", StatsBuffer[i].url_sav); } } } } } /* UnLock */ webhttrack_release(); return 1; } const char *__cdecl htsshow_query(t_hts_callbackarg * carg, httrackp * opt, const char *question) { static char s[] = ""; /* ok */ return s; } const char *__cdecl htsshow_query2(t_hts_callbackarg * carg, httrackp * opt, const char *question) { static char s[] = ""; /* ok */ return s; } const char *__cdecl htsshow_query3(t_hts_callbackarg * carg, httrackp * opt, const char *question) { static char s[] = ""; /* ok */ return s; } int __cdecl htsshow_check(t_hts_callbackarg * carg, httrackp * opt, const char *adr, const char *fil, int status) { return -1; } int __cdecl htsshow_check_mime(t_hts_callbackarg * carg, httrackp * opt, const char *adr, const char *fil, const char *mime, int status) { return -1; } void __cdecl htsshow_pause(t_hts_callbackarg * carg, httrackp * opt, const char *lockfile) { } void __cdecl htsshow_filesave(t_hts_callbackarg * carg, httrackp * opt, const char *file) { } void __cdecl htsshow_filesave2(t_hts_callbackarg * carg, httrackp * opt, const char *adr, const char *fil, const char *save, int is_new, int is_modified, int not_updated) { } int __cdecl htsshow_linkdetected(t_hts_callbackarg * carg, httrackp * opt, char *link) { return 1; } int __cdecl htsshow_linkdetected2(t_hts_callbackarg * carg, httrackp * opt, char *link, const char *start_tag) { return 1; } int __cdecl htsshow_xfrstatus(t_hts_callbackarg * carg, httrackp * opt, lien_back * back) { return 1; } int __cdecl htsshow_savename(t_hts_callbackarg * carg, httrackp * opt, const char *adr_complete, const char *fil_complete, const char *referer_adr, const char *referer_fil, char *save) { return 1; } int __cdecl htsshow_sendheader(t_hts_callbackarg * carg, httrackp * opt, char *buff, const char *adr, const char *fil, const char *referer_adr, const char *referer_fil, htsblk * outgoing) { return 1; } int __cdecl htsshow_receiveheader(t_hts_callbackarg * carg, httrackp * opt, char *buff, const char *adr, const char *fil, const char *referer_adr, const char *referer_fil, htsblk * incoming) { return 1; } httrack-3.49.5/src/htsserver.h0000644000175000017500000002044414336470674013204 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Mini-server */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ // Fichier intercepteur d'URL .h #ifndef HTS_SERVER_DEFH #define HTS_SERVER_DEFH #include #include "htsnet.h" /* String */ #include "htsstrings.h" // Fonctions void socinput(T_SOC soc, char *s, int max); T_SOC smallserver_init_std(int *port_prox, char *adr_prox, int defaultPort); T_SOC smallserver_init(int *port, char *adr); int smallserver(T_SOC soc, char *url, char *method, char *data, char *path); #define CATCH_RESPONSE \ "HTTP/1.0 200 OK\r\n"\ "Content-type: text/html\r\n"\ "\r\n"\ "\r\n"\ "\r\n"\ "Link caught!\r\n"\ "\r\n"\ "\r\n"\ "\r\n"\ "

Link captured into HTTrack Website Copier, you can now restore your proxy preferences!

\r\n"\ "

\r\n"\ "

Clic here to go back

\r\n"\ ""\ "\r\n"\ "\r\n"\ extern int NewLangStrSz; extern coucal NewLangStr; extern int NewLangStrKeysSz; extern coucal NewLangStrKeys; extern int NewLangListSz; extern coucal NewLangList; extern httrackp *global_opt; /* Spaces: CR,LF,TAB,FF */ #define is_space(c) ( ((c)==' ') || ((c)=='\"') || ((c)==10) || ((c)==13) || ((c)==9) || ((c)==12) || ((c)==11) || ((c)=='\'') ) #define is_realspace(c) ( ((c)==' ') || ((c)==10) || ((c)==13) || ((c)==9) || ((c)==12) || ((c)==11) ) #define is_taborspace(c) ( ((c)==' ') || ((c)==9) ) #define is_quote(c) ( ((c)=='\"') || ((c)=='\'') ) #define is_retorsep(c) ( ((c)==10) || ((c)==13) || ((c)==9) ) #undef min #undef max #define min(a,b) ((a)>(b)?(b):(a)) #define max(a,b) ((a)>(b)?(a):(b)) extern void smallserver_setpinghandler(void (*fun)(void*), void*arg); extern int smallserver_setkey(const char *key, const char *value); extern int smallserver_setkeyint(const char *key, LLint value); extern int smallserver_setkeyarr(const char *key, int id, const char *key2, const char *value); int htslang_init(void); int htslang_uninit(void); /* Static definitions */ HTS_UNUSED static const char *gethomedir(void); HTS_UNUSED static int linput_cpp(FILE * fp, char *s, int max); HTS_UNUSED static int linput_trim(FILE * fp, char *s, int max); HTS_UNUSED static int fexist(const char *s); HTS_UNUSED static int linput(FILE * fp, char *s, int max); HTS_UNUSED static int linputsoc(T_SOC soc, char *s, int max) { int c; int j = 0; do { unsigned char ch; if (recv(soc, &ch, 1, 0) == 1) { c = ch; } else { c = EOF; } if (c != EOF) { switch (c) { case 13: break; // sauter CR case 10: c = -1; break; case 9: case 12: break; // sauter ces caractères default: s[j++] = (char) c; break; } } } while((c != -1) && (c != EOF) && (j < (max - 1))); s[j] = '\0'; return j; } HTS_UNUSED static int check_readinput_t(T_SOC soc, int timeout) { if (soc != INVALID_SOCKET) { fd_set fds; // poll structures struct timeval tv; // structure for select FD_ZERO(&fds); FD_SET(soc, &fds); tv.tv_sec = timeout; tv.tv_usec = 0; select((int) soc + 1, &fds, NULL, NULL, &tv); if (FD_ISSET(soc, &fds)) return 1; else return 0; } else return 0; } HTS_UNUSED static int linputsoc_t(T_SOC soc, char *s, int max, int timeout) { if (check_readinput_t(soc, timeout)) { return linputsoc(soc, s, max); } return -1; } static const char *gethomedir(void) { const char *home = getenv("HOME"); if (home) return home; else return "."; } static int linput_cpp(FILE * fp, char *s, int max) { int rlen = 0; s[0] = '\0'; do { int ret; if (rlen > 0) if (s[rlen - 1] == '\\') s[--rlen] = '\0'; // couper \ final // lire ligne ret = linput_trim(fp, s + rlen, max - rlen); if (ret > 0) rlen += ret; } while((s[max(rlen - 1, 0)] == '\\') && (rlen < max)); return rlen; } static int fexist(const char *s) { struct stat st; memset(&st, 0, sizeof(st)); if (stat(s, &st) == 0) { if (S_ISREG(st.st_mode)) { return 1; } } return 0; } static int linput(FILE * fp, char *s, int max) { int c; int j = 0; do { c = fgetc(fp); if (c != EOF) { switch (c) { case 13: break; // sauter CR case 10: c = -1; break; case 0: case 9: case 12: break; // sauter ces caractères default: s[j++] = (char) c; break; } } } while((c != -1) && (c != EOF) && (j < (max - 1))); s[j] = '\0'; return j; } static int linput_trim(FILE * fp, char *s, int max) { int rlen = 0; char *ls = (char *) malloc(max + 1); s[0] = '\0'; if (ls) { char *a; // lire ligne rlen = linput(fp, ls, max); if (rlen) { // sauter espaces et tabs en fin while((rlen > 0) && is_realspace(ls[max(rlen - 1, 0)])) ls[--rlen] = '\0'; // sauter espaces en début a = ls; while((rlen > 0) && ((*a == ' ') || (*a == '\t'))) { a++; rlen--; } if (rlen > 0) { memcpy(s, a, rlen); // can copy \0 chars s[rlen] = '\0'; } } // free(ls); } return rlen; } static int ehexh(char c) { if ((c >= '0') && (c <= '9')) return c - '0'; if ((c >= 'a') && (c <= 'f')) c -= ('a' - 'A'); if ((c >= 'A') && (c <= 'F')) return (c - 'A' + 10); return 0; } static int ehex(const char *s) { return 16 * ehexh(*s) + ehexh(*(s + 1)); } HTS_UNUSED static void unescapehttp(const char *s, String * tempo) { size_t i; for(i = 0; s[i] != '\0'; i++) { if (s[i] == '%' && s[i + 1] == '%') { i++; StringAddchar(*tempo, '%'); } else if (s[i] == '%') { char hc; i++; hc = (char) ehex(s + i); StringAddchar(*tempo, (char) hc); i++; // sauter 2 caractères finalement } else if (s[i] == '+') { StringAddchar(*tempo, ' '); } else StringAddchar(*tempo, s[i]); } } HTS_UNUSED static void unescapeini(char *s, String * tempo) { size_t i; char lastc = 0; for(i = 0; s[i] != '\0'; i++) { if (s[i] == '%' && s[i + 1] == '%') { i++; StringAddchar(*tempo, lastc = '%'); } else if (s[i] == '%') { char hc; i++; hc = (char) ehex(s + i); if (!is_retorsep(hc) || !is_retorsep(lastc)) { StringAddchar(*tempo, lastc = (char) hc); } i++; // sauter 2 caractères finalement } else StringAddchar(*tempo, lastc = s[i]); } } #endif httrack-3.49.5/src/htsserver.c0000644000175000017500000016231014360553246013170 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Mini-server */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* specific definitions */ /* specific definitions */ /* Bypass internal definition protection */ #define HTS_INTERNAL_BYTECODE #include "htsbase.h" #undef HTS_INTERNAL_BYTECODE #include "htsnet.h" #include "htslib.h" #include #include #include #include #include #ifdef _WIN32 #else #include #endif #ifndef _WIN32 #include #endif /* END specific definitions */ /* définitions globales */ #include "htsglobal.h" /* htslib */ /*#include "htslib.h"*/ /* HTTrack Website Copier Library */ #include "httrack-library.h" /* Language files */ /* Bypass internal definition protection */ #define HTS_INTERNAL_BYTECODE #include "coucal.h" #undef HTS_INTERNAL_BYTECODE int NewLangStrSz = 1024; coucal NewLangStr = NULL; int NewLangStrKeysSz = 1024; coucal NewLangStrKeys = NULL; int NewLangListSz = 1024; coucal NewLangList = NULL; /* Language files */ #include "htsserver.h" const char *gethomedir(void); int commandRunning = 0; int commandEndRequested = 0; int commandEnd = 0; int commandReturn = 0; char *commandReturnMsg = NULL; char *commandReturnCmdl = NULL; int commandReturnSet = 0; httrackp *global_opt = NULL; static void (*pingFun)(void*) = NULL; static void* pingFunArg = NULL; /* Extern */ extern void webhttrack_main(char *cmd); extern void webhttrack_lock(void); extern void webhttrack_release(void); static int is_image(const char *file) { return strstr(file, ".gif") != NULL || strstr(file, ".png") != NULL; } static int is_text(const char *file) { return ((strstr(file, ".txt") != NULL)); } static int is_html(const char *file) { return ((strstr(file, ".htm") != NULL)); } static int is_css(const char *file) { return ((strstr(file, ".css") != NULL)); } static int is_js(const char *file) { return ((strstr(file, ".js") != NULL)); } static void sig_brpipe(int code) { /* ignore */ } HTS_UNUSED static int check_readinput_t(T_SOC soc, int timeout); HTS_UNUSED static int recv_bl(T_SOC soc, void *buffer, size_t len, int timeout); HTS_UNUSED static int linputsoc(T_SOC soc, char *s, int max); HTS_UNUSED static int check_readinput(htsblk * r); HTS_UNUSED static int linputsoc_t(T_SOC soc, char *s, int max, int timeout); HTS_UNUSED static int linput(FILE * fp, char *s, int max); /* Language files */ HTS_UNUSED static int htslang_load(char *limit_to, const char *apppath); HTS_UNUSED static void conv_printf(const char *from, char *to); HTS_UNUSED static void LANG_DELETE(void); HTS_UNUSED static void LANG_INIT(const char *path); HTS_UNUSED static int LANG_T(const char *path, int l); HTS_UNUSED static int QLANG_T(int l); HTS_UNUSED static const char *LANGSEL(const char *name); HTS_UNUSED static const char *LANGINTKEY(const char *name); HTS_UNUSED static int LANG_SEARCH(const char *path, const char *iso); HTS_UNUSED static int LANG_LIST(const char *path, char *buffer, size_t size); // URL Link catcher // 0- Init the URL catcher with standard port // smallserver_init(&port,&return_host); T_SOC smallserver_init_std(int *port_prox, char *adr_prox, int defaultPort) { T_SOC soc; if (defaultPort <= 0) { int try_to_listen_to[] = { 8080, 8081, 8082, 8083, 8084, 8085, 8086, 8087, 8088, 8089, 32000, 32001, 32002, 32003, 32004, 32006, 32006, 32007, 32008, 32009, 42000, 42001, 42002, 42003, 42004, 42006, 42006, 42007, 42008, 42009, 0, -1 }; int i = 0; do { soc = smallserver_init(&try_to_listen_to[i], adr_prox); *port_prox = try_to_listen_to[i]; i++; } while((soc == INVALID_SOCKET) && (try_to_listen_to[i] >= 0)); } else { soc = smallserver_init(&defaultPort, adr_prox); *port_prox = defaultPort; } return soc; } // 1- Init the URL catcher // get hostname. return 1 upon success. static int gethost(const char *hostname, SOCaddr * server) { if (hostname != NULL && *hostname != '\0') { #if HTS_INET6==0 /* ipV4 resolver */ struct hostent *hp = gethostbyname(hostname); if (hp != NULL) { if (hp->h_length) { SOCaddr_copyaddr2(*server, hp->h_addr_list[0], hp->h_length); return 1; } } #else /* ipV6 resolver */ struct addrinfo *res = NULL; struct addrinfo hints; memset(&hints, 0, sizeof(hints)); hints.ai_family = PF_UNSPEC; hints.ai_socktype = SOCK_STREAM; hints.ai_protocol = IPPROTO_TCP; if (getaddrinfo(hostname, NULL, &hints, &res) == 0) { if (res) { if ((res->ai_addr) && (res->ai_addrlen)) { SOCaddr_copyaddr2(*server, res->ai_addr, res->ai_addrlen); freeaddrinfo(res); return 1; } } } if (res) { freeaddrinfo(res); } #endif } return 0; } static int my_getlocalhost(char *h_loc, size_t size) { SOCaddr addr; strcpy(h_loc, "localhost"); if (gethost(h_loc, &addr) == 1) { return 0; } // come on ... else { strcpy(h_loc, "127.0.0.1"); return 0; } } // get local hostname; falls back to "localhost" in case of error // always returns 0 static int my_gethostname(char *h_loc, size_t size) { h_loc[0] = '\0'; if (gethostname(h_loc, (int) size) == 0) { // host name SOCaddr addr; if (gethost(h_loc, &addr) == 1) { return 0; } else { return my_getlocalhost(h_loc, size); } } else { return my_getlocalhost(h_loc, size); } return 0; } // smallserver_init(&port,&return_host); T_SOC smallserver_init(int *port, char *adr) { T_SOC soc = INVALID_SOCKET; char h_loc[256 + 2]; commandRunning = commandEnd = commandReturn = commandReturnSet = commandEndRequested = 0; if (commandReturnMsg) free(commandReturnMsg); commandReturnMsg = NULL; if (commandReturnCmdl) free(commandReturnCmdl); commandReturnCmdl = NULL; if (my_gethostname(h_loc, 256) == 0) { // host name SOCaddr server; SOCaddr_initany(server); if ((soc = (T_SOC) socket(SOCaddr_sinfamily(server), SOCK_STREAM, 0)) != INVALID_SOCKET) { SOCaddr_initport(server, *port); if (bind(soc, &SOCaddr_sockaddr(server), SOCaddr_size(server)) == 0) { if (listen(soc, 10) >= 0) { // SOCaddr_inetntoa(adr, 128, server2); strcpy(adr, h_loc); } else { #ifdef _WIN32 closesocket(soc); #else close(soc); #endif soc = INVALID_SOCKET; } } else { #ifdef _WIN32 closesocket(soc); #else close(soc); #endif soc = INVALID_SOCKET; } } } return soc; } // 2 - Wait for URL // check if data is available // smallserver // returns 0 if error // url: buffer where URL must be stored - or ip:port in case of failure // data: 32Kb typedef struct { const char *name; int value; } initIntElt; typedef struct { const char *name; const char *value; } initStrElt; #define SET_ERROR(err) do { \ coucal_write(NewLangList, "error", (intptr_t)strdup(err)); \ error_redirect = "/server/error.html"; \ } while(0) int smallserver(T_SOC soc, char *url, char *method, char *data, char *path) { int timeout = 30; int retour = 0; int willexit = 0; int buffer_size = 32768; char *buffer = (char *) malloc(buffer_size); String headers = STRING_EMPTY; String output = STRING_EMPTY; String tmpbuff = STRING_EMPTY; String tmpbuff2 = STRING_EMPTY; String fspath = STRING_EMPTY; char catbuff[CATBUFF_SIZE]; /* Load strings */ htslang_init(); if (!htslang_load(NULL, path)) { fprintf(stderr, "unable to find lang.def and/or lang/ strings in %s\n", path); return 0; } LANG_T(path, 0); /* Init various values */ { char pth[1024]; const char *initOn[] = { "parseall", "Cache", "ka", "cookies", "parsejava", "testall", "updhack", "urlhack", "index", NULL }; const initIntElt initInt[] = { {"filter", 4}, {"travel", 2}, {"travel2", 1}, {"travel3", 1}, /* */ {"connexion", 4}, /* */ {"maxrate", 100000}, /* */ {"build", 1}, /* */ {"checktype", 2}, {"robots", 3}, {NULL, 0} }; initStrElt initStr[] = { {"user", "Mozilla/4.5 (compatible; HTTrack 3.0x; Windows 98)"}, {"footer", ""}, {"url2", "+*.png +*.gif +*.jpg +*.jpeg +*.css +*.js -ad.doubleclick.net/*"}, {NULL, NULL} }; int i = 0; for(i = 0; initInt[i].name; i++) { char tmp[32]; sprintf(tmp, "%d", initInt[i].value); coucal_write(NewLangList, initInt[i].name, (intptr_t) strdup(tmp)); } for(i = 0; initOn[i]; i++) { coucal_write(NewLangList, initOn[i], (intptr_t) strdup("1")); /* "on" */ } for(i = 0; initStr[i].name; i++) { coucal_write(NewLangList, initStr[i].name, (intptr_t) strdup(initStr[i].value)); } strcpybuff(pth, gethomedir()); strcatbuff(pth, "/websites"); coucal_write(NewLangList, "path", (intptr_t) strdup(pth)); } /* Lock */ webhttrack_lock(); // connexion (accept) while(!willexit && buffer != NULL && soc != INVALID_SOCKET) { char line1[1024]; char line[8192]; char line2[1024]; T_SOC soc_c; LLint length = 0; const char *error_redirect = NULL; line[0] = '\0'; buffer[0] = '\0'; StringClear(headers); StringClear(output); StringClear(tmpbuff); StringClear(tmpbuff2); StringClear(fspath); StringCat(headers, ""); StringCat(output, ""); StringCat(tmpbuff, ""); StringCat(tmpbuff2, ""); StringCat(fspath, ""); /* UnLock */ webhttrack_release(); /* sigpipe */ #ifndef _WIN32 signal(SIGPIPE, sig_brpipe); #endif /* Accept */ while((soc_c = (T_SOC) accept(soc, NULL, NULL)) == INVALID_SOCKET) ; /* Ping */ if (pingFun != NULL) { pingFun(pingFunArg); } /* Lock */ webhttrack_lock(); if (linputsoc_t(soc_c, line1, sizeof(line1) - 2, timeout) > 0) { int meth = 0; if (strfield(line1, "get ")) { meth = 1; } else if (strfield(line1, "post ")) { meth = 2; } else if (strfield(line1, "head ")) { /* yes, we can do that */ meth = 10; } else { #ifdef _DEBUG // assert(FALSE); #endif } if (meth) { /* Flush headers */ length = buffer_size - 2; while(linputsoc_t(soc_c, line, sizeof(line) - 2, timeout) > 0) { int p; if ((p = strfield(line, "Content-length:")) != 0) { sscanf(line + p, LLintP, &(length)); } else if ((p = strfield(line, "Accept-language:")) != 0) { char tmp[32]; char *s = line + p; /*int l; */ while(*s == ' ') s++; tmp[0] = '\0'; strncatbuff(tmp, s, 2); /*l = LANG_SEARCH(path, tmp); */ } } if (meth == 2) { int sz = 0; if (length > buffer_size - 2) { length = buffer_size - 2; } if (length > 0 && (sz = recv_bl(soc_c, buffer, (int) length, timeout)) < 0) { meth = 0; } else { buffer[sz] = '\0'; } } } /* Generated variables */ if (commandEnd && !commandReturnSet) { commandReturnSet = 1; if (commandReturn) { char tmp[32]; sprintf(tmp, "%d", commandReturn); coucal_write(NewLangList, "commandReturn", (intptr_t) strdup(tmp)); coucal_write(NewLangList, "commandReturnMsg", (intptr_t) commandReturnMsg); coucal_write(NewLangList, "commandReturnCmdl", (intptr_t) commandReturnCmdl); } else { coucal_write(NewLangList, "commandReturn", (intptr_t) NULL); coucal_write(NewLangList, "commandReturnMsg", (intptr_t) NULL); coucal_write(NewLangList, "commandReturnCmdl", (intptr_t) NULL); } } /* SID check */ { intptr_t adr = 0; if (coucal_readptr(NewLangList, "_sid", &adr)) { if (coucal_write (NewLangList, "sid", (intptr_t) strdup((char *) adr))) { } } } /* check variables */ if (meth && buffer[0]) { char *s = buffer; char *e, *f; strcatbuff(buffer, "&"); while(s && (e = strchr(s, '=')) && (f = strchr(s, '&'))) { const char *ua; String sua = STRING_EMPTY; *e = *f = '\0'; ua = e + 1; if (strfield2(ua, "on")) /* hack : "on" == 1 */ ua = "1"; unescapehttp(ua, &sua); coucal_write(NewLangList, s, (intptr_t) StringAcquire(&sua)); s = f + 1; } } /* Error check */ { intptr_t adr = 0; intptr_t adr2 = 0; if (coucal_readptr(NewLangList, "sid", &adr)) { if (coucal_readptr(NewLangList, "_sid", &adr2)) { if (strcmp((char *) adr, (char *) adr2) != 0) { meth = 0; } } } } /* Check variables (internal) */ if (meth) { int doLoad = 0; intptr_t adr = 0; if (coucal_readptr(NewLangList, "lang", &adr)) { int n = 0; if (sscanf((char *) adr, "%d", &n) == 1 && n > 0 && n - 1 != LANG_T(path, -1)) { LANG_T(path, n - 1); /* make a backup, because the GUI will override it */ coucal_write(NewLangList, "lang_", (intptr_t) strdup((char *) adr)); } } /* Load existing project settings */ if (coucal_readptr(NewLangList, "loadprojname", &adr)) { char *pname = (char *) adr; if (*pname) { coucal_write(NewLangList, "projname", (intptr_t) strdup(pname)); } coucal_write(NewLangList, "loadprojname", (intptr_t) NULL); doLoad = 1; } else if (coucal_readptr(NewLangList, "loadprojcateg", &adr)) { char *pname = (char *) adr; if (*pname) { coucal_write(NewLangList, "projcateg", (intptr_t) strdup(pname)); } coucal_write(NewLangList, "loadprojcateg", (intptr_t) NULL); } /* intial configuration */ { if (!coucal_read(NewLangList, "conf_file_loaded", NULL)) { coucal_write(NewLangList, "conf_file_loaded", (intptr_t) strdup("true")); doLoad = 2; } } /* path : / */ if (!commandRunning) { intptr_t adrpath = 0, adrprojname = 0; if (coucal_readptr(NewLangList, "path", &adrpath) && coucal_readptr(NewLangList, "projname", &adrprojname)) { StringClear(fspath); StringCat(fspath, (char *) adrpath); StringCat(fspath, "/"); StringCat(fspath, (char *) adrprojname); } } /* Load existing project settings */ if (doLoad) { FILE *fp; if (doLoad == 1) { StringCat(fspath, "/hts-cache/winprofile.ini"); } else if (doLoad == 2) { StringCopy(fspath, gethomedir()); #ifdef _WIN32 StringCat(fspath, "/httrack.ini"); #else StringCat(fspath, "/.httrack.ini"); #endif } fp = fopen(StringBuff(fspath), "rb"); if (fp) { /* Read file */ while(!feof(fp)) { char *str = line; char *pos; if (!linput(fp, line, sizeof(line) - 2)) { *str = '\0'; } pos = strchr(line, '='); if (pos) { String escline = STRING_EMPTY; *pos++ = '\0'; if (pos[0] == '0' && pos[1] == '\0') *pos = '\0'; /* 0 => empty */ unescapeini(pos, &escline); coucal_write(NewLangList, line, (intptr_t) StringAcquire(&escline)); } } fclose(fp); } } } /* Execute command */ { intptr_t adr = 0; int p = 0; if (coucal_readptr(NewLangList, "command", &adr)) { if (strcmp((char *) adr, "cancel") == 0) { if (commandRunning) { if (!commandEndRequested) { commandEndRequested = 1; hts_request_stop(global_opt, 0); } else { hts_request_stop(global_opt, 1); /* note: the force flag does not have anyeffect yet */ commandEndRequested = 2; /* will break the loop() callback */ } } } else if ((p = strfield((char *) adr, "cancel-file="))) { if (commandRunning) { hts_cancel_file_push(global_opt, (char *) adr + p); } } else if (strcmp((char *) adr, "cancel-parsing") == 0) { if (commandRunning) { hts_cancel_parsing(global_opt); } } else if ((p = strfield((char *) adr, "pause="))) { if (commandRunning) { hts_setpause(global_opt, 1); } } else if ((p = strfield((char *) adr, "unpause"))) { if (commandRunning) { hts_setpause(global_opt, 0); } } else if (strcmp((char *) adr, "abort") == 0) { if (commandRunning) { hts_request_stop(global_opt, 1); commandEndRequested = 2; /* will break the loop() callback */ } } else if ((p = strfield((char *) adr, "add-url="))) { if (commandRunning) { char *ptraddr[2]; ptraddr[0] = (char *) adr + p; ptraddr[1] = NULL; hts_addurl(global_opt, ptraddr); } } else if ((p = strfield((char *) adr, "httrack"))) { if (!commandRunning) { intptr_t adrcd = 0; if (coucal_readptr(NewLangList, "command_do", &adrcd)) { intptr_t adrw = 0; if (coucal_readptr(NewLangList, "winprofile", &adrw)) { /* User general profile */ intptr_t adruserprofile = 0; if (coucal_readptr (NewLangList, "userprofile", &adruserprofile) && adruserprofile != 0) { int count = (int) strlen((char *) adruserprofile); if (count > 0) { FILE *fp; StringClear(tmpbuff); StringCopy(tmpbuff, gethomedir()); #ifdef _WIN32 StringCat(tmpbuff, "/httrack.ini"); #else StringCat(tmpbuff, "/.httrack.ini"); #endif fp = fopen(StringBuff(tmpbuff), "wb"); if (fp != NULL) { (void) ((int) fwrite((void *) adruserprofile, 1, count, fp)); fclose(fp); } } } /* Profile */ StringClear(tmpbuff); StringCat(tmpbuff, StringBuff(fspath)); StringCat(tmpbuff, "/hts-cache/"); /* Create minimal directory structure */ if (!structcheck(StringBuff(tmpbuff))) { FILE *fp; StringCat(tmpbuff, "winprofile.ini"); fp = fopen(StringBuff(tmpbuff), "wb"); if (fp != NULL) { int count = (int) strlen((char *) adrw); if ((int) fwrite((void *) adrw, 1, count, fp) == count) { /* Wipe the doit.log file, useless here (all options are replicated) and even a bit annoying (duplicate/ghost options) The behaviour is exactly the same as in WinHTTrack */ StringClear(tmpbuff); StringCat(tmpbuff, StringBuff(fspath)); StringCat(tmpbuff, "/hts-cache/doit.log"); remove(StringBuff(tmpbuff)); /* RUN THE SERVER */ if (strcmp((char *) adrcd, "start") == 0) { webhttrack_main((char *) adr + p); } else { commandRunning = 0; commandEnd = 1; } } else { char tmp[1024]; sprintf(tmp, "Unable to write %d bytes in the the init file %s", count, StringBuff(fspath)); SET_ERROR(tmp); } fclose(fp); } else { char tmp[1024]; sprintf(tmp, "Unable to create the init file %s", StringBuff(fspath)); SET_ERROR(tmp); } } else { char tmp[1024]; sprintf(tmp, "Unable to create the directory structure in %s", StringBuff(fspath)); SET_ERROR(tmp); } } else { SET_ERROR ("Internal server error: unable to fetch project name or path"); } } } } else if (strcmp((char *) adr, "quit") == 0) { willexit = 1; } coucal_write(NewLangList, "command", (intptr_t) NULL); } } /* Response */ if (meth) { int virtualpath = 0; char *pos; char *url = strchr(line1, ' '); if (url && *++url == '/' && (pos = strchr(url, ' ')) && !(*pos = '\0')) { char fsfile[1024]; const char *file; FILE *fp; char *qpos; /* get the URL */ if (error_redirect == NULL) { if ((qpos = strchr(url, '?'))) { *qpos = '\0'; } fsfile[0] = '\0'; if (strcmp(url, "/") == 0) { file = "/server/index.html"; meth = 2; } else { file = url; } } else { file = error_redirect; meth = 2; } if (strncmp(file, "/website/", 9) == 0) { virtualpath = 1; } /* override */ if (commandRunning) { if (is_html(file)) { file = "/server/refresh.html"; } } else if (commandEnd && !virtualpath && !willexit) { if (is_html(file)) { file = "/server/finished.html"; } } if (strlen(path) + strlen(file) + 32 < sizeof(fsfile)) { if (strncmp(file, "/website/", 9) != 0) { sprintf(fsfile, "%shtml%s", path, file); } else { intptr_t adr = 0; if (coucal_readptr(NewLangList, "projpath", &adr)) { sprintf(fsfile, "%s%s", (char *) adr, file + 9); } } } if (fsfile[0] && strstr(file, "..") == NULL && (fp = fopen(fsfile, "rb"))) { char ok[] = "HTTP/1.0 200 OK\r\n" "Connection: close\r\n" "Server: httrack-small-server\r\n" "Content-type: text/html\r\n" "Cache-Control: no-cache, must-revalidate, private\r\n" "Pragma: no-cache\r\n"; char ok_img[] = "HTTP/1.0 200 OK\r\n" "Connection: close\r\n" "Server: httrack small server\r\n" "Content-type: image/gif\r\n"; char ok_js[] = "HTTP/1.0 200 OK\r\n" "Connection: close\r\n" "Server: httrack small server\r\n" "Content-type: text/javascript\r\n"; char ok_css[] = "HTTP/1.0 200 OK\r\n" "Connection: close\r\n" "Server: httrack small server\r\n" "Content-type: text/css\r\n"; char ok_text[] = "HTTP/1.0 200 OK\r\n" "Connection: close\r\n" "Server: httrack small server\r\n" "Content-type: text/plain\r\n"; char ok_unknown[] = "HTTP/1.0 200 OK\r\n" "Connection: close\r\n" "Server: httrack small server\r\n" "Content-type: application/octet-stream\r\n"; /* register current page */ coucal_write(NewLangList, "thisfile", (intptr_t) strdup(file)); /* Force GET for the last request */ if (meth == 2 && willexit) { meth = 1; } /* posted data are redirected to get protocol */ if (meth == 2) { char redir[] = "HTTP/1.0 302 Redirect\r\n" "Connection: close\r\n" "Server: httrack-small-server\r\n"; intptr_t adr = 0; const char *newfile = file; if (coucal_readptr(NewLangList, "redirect", &adr) && adr != 0) { const char *newadr = (char *) adr; if (*newadr) { newfile = newadr; } } StringMemcat(headers, redir, strlen(redir)); { char tmp[256]; if (strlen(file) < sizeof(tmp) - 32) { sprintf(tmp, "Location: %s\r\n", newfile); StringMemcat(headers, tmp, strlen(tmp)); } } coucal_write(NewLangList, "redirect", (intptr_t) NULL); } else if (is_html(file)) { int outputmode = 0; StringMemcat(headers, ok, sizeof(ok) - 1); while(!feof(fp)) { char *str = line; int prevlen = (int) StringLength(output); int nocr = 0; if (!linput(fp, line, sizeof(line) - 2)) { *str = '\0'; } if (*str && str[strlen(str) - 1] == '\\') { nocr = 1; str[strlen(str) - 1] = '\0'; } while(*str) { char *pos; size_t n; if (*str == '$' && *++str == '{' && (pos = strchr(++str, '}')) && (n = (pos - str)) && n < 1024) { char name_[1024 + 2]; char *name = name_; const char *langstr = NULL; int p; int format = 0; int listDefault = 0; name[0] = '\0'; strncatbuff(name, str, n); if (strncmp(name, "/*", 2) == 0) { /* comments */ } else if ((p = strfield(name, "html:"))) { name += p; format = 1; } else if ((p = strfield(name, "list:"))) { name += p; format = 2; } else if ((p = strfield(name, "liststr:"))) { name += p; format = -2; } else if ((p = strfield(name, "file-exists:"))) { char *pos2; name += p; format = 0; pos2 = strchr(name, ':'); langstr = ""; if (pos2 != NULL) { *pos2 = '\0'; if (strstr(name, "..") == NULL) { if (fexist(fconcat(catbuff, sizeof(catbuff), path, name))) { langstr = pos2 + 1; } } } } else if ((p = strfield(name, "do:"))) { char *pos2; char empty[2] = ""; name += p; format = 1; pos2 = strchr(name, ':'); langstr = ""; if (pos2 != NULL) { *pos2 = '\0'; pos2++; } else { pos2 = empty; } if (strcmp(name, "output-mode") == 0) { if (strcmp(pos2, "html") == 0) { outputmode = 1; } else if (strcmp(pos2, "inifile") == 0) { outputmode = 2; } else if (strcmp(pos2, "html-urlescaped") == 0) { outputmode = 3; } else { outputmode = 0; } } else if (strcmp(name, "if-file-exists") == 0) { if (strstr(pos2, "..") == NULL) { if (!fexist(fconcat(catbuff, sizeof(catbuff), path, pos2))) { outputmode = -1; } } } else if (strcmp(name, "if-project-file-exists") == 0) { if (strstr(pos2, "..") == NULL) { if (!fexist (fconcat(catbuff, sizeof(catbuff), StringBuff(fspath), pos2))) { outputmode = -1; } } } else if (strcmp(name, "if-file-do-not-exists") == 0) { if (strstr(pos2, "..") == NULL) { if (fexist(fconcat(catbuff, sizeof(catbuff), path, pos2))) { outputmode = -1; } } } else if (strcmp(name, "if-not-empty") == 0) { intptr_t adr = 0; if (!coucal_readptr(NewLangList, pos2, &adr) || *((char *) adr) == 0) { outputmode = -1; } } else if (strcmp(name, "if-empty") == 0) { intptr_t adr = 0; if (coucal_readptr(NewLangList, pos2, &adr) && *((char *) adr) != 0) { outputmode = -1; } } else if (strcmp(name, "end-if") == 0) { outputmode = 0; } else if (strcmp(name, "loadhash") == 0) { intptr_t adr = 0; if (coucal_readptr(NewLangList, "path", &adr)) { char *rpath = (char *) adr; //find_handle h; if (rpath[0]) { if (rpath[strlen(rpath) - 1] == '/') { rpath[strlen(rpath) - 1] = '\0'; /* note: patching stored (inhash) value */ } } { const char *profiles = hts_getcategories(rpath, 0); const char *categ = hts_getcategories(rpath, 1); coucal_write(NewLangList, "winprofile", (intptr_t) profiles); coucal_write(NewLangList, "wincateg", (intptr_t) categ); } } } else if (strcmp(name, "copy") == 0) { if (*pos2) { char *pos3 = strchr(pos2, ':'); if (pos3 && *(pos3 + 1)) { intptr_t adr = 0; *pos3++ = '\0'; if (coucal_readptr(NewLangList, pos2, &adr)) { coucal_write(NewLangList, pos3, (intptr_t) strdup((char *) adr)); coucal_write(NewLangList, pos2, (intptr_t) NULL); } } } } else if (strcmp(name, "set") == 0) { if (*pos2) { char *pos3 = strchr(pos2, ':'); if (pos3) { *pos3++ = '\0'; coucal_write(NewLangList, pos2, (intptr_t) strdup(pos3)); } else { coucal_write(NewLangList, pos2, (intptr_t) NULL); } } } } /* test: test:::.. ztest:::.. */ else if ((p = strfield(name, "test:")) || (p = strfield(name, "ztest:"))) { intptr_t adr = 0; char *pos2; int ztest = (name[0] == 'z'); langstr = ""; name += p; pos2 = strchr(name, ':'); if (pos2 != NULL) { *pos2 = '\0'; if (coucal_readptr(NewLangList, name, &adr) || ztest) { const char *newadr = (char *) adr; if (!newadr) newadr = ""; if (*newadr || ztest) { int npos = 0; name = pos2 + 1; format = 4; if (strchr(name, ':') == NULL) { npos = 0; /* first is good if only one : */ format = 0; } else { if (sscanf(newadr, "%d", &npos) != 1) { if (strfield(newadr, "on")) { npos = 1; } else { npos = 0; /* first one will be ok */ format = 0; } } } while(*name && *name != '}' && npos >= 0) { int end = 0; char *fpos = strchr(name, ':'); int n2; if (fpos == NULL) { fpos = name + strlen(name); end = 1; } n2 = (int) (fpos - name); if (npos == 0) { langstr = name; *fpos = '\0'; } else if (end) { npos = 0; } name += n2 + 1; npos--; } } } } } else if ((p = strfield(name, "listid:"))) { char *pos2; name += p; format = 2; pos2 = strchr(name, ':'); if (pos2) { char dname[32]; int n2 = (int) (pos2 - name); if (n2 > 0 && n2 < sizeof(dname) - 2) { intptr_t adr = 0; dname[0] = '\0'; strncatbuff(dname, name, n2); if (coucal_readptr(NewLangList, dname, &adr)) { int n = 0; if (sscanf((char *) adr, "%d", &n) == 1) { listDefault = n; } } name += n2 + 1; } } } else if ((p = strfield(name, "checked:"))) { name += p; format = 3; } if (langstr == NULL) { if (strfield2(name, "#iso")) { langstr = line2; line2[0] = '\0'; LANG_LIST(path, line2, sizeof(line2)); assertf(strlen(langstr) < sizeof(line2) - 2); } else { langstr = LANGSEL(name); if (langstr == NULL || *langstr == '\0') { intptr_t adr = 0; if (coucal_readptr(NewLangList, name, &adr)) { char *newadr = (char *) adr; langstr = newadr; } } } } if (langstr && outputmode != -1) { switch (format) { case 0: { const char *a = langstr; while(*a) { if (a[0] == '\\' && isxdigit(a[1]) && isxdigit(a[2])) { int n; char c; if (sscanf(a + 1, "%x", &n) == 1) { c = (char) n; StringMemcat(output, &c, 1); } a += 2; } else if (outputmode && a[0] == '<') { StringCat(output, "<"); } else if (outputmode && a[0] == '>') { StringCat(output, ">"); } else if (outputmode && a[0] == '&') { StringCat(output, "&"); } else if (outputmode && a[0] == '\'') { StringCat(output, "'"); } else if (outputmode == 3 && a[0] == ' ') { StringCat(output, "%20"); } else if (outputmode >= 2 && ((unsigned char) a[0]) < 32) { char tmp[32]; sprintf(tmp, "%%%02x", (unsigned char) a[0]); StringCat(output, tmp); } else if (outputmode == 2 && a[0] == '%') { StringCat(output, "%%"); } else if (outputmode == 3 && a[0] == '%') { StringCat(output, "%25"); } else { StringMemcat(output, a, 1); } a++; } } break; case 3: if (*langstr) { StringCat(output, "checked"); } break; default: if (*langstr) { int id = 1; const char *fstr = langstr; StringClear(tmpbuff); if (format == 2) { StringCat(output, "\r\n"); StringCat(output, ""); } else if (format == -2) { StringCat(output, StringBuff(tmpbuff)); StringCat(output, "\">"); StringCat(output, StringBuff(tmpbuff)); StringCat(output, ""); } else { StringCat(output, StringBuff(tmpbuff)); } StringClear(tmpbuff); } } } str = pos; } else { if (outputmode != -1) { StringMemcat(output, str, 1); } } str++; } if (!nocr && prevlen != StringLength(output)) { StringCat(output, "\r\n"); } } #ifdef _DEBUG { int len = (int) strlen((char *) StringBuff(output)); assert(len == (int) StringLength(output)); } #endif } else { if (is_text(file)) { StringMemcat(headers, ok_text, sizeof(ok_text) - 1); } else if (is_js(file)) { StringMemcat(headers, ok_js, sizeof(ok_js) - 1); } else if (is_css(file)) { StringMemcat(headers, ok_css, sizeof(ok_css) - 1); } else if (is_image(file)) { StringMemcat(headers, ok_img, sizeof(ok_img) - 1); } else { StringMemcat(headers, ok_unknown, sizeof(ok_unknown) - 1); } while(!feof(fp)) { int n = (int) fread(line, 1, sizeof(line) - 2, fp); if (n > 0) { StringMemcat(output, line, n); } } } fclose(fp); } else if (strcmp(file, "/ping") == 0 || strncmp(file, "/ping?", 6) == 0) { char error_hdr[] = "HTTP/1.0 200 Pong\r\n" "Server: httrack small server\r\n" "Content-type: text/html\r\n"; StringCat(headers, error_hdr); } else { char error_hdr[] = "HTTP/1.0 404 Not Found\r\n" "Server: httrack small server\r\n" "Content-type: text/html\r\n"; char error[] = "Page not found.\r\n"; StringCat(headers, error_hdr); StringCat(output, error); //assert(file == NULL); } } } else { #ifdef _DEBUG char error_hdr[] = "HTTP/1.0 500 Server Error\r\n" "Server: httrack small server\r\n" "Content-type: text/html\r\n"; char error[] = "Server error.\r\n"; StringCat(headers, error_hdr); StringCat(output, error); #endif } { char tmp[256]; sprintf(tmp, "Content-length: %d\r\n", (int) StringLength(output)); StringCat(headers, tmp); } StringCat(headers, "\r\n"); if ((send(soc_c, StringBuff(headers), (int) StringLength(headers), 0) != StringLength(headers)) || ((meth == 1) && (send(soc_c, StringBuff(output), (int) StringLength(output), 0) != StringLength(output))) ) { #ifdef _DEBUG //assert(FALSE); #endif } } else { #ifdef _DEBUG // assert(FALSE); #endif } /* Shutdown (FIN) and wait until confirmed */ { char c; #ifdef _WIN32 shutdown(soc_c, SD_SEND); #else shutdown(soc_c, 1); #endif /* This is necessary as IE sometimes (!) sends an additional CRLF after POST data */ while(recv(soc_c, ((char *) &c), 1, 0) > 0) ; } #ifdef _WIN32 closesocket(soc_c); #else close(soc_c); #endif } if (soc != INVALID_SOCKET) { #ifdef _WIN32 closesocket(soc); #else close(soc); #endif } StringFree(headers); StringFree(output); StringFree(tmpbuff); StringFree(tmpbuff2); StringFree(fspath); if (buffer) free(buffer); if (commandReturnMsg) free(commandReturnMsg); commandReturnMsg = NULL; if (commandReturnCmdl) free(commandReturnCmdl); commandReturnCmdl = NULL; /* Unlock */ webhttrack_release(); return retour; } /* Language files */ int htslang_init(void) { if (NewLangList == NULL) { NewLangList = coucal_new(0); coucal_set_name(NewLangList, "NewLangList"); if (NewLangList == NULL) { abortLog("Error in lang.h: not enough memory"); } else { coucal_value_is_malloc(NewLangList, 1); } } return 1; } int htslang_uninit(void) { if (NewLangList != NULL) { coucal_delete(&NewLangList); } return 1; } void smallserver_setpinghandler(void (*fun)(void*), void*arg) { pingFun = fun; pingFunArg = arg; } int smallserver_setkey(const char *key, const char *value) { return coucal_write(NewLangList, key, (intptr_t) strdup(value)); } int smallserver_setkeyint(const char *key, LLint value) { char tmp[256]; snprintf(tmp, sizeof(tmp), LLintP, value); return coucal_write(NewLangList, key, (intptr_t) strdup(tmp)); } int smallserver_setkeyarr(const char *key, int id, const char *key2, const char *value) { char tmp[256]; snprintf(tmp, sizeof(tmp), "%s%d%s", key, id, key2); return coucal_write(NewLangList, tmp, (intptr_t) strdup(value)); } static int htslang_load(char *limit_to, const char *path) { const char *hashname; char catbuff[CATBUFF_SIZE]; // int selected_lang = LANG_T(path, -1); // if (!limit_to) { LANG_DELETE(); NewLangStr = coucal_new(0); NewLangStrKeys = coucal_new(0); coucal_set_name(NewLangStr, "NewLangStr"); coucal_set_name(NewLangStrKeys, "NewLangStrKeys"); if ((NewLangStr == NULL) || (NewLangStrKeys == NULL)) { abortLog("Error in lang.h: not enough memory"); } else { coucal_value_is_malloc(NewLangStr, 1); coucal_value_is_malloc(NewLangStrKeys, 1); } } /* Load master file (list of keys and internal keys) */ if (!limit_to) { const char *mname = "lang.def"; FILE *fp = fopen(fconcat(catbuff, sizeof(catbuff), path, mname), "rb"); if (fp) { char intkey[8192]; char key[8192]; while(!feof(fp)) { linput_cpp(fp, intkey, 8000); linput_cpp(fp, key, 8000); if (strnotempty(intkey) && strnotempty(key)) { const char *test = LANGINTKEY(key); /* Increment for multiple definitions */ if (strnotempty(test)) { int increment = 0; size_t pos = strlen(key); do { increment++; sprintf(key + pos, "%d", increment); test = LANGINTKEY(key); } while(strnotempty(test)); } if (!strnotempty(test)) { // éviter doublons // conv_printf(key,key); const size_t len = strlen(intkey); char *const buff = (char *) malloc(len + 1); if (buff) { strcpybuff(buff, intkey); coucal_add(NewLangStrKeys, key, (intptr_t) buff); } } } // if } // while fclose(fp); } else { return 0; } } /* Language Name? */ { char name[256]; sprintf(name, "LANGUAGE_%d", selected_lang + 1); hashname = LANGINTKEY(name); } /* Get only language name */ if (limit_to) { if (hashname) strcpybuff(limit_to, hashname); else strcpybuff(limit_to, "???"); return 0; } /* Error */ if (!hashname) return 0; /* Load specific language file */ { int loops; // 2nd loop: load undefined strings for(loops = 0; loops < 2; loops++) { FILE *fp; char lbasename[1024]; { char name[256]; sprintf(name, "LANGUAGE_%d", (loops == 0) ? (selected_lang + 1) : 1); hashname = LANGINTKEY(name); } sprintf(lbasename, "lang/%s.txt", hashname); fp = fopen(fconcat(catbuff, sizeof(catbuff), path, lbasename), "rb"); if (fp) { char extkey[8192]; char value[8192]; while(!feof(fp)) { linput_cpp(fp, extkey, 8000); linput_cpp(fp, value, 8000); if (strnotempty(extkey) && strnotempty(value)) { const char *intkey; intkey = LANGINTKEY(extkey); if (strnotempty(intkey)) { /* Increment for multiple definitions */ { const char *test = LANGSEL(intkey); if (strnotempty(test)) { if (loops == 0) { int increment = 0; size_t pos = strlen(extkey); do { increment++; sprintf(extkey + pos, "%d", increment); intkey = LANGINTKEY(extkey); if (strnotempty(intkey)) test = LANGSEL(intkey); else test = ""; } while(strnotempty(test)); } else intkey = ""; } else { if (loops > 0) { //err_msg += intkey; //err_msg += " "; } } } /* Add key */ if (strnotempty(intkey)) { const size_t len = strlen(value); char *const buff = (char *) malloc(len + 1); if (buff) { conv_printf(value, buff); coucal_add(NewLangStr, intkey, (intptr_t) buff); } } } } // if } // while fclose(fp); } else { return 0; } } } // Control limit_to if (limit_to) limit_to[0] = '\0'; return 1; } /* NOTE : also contains the "webhttrack" hack */ static void conv_printf(const char *from, char *to) { int i = 0, j = 0, len; len = (int) strlen(from); while(i < len) { switch (from[i]) { case '\\': i++; switch (from[i]) { case 'a': to[j] = '\a'; break; case 'b': to[j] = '\b'; break; case 'f': to[j] = '\f'; break; case 'n': to[j] = '\n'; break; case 'r': to[j] = '\r'; break; case 't': to[j] = '\t'; break; case 'v': to[j] = '\v'; break; case '\'': to[j] = '\''; break; case '\"': to[j] = '\"'; break; case '\\': to[j] = '\\'; break; case '?': to[j] = '\?'; break; default: to[j] = from[i]; break; } break; default: to[j] = from[i]; break; } i++; j++; } to[j++] = '\0'; /* Dirty hack */ { char *a = to; while((a = strstr(a, "WinHTTrack"))) { a[0] = 'W'; a[1] = 'e'; a[2] = 'b'; a++; } } } static void LANG_DELETE(void) { coucal_delete(&NewLangStr); coucal_delete(&NewLangStrKeys); } // sélection de la langue static void LANG_INIT(const char *path) { //CWinApp* pApp = AfxGetApp(); //if (pApp) { /* pApp->GetProfileInt("Language","IntId",0); */ LANG_T(path, 0 /*pApp->GetProfileInt("Language","IntId",0) */ ); //} } static int LANG_T(const char *path, int l) { if (l >= 0) { QLANG_T(l); htslang_load(NULL, path); } return QLANG_T(-1); // 0=default (english) } static int LANG_SEARCH(const char *path, const char *iso) { char lang_str[1024]; int i = 0; int curr_lng = LANG_T(path, -1); int found = 0; do { QLANG_T(i); strcpybuff(lang_str, "LANGUAGE_ISO"); htslang_load(lang_str, path); if (strfield(iso, lang_str)) { found = i; } i++; } while(strlen(lang_str) > 0); QLANG_T(curr_lng); return found; } static int LANG_LIST(const char *path, char *buffer, size_t buffer_size) { char lang_str[1024]; int i = 0; int curr_lng = LANG_T(path, -1); buffer[0] = '\0'; do { QLANG_T(i); strlcpybuff(lang_str, "LANGUAGE_NAME", buffer_size); htslang_load(lang_str, path); if (strlen(lang_str) > 0) { if (buffer[0]) strcatbuff(buffer, "\n"); strlcatbuff(buffer, lang_str, buffer_size); } i++; } while(strlen(lang_str) > 0); QLANG_T(curr_lng); return i; } static int QLANG_T(int l) { static int lng = 0; if (l >= 0) { lng = l; } return lng; // 0=default (english) } const char* LANGSEL(const char* name) { coucal_value value; if (NewLangStr != NULL && coucal_read_value(NewLangStr, name, &value) != 0 && value.ptr != NULL) { return (char*) value.ptr; } else { return ""; } } const char* LANGINTKEY(const char* name) { coucal_value value; if (NewLangStrKeys != NULL && coucal_read_value(NewLangStrKeys, name, &value) != 0 && value.ptr != NULL) { return (char*) value.ptr; } else { return ""; } } /* *** Various functions *** */ static int recv_bl(T_SOC soc, void *buffer, size_t len, int timeout) { if (check_readinput_t(soc, timeout)) { int n = 1; size_t size = len; size_t offs = 0; while(n > 0 && size > 0) { n = recv(soc, ((char *) buffer) + offs, (int) size, 0); if (n > 0) { offs += n; size -= n; } } return (int) offs; } return -1; } // check if data is available static int check_readinput(htsblk * r) { if (r->soc != INVALID_SOCKET) { fd_set fds; // poll structures struct timeval tv; // structure for select FD_ZERO(&fds); FD_SET(r->soc, &fds); tv.tv_sec = 0; tv.tv_usec = 0; select((int) r->soc + 1, &fds, NULL, NULL, &tv); if (FD_ISSET(r->soc, &fds)) return 1; else return 0; } else return 0; } /*int strfield(const char* f,const char* s) { int r=0; while (streql(*f,*s) && ((*f)!=0) && ((*s)!=0)) { f++; s++; r++; } if (*s==0) return r; else return 0; }*/ /* same, except + */ httrack-3.49.5/src/md5.h0000644000175000017500000000222214336470674011636 00000000000000#ifndef MD5_H #define MD5_H #ifdef _WIN32 #ifndef SIZEOF_LONG #define SIZEOF_LONG 4 #endif #else #include "config.h" #endif #if SIZEOF_LONG==8 typedef unsigned int uint32; #elif SIZEOF_LONG==4 typedef unsigned long uint32; #else #error undefined: SIZEOF_LONG #endif struct MD5Context { union { unsigned char ui8[64]; uint32 ui32[16]; } in; uint32 buf[4]; uint32 bits[2]; int doByteReverse; }; void MD5Init(struct MD5Context *context, int brokenEndian); void MD5Update(struct MD5Context *context, unsigned char const *buf, unsigned len); void MD5Final(unsigned char digest[16], struct MD5Context *context); void MD5Transform(uint32 buf[4], uint32 const in[16]); int mdfile(char *fn, unsigned char *digest); int mdbinfile(char *fn, unsigned char *bindigest); /* These assume a little endian machine and return incorrect results! They are here for compatibility with old (broken) versions of RPM */ int mdfileBroken(char *fn, unsigned char *digest); int mdbinfileBroken(char *fn, unsigned char *bindigest); /* * This is needed to make RSAREF happy on some MS-DOS compilers. */ typedef struct MD5Context MD5CTX; #endif /* !MD5_H */ httrack-3.49.5/src/htscodepages.h0000644000175000017500000032746214336470674013642 00000000000000/** GENERATED FILE (/temp/httrack-3.47.21/src/htsbasiccharsets.sh), DO NOT EDIT **/ /* Table for 8859-10.TXT */ static const hts_UCS4 table_iso_8859_10[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x0085, 0x0086, 0x0087, 0x0088, 0x0089, 0x008a, 0x008b, 0x008c, 0x008d, 0x008e, 0x008f, 0x0090, 0x0091, 0x0092, 0x0093, 0x0094, 0x0095, 0x0096, 0x0097, 0x0098, 0x0099, 0x009a, 0x009b, 0x009c, 0x009d, 0x009e, 0x009f, 0x00a0, 0x0104, 0x0112, 0x0122, 0x012a, 0x0128, 0x0136, 0x00a7, 0x013b, 0x0110, 0x0160, 0x0166, 0x017d, 0x00ad, 0x016a, 0x014a, 0x00b0, 0x0105, 0x0113, 0x0123, 0x012b, 0x0129, 0x0137, 0x00b7, 0x013c, 0x0111, 0x0161, 0x0167, 0x017e, 0x2015, 0x016b, 0x014b, 0x0100, 0x00c1, 0x00c2, 0x00c3, 0x00c4, 0x00c5, 0x00c6, 0x012e, 0x010c, 0x00c9, 0x0118, 0x00cb, 0x0116, 0x00cd, 0x00ce, 0x00cf, 0x00d0, 0x0145, 0x014c, 0x00d3, 0x00d4, 0x00d5, 0x00d6, 0x0168, 0x00d8, 0x0172, 0x00da, 0x00db, 0x00dc, 0x00dd, 0x00de, 0x00df, 0x0101, 0x00e1, 0x00e2, 0x00e3, 0x00e4, 0x00e5, 0x00e6, 0x012f, 0x010d, 0x00e9, 0x0119, 0x00eb, 0x0117, 0x00ed, 0x00ee, 0x00ef, 0x00f0, 0x0146, 0x014d, 0x00f3, 0x00f4, 0x00f5, 0x00f6, 0x0169, 0x00f8, 0x0173, 0x00fa, 0x00fb, 0x00fc, 0x00fd, 0x00fe, 0x0138 }; /* Table for 8859-11.TXT */ static const hts_UCS4 table_iso_8859_11[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x0085, 0x0086, 0x0087, 0x0088, 0x0089, 0x008a, 0x008b, 0x008c, 0x008d, 0x008e, 0x008f, 0x0090, 0x0091, 0x0092, 0x0093, 0x0094, 0x0095, 0x0096, 0x0097, 0x0098, 0x0099, 0x009a, 0x009b, 0x009c, 0x009d, 0x009e, 0x009f, 0x00a0, 0x0e01, 0x0e02, 0x0e03, 0x0e04, 0x0e05, 0x0e06, 0x0e07, 0x0e08, 0x0e09, 0x0e0a, 0x0e0b, 0x0e0c, 0x0e0d, 0x0e0e, 0x0e0f, 0x0e10, 0x0e11, 0x0e12, 0x0e13, 0x0e14, 0x0e15, 0x0e16, 0x0e17, 0x0e18, 0x0e19, 0x0e1a, 0x0e1b, 0x0e1c, 0x0e1d, 0x0e1e, 0x0e1f, 0x0e20, 0x0e21, 0x0e22, 0x0e23, 0x0e24, 0x0e25, 0x0e26, 0x0e27, 0x0e28, 0x0e29, 0x0e2a, 0x0e2b, 0x0e2c, 0x0e2d, 0x0e2e, 0x0e2f, 0x0e30, 0x0e31, 0x0e32, 0x0e33, 0x0e34, 0x0e35, 0x0e36, 0x0e37, 0x0e38, 0x0e39, 0x0e3a, 0x0000, 0x0000, 0x0000, 0x0000, 0x0e3f, 0x0e40, 0x0e41, 0x0e42, 0x0e43, 0x0e44, 0x0e45, 0x0e46, 0x0e47, 0x0e48, 0x0e49, 0x0e4a, 0x0e4b, 0x0e4c, 0x0e4d, 0x0e4e, 0x0e4f, 0x0e50, 0x0e51, 0x0e52, 0x0e53, 0x0e54, 0x0e55, 0x0e56, 0x0e57, 0x0e58, 0x0e59, 0x0e5a, 0x0e5b, 0x0000, 0x0000, 0x0000, 0x0000 }; /* Table for 8859-13.TXT */ static const hts_UCS4 table_iso_8859_13[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x0085, 0x0086, 0x0087, 0x0088, 0x0089, 0x008a, 0x008b, 0x008c, 0x008d, 0x008e, 0x008f, 0x0090, 0x0091, 0x0092, 0x0093, 0x0094, 0x0095, 0x0096, 0x0097, 0x0098, 0x0099, 0x009a, 0x009b, 0x009c, 0x009d, 0x009e, 0x009f, 0x00a0, 0x201d, 0x00a2, 0x00a3, 0x00a4, 0x201e, 0x00a6, 0x00a7, 0x00d8, 0x00a9, 0x0156, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x00c6, 0x00b0, 0x00b1, 0x00b2, 0x00b3, 0x201c, 0x00b5, 0x00b6, 0x00b7, 0x00f8, 0x00b9, 0x0157, 0x00bb, 0x00bc, 0x00bd, 0x00be, 0x00e6, 0x0104, 0x012e, 0x0100, 0x0106, 0x00c4, 0x00c5, 0x0118, 0x0112, 0x010c, 0x00c9, 0x0179, 0x0116, 0x0122, 0x0136, 0x012a, 0x013b, 0x0160, 0x0143, 0x0145, 0x00d3, 0x014c, 0x00d5, 0x00d6, 0x00d7, 0x0172, 0x0141, 0x015a, 0x016a, 0x00dc, 0x017b, 0x017d, 0x00df, 0x0105, 0x012f, 0x0101, 0x0107, 0x00e4, 0x00e5, 0x0119, 0x0113, 0x010d, 0x00e9, 0x017a, 0x0117, 0x0123, 0x0137, 0x012b, 0x013c, 0x0161, 0x0144, 0x0146, 0x00f3, 0x014d, 0x00f5, 0x00f6, 0x00f7, 0x0173, 0x0142, 0x015b, 0x016b, 0x00fc, 0x017c, 0x017e, 0x2019 }; /* Table for 8859-14.TXT */ static const hts_UCS4 table_iso_8859_14[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x0085, 0x0086, 0x0087, 0x0088, 0x0089, 0x008a, 0x008b, 0x008c, 0x008d, 0x008e, 0x008f, 0x0090, 0x0091, 0x0092, 0x0093, 0x0094, 0x0095, 0x0096, 0x0097, 0x0098, 0x0099, 0x009a, 0x009b, 0x009c, 0x009d, 0x009e, 0x009f, 0x00a0, 0x1e02, 0x1e03, 0x00a3, 0x010a, 0x010b, 0x1e0a, 0x00a7, 0x1e80, 0x00a9, 0x1e82, 0x1e0b, 0x1ef2, 0x00ad, 0x00ae, 0x0178, 0x1e1e, 0x1e1f, 0x0120, 0x0121, 0x1e40, 0x1e41, 0x00b6, 0x1e56, 0x1e81, 0x1e57, 0x1e83, 0x1e60, 0x1ef3, 0x1e84, 0x1e85, 0x1e61, 0x00c0, 0x00c1, 0x00c2, 0x00c3, 0x00c4, 0x00c5, 0x00c6, 0x00c7, 0x00c8, 0x00c9, 0x00ca, 0x00cb, 0x00cc, 0x00cd, 0x00ce, 0x00cf, 0x0174, 0x00d1, 0x00d2, 0x00d3, 0x00d4, 0x00d5, 0x00d6, 0x1e6a, 0x00d8, 0x00d9, 0x00da, 0x00db, 0x00dc, 0x00dd, 0x0176, 0x00df, 0x00e0, 0x00e1, 0x00e2, 0x00e3, 0x00e4, 0x00e5, 0x00e6, 0x00e7, 0x00e8, 0x00e9, 0x00ea, 0x00eb, 0x00ec, 0x00ed, 0x00ee, 0x00ef, 0x0175, 0x00f1, 0x00f2, 0x00f3, 0x00f4, 0x00f5, 0x00f6, 0x1e6b, 0x00f8, 0x00f9, 0x00fa, 0x00fb, 0x00fc, 0x00fd, 0x0177, 0x00ff }; /* Table for 8859-15.TXT */ static const hts_UCS4 table_iso_8859_15[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x0085, 0x0086, 0x0087, 0x0088, 0x0089, 0x008a, 0x008b, 0x008c, 0x008d, 0x008e, 0x008f, 0x0090, 0x0091, 0x0092, 0x0093, 0x0094, 0x0095, 0x0096, 0x0097, 0x0098, 0x0099, 0x009a, 0x009b, 0x009c, 0x009d, 0x009e, 0x009f, 0x00a0, 0x00a1, 0x00a2, 0x00a3, 0x20ac, 0x00a5, 0x0160, 0x00a7, 0x0161, 0x00a9, 0x00aa, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x00af, 0x00b0, 0x00b1, 0x00b2, 0x00b3, 0x017d, 0x00b5, 0x00b6, 0x00b7, 0x017e, 0x00b9, 0x00ba, 0x00bb, 0x0152, 0x0153, 0x0178, 0x00bf, 0x00c0, 0x00c1, 0x00c2, 0x00c3, 0x00c4, 0x00c5, 0x00c6, 0x00c7, 0x00c8, 0x00c9, 0x00ca, 0x00cb, 0x00cc, 0x00cd, 0x00ce, 0x00cf, 0x00d0, 0x00d1, 0x00d2, 0x00d3, 0x00d4, 0x00d5, 0x00d6, 0x00d7, 0x00d8, 0x00d9, 0x00da, 0x00db, 0x00dc, 0x00dd, 0x00de, 0x00df, 0x00e0, 0x00e1, 0x00e2, 0x00e3, 0x00e4, 0x00e5, 0x00e6, 0x00e7, 0x00e8, 0x00e9, 0x00ea, 0x00eb, 0x00ec, 0x00ed, 0x00ee, 0x00ef, 0x00f0, 0x00f1, 0x00f2, 0x00f3, 0x00f4, 0x00f5, 0x00f6, 0x00f7, 0x00f8, 0x00f9, 0x00fa, 0x00fb, 0x00fc, 0x00fd, 0x00fe, 0x00ff }; /* Table for 8859-16.TXT */ static const hts_UCS4 table_iso_8859_16[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x0085, 0x0086, 0x0087, 0x0088, 0x0089, 0x008a, 0x008b, 0x008c, 0x008d, 0x008e, 0x008f, 0x0090, 0x0091, 0x0092, 0x0093, 0x0094, 0x0095, 0x0096, 0x0097, 0x0098, 0x0099, 0x009a, 0x009b, 0x009c, 0x009d, 0x009e, 0x009f, 0x00a0, 0x0104, 0x0105, 0x0141, 0x20ac, 0x201e, 0x0160, 0x00a7, 0x0161, 0x00a9, 0x0218, 0x00ab, 0x0179, 0x00ad, 0x017a, 0x017b, 0x00b0, 0x00b1, 0x010c, 0x0142, 0x017d, 0x201d, 0x00b6, 0x00b7, 0x017e, 0x010d, 0x0219, 0x00bb, 0x0152, 0x0153, 0x0178, 0x017c, 0x00c0, 0x00c1, 0x00c2, 0x0102, 0x00c4, 0x0106, 0x00c6, 0x00c7, 0x00c8, 0x00c9, 0x00ca, 0x00cb, 0x00cc, 0x00cd, 0x00ce, 0x00cf, 0x0110, 0x0143, 0x00d2, 0x00d3, 0x00d4, 0x0150, 0x00d6, 0x015a, 0x0170, 0x00d9, 0x00da, 0x00db, 0x00dc, 0x0118, 0x021a, 0x00df, 0x00e0, 0x00e1, 0x00e2, 0x0103, 0x00e4, 0x0107, 0x00e6, 0x00e7, 0x00e8, 0x00e9, 0x00ea, 0x00eb, 0x00ec, 0x00ed, 0x00ee, 0x00ef, 0x0111, 0x0144, 0x00f2, 0x00f3, 0x00f4, 0x0151, 0x00f6, 0x015b, 0x0171, 0x00f9, 0x00fa, 0x00fb, 0x00fc, 0x0119, 0x021b, 0x00ff }; /* Table for 8859-1.TXT */ static const hts_UCS4 table_iso_8859_1[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x0085, 0x0086, 0x0087, 0x0088, 0x0089, 0x008a, 0x008b, 0x008c, 0x008d, 0x008e, 0x008f, 0x0090, 0x0091, 0x0092, 0x0093, 0x0094, 0x0095, 0x0096, 0x0097, 0x0098, 0x0099, 0x009a, 0x009b, 0x009c, 0x009d, 0x009e, 0x009f, 0x00a0, 0x00a1, 0x00a2, 0x00a3, 0x00a4, 0x00a5, 0x00a6, 0x00a7, 0x00a8, 0x00a9, 0x00aa, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x00af, 0x00b0, 0x00b1, 0x00b2, 0x00b3, 0x00b4, 0x00b5, 0x00b6, 0x00b7, 0x00b8, 0x00b9, 0x00ba, 0x00bb, 0x00bc, 0x00bd, 0x00be, 0x00bf, 0x00c0, 0x00c1, 0x00c2, 0x00c3, 0x00c4, 0x00c5, 0x00c6, 0x00c7, 0x00c8, 0x00c9, 0x00ca, 0x00cb, 0x00cc, 0x00cd, 0x00ce, 0x00cf, 0x00d0, 0x00d1, 0x00d2, 0x00d3, 0x00d4, 0x00d5, 0x00d6, 0x00d7, 0x00d8, 0x00d9, 0x00da, 0x00db, 0x00dc, 0x00dd, 0x00de, 0x00df, 0x00e0, 0x00e1, 0x00e2, 0x00e3, 0x00e4, 0x00e5, 0x00e6, 0x00e7, 0x00e8, 0x00e9, 0x00ea, 0x00eb, 0x00ec, 0x00ed, 0x00ee, 0x00ef, 0x00f0, 0x00f1, 0x00f2, 0x00f3, 0x00f4, 0x00f5, 0x00f6, 0x00f7, 0x00f8, 0x00f9, 0x00fa, 0x00fb, 0x00fc, 0x00fd, 0x00fe, 0x00ff }; /* Table for 8859-2.TXT */ static const hts_UCS4 table_iso_8859_2[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x0085, 0x0086, 0x0087, 0x0088, 0x0089, 0x008a, 0x008b, 0x008c, 0x008d, 0x008e, 0x008f, 0x0090, 0x0091, 0x0092, 0x0093, 0x0094, 0x0095, 0x0096, 0x0097, 0x0098, 0x0099, 0x009a, 0x009b, 0x009c, 0x009d, 0x009e, 0x009f, 0x00a0, 0x0104, 0x02d8, 0x0141, 0x00a4, 0x013d, 0x015a, 0x00a7, 0x00a8, 0x0160, 0x015e, 0x0164, 0x0179, 0x00ad, 0x017d, 0x017b, 0x00b0, 0x0105, 0x02db, 0x0142, 0x00b4, 0x013e, 0x015b, 0x02c7, 0x00b8, 0x0161, 0x015f, 0x0165, 0x017a, 0x02dd, 0x017e, 0x017c, 0x0154, 0x00c1, 0x00c2, 0x0102, 0x00c4, 0x0139, 0x0106, 0x00c7, 0x010c, 0x00c9, 0x0118, 0x00cb, 0x011a, 0x00cd, 0x00ce, 0x010e, 0x0110, 0x0143, 0x0147, 0x00d3, 0x00d4, 0x0150, 0x00d6, 0x00d7, 0x0158, 0x016e, 0x00da, 0x0170, 0x00dc, 0x00dd, 0x0162, 0x00df, 0x0155, 0x00e1, 0x00e2, 0x0103, 0x00e4, 0x013a, 0x0107, 0x00e7, 0x010d, 0x00e9, 0x0119, 0x00eb, 0x011b, 0x00ed, 0x00ee, 0x010f, 0x0111, 0x0144, 0x0148, 0x00f3, 0x00f4, 0x0151, 0x00f6, 0x00f7, 0x0159, 0x016f, 0x00fa, 0x0171, 0x00fc, 0x00fd, 0x0163, 0x02d9 }; /* Table for 8859-3.TXT */ static const hts_UCS4 table_iso_8859_3[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x0085, 0x0086, 0x0087, 0x0088, 0x0089, 0x008a, 0x008b, 0x008c, 0x008d, 0x008e, 0x008f, 0x0090, 0x0091, 0x0092, 0x0093, 0x0094, 0x0095, 0x0096, 0x0097, 0x0098, 0x0099, 0x009a, 0x009b, 0x009c, 0x009d, 0x009e, 0x009f, 0x00a0, 0x0126, 0x02d8, 0x00a3, 0x00a4, 0x0000, 0x0124, 0x00a7, 0x00a8, 0x0130, 0x015e, 0x011e, 0x0134, 0x00ad, 0x0000, 0x017b, 0x00b0, 0x0127, 0x00b2, 0x00b3, 0x00b4, 0x00b5, 0x0125, 0x00b7, 0x00b8, 0x0131, 0x015f, 0x011f, 0x0135, 0x00bd, 0x0000, 0x017c, 0x00c0, 0x00c1, 0x00c2, 0x0000, 0x00c4, 0x010a, 0x0108, 0x00c7, 0x00c8, 0x00c9, 0x00ca, 0x00cb, 0x00cc, 0x00cd, 0x00ce, 0x00cf, 0x0000, 0x00d1, 0x00d2, 0x00d3, 0x00d4, 0x0120, 0x00d6, 0x00d7, 0x011c, 0x00d9, 0x00da, 0x00db, 0x00dc, 0x016c, 0x015c, 0x00df, 0x00e0, 0x00e1, 0x00e2, 0x0000, 0x00e4, 0x010b, 0x0109, 0x00e7, 0x00e8, 0x00e9, 0x00ea, 0x00eb, 0x00ec, 0x00ed, 0x00ee, 0x00ef, 0x0000, 0x00f1, 0x00f2, 0x00f3, 0x00f4, 0x0121, 0x00f6, 0x00f7, 0x011d, 0x00f9, 0x00fa, 0x00fb, 0x00fc, 0x016d, 0x015d, 0x02d9 }; /* Table for 8859-4.TXT */ static const hts_UCS4 table_iso_8859_4[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x0085, 0x0086, 0x0087, 0x0088, 0x0089, 0x008a, 0x008b, 0x008c, 0x008d, 0x008e, 0x008f, 0x0090, 0x0091, 0x0092, 0x0093, 0x0094, 0x0095, 0x0096, 0x0097, 0x0098, 0x0099, 0x009a, 0x009b, 0x009c, 0x009d, 0x009e, 0x009f, 0x00a0, 0x0104, 0x0138, 0x0156, 0x00a4, 0x0128, 0x013b, 0x00a7, 0x00a8, 0x0160, 0x0112, 0x0122, 0x0166, 0x00ad, 0x017d, 0x00af, 0x00b0, 0x0105, 0x02db, 0x0157, 0x00b4, 0x0129, 0x013c, 0x02c7, 0x00b8, 0x0161, 0x0113, 0x0123, 0x0167, 0x014a, 0x017e, 0x014b, 0x0100, 0x00c1, 0x00c2, 0x00c3, 0x00c4, 0x00c5, 0x00c6, 0x012e, 0x010c, 0x00c9, 0x0118, 0x00cb, 0x0116, 0x00cd, 0x00ce, 0x012a, 0x0110, 0x0145, 0x014c, 0x0136, 0x00d4, 0x00d5, 0x00d6, 0x00d7, 0x00d8, 0x0172, 0x00da, 0x00db, 0x00dc, 0x0168, 0x016a, 0x00df, 0x0101, 0x00e1, 0x00e2, 0x00e3, 0x00e4, 0x00e5, 0x00e6, 0x012f, 0x010d, 0x00e9, 0x0119, 0x00eb, 0x0117, 0x00ed, 0x00ee, 0x012b, 0x0111, 0x0146, 0x014d, 0x0137, 0x00f4, 0x00f5, 0x00f6, 0x00f7, 0x00f8, 0x0173, 0x00fa, 0x00fb, 0x00fc, 0x0169, 0x016b, 0x02d9 }; /* Table for 8859-5.TXT */ static const hts_UCS4 table_iso_8859_5[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x0085, 0x0086, 0x0087, 0x0088, 0x0089, 0x008a, 0x008b, 0x008c, 0x008d, 0x008e, 0x008f, 0x0090, 0x0091, 0x0092, 0x0093, 0x0094, 0x0095, 0x0096, 0x0097, 0x0098, 0x0099, 0x009a, 0x009b, 0x009c, 0x009d, 0x009e, 0x009f, 0x00a0, 0x0401, 0x0402, 0x0403, 0x0404, 0x0405, 0x0406, 0x0407, 0x0408, 0x0409, 0x040a, 0x040b, 0x040c, 0x00ad, 0x040e, 0x040f, 0x0410, 0x0411, 0x0412, 0x0413, 0x0414, 0x0415, 0x0416, 0x0417, 0x0418, 0x0419, 0x041a, 0x041b, 0x041c, 0x041d, 0x041e, 0x041f, 0x0420, 0x0421, 0x0422, 0x0423, 0x0424, 0x0425, 0x0426, 0x0427, 0x0428, 0x0429, 0x042a, 0x042b, 0x042c, 0x042d, 0x042e, 0x042f, 0x0430, 0x0431, 0x0432, 0x0433, 0x0434, 0x0435, 0x0436, 0x0437, 0x0438, 0x0439, 0x043a, 0x043b, 0x043c, 0x043d, 0x043e, 0x043f, 0x0440, 0x0441, 0x0442, 0x0443, 0x0444, 0x0445, 0x0446, 0x0447, 0x0448, 0x0449, 0x044a, 0x044b, 0x044c, 0x044d, 0x044e, 0x044f, 0x2116, 0x0451, 0x0452, 0x0453, 0x0454, 0x0455, 0x0456, 0x0457, 0x0458, 0x0459, 0x045a, 0x045b, 0x045c, 0x00a7, 0x045e, 0x045f }; /* Table for 8859-6.TXT */ static const hts_UCS4 table_iso_8859_6[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x0085, 0x0086, 0x0087, 0x0088, 0x0089, 0x008a, 0x008b, 0x008c, 0x008d, 0x008e, 0x008f, 0x0090, 0x0091, 0x0092, 0x0093, 0x0094, 0x0095, 0x0096, 0x0097, 0x0098, 0x0099, 0x009a, 0x009b, 0x009c, 0x009d, 0x009e, 0x009f, 0x00a0, 0x0000, 0x0000, 0x0000, 0x00a4, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x060c, 0x00ad, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x061b, 0x0000, 0x0000, 0x0000, 0x061f, 0x0000, 0x0621, 0x0622, 0x0623, 0x0624, 0x0625, 0x0626, 0x0627, 0x0628, 0x0629, 0x062a, 0x062b, 0x062c, 0x062d, 0x062e, 0x062f, 0x0630, 0x0631, 0x0632, 0x0633, 0x0634, 0x0635, 0x0636, 0x0637, 0x0638, 0x0639, 0x063a, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0640, 0x0641, 0x0642, 0x0643, 0x0644, 0x0645, 0x0646, 0x0647, 0x0648, 0x0649, 0x064a, 0x064b, 0x064c, 0x064d, 0x064e, 0x064f, 0x0650, 0x0651, 0x0652, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000 }; /* Table for 8859-7.TXT */ static const hts_UCS4 table_iso_8859_7[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x0085, 0x0086, 0x0087, 0x0088, 0x0089, 0x008a, 0x008b, 0x008c, 0x008d, 0x008e, 0x008f, 0x0090, 0x0091, 0x0092, 0x0093, 0x0094, 0x0095, 0x0096, 0x0097, 0x0098, 0x0099, 0x009a, 0x009b, 0x009c, 0x009d, 0x009e, 0x009f, 0x00a0, 0x2018, 0x2019, 0x00a3, 0x20ac, 0x20af, 0x00a6, 0x00a7, 0x00a8, 0x00a9, 0x037a, 0x00ab, 0x00ac, 0x00ad, 0x0000, 0x2015, 0x00b0, 0x00b1, 0x00b2, 0x00b3, 0x0384, 0x0385, 0x0386, 0x00b7, 0x0388, 0x0389, 0x038a, 0x00bb, 0x038c, 0x00bd, 0x038e, 0x038f, 0x0390, 0x0391, 0x0392, 0x0393, 0x0394, 0x0395, 0x0396, 0x0397, 0x0398, 0x0399, 0x039a, 0x039b, 0x039c, 0x039d, 0x039e, 0x039f, 0x03a0, 0x03a1, 0x0000, 0x03a3, 0x03a4, 0x03a5, 0x03a6, 0x03a7, 0x03a8, 0x03a9, 0x03aa, 0x03ab, 0x03ac, 0x03ad, 0x03ae, 0x03af, 0x03b0, 0x03b1, 0x03b2, 0x03b3, 0x03b4, 0x03b5, 0x03b6, 0x03b7, 0x03b8, 0x03b9, 0x03ba, 0x03bb, 0x03bc, 0x03bd, 0x03be, 0x03bf, 0x03c0, 0x03c1, 0x03c2, 0x03c3, 0x03c4, 0x03c5, 0x03c6, 0x03c7, 0x03c8, 0x03c9, 0x03ca, 0x03cb, 0x03cc, 0x03cd, 0x03ce, 0x0000 }; /* Table for 8859-8.TXT */ static const hts_UCS4 table_iso_8859_8[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x0085, 0x0086, 0x0087, 0x0088, 0x0089, 0x008a, 0x008b, 0x008c, 0x008d, 0x008e, 0x008f, 0x0090, 0x0091, 0x0092, 0x0093, 0x0094, 0x0095, 0x0096, 0x0097, 0x0098, 0x0099, 0x009a, 0x009b, 0x009c, 0x009d, 0x009e, 0x009f, 0x00a0, 0x0000, 0x00a2, 0x00a3, 0x00a4, 0x00a5, 0x00a6, 0x00a7, 0x00a8, 0x00a9, 0x00d7, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x00af, 0x00b0, 0x00b1, 0x00b2, 0x00b3, 0x00b4, 0x00b5, 0x00b6, 0x00b7, 0x00b8, 0x00b9, 0x00f7, 0x00bb, 0x00bc, 0x00bd, 0x00be, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x2017, 0x05d0, 0x05d1, 0x05d2, 0x05d3, 0x05d4, 0x05d5, 0x05d6, 0x05d7, 0x05d8, 0x05d9, 0x05da, 0x05db, 0x05dc, 0x05dd, 0x05de, 0x05df, 0x05e0, 0x05e1, 0x05e2, 0x05e3, 0x05e4, 0x05e5, 0x05e6, 0x05e7, 0x05e8, 0x05e9, 0x05ea, 0x0000, 0x0000, 0x200e, 0x200f, 0x0000 }; /* Table for 8859-9.TXT */ static const hts_UCS4 table_iso_8859_9[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x0085, 0x0086, 0x0087, 0x0088, 0x0089, 0x008a, 0x008b, 0x008c, 0x008d, 0x008e, 0x008f, 0x0090, 0x0091, 0x0092, 0x0093, 0x0094, 0x0095, 0x0096, 0x0097, 0x0098, 0x0099, 0x009a, 0x009b, 0x009c, 0x009d, 0x009e, 0x009f, 0x00a0, 0x00a1, 0x00a2, 0x00a3, 0x00a4, 0x00a5, 0x00a6, 0x00a7, 0x00a8, 0x00a9, 0x00aa, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x00af, 0x00b0, 0x00b1, 0x00b2, 0x00b3, 0x00b4, 0x00b5, 0x00b6, 0x00b7, 0x00b8, 0x00b9, 0x00ba, 0x00bb, 0x00bc, 0x00bd, 0x00be, 0x00bf, 0x00c0, 0x00c1, 0x00c2, 0x00c3, 0x00c4, 0x00c5, 0x00c6, 0x00c7, 0x00c8, 0x00c9, 0x00ca, 0x00cb, 0x00cc, 0x00cd, 0x00ce, 0x00cf, 0x011e, 0x00d1, 0x00d2, 0x00d3, 0x00d4, 0x00d5, 0x00d6, 0x00d7, 0x00d8, 0x00d9, 0x00da, 0x00db, 0x00dc, 0x0130, 0x015e, 0x00df, 0x00e0, 0x00e1, 0x00e2, 0x00e3, 0x00e4, 0x00e5, 0x00e6, 0x00e7, 0x00e8, 0x00e9, 0x00ea, 0x00eb, 0x00ec, 0x00ed, 0x00ee, 0x00ef, 0x011f, 0x00f1, 0x00f2, 0x00f3, 0x00f4, 0x00f5, 0x00f6, 0x00f7, 0x00f8, 0x00f9, 0x00fa, 0x00fb, 0x00fc, 0x0131, 0x015f, 0x00ff }; /* Table for CP037.TXT */ static const hts_UCS4 table_cp037[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x009c, 0x0009, 0x0086, 0x007f, 0x0097, 0x008d, 0x008e, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x009d, 0x0085, 0x0008, 0x0087, 0x0018, 0x0019, 0x0092, 0x008f, 0x001c, 0x001d, 0x001e, 0x001f, 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x000a, 0x0017, 0x001b, 0x0088, 0x0089, 0x008a, 0x008b, 0x008c, 0x0005, 0x0006, 0x0007, 0x0090, 0x0091, 0x0016, 0x0093, 0x0094, 0x0095, 0x0096, 0x0004, 0x0098, 0x0099, 0x009a, 0x009b, 0x0014, 0x0015, 0x009e, 0x001a, 0x0020, 0x00a0, 0x00e2, 0x00e4, 0x00e0, 0x00e1, 0x00e3, 0x00e5, 0x00e7, 0x00f1, 0x00a2, 0x002e, 0x003c, 0x0028, 0x002b, 0x007c, 0x0026, 0x00e9, 0x00ea, 0x00eb, 0x00e8, 0x00ed, 0x00ee, 0x00ef, 0x00ec, 0x00df, 0x0021, 0x0024, 0x002a, 0x0029, 0x003b, 0x00ac, 0x002d, 0x002f, 0x00c2, 0x00c4, 0x00c0, 0x00c1, 0x00c3, 0x00c5, 0x00c7, 0x00d1, 0x00a6, 0x002c, 0x0025, 0x005f, 0x003e, 0x003f, 0x00f8, 0x00c9, 0x00ca, 0x00cb, 0x00c8, 0x00cd, 0x00ce, 0x00cf, 0x00cc, 0x0060, 0x003a, 0x0023, 0x0040, 0x0027, 0x003d, 0x0022, 0x00d8, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x00ab, 0x00bb, 0x00f0, 0x00fd, 0x00fe, 0x00b1, 0x00b0, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x00aa, 0x00ba, 0x00e6, 0x00b8, 0x00c6, 0x00a4, 0x00b5, 0x007e, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x00a1, 0x00bf, 0x00d0, 0x00dd, 0x00de, 0x00ae, 0x005e, 0x00a3, 0x00a5, 0x00b7, 0x00a9, 0x00a7, 0x00b6, 0x00bc, 0x00bd, 0x00be, 0x005b, 0x005d, 0x00af, 0x00a8, 0x00b4, 0x00d7, 0x007b, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x00ad, 0x00f4, 0x00f6, 0x00f2, 0x00f3, 0x00f5, 0x007d, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x00b9, 0x00fb, 0x00fc, 0x00f9, 0x00fa, 0x00ff, 0x005c, 0x00f7, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x00b2, 0x00d4, 0x00d6, 0x00d2, 0x00d3, 0x00d5, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x00b3, 0x00db, 0x00dc, 0x00d9, 0x00da, 0x009f }; /* Table for CP1006.TXT */ static const hts_UCS4 table_cp1006[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x0085, 0x0086, 0x0087, 0x0088, 0x0089, 0x008a, 0x008b, 0x008c, 0x008d, 0x008e, 0x008f, 0x0090, 0x0091, 0x0092, 0x0093, 0x0094, 0x0095, 0x0096, 0x0097, 0x0098, 0x0099, 0x009a, 0x009b, 0x009c, 0x009d, 0x009e, 0x009f, 0x00a0, 0x06f0, 0x06f1, 0x06f2, 0x06f3, 0x06f4, 0x06f5, 0x06f6, 0x06f7, 0x06f8, 0x06f9, 0x060c, 0x061b, 0x00ad, 0x061f, 0xfe81, 0xfe8d, 0xfe8e, 0xfe8e, 0xfe8f, 0xfe91, 0xfb56, 0xfb58, 0xfe93, 0xfe95, 0xfe97, 0xfb66, 0xfb68, 0xfe99, 0xfe9b, 0xfe9d, 0xfe9f, 0xfb7a, 0xfb7c, 0xfea1, 0xfea3, 0xfea5, 0xfea7, 0xfea9, 0xfb84, 0xfeab, 0xfead, 0xfb8c, 0xfeaf, 0xfb8a, 0xfeb1, 0xfeb3, 0xfeb5, 0xfeb7, 0xfeb9, 0xfebb, 0xfebd, 0xfebf, 0xfec1, 0xfec5, 0xfec9, 0xfeca, 0xfecb, 0xfecc, 0xfecd, 0xfece, 0xfecf, 0xfed0, 0xfed1, 0xfed3, 0xfed5, 0xfed7, 0xfed9, 0xfedb, 0xfb92, 0xfb94, 0xfedd, 0xfedf, 0xfee0, 0xfee1, 0xfee3, 0xfb9e, 0xfee5, 0xfee7, 0xfe85, 0xfeed, 0xfba6, 0xfba8, 0xfba9, 0xfbaa, 0xfe80, 0xfe89, 0xfe8a, 0xfe8b, 0xfef1, 0xfef2, 0xfef3, 0xfbb0, 0xfbae, 0xfe7c, 0xfe7d }; /* Table for CP1026.TXT */ static const hts_UCS4 table_cp1026[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x009c, 0x0009, 0x0086, 0x007f, 0x0097, 0x008d, 0x008e, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x009d, 0x0085, 0x0008, 0x0087, 0x0018, 0x0019, 0x0092, 0x008f, 0x001c, 0x001d, 0x001e, 0x001f, 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x000a, 0x0017, 0x001b, 0x0088, 0x0089, 0x008a, 0x008b, 0x008c, 0x0005, 0x0006, 0x0007, 0x0090, 0x0091, 0x0016, 0x0093, 0x0094, 0x0095, 0x0096, 0x0004, 0x0098, 0x0099, 0x009a, 0x009b, 0x0014, 0x0015, 0x009e, 0x001a, 0x0020, 0x00a0, 0x00e2, 0x00e4, 0x00e0, 0x00e1, 0x00e3, 0x00e5, 0x007b, 0x00f1, 0x00c7, 0x002e, 0x003c, 0x0028, 0x002b, 0x0021, 0x0026, 0x00e9, 0x00ea, 0x00eb, 0x00e8, 0x00ed, 0x00ee, 0x00ef, 0x00ec, 0x00df, 0x011e, 0x0130, 0x002a, 0x0029, 0x003b, 0x005e, 0x002d, 0x002f, 0x00c2, 0x00c4, 0x00c0, 0x00c1, 0x00c3, 0x00c5, 0x005b, 0x00d1, 0x015f, 0x002c, 0x0025, 0x005f, 0x003e, 0x003f, 0x00f8, 0x00c9, 0x00ca, 0x00cb, 0x00c8, 0x00cd, 0x00ce, 0x00cf, 0x00cc, 0x0131, 0x003a, 0x00d6, 0x015e, 0x0027, 0x003d, 0x00dc, 0x00d8, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x00ab, 0x00bb, 0x007d, 0x0060, 0x00a6, 0x00b1, 0x00b0, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x00aa, 0x00ba, 0x00e6, 0x00b8, 0x00c6, 0x00a4, 0x00b5, 0x00f6, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x00a1, 0x00bf, 0x005d, 0x0024, 0x0040, 0x00ae, 0x00a2, 0x00a3, 0x00a5, 0x00b7, 0x00a9, 0x00a7, 0x00b6, 0x00bc, 0x00bd, 0x00be, 0x00ac, 0x007c, 0x00af, 0x00a8, 0x00b4, 0x00d7, 0x00e7, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x00ad, 0x00f4, 0x007e, 0x00f2, 0x00f3, 0x00f5, 0x011f, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x00b9, 0x00fb, 0x005c, 0x00f9, 0x00fa, 0x00ff, 0x00fc, 0x00f7, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x00b2, 0x00d4, 0x0023, 0x00d2, 0x00d3, 0x00d5, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x00b3, 0x00db, 0x0022, 0x00d9, 0x00da, 0x009f }; /* Table for CP1250.TXT */ static const hts_UCS4 table_cp1250[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x20ac, 0x0081, 0x201a, 0x0083, 0x201e, 0x2026, 0x2020, 0x2021, 0x0088, 0x2030, 0x0160, 0x2039, 0x015a, 0x0164, 0x017d, 0x0179, 0x0090, 0x2018, 0x2019, 0x201c, 0x201d, 0x2022, 0x2013, 0x2014, 0x0098, 0x2122, 0x0161, 0x203a, 0x015b, 0x0165, 0x017e, 0x017a, 0x00a0, 0x02c7, 0x02d8, 0x0141, 0x00a4, 0x0104, 0x00a6, 0x00a7, 0x00a8, 0x00a9, 0x015e, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x017b, 0x00b0, 0x00b1, 0x02db, 0x0142, 0x00b4, 0x00b5, 0x00b6, 0x00b7, 0x00b8, 0x0105, 0x015f, 0x00bb, 0x013d, 0x02dd, 0x013e, 0x017c, 0x0154, 0x00c1, 0x00c2, 0x0102, 0x00c4, 0x0139, 0x0106, 0x00c7, 0x010c, 0x00c9, 0x0118, 0x00cb, 0x011a, 0x00cd, 0x00ce, 0x010e, 0x0110, 0x0143, 0x0147, 0x00d3, 0x00d4, 0x0150, 0x00d6, 0x00d7, 0x0158, 0x016e, 0x00da, 0x0170, 0x00dc, 0x00dd, 0x0162, 0x00df, 0x0155, 0x00e1, 0x00e2, 0x0103, 0x00e4, 0x013a, 0x0107, 0x00e7, 0x010d, 0x00e9, 0x0119, 0x00eb, 0x011b, 0x00ed, 0x00ee, 0x010f, 0x0111, 0x0144, 0x0148, 0x00f3, 0x00f4, 0x0151, 0x00f6, 0x00f7, 0x0159, 0x016f, 0x00fa, 0x0171, 0x00fc, 0x00fd, 0x0163, 0x02d9 }; /* Table for CP1251.TXT */ static const hts_UCS4 table_cp1251[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x0402, 0x0403, 0x201a, 0x0453, 0x201e, 0x2026, 0x2020, 0x2021, 0x20ac, 0x2030, 0x0409, 0x2039, 0x040a, 0x040c, 0x040b, 0x040f, 0x0452, 0x2018, 0x2019, 0x201c, 0x201d, 0x2022, 0x2013, 0x2014, 0x0098, 0x2122, 0x0459, 0x203a, 0x045a, 0x045c, 0x045b, 0x045f, 0x00a0, 0x040e, 0x045e, 0x0408, 0x00a4, 0x0490, 0x00a6, 0x00a7, 0x0401, 0x00a9, 0x0404, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x0407, 0x00b0, 0x00b1, 0x0406, 0x0456, 0x0491, 0x00b5, 0x00b6, 0x00b7, 0x0451, 0x2116, 0x0454, 0x00bb, 0x0458, 0x0405, 0x0455, 0x0457, 0x0410, 0x0411, 0x0412, 0x0413, 0x0414, 0x0415, 0x0416, 0x0417, 0x0418, 0x0419, 0x041a, 0x041b, 0x041c, 0x041d, 0x041e, 0x041f, 0x0420, 0x0421, 0x0422, 0x0423, 0x0424, 0x0425, 0x0426, 0x0427, 0x0428, 0x0429, 0x042a, 0x042b, 0x042c, 0x042d, 0x042e, 0x042f, 0x0430, 0x0431, 0x0432, 0x0433, 0x0434, 0x0435, 0x0436, 0x0437, 0x0438, 0x0439, 0x043a, 0x043b, 0x043c, 0x043d, 0x043e, 0x043f, 0x0440, 0x0441, 0x0442, 0x0443, 0x0444, 0x0445, 0x0446, 0x0447, 0x0448, 0x0449, 0x044a, 0x044b, 0x044c, 0x044d, 0x044e, 0x044f }; /* Table for CP1252.TXT */ static const hts_UCS4 table_cp1252[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x20ac, 0x0081, 0x201a, 0x0192, 0x201e, 0x2026, 0x2020, 0x2021, 0x02c6, 0x2030, 0x0160, 0x2039, 0x0152, 0x008d, 0x017d, 0x008f, 0x0090, 0x2018, 0x2019, 0x201c, 0x201d, 0x2022, 0x2013, 0x2014, 0x02dc, 0x2122, 0x0161, 0x203a, 0x0153, 0x009d, 0x017e, 0x0178, 0x00a0, 0x00a1, 0x00a2, 0x00a3, 0x00a4, 0x00a5, 0x00a6, 0x00a7, 0x00a8, 0x00a9, 0x00aa, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x00af, 0x00b0, 0x00b1, 0x00b2, 0x00b3, 0x00b4, 0x00b5, 0x00b6, 0x00b7, 0x00b8, 0x00b9, 0x00ba, 0x00bb, 0x00bc, 0x00bd, 0x00be, 0x00bf, 0x00c0, 0x00c1, 0x00c2, 0x00c3, 0x00c4, 0x00c5, 0x00c6, 0x00c7, 0x00c8, 0x00c9, 0x00ca, 0x00cb, 0x00cc, 0x00cd, 0x00ce, 0x00cf, 0x00d0, 0x00d1, 0x00d2, 0x00d3, 0x00d4, 0x00d5, 0x00d6, 0x00d7, 0x00d8, 0x00d9, 0x00da, 0x00db, 0x00dc, 0x00dd, 0x00de, 0x00df, 0x00e0, 0x00e1, 0x00e2, 0x00e3, 0x00e4, 0x00e5, 0x00e6, 0x00e7, 0x00e8, 0x00e9, 0x00ea, 0x00eb, 0x00ec, 0x00ed, 0x00ee, 0x00ef, 0x00f0, 0x00f1, 0x00f2, 0x00f3, 0x00f4, 0x00f5, 0x00f6, 0x00f7, 0x00f8, 0x00f9, 0x00fa, 0x00fb, 0x00fc, 0x00fd, 0x00fe, 0x00ff }; /* Table for CP1253.TXT */ static const hts_UCS4 table_cp1253[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x20ac, 0x0081, 0x201a, 0x0192, 0x201e, 0x2026, 0x2020, 0x2021, 0x0088, 0x2030, 0x008a, 0x2039, 0x008c, 0x008d, 0x008e, 0x008f, 0x0090, 0x2018, 0x2019, 0x201c, 0x201d, 0x2022, 0x2013, 0x2014, 0x0098, 0x2122, 0x009a, 0x203a, 0x009c, 0x009d, 0x009e, 0x009f, 0x00a0, 0x0385, 0x0386, 0x00a3, 0x00a4, 0x00a5, 0x00a6, 0x00a7, 0x00a8, 0x00a9, 0x00aa, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x2015, 0x00b0, 0x00b1, 0x00b2, 0x00b3, 0x0384, 0x00b5, 0x00b6, 0x00b7, 0x0388, 0x0389, 0x038a, 0x00bb, 0x038c, 0x00bd, 0x038e, 0x038f, 0x0390, 0x0391, 0x0392, 0x0393, 0x0394, 0x0395, 0x0396, 0x0397, 0x0398, 0x0399, 0x039a, 0x039b, 0x039c, 0x039d, 0x039e, 0x039f, 0x03a0, 0x03a1, 0x00d2, 0x03a3, 0x03a4, 0x03a5, 0x03a6, 0x03a7, 0x03a8, 0x03a9, 0x03aa, 0x03ab, 0x03ac, 0x03ad, 0x03ae, 0x03af, 0x03b0, 0x03b1, 0x03b2, 0x03b3, 0x03b4, 0x03b5, 0x03b6, 0x03b7, 0x03b8, 0x03b9, 0x03ba, 0x03bb, 0x03bc, 0x03bd, 0x03be, 0x03bf, 0x03c0, 0x03c1, 0x03c2, 0x03c3, 0x03c4, 0x03c5, 0x03c6, 0x03c7, 0x03c8, 0x03c9, 0x03ca, 0x03cb, 0x03cc, 0x03cd, 0x03ce, 0x00ff }; /* Table for CP1254.TXT */ static const hts_UCS4 table_cp1254[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x20ac, 0x0081, 0x201a, 0x0192, 0x201e, 0x2026, 0x2020, 0x2021, 0x02c6, 0x2030, 0x0160, 0x2039, 0x0152, 0x008d, 0x008e, 0x008f, 0x0090, 0x2018, 0x2019, 0x201c, 0x201d, 0x2022, 0x2013, 0x2014, 0x02dc, 0x2122, 0x0161, 0x203a, 0x0153, 0x009d, 0x009e, 0x0178, 0x00a0, 0x00a1, 0x00a2, 0x00a3, 0x00a4, 0x00a5, 0x00a6, 0x00a7, 0x00a8, 0x00a9, 0x00aa, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x00af, 0x00b0, 0x00b1, 0x00b2, 0x00b3, 0x00b4, 0x00b5, 0x00b6, 0x00b7, 0x00b8, 0x00b9, 0x00ba, 0x00bb, 0x00bc, 0x00bd, 0x00be, 0x00bf, 0x00c0, 0x00c1, 0x00c2, 0x00c3, 0x00c4, 0x00c5, 0x00c6, 0x00c7, 0x00c8, 0x00c9, 0x00ca, 0x00cb, 0x00cc, 0x00cd, 0x00ce, 0x00cf, 0x011e, 0x00d1, 0x00d2, 0x00d3, 0x00d4, 0x00d5, 0x00d6, 0x00d7, 0x00d8, 0x00d9, 0x00da, 0x00db, 0x00dc, 0x0130, 0x015e, 0x00df, 0x00e0, 0x00e1, 0x00e2, 0x00e3, 0x00e4, 0x00e5, 0x00e6, 0x00e7, 0x00e8, 0x00e9, 0x00ea, 0x00eb, 0x00ec, 0x00ed, 0x00ee, 0x00ef, 0x011f, 0x00f1, 0x00f2, 0x00f3, 0x00f4, 0x00f5, 0x00f6, 0x00f7, 0x00f8, 0x00f9, 0x00fa, 0x00fb, 0x00fc, 0x0131, 0x015f, 0x00ff }; /* Table for CP1255.TXT */ static const hts_UCS4 table_cp1255[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x20ac, 0x0081, 0x201a, 0x0192, 0x201e, 0x2026, 0x2020, 0x2021, 0x02c6, 0x2030, 0x008a, 0x2039, 0x008c, 0x008d, 0x008e, 0x008f, 0x0090, 0x2018, 0x2019, 0x201c, 0x201d, 0x2022, 0x2013, 0x2014, 0x02dc, 0x2122, 0x009a, 0x203a, 0x009c, 0x009d, 0x009e, 0x009f, 0x00a0, 0x00a1, 0x00a2, 0x00a3, 0x20aa, 0x00a5, 0x00a6, 0x00a7, 0x00a8, 0x00a9, 0x00d7, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x00af, 0x00b0, 0x00b1, 0x00b2, 0x00b3, 0x00b4, 0x00b5, 0x00b6, 0x00b7, 0x00b8, 0x00b9, 0x00f7, 0x00bb, 0x00bc, 0x00bd, 0x00be, 0x00bf, 0x05b0, 0x05b1, 0x05b2, 0x05b3, 0x05b4, 0x05b5, 0x05b6, 0x05b7, 0x05b8, 0x05b9, 0x00ca, 0x05bb, 0x05bc, 0x05bd, 0x05be, 0x05bf, 0x05c0, 0x05c1, 0x05c2, 0x05c3, 0x05f0, 0x05f1, 0x05f2, 0x05f3, 0x05f4, 0x00d9, 0x00da, 0x00db, 0x00dc, 0x00dd, 0x00de, 0x00df, 0x05d0, 0x05d1, 0x05d2, 0x05d3, 0x05d4, 0x05d5, 0x05d6, 0x05d7, 0x05d8, 0x05d9, 0x05da, 0x05db, 0x05dc, 0x05dd, 0x05de, 0x05df, 0x05e0, 0x05e1, 0x05e2, 0x05e3, 0x05e4, 0x05e5, 0x05e6, 0x05e7, 0x05e8, 0x05e9, 0x05ea, 0x00fb, 0x00fc, 0x200e, 0x200f, 0x00ff }; /* Table for CP1256.TXT */ static const hts_UCS4 table_cp1256[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x20ac, 0x067e, 0x201a, 0x0192, 0x201e, 0x2026, 0x2020, 0x2021, 0x02c6, 0x2030, 0x0679, 0x2039, 0x0152, 0x0686, 0x0698, 0x0688, 0x06af, 0x2018, 0x2019, 0x201c, 0x201d, 0x2022, 0x2013, 0x2014, 0x06a9, 0x2122, 0x0691, 0x203a, 0x0153, 0x200c, 0x200d, 0x06ba, 0x00a0, 0x060c, 0x00a2, 0x00a3, 0x00a4, 0x00a5, 0x00a6, 0x00a7, 0x00a8, 0x00a9, 0x06be, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x00af, 0x00b0, 0x00b1, 0x00b2, 0x00b3, 0x00b4, 0x00b5, 0x00b6, 0x00b7, 0x00b8, 0x00b9, 0x061b, 0x00bb, 0x00bc, 0x00bd, 0x00be, 0x061f, 0x06c1, 0x0621, 0x0622, 0x0623, 0x0624, 0x0625, 0x0626, 0x0627, 0x0628, 0x0629, 0x062a, 0x062b, 0x062c, 0x062d, 0x062e, 0x062f, 0x0630, 0x0631, 0x0632, 0x0633, 0x0634, 0x0635, 0x0636, 0x00d7, 0x0637, 0x0638, 0x0639, 0x063a, 0x0640, 0x0641, 0x0642, 0x0643, 0x00e0, 0x0644, 0x00e2, 0x0645, 0x0646, 0x0647, 0x0648, 0x00e7, 0x00e8, 0x00e9, 0x00ea, 0x00eb, 0x0649, 0x064a, 0x00ee, 0x00ef, 0x064b, 0x064c, 0x064d, 0x064e, 0x00f4, 0x064f, 0x0650, 0x00f7, 0x0651, 0x00f9, 0x0652, 0x00fb, 0x00fc, 0x200e, 0x200f, 0x06d2 }; /* Table for CP1257.TXT */ static const hts_UCS4 table_cp1257[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x20ac, 0x0081, 0x201a, 0x0083, 0x201e, 0x2026, 0x2020, 0x2021, 0x0088, 0x2030, 0x008a, 0x2039, 0x008c, 0x00a8, 0x02c7, 0x00b8, 0x0090, 0x2018, 0x2019, 0x201c, 0x201d, 0x2022, 0x2013, 0x2014, 0x0098, 0x2122, 0x009a, 0x203a, 0x009c, 0x00af, 0x02db, 0x009f, 0x00a0, 0x00a1, 0x00a2, 0x00a3, 0x00a4, 0x00a5, 0x00a6, 0x00a7, 0x00d8, 0x00a9, 0x0156, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x00c6, 0x00b0, 0x00b1, 0x00b2, 0x00b3, 0x00b4, 0x00b5, 0x00b6, 0x00b7, 0x00f8, 0x00b9, 0x0157, 0x00bb, 0x00bc, 0x00bd, 0x00be, 0x00e6, 0x0104, 0x012e, 0x0100, 0x0106, 0x00c4, 0x00c5, 0x0118, 0x0112, 0x010c, 0x00c9, 0x0179, 0x0116, 0x0122, 0x0136, 0x012a, 0x013b, 0x0160, 0x0143, 0x0145, 0x00d3, 0x014c, 0x00d5, 0x00d6, 0x00d7, 0x0172, 0x0141, 0x015a, 0x016a, 0x00dc, 0x017b, 0x017d, 0x00df, 0x0105, 0x012f, 0x0101, 0x0107, 0x00e4, 0x00e5, 0x0119, 0x0113, 0x010d, 0x00e9, 0x017a, 0x0117, 0x0123, 0x0137, 0x012b, 0x013c, 0x0161, 0x0144, 0x0146, 0x00f3, 0x014d, 0x00f5, 0x00f6, 0x00f7, 0x0173, 0x0142, 0x015b, 0x016b, 0x00fc, 0x017c, 0x017e, 0x02d9 }; /* Table for CP1258.TXT */ static const hts_UCS4 table_cp1258[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x20ac, 0x0081, 0x201a, 0x0192, 0x201e, 0x2026, 0x2020, 0x2021, 0x02c6, 0x2030, 0x008a, 0x2039, 0x0152, 0x008d, 0x008e, 0x008f, 0x0090, 0x2018, 0x2019, 0x201c, 0x201d, 0x2022, 0x2013, 0x2014, 0x02dc, 0x2122, 0x009a, 0x203a, 0x0153, 0x009d, 0x009e, 0x0178, 0x00a0, 0x00a1, 0x00a2, 0x00a3, 0x00a4, 0x00a5, 0x00a6, 0x00a7, 0x00a8, 0x00a9, 0x00aa, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x00af, 0x00b0, 0x00b1, 0x00b2, 0x00b3, 0x00b4, 0x00b5, 0x00b6, 0x00b7, 0x00b8, 0x00b9, 0x00ba, 0x00bb, 0x00bc, 0x00bd, 0x00be, 0x00bf, 0x00c0, 0x00c1, 0x00c2, 0x0102, 0x00c4, 0x00c5, 0x00c6, 0x00c7, 0x00c8, 0x00c9, 0x00ca, 0x00cb, 0x0300, 0x00cd, 0x00ce, 0x00cf, 0x0110, 0x00d1, 0x0309, 0x00d3, 0x00d4, 0x01a0, 0x00d6, 0x00d7, 0x00d8, 0x00d9, 0x00da, 0x00db, 0x00dc, 0x01af, 0x0303, 0x00df, 0x00e0, 0x00e1, 0x00e2, 0x0103, 0x00e4, 0x00e5, 0x00e6, 0x00e7, 0x00e8, 0x00e9, 0x00ea, 0x00eb, 0x0301, 0x00ed, 0x00ee, 0x00ef, 0x0111, 0x00f1, 0x0323, 0x00f3, 0x00f4, 0x01a1, 0x00f6, 0x00f7, 0x00f8, 0x00f9, 0x00fa, 0x00fb, 0x00fc, 0x01b0, 0x20ab, 0x00ff }; /* Table for CP424.TXT */ static const hts_UCS4 table_cp424[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x009c, 0x0009, 0x0086, 0x007f, 0x0097, 0x008d, 0x008e, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x009d, 0x0085, 0x0008, 0x0087, 0x0018, 0x0019, 0x0092, 0x008f, 0x001c, 0x001d, 0x001e, 0x001f, 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x000a, 0x0017, 0x001b, 0x0088, 0x0089, 0x008a, 0x008b, 0x008c, 0x0005, 0x0006, 0x0007, 0x0090, 0x0091, 0x0016, 0x0093, 0x0094, 0x0095, 0x0096, 0x0004, 0x0098, 0x0099, 0x009a, 0x009b, 0x0014, 0x0015, 0x009e, 0x001a, 0x0020, 0x05d0, 0x05d1, 0x05d2, 0x05d3, 0x05d4, 0x05d5, 0x05d6, 0x05d7, 0x05d8, 0x00a2, 0x002e, 0x003c, 0x0028, 0x002b, 0x007c, 0x0026, 0x05d9, 0x05da, 0x05db, 0x05dc, 0x05dd, 0x05de, 0x05df, 0x05e0, 0x05e1, 0x0021, 0x0024, 0x002a, 0x0029, 0x003b, 0x00ac, 0x002d, 0x002f, 0x05e2, 0x05e3, 0x05e4, 0x05e5, 0x05e6, 0x05e7, 0x05e8, 0x05e9, 0x00a6, 0x002c, 0x0025, 0x005f, 0x003e, 0x003f, 0x0070, 0x05ea, 0x0072, 0x0073, 0x00a0, 0x0075, 0x0076, 0x0077, 0x2017, 0x0060, 0x003a, 0x0023, 0x0040, 0x0027, 0x003d, 0x0022, 0x0080, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x00ab, 0x00bb, 0x008c, 0x008d, 0x008e, 0x00b1, 0x00b0, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x009a, 0x009b, 0x009c, 0x00b8, 0x009e, 0x00a4, 0x00b5, 0x007e, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x00aa, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x00ae, 0x005e, 0x00a3, 0x00a5, 0x00b7, 0x00a9, 0x00a7, 0x00b6, 0x00bc, 0x00bd, 0x00be, 0x005b, 0x005d, 0x00af, 0x00a8, 0x00b4, 0x00d7, 0x007b, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x00ad, 0x00cb, 0x00cc, 0x00cd, 0x00ce, 0x00cf, 0x007d, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x00b9, 0x00db, 0x00dc, 0x00dd, 0x00de, 0x00df, 0x005c, 0x00f7, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x00b2, 0x00eb, 0x00ec, 0x00ed, 0x00ee, 0x00ef, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x00b3, 0x00fb, 0x00fc, 0x00fd, 0x00fe, 0x009f }; /* Table for CP437.TXT */ static const hts_UCS4 table_cp437[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x00c7, 0x00fc, 0x00e9, 0x00e2, 0x00e4, 0x00e0, 0x00e5, 0x00e7, 0x00ea, 0x00eb, 0x00e8, 0x00ef, 0x00ee, 0x00ec, 0x00c4, 0x00c5, 0x00c9, 0x00e6, 0x00c6, 0x00f4, 0x00f6, 0x00f2, 0x00fb, 0x00f9, 0x00ff, 0x00d6, 0x00dc, 0x00a2, 0x00a3, 0x00a5, 0x20a7, 0x0192, 0x00e1, 0x00ed, 0x00f3, 0x00fa, 0x00f1, 0x00d1, 0x00aa, 0x00ba, 0x00bf, 0x2310, 0x00ac, 0x00bd, 0x00bc, 0x00a1, 0x00ab, 0x00bb, 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x2561, 0x2562, 0x2556, 0x2555, 0x2563, 0x2551, 0x2557, 0x255d, 0x255c, 0x255b, 0x2510, 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x255e, 0x255f, 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x2567, 0x2568, 0x2564, 0x2565, 0x2559, 0x2558, 0x2552, 0x2553, 0x256b, 0x256a, 0x2518, 0x250c, 0x2588, 0x2584, 0x258c, 0x2590, 0x2580, 0x03b1, 0x00df, 0x0393, 0x03c0, 0x03a3, 0x03c3, 0x00b5, 0x03c4, 0x03a6, 0x0398, 0x03a9, 0x03b4, 0x221e, 0x03c6, 0x03b5, 0x2229, 0x2261, 0x00b1, 0x2265, 0x2264, 0x2320, 0x2321, 0x00f7, 0x2248, 0x00b0, 0x2219, 0x00b7, 0x221a, 0x207f, 0x00b2, 0x25a0, 0x00a0 }; /* Table for CP500.TXT */ static const hts_UCS4 table_cp500[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x009c, 0x0009, 0x0086, 0x007f, 0x0097, 0x008d, 0x008e, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x009d, 0x0085, 0x0008, 0x0087, 0x0018, 0x0019, 0x0092, 0x008f, 0x001c, 0x001d, 0x001e, 0x001f, 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x000a, 0x0017, 0x001b, 0x0088, 0x0089, 0x008a, 0x008b, 0x008c, 0x0005, 0x0006, 0x0007, 0x0090, 0x0091, 0x0016, 0x0093, 0x0094, 0x0095, 0x0096, 0x0004, 0x0098, 0x0099, 0x009a, 0x009b, 0x0014, 0x0015, 0x009e, 0x001a, 0x0020, 0x00a0, 0x00e2, 0x00e4, 0x00e0, 0x00e1, 0x00e3, 0x00e5, 0x00e7, 0x00f1, 0x005b, 0x002e, 0x003c, 0x0028, 0x002b, 0x0021, 0x0026, 0x00e9, 0x00ea, 0x00eb, 0x00e8, 0x00ed, 0x00ee, 0x00ef, 0x00ec, 0x00df, 0x005d, 0x0024, 0x002a, 0x0029, 0x003b, 0x005e, 0x002d, 0x002f, 0x00c2, 0x00c4, 0x00c0, 0x00c1, 0x00c3, 0x00c5, 0x00c7, 0x00d1, 0x00a6, 0x002c, 0x0025, 0x005f, 0x003e, 0x003f, 0x00f8, 0x00c9, 0x00ca, 0x00cb, 0x00c8, 0x00cd, 0x00ce, 0x00cf, 0x00cc, 0x0060, 0x003a, 0x0023, 0x0040, 0x0027, 0x003d, 0x0022, 0x00d8, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x00ab, 0x00bb, 0x00f0, 0x00fd, 0x00fe, 0x00b1, 0x00b0, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x00aa, 0x00ba, 0x00e6, 0x00b8, 0x00c6, 0x00a4, 0x00b5, 0x007e, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x00a1, 0x00bf, 0x00d0, 0x00dd, 0x00de, 0x00ae, 0x00a2, 0x00a3, 0x00a5, 0x00b7, 0x00a9, 0x00a7, 0x00b6, 0x00bc, 0x00bd, 0x00be, 0x00ac, 0x007c, 0x00af, 0x00a8, 0x00b4, 0x00d7, 0x007b, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x00ad, 0x00f4, 0x00f6, 0x00f2, 0x00f3, 0x00f5, 0x007d, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x00b9, 0x00fb, 0x00fc, 0x00f9, 0x00fa, 0x00ff, 0x005c, 0x00f7, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x00b2, 0x00d4, 0x00d6, 0x00d2, 0x00d3, 0x00d5, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x00b3, 0x00db, 0x00dc, 0x00d9, 0x00da, 0x009f }; /* Table for CP737.TXT */ static const hts_UCS4 table_cp737[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x0391, 0x0392, 0x0393, 0x0394, 0x0395, 0x0396, 0x0397, 0x0398, 0x0399, 0x039a, 0x039b, 0x039c, 0x039d, 0x039e, 0x039f, 0x03a0, 0x03a1, 0x03a3, 0x03a4, 0x03a5, 0x03a6, 0x03a7, 0x03a8, 0x03a9, 0x03b1, 0x03b2, 0x03b3, 0x03b4, 0x03b5, 0x03b6, 0x03b7, 0x03b8, 0x03b9, 0x03ba, 0x03bb, 0x03bc, 0x03bd, 0x03be, 0x03bf, 0x03c0, 0x03c1, 0x03c3, 0x03c2, 0x03c4, 0x03c5, 0x03c6, 0x03c7, 0x03c8, 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x2561, 0x2562, 0x2556, 0x2555, 0x2563, 0x2551, 0x2557, 0x255d, 0x255c, 0x255b, 0x2510, 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x255e, 0x255f, 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x2567, 0x2568, 0x2564, 0x2565, 0x2559, 0x2558, 0x2552, 0x2553, 0x256b, 0x256a, 0x2518, 0x250c, 0x2588, 0x2584, 0x258c, 0x2590, 0x2580, 0x03c9, 0x03ac, 0x03ad, 0x03ae, 0x03ca, 0x03af, 0x03cc, 0x03cd, 0x03cb, 0x03ce, 0x0386, 0x0388, 0x0389, 0x038a, 0x038c, 0x038e, 0x038f, 0x00b1, 0x2265, 0x2264, 0x03aa, 0x03ab, 0x00f7, 0x2248, 0x00b0, 0x2219, 0x00b7, 0x221a, 0x207f, 0x00b2, 0x25a0, 0x00a0 }; /* Table for CP775.TXT */ static const hts_UCS4 table_cp775[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x0106, 0x00fc, 0x00e9, 0x0101, 0x00e4, 0x0123, 0x00e5, 0x0107, 0x0142, 0x0113, 0x0156, 0x0157, 0x012b, 0x0179, 0x00c4, 0x00c5, 0x00c9, 0x00e6, 0x00c6, 0x014d, 0x00f6, 0x0122, 0x00a2, 0x015a, 0x015b, 0x00d6, 0x00dc, 0x00f8, 0x00a3, 0x00d8, 0x00d7, 0x00a4, 0x0100, 0x012a, 0x00f3, 0x017b, 0x017c, 0x017a, 0x201d, 0x00a6, 0x00a9, 0x00ae, 0x00ac, 0x00bd, 0x00bc, 0x0141, 0x00ab, 0x00bb, 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x0104, 0x010c, 0x0118, 0x0116, 0x2563, 0x2551, 0x2557, 0x255d, 0x012e, 0x0160, 0x2510, 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x0172, 0x016a, 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x017d, 0x0105, 0x010d, 0x0119, 0x0117, 0x012f, 0x0161, 0x0173, 0x016b, 0x017e, 0x2518, 0x250c, 0x2588, 0x2584, 0x258c, 0x2590, 0x2580, 0x00d3, 0x00df, 0x014c, 0x0143, 0x00f5, 0x00d5, 0x00b5, 0x0144, 0x0136, 0x0137, 0x013b, 0x013c, 0x0146, 0x0112, 0x0145, 0x2019, 0x00ad, 0x00b1, 0x201c, 0x00be, 0x00b6, 0x00a7, 0x00f7, 0x201e, 0x00b0, 0x2219, 0x00b7, 0x00b9, 0x00b3, 0x00b2, 0x25a0, 0x00a0 }; /* Table for CP850.TXT */ static const hts_UCS4 table_cp850[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x00c7, 0x00fc, 0x00e9, 0x00e2, 0x00e4, 0x00e0, 0x00e5, 0x00e7, 0x00ea, 0x00eb, 0x00e8, 0x00ef, 0x00ee, 0x00ec, 0x00c4, 0x00c5, 0x00c9, 0x00e6, 0x00c6, 0x00f4, 0x00f6, 0x00f2, 0x00fb, 0x00f9, 0x00ff, 0x00d6, 0x00dc, 0x00f8, 0x00a3, 0x00d8, 0x00d7, 0x0192, 0x00e1, 0x00ed, 0x00f3, 0x00fa, 0x00f1, 0x00d1, 0x00aa, 0x00ba, 0x00bf, 0x00ae, 0x00ac, 0x00bd, 0x00bc, 0x00a1, 0x00ab, 0x00bb, 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x00c1, 0x00c2, 0x00c0, 0x00a9, 0x2563, 0x2551, 0x2557, 0x255d, 0x00a2, 0x00a5, 0x2510, 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x00e3, 0x00c3, 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x00a4, 0x00f0, 0x00d0, 0x00ca, 0x00cb, 0x00c8, 0x0131, 0x00cd, 0x00ce, 0x00cf, 0x2518, 0x250c, 0x2588, 0x2584, 0x00a6, 0x00cc, 0x2580, 0x00d3, 0x00df, 0x00d4, 0x00d2, 0x00f5, 0x00d5, 0x00b5, 0x00fe, 0x00de, 0x00da, 0x00db, 0x00d9, 0x00fd, 0x00dd, 0x00af, 0x00b4, 0x00ad, 0x00b1, 0x2017, 0x00be, 0x00b6, 0x00a7, 0x00f7, 0x00b8, 0x00b0, 0x00a8, 0x00b7, 0x00b9, 0x00b3, 0x00b2, 0x25a0, 0x00a0 }; /* Table for CP852.TXT */ static const hts_UCS4 table_cp852[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x00c7, 0x00fc, 0x00e9, 0x00e2, 0x00e4, 0x016f, 0x0107, 0x00e7, 0x0142, 0x00eb, 0x0150, 0x0151, 0x00ee, 0x0179, 0x00c4, 0x0106, 0x00c9, 0x0139, 0x013a, 0x00f4, 0x00f6, 0x013d, 0x013e, 0x015a, 0x015b, 0x00d6, 0x00dc, 0x0164, 0x0165, 0x0141, 0x00d7, 0x010d, 0x00e1, 0x00ed, 0x00f3, 0x00fa, 0x0104, 0x0105, 0x017d, 0x017e, 0x0118, 0x0119, 0x00ac, 0x017a, 0x010c, 0x015f, 0x00ab, 0x00bb, 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x00c1, 0x00c2, 0x011a, 0x015e, 0x2563, 0x2551, 0x2557, 0x255d, 0x017b, 0x017c, 0x2510, 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x0102, 0x0103, 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x00a4, 0x0111, 0x0110, 0x010e, 0x00cb, 0x010f, 0x0147, 0x00cd, 0x00ce, 0x011b, 0x2518, 0x250c, 0x2588, 0x2584, 0x0162, 0x016e, 0x2580, 0x00d3, 0x00df, 0x00d4, 0x0143, 0x0144, 0x0148, 0x0160, 0x0161, 0x0154, 0x00da, 0x0155, 0x0170, 0x00fd, 0x00dd, 0x0163, 0x00b4, 0x00ad, 0x02dd, 0x02db, 0x02c7, 0x02d8, 0x00a7, 0x00f7, 0x00b8, 0x00b0, 0x00a8, 0x02d9, 0x0171, 0x0158, 0x0159, 0x25a0, 0x00a0 }; /* Table for CP855.TXT */ static const hts_UCS4 table_cp855[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x0452, 0x0402, 0x0453, 0x0403, 0x0451, 0x0401, 0x0454, 0x0404, 0x0455, 0x0405, 0x0456, 0x0406, 0x0457, 0x0407, 0x0458, 0x0408, 0x0459, 0x0409, 0x045a, 0x040a, 0x045b, 0x040b, 0x045c, 0x040c, 0x045e, 0x040e, 0x045f, 0x040f, 0x044e, 0x042e, 0x044a, 0x042a, 0x0430, 0x0410, 0x0431, 0x0411, 0x0446, 0x0426, 0x0434, 0x0414, 0x0435, 0x0415, 0x0444, 0x0424, 0x0433, 0x0413, 0x00ab, 0x00bb, 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x0445, 0x0425, 0x0438, 0x0418, 0x2563, 0x2551, 0x2557, 0x255d, 0x0439, 0x0419, 0x2510, 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x043a, 0x041a, 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x00a4, 0x043b, 0x041b, 0x043c, 0x041c, 0x043d, 0x041d, 0x043e, 0x041e, 0x043f, 0x2518, 0x250c, 0x2588, 0x2584, 0x041f, 0x044f, 0x2580, 0x042f, 0x0440, 0x0420, 0x0441, 0x0421, 0x0442, 0x0422, 0x0443, 0x0423, 0x0436, 0x0416, 0x0432, 0x0412, 0x044c, 0x042c, 0x2116, 0x00ad, 0x044b, 0x042b, 0x0437, 0x0417, 0x0448, 0x0428, 0x044d, 0x042d, 0x0449, 0x0429, 0x0447, 0x0427, 0x00a7, 0x25a0, 0x00a0 }; /* Table for CP856.TXT */ static const hts_UCS4 table_cp856[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x05d0, 0x05d1, 0x05d2, 0x05d3, 0x05d4, 0x05d5, 0x05d6, 0x05d7, 0x05d8, 0x05d9, 0x05da, 0x05db, 0x05dc, 0x05dd, 0x05de, 0x05df, 0x05e0, 0x05e1, 0x05e2, 0x05e3, 0x05e4, 0x05e5, 0x05e6, 0x05e7, 0x05e8, 0x05e9, 0x05ea, 0x009b, 0x00a3, 0x009d, 0x00d7, 0x009f, 0x00a0, 0x00a1, 0x00a2, 0x00a3, 0x00a4, 0x00a5, 0x00a6, 0x00a7, 0x00a8, 0x00ae, 0x00ac, 0x00bd, 0x00bc, 0x00ad, 0x00ab, 0x00bb, 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x00b5, 0x00b6, 0x00b7, 0x00a9, 0x2563, 0x2551, 0x2557, 0x255d, 0x00a2, 0x00a5, 0x2510, 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x00c6, 0x00c7, 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x00a4, 0x00d0, 0x00d1, 0x00d2, 0x00d3, 0x00d4, 0x00d5, 0x00d6, 0x00d7, 0x00d8, 0x2518, 0x250c, 0x2588, 0x2584, 0x00a6, 0x00de, 0x2580, 0x00e0, 0x00e1, 0x00e2, 0x00e3, 0x00e4, 0x00e5, 0x00b5, 0x00e7, 0x00e8, 0x00e9, 0x00ea, 0x00eb, 0x00ec, 0x00ed, 0x00af, 0x00b4, 0x00ad, 0x00b1, 0x2017, 0x00be, 0x00b6, 0x00a7, 0x00f7, 0x00b8, 0x00b0, 0x00a8, 0x00b7, 0x00b9, 0x00b3, 0x00b2, 0x25a0, 0x00a0 }; /* Table for CP857.TXT */ static const hts_UCS4 table_cp857[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x00c7, 0x00fc, 0x00e9, 0x00e2, 0x00e4, 0x00e0, 0x00e5, 0x00e7, 0x00ea, 0x00eb, 0x00e8, 0x00ef, 0x00ee, 0x0131, 0x00c4, 0x00c5, 0x00c9, 0x00e6, 0x00c6, 0x00f4, 0x00f6, 0x00f2, 0x00fb, 0x00f9, 0x0130, 0x00d6, 0x00dc, 0x00f8, 0x00a3, 0x00d8, 0x015e, 0x015f, 0x00e1, 0x00ed, 0x00f3, 0x00fa, 0x00f1, 0x00d1, 0x011e, 0x011f, 0x00bf, 0x00ae, 0x00ac, 0x00bd, 0x00bc, 0x00a1, 0x00ab, 0x00bb, 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x00c1, 0x00c2, 0x00c0, 0x00a9, 0x2563, 0x2551, 0x2557, 0x255d, 0x00a2, 0x00a5, 0x2510, 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x00e3, 0x00c3, 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x00a4, 0x00ba, 0x00aa, 0x00ca, 0x00cb, 0x00c8, 0x00d5, 0x00cd, 0x00ce, 0x00cf, 0x2518, 0x250c, 0x2588, 0x2584, 0x00a6, 0x00cc, 0x2580, 0x00d3, 0x00df, 0x00d4, 0x00d2, 0x00f5, 0x00d5, 0x00b5, 0x00e7, 0x00d7, 0x00da, 0x00db, 0x00d9, 0x00ec, 0x00ff, 0x00af, 0x00b4, 0x00ad, 0x00b1, 0x00f2, 0x00be, 0x00b6, 0x00a7, 0x00f7, 0x00b8, 0x00b0, 0x00a8, 0x00b7, 0x00b9, 0x00b3, 0x00b2, 0x25a0, 0x00a0 }; /* Table for CP860.TXT */ static const hts_UCS4 table_cp860[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x00c7, 0x00fc, 0x00e9, 0x00e2, 0x00e3, 0x00e0, 0x00c1, 0x00e7, 0x00ea, 0x00ca, 0x00e8, 0x00cd, 0x00d4, 0x00ec, 0x00c3, 0x00c2, 0x00c9, 0x00c0, 0x00c8, 0x00f4, 0x00f5, 0x00f2, 0x00da, 0x00f9, 0x00cc, 0x00d5, 0x00dc, 0x00a2, 0x00a3, 0x00d9, 0x20a7, 0x00d3, 0x00e1, 0x00ed, 0x00f3, 0x00fa, 0x00f1, 0x00d1, 0x00aa, 0x00ba, 0x00bf, 0x00d2, 0x00ac, 0x00bd, 0x00bc, 0x00a1, 0x00ab, 0x00bb, 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x2561, 0x2562, 0x2556, 0x2555, 0x2563, 0x2551, 0x2557, 0x255d, 0x255c, 0x255b, 0x2510, 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x255e, 0x255f, 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x2567, 0x2568, 0x2564, 0x2565, 0x2559, 0x2558, 0x2552, 0x2553, 0x256b, 0x256a, 0x2518, 0x250c, 0x2588, 0x2584, 0x258c, 0x2590, 0x2580, 0x03b1, 0x00df, 0x0393, 0x03c0, 0x03a3, 0x03c3, 0x00b5, 0x03c4, 0x03a6, 0x0398, 0x03a9, 0x03b4, 0x221e, 0x03c6, 0x03b5, 0x2229, 0x2261, 0x00b1, 0x2265, 0x2264, 0x2320, 0x2321, 0x00f7, 0x2248, 0x00b0, 0x2219, 0x00b7, 0x221a, 0x207f, 0x00b2, 0x25a0, 0x00a0 }; /* Table for CP861.TXT */ static const hts_UCS4 table_cp861[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x00c7, 0x00fc, 0x00e9, 0x00e2, 0x00e4, 0x00e0, 0x00e5, 0x00e7, 0x00ea, 0x00eb, 0x00e8, 0x00d0, 0x00f0, 0x00de, 0x00c4, 0x00c5, 0x00c9, 0x00e6, 0x00c6, 0x00f4, 0x00f6, 0x00fe, 0x00fb, 0x00dd, 0x00fd, 0x00d6, 0x00dc, 0x00f8, 0x00a3, 0x00d8, 0x20a7, 0x0192, 0x00e1, 0x00ed, 0x00f3, 0x00fa, 0x00c1, 0x00cd, 0x00d3, 0x00da, 0x00bf, 0x2310, 0x00ac, 0x00bd, 0x00bc, 0x00a1, 0x00ab, 0x00bb, 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x2561, 0x2562, 0x2556, 0x2555, 0x2563, 0x2551, 0x2557, 0x255d, 0x255c, 0x255b, 0x2510, 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x255e, 0x255f, 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x2567, 0x2568, 0x2564, 0x2565, 0x2559, 0x2558, 0x2552, 0x2553, 0x256b, 0x256a, 0x2518, 0x250c, 0x2588, 0x2584, 0x258c, 0x2590, 0x2580, 0x03b1, 0x00df, 0x0393, 0x03c0, 0x03a3, 0x03c3, 0x00b5, 0x03c4, 0x03a6, 0x0398, 0x03a9, 0x03b4, 0x221e, 0x03c6, 0x03b5, 0x2229, 0x2261, 0x00b1, 0x2265, 0x2264, 0x2320, 0x2321, 0x00f7, 0x2248, 0x00b0, 0x2219, 0x00b7, 0x221a, 0x207f, 0x00b2, 0x25a0, 0x00a0 }; /* Table for CP862.TXT */ static const hts_UCS4 table_cp862[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x05d0, 0x05d1, 0x05d2, 0x05d3, 0x05d4, 0x05d5, 0x05d6, 0x05d7, 0x05d8, 0x05d9, 0x05da, 0x05db, 0x05dc, 0x05dd, 0x05de, 0x05df, 0x05e0, 0x05e1, 0x05e2, 0x05e3, 0x05e4, 0x05e5, 0x05e6, 0x05e7, 0x05e8, 0x05e9, 0x05ea, 0x00a2, 0x00a3, 0x00a5, 0x20a7, 0x0192, 0x00e1, 0x00ed, 0x00f3, 0x00fa, 0x00f1, 0x00d1, 0x00aa, 0x00ba, 0x00bf, 0x2310, 0x00ac, 0x00bd, 0x00bc, 0x00a1, 0x00ab, 0x00bb, 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x2561, 0x2562, 0x2556, 0x2555, 0x2563, 0x2551, 0x2557, 0x255d, 0x255c, 0x255b, 0x2510, 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x255e, 0x255f, 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x2567, 0x2568, 0x2564, 0x2565, 0x2559, 0x2558, 0x2552, 0x2553, 0x256b, 0x256a, 0x2518, 0x250c, 0x2588, 0x2584, 0x258c, 0x2590, 0x2580, 0x03b1, 0x00df, 0x0393, 0x03c0, 0x03a3, 0x03c3, 0x00b5, 0x03c4, 0x03a6, 0x0398, 0x03a9, 0x03b4, 0x221e, 0x03c6, 0x03b5, 0x2229, 0x2261, 0x00b1, 0x2265, 0x2264, 0x2320, 0x2321, 0x00f7, 0x2248, 0x00b0, 0x2219, 0x00b7, 0x221a, 0x207f, 0x00b2, 0x25a0, 0x00a0 }; /* Table for CP863.TXT */ static const hts_UCS4 table_cp863[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x00c7, 0x00fc, 0x00e9, 0x00e2, 0x00c2, 0x00e0, 0x00b6, 0x00e7, 0x00ea, 0x00eb, 0x00e8, 0x00ef, 0x00ee, 0x2017, 0x00c0, 0x00a7, 0x00c9, 0x00c8, 0x00ca, 0x00f4, 0x00cb, 0x00cf, 0x00fb, 0x00f9, 0x00a4, 0x00d4, 0x00dc, 0x00a2, 0x00a3, 0x00d9, 0x00db, 0x0192, 0x00a6, 0x00b4, 0x00f3, 0x00fa, 0x00a8, 0x00b8, 0x00b3, 0x00af, 0x00ce, 0x2310, 0x00ac, 0x00bd, 0x00bc, 0x00be, 0x00ab, 0x00bb, 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x2561, 0x2562, 0x2556, 0x2555, 0x2563, 0x2551, 0x2557, 0x255d, 0x255c, 0x255b, 0x2510, 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x255e, 0x255f, 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x2567, 0x2568, 0x2564, 0x2565, 0x2559, 0x2558, 0x2552, 0x2553, 0x256b, 0x256a, 0x2518, 0x250c, 0x2588, 0x2584, 0x258c, 0x2590, 0x2580, 0x03b1, 0x00df, 0x0393, 0x03c0, 0x03a3, 0x03c3, 0x00b5, 0x03c4, 0x03a6, 0x0398, 0x03a9, 0x03b4, 0x221e, 0x03c6, 0x03b5, 0x2229, 0x2261, 0x00b1, 0x2265, 0x2264, 0x2320, 0x2321, 0x00f7, 0x2248, 0x00b0, 0x2219, 0x00b7, 0x221a, 0x207f, 0x00b2, 0x25a0, 0x00a0 }; /* Table for CP864.TXT */ static const hts_UCS4 table_cp864[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x066a, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x00b0, 0x00b7, 0x2219, 0x221a, 0x2592, 0x2500, 0x2502, 0x253c, 0x2524, 0x252c, 0x251c, 0x2534, 0x2510, 0x250c, 0x2514, 0x2518, 0x03b2, 0x221e, 0x03c6, 0x00b1, 0x00bd, 0x00bc, 0x2248, 0x00ab, 0x00bb, 0xfef7, 0xfef8, 0x009b, 0x009c, 0xfefb, 0xfefc, 0x009f, 0x00a0, 0x00ad, 0xfe82, 0x00a3, 0x00a4, 0xfe84, 0x00a6, 0x00a7, 0xfe8e, 0xfe8f, 0xfe95, 0xfe99, 0x060c, 0xfe9d, 0xfea1, 0xfea5, 0x0660, 0x0661, 0x0662, 0x0663, 0x0664, 0x0665, 0x0666, 0x0667, 0x0668, 0x0669, 0xfed1, 0x061b, 0xfeb1, 0xfeb5, 0xfeb9, 0x061f, 0x00a2, 0xfe80, 0xfe81, 0xfe83, 0xfe85, 0xfeca, 0xfe8b, 0xfe8d, 0xfe91, 0xfe93, 0xfe97, 0xfe9b, 0xfe9f, 0xfea3, 0xfea7, 0xfea9, 0xfeab, 0xfead, 0xfeaf, 0xfeb3, 0xfeb7, 0xfebb, 0xfebf, 0xfec1, 0xfec5, 0xfecb, 0xfecf, 0x00a6, 0x00ac, 0x00f7, 0x00d7, 0xfec9, 0x0640, 0xfed3, 0xfed7, 0xfedb, 0xfedf, 0xfee3, 0xfee7, 0xfeeb, 0xfeed, 0xfeef, 0xfef3, 0xfebd, 0xfecc, 0xfece, 0xfecd, 0xfee1, 0xfe7d, 0x0651, 0xfee5, 0xfee9, 0xfeec, 0xfef0, 0xfef2, 0xfed0, 0xfed5, 0xfef5, 0xfef6, 0xfedd, 0xfed9, 0xfef1, 0x25a0, 0x00ff }; /* Table for CP865.TXT */ static const hts_UCS4 table_cp865[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x00c7, 0x00fc, 0x00e9, 0x00e2, 0x00e4, 0x00e0, 0x00e5, 0x00e7, 0x00ea, 0x00eb, 0x00e8, 0x00ef, 0x00ee, 0x00ec, 0x00c4, 0x00c5, 0x00c9, 0x00e6, 0x00c6, 0x00f4, 0x00f6, 0x00f2, 0x00fb, 0x00f9, 0x00ff, 0x00d6, 0x00dc, 0x00f8, 0x00a3, 0x00d8, 0x20a7, 0x0192, 0x00e1, 0x00ed, 0x00f3, 0x00fa, 0x00f1, 0x00d1, 0x00aa, 0x00ba, 0x00bf, 0x2310, 0x00ac, 0x00bd, 0x00bc, 0x00a1, 0x00ab, 0x00a4, 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x2561, 0x2562, 0x2556, 0x2555, 0x2563, 0x2551, 0x2557, 0x255d, 0x255c, 0x255b, 0x2510, 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x255e, 0x255f, 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x2567, 0x2568, 0x2564, 0x2565, 0x2559, 0x2558, 0x2552, 0x2553, 0x256b, 0x256a, 0x2518, 0x250c, 0x2588, 0x2584, 0x258c, 0x2590, 0x2580, 0x03b1, 0x00df, 0x0393, 0x03c0, 0x03a3, 0x03c3, 0x00b5, 0x03c4, 0x03a6, 0x0398, 0x03a9, 0x03b4, 0x221e, 0x03c6, 0x03b5, 0x2229, 0x2261, 0x00b1, 0x2265, 0x2264, 0x2320, 0x2321, 0x00f7, 0x2248, 0x00b0, 0x2219, 0x00b7, 0x221a, 0x207f, 0x00b2, 0x25a0, 0x00a0 }; /* Table for CP866.TXT */ static const hts_UCS4 table_cp866[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x0410, 0x0411, 0x0412, 0x0413, 0x0414, 0x0415, 0x0416, 0x0417, 0x0418, 0x0419, 0x041a, 0x041b, 0x041c, 0x041d, 0x041e, 0x041f, 0x0420, 0x0421, 0x0422, 0x0423, 0x0424, 0x0425, 0x0426, 0x0427, 0x0428, 0x0429, 0x042a, 0x042b, 0x042c, 0x042d, 0x042e, 0x042f, 0x0430, 0x0431, 0x0432, 0x0433, 0x0434, 0x0435, 0x0436, 0x0437, 0x0438, 0x0439, 0x043a, 0x043b, 0x043c, 0x043d, 0x043e, 0x043f, 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x2561, 0x2562, 0x2556, 0x2555, 0x2563, 0x2551, 0x2557, 0x255d, 0x255c, 0x255b, 0x2510, 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x255e, 0x255f, 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x2567, 0x2568, 0x2564, 0x2565, 0x2559, 0x2558, 0x2552, 0x2553, 0x256b, 0x256a, 0x2518, 0x250c, 0x2588, 0x2584, 0x258c, 0x2590, 0x2580, 0x0440, 0x0441, 0x0442, 0x0443, 0x0444, 0x0445, 0x0446, 0x0447, 0x0448, 0x0449, 0x044a, 0x044b, 0x044c, 0x044d, 0x044e, 0x044f, 0x0401, 0x0451, 0x0404, 0x0454, 0x0407, 0x0457, 0x040e, 0x045e, 0x00b0, 0x2219, 0x00b7, 0x221a, 0x2116, 0x00a4, 0x25a0, 0x00a0 }; /* Table for CP869.TXT */ static const hts_UCS4 table_cp869[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x0085, 0x0386, 0x0087, 0x00b7, 0x00ac, 0x00a6, 0x2018, 0x2019, 0x0388, 0x2015, 0x0389, 0x038a, 0x03aa, 0x038c, 0x0093, 0x0094, 0x038e, 0x03ab, 0x00a9, 0x038f, 0x00b2, 0x00b3, 0x03ac, 0x00a3, 0x03ad, 0x03ae, 0x03af, 0x03ca, 0x0390, 0x03cc, 0x03cd, 0x0391, 0x0392, 0x0393, 0x0394, 0x0395, 0x0396, 0x0397, 0x00bd, 0x0398, 0x0399, 0x00ab, 0x00bb, 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x039a, 0x039b, 0x039c, 0x039d, 0x2563, 0x2551, 0x2557, 0x255d, 0x039e, 0x039f, 0x2510, 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x03a0, 0x03a1, 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x03a3, 0x03a4, 0x03a5, 0x03a6, 0x03a7, 0x03a8, 0x03a9, 0x03b1, 0x03b2, 0x03b3, 0x2518, 0x250c, 0x2588, 0x2584, 0x03b4, 0x03b5, 0x2580, 0x03b6, 0x03b7, 0x03b8, 0x03b9, 0x03ba, 0x03bb, 0x03bc, 0x03bd, 0x03be, 0x03bf, 0x03c0, 0x03c1, 0x03c3, 0x03c2, 0x03c4, 0x0384, 0x00ad, 0x00b1, 0x03c5, 0x03c6, 0x03c7, 0x00a7, 0x03c8, 0x0385, 0x00b0, 0x00a8, 0x03c9, 0x03cb, 0x03b0, 0x03ce, 0x25a0, 0x00a0 }; /* Table for CP874.TXT */ static const hts_UCS4 table_cp874[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x20ac, 0x0081, 0x0082, 0x0083, 0x0084, 0x2026, 0x0086, 0x0087, 0x0088, 0x0089, 0x008a, 0x008b, 0x008c, 0x008d, 0x008e, 0x008f, 0x0090, 0x2018, 0x2019, 0x201c, 0x201d, 0x2022, 0x2013, 0x2014, 0x0098, 0x0099, 0x009a, 0x009b, 0x009c, 0x009d, 0x009e, 0x009f, 0x00a0, 0x0e01, 0x0e02, 0x0e03, 0x0e04, 0x0e05, 0x0e06, 0x0e07, 0x0e08, 0x0e09, 0x0e0a, 0x0e0b, 0x0e0c, 0x0e0d, 0x0e0e, 0x0e0f, 0x0e10, 0x0e11, 0x0e12, 0x0e13, 0x0e14, 0x0e15, 0x0e16, 0x0e17, 0x0e18, 0x0e19, 0x0e1a, 0x0e1b, 0x0e1c, 0x0e1d, 0x0e1e, 0x0e1f, 0x0e20, 0x0e21, 0x0e22, 0x0e23, 0x0e24, 0x0e25, 0x0e26, 0x0e27, 0x0e28, 0x0e29, 0x0e2a, 0x0e2b, 0x0e2c, 0x0e2d, 0x0e2e, 0x0e2f, 0x0e30, 0x0e31, 0x0e32, 0x0e33, 0x0e34, 0x0e35, 0x0e36, 0x0e37, 0x0e38, 0x0e39, 0x0e3a, 0x00db, 0x00dc, 0x00dd, 0x00de, 0x0e3f, 0x0e40, 0x0e41, 0x0e42, 0x0e43, 0x0e44, 0x0e45, 0x0e46, 0x0e47, 0x0e48, 0x0e49, 0x0e4a, 0x0e4b, 0x0e4c, 0x0e4d, 0x0e4e, 0x0e4f, 0x0e50, 0x0e51, 0x0e52, 0x0e53, 0x0e54, 0x0e55, 0x0e56, 0x0e57, 0x0e58, 0x0e59, 0x0e5a, 0x0e5b, 0x00fc, 0x00fd, 0x00fe, 0x00ff }; /* Table for CP875.TXT */ static const hts_UCS4 table_cp875[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x009c, 0x0009, 0x0086, 0x007f, 0x0097, 0x008d, 0x008e, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x009d, 0x0085, 0x0008, 0x0087, 0x0018, 0x0019, 0x0092, 0x008f, 0x001c, 0x001d, 0x001e, 0x001f, 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x000a, 0x0017, 0x001b, 0x0088, 0x0089, 0x008a, 0x008b, 0x008c, 0x0005, 0x0006, 0x0007, 0x0090, 0x0091, 0x0016, 0x0093, 0x0094, 0x0095, 0x0096, 0x0004, 0x0098, 0x0099, 0x009a, 0x009b, 0x0014, 0x0015, 0x009e, 0x001a, 0x0020, 0x0391, 0x0392, 0x0393, 0x0394, 0x0395, 0x0396, 0x0397, 0x0398, 0x0399, 0x005b, 0x002e, 0x003c, 0x0028, 0x002b, 0x0021, 0x0026, 0x039a, 0x039b, 0x039c, 0x039d, 0x039e, 0x039f, 0x03a0, 0x03a1, 0x03a3, 0x005d, 0x0024, 0x002a, 0x0029, 0x003b, 0x005e, 0x002d, 0x002f, 0x03a4, 0x03a5, 0x03a6, 0x03a7, 0x03a8, 0x03a9, 0x03aa, 0x03ab, 0x007c, 0x002c, 0x0025, 0x005f, 0x003e, 0x003f, 0x00a8, 0x0386, 0x0388, 0x0389, 0x00a0, 0x038a, 0x038c, 0x038e, 0x038f, 0x0060, 0x003a, 0x0023, 0x0040, 0x0027, 0x003d, 0x0022, 0x0385, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x03b1, 0x03b2, 0x03b3, 0x03b4, 0x03b5, 0x03b6, 0x00b0, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x03b7, 0x03b8, 0x03b9, 0x03ba, 0x03bb, 0x03bc, 0x00b4, 0x007e, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x03bd, 0x03be, 0x03bf, 0x03c0, 0x03c1, 0x03c3, 0x00a3, 0x03ac, 0x03ad, 0x03ae, 0x03ca, 0x03af, 0x03cc, 0x03cd, 0x03cb, 0x03ce, 0x03c2, 0x03c4, 0x03c5, 0x03c6, 0x03c7, 0x03c8, 0x007b, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x00ad, 0x03c9, 0x0390, 0x03b0, 0x2018, 0x2015, 0x007d, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x00b1, 0x00bd, 0x001a, 0x0387, 0x2019, 0x00a6, 0x005c, 0x001a, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x00b2, 0x00a7, 0x001a, 0x001a, 0x00ab, 0x00ac, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x00b3, 0x00a9, 0x001a, 0x001a, 0x00bb, 0x009f }; /* Table for KOI8-R.TXT */ static const hts_UCS4 table_koi8_r[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x2500, 0x2502, 0x250c, 0x2510, 0x2514, 0x2518, 0x251c, 0x2524, 0x252c, 0x2534, 0x253c, 0x2580, 0x2584, 0x2588, 0x258c, 0x2590, 0x2591, 0x2592, 0x2593, 0x2320, 0x25a0, 0x2219, 0x221a, 0x2248, 0x2264, 0x2265, 0x00a0, 0x2321, 0x00b0, 0x00b2, 0x00b7, 0x00f7, 0x2550, 0x2551, 0x2552, 0x0451, 0x2553, 0x2554, 0x2555, 0x2556, 0x2557, 0x2558, 0x2559, 0x255a, 0x255b, 0x255c, 0x255d, 0x255e, 0x255f, 0x2560, 0x2561, 0x0401, 0x2562, 0x2563, 0x2564, 0x2565, 0x2566, 0x2567, 0x2568, 0x2569, 0x256a, 0x256b, 0x256c, 0x00a9, 0x044e, 0x0430, 0x0431, 0x0446, 0x0434, 0x0435, 0x0444, 0x0433, 0x0445, 0x0438, 0x0439, 0x043a, 0x043b, 0x043c, 0x043d, 0x043e, 0x043f, 0x044f, 0x0440, 0x0441, 0x0442, 0x0443, 0x0436, 0x0432, 0x044c, 0x044b, 0x0437, 0x0448, 0x044d, 0x0449, 0x0447, 0x044a, 0x042e, 0x0410, 0x0411, 0x0426, 0x0414, 0x0415, 0x0424, 0x0413, 0x0425, 0x0418, 0x0419, 0x041a, 0x041b, 0x041c, 0x041d, 0x041e, 0x041f, 0x042f, 0x0420, 0x0421, 0x0422, 0x0423, 0x0416, 0x0412, 0x042c, 0x042b, 0x0417, 0x0428, 0x042d, 0x0429, 0x0427, 0x042a }; /* Table for KOI8-U.TXT */ static const hts_UCS4 table_koi8_u[256] = { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f, 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057, 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f, 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067, 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f, 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f, 0x2500, 0x2502, 0x250c, 0x2510, 0x2514, 0x2518, 0x251c, 0x2524, 0x252c, 0x2534, 0x253c, 0x2580, 0x2584, 0x2588, 0x258c, 0x2590, 0x2591, 0x2592, 0x2593, 0x2320, 0x25a0, 0x2219, 0x221a, 0x2248, 0x2264, 0x2265, 0x00a0, 0x2321, 0x00b0, 0x00b2, 0x00b7, 0x00f7, 0x2550, 0x2551, 0x2552, 0x0451, 0x0454, 0x2554, 0x0456, 0x0457, 0x2557, 0x2558, 0x2559, 0x255a, 0x255b, 0x0491, 0x255d, 0x255e, 0x255f, 0x2560, 0x2561, 0x0401, 0x0404, 0x2563, 0x0406, 0x0407, 0x2566, 0x2567, 0x2568, 0x2569, 0x256a, 0x0490, 0x256c, 0x00a9, 0x044e, 0x0430, 0x0431, 0x0446, 0x0434, 0x0435, 0x0444, 0x0433, 0x0445, 0x0438, 0x0439, 0x043a, 0x043b, 0x043c, 0x043d, 0x043e, 0x043f, 0x044f, 0x0440, 0x0441, 0x0442, 0x0443, 0x0436, 0x0432, 0x044c, 0x044b, 0x0437, 0x0448, 0x044d, 0x0449, 0x0447, 0x044a, 0x042e, 0x0410, 0x0411, 0x0426, 0x0414, 0x0415, 0x0424, 0x0413, 0x0425, 0x0418, 0x0419, 0x041a, 0x041b, 0x041c, 0x041d, 0x041e, 0x041f, 0x042f, 0x0420, 0x0421, 0x0422, 0x0423, 0x0416, 0x0412, 0x042c, 0x042b, 0x0417, 0x0428, 0x042d, 0x0429, 0x0427, 0x042a }; static const struct { const char *name; const hts_UCS4 *table; } table_mappings[] = { { "iso885910", table_iso_8859_10 }, { "iso885911", table_iso_8859_11 }, { "iso885913", table_iso_8859_13 }, { "iso885914", table_iso_8859_14 }, { "iso885915", table_iso_8859_15 }, { "iso885916", table_iso_8859_16 }, { "iso88591", table_iso_8859_1 }, { "iso88592", table_iso_8859_2 }, { "iso88593", table_iso_8859_3 }, { "iso88594", table_iso_8859_4 }, { "iso88595", table_iso_8859_5 }, { "iso88596", table_iso_8859_6 }, { "iso88597", table_iso_8859_7 }, { "iso88598", table_iso_8859_8 }, { "iso88599", table_iso_8859_9 }, { "cp037", table_cp037 }, { "cp1006", table_cp1006 }, { "cp1026", table_cp1026 }, { "cp1250", table_cp1250 }, { "cp1251", table_cp1251 }, { "cp1252", table_cp1252 }, { "cp1253", table_cp1253 }, { "cp1254", table_cp1254 }, { "cp1255", table_cp1255 }, { "cp1256", table_cp1256 }, { "cp1257", table_cp1257 }, { "cp1258", table_cp1258 }, { "cp424", table_cp424 }, { "cp437", table_cp437 }, { "cp500", table_cp500 }, { "cp737", table_cp737 }, { "cp775", table_cp775 }, { "cp850", table_cp850 }, { "cp852", table_cp852 }, { "cp855", table_cp855 }, { "cp856", table_cp856 }, { "cp857", table_cp857 }, { "cp860", table_cp860 }, { "cp861", table_cp861 }, { "cp862", table_cp862 }, { "cp863", table_cp863 }, { "cp864", table_cp864 }, { "cp865", table_cp865 }, { "cp866", table_cp866 }, { "cp869", table_cp869 }, { "cp874", table_cp874 }, { "cp875", table_cp875 }, { "koi8r", table_koi8_r }, { "koi8u", table_koi8_u }, { NULL, NULL } }; httrack-3.49.5/src/htsbasiccharsets.sh0000755000175000017500000000366214336470674014705 00000000000000#!/bin/bash # # Change this to download files if false; then echo "mget ftp://ftp.unicode.org/Public/MAPPINGS/ISO8859/8859-*.TXT" | lftp echo "mget ftp://ftp.unicode.org/Public/MAPPINGS/VENDORS/MICSFT/PC/CP*.TXT" | lftp echo "mget ftp://ftp.unicode.org/Public/MAPPINGS/VENDORS/MICSFT/WINDOWS/CP*.TXT" | lftp echo "mget ftp://ftp.unicode.org/Public/MAPPINGS/VENDORS/MICSFT/EBCDIC/CP*.TXT" | lftp echo "mget ftp://ftp.unicode.org/Public/MAPPINGS/VENDORS/MISC/CP*.TXT" | lftp echo "mget ftp://ftp.unicode.org/Public/MAPPINGS/VENDORS/MISC/KOI8*.TXT" | lftp rm -f CP932.TXT CP936.TXT CP949.TXT CP950.TXT fi # Produce code printf "/** GENERATED FILE ($0), DO NOT EDIT **/\n\n" for i in *.TXT ; do echo "processing $i" >&2 grep -vE "^(#|$)" $i | grep -E "^0x" | sed -e 's/[[:space:]]/ /g' | cut -f1,2 -d' ' | \ ( unset arr while read LINE ; do from=$[$(echo $LINE | cut -f1 -d' ')] if ! test -n "$from"; then echo "error with $i" >&2 exit 1 elif test $from -ge 256; then echo "out-of-range ($LINE) with $i" >&2 exit 1 fi to=$(echo $LINE | cut -f2 -d' ') arr[$from]=$to done name=$(echo $i | tr 'A-Z' 'a-z' | tr '-' '_' | sed -e 's/\.txt//' -e 's/8859/iso_8859/') printf "/* Table for $i */\nstatic const hts_UCS4 table_${name}[256] = {\n " i=0 while test "$i" -lt 256; do if test "$i" -gt 0; then printf ", " if test $[${i}%8] -eq 0; then printf "\n " fi fi value=${arr[$i]:-0} printf "0x%04x" $value i=$[${i}+1] done printf " };\n\n" ) echo "processed $i" >&2 done # Indexes printf "static const struct {\n const char *name;\n const hts_UCS4 *table;\n} table_mappings[] = {\n" for i in *.TXT ; do name=$(echo $i | tr 'A-Z' 'a-z' | tr '-' '_' | sed -e 's/\.txt//' -e 's/8859/iso_8859/') printf " { \"$(echo $name | tr -d '_')\", table_${name} },\n" done printf " { NULL, NULL }\n};\n" httrack-3.49.5/src/htsentities.sh0000755000175000017500000000370114336470674013705 00000000000000#!/bin/bash # src=html40.txt url=http://www.w3.org/TR/1998/REC-html40-19980424/html40.txt dest=htsentities.h ( cat <) for each entity. We should in theory check using strncmp() that we actually have the correct entity, but this is actually statistically not needed. We may want to do better, but we expect the hash function to be uniform, and let the compiler be smart enough to optimize the switch (for example by checking in log2() intervals) This code has been generated using the evil $0 script. */ static int decode_entity(const unsigned int hash, const size_t len) { switch(hash) { EOF ( if test -f ${src}; then cat ${src} else GET "${url}" fi ) \ | grep -E '^$//' \ -e 's/\([^ ]*\) CDATA "&#\([^\"]*\);" -- \(.*\)/\1 \2 \3/'\ | ( \ read A while test -n "$A"; do ent="${A%% *}" code=$(echo "$A"|cut -f2 -d' ') # compute hash hash=0 i=0 a=1664525 c=1013904223 m="$[1 << 32]" while test "$i" -lt ${#ent}; do d="$(echo -n "${ent:${i}:1}"|hexdump -v -e '/1 "%d"')" hash="$[((${hash}*${a})%(${m})+${d}+${c})%(${m})]" i=$[${i}+1] done echo -e " /* $A */" echo -e " case ${hash}u:" echo -e " if (len == ${#ent} /* && strncmp(ent, \"${ent}\") == 0 */) {" echo -e " return ${code};" echo -e " }" echo -e " break;" # next read A done ) cat < ${dest} httrack-3.49.5/src/htsentities.h0000644000175000017500000012176314336470674013530 00000000000000/* -- htsentities.h -- FILE GENERATED BY ./htsentities.sh, DO NOT MODIFY We compute the LCG hash (see ) for each entity. We should in theory check using strncmp() that we actually have the correct entity, but this is actually statistically not needed. We may want to do better, but we expect the hash function to be uniform, and let the compiler be smart enough to optimize the switch (for example by checking in log2() intervals) This code has been generated using the evil ./htsentities.sh script. */ static int decode_entity(const unsigned int hash, const size_t len) { switch(hash) { /* nbsp 160 no-break space = non-breaking space, */ case 3948425267u: if (len == 4 /* && strncmp(ent, "nbsp") == 0 */) { return 160; } break; /* iexcl 161 inverted exclamation mark, U+00A1 ISOnum */ case 1499591408u: if (len == 5 /* && strncmp(ent, "iexcl") == 0 */) { return 161; } break; /* cent 162 cent sign, U+00A2 ISOnum */ case 2824786826u: if (len == 4 /* && strncmp(ent, "cent") == 0 */) { return 162; } break; /* pound 163 pound sign, U+00A3 ISOnum */ case 805305925u: if (len == 5 /* && strncmp(ent, "pound") == 0 */) { return 163; } break; /* curren 164 currency sign, U+00A4 ISOnum */ case 1584829677u: if (len == 6 /* && strncmp(ent, "curren") == 0 */) { return 164; } break; /* yen 165 yen sign = yuan sign, U+00A5 ISOnum */ case 3581281881u: if (len == 3 /* && strncmp(ent, "yen") == 0 */) { return 165; } break; /* brvbar 166 broken bar = broken vertical bar, */ case 3768851825u: if (len == 6 /* && strncmp(ent, "brvbar") == 0 */) { return 166; } break; /* sect 167 section sign, U+00A7 ISOnum */ case 2614630987u: if (len == 4 /* && strncmp(ent, "sect") == 0 */) { return 167; } break; /* uml 168 diaeresis = spacing diaeresis, */ case 2036319259u: if (len == 3 /* && strncmp(ent, "uml") == 0 */) { return 168; } break; /* copy 169 copyright sign, U+00A9 ISOnum */ case 2428845635u: if (len == 4 /* && strncmp(ent, "copy") == 0 */) { return 169; } break; /* ordf 170 feminine ordinal indicator, U+00AA ISOnum */ case 212470411u: if (len == 4 /* && strncmp(ent, "ordf") == 0 */) { return 170; } break; /* laquo 171 left-pointing double angle quotation mark */ case 401220509u: if (len == 5 /* && strncmp(ent, "laquo") == 0 */) { return 171; } break; /* not 172 not sign, U+00AC ISOnum */ case 3607627678u: if (len == 3 /* && strncmp(ent, "not") == 0 */) { return 172; } break; /* shy 173 soft hyphen = discretionary hyphen, */ case 1248857237u: if (len == 3 /* && strncmp(ent, "shy") == 0 */) { return 173; } break; /* reg 174 registered sign = registered trade mark sign, */ case 854293939u: if (len == 3 /* && strncmp(ent, "reg") == 0 */) { return 174; } break; /* macr 175 macron = spacing macron = overline */ case 591423527u: if (len == 4 /* && strncmp(ent, "macr") == 0 */) { return 175; } break; /* deg 176 degree sign, U+00B0 ISOnum */ case 3990252661u: if (len == 3 /* && strncmp(ent, "deg") == 0 */) { return 176; } break; /* plusmn 177 plus-minus sign = plus-or-minus sign, */ case 3641444957u: if (len == 6 /* && strncmp(ent, "plusmn") == 0 */) { return 177; } break; /* sup2 178 superscript two = superscript digit two */ case 279450434u: if (len == 4 /* && strncmp(ent, "sup2") == 0 */) { return 178; } break; /* sup3 179 superscript three = superscript digit three */ case 279450435u: if (len == 4 /* && strncmp(ent, "sup3") == 0 */) { return 179; } break; /* acute 180 acute accent = spacing acute, */ case 1795641881u: if (len == 5 /* && strncmp(ent, "acute") == 0 */) { return 180; } break; /* micro 181 micro sign, U+00B5 ISOnum */ case 1447763057u: if (len == 5 /* && strncmp(ent, "micro") == 0 */) { return 181; } break; /* para 182 pilcrow sign = paragraph sign, */ case 848855704u: if (len == 4 /* && strncmp(ent, "para") == 0 */) { return 182; } break; /* middot 183 middle dot = Georgian comma */ case 3167839463u: if (len == 6 /* && strncmp(ent, "middot") == 0 */) { return 183; } break; /* cedil 184 cedilla = spacing cedilla, U+00B8 ISOdia */ case 1354214564u: if (len == 5 /* && strncmp(ent, "cedil") == 0 */) { return 184; } break; /* sup1 185 superscript one = superscript digit one, */ case 279450433u: if (len == 4 /* && strncmp(ent, "sup1") == 0 */) { return 185; } break; /* ordm 186 masculine ordinal indicator, */ case 212470418u: if (len == 4 /* && strncmp(ent, "ordm") == 0 */) { return 186; } break; /* raquo 187 right-pointing double angle quotation mark */ case 1355124995u: if (len == 5 /* && strncmp(ent, "raquo") == 0 */) { return 187; } break; /* frac14 188 vulgar fraction one quarter */ case 1016175271u: if (len == 6 /* && strncmp(ent, "frac14") == 0 */) { return 188; } break; /* frac12 189 vulgar fraction one half */ case 1016175269u: if (len == 6 /* && strncmp(ent, "frac12") == 0 */) { return 189; } break; /* frac34 190 vulgar fraction three quarters */ case 1019504321u: if (len == 6 /* && strncmp(ent, "frac34") == 0 */) { return 190; } break; /* iquest 191 inverted question mark */ case 430057661u: if (len == 6 /* && strncmp(ent, "iquest") == 0 */) { return 191; } break; /* Agrave 192 latin capital letter A with grave */ case 2815520320u: if (len == 6 /* && strncmp(ent, "Agrave") == 0 */) { return 192; } break; /* Aacute 193 latin capital letter A with acute, */ case 4192391993u: if (len == 6 /* && strncmp(ent, "Aacute") == 0 */) { return 193; } break; /* Acirc 194 latin capital letter A with circumflex, */ case 619920369u: if (len == 5 /* && strncmp(ent, "Acirc") == 0 */) { return 194; } break; /* Atilde 195 latin capital letter A with tilde, */ case 4145258425u: if (len == 6 /* && strncmp(ent, "Atilde") == 0 */) { return 195; } break; /* Auml 196 latin capital letter A with diaeresis, */ case 3558330427u: if (len == 4 /* && strncmp(ent, "Auml") == 0 */) { return 196; } break; /* Aring 197 latin capital letter A with ring above */ case 1775583868u: if (len == 5 /* && strncmp(ent, "Aring") == 0 */) { return 197; } break; /* AElig 198 latin capital letter AE */ case 3743972869u: if (len == 5 /* && strncmp(ent, "AElig") == 0 */) { return 198; } break; /* Ccedil 199 latin capital letter C with cedilla, */ case 885931646u: if (len == 6 /* && strncmp(ent, "Ccedil") == 0 */) { return 199; } break; /* Egrave 200 latin capital letter E with grave, */ case 1380421556u: if (len == 6 /* && strncmp(ent, "Egrave") == 0 */) { return 200; } break; /* Eacute 201 latin capital letter E with acute, */ case 2757293229u: if (len == 6 /* && strncmp(ent, "Eacute") == 0 */) { return 201; } break; /* Ecirc 202 latin capital letter E with circumflex, */ case 1255856693u: if (len == 5 /* && strncmp(ent, "Ecirc") == 0 */) { return 202; } break; /* Euml 203 latin capital letter E with diaeresis, */ case 2436627087u: if (len == 4 /* && strncmp(ent, "Euml") == 0 */) { return 203; } break; /* Igrave 204 latin capital letter I with grave, */ case 4240290088u: if (len == 6 /* && strncmp(ent, "Igrave") == 0 */) { return 204; } break; /* Iacute 205 latin capital letter I with acute, */ case 1322194465u: if (len == 6 /* && strncmp(ent, "Iacute") == 0 */) { return 205; } break; /* Icirc 206 latin capital letter I with circumflex, */ case 1891793017u: if (len == 5 /* && strncmp(ent, "Icirc") == 0 */) { return 206; } break; /* Iuml 207 latin capital letter I with diaeresis, */ case 1314923747u: if (len == 4 /* && strncmp(ent, "Iuml") == 0 */) { return 207; } break; /* ETH 208 latin capital letter ETH, U+00D0 ISOlat1 */ case 475229442u: if (len == 3 /* && strncmp(ent, "ETH") == 0 */) { return 208; } break; /* Ntilde 209 latin capital letter N with tilde, */ case 2702412914u: if (len == 6 /* && strncmp(ent, "Ntilde") == 0 */) { return 209; } break; /* Ograve 210 latin capital letter O with grave, */ case 4235125590u: if (len == 6 /* && strncmp(ent, "Ograve") == 0 */) { return 210; } break; /* Oacute 211 latin capital letter O with acute, */ case 1317029967u: if (len == 6 /* && strncmp(ent, "Oacute") == 0 */) { return 211; } break; /* Ocirc 212 latin capital letter O with circumflex, */ case 2845697503u: if (len == 5 /* && strncmp(ent, "Ocirc") == 0 */) { return 212; } break; /* Otilde 213 latin capital letter O with tilde, */ case 1269896399u: if (len == 6 /* && strncmp(ent, "Otilde") == 0 */) { return 213; } break; /* Ouml 214 latin capital letter O with diaeresis, */ case 1779852385u: if (len == 4 /* && strncmp(ent, "Ouml") == 0 */) { return 214; } break; /* times 215 multiplication sign, U+00D7 ISOnum */ case 2139742557u: if (len == 5 /* && strncmp(ent, "times") == 0 */) { return 215; } break; /* Oslash 216 latin capital letter O with stroke */ case 1378045056u: if (len == 6 /* && strncmp(ent, "Oslash") == 0 */) { return 216; } break; /* Ugrave 217 latin capital letter U with grave, */ case 4229961092u: if (len == 6 /* && strncmp(ent, "Ugrave") == 0 */) { return 217; } break; /* Uacute 218 latin capital letter U with acute, */ case 1311865469u: if (len == 6 /* && strncmp(ent, "Uacute") == 0 */) { return 218; } break; /* Ucirc 219 latin capital letter U with circumflex, */ case 3799601989u: if (len == 5 /* && strncmp(ent, "Ucirc") == 0 */) { return 219; } break; /* Uuml 220 latin capital letter U with diaeresis, */ case 2244781023u: if (len == 4 /* && strncmp(ent, "Uuml") == 0 */) { return 220; } break; /* Yacute 221 latin capital letter Y with acute, */ case 4171734001u: if (len == 6 /* && strncmp(ent, "Yacute") == 0 */) { return 221; } break; /* THORN 222 latin capital letter THORN, */ case 4251263774u: if (len == 5 /* && strncmp(ent, "THORN") == 0 */) { return 222; } break; /* szlig 223 latin small letter sharp s = ess-zed, */ case 51833136u: if (len == 5 /* && strncmp(ent, "szlig") == 0 */) { return 223; } break; /* agrave 224 latin small letter a with grave */ case 4219632096u: if (len == 6 /* && strncmp(ent, "agrave") == 0 */) { return 224; } break; /* aacute 225 latin small letter a with acute, */ case 1301536473u: if (len == 6 /* && strncmp(ent, "aacute") == 0 */) { return 225; } break; /* acirc 226 latin small letter a with circumflex, */ case 1412443665u: if (len == 5 /* && strncmp(ent, "acirc") == 0 */) { return 226; } break; /* atilde 227 latin small letter a with tilde, */ case 1254402905u: if (len == 6 /* && strncmp(ent, "atilde") == 0 */) { return 227; } break; /* auml 228 latin small letter a with diaeresis, */ case 3174638299u: if (len == 4 /* && strncmp(ent, "auml") == 0 */) { return 228; } break; /* aring 229 latin small letter a with ring above */ case 2568107164u: if (len == 5 /* && strncmp(ent, "aring") == 0 */) { return 229; } break; /* aelig 230 latin small letter ae */ case 4152804037u: if (len == 5 /* && strncmp(ent, "aelig") == 0 */) { return 230; } break; /* ccedil 231 latin small letter c with cedilla, */ case 2290043422u: if (len == 6 /* && strncmp(ent, "ccedil") == 0 */) { return 231; } break; /* egrave 232 latin small letter e with grave, */ case 2784533332u: if (len == 6 /* && strncmp(ent, "egrave") == 0 */) { return 232; } break; /* eacute 233 latin small letter e with acute, */ case 4161405005u: if (len == 6 /* && strncmp(ent, "eacute") == 0 */) { return 233; } break; /* ecirc 234 latin small letter e with circumflex, */ case 2048379989u: if (len == 5 /* && strncmp(ent, "ecirc") == 0 */) { return 234; } break; /* euml 235 latin small letter e with diaeresis, */ case 2052934959u: if (len == 4 /* && strncmp(ent, "euml") == 0 */) { return 235; } break; /* igrave 236 latin small letter i with grave, */ case 1349434568u: if (len == 6 /* && strncmp(ent, "igrave") == 0 */) { return 236; } break; /* iacute 237 latin small letter i with acute, */ case 2726306241u: if (len == 6 /* && strncmp(ent, "iacute") == 0 */) { return 237; } break; /* icirc 238 latin small letter i with circumflex, */ case 2684316313u: if (len == 5 /* && strncmp(ent, "icirc") == 0 */) { return 238; } break; /* iuml 239 latin small letter i with diaeresis, */ case 931231619u: if (len == 4 /* && strncmp(ent, "iuml") == 0 */) { return 239; } break; /* eth 240 latin small letter eth, U+00F0 ISOlat1 */ case 109822946u: if (len == 3 /* && strncmp(ent, "eth") == 0 */) { return 240; } break; /* ntilde 241 latin small letter n with tilde, */ case 4106524690u: if (len == 6 /* && strncmp(ent, "ntilde") == 0 */) { return 241; } break; /* ograve 242 latin small letter o with grave, */ case 1344270070u: if (len == 6 /* && strncmp(ent, "ograve") == 0 */) { return 242; } break; /* oacute 243 latin small letter o with acute, */ case 2721141743u: if (len == 6 /* && strncmp(ent, "oacute") == 0 */) { return 243; } break; /* ocirc 244 latin small letter o with circumflex, */ case 3638220799u: if (len == 5 /* && strncmp(ent, "ocirc") == 0 */) { return 244; } break; /* otilde 245 latin small letter o with tilde, */ case 2674008175u: if (len == 6 /* && strncmp(ent, "otilde") == 0 */) { return 245; } break; /* ouml 246 latin small letter o with diaeresis, */ case 1396160257u: if (len == 4 /* && strncmp(ent, "ouml") == 0 */) { return 246; } break; /* divide 247 division sign, U+00F7 ISOnum */ case 2204943563u: if (len == 6 /* && strncmp(ent, "divide") == 0 */) { return 247; } break; /* oslash 248 latin small letter o with stroke, */ case 2782156832u: if (len == 6 /* && strncmp(ent, "oslash") == 0 */) { return 248; } break; /* ugrave 249 latin small letter u with grave, */ case 1339105572u: if (len == 6 /* && strncmp(ent, "ugrave") == 0 */) { return 249; } break; /* uacute 250 latin small letter u with acute, */ case 2715977245u: if (len == 6 /* && strncmp(ent, "uacute") == 0 */) { return 250; } break; /* ucirc 251 latin small letter u with circumflex, */ case 297157989u: if (len == 5 /* && strncmp(ent, "ucirc") == 0 */) { return 251; } break; /* uuml 252 latin small letter u with diaeresis, */ case 1861088895u: if (len == 4 /* && strncmp(ent, "uuml") == 0 */) { return 252; } break; /* yacute 253 latin small letter y with acute, */ case 1280878481u: if (len == 6 /* && strncmp(ent, "yacute") == 0 */) { return 253; } break; /* thorn 254 latin small letter thorn with, */ case 4294688446u: if (len == 5 /* && strncmp(ent, "thorn") == 0 */) { return 254; } break; /* yuml 255 latin small letter y with diaeresis, */ case 739385555u: if (len == 4 /* && strncmp(ent, "yuml") == 0 */) { return 255; } break; /* fnof 402 latin small f with hook = function */ case 2270075705u: if (len == 4 /* && strncmp(ent, "fnof") == 0 */) { return 402; } break; /* Alpha 913 greek capital letter alpha, U+0391 */ case 4027656009u: if (len == 5 /* && strncmp(ent, "Alpha") == 0 */) { return 913; } break; /* Beta 914 greek capital letter beta, U+0392 */ case 277666448u: if (len == 4 /* && strncmp(ent, "Beta") == 0 */) { return 914; } break; /* Gamma 915 greek capital letter gamma, */ case 1537149070u: if (len == 5 /* && strncmp(ent, "Gamma") == 0 */) { return 915; } break; /* Delta 916 greek capital letter delta, */ case 3855542753u: if (len == 5 /* && strncmp(ent, "Delta") == 0 */) { return 916; } break; /* Epsilon 917 greek capital letter epsilon, U+0395 */ case 2449300823u: if (len == 7 /* && strncmp(ent, "Epsilon") == 0 */) { return 917; } break; /* Zeta 918 greek capital letter zeta, U+0396 */ case 2137381000u: if (len == 4 /* && strncmp(ent, "Zeta") == 0 */) { return 918; } break; /* Eta 919 greek capital letter eta, U+0397 */ case 528494267u: if (len == 3 /* && strncmp(ent, "Eta") == 0 */) { return 919; } break; /* Theta 920 greek capital letter theta, */ case 3904764433u: if (len == 5 /* && strncmp(ent, "Theta") == 0 */) { return 920; } break; /* Iota 921 greek capital letter iota, U+0399 */ case 3284124477u: if (len == 4 /* && strncmp(ent, "Iota") == 0 */) { return 921; } break; /* Kappa 922 greek capital letter kappa, U+039A */ case 3346788084u: if (len == 5 /* && strncmp(ent, "Kappa") == 0 */) { return 922; } break; /* Lambda 923 greek capital letter lambda, */ case 1824315307u: if (len == 6 /* && strncmp(ent, "Lambda") == 0 */) { return 923; } break; /* Mu 924 greek capital letter mu, U+039C */ case 1324604304u: if (len == 2 /* && strncmp(ent, "Mu") == 0 */) { return 924; } break; /* Nu 925 greek capital letter nu, U+039D */ case 1326268829u: if (len == 2 /* && strncmp(ent, "Nu") == 0 */) { return 925; } break; /* Xi 926 greek capital letter xi, U+039E ISOgrk3 */ case 1342914067u: if (len == 2 /* && strncmp(ent, "Xi") == 0 */) { return 926; } break; /* Omicron 927 greek capital letter omicron, U+039F */ case 488730696u: if (len == 7 /* && strncmp(ent, "Omicron") == 0 */) { return 927; } break; /* Pi 928 greek capital letter pi, U+03A0 ISOgrk3 */ case 1329597867u: if (len == 2 /* && strncmp(ent, "Pi") == 0 */) { return 928; } break; /* Rho 929 greek capital letter rho, U+03A1 */ case 1277958850u: if (len == 3 /* && strncmp(ent, "Rho") == 0 */) { return 929; } break; /* Sigma 931 greek capital letter sigma, */ case 3159100428u: if (len == 5 /* && strncmp(ent, "Sigma") == 0 */) { return 931; } break; /* Tau 932 greek capital letter tau, U+03A4 */ case 2045446591u: if (len == 3 /* && strncmp(ent, "Tau") == 0 */) { return 932; } break; /* Upsilon 933 greek capital letter upsilon, */ case 2291992807u: if (len == 7 /* && strncmp(ent, "Upsilon") == 0 */) { return 933; } break; /* Phi 934 greek capital letter phi, */ case 498819434u: if (len == 3 /* && strncmp(ent, "Phi") == 0 */) { return 934; } break; /* Chi 935 greek capital letter chi, U+03A7 */ case 4024347861u: if (len == 3 /* && strncmp(ent, "Chi") == 0 */) { return 935; } break; /* Psi 936 greek capital letter psi, */ case 517129209u: if (len == 3 /* && strncmp(ent, "Psi") == 0 */) { return 936; } break; /* Omega 937 greek capital letter omega, */ case 612334204u: if (len == 5 /* && strncmp(ent, "Omega") == 0 */) { return 937; } break; /* alpha 945 greek small letter alpha, */ case 525212009u: if (len == 5 /* && strncmp(ent, "alpha") == 0 */) { return 945; } break; /* beta 946 greek small letter beta, U+03B2 ISOgrk3 */ case 4188941616u: if (len == 4 /* && strncmp(ent, "beta") == 0 */) { return 946; } break; /* gamma 947 greek small letter gamma, */ case 2329672366u: if (len == 5 /* && strncmp(ent, "gamma") == 0 */) { return 947; } break; /* delta 948 greek small letter delta, */ case 353098753u: if (len == 5 /* && strncmp(ent, "delta") == 0 */) { return 948; } break; /* epsilon 949 greek small letter epsilon, */ case 2134684791u: if (len == 7 /* && strncmp(ent, "epsilon") == 0 */) { return 949; } break; /* zeta 950 greek small letter zeta, U+03B6 ISOgrk3 */ case 1753688872u: if (len == 4 /* && strncmp(ent, "zeta") == 0 */) { return 950; } break; /* eta 951 greek small letter eta, U+03B7 ISOgrk3 */ case 109822939u: if (len == 3 /* && strncmp(ent, "eta") == 0 */) { return 951; } break; /* theta 952 greek small letter theta, */ case 402320433u: if (len == 5 /* && strncmp(ent, "theta") == 0 */) { return 952; } break; /* iota 953 greek small letter iota, U+03B9 ISOgrk3 */ case 2900432349u: if (len == 4 /* && strncmp(ent, "iota") == 0 */) { return 953; } break; /* kappa 954 greek small letter kappa, */ case 4139311380u: if (len == 5 /* && strncmp(ent, "kappa") == 0 */) { return 954; } break; /* lambda 955 greek small letter lambda, */ case 3228427083u: if (len == 6 /* && strncmp(ent, "lambda") == 0 */) { return 955; } break; /* mu 956 greek small letter mu, U+03BC ISOgrk3 */ case 1377869104u: if (len == 2 /* && strncmp(ent, "mu") == 0 */) { return 956; } break; /* nu 957 greek small letter nu, U+03BD ISOgrk3 */ case 1379533629u: if (len == 2 /* && strncmp(ent, "nu") == 0 */) { return 957; } break; /* xi 958 greek small letter xi, U+03BE ISOgrk3 */ case 1396178867u: if (len == 2 /* && strncmp(ent, "xi") == 0 */) { return 958; } break; /* omicron 959 greek small letter omicron, U+03BF NEW */ case 174114664u: if (len == 7 /* && strncmp(ent, "omicron") == 0 */) { return 959; } break; /* pi 960 greek small letter pi, U+03C0 ISOgrk3 */ case 1382862667u: if (len == 2 /* && strncmp(ent, "pi") == 0 */) { return 960; } break; /* rho 961 greek small letter rho, U+03C1 ISOgrk3 */ case 859287522u: if (len == 3 /* && strncmp(ent, "rho") == 0 */) { return 961; } break; /* sigmaf 962 greek small letter final sigma, */ case 2582995969u: if (len == 6 /* && strncmp(ent, "sigmaf") == 0 */) { return 962; } break; /* sigma 963 greek small letter sigma, */ case 3951623724u: if (len == 5 /* && strncmp(ent, "sigma") == 0 */) { return 963; } break; /* tau 964 greek small letter tau, U+03C4 ISOgrk3 */ case 1626775263u: if (len == 3 /* && strncmp(ent, "tau") == 0 */) { return 964; } break; /* upsilon 965 greek small letter upsilon, */ case 1977376775u: if (len == 7 /* && strncmp(ent, "upsilon") == 0 */) { return 965; } break; /* phi 966 greek small letter phi, U+03C6 ISOgrk3 */ case 80148106u: if (len == 3 /* && strncmp(ent, "phi") == 0 */) { return 966; } break; /* chi 967 greek small letter chi, U+03C7 ISOgrk3 */ case 3605676533u: if (len == 3 /* && strncmp(ent, "chi") == 0 */) { return 967; } break; /* psi 968 greek small letter psi, U+03C8 ISOgrk3 */ case 98457881u: if (len == 3 /* && strncmp(ent, "psi") == 0 */) { return 968; } break; /* omega 969 greek small letter omega, */ case 1404857500u: if (len == 5 /* && strncmp(ent, "omega") == 0 */) { return 969; } break; /* thetasym 977 greek small letter theta symbol, */ case 3881711083u: if (len == 8 /* && strncmp(ent, "thetasym") == 0 */) { return 977; } break; /* upsih 978 greek upsilon with hook symbol, */ case 3753563936u: if (len == 5 /* && strncmp(ent, "upsih") == 0 */) { return 978; } break; /* piv 982 greek pi symbol, U+03D6 ISOgrk3 */ case 81812644u: if (len == 3 /* && strncmp(ent, "piv") == 0 */) { return 982; } break; /* bull 8226 bullet = black small circle, */ case 1818806115u: if (len == 4 /* && strncmp(ent, "bull") == 0 */) { return 8226; } break; /* hellip 8230 horizontal ellipsis = three dot leader, */ case 1967714928u: if (len == 6 /* && strncmp(ent, "hellip") == 0 */) { return 8230; } break; /* prime 8242 prime = minutes = feet, U+2032 ISOtech */ case 656236556u: if (len == 5 /* && strncmp(ent, "prime") == 0 */) { return 8242; } break; /* Prime 8243 double prime = seconds = inches, */ case 4158680556u: if (len == 5 /* && strncmp(ent, "Prime") == 0 */) { return 8243; } break; /* oline 8254 overline = spacing overscore, */ case 33988362u: if (len == 5 /* && strncmp(ent, "oline") == 0 */) { return 8254; } break; /* frasl 8260 fraction slash, U+2044 NEW */ case 254792559u: if (len == 5 /* && strncmp(ent, "frasl") == 0 */) { return 8260; } break; /* weierp 8472 script capital P = power set */ case 3305299450u: if (len == 6 /* && strncmp(ent, "weierp") == 0 */) { return 8472; } break; /* image 8465 blackletter capital I = imaginary part, */ case 3187641494u: if (len == 5 /* && strncmp(ent, "image") == 0 */) { return 8465; } break; /* real 8476 blackletter capital R = real part symbol, */ case 3965469588u: if (len == 4 /* && strncmp(ent, "real") == 0 */) { return 8476; } break; /* trade 8482 trade mark sign, U+2122 ISOnum */ case 2455601811u: if (len == 5 /* && strncmp(ent, "trade") == 0 */) { return 8482; } break; /* alefsym 8501 alef symbol = first transfinite cardinal, */ case 3894502290u: if (len == 7 /* && strncmp(ent, "alefsym") == 0 */) { return 8501; } break; /* larr 8592 leftwards arrow, U+2190 ISOnum */ case 1970559061u: if (len == 4 /* && strncmp(ent, "larr") == 0 */) { return 8592; } break; /* uarr 8593 upwards arrow, U+2191 ISOnum */ case 2667952018u: if (len == 4 /* && strncmp(ent, "uarr") == 0 */) { return 8593; } break; /* rarr 8594 rightwards arrow, U+2192 ISOnum */ case 2435487699u: if (len == 4 /* && strncmp(ent, "rarr") == 0 */) { return 8594; } break; /* darr 8595 downwards arrow, U+2193 ISOnum */ case 4213965741u: if (len == 4 /* && strncmp(ent, "darr") == 0 */) { return 8595; } break; /* harr 8596 left right arrow, U+2194 ISOamsa */ case 3092262401u: if (len == 4 /* && strncmp(ent, "harr") == 0 */) { return 8596; } break; /* crarr 8629 downwards arrow with corner leftwards */ case 4071143093u: if (len == 5 /* && strncmp(ent, "crarr") == 0 */) { return 8629; } break; /* lArr 8656 leftwards double arrow, U+21D0 ISOtech */ case 2389230389u: if (len == 4 /* && strncmp(ent, "lArr") == 0 */) { return 8656; } break; /* uArr 8657 upwards double arrow, U+21D1 ISOamsa */ case 3086623346u: if (len == 4 /* && strncmp(ent, "uArr") == 0 */) { return 8657; } break; /* rArr 8658 rightwards double arrow, */ case 2854159027u: if (len == 4 /* && strncmp(ent, "rArr") == 0 */) { return 8658; } break; /* dArr 8659 downwards double arrow, U+21D3 ISOamsa */ case 337669773u: if (len == 4 /* && strncmp(ent, "dArr") == 0 */) { return 8659; } break; /* hArr 8660 left right double arrow, */ case 3510933729u: if (len == 4 /* && strncmp(ent, "hArr") == 0 */) { return 8660; } break; /* forall 8704 for all, U+2200 ISOtech */ case 2607244222u: if (len == 6 /* && strncmp(ent, "forall") == 0 */) { return 8704; } break; /* part 8706 partial differential, U+2202 ISOtech */ case 848855723u: if (len == 4 /* && strncmp(ent, "part") == 0 */) { return 8706; } break; /* exist 8707 there exists, U+2203 ISOtech */ case 3677294764u: if (len == 5 /* && strncmp(ent, "exist") == 0 */) { return 8707; } break; /* empty 8709 empty set = null set = diameter, */ case 4121922294u: if (len == 5 /* && strncmp(ent, "empty") == 0 */) { return 8709; } break; /* nabla 8711 nabla = backward difference, */ case 3450596949u: if (len == 5 /* && strncmp(ent, "nabla") == 0 */) { return 8711; } break; /* isin 8712 element of, U+2208 ISOtech */ case 145434111u: if (len == 4 /* && strncmp(ent, "isin") == 0 */) { return 8712; } break; /* notin 8713 not an element of, U+2209 ISOtech */ case 89445443u: if (len == 5 /* && strncmp(ent, "notin") == 0 */) { return 8713; } break; /* ni 8715 contains as member, U+220B ISOtech */ case 1379533617u: if (len == 2 /* && strncmp(ent, "ni") == 0 */) { return 8715; } break; /* prod 8719 n-ary product = product sign, */ case 3171579821u: if (len == 4 /* && strncmp(ent, "prod") == 0 */) { return 8719; } break; /* sum 8721 n-ary sumation, U+2211 ISOamsb */ case 1270496050u: if (len == 3 /* && strncmp(ent, "sum") == 0 */) { return 8721; } break; /* minus 8722 minus sign, U+2212 ISOtech */ case 1443056095u: if (len == 5 /* && strncmp(ent, "minus") == 0 */) { return 8722; } break; /* lowast 8727 asterisk operator, U+2217 ISOtech */ case 137860408u: if (len == 6 /* && strncmp(ent, "lowast") == 0 */) { return 8727; } break; /* radic 8730 square root = radical sign, */ case 565711814u: if (len == 5 /* && strncmp(ent, "radic") == 0 */) { return 8730; } break; /* prop 8733 proportional to, U+221D ISOtech */ case 3171579833u: if (len == 4 /* && strncmp(ent, "prop") == 0 */) { return 8733; } break; /* infin 8734 infinity, U+221E ISOtech */ case 3784651419u: if (len == 5 /* && strncmp(ent, "infin") == 0 */) { return 8734; } break; /* ang 8736 angle, U+2220 ISOamso */ case 2836524271u: if (len == 3 /* && strncmp(ent, "ang") == 0 */) { return 8736; } break; /* and 8743 logical and = wedge, U+2227 ISOtech */ case 2836524268u: if (len == 3 /* && strncmp(ent, "and") == 0 */) { return 8743; } break; /* or 8744 logical or = vee, U+2228 ISOtech */ case 1381198151u: if (len == 2 /* && strncmp(ent, "or") == 0 */) { return 8744; } break; /* cap 8745 intersection = cap, U+2229 ISOtech */ case 3594024865u: if (len == 3 /* && strncmp(ent, "cap") == 0 */) { return 8745; } break; /* cup 8746 union = cup, U+222A ISOtech */ case 3627315365u: if (len == 3 /* && strncmp(ent, "cup") == 0 */) { return 8746; } break; /* int 8747 integral, U+222B ISOtech */ case 1658114628u: if (len == 3 /* && strncmp(ent, "int") == 0 */) { return 8747; } break; /* there4 8756 therefore, U+2234 ISOtech */ case 1359369970u: if (len == 6 /* && strncmp(ent, "there4") == 0 */) { return 8756; } break; /* sim 8764 tilde operator = varies with = similar to, */ case 1250521750u: if (len == 3 /* && strncmp(ent, "sim") == 0 */) { return 8764; } break; /* cong 8773 approximately equal to, U+2245 ISOtech */ case 2425516567u: if (len == 4 /* && strncmp(ent, "cong") == 0 */) { return 8773; } break; /* asymp 8776 almost equal to = asymptotic to, */ case 3150422973u: if (len == 5 /* && strncmp(ent, "asymp") == 0 */) { return 8776; } break; /* ne 8800 not equal to, U+2260 ISOtech */ case 1379533613u: if (len == 2 /* && strncmp(ent, "ne") == 0 */) { return 8800; } break; /* equiv 8801 identical to, U+2261 ISOtech */ case 634790405u: if (len == 5 /* && strncmp(ent, "equiv") == 0 */) { return 8801; } break; /* le 8804 less-than or equal to, U+2264 ISOtech */ case 1376204563u: if (len == 2 /* && strncmp(ent, "le") == 0 */) { return 8804; } break; /* ge 8805 greater-than or equal to, */ case 1367881938u: if (len == 2 /* && strncmp(ent, "ge") == 0 */) { return 8805; } break; /* sub 8834 subset of, U+2282 ISOtech */ case 1270496039u: if (len == 3 /* && strncmp(ent, "sub") == 0 */) { return 8834; } break; /* sup 8835 superset of, U+2283 ISOtech */ case 1270496053u: if (len == 3 /* && strncmp(ent, "sup") == 0 */) { return 8835; } break; /* nsub 8836 not a subset of, U+2284 ISOamsn */ case 1984504696u: if (len == 4 /* && strncmp(ent, "nsub") == 0 */) { return 8836; } break; /* sube 8838 subset of or equal to, U+2286 ISOtech */ case 256147135u: if (len == 4 /* && strncmp(ent, "sube") == 0 */) { return 8838; } break; /* supe 8839 superset of or equal to, */ case 279450485u: if (len == 4 /* && strncmp(ent, "supe") == 0 */) { return 8839; } break; /* oplus 8853 circled plus = direct sum, */ case 92645826u: if (len == 5 /* && strncmp(ent, "oplus") == 0 */) { return 8853; } break; /* otimes 8855 circled times = vector product, */ case 3065242419u: if (len == 6 /* && strncmp(ent, "otimes") == 0 */) { return 8855; } break; /* perp 8869 up tack = orthogonal to = perpendicular, */ case 2407134539u: if (len == 4 /* && strncmp(ent, "perp") == 0 */) { return 8869; } break; /* sdot 8901 dot operator, U+22C5 ISOamsb */ case 2245035582u: if (len == 4 /* && strncmp(ent, "sdot") == 0 */) { return 8901; } break; /* lceil 8968 left ceiling = apl upstile, */ case 1588009020u: if (len == 5 /* && strncmp(ent, "lceil") == 0 */) { return 8968; } break; /* rceil 8969 right ceiling, U+2309 ISOamsc */ case 2541913506u: if (len == 5 /* && strncmp(ent, "rceil") == 0 */) { return 8969; } break; /* lfloor 8970 left floor = apl downstile, */ case 1870296512u: if (len == 6 /* && strncmp(ent, "lfloor") == 0 */) { return 8970; } break; /* rfloor 8971 right floor, U+230B ISOamsc */ case 1865132014u: if (len == 6 /* && strncmp(ent, "rfloor") == 0 */) { return 8971; } break; /* lang 9001 left-pointing angle bracket = bra, */ case 1963900950u: if (len == 4 /* && strncmp(ent, "lang") == 0 */) { return 9001; } break; /* rang 9002 right-pointing angle bracket = ket, */ case 2428829588u: if (len == 4 /* && strncmp(ent, "rang") == 0 */) { return 9002; } break; /* loz 9674 lozenge, U+25CA ISOpub */ case 2828488274u: if (len == 3 /* && strncmp(ent, "loz") == 0 */) { return 9674; } break; /* spades 9824 black spade suit, U+2660 ISOpub */ case 4026453962u: if (len == 6 /* && strncmp(ent, "spades") == 0 */) { return 9824; } break; /* clubs 9827 black club suit = shamrock, */ case 2781041564u: if (len == 5 /* && strncmp(ent, "clubs") == 0 */) { return 9827; } break; /* hearts 9829 black heart suit = valentine, */ case 2039418001u: if (len == 6 /* && strncmp(ent, "hearts") == 0 */) { return 9829; } break; /* diams 9830 black diamond suit, U+2666 ISOpub */ case 3524411593u: if (len == 5 /* && strncmp(ent, "diams") == 0 */) { return 9830; } break; /* quot 34 quotation mark = APL quote, */ case 2986121293u: if (len == 4 /* && strncmp(ent, "quot") == 0 */) { return 34; } break; /* amp 38 ampersand, U+0026 ISOnum */ case 2834859755u: if (len == 3 /* && strncmp(ent, "amp") == 0 */) { return 38; } break; /* lt 60 less-than sign, U+003C ISOnum */ case 1376204578u: if (len == 2 /* && strncmp(ent, "lt") == 0 */) { return 60; } break; /* gt 62 greater-than sign, U+003E ISOnum */ case 1367881953u: if (len == 2 /* && strncmp(ent, "gt") == 0 */) { return 62; } break; /* OElig 338 latin capital ligature OE, */ case 1674782707u: if (len == 5 /* && strncmp(ent, "OElig") == 0 */) { return 338; } break; /* oelig 339 latin small ligature oe, U+0153 ISOlat2 */ case 2083613875u: if (len == 5 /* && strncmp(ent, "oelig") == 0 */) { return 339; } break; /* Scaron 352 latin capital letter S with caron, */ case 1731202952u: if (len == 6 /* && strncmp(ent, "Scaron") == 0 */) { return 352; } break; /* scaron 353 latin small letter s with caron, */ case 3135314728u: if (len == 6 /* && strncmp(ent, "scaron") == 0 */) { return 353; } break; /* Yuml 376 latin capital letter Y with diaeresis, */ case 1123077683u: if (len == 4 /* && strncmp(ent, "Yuml") == 0 */) { return 376; } break; /* circ 710 modifier letter circumflex accent, */ case 94756433u: if (len == 4 /* && strncmp(ent, "circ") == 0 */) { return 710; } break; /* tilde 732 small tilde, U+02DC ISOdia */ case 1748508313u: if (len == 5 /* && strncmp(ent, "tilde") == 0 */) { return 732; } break; /* ensp 8194 en space, U+2002 ISOpub */ case 3630901474u: if (len == 4 /* && strncmp(ent, "ensp") == 0 */) { return 8194; } break; /* emsp 8195 em space, U+2003 ISOpub */ case 3241331769u: if (len == 4 /* && strncmp(ent, "emsp") == 0 */) { return 8195; } break; /* thinsp 8201 thin space, U+2009 ISOpub */ case 2997658516u: if (len == 6 /* && strncmp(ent, "thinsp") == 0 */) { return 8201; } break; /* zwnj 8204 zero width non-joiner, */ case 166021829u: if (len == 4 /* && strncmp(ent, "zwnj") == 0 */) { return 8204; } break; /* zwj 8205 zero width joiner, U+200D NEW RFC 2070 */ case 4000813032u: if (len == 3 /* && strncmp(ent, "zwj") == 0 */) { return 8205; } break; /* lrm 8206 left-to-right mark, U+200E NEW RFC 2070 */ case 2833481836u: if (len == 3 /* && strncmp(ent, "lrm") == 0 */) { return 8206; } break; /* rlm 8207 right-to-left mark, U+200F NEW RFC 2070 */ case 865945620u: if (len == 3 /* && strncmp(ent, "rlm") == 0 */) { return 8207; } break; /* ndash 8211 en dash, U+2013 ISOpub */ case 3305143245u: if (len == 5 /* && strncmp(ent, "ndash") == 0 */) { return 8211; } break; /* mdash 8212 em dash, U+2014 ISOpub */ case 3146159164u: if (len == 5 /* && strncmp(ent, "mdash") == 0 */) { return 8212; } break; /* lsquo 8216 left single quotation mark, */ case 1796006423u: if (len == 5 /* && strncmp(ent, "lsquo") == 0 */) { return 8216; } break; /* rsquo 8217 right single quotation mark, */ case 2749910909u: if (len == 5 /* && strncmp(ent, "rsquo") == 0 */) { return 8217; } break; /* sbquo 8218 single low-9 quotation mark, U+201A NEW */ case 159941417u: if (len == 5 /* && strncmp(ent, "sbquo") == 0 */) { return 8218; } break; /* ldquo 8220 left double quotation mark, */ case 633684828u: if (len == 5 /* && strncmp(ent, "ldquo") == 0 */) { return 8220; } break; /* rdquo 8221 right double quotation mark, */ case 1587589314u: if (len == 5 /* && strncmp(ent, "rdquo") == 0 */) { return 8221; } break; /* bdquo 8222 double low-9 quotation mark, U+201E NEW */ case 3338811314u: if (len == 5 /* && strncmp(ent, "bdquo") == 0 */) { return 8222; } break; /* dagger 8224 dagger, U+2020 ISOpub */ case 3288241744u: if (len == 6 /* && strncmp(ent, "dagger") == 0 */) { return 8224; } break; /* Dagger 8225 double dagger, U+2021 ISOpub */ case 1884129968u: if (len == 6 /* && strncmp(ent, "Dagger") == 0 */) { return 8225; } break; /* permil 8240 per mille sign, U+2030 ISOtech */ case 4246983035u: if (len == 6 /* && strncmp(ent, "permil") == 0 */) { return 8240; } break; /* lsaquo 8249 single left-pointing angle quotation mark, */ case 2442191187u: if (len == 6 /* && strncmp(ent, "lsaquo") == 0 */) { return 8249; } break; /* rsaquo 8250 single right-pointing angle quotation mark, */ case 2437026689u: if (len == 6 /* && strncmp(ent, "rsaquo") == 0 */) { return 8250; } break; /* euro 8364 euro sign, U+20AC NEW */ case 2061257587u: if (len == 4 /* && strncmp(ent, "euro") == 0 */) { return 8364; } break; } /* unknown */ return -1; } httrack-3.49.5/src/htsencoding.h0000644000175000017500000000655614336470674013474 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Encoding conversion functions */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTS_ENCODING_DEFH #define HTS_ENCODING_DEFH /** Standard includes. **/ #include #include #ifdef _WIN32 #include #endif /** * Flags for hts_unescapeUrlSpecial(). **/ typedef enum unescapeFlags { /** Do not decode ASCII. **/ UNESCAPE_URL_NO_ASCII = 1 } unescapeFlags; /** * Unescape HTML entities (as per HTML 4.0 Specification) * and replace them in-place by their UTF-8 equivalents. * Note: source and destination may be the same, and the destination only * needs to hold as space as the source. * Returns 0 upon success, -1 upon overflow or error. **/ extern int hts_unescapeEntities(const char *src, char *dest, const size_t max); /** * Unescape HTML entities (as per HTML 4.0 Specification) * and replace them in-place by their charset equivalents. * Note: source and destination may be the same, and the destination only * needs to hold as space as the source. * Returns 0 upon success, -1 upon overflow or error. **/ extern int hts_unescapeEntitiesWithCharset(const char *src, char *dest, const size_t max, const char *charset); /** * Unescape an URL-encoded string. The implicit charset is UTF-8. * In case of UTF-8 decoding error inside URL-encoded characters, * the characters are left undecoded. * Note: source and destination MUST NOT be the same. * Returns 0 upon success, -1 upon overflow or error. **/ extern int hts_unescapeUrl(const char *src, char *dest, const size_t max); /** * Unescape an URL-encoded string. The implicit charset is UTF-8. * In case of UTF-8 decoding error inside URL-encoded characters, * the characters are left undecoded. * "flags" is a mask composed of UNESCAPE_URL_XXX constants. * Note: source and destination MUST NOT be the same. * Returns 0 upon success, -1 upon overflow or error. **/ extern int hts_unescapeUrlSpecial(const char *src, char *dest, const size_t max, const int flags); #endif httrack-3.49.5/src/punycode.h0000644000175000017500000001050114336470674012776 00000000000000/* punycode.c from RFC 3492 http://www.nicemice.net/idn/ Adam M. Costello http://www.nicemice.net/amc/ This is ANSI C code (C89) implementing Punycode (RFC 3492). */ #ifndef PUNYCODE_COSTELLO_RFC3492_H #define PUNYCODE_COSTELLO_RFC3492_H /********************/ /* Public interface */ #include typedef enum punycode_status { punycode_success, punycode_bad_input, /* Input is invalid. */ punycode_big_output, /* Output would exceed the space provided. */ punycode_overflow /* Input needs wider integers to process. */ } punycode_status; #if UINT_MAX >= (1 << 26) - 1 typedef unsigned int punycode_uint; #else typedef unsigned long punycode_uint; #endif /* punycode_encode() converts Unicode to Punycode. The input */ /* is represented as an array of Unicode code points (not code */ /* units; surrogate pairs are not allowed), and the output */ /* will be represented as an array of ASCII code points. The */ /* output string is *not* null-terminated; it will contain */ /* zeros if and only if the input contains zeros. (Of course */ /* the caller can leave room for a terminator and add one if */ /* needed.) The input_length is the number of code points in */ /* the input. The output_length is an in/out argument: the */ /* caller passes in the maximum number of code points that it */ /* can receive, and on successful return it will contain the */ /* number of code points actually output. The case_flags array */ /* holds input_length boolean values, where nonzero suggests that */ /* the corresponding Unicode character be forced to uppercase */ /* after being decoded (if possible), and zero suggests that */ /* it be forced to lowercase (if possible). ASCII code points */ /* are encoded literally, except that ASCII letters are forced */ /* to uppercase or lowercase according to the corresponding */ /* uppercase flags. If case_flags is a null pointer then ASCII */ /* letters are left as they are, and other code points are */ /* treated as if their uppercase flags were zero. The return */ /* value can be any of the punycode_status values defined above */ /* except punycode_bad_input; if not punycode_success, then */ /* output_size and output might contain garbage. */ enum punycode_status punycode_encode(punycode_uint input_length, const punycode_uint input[], const unsigned char case_flags[], punycode_uint * output_length, char output[]); /* punycode_decode() converts Punycode to Unicode. The input is */ /* represented as an array of ASCII code points, and the output */ /* will be represented as an array of Unicode code points. The */ /* input_length is the number of code points in the input. The */ /* output_length is an in/out argument: the caller passes in */ /* the maximum number of code points that it can receive, and */ /* on successful return it will contain the actual number of */ /* code points output. The case_flags array needs room for at */ /* least output_length values, or it can be a null pointer if the */ /* case information is not needed. A nonzero flag suggests that */ /* the corresponding Unicode character be forced to uppercase */ /* by the caller (if possible), while zero suggests that it be */ /* forced to lowercase (if possible). ASCII code points are */ /* output already in the proper case, but their flags will be set */ /* appropriately so that applying the flags would be harmless. */ /* The return value can be any of the punycode_status values */ /* defined above; if not punycode_success, then output_length, */ /* output, and case_flags might contain garbage. On success, the */ /* decoder will never need to write an output_length greater than */ /* input_length, because of how the encoding is defined. */ enum punycode_status punycode_decode(punycode_uint input_length, const char input[], punycode_uint * output_length, punycode_uint output[], unsigned char case_flags[]); #endif httrack-3.49.5/src/htscharset.h0000644000175000017500000001251014336470674013322 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Charset conversion functions */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTS_CHARSET_DEFH #define HTS_CHARSET_DEFH /** Standard includes. **/ #include #include #ifdef _WIN32 #include #endif /** UCS4 type. **/ typedef unsigned int hts_UCS4; /** Leading character (ASCII or leading UTF-8 sequence) **/ #define HTS_IS_LEADING_UTF8(C) ((unsigned char)(C) < 0x80 || (unsigned char)(C) >= 0xc0) /** * Convert the string "s" from charset "charset" to UTF-8. * Return NULL upon error. **/ extern char *hts_convertStringToUTF8(const char *s, size_t size, const char *charset); /** * Convert the string "s" from UTF-8 to charset "charset". * Return NULL upon error. **/ extern char *hts_convertStringFromUTF8(const char *s, size_t size, const char *charset); /** * Convert an UTF-8 string to an IDNA (RFC 3492) string. **/ extern char *hts_convertStringUTF8ToIDNA(const char *s, size_t size); /** * Convert an IDNA (RFC 3492) string to an UTF-8 string. **/ extern char *hts_convertStringIDNAToUTF8(const char *s, size_t size); /** * Has the given string any IDNA segments ? **/ extern int hts_isStringIDNA(const char *s, size_t size); /** * Extract the charset from the HTML buffer "html" **/ extern char *hts_getCharsetFromMeta(const char *html, size_t size); /** * Is the given string an ASCII string ? **/ extern int hts_isStringAscii(const char *s, size_t size); /** * Is the given string an UTF-8 string ? **/ extern int hts_isStringUTF8(const char *s, size_t size); /** * Is the given charset the UTF-8 charset ? **/ extern int hts_isCharsetUTF8(const char *charset); /** * Get an UTF-8 string length in characters. **/ extern size_t hts_stringLengthUTF8(const char *s); /** * Copy at most 'nBytes' bytes from src to dest, not truncating UTF-8 * sequences. * Returns the number of bytes copied, not including the terminating \0. **/ extern size_t hts_copyStringUTF8(char *dest, const char *src, size_t nBytes); /** * Append at most 'nBytes' bytes from src to dest, not truncating UTF-8 * sequences. * Returns the number of bytes appended, not including the terminating \0. **/ extern size_t hts_appendStringUTF8(char *dest, const char *src, size_t nBytes); /** * Convert an UTF-8 string into an Unicode string (0-terminated). **/ extern hts_UCS4* hts_convertUTF8StringToUCS4(const char *s, size_t size, size_t *nChars); /** * Convert an Unicode string into an UTF-8 string. **/ extern char *hts_convertUCS4StringToUTF8(const hts_UCS4 *s, size_t nChars); /** * Return the length (in characters) of an UCS4 string terminated by 0. **/ extern size_t hts_stringLengthUCS4(const hts_UCS4 *s); /** * Write the Unicode character 'uc' in 'dest' of maximum size 'size'. * Return the number of bytes written, or 0 upon error. * Note: does not \0-terminate the destination buffer. **/ extern size_t hts_writeUTF8(hts_UCS4 uc, char *dest, size_t size); /** * Read the next Unicode character within 'src' of size 'size' and, upon * successful reading, return the number of bytes read and place the * character is 'puc'. * Return 0 upon error. **/ extern size_t hts_readUTF8(const char *src, size_t size, hts_UCS4 *puc); /** * Given the first UTF-8 sequence character, get the total number of * characters in the sequence (1 for ASCII). * Return 0 upon error (not a leading character). **/ extern size_t hts_getUTF8SequenceLength(const char lead); /** WIN32 specific functions. **/ #ifdef _WIN32 /** * Convert UTF-8 to WCHAR. * This function is WIN32 specific. **/ extern LPWSTR hts_convertUTF8StringToUCS2(const char *s, int size, int *pwsize); /** * Convert from WCHAR. * This function is WIN32 specific. **/ extern char *hts_convertUCS2StringToUTF8(LPWSTR woutput, int wsize); /** * Convert current system codepage to UTF-8. * This function is WIN32 specific. **/ extern char *hts_convertStringSystemToUTF8(const char *s, size_t size); #endif #endif httrack-3.49.5/src/httrack-library.h0000644000175000017500000003444714336470674014271 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: HTTrack definition file for library usage */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTTRACK_DEFLIB #define HTTRACK_DEFLIB #ifdef __cplusplus extern "C" { #endif #include "htsglobal.h" #ifndef _WIN32 #include #endif #include #ifndef HTS_DEF_FWSTRUCT_httrackp #define HTS_DEF_FWSTRUCT_httrackp typedef struct httrackp httrackp; #endif #ifndef HTS_DEF_FWSTRUCT_strc_int2bytes2 #define HTS_DEF_FWSTRUCT_strc_int2bytes2 typedef struct strc_int2bytes2 strc_int2bytes2; #endif #ifndef HTS_DEF_DEFSTRUCT_hts_log_type #define HTS_DEF_DEFSTRUCT_hts_log_type typedef enum hts_log_type { LOG_PANIC, LOG_ERROR, LOG_WARNING, LOG_NOTICE, LOG_INFO, LOG_DEBUG, LOG_TRACE, LOG_ERRNO = 1 << 8 } hts_log_type; #endif #ifndef HTS_DEF_FWSTRUCT_hts_stat_struct #define HTS_DEF_FWSTRUCT_hts_stat_struct typedef struct hts_stat_struct hts_stat_struct; #endif /** Assert error callback. **/ #ifndef HTS_DEF_FWSTRUCT_htsErrorCallback #define HTS_DEF_FWSTRUCT_htsErrorCallback typedef void (*htsErrorCallback) (const char *msg, const char *file, int line); #endif /* Helpers for plugging callbacks requires: htsdefines.h */ /* Add a function callback 'FUNCTION' to the option structure 'OPT' callback member 'MEMBER', with an optional (may be NULL) argument 'ARGUMENT' */ #define CHAIN_FUNCTION(OPT, MEMBER, FUNCTION, ARGUMENT) do { \ t_hts_callbackarg *carg = (t_hts_callbackarg*) hts_malloc(sizeof(t_hts_callbackarg)); \ carg->userdef = ( ARGUMENT ); \ carg->prev.fun = (void*) ( OPT )->callbacks_fun-> MEMBER .fun; \ carg->prev.carg = ( OPT )->callbacks_fun-> MEMBER .carg; \ ( OPT )->callbacks_fun-> MEMBER .fun = ( FUNCTION ); \ ( OPT )->callbacks_fun-> MEMBER .carg = carg; \ } while(0) /* The following helpers are useful only if you know that an existing callback migh be existing before before the call to CHAIN_FUNCTION() If your functions were added just after hts_create_opt(), no need to make the previous function check */ /* Get the user-defined pointer initially passed to CHAIN_FUNCTION(), given the callback's carg argument */ #define CALLBACKARG_USERDEF(CARG) ( ( (CARG) != NULL ) ? (CARG)->userdef : NULL ) /* Get the previously existing function before the call to CHAIN_FUNCTION(), given the callback's carg argument */ #define CALLBACKARG_PREV_FUN(CARG, NAME) ( (t_hts_htmlcheck_ ##NAME) ( ( (CARG) != NULL ) ? (CARG)->prev.fun : NULL ) ) /* Get the previously existing function argument before the call to CHAIN_FUNCTION(), given the callback's carg argument */ #define CALLBACKARG_PREV_CARG(CARG) ( ( (CARG) != NULL ) ? (CARG)->prev.carg : NULL ) /* Functions */ /* Initialization */ HTSEXT_API int hts_init(void); HTSEXT_API int hts_uninit(void); HTSEXT_API void htsthread_wait(void); /* Main functions */ HTSEXT_API int hts_main(int argc, char **argv); HTSEXT_API int hts_main2(int argc, char **argv, httrackp * opt); /* Options handling */ HTSEXT_API httrackp *hts_create_opt(void); HTSEXT_API void hts_free_opt(httrackp * opt); HTSEXT_API size_t hts_sizeof_opt(void); HTSEXT_API const hts_stat_struct* hts_get_stats(httrackp * opt); HTSEXT_API void set_wrappers(httrackp * opt); /* LEGACY */ HTSEXT_API int plug_wrapper(httrackp * opt, const char *moduleName, const char *argv); HTSEXT_API void hts_set_error_callback(htsErrorCallback handler); HTSEXT_API htsErrorCallback hts_get_error_callback(void); /* Logging */ HTSEXT_API int hts_log(httrackp * opt, const char *prefix, const char *msg); HTSEXT_API void hts_log_print(httrackp * opt, int type, const char *format, ...) HTS_PRINTF_FUN(3, 4); HTSEXT_API void hts_log_vprint(httrackp * opt, int type, const char *format, va_list args); HTSEXT_API void hts_set_log_vprint_callback(void (*callback)(httrackp * opt, int type, const char *format, va_list args)); /* Infos */ HTSEXT_API const char *hts_get_version_info(httrackp * opt); HTSEXT_API const char *hts_is_available(void); HTSEXT_API const char* hts_version(void); HTSEXT_API const hts_stat_struct* hts_get_stats(httrackp * opt); /* Wrapper functions */ HTSEXT_API int htswrap_init(void); // DEPRECATED - DUMMY FUNCTION HTSEXT_API int htswrap_free(void); // DEPRECATED - DUMMY FUNCTION HTSEXT_API int htswrap_add(httrackp * opt, const char *name, void *fct); HTSEXT_API uintptr_t htswrap_read(httrackp * opt, const char *name); HTSEXT_API int htswrap_set_userdef(httrackp * opt, void *userdef); HTSEXT_API void *htswrap_get_userdef(httrackp * opt); /* Internal library allocators, if a different libc is being used by the client */ HTSEXT_API char *hts_strdup(const char *string); HTSEXT_API void *hts_malloc(size_t size); HTSEXT_API void *hts_realloc(void *const data, const size_t size); HTSEXT_API void hts_free(void *data); /* Other functions */ HTSEXT_API int hts_resetvar(void); // DEPRECATED - DUMMY FUNCTION HTSEXT_API int hts_buildtopindex(httrackp * opt, const char *path, const char *binpath); HTSEXT_API char *hts_getcategories(char *path, int type); HTSEXT_API char *hts_getcategory(const char *filename); /* Catch-URL */ HTSEXT_API T_SOC catch_url_init_std(int *port_prox, char *adr_prox); HTSEXT_API T_SOC catch_url_init(int *port, char *adr); HTSEXT_API int catch_url(T_SOC soc, char *url, char *method, char *data); /* State */ HTSEXT_API int hts_is_parsing(httrackp * opt, int flag); HTSEXT_API int hts_is_testing(httrackp * opt); HTSEXT_API int hts_is_exiting(httrackp * opt); /*HTSEXT_API int hts_setopt(httrackp* opt); DEPRECATED ; see copy_htsopt() */ HTSEXT_API int hts_addurl(httrackp * opt, char **url); HTSEXT_API int hts_resetaddurl(httrackp * opt); HTSEXT_API int copy_htsopt(const httrackp * from, httrackp * to); HTSEXT_API char *hts_errmsg(httrackp * opt); HTSEXT_API int hts_setpause(httrackp * opt, int); HTSEXT_API int hts_request_stop(httrackp * opt, int force); HTSEXT_API int hts_cancel_file_push(httrackp * opt, const char *url); HTSEXT_API void hts_cancel_test(httrackp * opt); HTSEXT_API void hts_cancel_parsing(httrackp * opt); HTSEXT_API void hts_cancel_test(httrackp * opt); HTSEXT_API void hts_cancel_parsing(httrackp * opt); HTSEXT_API int hts_has_stopped(httrackp * opt); /* Tools */ HTSEXT_API int structcheck(const char *path); HTSEXT_API int structcheck_utf8(const char *path); HTSEXT_API int dir_exists(const char *path); HTSEXT_API void infostatuscode(char *msg, int statuscode); HTSEXT_API TStamp mtime_local(void); HTSEXT_API void qsec2str(char *st, TStamp t); HTSEXT_API char *int2char(strc_int2bytes2 * strc, int n); HTSEXT_API char *int2bytes(strc_int2bytes2 * strc, LLint n); HTSEXT_API char *int2bytessec(strc_int2bytes2 * strc, long int n); HTSEXT_API char **int2bytes2(strc_int2bytes2 * strc, LLint n); HTSEXT_API char *jump_identification(char *); HTSEXT_API const char *jump_identification_const(const char *); HTSEXT_API char *jump_normalized(char *); HTSEXT_API const char *jump_normalized_const(const char *); HTSEXT_API char *jump_toport(char *); HTSEXT_API const char *jump_toport_const(const char *); HTSEXT_API char *fil_normalized(const char *source, char *dest); HTSEXT_API char *adr_normalized(const char *source, char *dest); HTSEXT_API const char *hts_rootdir(char *file); /* Escaping URLs */ HTSEXT_API void unescape_amp(char *s); HTSEXT_API size_t escape_spc_url(const char *const src, char *const dest, const size_t size); HTSEXT_API size_t escape_in_url(const char *const src, char *const dest, const size_t size); HTSEXT_API size_t escape_uri(const char *const src, char *const dest, const size_t size); HTSEXT_API size_t escape_uri_utf(const char *const src, char *const dest, const size_t size); HTSEXT_API size_t escape_check_url(const char *const src, char *const dest, const size_t size); HTSEXT_API size_t append_escape_spc_url(const char *const src, char *const dest, const size_t size); HTSEXT_API size_t append_escape_in_url(const char *const src, char *const dest, const size_t size); HTSEXT_API size_t append_escape_uri(const char *const src, char *const dest, const size_t size); HTSEXT_API size_t append_escape_uri_utf(const char *const src, char *const dest, const size_t size); HTSEXT_API size_t append_escape_check_url(const char *const src, char *const dest, const size_t size); HTSEXT_API size_t inplace_escape_spc_url(char *const dest, const size_t size); HTSEXT_API size_t inplace_escape_in_url(char *const dest, const size_t size); HTSEXT_API size_t inplace_escape_uri(char *const dest, const size_t size); HTSEXT_API size_t inplace_escape_uri_utf(char *const dest, const size_t size); HTSEXT_API size_t inplace_escape_check_url(char *const dest, const size_t size); HTSEXT_API char *escape_check_url_addr(const char *const src, char *const dest, const size_t size); HTSEXT_API size_t make_content_id(const char *const adr, const char *const fil, char *const dest, const size_t size); HTSEXT_API size_t x_escape_http(const char *const s, char *const dest, const size_t max_size, const int mode); HTSEXT_API void escape_remove_control(char *const s); HTSEXT_API size_t escape_for_html_print(const char *const s, char *const dest, const size_t size); HTSEXT_API size_t escape_for_html_print_full(const char *const s, char *const dest, const size_t size); HTSEXT_API char *unescape_http(char *const catbuff, const size_t size, const char *const s); HTSEXT_API char *unescape_http_unharm(char *const catbuff, const size_t size, const char *s, const int no_high); HTSEXT_API char *antislash_unescaped(char *catbuff, const char *s); HTSEXT_API void escape_remove_control(char *s); HTSEXT_API void get_httptype(httrackp * opt, char *s, const char *fil, int flag); HTSEXT_API int is_knowntype(httrackp * opt, const char *fil); HTSEXT_API int is_userknowntype(httrackp * opt, const char *fil); HTSEXT_API int is_dyntype(const char *fil); HTSEXT_API const char *get_ext(char *catbuff, size_t size, const char *fil); HTSEXT_API int may_unknown(httrackp * opt, const char *st); HTSEXT_API void guess_httptype(httrackp * opt, char *s, const char *fil); /* Ugly string tools */ HTSEXT_API char *concat(char *catbuff, size_t size, const char *a, const char *b); HTSEXT_API char *fconcat(char *catbuff, size_t size, const char *a, const char *b); HTSEXT_API char *fconv(char *catbuff, size_t size, const char *a); HTSEXT_API char *fslash(char *catbuff, size_t size, const char *a); /* Debugging */ HTSEXT_API void hts_debug(int level); /* Portable directory API */ #ifndef HTS_DEF_FWSTRUCT_find_handle_struct #define HTS_DEF_FWSTRUCT_find_handle_struct typedef struct find_handle_struct find_handle_struct; typedef find_handle_struct *find_handle; #endif #ifndef HTS_DEF_FWSTRUCT_topindex_chain #define HTS_DEF_FWSTRUCT_topindex_chain typedef struct topindex_chain topindex_chain; #endif struct topindex_chain { int level; /* sort level */ char *category; /* category */ char name[2048]; /* path */ struct topindex_chain *next; /* next element */ }; HTSEXT_API find_handle hts_findfirst(char *path); HTSEXT_API int hts_findnext(find_handle find); HTSEXT_API int hts_findclose(find_handle find); HTSEXT_API char *hts_findgetname(find_handle find); HTSEXT_API int hts_findgetsize(find_handle find); HTSEXT_API int hts_findisdir(find_handle find); HTSEXT_API int hts_findisfile(find_handle find); HTSEXT_API int hts_findissystem(find_handle find); /* UTF-8 aware FILE API */ #ifndef HTS_DEF_FILEAPI #ifdef _WIN32 #define FOPEN hts_fopen_utf8 HTSEXT_API FILE *hts_fopen_utf8(const char *path, const char *mode); #define STAT hts_stat_utf8 typedef struct _stat STRUCT_STAT; HTSEXT_API int hts_stat_utf8(const char *path, STRUCT_STAT * buf); #define UNLINK hts_unlink_utf8 HTSEXT_API int hts_unlink_utf8(const char *pathname); #define RENAME hts_rename_utf8 HTSEXT_API int hts_rename_utf8(const char *oldpath, const char *newpath); #define MKDIR(F) hts_mkdir_utf8(F) HTSEXT_API int hts_mkdir_utf8(const char *pathname); #define UTIME(A,B) hts_utime_utf8(A,B) typedef struct _utimbuf STRUCT_UTIMBUF; HTSEXT_API int hts_utime_utf8(const char *filename, const STRUCT_UTIMBUF * times); #else #define FOPEN fopen #define STAT stat typedef struct stat STRUCT_STAT; #define UNLINK unlink #define RENAME rename #define MKDIR(F) mkdir(F, HTS_ACCESS_FOLDER) typedef struct utimbuf STRUCT_UTIMBUF; #define UTIME(A,B) utime(A,B) #endif #define HTS_DEF_FILEAPI #endif /** Macro aimed to break at build-time if a size is not a sizeof() strictly * greater than sizeof(char*). **/ #undef COMPILE_TIME_CHECK_SIZE #define COMPILE_TIME_CHECK_SIZE(A) (void) ((void (*)(char[A - sizeof(char*) - 1])) NULL) /** Macro aimed to break at compile-time if a size is not a sizeof() strictly * greater than sizeof(char*). **/ #undef RUNTIME_TIME_CHECK_SIZE #define RUNTIME_TIME_CHECK_SIZE(A) assertf((A) != sizeof(void*)) #define fconv(A,B,C) (COMPILE_TIME_CHECK_SIZE(B), fconv(A,B,C)) #define concat(A,B,C,D) (COMPILE_TIME_CHECK_SIZE(B), concat(A,B,C,D)) #define fconcat(A,B,C,D) (COMPILE_TIME_CHECK_SIZE(B), fconcat(A,B,C,D)) #define fslash(A,B,C) (COMPILE_TIME_CHECK_SIZE(B), fslash(A,B,C)) #ifdef __cplusplus } #endif #endif httrack-3.49.5/src/htsarrays.h0000644000175000017500000001116214336470674013174 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Arrays */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTS_ARRAYS_DEFSTATIC #define HTS_ARRAYS_DEFSTATIC /* System definitions. */ #include #include #include "htssafe.h" /* Memory allocation assertion failure */ static void hts_record_assert_memory_failed(const size_t size) { fprintf(stderr, "memory allocation failed (%lu bytes)", \ (long int) size); \ assertf(! "memory allocation failed"); \ } /** Dynamic array of T elements. **/ #define TypedArray(T) \ struct { \ /** Elements. **/ \ union { \ /** Typed. **/ \ T* elts; \ /** Opaque. **/ \ void* ptr; \ } data; \ /** Count. **/ \ size_t size; \ /** Capacity. **/ \ size_t capa; \ } #define EMPTY_TYPED_ARRAY { { NULL }, 0, 0 } /** Array size, in elements. **/ #define TypedArraySize(A) ((A).size) /** Array capacity, in elements. **/ #define TypedArrayCapa(A) ((A).capa) /** * Remaining free space, in elements. * Macro, first element evaluated multiple times. **/ #define TypedArrayRoom(A) ( TypedArrayCapa(A) - TypedArraySize(A) ) /** Array elements, of type T*. **/ #define TypedArrayElts(A) ((A).data.elts) /** Array pointer, of type void*. **/ #define TypedArrayPtr(A) ((A).data.ptr) /** Size of T. **/ #define TypedArrayWidth(A) (sizeof(*TypedArrayElts(A))) /** Nth element of the array. **/ #define TypedArrayNth(A, N) (TypedArrayElts(A)[N]) /** * Tail of the array (outside the array). * The returned pointer points to the beginning of TypedArrayRoom(A) * free elements. **/ #define TypedArrayTail(A) (TypedArrayNth(A, TypedArraySize(A))) /** * Ensure at least 'ROOM' elements can be put in the remaining space. * After a call to this macro, TypedArrayRoom(A) is guaranteed to be at * least equal to 'ROOM'. **/ #define TypedArrayEnsureRoom(A, ROOM) do { \ const size_t room_ = (ROOM); \ while (TypedArrayRoom(A) < room_) { \ TypedArrayCapa(A) = TypedArrayCapa(A) < 16 ? 16 : TypedArrayCapa(A) * 2; \ } \ TypedArrayPtr(A) = realloc(TypedArrayPtr(A), \ TypedArrayCapa(A)*TypedArrayWidth(A)); \ if (TypedArrayPtr(A) == NULL) { \ hts_record_assert_memory_failed(TypedArrayCapa(A)*TypedArrayWidth(A)); \ } \ } while(0) /** Add an element. Macro, first element evaluated multiple times. **/ #define TypedArrayAdd(A, E) do { \ TypedArrayEnsureRoom(A, 1); \ assertf(TypedArraySize(A) < TypedArrayCapa(A)); \ TypedArrayTail(A) = (E); \ TypedArraySize(A)++; \ } while(0) /** * Add 'COUNT' elements from 'PTR'. * Macro, first element evaluated multiple times. **/ #define TypedArrayAppend(A, PTR, COUNT) do { \ const size_t count_ = (COUNT); \ /* This 1-case is to benefit from type safety. */ \ if (count_ == 1) { \ TypedArrayAdd(A, *(PTR)); \ } else { \ const void *const source_ = (PTR); \ TypedArrayEnsureRoom(A, count_); \ assertf(count_ <= TypedArrayRoom(A)); \ memcpy(&TypedArrayTail(A), source_, count_ * TypedArrayWidth(A)); \ TypedArraySize(A) += count_; \ } \ } while(0) /** Clear an array, freeing memory and clearing size and capacity. **/ #define TypedArrayFree(A) do { \ if (TypedArrayPtr(A) != NULL) { \ TypedArrayCapa(A) = TypedArraySize(A) = 0; \ free(TypedArrayPtr(A)); \ TypedArrayPtr(A) = NULL; \ } \ } while(0) #endif httrack-3.49.5/src/htsstrings.h0000644000175000017500000002033414336470674013365 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Strings */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* Safer Strings ; standalone .h library */ #ifndef HTS_STRINGS_DEFSTATIC #define HTS_STRINGS_DEFSTATIC /* System definitions. */ #include /* GCC extension */ #ifndef HTS_UNUSED #ifdef __GNUC__ #define HTS_UNUSED __attribute__ ((unused)) #define HTS_STATIC static __attribute__ ((unused)) #define HTS_PRINTF_FUN(fmt, arg) __attribute__ ((format (printf, fmt, arg))) #else #define HTS_UNUSED #define HTS_STATIC static #define HTS_PRINTF_FUN(fmt, arg) #endif #endif /** Forward definitions **/ #ifndef HTS_DEF_FWSTRUCT_String #define HTS_DEF_FWSTRUCT_String typedef struct String String; #endif #ifndef HTS_DEF_STRUCT_String #define HTS_DEF_STRUCT_String struct String { char *buffer_; size_t length_; size_t capacity_; }; #endif /** Allocator **/ #ifndef STRING_REALLOC #define STRING_REALLOC(BUFF, SIZE) ( (char*) realloc(BUFF, SIZE) ) #define STRING_FREE(BUFF) free(BUFF) #endif #ifndef STRING_ASSERT #include #define STRING_ASSERT(EXP) assert(EXP) #endif /** An empty string **/ #define STRING_EMPTY { (char*) NULL, 0, 0 } /** String buffer **/ #define StringBuff(BLK) ( (const char*) ((BLK).buffer_) ) /** String buffer (read/write) **/ #define StringBuffRW(BLK) ((BLK).buffer_) /** String length **/ #define StringLength(BLK) ((BLK).length_) /** String not empty ? **/ #define StringNotEmpty(BLK) ( StringLength(BLK) > 0 ) /** String capacity **/ #define StringCapacity(BLK) ((BLK).capacity_) /** Subcharacter **/ #define StringSub(BLK, POS) ( StringBuff(BLK)[POS] ) /** Subcharacter (read/write) **/ #define StringSubRW(BLK, POS) ( StringBuffRW(BLK)[POS] ) /** Subcharacter (read/write) **/ #define StringSubRW(BLK, POS) ( StringBuffRW(BLK)[POS] ) /** Right subcharacter **/ #define StringRight(BLK, POS) ( StringBuff(BLK)[StringLength(BLK) - POS] ) /** Right subcharacter (read/write) **/ #define StringRightRW(BLK, POS) ( StringBuffRW(BLK)[StringLength(BLK) - POS] ) /** Remove the utter right character from the string. **/ #define StringPopRight(BLK) do { \ StringBuffRW(BLK)[--StringLength(BLK)] = '\0'; \ } while(0) /** Ensure the string is large enough for exactly CAPACITY bytes overall (including \0). **/ #define StringRoomTotal(BLK, CAPACITY) do { \ const size_t capacity_ = (size_t) (CAPACITY); \ while ((BLK).capacity_ < capacity_) { \ if ((BLK).capacity_ < 16) { \ (BLK).capacity_ = 16; \ } else { \ (BLK).capacity_ *= 2; \ } \ (BLK).buffer_ = STRING_REALLOC((BLK).buffer_, (BLK).capacity_); \ STRING_ASSERT((BLK).buffer_ != NULL); \ } \ } while(0) /** Ensure the string is large enough for exactly SIZE more characters (not including \0). **/ #define StringRoom(BLK, SIZE) StringRoomTotal(BLK, StringLength(BLK) + (SIZE) + 1) /** Return the RW buffer for a strcat() operation of at most SIZE characters. **/ #define StringBuffN(BLK, SIZE) StringBuffN_(&(BLK), SIZE) HTS_STATIC char *StringBuffN_(String * blk, int size) { StringRoom(*blk, size); return StringBuffRW(*blk); } /** Initialize a string. **/ #define StringInit(BLK) do { \ (BLK).buffer_ = NULL; \ (BLK).capacity_ = 0; \ (BLK).length_ = 0; \ } while(0) /** Clear a string (set its length to 0) **/ #define StringClear(BLK) do { \ (BLK).length_ = 0; \ StringRoom(BLK, 0); \ (BLK).buffer_[0] = '\0'; \ } while(0) /** Set the length of a string to 'SIZE'. If SIZE is negative, check the size using strlen(). **/ #define StringSetLength(BLK, SIZE) do { \ if (SIZE >= 0) { \ (BLK).length_ = SIZE; \ } else { \ (BLK).length_ = strlen((BLK).buffer_); \ } \ } while(0) /** Free a string (release memory) **/ #define StringFree(BLK) do { \ if ((BLK).buffer_ != NULL) { \ STRING_FREE((BLK).buffer_); \ (BLK).buffer_ = NULL; \ } \ (BLK).capacity_ = 0; \ (BLK).length_ = 0; \ } while(0) /** Assign an allocated pointer to a a string. The pointer _MUST_ be compatible with STRING_REALLOC() and STRING_FREE() **/ #define StringSetBuffer(BLK, STR) do { \ size_t len__ = strlen( STR ); \ StringFree(BLK); \ (BLK).buffer_ = ( STR ); \ (BLK).capacity_ = len__; \ (BLK).length_ = len__; \ } while(0) /** Append a memory block to a string **/ #define StringMemcat(BLK, STR, SIZE) do { \ const char* str_mc_ = (STR); \ const size_t size_mc_ = (size_t) (SIZE); \ StringRoom(BLK, size_mc_); \ if (size_mc_ > 0) { \ memcpy((BLK).buffer_ + (BLK).length_, str_mc_, size_mc_); \ (BLK).length_ += size_mc_; \ } \ *((BLK).buffer_ + (BLK).length_) = '\0'; \ } while(0) /** Copy a memory block to a string **/ #define StringMemcpy(BLK, STR, SIZE) do { \ (BLK).length_ = 0; \ StringMemcat(BLK, STR, SIZE); \ } while(0) /** Add a character **/ #define StringAddchar(BLK, c) do { \ String * const s__ = &(BLK); \ char c__ = (c); \ StringRoom(*s__, 1); \ StringBuffRW(*s__)[StringLength(*s__)++] = c__; \ StringBuffRW(*s__)[StringLength(*s__) ] = 0; \ } while(0) /** Acquire a string ; it's the client's responsability to free() it **/ HTS_STATIC char *StringAcquire(String * blk) { char *buff = StringBuffRW(*blk); StringBuffRW(*blk) = NULL; StringCapacity(*blk) = 0; StringLength(*blk) = 0; return buff; } /** Clone a string. **/ HTS_STATIC String StringDup(const String * src) { String s = STRING_EMPTY; StringMemcat(s, StringBuff(*src), StringLength(*src)); return s; } /** Attach a string using a pointer. **/ HTS_STATIC void StringAttach(String * blk, char **str) { StringFree(*blk); if (str != NULL && *str != NULL) { StringBuffRW(*blk) = *str; StringCapacity(*blk) = StringLength(*blk) = strlen(StringBuff(*blk)); *str = NULL; } } /** Append a string to another one. **/ #define StringCat(BLK, STR) do { \ const char *const str__ = ( STR ); \ if (str__ != NULL) { \ const size_t size__ = strlen(str__); \ StringMemcat(BLK, str__, size__); \ } \ } while(0) #define StringCatN(BLK, STR, SIZE) do { \ const char *str__ = ( STR ); \ if (str__ != NULL) { \ size_t size__ = strlen(str__); \ if (size__ > (SIZE)) { \ size__ = (SIZE); \ } \ StringMemcat(BLK, str__, size__); \ } \ } while(0) #define StringCopyN(BLK, STR, SIZE) do { \ const char *str__ = ( STR ); \ const size_t usize__ = (SIZE); \ (BLK).length_ = 0; \ if (str__ != NULL) { \ size_t size__ = strlen(str__); \ if (size__ > usize__ ) { \ size__ = usize__; \ } \ StringMemcat(BLK, str__, size__); \ } else { \ StringClear(BLK); \ } \ } while(0) #define StringCopyS(blk, blk2) StringCopyN(blk, (blk2).buffer_, (blk2).length_) /** Copy a string to another one. **/ #define StringCopy(BLK, STR) do { \ const char *str__ = ( STR ); \ if (str__ != NULL) { \ size_t size__ = strlen(str__); \ StringMemcpy(BLK, str__, size__); \ } else { \ StringClear(BLK); \ } \ } while(0) /** Copy a (potentially overlapping) string to another one. **/ #define StringCopyOverlapped(BLK, STR) do { \ String s__ = STRING_EMPTY; \ StringCopy(s__, STR); \ StringCopyS(BLK, s__); \ StringFree(s__); \ } while(0) #endif httrack-3.49.5/src/htszlib.h0000644000175000017500000000347114336470674012637 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Unpacking subroutines using Jean-loup Gailly's Zlib */ /* for http compressed data */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTS_DEFZLIB #define HTS_DEFZLIB /* ZLib */ #include "zlib.h" //#include "zutil.h" /* MiniZip */ #include "minizip/zip.h" #include "minizip/unzip.h" #include "minizip/mztools.h" /* Library internal definictions */ #ifdef HTS_INTERNAL_BYTECODE extern int hts_zunpack(char *filename, char *newfile); extern int hts_extract_meta(const char *path); extern const char *hts_get_zerror(int err); #endif #endif httrack-3.49.5/src/htswrap.h0000644000175000017500000000401014336470674012636 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: httrack.c subroutines: */ /* wrapper system (for shell */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTSWRAP_DEFH #define HTSWRAP_DEFH /* Library internal definictions */ #ifdef HTS_INTERNAL_BYTECODE #include "htsglobal.h" #include "coucal.h" /* Forward definitions */ #ifndef HTS_DEF_FWSTRUCT_httrackp #define HTS_DEF_FWSTRUCT_httrackp typedef struct httrackp httrackp; #endif #ifdef __cplusplus extern "C" { #endif HTSEXT_API int htswrap_init(void); // LEGACY HTSEXT_API int htswrap_free(void); // LEGACY #ifdef __cplusplus } #endif //HTSEXT_API int htswrap_add(httrackp * opt, const char *name, void *fct); //HTSEXT_API uintptr_t htswrap_read(httrackp * opt, const char *name); #endif #endif httrack-3.49.5/src/htswizard.h0000644000175000017500000000430714336470674013176 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: httrack.c subroutines: */ /* wizard system (accept/refuse links) */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTSWIZARD_DEFH #define HTSWIZARD_DEFH /* Library internal definictions */ #ifdef HTS_INTERNAL_BYTECODE #include "htsglobal.h" /* Forward definitions */ #ifndef HTS_DEF_FWSTRUCT_httrackp #define HTS_DEF_FWSTRUCT_httrackp typedef struct httrackp httrackp; #endif #ifndef HTS_DEF_FWSTRUCT_lien_url #define HTS_DEF_FWSTRUCT_lien_url typedef struct lien_url lien_url; #endif int hts_acceptlink(httrackp * opt, int ptr, const char *adr, const char *fil, const char *tag, const char *attribute, int *set_prio_to_0, int *just_test_it); int hts_testlinksize(httrackp * opt, const char *adr, const char *fil, LLint size); int hts_acceptmime(httrackp * opt, int ptr, const char *adr, const char *fil, const char *mime); #endif #endif httrack-3.49.5/src/htstools.h0000644000175000017500000001055314336470674013036 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: httrack.c subroutines: */ /* various tools (filename analyzing ..) */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTSTOOLS_DEFH #define HTSTOOLS_DEFH /* specific definitions */ #include "htsglobal.h" /* Forward definitions */ #ifndef HTS_DEF_FWSTRUCT_httrackp #define HTS_DEF_FWSTRUCT_httrackp typedef struct httrackp httrackp; #endif #ifndef HTS_DEF_FWSTRUCT_find_handle_struct #define HTS_DEF_FWSTRUCT_find_handle_struct typedef struct find_handle_struct find_handle_struct; typedef find_handle_struct *find_handle; #endif #ifndef HTS_DEF_FWSTRUCT_lien_adrfil #define HTS_DEF_FWSTRUCT_lien_adrfil typedef struct lien_adrfil lien_adrfil; #endif #ifndef HTS_DEF_FWSTRUCT_lien_adrfilsave #define HTS_DEF_FWSTRUCT_lien_adrfilsave typedef struct lien_adrfilsave lien_adrfilsave; #endif /* Library internal definictions */ #ifdef HTS_INTERNAL_BYTECODE int ident_url_relatif(const char *lien, const char *origin_adr, const char *origin_fil, lien_adrfil* const adrfil); int lienrelatif(char *s, const char *link, const char *curr); int link_has_authority(const char *lien); int link_has_authorization(const char *lien); void long_to_83(int mode, char *n83, char *save); void longfile_to_83(int mode, char *n83, char *save); HTS_INLINE int __rech_tageq(const char *adr, const char *s); HTS_INLINE int __rech_tageqbegdigits(const char *adr, const char *s); HTS_INLINE int rech_tageq_all(const char *adr, const char *s); int hts_template_format(FILE *const out, const char *format, ...); int hts_template_format_str(char *buffer, size_t size, const char *format, ...); #define rech_tageq(adr,s) \ ( \ ( (*((adr)-1)=='<') || (is_space(*((adr)-1))) ) ? \ ( \ (streql(*(adr),*(s))) ? \ (__rech_tageq((adr),(s))) \ : 0 \ ) \ : 0\ ) #define rech_tageqbegdigits(adr,s) \ ( \ ( (*((adr)-1)=='<') || (is_space(*((adr)-1))) ) ? \ ( \ (streql(*(adr),*(s))) ? \ (__rech_tageqbegdigits((adr),(s))) \ : 0 \ ) \ : 0\ ) //HTS_INLINE int rech_tageq(const char* adr,const char* s); HTS_INLINE int rech_sampletag(const char *adr, const char *s); HTS_INLINE int rech_endtoken(const char *adr, const char **start); HTS_INLINE int check_tag(const char *from, const char *tag); int verif_backblue(httrackp * opt, const char *base); int verif_external(httrackp * opt, int nb, int test); int istoobig(httrackp * opt, LLint size, LLint maxhtml, LLint maxnhtml, char *type); HTSEXT_API int hts_buildtopindex(httrackp * opt, const char *path, const char *binpath); // Portable directory find functions // Directory find functions HTSEXT_API find_handle hts_findfirst(char *path); HTSEXT_API int hts_findnext(find_handle find); HTSEXT_API int hts_findclose(find_handle find); // HTSEXT_API char *hts_findgetname(find_handle find); HTSEXT_API int hts_findgetsize(find_handle find); HTSEXT_API int hts_findisdir(find_handle find); HTSEXT_API int hts_findisfile(find_handle find); HTSEXT_API int hts_findissystem(find_handle find); #endif #endif httrack-3.49.5/src/htsthread.h0000644000175000017500000000461414336470674013146 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Threads */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTS_DEFTHREAD #define HTS_DEFTHREAD #include "htsglobal.h" #ifndef _WIN32 #include #endif #ifdef _WIN32 #include "windows.h" #endif #ifndef USE_BEGINTHREAD #error needs USE_BEGINTHREAD #endif /* Forward definition */ #ifndef HTS_DEF_FWSTRUCT_htsmutex_s #define HTS_DEF_FWSTRUCT_htsmutex_s typedef struct htsmutex_s htsmutex_s, *htsmutex; #endif #define HTSMUTEX_INIT NULL #ifdef _WIN32 struct htsmutex_s { HANDLE handle; }; #else /* #ifdef _WIN32 */ struct htsmutex_s { pthread_mutex_t handle; }; #endif /* #ifdef _WIN32 */ /* Library internal definictions */ HTSEXT_API int hts_newthread(void (*fun) (void *arg), void *arg); HTSEXT_API void htsthread_wait_n(int n_wait); /* Locking functions */ HTSEXT_API void hts_mutexinit(htsmutex * mutex); HTSEXT_API void hts_mutexfree(htsmutex * mutex); HTSEXT_API void hts_mutexlock(htsmutex * mutex); HTSEXT_API void hts_mutexrelease(htsmutex * mutex); #ifdef HTS_INTERNAL_BYTECODE /* Thread initialization */ HTSEXT_API void htsthread_init(void); HTSEXT_API void htsthread_uninit(void); #endif #endif httrack-3.49.5/src/htsrobots.h0000644000175000017500000000372414336470674013210 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: httrack.c subroutines: */ /* robots.txt (website robot file) */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTSROBOTS_DEFH #define HTSROBOTS_DEFH // robots wizard #ifndef HTS_DEF_FWSTRUCT_robots_wizard #define HTS_DEF_FWSTRUCT_robots_wizard typedef struct robots_wizard robots_wizard; #endif struct robots_wizard { char adr[128]; char token[4096]; struct robots_wizard *next; }; /* Library internal definictions */ #ifdef HTS_INTERNAL_BYTECODE int checkrobots(robots_wizard * robots, const char *adr, const char *fil); void checkrobots_free(robots_wizard * robots); int checkrobots_set(robots_wizard * robots, const char *adr, const char *data); #endif #endif httrack-3.49.5/src/htsopt.h0000644000175000017500000005564414336470674012512 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: HTTrack parameters block */ /* Called by httrack.h and some other files */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTTRACK_DEFOPT #define HTTRACK_DEFOPT #include #include "htsglobal.h" #include "htsnet.h" #ifdef __cplusplus extern "C" { #endif /* Forward definitions */ #ifndef HTS_DEF_FWSTRUCT_t_hts_htmlcheck_callbacks #define HTS_DEF_FWSTRUCT_t_hts_htmlcheck_callbacks typedef struct t_hts_htmlcheck_callbacks t_hts_htmlcheck_callbacks; #endif #ifndef HTS_DEF_FWSTRUCT_t_dnscache #define HTS_DEF_FWSTRUCT_t_dnscache typedef struct t_dnscache t_dnscache; #endif #ifndef HTS_DEF_FWSTRUCT_hash_struct #define HTS_DEF_FWSTRUCT_hash_struct typedef struct hash_struct hash_struct; #endif #ifndef HTS_DEF_FWSTRUCT_robots_wizard #define HTS_DEF_FWSTRUCT_robots_wizard typedef struct robots_wizard robots_wizard; #endif #ifndef HTS_DEF_FWSTRUCT_t_cookie #define HTS_DEF_FWSTRUCT_t_cookie typedef struct t_cookie t_cookie; #endif /** Forward definitions **/ #ifndef HTS_DEF_FWSTRUCT_String #define HTS_DEF_FWSTRUCT_String typedef struct String String; #endif #ifndef HTS_DEF_STRUCT_String #define HTS_DEF_STRUCT_String struct String { char *buffer_; size_t length_; size_t capacity_; }; #endif /* Defines */ #define CATBUFF_SIZE (STRING_SIZE*2*2) #define STRING_SIZE 2048 /* Proxy structure */ #ifndef HTS_DEF_FWSTRUCT_t_proxy #define HTS_DEF_FWSTRUCT_t_proxy typedef struct t_proxy t_proxy; #endif struct t_proxy { int active; String name; int port; String bindhost; // bind this host }; /* Structure utile pour copier en bloc les paramètres */ #ifndef HTS_DEF_FWSTRUCT_htsfilters #define HTS_DEF_FWSTRUCT_htsfilters typedef struct htsfilters htsfilters; #endif struct htsfilters { char ***filters; int *filptr; //int* filter_max; }; /* User callbacks chain */ typedef int (*htscallbacksfncptr) (void); typedef struct htscallbacks htscallbacks; struct htscallbacks { void *moduleHandle; htscallbacksfncptr exitFnc; htscallbacks *next; }; /* filenote() internal file structure */ #ifndef HTS_DEF_FWSTRUCT_filenote_strc #define HTS_DEF_FWSTRUCT_filenote_strc typedef struct filenote_strc filenote_strc; #endif struct filenote_strc { FILE *lst; char path[STRING_SIZE * 2]; }; /* concat() functions */ #ifndef HTS_DEF_FWSTRUCT_concat_strc #define HTS_DEF_FWSTRUCT_concat_strc typedef struct concat_strc concat_strc; #endif struct concat_strc { int index; char buff[16][STRING_SIZE * 2 * 2]; }; /* int2 functions */ #ifndef HTS_DEF_FWSTRUCT_strc_int2bytes2 #define HTS_DEF_FWSTRUCT_strc_int2bytes2 typedef struct strc_int2bytes2 strc_int2bytes2; #endif struct strc_int2bytes2 { char catbuff[CATBUFF_SIZE]; char buff1[256]; char buff2[32]; char *buffadr[2]; }; /* cmd callback */ #ifndef HTS_DEF_FWSTRUCT_usercommand_strc #define HTS_DEF_FWSTRUCT_usercommand_strc typedef struct usercommand_strc usercommand_strc; #endif struct usercommand_strc { int exe; char cmd[2048]; }; /* error logging */ #ifndef HTS_DEF_FWSTRUCT_fspc_strc #define HTS_DEF_FWSTRUCT_fspc_strc typedef struct fspc_strc fspc_strc; #endif struct fspc_strc { int error; int warning; int info; }; /* lien_url */ #ifndef HTS_DEF_FWSTRUCT_lien_url #define HTS_DEF_FWSTRUCT_lien_url typedef struct lien_url lien_url; #endif #ifndef HTS_DEF_DEFSTRUCT_hts_log_type #define HTS_DEF_DEFSTRUCT_hts_log_type typedef enum hts_log_type { LOG_PANIC, LOG_ERROR, LOG_WARNING, LOG_NOTICE, LOG_INFO, LOG_DEBUG, LOG_TRACE, LOG_ERRNO = 1 << 8 } hts_log_type; #endif /* Structure état du miroir */ #ifndef HTS_DEF_FWSTRUCT_htsoptstatecancel #define HTS_DEF_FWSTRUCT_htsoptstatecancel typedef struct htsoptstatecancel htsoptstatecancel; #endif struct htsoptstatecancel { char *url; htsoptstatecancel *next; }; /* Mutexes */ #ifndef HTS_DEF_FWSTRUCT_htsmutex_s #define HTS_DEF_FWSTRUCT_htsmutex_s typedef struct htsmutex_s htsmutex_s, *htsmutex; #endif /* Hashtables */ #ifndef HTS_DEF_FWSTRUCT_struct_coucal #define HTS_DEF_FWSTRUCT_struct_coucal typedef struct struct_coucal struct_coucal, *coucal; #endif /* Structure état du miroir */ #ifndef HTS_DEF_FWSTRUCT_htsoptstate #define HTS_DEF_FWSTRUCT_htsoptstate typedef struct htsoptstate htsoptstate; #endif struct htsoptstate { htsmutex lock; /* 3.41 */ /* */ int stop; int exit_xh; int back_add_stats; /* */ int mimehtml_created; String mimemid; FILE *mimefp; int delayedId; /* */ filenote_strc strc; /* Functions context (avoir thread variables!) */ htscallbacks callbacks; concat_strc concat; usercommand_strc usercmd; fspc_strc fspc; char *userhttptype; int verif_backblue_done; int verif_external_status; t_dnscache *dns_cache; int dns_cache_nthreads; /* HTML parsing state */ char _hts_errmsg[HTS_CDLMAXSIZE + 256]; int _hts_in_html_parsing; int _hts_in_html_done; int _hts_in_html_poll; int _hts_setpause; int _hts_in_mirror; char **_hts_addurl; int _hts_cancel; htsoptstatecancel *cancel; /* 3.41 */ char HTbuff[2048]; unsigned int debug_state; unsigned int tmpnameid; /* 3.41 */ int is_ended; /* 3.48-14 */ }; /* Library handles */ #ifndef HTS_DEF_FWSTRUCT_htslibhandles #define HTS_DEF_FWSTRUCT_htslibhandles typedef struct htslibhandles htslibhandles; #endif #ifndef HTS_DEF_FWSTRUCT_htslibhandle #define HTS_DEF_FWSTRUCT_htslibhandle typedef struct htslibhandle htslibhandle; #endif struct htslibhandle { char *moduleName; void *handle; }; struct htslibhandles { int count; htslibhandle *handles; }; /* Javascript parser flags */ typedef enum htsparsejava_flags { HTSPARSE_NONE = 0, // don't parse HTSPARSE_DEFAULT = 1, // parse default (all) HTSPARSE_NO_CLASS = 2, // don't parse .java HTSPARSE_NO_JAVASCRIPT = 4, // don't parse .js HTSPARSE_NO_AGGRESSIVE = 8 // don't aggressively parse .js or .java } htsparsejava_flags; #ifndef HTS_DEF_FWSTRUCT_lien_buffers #define HTS_DEF_FWSTRUCT_lien_buffers typedef struct lien_buffers lien_buffers; #endif // paramètres httrack (options) #ifndef HTS_DEF_FWSTRUCT_httrackp #define HTS_DEF_FWSTRUCT_httrackp typedef struct httrackp httrackp; #endif struct httrackp { size_t size_httrackp; // size of this structure /* */ int wizard; // wizard aucun/grand/petit int flush; // fflush sur les fichiers log int travel; // type de déplacements (same domain etc) int seeker; // up & down int depth; // nombre de niveaux de récursion int extdepth; // nombre de niveaux de récursion à l'éxtérieur int urlmode; // liens relatifs etc int no_type_change; // do not change file type according to MIME int debug; // mode débug log int getmode; // sauver html, images.. FILE *log; // fichier log FILE *errlog; // et erreur LLint maxsite; // taille max site LLint maxfile_nonhtml; // taille max non html LLint maxfile_html; // taille max html int maxsoc; // nbre sockets LLint fragment; // fragmentation d'un site int nearlink; // prendre les images/data proche d'une page mais à l'extérieur int makeindex; // faire un index int kindex; // et un index 'keyword' int delete_old; // effacer anciens fichiers int timeout; // nombre de secondes de timeout int rateout; // nombre d'octets minium pour le transfert int maxtime; // temps max en secondes int maxrate; // taux de transfert max float maxconn; // nombre max de connexions/s int waittime; // démarrage programmé int cache; // génération d'un cache //int aff_progress; // barre de progression int shell; // gestion d'un shell par pipe stdin/stdout t_proxy proxy; // configuration du proxy int savename_83; // conversion 8-3 pour les noms de fichiers int savename_type; // type de noms: structure originale/html-images en un seul niveau String savename_userdef; // structure userdef (ex: %h%p/%n%q.%t) int savename_delayed; // delayed type check int delayed_cached; // delayed type check can be cached to speedup updates int mimehtml; // MIME-html int user_agent_send; // user agent (ex: httrack/1.0 [sun]) String user_agent; // String referer; // referer String from; // from String path_log; // chemin pour cache et log String path_html; // chemin pour miroir String path_html_utf8; // chemin pour miroir, UTF-8 String path_bin; // chemin pour templates int retry; // nombre d'essais supplémentaires en cas d'échec int makestat; // mettre à jour un fichier log de statistiques de transfert int maketrack; // mettre à jour un fichier log de statistiques d'opérations int parsejava; // parsing des classes java pour récupérer les class, gif & cie ; see htsparsejava_flags int hostcontrol; // abandon d'un host trop lent etc. int errpage; // générer une page d'erreur en cas de 404 etc. int check_type; // si type inconnu (cgi,asp,/) alors tester lien (et gérer moved éventuellement) int all_in_cache; // tout mettre en cache! int robots; // traitement des robots int external; // pages externes->pages d'erreur int passprivacy; // pas de mot de pass dans les liens externes? int includequery; // include la query-string int mirror_first_page; // miroir des liens String sys_com; // commande système int sys_com_exec; // executer commande int accept_cookie; // gestion des cookies t_cookie *cookie; int http10; // forcer http 1.0 int nokeepalive; // pas de keep-alive int nocompression; // pas de compression int sizehack; // forcer réponse "mis à jour" si taille identique int urlhack; // force "url normalization" to avoid loops int tolerant; // accepter content-length incorrect int parseall; // essayer de tout parser (tags inconnus contenant des liens, par exemple) int parsedebug; // débugger parser (debug!) int norecatch; // ne pas reprendre les fichiers effacés localement par l'utilisateur int verbosedisplay; // animation textuelle String footer; // ligne d'infos int maxcache; // maximum en mémoire au niveau du cache (backing) //int maxcache_anticipate; // maximum de liens à anticiper (majorant) int ftp_proxy; // proxy http pour ftp String filelist; // fichier liste URL à inclure String urllist; // fichier liste de filtres à inclure htsfilters filters; // contient les pointeurs pour les filtres hash_struct *hash; // hash structure lien_url **liens; // links int lien_tot; // top index of "links" heap (always out-of-range) lien_buffers *liensbuf; // links buffers robots_wizard *robotsptr; // robots ptr String lang_iso; // en, fr .. String accept; // Accept: String headers; // Additional headers String mimedefs; // ext1=mimetype1\next2=mimetype2.. String mod_blacklist; // (3.41) int convert_utf8; // filenames UTF-8 conversion (3.46) // int maxlink; // nombre max de liens int maxfilter; // nombre max de filtres // const char *exec; // adresse du nom de l'éxecutable // int quiet; // poser des questions autres que wizard? int keyboard; // vérifier stdin int bypass_limits; // bypass built-in limits int background_on_suspend; // background process on suspend signal // int is_update; // c'est une update (afficher "File updated...") int dir_topindex; // reconstruire top index par la suite // // callbacks t_hts_htmlcheck_callbacks *callbacks_fun; // store library handles htslibhandles libHandles; // htsoptstate state; // state }; // stats for httrack #ifndef HTS_DEF_FWSTRUCT_hts_stat_struct #define HTS_DEF_FWSTRUCT_hts_stat_struct typedef struct hts_stat_struct hts_stat_struct; #endif struct hts_stat_struct { LLint HTS_TOTAL_RECV; // flux entrant reçu LLint stat_bytes; // octets écrits sur disque // int HTS_TOTAL_RECV_STATE; // status: 0 tout va bien 1: ralentir un peu 2: ralentir 3: beaucoup TStamp stat_timestart; // départ // LLint total_packed; // flux entrant compressé reçu LLint total_unpacked; // flux entrant compressé reçu int total_packedfiles; // fichiers compressés // TStamp istat_timestart[2]; // départ pour calcul instantanné LLint istat_bytes[2]; // calcul pour instantanné TStamp istat_reference01; // top départ donné par #0 à #1 int istat_idlasttimer; // id du timer qui a récemment donné une stat // int stat_files; // nombre de fichiers écrits int stat_updated_files; // nombre de fichiers mis à jour int stat_background; // nombre de fichiers écrits en arrière plan // int stat_nrequests; // nombre de requêtes sur socket int stat_sockid; // nombre de sockets allouées au total int stat_nsocket; // nombre de sockets int stat_errors; // nombre d'erreurs int stat_errors_front; // idem, mais au tout premier niveau int stat_warnings; // '' warnings int stat_infos; // '' infos int nbk; // fichiers anticipés en arrière plan et terminés LLint nb; // données transférées actuellement (estimation) // LLint rate; // TStamp last_connect; // last connect() call TStamp last_request; // last request issued }; // structure pour paramètres supplémentaires lors de la requête #ifndef HTS_DEF_FWSTRUCT_htsrequest_proxy #define HTS_DEF_FWSTRUCT_htsrequest_proxy typedef struct htsrequest_proxy htsrequest_proxy; #endif struct htsrequest_proxy { int active; const char* name; int port; const char* bindhost; // bind this host }; #ifndef HTS_DEF_FWSTRUCT_htsrequest #define HTS_DEF_FWSTRUCT_htsrequest typedef struct htsrequest htsrequest; #endif struct htsrequest { short int user_agent_send; // user agent (ex: httrack/1.0 [sun]) short int http11; // l'en tête peut (doit) être signé HTTP/1.1 et non HTTP/1.0 short int nokeepalive; // pas de keep-alive short int range_used; // Range utilisé short int nocompression; // Pas de compression short int flush_garbage; // recycled const char* user_agent; const char* referer; const char* from; const char* lang_iso; const char* accept; const char* headers; htsrequest_proxy proxy; // proxy }; // structure pour retour d'une connexion/prise d'en tête #ifndef HTS_DEF_FWSTRUCT_htsblk #define HTS_DEF_FWSTRUCT_htsblk typedef struct htsblk htsblk; #endif struct htsblk { int statuscode; // status-code, -1=erreur, 200=OK,201=..etc (cf RFC1945) short int notmodified; // page ou fichier NON modifié (transféré) short int is_write; // sortie sur disque (out) ou en mémoire (adr) short int is_chunk; // mode chunk short int compressed; // compressé? short int empty; // vide? short int keep_alive; // Keep-Alive? short int keep_alive_trailers; // ..with trailers extension int keep_alive_t; // KA timeout int keep_alive_max; // KA number of requests char *adr; // adresse du bloc de mémoire, NULL=vide char *headers; // adresse des en têtes si présents FILE *out; // écriture directe sur disque (si is_write=1) LLint size; // taille fichier char msg[80]; // message éventuel si échec ("\0"=non précisé) char contenttype[64]; // content-type ("text/html" par exemple) char charset[64]; // charset ("iso-8859-1" par exemple) char contentencoding[64]; // content-encoding ("gzip" par exemple) char *location; // on copie dedans éventuellement la véritable 'location' LLint totalsize; // taille totale à télécharger (-1=inconnue) short int is_file; // ce n'est pas une socket mais un descripteur de fichier si 1 T_SOC soc; // ID socket SOCaddr address; // IP address int address_size; // IP address structure length (unused internally) FILE *fp; // fichier pour file:// #if HTS_USEOPENSSL short int ssl; // is this connection a SSL one? (https) // BIO* ssl_soc; // SSL structure SSL *ssl_con; // connection structure #endif char lastmodified[64]; // Last-Modified char etag[256]; // Etag char cdispo[256]; // Content-Disposition coupé LLint crange; // Content-Range LLint crange_start; // Content-Range LLint crange_end; // Content-Range int debugid; // debug connection /* */ htsrequest req; // paramètres pour la requête /*char digest[32+2]; // digest md5 généré par le moteur ("" si non généré) */ }; // structure d'un lien #ifndef HTS_DEF_FWSTRUCT_lien_url #define HTS_DEF_FWSTRUCT_lien_url typedef struct lien_url lien_url; #endif struct lien_url { char *adr; // adresse char *fil; // nom du fichier distant char *sav; // nom à sauver sur disque (avec chemin éventuel) char *cod; // chemin codebase éventuel si classe java char *former_adr; // adresse initiale (avant éventuel moved), peut être nulle char *former_fil; // nom du fichier distant initial (avant éventuel moved), peut être nul int premier; // pointeur sur le premier lien qui a donné lieu aux autres liens du domaine int precedent; // pointeur sur le lien qui a donné lieu à ce lien précis int depth; // profondeur autorisée lien ; >0 forte 0=faible int pass2; // traiter après les autres, seconde passe. si == -1, lien traité en background char link_import; // lien importé à la suite d'un moved - ne pas appliquer les règles classiques up/down //int moved; // pointeur sur moved int retry; // nombre de retry restants int testmode; // mode test uniquement, envoyer juste un head! }; // chargement de fichiers en 'arrière plan' #ifndef HTS_DEF_FWSTRUCT_lien_back #define HTS_DEF_FWSTRUCT_lien_back typedef struct lien_back lien_back; #endif struct lien_back { #if DEBUG_CHECKINT char magic; #endif char url_adr[HTS_URLMAXSIZE * 2]; // adresse char url_fil[HTS_URLMAXSIZE * 2]; // nom du fichier distant char url_sav[HTS_URLMAXSIZE * 2]; // nom à sauver sur disque (avec chemin éventuel) char referer_adr[HTS_URLMAXSIZE * 2]; // adresse host page referer char referer_fil[HTS_URLMAXSIZE * 2]; // fichier page referer char location_buffer[HTS_URLMAXSIZE * 2]; // "location" en cas de "moved" (302,..) char *tmpfile; // nom à sauver temporairement (compressé) char tmpfile_buffer[HTS_URLMAXSIZE * 2]; // buffer pour le nom à sauver temporairement char send_too[1024]; // données à envoyer en même temps que le header int status; // status (-1=non utilisé, 0: prêt, >0: opération en cours) int locked; // locked (to be used soon) int testmode; // mode de test int timeout; // gérer des timeouts? (!=0 : nombre de secondes) TStamp timeout_refresh; // si oui, time refresh int rateout; // timeout refresh? (!=0 : taux minimum toléré en octets/s) TStamp rateout_time; // si oui, date de départ LLint maxfile_nonhtml; // taille max d'un fichier non html LLint maxfile_html; // idem pour un ficheir html htsblk r; // structure htsblk de chaque objet en background int is_update; // mode update int head_request; // requète HEAD? LLint range_req_size; // range utilisé TStamp ka_time_start; // refresh time for KA // int http11; // L'en tête doit être signé HTTP/1.1 et non HTTP/1.0 int is_chunk; // chunk? char *chunk_adr; // adresse chunk en cours de chargement LLint chunk_size; // taille chunk en cours de chargement LLint chunk_blocksize; // taille data declaree par le chunk LLint compressed_size; // taille compressés (stats uniquement) // //int links_index; // to access liens[links_index] // char info[256]; // éventuel status pour le ftp int stop_ftp; // flag stop pour ftp int finalized; // finalized (optim memory) int early_add; // was added before link heap saw it #if DEBUG_CHECKINT char magic2; #endif }; #ifdef __cplusplus } #endif #endif httrack-3.49.5/src/htsnet.h0000644000175000017500000001764014336470674012470 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Net definitions */ /* Used in .c files that needs connect() functions and so */ /* Note: includes htsbasenet.h */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTS_DEFNETH #define HTS_DEFNETH /* basic net definitions */ #include "htsglobal.h" #include "htsbasenet.h" #include "htssafe.h" #include #include #ifdef _WIN32 // pour read #include // pour FindFirstFile #include typedef USHORT in_port_t; typedef ADDRESS_FAMILY sa_family_t; #else //typedef int T_SOC; #define INVALID_SOCKET -1 #include #include #include #include #include /* Force for sun env. */ #ifndef BSD_COMP #define BSD_COMP #endif #include /* gethostname & co */ #ifndef _WIN32 #include #endif /* inet_addr */ #include // pas la peine normalement.. #ifndef HTS_DO_NOT_REDEFINE_in_addr_t typedef unsigned long in_addr_t; #endif #endif #ifdef __cplusplus extern "C" { #endif /* Ipv4 structures */ #if HTS_INET6 != 0 typedef struct in6_addr INaddr; #else typedef struct in_addr INaddr; #endif /* This should handle all cases */ #ifndef HTS_DEF_FWSTRUCT_SOCaddr #define HTS_DEF_FWSTRUCT_SOCaddr typedef struct SOCaddr SOCaddr; #endif struct SOCaddr { union { /* Generic version, for network functions such as getnameinfo() */ struct sockaddr sa; /* IPv4 */ struct sockaddr_in in; #if HTS_INET6 != 0 /* IPv6 */ struct sockaddr_in6 in6; #endif } m_addr; }; static HTS_INLINE HTS_UNUSED in_port_t* SOCaddr_sinport_(SOCaddr *const addr, const char *file, const int line) { assertf_(addr != NULL, file, line); switch(addr->m_addr.sa.sa_family) { case AF_INET: return &addr->m_addr.in.sin_port; break; #if HTS_INET6 != 0 case AF_INET6: return &addr->m_addr.in6.sin6_port; break; #endif default: assertf_(! "invalid structure", file, line); return 0; break; } } static HTS_INLINE HTS_UNUSED socklen_t SOCaddr_size_(const SOCaddr*const addr, const char *file, const int line) { assertf_(addr != NULL, file, line); switch(addr->m_addr.sa.sa_family) { case AF_INET: return sizeof(addr->m_addr.in); break; #if HTS_INET6 != 0 case AF_INET6: return sizeof(addr->m_addr.in6); break; #endif default: return 0; break; } } static HTS_INLINE HTS_UNUSED void SOCaddr_clear_(SOCaddr*const addr, const char *file, const int line) { assertf_(addr != NULL, file, line); addr->m_addr.sa.sa_family = AF_UNSPEC; } /* Ipv4/6 structure members */ #define SOCaddr_sinfamily(server) ((server).m_addr.sa.sa_family) #define SOCaddr_sinport(server) (*SOCaddr_sinport_(&(server), __FILE__, __LINE__)) #define SOCaddr_size(server) (SOCaddr_size_(&(server), __FILE__, __LINE__)) #define SOCaddr_is_valid(server) (SOCaddr_size_(&(server), __FILE__, __LINE__) != 0 ) #define SOCaddr_clear(server) SOCaddr_clear_(&(server), __FILE__, __LINE__) #define SOCaddr_sockaddr(server) ((server).m_addr.sa) #define SOCaddr_capacity(server) sizeof((server).m_addr) /* AF_xx */ #if HTS_INET6 != 0 #define AFinet AF_INET6 #else #define AFinet AF_INET #endif /* Set port to sockaddr structure */ #define SOCaddr_initport(server, port) do { \ SOCaddr_sinport(server) = htons((in_port_t) (port)); \ } while(0) static HTS_INLINE HTS_UNUSED socklen_t SOCaddr_initany_(SOCaddr*const addr, const char *file, const int line) { assertf_(addr != NULL, file, line); memset(&addr->m_addr.in, 0, sizeof(addr->m_addr.in)); addr->m_addr.in.sin_family = AF_INET; return SOCaddr_size_(addr, file, line); } #define SOCaddr_initany(server) do { \ SOCaddr_initany_(&(server), __FILE__, __LINE__); \ } while(0) /* Copy sockaddr_in/sockaddr_in6/raw IPv4/raw IPv6 to our opaque SOCaddr */ static HTS_UNUSED socklen_t SOCaddr_copyaddr_(SOCaddr*const server, const void *data, const size_t data_size, const char *file, const int line) { assertf_(server != NULL, file, line); assertf_(data != NULL, file, line); if (data_size == sizeof(struct sockaddr_in)) { memcpy(&server->m_addr.in, data, sizeof(struct sockaddr_in)); assertf_(server->m_addr.sa.sa_family == AF_INET, file, line); #if HTS_INET6 != 0 } else if (data_size == sizeof(struct sockaddr_in6)) { memcpy(&server->m_addr.in6, data, sizeof(struct sockaddr_in6)); assertf_(server->m_addr.sa.sa_family == AF_INET6, file, line); #endif } else if (data_size == 4) { memset(&server->m_addr.in, 0, sizeof(server->m_addr.in)); server->m_addr.in.sin_family = AF_INET; server->m_addr.in.sin_port = 0; memcpy(&server->m_addr.in.sin_addr, data, 4); #if HTS_INET6 != 0 } else if (data_size == 16) { memset(&server->m_addr.in6, 0, sizeof(server->m_addr.in6)); server->m_addr.in6.sin6_family = AF_INET6; server->m_addr.in6.sin6_port = 0; memcpy(&server->m_addr.in6.sin6_addr, data, 16); #endif } else { server->m_addr.in.sin_family = AF_INET; } return SOCaddr_size_(server, file, line); } #define SOCaddr_copyaddr(server, server_len, hpaddr, hpsize) do { \ server_len = (int) SOCaddr_copyaddr_(&(server), hpaddr, hpsize, __FILE__, __LINE__); \ } while(0) #define SOCaddr_copyaddr2(server, hpaddr, hpsize) do { \ (void) SOCaddr_copyaddr_(&(server), hpaddr, hpsize, __FILE__, __LINE__); \ } while(0) #define SOCaddr_copy_SOCaddr(dest, src) do { \ SOCaddr_copyaddr_(&(dest), &(src).m_addr.sa, SOCaddr_size(src), __FILE__, __LINE__); \ } while(0) /* Get dotted address */ static HTS_UNUSED void SOCaddr_inetntoa_(char *namebuf, size_t namebuflen, SOCaddr *const ss, const char *file, const int line) { assertf_(namebuf != NULL, file, line); assertf_(ss != NULL, file, line); if (getnameinfo(&ss->m_addr.sa, sizeof(ss->m_addr), namebuf, namebuflen, NULL, 0, NI_NUMERICHOST) == 0) { /* remove scope id(s) */ char *const pos = strchr(namebuf, '%'); if (pos != NULL) { *pos = '\0'; } } else { namebuf[0] = '\0'; } } #define SOCaddr_inetntoa(namebuf, namebuflen, ss) \ SOCaddr_inetntoa_(namebuf, namebuflen, &(ss), __FILE__, __LINE__) /* Get protocol ID */ #define SOCaddr_getproto(ss) ( SOCaddr_size(ss) == sizeof(struct sockaddr_in) ? '1' : '2') /* Socket length type */ typedef socklen_t SOClen; #ifdef __cplusplus } #endif #endif httrack-3.49.5/src/htsname.h0000644000175000017500000000754514336470674012625 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: httrack.c subroutines: */ /* savename routine (compute output filename) */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTSNAME_DEFH #define HTSNAME_DEFH #include "htsglobal.h" #define DELAYED_EXT "delayed" #define IS_DELAYED_EXT(a) ( ((a) != NULL) && ((a)[0] != 0) && strendwith_(a, "." DELAYED_EXT) ) HTS_STATIC int strendwith_(const char *a, const char *b) { int i, j; for(i = 0; a[i] != 0; i++) ; for(j = 0; b[j] != 0; j++) ; while(i >= 0 && j >= 0 && a[i] == b[j]) { i--; j--; } return (j == -1); } #define CACHE_REFNAME "hts-cache/ref" /* Library internal definictions */ #ifdef HTS_INTERNAL_BYTECODE /* Forward definitions */ #ifndef HTS_DEF_FWSTRUCT_httrackp #define HTS_DEF_FWSTRUCT_httrackp typedef struct httrackp httrackp; #endif #ifndef HTS_DEF_FWSTRUCT_lien_url #define HTS_DEF_FWSTRUCT_lien_url typedef struct lien_url lien_url; #endif #ifndef HTS_DEF_FWSTRUCT_struct_back #define HTS_DEF_FWSTRUCT_struct_back typedef struct struct_back struct_back; #endif #ifndef HTS_DEF_FWSTRUCT_cache_back #define HTS_DEF_FWSTRUCT_cache_back typedef struct cache_back cache_back; #endif #ifndef HTS_DEF_FWSTRUCT_hash_struct #define HTS_DEF_FWSTRUCT_hash_struct typedef struct hash_struct hash_struct; #endif #ifndef HTS_DEF_FWSTRUCT_lien_back #define HTS_DEF_FWSTRUCT_lien_back typedef struct lien_back lien_back; #endif #ifndef HTS_DEF_FWSTRUCT_lien_adrfil #define HTS_DEF_FWSTRUCT_lien_adrfil typedef struct lien_adrfil lien_adrfil; #endif #ifndef HTS_DEF_FWSTRUCT_lien_adrfilsave #define HTS_DEF_FWSTRUCT_lien_adrfilsave typedef struct lien_adrfilsave lien_adrfilsave; #endif // note: 'headers' can either be null, or incomplete (only r member filled) int url_savename(lien_adrfilsave *const afs, lien_adrfil *const former, const char *referer_adr, const char *referer_fil, httrackp * opt, struct_back * sback, cache_back * cache, hash_struct * hash, int ptr, int numero_passe, const lien_back * headers); void standard_name(char *b, const char *dot_pos, const char *nom_pos, const char *fil_complete, int short_ver); void url_savename_addstr(char *d, const char *s); char *url_md5(char *digest_buffer, const char *fil_complete); void url_savename_refname(const char *adr, const char *fil, char *filename); char *url_savename_refname_fullpath(httrackp * opt, const char *adr, const char *fil); void url_savename_refname_remove(httrackp * opt, const char *adr, const char *fil); #endif #endif httrack-3.49.5/src/htsmodules.h0000644000175000017500000001160514360553245013336 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: htsmodules.h subroutines: */ /* external modules (parsers) */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTS_MODULES #define HTS_MODULES /* Forware definitions */ #ifndef HTS_DEF_FWSTRUCT_lien_url #define HTS_DEF_FWSTRUCT_lien_url typedef struct lien_url lien_url; #endif #ifndef HTS_DEF_FWSTRUCT_httrackp #define HTS_DEF_FWSTRUCT_httrackp typedef struct httrackp httrackp; #endif #ifndef HTS_DEF_FWSTRUCT_struct_back #define HTS_DEF_FWSTRUCT_struct_back typedef struct struct_back struct_back; #endif #ifndef HTS_DEF_FWSTRUCT_cache_back #define HTS_DEF_FWSTRUCT_cache_back typedef struct cache_back cache_back; #endif #ifndef HTS_DEF_FWSTRUCT_hash_struct #define HTS_DEF_FWSTRUCT_hash_struct typedef struct hash_struct hash_struct; #endif /* Function type to add links inside the module link : link to add (absolute or relative) str : structure defined below Returns 1 if the link was added, 0 if not */ #ifndef HTS_DEF_FWSTRUCT_htsmoduleStruct #define HTS_DEF_FWSTRUCT_htsmoduleStruct typedef struct htsmoduleStruct htsmoduleStruct; #endif typedef int (*t_htsAddLink) (htsmoduleStruct * str, char *link); /* Structure passed to the module */ struct htsmoduleStruct { /* Read-only elements */ const char *filename; /* filename (C:\My Web Sites\...) */ int size; /* size of filename (should be > 0) */ const char *mime; /* MIME type of the object */ const char *url_host; /* incoming hostname (www.foo.com) */ const char *url_file; /* incoming filename (/bar/bar.gny) */ /* Write-only */ const char *wrapper_name; /* name of wrapper (static string) */ char *err_msg; /* if an error occurred, the error message (max. 1KB) */ /* Read/Write */ int relativeToHtmlLink; /* set this to 1 if all urls you pass to addLink are in fact relative to the html file where your module was originally */ /* Callbacks */ t_htsAddLink addLink; /* call this function when links are being detected. it if not your responsability to decide if the engine will keep them, or not. */ /* Optional */ char *localLink; /* if non null, the engine will write there the local relative filename of the link added by addLink(), or the absolute path if the link was refused by the wizard */ int localLinkSize; /* size of the optionnal buffer */ /* User-defined */ void *userdef; /* can be used by callback routines */ /* The parser httrackp structure (may be used) */ httrackp *opt; /* Internal use - please don't touch */ struct_back *sback; cache_back *cache; hash_struct *hashptr; int numero_passe; /* */ int *ptr_; const char *page_charset_; /* Internal use - please don't touch */ }; #ifdef __cplusplus extern "C" { #endif /* Used to wrap module initialization */ /* return 1 if init was ok */ typedef int (*t_htsWrapperInit) (char *fn, char *args); typedef int (*t_htsWrapperExit) (void); typedef int (*t_htsWrapperPlugInit) (char *args); /* Library internal definictions */ #ifdef HTS_INTERNAL_BYTECODE HTSEXT_API const char *hts_get_version_info(httrackp * opt); HTSEXT_API const char *hts_is_available(void); extern void htspe_init(void); extern void htspe_uninit(void); extern int hts_parse_externals(htsmoduleStruct * str); /*extern int swf_is_available;*/ extern int V6_is_available; #endif #ifdef __cplusplus } #endif #endif httrack-3.49.5/src/htsmd5.h0000644000175000017500000000365414336470674012367 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: htsmd5.c subroutines: */ /* generate a md5 hash */ /* */ /* Written March 1993 by Branko Lankester */ /* Modified June 1993 by Colin Plumb for altered md5.c. */ /* Modified October 1995 by Erik Troan for RPM */ /* Modified 2000 by Xavier Roche for domd5mem */ /* ------------------------------------------------------------ */ #ifndef HTSMD5_DEFH #define HTSMD5_DEFH /* Library internal definictions */ #ifdef HTS_INTERNAL_BYTECODE int domd5mem(const char *buf, size_t len, char *digest, int asAscii); unsigned long int md5sum32(const char *buff); void md5selftest(void); #endif #endif httrack-3.49.5/src/htslib.h0000644000175000017500000004704714336470674012454 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Subroutines .h */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ // Fichier librairie .h #ifndef HTS_DEFH #define HTS_DEFH #include "httrack-library.h" /* Forward definitions */ #ifndef HTS_DEF_FWSTRUCT_htsrequest #define HTS_DEF_FWSTRUCT_htsrequest typedef struct htsrequest htsrequest; #endif #ifndef HTS_DEF_FWSTRUCT_htsblk #define HTS_DEF_FWSTRUCT_htsblk typedef struct htsblk htsblk; #endif #ifndef HTS_DEF_FWSTRUCT_t_dnscache #define HTS_DEF_FWSTRUCT_t_dnscache typedef struct t_dnscache t_dnscache; #endif #ifndef HTS_DEF_FWSTRUCT_lien_adrfil #define HTS_DEF_FWSTRUCT_lien_adrfil typedef struct lien_adrfil lien_adrfil; #endif #ifndef HTS_DEF_FWSTRUCT_lien_adrfilsave #define HTS_DEF_FWSTRUCT_lien_adrfilsave typedef struct lien_adrfilsave lien_adrfilsave; #endif /* définitions globales */ #include "htsglobal.h" /* basic net definitions */ #include "htsbase.h" #include "htsbasenet.h" #include "htsnet.h" #include "htsdefines.h" /* readdir() */ #ifndef _WIN32 #include #include #endif /* cookies et auth */ #include "htsbauth.h" // Attention, définition existante également dans le shell // (à modifier avec celle-ci) #define POSTTOK "?>post" #include "htsopt.h" #define READ_ERROR (-1) #define READ_EOF (-2) #define READ_TIMEOUT (-3) #define READ_INTERNAL_ERROR (-4) /* concat */ #if ( defined(_WIN32) && defined(_MSC_VER) && ( _MSC_VER >= 1300 ) && (_MSC_VER <= 1310 ) ) /* NOTE: VC2003 inlining bug in optim mode not respecting function call sequence point */ #define MSVC2003INLINEBUG __declspec(noinline) #else #define MSVC2003INLINEBUG #endif MSVC2003INLINEBUG HTS_STATIC char *getHtsOptBuff_(httrackp * opt) { opt->state.concat.index = (opt->state.concat.index + 1) % 16; return opt->state.concat.buff[opt->state.concat.index]; } #undef MSVC2003INLINEBUG #define OPT_GET_BUFF(OPT) ( getHtsOptBuff_(OPT) ) #define OPT_GET_BUFF_SIZE(OPT) ( sizeof(opt->state.concat.buff[0]) ) /* ANCIENNE STURCTURE pour cache 1.0 */ #ifndef HTS_DEF_FWSTRUCT_OLD_t_proxy #define HTS_DEF_FWSTRUCT_OLD_t_proxy typedef struct OLD_t_proxy OLD_t_proxy; #endif struct OLD_t_proxy { int active; char name[1024]; int port; }; #ifndef HTS_DEF_FWSTRUCT_OLD_htsblk #define HTS_DEF_FWSTRUCT_OLD_htsblk typedef struct OLD_htsblk OLD_htsblk; #endif struct OLD_htsblk { int statuscode; // ANCIENNE STURCTURE - status-code, -1=erreur, 200=OK,201=..etc (cf RFC1945) int notmodified; // ANCIENNE STURCTURE - page ou fichier NON modifié (transféré) int is_write; // ANCIENNE STURCTURE - sortie sur disque (out) ou en mémoire (adr) char *adr; // ANCIENNE STURCTURE - adresse du bloc de mémoire, NULL=vide FILE *out; // ANCIENNE STURCTURE - écriture directe sur disque (si is_write=1) int size; // ANCIENNE STURCTURE - taille fichier char msg[80]; // ANCIENNE STURCTURE - message éventuel si échec ("\0"=non précisé) char contenttype[64]; // ANCIENNE STURCTURE - content-type ("text/html" par exemple) char *location; // ANCIENNE STURCTURE - on copie dedans éventuellement la véritable 'location' int totalsize; // ANCIENNE STURCTURE - taille totale à télécharger (-1=inconnue) int is_file; // ANCIENNE STURCTURE - ce n'est pas une socket mais un descripteur de fichier si 1 T_SOC soc; // ANCIENNE STURCTURE - ID socket FILE *fp; // ANCIENNE STURCTURE - fichier pour file:// OLD_t_proxy proxy; // ANCIENNE STURCTURE - proxy int user_agent_send; // ANCIENNE STURCTURE - user agent (ex: httrack/1.0 [sun]) char user_agent[64]; int http11; // ANCIENNE STURCTURE - l'en tête doit être signé HTTP/1.1 et non HTTP/1.0 }; /* fin ANCIENNE STURCTURE pour cache 1.0 */ // cache pour le dns, pour éviter de faire des gethostbyname sans arrêt #ifndef HTS_DEF_FWSTRUCT_t_dnscache #define HTS_DEF_FWSTRUCT_t_dnscache typedef struct t_dnscache t_dnscache; #endif struct t_dnscache { struct t_dnscache *next; const char *iadr; size_t host_length; // length ; (4 or 16) ; 0 for error char host_addr[HTS_MAXADDRLEN]; }; /* Library internal definictions */ #ifdef HTS_INTERNAL_BYTECODE // initialize an htsblk structure void hts_init_htsblk(htsblk * r); // attach specific project log to hachtable logger void hts_set_hash_handler(coucal hashtable, httrackp *opt); // version HTSEXT_API const char* hts_version(void); // fonctions unix/winsock int hts_read(htsblk * r, char *buff, int size); //int HTS_TOTAL_RECV_CHECK(int var); LLint check_downloadable_bytes(int rate); HTSEXT_API int hts_uninit_module(void); // fonctions principales T_SOC http_fopen(httrackp * opt, const char *adr, const char *fil, htsblk * retour); T_SOC http_xfopen(httrackp * opt, int mode, int treat, int waitconnect, const char *xsend, const char *adr, const char *fil, htsblk * retour); int http_sendhead(httrackp * opt, t_cookie * cookie, int mode, const char *xsend, const char *adr, const char *fil, const char *referer_adr, const char *referer_fil, htsblk * retour); //int newhttp(char* iadr,char* err=NULL); T_SOC newhttp(httrackp * opt, const char *iadr, htsblk * retour, int port, int waitconnect); HTS_INLINE void deletehttp(htsblk * r); HTS_INLINE int deleteaddr(htsblk * r); HTS_INLINE void deletesoc(T_SOC soc); HTS_INLINE void deletesoc_r(htsblk * r); htsblk http_test(httrackp * opt, const char *adr, const char *fil, char *loc); int check_readinput(htsblk * r); int check_readinput_t(T_SOC soc, int timeout); void treathead(t_cookie * cookie, const char *adr, const char *fil, htsblk * retour, char *rcvd); void treatfirstline(htsblk * retour, const char *rcvd); // sous-fonctions LLint http_xfread1(htsblk * r, int bufl); HTS_INLINE SOCaddr* hts_dns_resolve2(httrackp * opt, const char *iadr, SOCaddr *const addr, const char **error); HTS_INLINE SOCaddr* hts_dns_resolve(httrackp * opt, const char *iadr, SOCaddr *const addr); HTSEXT_API SOCaddr* hts_dns_resolve_nocache2(const char *const hostname, SOCaddr *const addr, const char **error); HTSEXT_API SOCaddr* hts_dns_resolve_nocache(const char *const hostname, SOCaddr *const addr); HTSEXT_API int check_hostname_dns(const char *const hostname); int ftp_available(void); #if HTS_DNSCACHE void hts_cache_free(t_dnscache *const cache); t_dnscache *hts_cache(httrackp * opt); #endif // outils divers HTS_INLINE TStamp time_local(void); void sec2str(char *s, TStamp t); void time_gmt_rfc822(char *s); void time_local_rfc822(char *s); struct tm *convert_time_rfc822(struct tm *buffer, const char *s); int set_filetime(const char *file, struct tm *tm_time); int set_filetime_rfc822(const char *file, const char *date); int get_filetime_rfc822(const char *file, char *date); HTS_INLINE void time_rfc822(char *s, struct tm *A); HTS_INLINE void time_rfc822_local(char *s, struct tm *A); HTS_INLINE int sendc(htsblk * r, const char *s); int finput(T_SOC fd, char *s, int max); int binput(char *buff, char *s, int max); int linput(FILE * fp, char *s, int max); int linputsoc(T_SOC soc, char *s, int max); int linputsoc_t(T_SOC soc, char *s, int max, int timeout); int linput_trim(FILE * fp, char *s, int max); int linput_cpp(FILE * fp, char *s, int max); void rawlinput(FILE * fp, char *s, int max); const char *strstrcase(const char *s, const char *o); int ident_url_absolute(const char *url, lien_adrfil *adrfil); void fil_simplifie(char *f); int is_unicode_utf8(const char *buffer, const size_t size); void map_characters(unsigned char *buffer, unsigned int size, unsigned int *map); int ishtml(httrackp * opt, const char *urlfil); int ishtml_ext(const char *a); int ishttperror(int err); int get_userhttptype(httrackp * opt, char *s, const char *fil); void give_mimext(char *s, const char *st); int may_bogus_multiple(httrackp * opt, const char *mime, const char *filename); int may_unknown2(httrackp * opt, const char *mime, const char *filename); const char *strrchr_limit(const char *s, char c, const char *limit); char *jump_protocol(char *source); const char *jump_protocol_const(const char *source); void code64(unsigned char *a, int size_a, unsigned char *b, int crlf); #define copychar(catbuff,a) concat(catbuff,(a),NULL) char *convtolower(char *catbuff, const char *a); void hts_lowcase(char *s); void hts_replace(char *s, char from, char to); int multipleStringMatch(const char *s, const char *match); void fprintfio(FILE * fp, const char *buff, const char *prefix); #ifdef _WIN32 #else int sig_ignore_flag(int setflag); // flag ignore #endif void cut_path(char *fullpath, char *path, char *pname); int fexist(const char *s); int fexist_utf8(const char *s); /*LLint fsize(const char* s); */ off_t fpsize(FILE * fp); off_t fsize(const char *s); off_t fsize_utf8(const char *s); // Threads typedef void *(*beginthread_type) (void *); /*unsigned long _beginthread( beginthread_type start_address, unsigned stack_size, void *arglist );*/ /* variables globales */ extern HTSEXT_API hts_stat_struct HTS_STAT; extern int _DEBUG_HEAD; extern FILE *ioinfo; /* constantes */ extern const char *hts_mime_keep[]; extern const char *hts_mime[][2]; extern const char *hts_main_mime[]; extern const char *hts_detect[]; extern const char *hts_detectbeg[]; extern const char *hts_nodetect[]; extern const char *hts_detectURL[]; extern const char *hts_detectandleave[]; extern const char *hts_detect_js[]; // htsmodule.c definitions extern void *openFunctionLib(const char *file_); extern void *getFunctionPtr(void *handle, const char *fncname); extern void closeFunctionLib(void *handle); extern void clearCallbacks(htscallbacks * chain); int hts_set_callback(t_hts_htmlcheck_callbacks * callbacks, const char *name, void *function); void *hts_get_callback(t_hts_htmlcheck_callbacks * callbacks, const char *name); #define CBSTRUCT(OPT) ((t_hts_htmlcheck_callbacks*) ((OPT)->callbacks_fun)) #define GET_USERCALLBACK(OPT, NAME) ( CBSTRUCT(OPT)-> NAME .fun ) #define GET_USERARG(OPT, NAME) ( CBSTRUCT(OPT)-> NAME .carg ) #define GET_USERDEF(OPT, NAME) ( \ (CBSTRUCT(OPT) != NULL && CBSTRUCT(OPT)-> NAME .fun != NULL) \ ? ( GET_USERARG(OPT, NAME) ) \ : ( default_callbacks. NAME .carg ) \ ) #define GET_CALLBACK(OPT, NAME) ( \ (CBSTRUCT(OPT) != NULL && CBSTRUCT(OPT)-> NAME .fun != NULL) \ ? ( GET_USERCALLBACK(OPT, NAME ) ) \ : ( default_callbacks. NAME .fun ) \ ) /* Predefined macros */ #define RUN_CALLBACK_NOARG(OPT, NAME) GET_CALLBACK(OPT, NAME)(GET_USERARG(OPT, NAME)) #define RUN_CALLBACK0(OPT, NAME) GET_CALLBACK(OPT, NAME)(GET_USERARG(OPT, NAME), OPT) #define RUN_CALLBACK1(OPT, NAME, ARG1) GET_CALLBACK(OPT, NAME)(GET_USERARG(OPT, NAME), OPT, ARG1) #define RUN_CALLBACK2(OPT, NAME, ARG1, ARG2) GET_CALLBACK(OPT, NAME)(GET_USERARG(OPT, NAME), OPT, ARG1, ARG2) #define RUN_CALLBACK3(OPT, NAME, ARG1, ARG2, ARG3) GET_CALLBACK(OPT, NAME)(GET_USERARG(OPT, NAME), OPT, ARG1, ARG2, ARG3) #define RUN_CALLBACK4(OPT, NAME, ARG1, ARG2, ARG3, ARG4) GET_CALLBACK(OPT, NAME)(GET_USERARG(OPT, NAME), OPT, ARG1, ARG2, ARG3, ARG4) #define RUN_CALLBACK5(OPT, NAME, ARG1, ARG2, ARG3, ARG4, ARG5) GET_CALLBACK(OPT, NAME)(GET_USERARG(OPT, NAME), OPT, ARG1, ARG2, ARG3, ARG4, ARG5) #define RUN_CALLBACK6(OPT, NAME, ARG1, ARG2, ARG3, ARG4, ARG5, ARG6) GET_CALLBACK(OPT, NAME)(GET_USERARG(OPT, NAME), OPT, ARG1, ARG2, ARG3, ARG4, ARG5, ARG6) #define RUN_CALLBACK7(OPT, NAME, ARG1, ARG2, ARG3, ARG4, ARG5, ARG6, ARG7) GET_CALLBACK(OPT, NAME)(GET_USERARG(OPT, NAME), OPT, ARG1, ARG2, ARG3, ARG4, ARG5, ARG6, ARG7) #define RUN_CALLBACK8(OPT, NAME, ARG1, ARG2, ARG3, ARG4, ARG5, ARG6, ARG7, ARG8) GET_CALLBACK(OPT, NAME)(GET_USERARG(OPT, NAME), OPT, ARG1, ARG2, ARG3, ARG4, ARG5, ARG6, ARG7, ARG8) /* #define GET_CALLBACK(OPT, NAME, ARG) ( \ ( \ ( ARG ) = GET_USERDEF(OPT, NAME), \ ( \ (CBSTRUCT(OPT) != NULL && CBSTRUCT(OPT)-> NAME .fun != NULL) \ ? ( GET_USERCALLBACK(OPT, NAME ) ) \ : ( default_callbacks. NAME .fun ) \ ) \ ) \ ) */ /* UTF-8 aware FILE API */ #ifndef HTS_DEF_FILEAPI #ifdef _WIN32 #define FOPEN hts_fopen_utf8 HTSEXT_API FILE *hts_fopen_utf8(const char *path, const char *mode); #define STAT hts_stat_utf8 typedef struct _stat STRUCT_STAT; HTSEXT_API int hts_stat_utf8(const char *path, STRUCT_STAT * buf); #define UNLINK hts_unlink_utf8 HTSEXT_API int hts_unlink_utf8(const char *pathname); #define RENAME hts_rename_utf8 HTSEXT_API int hts_rename_utf8(const char *oldpath, const char *newpath); #define MKDIR(F) hts_mkdir_utf8(F) HTSEXT_API int hts_mkdir_utf8(const char *pathname); #define UTIME(A,B) hts_utime_utf8(A,B) typedef struct _utimbuf STRUCT_UTIMBUF; HTSEXT_API int hts_utime_utf8(const char *filename, const STRUCT_UTIMBUF * times); #else /* The underlying filesystem charset is supposed to be UTF-8 */ #define FOPEN fopen #define STAT stat typedef struct stat STRUCT_STAT; #define UNLINK unlink #define RENAME rename #define MKDIR(F) mkdir(F, HTS_ACCESS_FOLDER) typedef struct utimbuf STRUCT_UTIMBUF; #define UTIME(A,B) utime(A,B) #endif #define HTS_DEF_FILEAPI #endif #endif // internals #undef PATH_SEPARATOR #ifdef _WIN32 #define PATH_SEPARATOR '\\' #else #define PATH_SEPARATOR '/' #endif /* Spaces: CR,LF,TAB,FF */ #define is_space(c) ( ((c)==' ') || ((c)=='\"') || ((c)==10) || ((c)==13) || ((c)==9) || ((c)==12) || ((c)==11) || ((c)=='\'') ) #define is_realspace(c) ( ((c)==' ') || ((c)==10) || ((c)==13) || ((c)==9) || ((c)==12) || ((c)==11) ) #define is_taborspace(c) ( ((c)==' ') || ((c)==9) ) #define is_quote(c) ( ((c)=='\"') || ((c)=='\'') ) #define is_retorsep(c) ( ((c)==10) || ((c)==13) || ((c)==9) ) //HTS_INLINE int is_space(char); //HTS_INLINE int is_realspace(char); #define HTTP_IS_REDIRECT(code) ( \ (code) == 301 \ || (code) == 302 \ || (code) == 303 \ || (code) == 307 \ || (code) == 308 \ ) #define HTTP_IS_NOTMODIFIED(code) ( \ (code) == 304 \ ) #define HTTP_IS_OK(code) ( ( (code) / 100 ) == 2 ) #define HTTP_IS_ERROR(code) ( !HTTP_IS_OK(code) && !HTTP_IS_REDIRECT(code) && !HTTP_IS_NOTMODIFIED(code) ) // compare le début de f avec s et retourne la position de la fin // 'A=a' (case insensitive) HTS_STATIC int strfield(const char *f, const char *s) { int r = 0; while(streql(*f, *s) && ((*f) != 0) && ((*s) != 0)) { f++; s++; r++; } if (*s == 0) return r; else return 0; } HTS_STATIC int strcmpnocase(const char *a, const char *b) { while(*a) { int cmp = hichar(*a) - hichar(*b); if (cmp != 0) return cmp; a++; b++; } return 0; } #ifdef _WIN32 #define strcasecmp(a,b) stricmp(a,b) #define strncasecmp(a,b,n) strnicmp(a,b,n) #define snprintf _snprintf #endif #define strfield2(f,s) ( (strlen(f)!=strlen(s)) ? 0 : (strfield(f,s)) ) // is this MIME an hypertext MIME (text/html), html/js-style or other script/text type? #define HTS_HYPERTEXT_DEFAULT_MIME "text/html" #define is_html_mime_type(a) \ ( (strfield2((a),"text/html")!=0)\ || (strfield2((a),"application/xhtml+xml")!=0) \ ) #define is_hypertext_mime__(a) \ ( \ is_html_mime_type(a)\ || (strfield2((a),"application/x-javascript")!=0) \ || (strfield2((a),"text/css")!=0) \ /*|| (strfield2((a),"text/vnd.wap.wml")!=0)*/ \ || (strfield2((a),"image/svg+xml")!=0) \ || (strfield2((a),"image/svg-xml")!=0) \ /*|| (strfield2((a),"audio/x-pn-realaudio")!=0) */\ || (strfield2((a),"application/x-authorware-map")!=0) \ ) #define may_be_hypertext_mime__(a) \ (\ (strfield2((a),"audio/x-pn-realaudio")!=0) \ || (strfield2((a),"audio/x-mpegurl")!=0) \ /*|| (strfield2((a),"text/xml")!=0) || (strfield2((a),"application/xml")!=0) : TODO: content check */ \ ) /* Library internal definictions */ #ifdef HTS_INTERNAL_BYTECODE // check if (mime, file) is hypertext HTS_STATIC int is_hypertext_mime(httrackp * opt, const char *mime, const char *file) { if (is_hypertext_mime__(mime)) return 1; if (may_unknown(opt, mime)) { char guessed[256]; guessed[0] = '\0'; guess_httptype(opt, guessed, file); return is_hypertext_mime__(guessed); } return 0; } // check if (mime, file) might be "false" hypertext HTS_STATIC int may_be_hypertext_mime(httrackp * opt, const char *mime, const char *file) { if (may_be_hypertext_mime__(mime)) return 1; if (file != NULL && file[0] != '\0' && may_unknown(opt, mime)) { char guessed[256]; guessed[0] = '\0'; guess_httptype(opt, guessed, file); return may_be_hypertext_mime__(guessed); } return 0; } // compare (mime, file) with reference HTS_STATIC int compare_mime(httrackp * opt, const char *mime, const char *file, const char *reference) { if (is_hypertext_mime__(mime) || may_be_hypertext_mime__(mime)) return strfield2(mime, reference); if (file != NULL && file[0] != '\0' && may_unknown(opt, mime)) { char guessed[256]; guessed[0] = '\0'; guess_httptype(opt, guessed, file); return strfield2(guessed, reference); } return 0; } #endif // returns (size_t) -1 upon error static HTS_UNUSED size_t off_t_to_size_t(off_t o) { const size_t so = (size_t) o; if ((off_t) so == o) { return so; } else { return (size_t) -1; } } /* dirent() compatibility */ #ifdef _WIN32 #define HTS_DIRENT_SIZE 256 struct dirent { ino_t d_ino; /* ignored */ off_t d_off; /* ignored */ unsigned short d_reclen; /* ignored */ unsigned char d_type; /* ignored */ char d_name[HTS_DIRENT_SIZE]; /* filename */ }; typedef struct DIR DIR; struct DIR { HANDLE h; struct dirent entry; char *name; }; DIR *opendir(const char *name); struct dirent *readdir(DIR * dir); int closedir(DIR * dir); #endif #endif httrack-3.49.5/src/htsindex.h0000644000175000017500000000342614336470674013006 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: htsindex.h */ /* keyword indexing system (search index) */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTSKINDEX_DEFH #define HTSKINDEX_DEFH /* Library internal definictions */ #ifdef HTS_INTERNAL_BYTECODE #include "htsglobal.h" int index_keyword(const char *html_data, LLint size, const char *mime, const char *filename, const char *indexpath); void index_init(const char *indexpath); void index_finish(const char *indexpath, int mode); #endif #endif httrack-3.49.5/src/htshelp.h0000644000175000017500000000360514336470674012626 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: httrack.c subroutines: */ /* command-line help system */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTSHELP_DEFH #define HTSHELP_DEFH /* Library internal definictions */ #ifdef HTS_INTERNAL_BYTECODE /* Forward definitions */ #ifndef HTS_DEF_FWSTRUCT_httrackp #define HTS_DEF_FWSTRUCT_httrackp typedef struct httrackp httrackp; #endif void infomsg(const char *msg); void help(const char *app, int more); void make_empty_index(const char *str); void help_wizard(httrackp * opt); int help_query(const char *list, int def); void help_catchurl(const char *dest_path); #endif #endif httrack-3.49.5/src/htshash.h0000644000175000017500000000436314336470674012623 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: httrack.c subroutines: */ /* hash table system (fast index) */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTSHASH_DEFH #define HTSHASH_DEFH /* Library internal definictions */ #ifdef HTS_INTERNAL_BYTECODE /* Forward definitions */ #ifndef HTS_DEF_FWSTRUCT_hash_struct #define HTS_DEF_FWSTRUCT_hash_struct typedef struct hash_struct hash_struct; #endif /** Type of hash. **/ typedef enum hash_struct_type { HASH_STRUCT_FILENAME = 0, HASH_STRUCT_ADR_PATH, HASH_STRUCT_ORIGINAL_ADR_PATH } hash_struct_type; // tables de hachage void hash_init(httrackp *opt, hash_struct *hash, int normalized); void hash_free(hash_struct *hash); int hash_read(const hash_struct * hash, const char *nom1, const char *nom2, hash_struct_type type); void hash_write(hash_struct * hash, size_t lpos); int *hash_calc_chaine(hash_struct * hash, hash_struct_type type, int pos); unsigned long int hash_cle(const char *nom1, const char *nom2); #endif #endif httrack-3.49.5/src/htsglobal.h0000644000175000017500000002266014555202547013133 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Global #define file */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ // Fichier réunissant l'ensemble des defines #ifndef HTTRACK_GLOBAL_DEFH #define HTTRACK_GLOBAL_DEFH // Version (also check external version information) #define HTTRACK_VERSION "3.49-5" #define HTTRACK_VERSIONID "3.49.5" #define HTTRACK_AFF_VERSION "3.x" #define HTTRACK_LIB_VERSION "2.0" #ifndef HTS_NOINCLUDES #include #include #endif // Définition plate-forme #include "htsconfig.h" // WIN32 types #ifdef _WIN32 #ifndef SIZEOF_LONG #define SIZEOF_LONG 4 #define SIZEOF_LONG_LONG 8 #endif #endif /* GCC extension */ #ifndef HTS_UNUSED #ifdef __GNUC__ #define HTS_UNUSED __attribute__ ((unused)) #define HTS_STATIC static __attribute__ ((unused)) #define HTS_PRINTF_FUN(fmt, arg) __attribute__ ((format (printf, fmt, arg))) #else #define HTS_UNUSED #define HTS_STATIC static #define HTS_PRINTF_FUN(fmt, arg) #endif #endif // config.h #ifdef _WIN32 /* #define HAVE_SYS_STAT_H 1 #define HAVE_SYS_TYPES_H 1 #define HAVE_SYS_STAT_H 1 */ #ifndef DLLIB #define DLLIB 1 #endif #ifndef HTS_INET6 #define HTS_INET6 1 #endif #ifndef S_ISREG #define S_ISREG(m) ((m) & _S_IFREG) #define S_ISDIR(m) ((m) & _S_IFDIR) #endif #else #include "config.h" #ifndef SETUID #define HTS_DO_NOT_USE_UID #endif #ifndef HTS_LONGLONG #ifdef SIZEOF_LONG_LONG #if SIZEOF_LONG_LONG==8 #define HTS_LONGLONG 1 #endif #endif #ifndef HTS_LONGLONG #ifdef __sun #define HTS_LONGLONG 0 #endif #ifdef __osf__ #define HTS_LONGLONG 0 #endif #ifdef __linux #define HTS_LONGLONG 1 #endif #ifdef _WIN32 #define HTS_LONGLONG 1 #endif #endif #endif #ifdef DLLIB #define HTS_DLOPEN 1 #else #define HTS_DLOPEN 0 #endif #endif #ifndef BIGSTK #define BIGSTK #endif // compatibilité DOS #ifdef _WIN32 #define HTS_DOSNAME 1 #else #define HTS_DOSNAME 0 #endif // utiliser zlib? #ifndef HTS_USEZLIB // autoload #define HTS_USEZLIB 1 #endif #ifndef HTS_INET6 #define HTS_INET6 0 #endif // utiliser openssl? #ifndef HTS_USEOPENSSL // autoload #define HTS_USEOPENSSL 1 #endif #ifndef HTS_DLOPEN #define HTS_DLOPEN 1 #endif #ifndef HTS_USESWF #define HTS_USESWF 1 #endif #ifdef _WIN32 #else #define __cdecl #endif /* rc file */ #ifdef _WIN32 #define HTS_HTTRACKRC "httrackrc" #else #ifndef HTS_ETCPATH #define HTS_ETCPATH "/etc" #endif #ifndef HTS_BINPATH #define HTS_BINPATH "/usr/bin" #endif #ifndef HTS_LIBPATH #define HTS_LIBPATH "/usr/lib" #endif #ifndef HTS_PREFIX #define HTS_PREFIX "/usr" #endif #define HTS_HTTRACKRC ".httrackrc" #define HTS_HTTRACKCNF HTS_ETCPATH"/httrack.conf" #ifdef DATADIR #define HTS_HTTRACKDIR DATADIR"/httrack/" #else #define HTS_HTTRACKDIR HTS_PREFIX"/share/httrack/" #endif #endif /* Taille max d'une URL */ #define HTS_URLMAXSIZE 1024 /* Taille max ligne de commande (>=HTS_URLMAXSIZE*2) */ #define HTS_CDLMAXSIZE 1024 /* Copyright (C) 1998-2017 Xavier Roche and other contributors */ #define HTTRACK_AFF_AUTHORS "[XR&CO'2014]" #define HTS_DEFAULT_FOOTER "" #define HTTRACK_WEB "http://www.httrack.com" #define HTS_UPDATE_WEBSITE "http://www.httrack.com/update.php3?Product=HTTrack&Version=" HTTRACK_VERSIONID "&VersionStr=" HTTRACK_VERSION "&Platform=%d&Language=%s" #define H_CRLF "\x0d\x0a" #define CRLF "\x0d\x0a" #ifdef _WIN32 #define LF "\x0d\x0a" #else #define LF "\x0a" #endif /* équivaut à "paramètre vide", par exemple -F (none) */ #define HTS_NOPARAM "(none)" #define HTS_NOPARAM2 "\"(none)\"" /* maximum et minimum */ #define maximum(A,B) ( (A) > (B) ? (A) : (B) ) #define minimum(A,B) ( (A) < (B) ? (A) : (B) ) /* chaine no empty ? (and not null) */ #define strnotempty(A) (((A) != NULL && (A)[0] != '\0')) /* optimisation inline si possible */ #ifdef __cplusplus #define HTS_INLINE inline #else #define HTS_INLINE #endif #ifdef _WIN32 #ifdef LIBHTTRACK_EXPORTS #define HTSEXT_API __declspec(dllexport) #else #define HTSEXT_API __declspec(dllimport) #endif #else /* See */ #if ( ( defined(__GNUC__) && ( __GNUC__ >= 4 ) ) \ || ( defined(HAVE_VISIBILITY) && HAVE_VISIBILITY ) ) #define HTSEXT_API __attribute__ ((visibility ("default"))) #else #define HTSEXT_API #endif #endif #ifndef HTS_LONGLONG #ifdef HTS_NO_64_BIT #define HTS_LONGLONG 0 #else #define HTS_LONGLONG 1 #endif #endif // long long int? (or int) // (and int cast for system functions like malloc() ) #if HTS_LONGLONG #ifdef LLINT_FORMAT typedef LLINT_TYPE LLint; typedef LLINT_TYPE TStamp; #define LLintP LLINT_FORMAT #else #ifdef _WIN32 typedef __int64 LLint; typedef __int64 TStamp; #define LLintP "%I64d" #elif (defined(_LP64) || defined(__x86_64__) \ || defined(__powerpc64__) || defined(__64BIT__)) typedef long int LLint; typedef long int TStamp; #define LLintP "%ld" #else typedef long long int LLint; typedef long long int TStamp; #define LLintP "%lld" #endif #endif /* HTS_LONGLONG */ #else typedef int LLint; #define LLintP "%d" typedef double TStamp; #endif #ifdef LFS_FLAG typedef LLint INTsys; #define INTsysP LLintP #ifdef __linux #define HTS_FSEEKO #endif #else typedef int INTsys; #define INTsysP "%d" #endif #ifdef _WIN32 #if defined(_WIN64) typedef unsigned __int64 T_SOC; #else typedef unsigned __int32 T_SOC; #endif #else typedef int T_SOC; #endif /* IPV4, IPV6 and various unified structures */ #define HTS_MAXADDRLEN 64 #ifdef _WIN32 #else #define __cdecl #endif /* mode pour mkdir ET chmod (accès aux fichiers) */ #define HTS_PROTECT_FOLDER (S_IRUSR|S_IWUSR|S_IXUSR) #if HTS_ACCESS #define HTS_ACCESS_FILE (S_IRUSR|S_IWUSR|S_IRGRP|S_IROTH) #define HTS_ACCESS_FOLDER (S_IRUSR|S_IWUSR|S_IXUSR|S_IRGRP|S_IXGRP|S_IROTH|S_IXOTH) #else #define HTS_ACCESS_FILE (S_IRUSR|S_IWUSR) #define HTS_ACCESS_FOLDER (S_IRUSR|S_IWUSR|S_IXUSR) #endif /* vérifier la déclaration des variables préprocesseur */ #ifndef HTS_DOSNAME #error | HTS_DOSNAME Has not been defined. #error | Set it to 1 if you are under DOS, 0 under Unix. #error | Example: place this line in you source, before includes: #error | #define HTS_DOSNAME 0 #error #error #endif #ifndef HTS_ACCESS /* Par défaut, accès à tous les utilisateurs */ #define HTS_ACCESS 1 #endif /* fflush sur stdout */ #define io_flush { fflush(stdout); fflush(stdin); } /* HTSLib */ // Cache DNS, accélère les résolution d'adresses #define HTS_DNSCACHE 1 // ID d'une pseudo-socket locale pour les file:// #define LOCAL_SOCKET_ID -2 // taille de chaque buffer (10 sockets 650 ko) #define TAILLE_BUFFER 65536 #ifdef HTS_DO_NOT_USE_PTHREAD #error needs threads support #endif #define USE_BEGINTHREAD 1 #ifdef _DEBUG // trace mallocs //#define HTS_TRACE_MALLOC #ifdef HTS_TRACE_MALLOC typedef unsigned long int t_htsboundary; #ifndef HTS_DEF_FWSTRUCT_mlink #define HTS_DEF_FWSTRUCT_mlink typedef struct mlink mlink; #endif struct mlink { char *adr; int len; int id; struct mlink *next; }; static const t_htsboundary htsboundary = 0xDEADBEEF; #endif #endif /* strxxx debugging */ #ifndef NOSTRDEBUG #define STRDEBUG 1 #endif /* ------------------------------------------------------------ */ /* Debugging */ /* ------------------------------------------------------------ */ // débuggage types #define DEBUG_SHOWTYPES 0 // backing debug #define BDEBUG 0 // chunk receive #define CHUNKDEBUG 0 // realloc links debug #define MDEBUG 0 // cache debug #define DEBUGCA 0 // DNS debug #define DEBUGDNS 0 // savename debug #define DEBUG_SAVENAME 0 // debug robots #define DEBUG_ROBOTS 0 // debug hash #define DEBUG_HASH 0 // Vérification d'intégrité #define DEBUG_CHECKINT 0 // nbr sockets debug #define NSDEBUG 0 // débuggage HTSLib #define HDEBUG 0 // surveillance de la connexion #define CNXDEBUG 0 // debuggage cookies #define DEBUG_COOK 0 // débuggage hard.. #define HTS_WIDE_DEBUG 0 // debuggage deletehttp et cie #define HTS_DEBUG_CLOSESOCK 0 // debug tracage mémoire #define MEMDEBUG 0 // htsmain #define DEBUG_STEPS 0 // Débuggage de contrôle #if HTS_DEBUG_CLOSESOCK #define _HTS_WIDE 1 #endif #if HTS_WIDE_DEBUG #define _HTS_WIDE 1 #endif #if _HTS_WIDE extern FILE *DEBUG_fp; #define DEBUG_W(A) { if (DEBUG_fp==NULL) DEBUG_fp=fopen("bug.out","wb"); fprintf(DEBUG_fp,":>"A); fflush(DEBUG_fp); } #undef _ #define _ , #endif #endif httrack-3.49.5/src/htsftp.h0000644000175000017500000000515714336470674012473 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: basic FTP protocol manager .h */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTSFTP_DEFH #define HTSFTP_DEFH #include "htsbase.h" #include "htsbasenet.h" #include "htsthread.h" /* Forward definitions */ #ifndef HTS_DEF_FWSTRUCT_lien_back #define HTS_DEF_FWSTRUCT_lien_back typedef struct lien_back lien_back; #endif #ifndef HTS_DEF_FWSTRUCT_httrackp #define HTS_DEF_FWSTRUCT_httrackp typedef struct httrackp httrackp; #endif /* Download structure */ #ifndef HTS_DEF_FWSTRUCT_FTPDownloadStruct #define HTS_DEF_FWSTRUCT_FTPDownloadStruct typedef struct FTPDownloadStruct FTPDownloadStruct; #endif struct FTPDownloadStruct { lien_back *pBack; httrackp *pOpt; }; /* Library internal definictions */ #ifdef HTS_INTERNAL_BYTECODE #if USE_BEGINTHREAD void launch_ftp(FTPDownloadStruct * params); void back_launch_ftp(void *pP); #else void launch_ftp(FTPDownloadStruct * params, char *path, char *exec); int back_launch_ftp(FTPDownloadStruct * params); #endif int run_launch_ftp(FTPDownloadStruct * params); int send_line(T_SOC soc, const char *data); int get_ftp_line(T_SOC soc, char *line, size_t line_size, int timeout); T_SOC get_datasocket(char *to_send, size_t to_send_size); int stop_ftp(lien_back * back); char *linejmp(char *line); int check_socket(T_SOC soc); int check_socket_connect(T_SOC soc); int wait_socket_receive(T_SOC soc, int timeout); #endif #endif httrack-3.49.5/src/htsfilters.h0000644000175000017500000000355614336470674013353 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: httrack.c subroutines: */ /* filters ("regexp") */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTSFILT_DEFH #define HTSFILT_DEFH /* Library internal definictions */ #ifdef HTS_INTERNAL_BYTECODE #include "htsbase.h" int fa_strjoker(int type, char **filters, int nfil, const char *nom, LLint * size, int *size_flag, int *depth); HTS_INLINE const char *strjoker(const char *chaine, const char *joker, LLint * size, int *size_flag); const char *strjokerfind(const char *chaine, const char *joker); #endif #endif httrack-3.49.5/src/htsdefines.h0000644000175000017500000002412414336470674013312 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Some defines for httrack.c and others */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ // Fichier librairie .h #ifndef HTS_DEFINES_DEFH #define HTS_DEFINES_DEFH /* Forward definitions */ #ifndef HTS_DEF_FWSTRUCT_httrackp #define HTS_DEF_FWSTRUCT_httrackp typedef struct httrackp httrackp; #endif #ifndef HTS_DEF_FWSTRUCT_lien_back #define HTS_DEF_FWSTRUCT_lien_back typedef struct lien_back lien_back; #endif #ifndef HTS_DEF_FWSTRUCT_htsblk #define HTS_DEF_FWSTRUCT_htsblk typedef struct htsblk htsblk; #endif #ifndef HTS_DEF_FWSTRUCT_hts_stat_struct #define HTS_DEF_FWSTRUCT_hts_stat_struct typedef struct hts_stat_struct hts_stat_struct; #endif #ifndef HTS_DEF_FWSTRUCT_htsmoduleStruct #define HTS_DEF_FWSTRUCT_htsmoduleStruct typedef struct htsmoduleStruct htsmoduleStruct; #endif #ifndef HTS_DEF_FWSTRUCT_t_hts_callbackarg #define HTS_DEF_FWSTRUCT_t_hts_callbackarg typedef struct t_hts_callbackarg t_hts_callbackarg; #endif #ifndef HTS_DEF_FWSTRUCT_t_hts_callbackarg #define HTS_DEF_FWSTRUCT_t_hts_callbackarg typedef struct t_hts_callbackarg t_hts_callbackarg; #endif /* External callbacks */ #ifndef EXTERNAL_FUNCTION #ifdef _WIN32 #define EXTERNAL_FUNCTION __declspec(dllexport) #else #define EXTERNAL_FUNCTION #endif #endif /* --wrapper plug function prototype */ typedef int (*t_hts_plug) (httrackp * opt, const char *argv); typedef int (*t_hts_unplug) (httrackp * opt); /* htsopt function callbacks definitions */ typedef void (*t_hts_htmlcheck_init) (t_hts_callbackarg * carg); typedef void (*t_hts_htmlcheck_uninit) (t_hts_callbackarg * carg); typedef int (*t_hts_htmlcheck_start) (t_hts_callbackarg * carg, httrackp * opt); typedef int (*t_hts_htmlcheck_end) (t_hts_callbackarg * carg, httrackp * opt); typedef int (*t_hts_htmlcheck_chopt) (t_hts_callbackarg * carg, httrackp * opt); typedef int (*t_hts_htmlcheck_process) (t_hts_callbackarg * carg, httrackp * opt, char **html, int *len, const char *url_adresse, const char *url_fichier); typedef t_hts_htmlcheck_process t_hts_htmlcheck_preprocess; typedef t_hts_htmlcheck_process t_hts_htmlcheck_postprocess; typedef int (*t_hts_htmlcheck_check_html) (t_hts_callbackarg * carg, httrackp * opt, char *html, int len, const char *url_adresse, const char *url_fichier); typedef const char *(*t_hts_htmlcheck_query) (t_hts_callbackarg * carg, httrackp * opt, const char *question); typedef const char *(*t_hts_htmlcheck_query2) (t_hts_callbackarg * carg, httrackp * opt, const char *question); typedef const char *(*t_hts_htmlcheck_query3) (t_hts_callbackarg * carg, httrackp * opt, const char *question); typedef int (*t_hts_htmlcheck_loop) (t_hts_callbackarg * carg, httrackp * opt, lien_back * back, int back_max, int back_index, int lien_tot, int lien_ntot, int stat_time, hts_stat_struct * stats); typedef int (*t_hts_htmlcheck_check_link) (t_hts_callbackarg * carg, httrackp * opt, const char *adr, const char *fil, int status); typedef int (*t_hts_htmlcheck_check_mime) (t_hts_callbackarg * carg, httrackp * opt, const char *adr, const char *fil, const char *mime, int status); typedef void (*t_hts_htmlcheck_pause) (t_hts_callbackarg * carg, httrackp * opt, const char *lockfile); typedef void (*t_hts_htmlcheck_filesave) (t_hts_callbackarg * carg, httrackp * opt, const char *file); typedef void (*t_hts_htmlcheck_filesave2) (t_hts_callbackarg * carg, httrackp * opt, const char *hostname, const char *filename, const char *localfile, int is_new, int is_modified, int not_updated); typedef int (*t_hts_htmlcheck_linkdetected) (t_hts_callbackarg * carg, httrackp * opt, char *link); typedef int (*t_hts_htmlcheck_linkdetected2) (t_hts_callbackarg * carg, httrackp * opt, char *link, const char *tag_start); typedef int (*t_hts_htmlcheck_xfrstatus) (t_hts_callbackarg * carg, httrackp * opt, lien_back * back); typedef int (*t_hts_htmlcheck_savename) (t_hts_callbackarg * carg, httrackp * opt, const char *adr_complete, const char *fil_complete, const char *referer_adr, const char *referer_fil, char *save); typedef t_hts_htmlcheck_savename t_hts_htmlcheck_extsavename; typedef int (*t_hts_htmlcheck_sendhead) (t_hts_callbackarg * carg, httrackp * opt, char *buff, const char *adr, const char *fil, const char *referer_adr, const char *referer_fil, htsblk * outgoing); typedef int (*t_hts_htmlcheck_receivehead) (t_hts_callbackarg * carg, httrackp * opt, char *buff, const char *adr, const char *fil, const char *referer_adr, const char *referer_fil, htsblk * incoming); /* External additional parsing module(s) */ typedef int (*t_hts_htmlcheck_detect) (t_hts_callbackarg * carg, httrackp * opt, htsmoduleStruct * str); typedef int (*t_hts_htmlcheck_parse) (t_hts_callbackarg * carg, httrackp * opt, htsmoduleStruct * str); /* Callbacks */ #ifndef HTS_DEF_FWSTRUCT_t_hts_htmlcheck_callbacks #define HTS_DEF_FWSTRUCT_t_hts_htmlcheck_callbacks typedef struct t_hts_htmlcheck_callbacks t_hts_htmlcheck_callbacks; #endif /* Callabck array */ #define DEFCALLBACK(NAME) \ struct NAME { \ t_hts_htmlcheck_ ##NAME fun; \ t_hts_callbackarg *carg; \ } NAME /* Callback items */ typedef void *t_hts_htmlcheck_t_hts_htmlcheck_callbacks_item; typedef DEFCALLBACK(t_hts_htmlcheck_callbacks_item); /* Linked list, which should be used for the 'arg' user-defined argument */ struct t_hts_callbackarg { /* User-defined agument for the called function */ void *userdef; /* Previous function, if any (fun != NULL) */ struct prev { void *fun; t_hts_callbackarg *carg; } prev; }; /* Callback structure */ struct t_hts_htmlcheck_callbacks { /* v3.41 */ DEFCALLBACK(init); DEFCALLBACK(uninit); DEFCALLBACK(start); DEFCALLBACK(end); DEFCALLBACK(chopt); DEFCALLBACK(preprocess); DEFCALLBACK(postprocess); DEFCALLBACK(check_html); DEFCALLBACK(query); DEFCALLBACK(query2); DEFCALLBACK(query3); DEFCALLBACK(loop); DEFCALLBACK(check_link); DEFCALLBACK(check_mime); DEFCALLBACK(pause); DEFCALLBACK(filesave); DEFCALLBACK(filesave2); DEFCALLBACK(linkdetected); DEFCALLBACK(linkdetected2); DEFCALLBACK(xfrstatus); DEFCALLBACK(savename); DEFCALLBACK(sendhead); DEFCALLBACK(receivehead); DEFCALLBACK(detect); DEFCALLBACK(parse); /* >3.41 */ DEFCALLBACK(extsavename); }; /* Library internal definitions */ #ifdef HTS_INTERNAL_BYTECODE #ifndef HTS_DEF_FWSTRUCT_t_hts_callback_ref #define HTS_DEF_FWSTRUCT_t_hts_callback_ref typedef struct t_hts_callback_ref t_hts_callback_ref; #endif struct t_hts_callback_ref { const char *name; size_t offset; }; #ifdef __cplusplus extern "C" { #endif extern const t_hts_htmlcheck_callbacks default_callbacks; #ifdef __cplusplus } #endif #define HT_PRINT(A) strcatbuff(opt->state.HTbuff,A); #define HT_REQUEST_START opt->state.HTbuff[0]='\0'; #define HT_REQUEST_END #define HTT_REQUEST_START opt->state.HTbuff[0]='\0'; #define HTT_REQUEST_END #define HTS_REQUEST_START opt->state.HTbuff[0]='\0'; #define HTS_REQUEST_END #define HTS_PANIC_PRINTF(S) strcpybuff(opt->state._hts_errmsg,S); #endif #endif httrack-3.49.5/src/htscoremain.h0000644000175000017500000000337414336470674013476 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: httrack.c subroutines: */ /* main routine (first called) */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTSMAINHSR_DEFH #define HTSMAINHSR_DEFH // --assume standard #define HTS_ASSUME_STANDARD \ "php2 php3 php4 php cgi asp jsp pl cfm nsf=text/html" #include "htsglobal.h" #include "htsopt.h" /* Library internal definictions */ #ifdef HTS_INTERNAL_BYTECODE int cmdl_opt(char *s); int check_path(String * s, char *defaultname); #endif #endif httrack-3.49.5/src/htsparse.h0000644000175000017500000001370614336470674013013 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: htsparse.h parser */ /* html/javascript/css parser */ /* and other parser routines */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #include "htsglobal.h" /* Forward definitions */ #ifndef HTS_DEF_FWSTRUCT_htsblk #define HTS_DEF_FWSTRUCT_htsblk typedef struct htsblk htsblk; #endif #ifndef HTS_DEF_FWSTRUCT_robots_wizard #define HTS_DEF_FWSTRUCT_robots_wizard typedef struct robots_wizard robots_wizard; #endif #ifndef HTS_DEF_FWSTRUCT_hash_struct #define HTS_DEF_FWSTRUCT_hash_struct typedef struct hash_struct hash_struct; #endif #ifndef HTS_DEF_FWSTRUCT_htsmoduleStructExtended #define HTS_DEF_FWSTRUCT_htsmoduleStructExtended typedef struct htsmoduleStructExtended htsmoduleStructExtended; #endif struct htsmoduleStructExtended { /* Main object */ htsblk *r_; /* Error handling */ int *error_; int *exit_xh_; int *store_errpage_; /* Structural */ int *filptr_; char ***filters_; robots_wizard *robots_; hash_struct *hash_; //int *lien_max_; /* Base & codebase */ char *base; char *codebase; /* Index */ int *makeindex_done_; FILE **makeindex_fp_; int *makeindex_links_; char *makeindex_firstlink_; /* Html templates */ char *template_header_; char *template_body_; char *template_footer_; /* Specific to downloads */ LLint *stat_fragment_; TStamp makestat_time; FILE *makestat_fp; LLint *makestat_total_; int *makestat_lnk_; FILE *maketrack_fp; /* Function-dependant */ char *loc_; TStamp *last_info_shell_; int *info_shell_; }; /* Library internal definictions */ #ifdef HTS_INTERNAL_BYTECODE /* Main parser, attempt to scan links inside the html/css/js file Parameters: The public module structure, and the private module variables */ int htsparse(htsmoduleStruct * str, htsmoduleStructExtended * stre); /* Check for 301,302.. errors ("moved") and handle them; re-isuue requests, make rediretc file, handle filters considerations.. Parameters: The public module structure, and the private module variables Returns 0 upon success */ int hts_mirror_check_moved(htsmoduleStruct * str, htsmoduleStructExtended * stre); /* Process user intercations: pause, add link, delete link.. */ void hts_mirror_process_user_interaction(htsmoduleStruct * str, htsmoduleStructExtended * stre); /* Get the next file on the queue, waiting for it, handling other files in background.. Parameters: The public module structure, and the private module variables Returns 0 upon success */ int hts_mirror_wait_for_next_file(htsmoduleStruct * str, htsmoduleStructExtended * stre); /* Wait for (adr, fil, save) to be started, that is, to be ready for naming, having its header MIME type If the final URL is to be forbidden, sets 'forbidden_url' to the corresponding value */ int hts_wait_delayed(htsmoduleStruct * str, lien_adrfilsave *afs, char *parent_adr, char *parent_fil, lien_adrfil *former, int *forbidden_url); /* Context state */ #define ENGINE_DEFINE_CONTEXT_BASE() \ httrackp* const opt HTS_UNUSED = (httrackp*) str->opt; \ struct_back* const sback HTS_UNUSED = (struct_back*) str->sback; \ lien_back* const back HTS_UNUSED = sback->lnk; \ const int back_max HTS_UNUSED = sback->count; \ cache_back* const cache HTS_UNUSED = (cache_back*) str->cache; \ hash_struct* const hashptr HTS_UNUSED = (hash_struct*) str->hashptr; \ const int numero_passe HTS_UNUSED = str->numero_passe; \ /* variable */ \ int ptr = *str->ptr_ #define ENGINE_SET_CONTEXT_BASE() \ ptr = *str->ptr_ #define ENGINE_LOAD_CONTEXT_BASE() \ ENGINE_DEFINE_CONTEXT_BASE() #define ENGINE_SAVE_CONTEXT_BASE() \ /* Apply changes */ \ * str->ptr_ = ptr #define WAIT_FOR_AVAILABLE_SOCKET() do { \ int prev = opt->state._hts_in_html_parsing; \ while(back_pluggable_sockets_strict(sback, opt) <= 0) { \ opt->state._hts_in_html_parsing = 6; \ /* Wait .. */ \ back_wait(sback,opt,cache,0); \ /* Transfer rate */ \ engine_stats(); \ /* Refresh various stats */ \ HTS_STAT.stat_nsocket=back_nsoc(sback); \ HTS_STAT.stat_errors=fspc(opt,NULL,"error"); \ HTS_STAT.stat_warnings=fspc(opt,NULL,"warning"); \ HTS_STAT.stat_infos=fspc(opt,NULL,"info"); \ HTS_STAT.nbk=backlinks_done(sback,opt->liens,opt->lien_tot,ptr); \ HTS_STAT.nb=back_transferred(HTS_STAT.stat_bytes,sback); \ /* Check */ \ if (!RUN_CALLBACK7(opt, loop, sback->lnk, sback->count, -1,ptr,opt->lien_tot,(int) (time_local()-HTS_STAT.stat_timestart),&HTS_STAT)) { \ return -1; \ } \ } \ opt->state._hts_in_html_parsing = prev; \ } while(0) #endif httrack-3.49.5/src/htscore.h0000644000175000017500000002342114336470674012624 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Main file .h */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ // Fichier librairie .h #ifndef HTS_CORE_DEFH #define HTS_CORE_DEFH #include "htsglobal.h" /* specific definitions */ #include "htsbase.h" // Includes & définitions #include #include #ifdef _WIN32 #include #include #else #ifndef _WIN32 #include #endif #endif /* END specific definitions */ /* Forward definitions */ #ifndef HTS_DEF_FWSTRUCT_lien_url #define HTS_DEF_FWSTRUCT_lien_url typedef struct lien_url lien_url; #endif #ifndef HTS_DEF_FWSTRUCT_lien_back #define HTS_DEF_FWSTRUCT_lien_back typedef struct lien_back lien_back; #endif #ifndef HTS_DEF_FWSTRUCT_struct_back #define HTS_DEF_FWSTRUCT_struct_back typedef struct struct_back struct_back; #endif #ifndef HTS_DEF_FWSTRUCT_cache_back #define HTS_DEF_FWSTRUCT_cache_back typedef struct cache_back cache_back; #endif #ifndef HTS_DEF_FWSTRUCT_hash_struct #define HTS_DEF_FWSTRUCT_hash_struct typedef struct hash_struct hash_struct; #endif #ifndef HTS_DEF_FWSTRUCT_filecreate_params #define HTS_DEF_FWSTRUCT_filecreate_params typedef struct filecreate_params filecreate_params; #endif // Include htslib.h for all types #include "htslib.h" // options #include "htsopt.h" // INCLUDES .H PARTIES DE CODE HTTRACK // routine main #include "htscoremain.h" // core routines #include "htscore.h" // divers outils pour httrack.c #include "htstools.h" // aide pour la version en ligne de commande #include "htshelp.h" // génération du nom de fichier à sauver #include "htsname.h" // gestion ftp #include "htsftp.h" // gestion interception d'URL #include "htscatchurl.h" // gestion robots.txt #include "htsrobots.h" // routines d'acceptation de liens #include "htswizard.h" // routines de regexp #include "htsfilters.h" // gestion backing #include "htsback.h" // gestion cache #include "htscache.h" // gestion hashage #include "htshash.h" #include "coucal.h" #include "htsdefines.h" #include "hts-indextmpl.h" // adr, fil #ifndef HTS_DEF_FWSTRUCT_lien_adrfil #define HTS_DEF_FWSTRUCT_lien_adrfil typedef struct lien_adrfil lien_adrfil; #endif struct lien_adrfil { char adr[HTS_URLMAXSIZE * 2]; // adresse char fil[HTS_URLMAXSIZE * 2]; // nom du fichier distant }; // adr, fil, save #ifndef HTS_DEF_FWSTRUCT_lien_adrfilsave #define HTS_DEF_FWSTRUCT_lien_adrfilsave typedef struct lien_adrfilsave lien_adrfilsave; #endif struct lien_adrfilsave { lien_adrfil af; char save[HTS_URLMAXSIZE * 2]; // nom à sauver sur disque (avec chemin éventuel) }; #ifndef HTS_DEF_FWSTRUCT_struct_back #define HTS_DEF_FWSTRUCT_struct_back typedef struct struct_back struct_back; #endif struct struct_back { lien_back *lnk; int count; coucal ready; LLint ready_size_bytes; }; typedef struct cache_back_zip_entry cache_back_zip_entry; // cache #ifndef HTS_DEF_FWSTRUCT_cache_back #define HTS_DEF_FWSTRUCT_cache_back typedef struct cache_back cache_back; #endif struct cache_back { int version; // 0 ou 1 /* */ int type; int ro; FILE *dat, *ndx, *olddat; char *use; // liste des adr+fil FILE *lst; // liste des fichiers pour la "purge" FILE *txt; // liste des fichiers (info) char lastmodified[256]; // HASH coucal hashtable; // HASH for tests (naming subsystem) coucal cached_tests; // fichiers log optionnels FILE *log; FILE *errlog; // variables int ptr_ant; // pointeur pour anticiper int ptr_last; // pointeur pour anticiper // void *zipInput; void *zipOutput; cache_back_zip_entry *zipEntries; int zipEntriesOffs; int zipEntriesCapa; }; #ifndef HTS_DEF_FWSTRUCT_hash_struct #define HTS_DEF_FWSTRUCT_hash_struct typedef struct hash_struct hash_struct; #endif struct hash_struct { /* Links big array reference */ const lien_url *const*const*liens; /* Savename (case insensitive ; lowercased) */ coucal sav; /* Address and path */ coucal adrfil; /* Former address and path */ coucal former_adrfil; /** Buffers **/ int normalized; char normfil[HTS_URLMAXSIZE * 2]; char normfil2[HTS_URLMAXSIZE * 2]; char catbuff[CATBUFF_SIZE]; }; #ifndef HTS_DEF_FWSTRUCT_filecreate_params #define HTS_DEF_FWSTRUCT_filecreate_params typedef struct filecreate_params filecreate_params; #endif struct filecreate_params { FILE *lst; char path[HTS_URLMAXSIZE * 2]; }; /* Access macros. */ #define heap(N) (opt->liens[N]) #define heap_top_index() (opt->lien_tot - 1) #define heap_top() (heap(heap_top_index())) #define urladr() (heap(ptr)->adr) #define urlfil() (heap(ptr)->fil) #define savename() (heap(ptr)->sav) #define parenturladr() (heap(heap(ptr)->precedent)->adr) #define parenturlfil() (heap(heap(ptr)->precedent)->fil) #define parentsavename() (heap(heap(ptr)->precedent)->sav) #define relativeurladr() ((!parent_relative)?urladr():parenturladr()) #define relativeurlfil() ((!parent_relative)?urlfil():parenturlfil()) #define relativesavename() ((!parent_relative)?savename():parentsavename()) /* Library internal definictions */ #ifdef HTS_INTERNAL_BYTECODE HTS_STATIC int cache_writable(cache_back * cache) { return (cache != NULL && (cache->dat != NULL || cache->zipOutput != NULL)); } HTS_STATIC int cache_readable(cache_back * cache) { return (cache != NULL && (cache->olddat != NULL || cache->zipInput != NULL)); } #endif // Fonctions // INCLUDES .H PARTIES DE CODE HTTRACK /* Library internal definictions */ #ifdef HTS_INTERNAL_BYTECODE char *hts_cancel_file_pop(httrackp * opt); #endif // add a link on the heap int hts_record_link(httrackp * opt, const char *address, const char *file, const char *save, const char *ref_address, const char *ref_file, const char *codebase); // index of the latest added link size_t hts_record_link_latest(httrackp *opt); // invalidate an entry void hts_invalidate_link(httrackp * opt, int lpos); // wipe all records void hts_record_init(httrackp *opt); void hts_record_free(httrackp *opt); //int httpmirror(char* url,int level,httrackp opt); int httpmirror(char *url1, httrackp * opt); int filesave(httrackp * opt, const char *adr, int len, const char *s, const char *url_adr /* = NULL */ , const char *url_fil /* = NULL */ ); char *hts_cancel_file_pop(httrackp * opt); int check_fatal_io_errno(void); int engine_stats(void); void host_ban(httrackp * opt, int ptr, struct_back * sback, const char *host); FILE *filecreate(filenote_strc * strct, const char *s); FILE *fileappend(filenote_strc * strct, const char *s); int filecreateempty(filenote_strc * strct, const char *filename); int filenote(filenote_strc * strct, const char *s, filecreate_params * params); void file_notify(httrackp * opt, const char *adr, const char *fil, const char *save, int create, int modify, int wasupdated); void usercommand(httrackp * opt, int exe, const char *cmd, const char *file, const char *adr, const char *fil); void usercommand_exe(const char *cmd, const char *file); int filters_init(char ***ptrfilters, int maxfilter, int filterinc); int fspc(httrackp * opt, FILE * fp, const char *type); char *next_token(char *p, int flag); // char *readfile(const char *fil); char *readfile2(const char *fil, LLint * size); char *readfile_utf8(const char *fil); char *readfile_or(const char *fil, const char *defaultdata); #if 0 void check_rate(TStamp stat_timestart, int maxrate); #endif // liens int liens_record(char *adr, char *fil, char *save, char *former_adr, char *former_fil, char *codebase); // backing, routines externes int back_pluggable_sockets(struct_back * sback, httrackp * opt); int back_pluggable_sockets_strict(struct_back * sback, httrackp * opt); int back_fill(struct_back * sback, httrackp * opt, cache_back * cache, int ptr, int numero_passe); int backlinks_done(const struct_back * sback, lien_url ** liens, int lien_tot, int ptr); int back_fillmax(struct_back * sback, httrackp * opt, cache_back * cache, int ptr, int numero_passe); int ask_continue(httrackp * opt); int nombre_digit(int n); // Java #if 0 int hts_add_file(char *file, int file_position); #endif // Polling #if HTS_POLL int check_flot(T_SOC s); int check_stdin(void); int read_stdin(char *s, int max); #endif int check_sockerror(T_SOC s); int check_sockdata(T_SOC s); /* external modules */ int htsAddLink(htsmoduleStruct * str, char *link); // Void void voidf(void); #define HTS_TOPINDEX "TOP_INDEX_HTTRACK" #endif httrack-3.49.5/src/htsconfig.h0000644000175000017500000000777614336470674013160 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Global engine definition file */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ // Ensemble des paramètres du robot #ifndef HTTRACK_GLOBAL_ENGINE_DEFH #define HTTRACK_GLOBAL_ENGINE_DEFH // ------------------------------------------------------------ // Définitions du ROBOT // accès des miroirs pour les autres utilisateurs (0/1) #define HTS_ACCESS 1 // temps de poll d'une socket: 1/10s #define HTS_SOCK_SEC 0 #define HTS_SOCK_MS 100000 // nom par défaut #define DEFAULT_HTML "index.html" // nom par défaut pour / en ftp #define DEFAULT_FTP "index.txt" // extension par défaut pour fichiers n'en ayant pas #define DEFAULT_EXT ".html" #define DEFAULT_EXT_SHORT ".htm" //#define DEFAULT_BIN_EXT ".bin" //#define DEFAULT_BIN_EXT_SHORT ".bin" //#define DEFAULT_EXT ".txt" //#define DEFAULT_EXT_SHORT ".txt" // éviter les /nul, /con.. #define HTS_OVERRIDE_DOS_FOLDERS 1 // indexing (keyword) #define HTS_MAKE_KEYWORD_INDEX 1 // poll stdin autorisé? (0/1) #define HTS_POLL 1 // le slash est un html par défaut (exemple/ est toujours un html) #define HTS_SLASH_ISHTML 1 // supprimer index si un répertoire identique existe #define HTS_REMOVE_ANNOYING_INDEX 1 // écriture directe dur disque possible (0/1) #define HTS_DIRECTDISK 1 // always direct-to-disk (0/1) #define HTS_DIRECTDISK_ALWAYS 1 // gérer une table de hachage? // REMOVED // #define HTS_HASH 1 // fast cache (build hash table) #define HTS_FAST_CACHE 1 // le > peut être considéré comme un tag de fermeture de commentaire (\r\n"\ "\r\n"\ "Link caught!\r\n"\ "\r\n"\ "\r\n"\ "\r\n"\ "

Link captured into HTTrack Website Copier, you can now restore your proxy preferences!

\r\n"\ "

\r\n"\ "

Clic here to go back

\r\n"\ ""\ "\r\n"\ "\r\n"\ #endif #endif httrack-3.49.5/src/htscache.h0000644000175000017500000000731214336470674012740 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: httrack.c subroutines: */ /* cache system (index and stores files in cache) */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTSCACHE_DEFH #define HTSCACHE_DEFH /* Library internal definictions */ #ifdef HTS_INTERNAL_BYTECODE #include "htsglobal.h" #include /* Forward definitions */ #ifndef HTS_DEF_FWSTRUCT_httrackp #define HTS_DEF_FWSTRUCT_httrackp typedef struct httrackp httrackp; #endif #ifndef HTS_DEF_FWSTRUCT_cache_back #define HTS_DEF_FWSTRUCT_cache_back typedef struct cache_back cache_back; #endif #ifndef HTS_DEF_FWSTRUCT_htsblk #define HTS_DEF_FWSTRUCT_htsblk typedef struct htsblk htsblk; #endif // cache void cache_mayadd(httrackp * opt, cache_back * cache, htsblk * r, const char *url_adr, const char *url_fil, const char *url_save); void cache_add(httrackp * opt, cache_back * cache, const htsblk * r, const char *url_adr, const char *url_fil, const char *url_save, int all_in_cache, const char *path_prefix); htsblk cache_read(httrackp * opt, cache_back * cache, const char *adr, const char *fil, const char *save, char *location); htsblk cache_read_ro(httrackp * opt, cache_back * cache, const char *adr, const char *fil, const char *save, char *location); htsblk cache_read_including_broken(httrackp * opt, cache_back * cache, const char *adr, const char *fil); htsblk cache_readex(httrackp * opt, cache_back * cache, const char *adr, const char *fil, const char *save, char *location, char *return_save, int readonly); htsblk *cache_header(httrackp * opt, cache_back * cache, const char *adr, const char *fil, htsblk * r); void cache_init(cache_back * cache, httrackp * opt); int cache_writedata(FILE * cache_ndx, FILE * cache_dat, const char *str1, const char *str2, char *outbuff, int len); int cache_readdata(cache_back * cache, const char *str1, const char *str2, char **inbuff, int *len); void cache_rstr(FILE * fp, char *s); char *cache_rstr_addr(FILE * fp); int cache_brstr(char *adr, char *s); int cache_quickbrstr(char *adr, char *s); int cache_brint(char *adr, int *i); void cache_rint(FILE * fp, int *i); void cache_rLLint(FILE * fp, LLint * i); int cache_wstr(FILE * fp, const char *s); int cache_wint(FILE * fp, int i); int cache_wLLint(FILE * fp, LLint i); #endif #endif httrack-3.49.5/src/htsbauth.h0000644000175000017500000000575314336470674013007 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: httrack.c subroutines: */ /* basic authentication: password storage */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTSBAUTH_DEFH #define HTSBAUTH_DEFH #include // robots wizard #ifndef HTS_DEF_FWSTRUCT_bauth_chain #define HTS_DEF_FWSTRUCT_bauth_chain typedef struct bauth_chain bauth_chain; #endif struct bauth_chain { char prefix[1024]; /* www.foo.com/secure/ */ char auth[1024]; /* base-64 encoded user:pass */ struct bauth_chain *next; /* next element */ }; // buffer pour les cookies et authentification #ifndef HTS_DEF_FWSTRUCT_t_cookie #define HTS_DEF_FWSTRUCT_t_cookie typedef struct t_cookie t_cookie; #endif struct t_cookie { int max_len; char data[32768]; bauth_chain auth; }; /* Library internal definictions */ #ifdef HTS_INTERNAL_BYTECODE // cookies int cookie_add(t_cookie * cookie, const char *cook_name, const char *cook_value, const char *domain, const char *path); int cookie_del(t_cookie * cookie, const char *cook_name, const char *domain, const char *path); int cookie_load(t_cookie * cookie, const char *path, const char *name); int cookie_save(t_cookie * cookie, const char *name); void cookie_insert(char *s, const char *ins); void cookie_delete(char *s, size_t pos); const char *cookie_get(char *buffer, const char *cookie_base, int param); char *cookie_find(char *s, const char *cook_name, const char *domain, const char *path); char *cookie_nextfield(char *a); // basic auth int bauth_add(t_cookie * cookie, const char *adr, const char *fil, const char *auth); char *bauth_check(t_cookie * cookie, const char *adr, const char *fil); char *bauth_prefix(char *buffer, const char *adr, const char *fil); #endif #endif httrack-3.49.5/src/htsbasenet.h0000644000175000017500000001121714336470674013315 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Basic net definitions */ /* Used in .c and .h files that needs hostent and so */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTS_DEFBASENETH #define HTS_DEFBASENETH #ifdef _WIN32 #if HTS_INET6==0 #include #else #undef HTS_USESCOPEID #define WIN32_LEAN_AND_MEAN // KB955045 (http://support.microsoft.com/kb/955045) // To execute an application using this function on earlier versions of Windows // (Windows 2000, Windows NT, and Windows Me/98/95), then it is mandatary to #include Ws2tcpip.h // and also Wspiapi.h. When the Wspiapi.h header file is included, the 'getaddrinfo' function is // #defined to the 'WspiapiGetAddrInfo' inline function in Wspiapi.h. #include #include //#include //#include #endif #else #define HTS_USESCOPEID #define INVALID_SOCKET -1 #endif #ifdef __cplusplus extern "C" { #endif #if HTS_USEOPENSSL /* OpensSSL crypto routines by Eric Young (eay@cryptsoft.com) Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) All rights reserved */ #ifndef HTS_OPENSSL_H_INCLUDED #define HTS_OPENSSL_H_INCLUDED /* OpenSSL definitions */ #include #include #include /* OpenSSL structure */ #include /* Global SSL context */ extern SSL_CTX *openssl_ctx; #endif #endif /** RFC2616 status-codes ('statuscode' member of htsblk) **/ typedef enum HTTPStatusCode { HTTP_CONTINUE = 100, HTTP_SWITCHING_PROTOCOLS = 101, HTTP_OK = 200, HTTP_CREATED = 201, HTTP_ACCEPTED = 202, HTTP_NON_AUTHORITATIVE_INFORMATION = 203, HTTP_NO_CONTENT = 204, HTTP_RESET_CONTENT = 205, HTTP_PARTIAL_CONTENT = 206, HTTP_MULTIPLE_CHOICES = 300, HTTP_MOVED_PERMANENTLY = 301, HTTP_FOUND = 302, HTTP_SEE_OTHER = 303, HTTP_NOT_MODIFIED = 304, HTTP_USE_PROXY = 305, HTTP_TEMPORARY_REDIRECT = 307, HTTP_BAD_REQUEST = 400, HTTP_UNAUTHORIZED = 401, HTTP_PAYMENT_REQUIRED = 402, HTTP_FORBIDDEN = 403, HTTP_NOT_FOUND = 404, HTTP_METHOD_NOT_ALLOWED = 405, HTTP_NOT_ACCEPTABLE = 406, HTTP_PROXY_AUTHENTICATION_REQUIRED = 407, HTTP_REQUEST_TIME_OUT = 408, HTTP_CONFLICT = 409, HTTP_GONE = 410, HTTP_LENGTH_REQUIRED = 411, HTTP_PRECONDITION_FAILED = 412, HTTP_REQUEST_ENTITY_TOO_LARGE = 413, HTTP_REQUEST_URI_TOO_LARGE = 414, HTTP_UNSUPPORTED_MEDIA_TYPE = 415, HTTP_REQUESTED_RANGE_NOT_SATISFIABLE = 416, HTTP_EXPECTATION_FAILED = 417, HTTP_INTERNAL_SERVER_ERROR = 500, HTTP_NOT_IMPLEMENTED = 501, HTTP_BAD_GATEWAY = 502, HTTP_SERVICE_UNAVAILABLE = 503, HTTP_GATEWAY_TIME_OUT = 504, HTTP_HTTP_VERSION_NOT_SUPPORTED = 505 } HTTPStatusCode; /** Internal HTTrack status-codes ('statuscode' member of htsblk) **/ typedef enum BackStatusCode { STATUSCODE_INVALID = -1, STATUSCODE_TIMEOUT = -2, STATUSCODE_SLOW = -3, STATUSCODE_CONNERROR = -4, STATUSCODE_NON_FATAL = -5, STATUSCODE_SSL_HANDSHAKE = -6, STATUSCODE_TOO_BIG = -7, STATUSCODE_TEST_OK = -10 } BackStatusCode; /** HTTrack status ('status' member of of 'lien_back') **/ typedef enum HTTrackStatus { STATUS_ALIVE = -103, STATUS_FREE = -1, STATUS_READY = 0, STATUS_TRANSFER = 1, STATUS_CHUNK_CR = 97, STATUS_CHUNK_WAIT = 98, STATUS_WAIT_HEADERS = 99, STATUS_CONNECTING = 100, STATUS_WAIT_DNS = 101, STATUS_SSL_WAIT_HANDSHAKE = 102, STATUS_FTP_TRANSFER = 1000, STATUS_FTP_READY = 1001 } HTTrackStatus; #ifdef __cplusplus } #endif #endif httrack-3.49.5/src/htssafe.h0000644000175000017500000001710614336470674012615 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: htssafe.h safe strings operations, and asserts */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTSSAFE_DEFH #define HTSSAFE_DEFH #include #include #include #include "htsglobal.h" /** * Emergency logging. * Default is to use libhttrack one. */ #if (!defined(HTSSAFE_ABORT_FUNCTION) && defined(LIBHTTRACK_EXPORTS)) /** Assert error callback. **/ #ifndef HTS_DEF_FWSTRUCT_htsErrorCallback #define HTS_DEF_FWSTRUCT_htsErrorCallback typedef void (*htsErrorCallback) (const char *msg, const char *file, int line); #ifdef __cplusplus extern "C" { #endif HTSEXT_API htsErrorCallback hts_get_error_callback(void); #ifdef __cplusplus } #endif #endif #define HTSSAFE_ABORT_FUNCTION(A,B,C) do { \ htsErrorCallback callback = hts_get_error_callback(); \ if (callback != NULL) { \ callback(A,B,C); \ } \ } while(0) #endif /** * Log an abort condition, and calls abort(). */ #define abortLog(a) abortf_(a, __FILE__, __LINE__) /** * Fatal assertion check. */ #define assertf__(exp, sexp, file, line) (void) ( (exp) || (abortf_(sexp, file, line), 0) ) /** * Fatal assertion check. */ #define assertf_(exp, file, line) assertf__(exp, #exp, file, line) /** * Fatal assertion check. */ #define assertf(exp) assertf_(exp, __FILE__, __LINE__) static HTS_UNUSED void log_abort_(const char *msg, const char *file, int line) { fprintf(stderr, "%s failed at %s:%d\n", msg, file, line); fflush(stderr); } static HTS_UNUSED void abortf_(const char *exp, const char *file, int line) { #ifdef HTSSAFE_ABORT_FUNCTION HTSSAFE_ABORT_FUNCTION(exp, file, line); #endif log_abort_(exp, file, line); abort(); } /** * Check whether 'VAR' is of type char[]. */ #if (defined(__GNUC__) && !defined(__cplusplus)) /* Note: char[] and const char[] are compatible */ #define HTS_IS_CHAR_BUFFER(VAR) ( __builtin_types_compatible_p ( typeof (VAR), char[] ) ) #else /* Note: a bit lame as char[8] won't be seen. */ #define HTS_IS_CHAR_BUFFER(VAR) ( sizeof(VAR) != sizeof(char*) ) #endif #define HTS_IS_NOT_CHAR_BUFFER(VAR) ( ! HTS_IS_CHAR_BUFFER(VAR) ) /* Compile-time checks. */ static HTS_UNUSED void htssafe_compile_time_check_(void) { char array[32]; char *pointer = array; char check_array[HTS_IS_CHAR_BUFFER(array) ? 1 : -1]; char check_pointer[HTS_IS_CHAR_BUFFER(pointer) ? -1 : 1]; (void) pointer; (void) check_array; (void) check_pointer; } /** * Append at most N characters from "B" to "A". * If "A" is a char[] variable whose size is not sizeof(char*), then the size * is assumed to be the capacity of this array. */ #define strncatbuff(A, B, N) \ ( HTS_IS_NOT_CHAR_BUFFER(A) \ ? strncat(A, B, N) \ : strncat_safe_(A, sizeof(A), B, \ HTS_IS_NOT_CHAR_BUFFER(B) ? (size_t) -1 : sizeof(B), N, \ "overflow while appending '" #B "' to '"#A"'", __FILE__, __LINE__) ) /** * Append characters of "B" to "A". * If "A" is a char[] variable whose size is not sizeof(char*), then the size * is assumed to be the capacity of this array. */ #define strcatbuff(A, B) \ ( HTS_IS_NOT_CHAR_BUFFER(A) \ ? strcat(A, B) \ : strncat_safe_(A, sizeof(A), B, \ HTS_IS_NOT_CHAR_BUFFER(B) ? (size_t) -1 : sizeof(B), (size_t) -1, \ "overflow while appending '" #B "' to '"#A"'", __FILE__, __LINE__) ) /** * Copy characters from "B" to "A". * If "A" is a char[] variable whose size is not sizeof(char*), then the size * is assumed to be the capacity of this array. */ #define strcpybuff(A, B) \ ( HTS_IS_NOT_CHAR_BUFFER(A) \ ? strcpy(A, B) \ : strcpy_safe_(A, sizeof(A), B, \ HTS_IS_NOT_CHAR_BUFFER(B) ? (size_t) -1 : sizeof(B), \ "overflow while copying '" #B "' to '"#A"'", __FILE__, __LINE__) ) /** * Append characters of "B" to "A", "A" having a maximum capacity of "S". */ #define strlcatbuff(A, B, S) \ strncat_safe_(A, S, B, \ HTS_IS_NOT_CHAR_BUFFER(B) ? (size_t) -1 : sizeof(B), (size_t) -1, \ "overflow while appending '" #B "' to '"#A"'", __FILE__, __LINE__) /** * Copy characters of "B" to "A", "A" having a maximum capacity of "S". */ #define strlcpybuff(A, B, S) \ strcpy_safe_(A, S, B, \ HTS_IS_NOT_CHAR_BUFFER(B) ? (size_t) -1 : sizeof(B), \ "overflow while copying '" #B "' to '"#A"'", __FILE__, __LINE__) /** strnlen replacement (autotools). **/ #if ( ! defined(_WIN32) && ! defined(HAVE_STRNLEN) ) static HTS_UNUSED size_t strnlen(const char *s, size_t maxlen) { size_t i; for(i = 0 ; i < maxlen && s[i] != '\0' ; i++) ; return i; } #endif static HTS_INLINE HTS_UNUSED size_t strlen_safe_(const char *source, const size_t sizeof_source, const char *file, int line) { size_t size; assertf_( source != NULL, file, line ); size = sizeof_source != (size_t) -1 ? strnlen(source, sizeof_source) : strlen(source); assertf_( size < sizeof_source, file, line ); return size; } static HTS_INLINE HTS_UNUSED char* strncat_safe_(char *const dest, const size_t sizeof_dest, const char *const source, const size_t sizeof_source, const size_t n, const char *exp, const char *file, int line) { const size_t source_len = strlen_safe_(source, sizeof_source, file, line); const size_t dest_len = strlen_safe_(dest, sizeof_dest, file, line); /* note: "size_t is an unsigned integral type" ((size_t) -1 is positive) */ const size_t source_copy = source_len <= n ? source_len : n; const size_t dest_final_len = dest_len + source_copy; assertf__(dest_final_len < sizeof_dest, exp, file, line); memcpy(dest + dest_len, source, source_copy); dest[dest_final_len] = '\0'; return dest; } static HTS_INLINE HTS_UNUSED char* strcpy_safe_(char *const dest, const size_t sizeof_dest, const char *const source, const size_t sizeof_source, const char *exp, const char *file, int line) { assertf_(sizeof_dest != 0, file, line); dest[0] = '\0'; return strncat_safe_(dest, sizeof_dest, source, sizeof_source, (size_t) -1, exp, file, line); } #define malloct(A) malloc(A) #define calloct(A,B) calloc((A), (B)) #define freet(A) do { if ((A) != NULL) { free(A); (A) = NULL; } } while(0) #define strdupt(A) strdup(A) #define realloct(A,B) realloc(A, B) #define memcpybuff(A, B, N) memcpy((A), (B), (N)) #endif httrack-3.49.5/src/htsbase.h0000644000175000017500000000573714336470674012620 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Basic definitions */ /* Used in .c files for basic (malloc() ..) definitions */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTS_BASICH #define HTS_BASICH #ifdef __cplusplus extern "C" { #endif #include "htsglobal.h" #include "htsstrings.h" #include "htssafe.h" #include #include #ifndef _WIN32 #include #endif #include #include #ifndef _WIN32 #include #endif #include #ifdef _WIN32 #else #include #endif #include /* GCC extension */ #ifndef HTS_UNUSED #ifdef __GNUC__ #define HTS_UNUSED __attribute__ ((unused)) #define HTS_STATIC static __attribute__ ((unused)) #define HTS_INLINE __inline__ #define HTS_PRINTF_FUN(fmt, arg) __attribute__ ((format (printf, fmt, arg))) #else #define HTS_UNUSED #define HTS_STATIC static #define HTS_INLINE #define HTS_PRINTF_FUN(fmt, arg) #endif #endif #undef min #undef max #define min(a,b) ((a)>(b)?(b):(a)) #define max(a,b) ((a)>(b)?(a):(b)) #ifndef _WIN32 #undef Sleep #define min(a,b) ((a)>(b)?(b):(a)) #define max(a,b) ((a)>(b)?(a):(b)) #define Sleep(a) { if (((a)*1000)%1000000) usleep(((a)*1000)%1000000); if (((a)*1000)/1000000) sleep(((a)*1000)/1000000); } #endif // teste égalité de 2 chars, case insensitive #define hichar(a) ((((a)>='a') && ((a)<='z')) ? ((a)-('a'-'A')) : (a)) #define streql(a,b) (hichar(a)==hichar(b)) // caractère maj #define isUpperLetter(a) ( ((a) >= 'A') && ((a) <= 'Z') ) /* Library internal definictions */ #ifdef HTS_INTERNAL_BYTECODE // functions #ifdef _WIN32 #define DynamicGet(handle, sym) GetProcAddress(handle, sym) #else #define DynamicGet(handle, sym) dlsym(handle, sym) #endif #endif #ifdef __cplusplus } #endif #endif httrack-3.49.5/src/htsback.h0000644000175000017500000001343214336470674012575 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: httrack.c subroutines: */ /* backing system (multiple socket download) */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTSBACK_DEFH #define HTSBACK_DEFH #include "htsglobal.h" #if HTS_XGETHOST #if USE_BEGINTHREAD #include "htsthread.h" #endif #endif /* Forward definitions */ #ifndef HTS_DEF_FWSTRUCT_httrackp #define HTS_DEF_FWSTRUCT_httrackp typedef struct httrackp httrackp; #endif #ifndef HTS_DEF_FWSTRUCT_struct_back #define HTS_DEF_FWSTRUCT_struct_back typedef struct struct_back struct_back; #endif #ifndef HTS_DEF_FWSTRUCT_cache_back #define HTS_DEF_FWSTRUCT_cache_back typedef struct cache_back cache_back; #endif #ifndef HTS_DEF_FWSTRUCT_lien_back #define HTS_DEF_FWSTRUCT_lien_back typedef struct lien_back lien_back; #endif #ifndef HTS_DEF_FWSTRUCT_htsblk #define HTS_DEF_FWSTRUCT_htsblk typedef struct htsblk htsblk; #endif /* Library internal definictions */ #ifdef HTS_INTERNAL_BYTECODE // create/destroy struct_back *back_new(httrackp *opt, int back_max); void back_free(struct_back ** sback); // backing #define BACK_ADD_TEST "(dummy)" #define BACK_ADD_TEST2 "(dummy2)" int back_index(httrackp * opt, struct_back * sback, const char *adr, const char *fil, const char *sav); int back_available(const struct_back * sback); LLint back_incache(const struct_back * sback); int back_done_incache(const struct_back * sback); HTS_INLINE int back_exist(struct_back * sback, httrackp * opt, const char *adr, const char *fil, const char *sav); int back_nsoc(const struct_back * sback); int back_nsoc_overall(const struct_back * sback); int back_add(struct_back * sback, httrackp * opt, cache_back * cache, const char *adr, const char *fil, const char *save, const char *referer_adr, const char *referer_fil, int test); int back_add_if_not_exists(struct_back * sback, httrackp * opt, cache_back * cache, const char *adr, const char *fil, const char *save, const char *referer_adr, const char *referer_fil, int test); int back_stack_available(struct_back * sback); int back_search(httrackp * opt, struct_back * sback); int back_search_quick(struct_back * sback); void back_clean(httrackp * opt, cache_back * cache, struct_back * sback); int back_cleanup_background(httrackp * opt, cache_back * cache, struct_back * sback); void back_wait(struct_back * sback, httrackp * opt, cache_back * cache, TStamp stat_timestart); int back_letlive(httrackp * opt, cache_back * cache, struct_back * sback, const int p); int back_searchlive(httrackp * opt, struct_back * sback, const char *search_addr); void back_connxfr(htsblk * src, htsblk * dst); void back_move(lien_back * src, lien_back * dst); void back_copy_static(const lien_back * src, lien_back * dst); int back_serialize(FILE * fp, const lien_back * src); int back_unserialize(FILE * fp, lien_back ** dst); int back_serialize_ref(httrackp * opt, const lien_back * src); int back_unserialize_ref(httrackp * opt, const char *adr, const char *fil, lien_back ** dst); void back_set_finished(struct_back * sback, const int p); void back_set_locked(struct_back * sback, const int p); void back_set_unlocked(struct_back * sback, const int p); int back_delete(httrackp * opt, cache_back * cache, struct_back * sback, const int p); void back_index_unlock(struct_back * sback, const int p); int back_clear_entry(lien_back * back); int back_flush_output(httrackp * opt, cache_back * cache, struct_back * sback, const int p); void back_delete_all(httrackp * opt, cache_back * cache, struct_back * sback); int back_maydelete(httrackp * opt, cache_back * cache, struct_back * sback, const int p); void back_maydeletehttp(httrackp * opt, cache_back * cache, struct_back * sback, const int p); int back_trylive(httrackp * opt, cache_back * cache, struct_back * sback, const int p); int back_finalize(httrackp * opt, cache_back * cache, struct_back * sback, const int p); void back_info(struct_back * sback, int i, int j, FILE * fp); void back_infostr(struct_back * sback, int i, int j, char *s); LLint back_transferred(LLint add, struct_back * sback); // hostback #if HTS_XGETHOST void back_solve(httrackp * opt, lien_back * sback); int host_wait(httrackp * opt, lien_back * sback); #endif int back_checksize(httrackp * opt, lien_back * eback, int check_only_totalsize); int back_checkmirror(httrackp * opt); #endif #endif httrack-3.49.5/src/htsalias.h0000644000175000017500000000417614336470674012773 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: htsalias.h subroutines: */ /* alias for command-line options and config files */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTSALIAS_DEFH #define HTSALIAS_DEFH /* Library internal definictions */ #ifdef HTS_INTERNAL_BYTECODE extern const char *hts_optalias[][4]; int optalias_check(int argc, const char *const *argv, int n_arg, int *return_argc, char **return_argv, char *return_error); int optalias_find(const char *token); const char *optalias_help(const char *token); int optreal_find(const char *token); int optinclude_file(const char *name, int *argc, char **argv, char *x_argvblk, int *x_ptr); const char *optreal_value(int p); const char *optalias_value(int p); const char *opttype_value(int p); const char *opthelp_value(int p); const char *hts_gethome(void); void expand_home(String * str); #endif #endif httrack-3.49.5/src/hts-indextmpl.h0000644000175000017500000014632014336470674013761 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Index.html templates file */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef HTTRACK_DEFTMPL #define HTTRACK_DEFTMPL /* Index for each project */ /* regen: (for i in *; do echo $i; cat $i | sed -e 's/"/\\"/g' | sed -e 's/^\(.*\)$/ "\1"LF\\/'; done) > /tmp/1.txt */ /* %s = INFO */ #define HTS_INDEX_HEADER \ ""LF\ ""LF\ ""LF\ ""LF\ " "LF\ " "LF\ " "LF\ " Local index - HTTrack Website Copier"LF\ " %s"LF\ " "LF\ ""LF\ ""LF\ ""LF\ "
· %s
"LF\ " "LF\ " "LF\ " "LF\ "
HTTrack Website Copier - Open Source offline browser
"LF\ ""LF\ ""LF\ ""LF\ ""LF\ "
"LF\ " "LF\ " "LF\ " "LF\ " "LF\ "
"LF\ " "LF\ " "LF\ " "LF\ " "LF\ "
"LF\ ""LF\ ""LF\ "

Index of locally available sites:

"LF\ " "LF /* %s = URL */ /* %s = TITLE */ #define HTS_INDEX_BODY \ ""LF\ " "LF\ " "LF\ " "LF #define HTS_INDEX_BODYCAT \ ""LF\ " "LF /* %s = INFO */ #define HTS_INDEX_FOOTER \ ""LF\ "
"LF\ " ·"LF\ " "LF\ " %s"LF\ " "LF\ "
"LF\ "
"LF\ " %s"LF\ "
"LF\ "
"LF\ "
"LF\ "
"LF\ "
"LF\ " Mirror and index made by HTTrack Website Copier [XR&CO'2014]"LF\ "
"LF\ " %s"LF\ " "LF\ ""LF\ ""LF\ "
"LF\ "
"LF\ "
"LF\ ""LF\ ""LF\ " "LF\ " "LF\ " "LF\ "
© 2014 Xavier Roche & other contributors - Web Design: Kauler Leto.
"LF\ ""LF\ ""LF\ ""LF\ ""LF\ ""LF\ ""LF /* Index for all projects (top index) */ /* %s = INFO */ #define HTS_TOPINDEX_HEADER \ ""LF\ ""LF\ ""LF\ ""LF\ " "LF\ " "LF\ " "LF\ " List of available projects - HTTrack Website Copier"LF\ " %s"LF\ ""LF\ " "LF\ ""LF\ ""LF\ ""LF\ ""LF\ " "LF\ " "LF\ " "LF\ "
HTTrack Website Copier - Open Source offline browser
"LF\ ""LF\ ""LF\ ""LF\ ""LF\ "
"LF\ " "LF\ " "LF\ " "LF\ " "LF\ "
"LF\ " "LF\ " "LF\ " "LF\ " "LF\ "
"LF\ ""LF\ ""LF\ ""LF\ "

Index of locally available projects:

"LF\ " "LF /* %s = URL */ /* %s = TITLE */ #define HTS_TOPINDEX_BODY \ ""LF\ " "LF\ " "LF\ " "LF /* %s = INFO */ #define HTS_TOPINDEX_FOOTER \ ""LF\ "
"LF\ " · %s"LF\ "
"LF\ "
"LF\ "
"LF\ " Mirror and index made by HTTrack Website Copier [XR&CO'2014]"LF\ "
"LF\ " %s"LF\ " "LF\ ""LF\ ""LF\ "
"LF\ "
"LF\ "
"LF\ ""LF\ ""LF\ " "LF\ " "LF\ " "LF\ "
© 2014 Xavier Roche & other contributors - Web Design: Kauler Leto.
"LF\ ""LF\ ""LF\ ""LF\ ""LF\ ""LF\ ""LF /* Other files (fade and backblue images) */ #define HTS_LOG_SECURITY_WARNING "note:\tthe hts-log.txt file, and hts-cache folder, may contain sensitive information,"LF\ "\tsuch as username/password authentication for websites mirrored in this project"LF\ "\tdo not share these files/folders if you want these information to remain private"LF #define HTS_DATA_UNKNOWN_HTML ""LF\ ""LF\ ""LF\ ""LF\ " "LF\ " "LF\ " "LF\ " Page not retrieved! - HTTrack Website Copier"LF\ " %s"LF\ " "LF\ ""LF\ ""LF\ ""LF\ ""LF\ " "LF\ " "LF\ " "LF\ "
HTTrack Website Copier - Open Source offline browser
"LF\ ""LF\ ""LF\ ""LF\ ""LF\ "
"LF\ " "LF\ " "LF\ " "LF\ " "LF\ "
"LF\ " "LF\ " "LF\ " "LF\ " "LF\ "
"LF\ ""LF\ "

Oops!...

"LF\ "

This page has not been retrieved by HTTrack Website Copier.

"LF\ ""LF\ "
Mirror by HTTrack Website Copier
"LF\ ""LF\ "
"LF\ "
"LF\ "
"LF\ ""LF\ ""LF\ " "LF\ " "LF\ " "LF\ "
© 2014 Xavier Roche & other contributors - Web Design: Kauler Leto.
"LF\ ""LF\ ""LF\ ""LF\ ""LF\ ""LF\ ""LF #define HTS_DATA_UNKNOWN_HTML_LEN 0 #define HTS_DATA_ERROR_HTML ""LF\ ""LF\ ""LF\ ""LF\ " "LF\ " "LF\ " "LF\ " Page not retrieved! - HTTrack Website Copier"LF\ " "LF\ ""LF\ ""LF\ ""LF\ ""LF\ " "LF\ " "LF\ " "LF\ "
HTTrack Website Copier - Open Source offline browser
"LF\ ""LF\ ""LF\ ""LF\ ""LF\ "
"LF\ " "LF\ " "LF\ " "LF\ " "LF\ "
"LF\ " "LF\ " "LF\ " "LF\ " "LF\ "
"LF\ ""LF\ "

Oops!...

"LF\ "

This page has not been retrieved by HTTrack Website Copier (%s).

"LF\ ""LF\ "
Mirror by HTTrack Website Copier
"LF\ ""LF\ ""LF\ ""LF\ "
"LF\ "
"LF\ "
"LF\ ""LF\ ""LF\ " "LF\ " "LF\ " "LF\ "
© 2014 Xavier Roche & other contributors - Web Design: Kauler Leto.
"LF\ ""LF\ ""LF\ ""LF\ ""LF\ ""LF\ ""LF // image gif "unknown" #define HTS_DATA_UNKNOWN_GIF \ "\x47\x49\x46\x38\x39\x61\x20\x0\x20\x0\xf7\xff\x0\xc0\xc0\xc0\xff\x0\x0\xfc\x3\x0\xf8\x6\x0\xf6\x9\x0\xf2\xc\x0\xf0\xf\x0\xf0\xe\x0\xed\x11\x0\xec\x13\x0\xeb\x14\x0\xe9\x15\x0\xe8\x18\x0\xe6\x18\x0\xe5\x1a\x0\xe3\x1c\x0\xe2\x1d\x0\xe1\x1e\x0\xdf\x20\x0\xdd\x23\x0\xdd\x22\x0\xdb\x23\x0\xda\x25\x0\xd9\x25\x0\xd8\x27\x0\xd6\x29\x0\xd5\x2a\x0\xd3\x2c\x0\xd2\x2d\x0"\ "\xd1\x2d\x0\xd0\x2f\x0\xcf\x30\x0\xce\x31\x0\xcb\x34\x0\xcb\x33\x0\xc8\x36\x0\xc5\x3b\x0\xc2\x3c\x0\xc0\x3f\x0\xbc\x43\x0\xba\x45\x0\xb7\x48\x0\xb4\x4c\x0\xb1\x4e\x0\xad\x51\x0\xaa\x55\x0\xa8\x58\x0\xa4\x5a\x0\xa1\x5e\x0\x9f\x60\x0\x99\x66\x0\x96\x68\x0\x93\x6c\x0\x90\x6e\x0\x8d\x72\x0\x8b\x74\x0\x8a\x75\x0\x88\x78\x0\x85\x79\x0\x82\x7d\x0\x7e\x80\x0\x7d\x82\x0\x79"\ "\x86\x0\x77\x88\x0\x73\x8b\x0\x72\x8d\x0\x70\x8e\x0\x6e\x91\x0\x6a\x95\x0\x68\x97\x0\x65\x9a\x0\x63\x9d\x0\x62\x9e\x0\x60\xa0\x0\x5d\xa2\x0\x5c\xa3\x0\x5a\xa5\x0\x57\xa9\x0\x57\xa7\x0\x54\xab\x0\x53\xac\x0\x52\xad\x0\x51\xae\x0\x4f\xb0\x0\x4e\xb1\x0\x4d\xb2\x0\x4c\xb4\x0\x49\xb6\x0\x48\xb8\x0\x46\xba\x0\x45\xbb\x0\x43\xbd\x0\x43\xbc\x0\x40\xbf\x0\x3f\xc0\x0\x3e\xc1"\ "\x0\x3d\xc2\x0\x3a\xc5\x0\x39\xc5\x0\x38\xc7\x0\x37\xc8\x0\x35\xca\x0\x34\xcb\x0\x32\xcc\x0\x31\xce\x0\x30\xd0\x0\x30\xce\x0\x2f\xd1\x0\x2e\xd1\x0\x2c\xd2\x0\x2b\xd4\x0\x2a\xd5\x0\x29\xd6\x0\x27\xd8\x0\x26\xda\x0\x26\xd8\x0\x25\xdb\x0\x24\xdc\x0\x21\xde\x0\x20\xdf\x0\x1f\xe1\x0\x1e\xe1\x0\x1c\xe3\x0\x1b\xe5\x0\x19\xe6\x0\x18\xe7\x0\x15\xeb\x0\x15\xea\x0\x14\xec\x0"\ "\x12\xed\x0\x10\xef\x0\xf\xf0\x0\xd\xf2\x0\xa\xf5\x0\x9\xf6\x0\x7\xf8\x0\x5\xfa\x0\x3\xfb\x0\x1\xfd\x0\x0\xfe\x2\x0\xfb\x4\x0\xf8\x7\x0\xf6\xa\x0\xf3\xd\x0\xee\x12\x0\xaa\x54\x0\xa5\x5a\x0\xa2\x5d\x0\xa0\x60\x0\x9c\x62\x0\x99\x66\x0\x98\x67\x0\x94\x6b\x0\x92\x6d\x0\x91\x6e\x0\x8f\x70\x0\x8c\x74\x0\x8a\x75\x0\x86\x79\x0\x83\x7c\x0\x81\x7e\x0\x7e\x82\x0"\ "\x7b\x83\x0\x79\x87\x0\x76\x8a\x0\x73\x8c\x0\x70\x8f\x0\x6a\x95\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0"\ "\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0"\ "\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x21\xf9\x4\x1\x0\x0\x0\x0\x2c\x0\x0\x0\x0\x20\x0\x20\x0\x40\x8"\ "\xff\x0\x1\x8\x1c\x48\xb0\x60\x82\x7\x16\x3a\x8c\x30\x91\x82\xc5\x8b\x82\x10\x23\xa\xa4\x81\x83\xa0\x92\x27\x56\xb6\x88\x51\x23\xb1\xa3\xc0\x38\x78\xfe\x10\x4a\xe4\xb1\xa4\xc9\x93\x1e\xf\x30\x90\x90\x41\xa2\x8e\x1e\x40\x88\x20\x41\x29\xf1\x4b\x99\x36\x75\xf6\xd0\x8c\xe8\x8\xd2\xce\x92\x94\x2e\x6d\xf2\x14\x8a\xd4\xcf\x92\x1\x4\x14\x58\x10\x1\xc3\x87\x82\x32\x6a\xe4\xe0\x81\x72\xc2\x86\x10"\ "\x1d\x83\x14\x49\xd2\x84\x8a\x96\xa3\x5\xa3\x5c\xe9\x42\x66\x8d\x1c\xb0\x4\xcf\xbc\xb1\xd3\x67\x10\x5a\x82\x80\xa\x29\x6a\xf4\xb6\xee\xce\x48\x93\x2c\x69\xb2\x4b\x50\x54\xa9\x53\x7c\x25\x6\x18\x60\xa0\x1\x5\xd\x22\x4a\xa0\x58\xe1\x22\xc6\xc\x1b\x34\x3\x10\x40\xe0\xa0\x2\x87\x88\x37\x76\xf8\x10\x82\x52\x1\x84\xb\x1e\x3a\xfe\x18\x62\x64\x9\x14\x94\x20\x48\x9c\x50\xd1\x2\x6\xc4\x23\x4c"\ "\xa4\x60\xf1\x12\xd8\xc9\x94\x2c\x60\xcc\xb8\xe1\x5b\x85\x4b\x18\x34\x70\xee\x4\x1e\x93\x66\x4e\x1e\x3f\x81\xd9\xd0\xd1\x13\xc8\x50\x60\x0\x7c\x4\x1d\x5a\xf4\x1c\x0\x22\x46\x8f\xaa\x6b\xdf\xce\xbd\xa3\xa4\x4a\x98\x38\x7d\xb\x7a\x9e\xa9\x13\xa8\x51\xa6\xba\xbf\xd\x8\x0\x3b\xff" #define HTS_DATA_UNKNOWN_GIF_LEN 1070 /* hexdump bg_rings.gif | cut -c9- - | sed -e 's/\([0-9a-f][0-9a-f]\)\([0-9a-f][0-9a-f]\)/\\x\2 \\x\1/g' | sed -e 's/ //g' | sed -e 's/^\(.*\)$/ \"\1\" \\/' */ #define HTS_DATA_BACK_GIF \ "\x47\x49\x46\x38\x39\x61\xf5\x01\xc8\x01\xa2\x00\x00\xcc\xcc\xdd" \ "\xc7\xc7\xda\xc4\xc4\xd7\xbe\xbe\xd3\xbd\xbd\xd2\xb9\xb9\xd0\xfe" \ "\x01\x02\x00\x00\x00\x21\xf9\x04\xfd\x14\x00\x06\x00\x2c\x00\x00" \ "\x00\x00\xf5\x01\xc8\x01\x40\x03\xff\x08\xba\xdc\xfe\x30\xca\x49" \ "\xab\xbd\x38\xeb\xcd\xbb\xff\x60\x28\x8e\x64\x69\x9e\x68\xaa\xae" \ "\x6c\xeb\xbe\x70\x2c\xcf\x74\x6d\xdf\x62\x20\x08\x43\xe1\xff\xc0" \ "\xa0\x70\x48\x2c\x1a\x8f\xc8\xa4\xd2\x38\x68\x06\x02\xb8\xa8\x74" \ "\x4a\xad\xc2\x74\x84\xa5\x76\xcb\xed\x7a\xbf\xe0\x30\xd8\x69\x2d" \ "\x9b\xcf\xe8\x40\x4f\xcc\x6e\xbb\xdf\xf0\xb8\x9c\x4d\x20\x40\xd1" \ "\xf8\xbc\x79\x3d\xef\xfb\xff\x42\x4d\x3b\x77\x7a\x12\x4f\x3b\x4d" \ "\x80\x6d\x03\x02\x85\x8e\x8f\x0f\x02\x8a\x93\x94\x43\x02\x84\x90" \ "\x99\x1f\x58\x95\x05\x8d\x9a\xa0\x24\x92\x9d\xa4\x6e\x03\xa1\xa8" \ "\xa1\x3c\x73\x9f\xa9\x8e\x59\xa5\xb1\x5b\xad\xae\xb5\xb6\x20\x02" \ "\xb0\x62\xb4\xb7\x28\xba\xb2\xc0\x43\xa7\xbd\xc4\xc5\x36\x7c\x5d" \ "\xc3\xc6\x10\xc8\xc1\xce\x98\xcb\xd1\xd2\x67\xa3\x5c\xbc\x8e\xd5" \ "\xce\xc0\xd7\xd3\xdd\xde\xa1\x01\xbf\x49\xdc\x33\x01\xda\xc1\xdf" \ "\xe9\xea\xe9\xe1\x4b\x76\x29\xd9\xe7\x9d\xeb\xf4\x14\x3a\xcd\xf2" \ "\x71\x82\xd0\xc4\xf1\x46\xe4\x13\xc4\xe5\x03\xa4\xac\x5e\x3f\x81" \ "\x03\x13\xca\x61\x84\xcd\x88\x04\x7c\x0a\xe7\xf0\x33\xa8\xc7\x5c" \ "\xc4\x71\x00\x7b\x71\x1a\x33\x91\xff\xca\x45\x82\x14\xf1\x20\x4c" \ "\xd8\x31\xe4\x89\x5c\x4b\x32\x96\x80\xf8\xd1\x94\xc9\x29\x23\xb5" \ "\x95\x7c\x89\x47\xcd\x91\x82\x1b\x5a\xfa\x51\x49\x33\x45\x4c\x60" \ "\x33\x7b\x2e\x6b\x47\x84\x1c\x4b\x9d\x62\x70\x0a\x85\x47\x72\xa9" \ "\xd3\x07\x3d\x18\x1c\x45\x0a\x86\xe7\x53\x0e\x3f\x4b\x05\xbd\xca" \ "\x75\x2a\xd5\x2f\x5c\x49\x0c\x54\x1a\xb6\x6c\x83\xaf\x72\xcc\x7a" \ "\xf0\x87\x4e\xad\xdb\x07\x59\xd1\x5a\x7b\x9b\x61\x2c\xdd\xbb\x0b" \ "\xd8\xca\xad\x8a\x97\x82\x57\x52\x5b\xfb\x3a\xd5\xbb\x17\xac\x60" \ "\x66\x76\x0f\xdf\x2d\x0c\x47\xb1\x83\xb8\xa4\x1c\xd3\xb5\xc8\xb8" \ "\x8d\x55\xb5\x94\xf3\x49\xa6\x5b\xf9\x4d\x60\xb5\x11\x37\xbb\x25" \ "\xdc\x99\x0b\xd9\xbe\x11\x09\x88\x36\x4b\xba\xf4\xac\xcd\xad\xb7" \ "\xad\x0e\xeb\xfa\xcd\xe6\xcc\x0a\x3f\xcf\x66\x57\xdb\x8d\x6a\xc9" \ "\xb8\x15\x9e\xde\x4d\x2f\x78\x6f\x30\xba\xc3\xc6\x3e\x97\x9c\x78" \ "\xb1\xe5\xc7\x97\x34\xef\xfa\xf5\xb7\x73\x75\xd0\xa3\x2b\x19\x8e" \ "\xd7\x78\xcb\x77\xd7\xa7\x41\xd6\xbe\x84\x7b\xdf\xbf\x17\xcd\x87" \ "\xcf\xe4\x9d\x3c\xdf\xdd\x44\x4b\xab\x5f\x7f\x06\xbd\xfb\x2d\xf3" \ "\x05\x67\x97\x3b\x60\x3a\xfd\x17\xff\xe3\xdd\x87\xdf\x7f\xf1\x09" \ "\x18\x04\x43\xff\xc1\xb0\x9f\x81\x5a\xe4\x27\x9a\x4d\x0c\xce\x21" \ "\xc8\x0e\x97\x3c\x61\xa1\x21\x16\x1e\xc2\x43\x13\x53\xd1\xb4\x60" \ "\x84\x5a\x5c\x76\x1d\x4a\x20\x86\x16\x56\x81\x25\xc6\xe1\x1f\x7d" \ "\x10\xa6\x38\xc7\x61\x28\xba\xa8\xcf\x8a\x09\x52\xb0\x43\x80\xd1" \ "\x5d\xd7\x9e\x8c\x72\x88\x58\xe3\x8f\x4b\xd9\xc7\x63\x1c\x3e\x02" \ "\x69\x24\x3d\x1f\x0e\xc9\xca\x91\x4c\xbe\x94\xa4\x92\x94\xf4\xd7" \ "\xe4\x94\xd3\x3c\x09\xe5\x39\x64\x50\xa9\x25\x24\x56\x5e\xe9\x1a" \ "\x87\x4f\x14\x77\xa3\x61\x5b\x3e\xd2\xa2\x97\x68\xa2\x59\xe6\x34" \ "\x67\xa6\xe9\x66\x6d\x6b\x5e\x45\xe2\x9b\x74\x9e\x13\x27\x71\x73" \ "\xd6\xa9\x27\x18\x77\xf6\x99\x57\x9e\x7b\x42\xe9\xe7\xa0\x29\x1c" \ "\x22\x64\xa0\x7d\x30\x42\x23\xa1\x8c\xaa\x93\xe1\xa3\x90\x46\xfa" \ "\x68\xa3\x94\x56\x6a\xe9\x94\x19\x52\xb8\x21\x87\x89\x84\xc1\xe9" \ "\x84\x14\x66\x78\xe9\xa8\x43\x01\x8a\xa8\x36\xfb\x90\xea\xa7\x0e" \ "\xa7\xb6\x5a\x44\x96\xaa\x52\xd4\xa6\xab\xb4\x02\x43\x40\x91\xb1" \ "\xb6\x70\x68\xad\x3e\x28\x3a\xdb\x3d\xbb\x2e\x84\x6b\xac\x3b\x22" \ "\x8a\x60\xae\x1c\x6c\x94\xe8\xa2\xff\x23\xba\x3a\x2c\xb2\x36\xac" \ "\x62\x0a\xb3\x4b\xe1\x98\x22\xb5\xd0\xda\x22\xed\x7b\x1e\xd2\xe9" \ "\x60\xb6\x93\x05\xfb\x03\xb6\x55\x74\x19\x1d\xb9\xe0\xee\xf6\x21" \ "\x78\x67\x58\xeb\x1e\xba\xe9\x6e\x39\x2b\x13\x32\x98\xeb\x1a\xbc" \ "\xf1\x66\x60\x21\x85\x9f\x0a\xf9\xa9\xa6\x17\x72\x95\xdd\xb7\x86" \ "\x5c\x49\x70\xae\xf3\xf2\xda\xeb\xb3\x53\x64\x17\x94\xbd\x9d\x65" \ "\x0b\xb1\x70\x8c\x5c\x12\x83\x86\x9d\xca\x71\xab\x19\x05\x46\xe0" \ "\xee\x71\x95\xc6\xf8\x11\xc3\xf5\x28\x9b\x52\x14\x1f\xd7\x76\x30" \ "\x8b\x2d\x91\x1c\x9e\xa9\x96\x98\x30\x71\x61\xf2\xa6\x96\x6f\x04" \ "\x53\x39\x58\xac\x81\x4d\xce\x6c\xdb\xcd\x24\x88\x2c\x95\x92\x2e" \ "\xdf\xb5\x73\x64\x40\xd7\x20\xae\xca\x35\x0e\x64\x5d\xd2\x35\xf8" \ "\x2c\x57\xd1\x65\xa5\x2c\x21\xd4\x52\x48\x8d\xd6\xca\x6e\x2d\x7d" \ "\x35\xd6\x52\x1c\x2d\x20\xd5\x4e\x25\x06\x76\xd6\x06\xc3\x67\xf6" \ "\xd9\x51\x88\x3d\xf6\x6c\x56\x7f\xcd\xb6\x14\x5e\xf7\x46\xf6\x4b" \ "\x75\x2f\x39\x37\xdd\x68\xe2\x6b\x50\xdc\x7d\xec\x8d\x36\x9a\x77" \ "\xcb\x1a\x91\xdf\x82\x6b\x90\x37\xc8\x9b\xa5\x97\x78\xb4\x6f\x22" \ "\xbe\xce\x47\x5c\x3f\x0e\x02\xe0\xff\xd1\x3d\x0d\xe3\x77\x96\xc7" \ "\xb0\xb8\x76\xa2\x61\x0e\x52\xe7\x2c\x68\xfd\xa5\x68\x9f\x2b\xa2" \ "\x39\xe9\xa2\xec\xb9\xfa\x61\xa6\xfb\x21\x79\xe2\x6e\xf3\x58\xf9" \ "\x53\xb1\x03\x32\x3b\xd8\xa9\x0b\xb8\x3b\x92\xf2\xfd\x0e\x6e\xee" \ "\xe7\x3a\x47\x7c\x29\x85\x67\x2b\x3a\x88\xb7\xab\xd5\xfb\x45\x16" \ "\xef\xfd\x3c\x88\xc2\xd3\x34\x7d\x65\xb0\x5a\x2a\xb2\xb3\x4c\x1e" \ "\xaf\x70\x10\x4f\x2d\x4f\xf4\x9a\xdb\x7e\xaf\xc5\x64\xe2\xa7\x1d" \ "\x32\xcc\x74\xae\x76\x3d\xe1\x73\xeb\xb0\x21\x52\xa9\x02\xe9\xbd" \ "\x97\xc9\xb3\x9e\xed\xfb\xa7\xe6\xaf\xff\xa5\xb5\x33\x5f\x79\xfc" \ "\xf7\xbf\x3e\xf1\x4f\x80\xaf\xaa\x5e\x01\x59\x94\x3e\x04\xbe\x21" \ "\x7b\xeb\xb9\xc7\x0f\x16\x38\x01\xf6\x39\xd0\x5b\xfd\x3a\xe0\x8b" \ "\x28\x98\x03\x0d\x5e\xf0\x83\x0e\xe1\x20\x0d\x12\x06\xc2\x12\x26" \ "\x41\x84\x99\xb0\xa0\x09\x69\x85\xc2\x75\x48\x70\x85\x43\x6a\x21" \ "\x70\x54\x08\x43\x3b\xc9\x90\x54\x18\xf3\x20\xf6\x7c\x75\xc3\x1e" \ "\xfa\xf0\x87\x40\x0c\xa2\x10\x87\x48\xc4\x22\x76\x2e\x87\x0c\x02" \ "\x55\x98\x8c\x88\xb5\x17\xd6\x10\x09\xf5\x63\x62\x78\x4c\xf6\xc4" \ "\x60\x40\x50\x8a\x25\xd3\x61\x15\xff\x65\x51\x07\x05\x62\xb1\x04" \ "\x24\xdc\xa2\x9b\x76\xf0\xc5\x7a\x89\x51\x8c\xc7\x2a\x23\x06\xc2" \ "\x78\xc6\x06\x81\x6a\x10\x93\x5a\xe3\xa3\x34\xb5\x29\x2d\x52\x62" \ "\x63\x5f\xbc\x5f\x9a\xa2\xd8\x13\x43\xd9\x31\x44\x5e\xa4\xd4\xf6" \ "\x04\x78\xab\x40\x3a\xc5\x89\x9d\xc0\x23\xd8\x02\x58\xa7\xe8\xe5" \ "\x8b\x8a\x7d\x20\x20\x7d\xfe\x58\x1b\x45\x8a\x10\x92\x2e\x89\xd3" \ "\x20\xe9\x24\x49\xd2\xb1\xb1\x0b\x9d\x0c\xd2\xa9\x9a\xa7\x46\x05" \ "\xd0\x30\x44\xa1\x0b\x94\x21\xd5\x58\xbe\x2f\x84\xd2\x16\x0d\xac" \ "\xcd\x2b\x4b\xc9\x81\x53\x1a\x81\x5d\x21\xa1\x24\x52\x56\x49\xcb" \ "\x11\xd8\xb2\x28\xe9\xe0\x64\x2f\xa5\xf1\x24\x52\x52\x81\x91\xbe" \ "\x1b\x26\x45\x92\x64\x4c\x19\xb8\x89\x97\xca\xd4\x43\xb0\x66\xc9" \ "\x01\x5d\x0a\x27\x9a\x7d\x59\x50\x33\x3f\x00\x3f\x6c\xae\x66\x3f" \ "\xb8\x5c\x81\x1e\x1d\xe7\xcd\xff\x08\x29\x9c\x22\x18\xa7\x89\x7a" \ "\x28\x3f\x6b\x7a\x81\x43\x8e\xc4\x4e\x79\x70\xa1\xbe\xc7\x21\x12" \ "\x83\xd0\x44\x41\x76\x8a\x54\xcf\xa4\xfd\xf2\x82\x57\xcc\xc3\x72" \ "\xfc\x02\xa5\x6d\x52\x49\x9d\x84\xa4\xa6\x07\x20\x32\x81\x2b\x21" \ "\xcc\x9d\xfa\x88\xa7\x23\x80\x35\xff\xad\x72\xf9\x20\x02\xc8\xec" \ "\x8d\x41\x23\x58\x18\x89\x86\x04\x93\x49\x90\x92\x45\x95\x94\x4f" \ "\xb5\x20\xf4\x0b\x22\x15\xcd\x3f\x0b\x90\xd2\x18\x9c\x54\x1e\x83" \ "\xca\x68\x25\x36\x8a\x97\x56\x16\x21\x94\x32\xbd\x97\x26\x29\x37" \ "\xaa\x53\xde\x0d\x4a\x25\xed\x09\x44\x91\xf0\xba\xfd\x1d\x61\x58" \ "\x43\xb5\xa2\x96\x5e\x4a\xd4\xce\x4d\x45\x25\x39\x2d\x4d\x50\x0d" \ "\x12\x55\xbd\x71\x90\x30\xbc\x60\xaa\x33\x8a\x4a\x1f\xad\xde\x74" \ "\x88\xc8\x18\xda\x90\x68\x5a\x16\xaf\x12\xa1\x97\x49\x95\xcd\x8f" \ "\x12\xa2\xcc\x82\xd6\xc8\xac\x42\x50\xa8\xe0\xd2\x0a\x8c\x04\xd1" \ "\x35\x08\x53\xf5\x27\x50\xbb\x3a\x90\x72\x56\x15\x7b\x1c\xcd\x87" \ "\x5c\x2d\x77\xd7\x58\xe4\xd5\x18\x85\x9d\x60\x39\x01\xf0\xd7\xca" \ "\x84\x67\x6d\xde\x84\x6b\x5d\x9d\x03\x59\x6f\x26\xb6\x14\xce\xb9" \ "\x6c\x01\x16\xcb\x00\x2f\xe1\x69\x20\x83\x65\x9d\x97\x0e\x6b\x8b" \ "\xa6\x70\x56\x01\xb1\xdc\xda\xaf\xd8\x7a\x5a\x05\x68\x16\x69\x2a" \ "\x35\xed\x69\x25\x0b\x0c\xb2\x96\x2c\x21\xb6\x95\x61\x37\x1b\x27" \ "\x5b\xce\xd2\x16\x28\xa8\x53\x48\x6b\x15\x90\x26\xd2\xa2\x62\x9d" \ "\x9c\x6d\x6c\x69\x42\x6b\x0c\xe4\xff\x2e\xf6\xb7\x6a\x75\x8c\x72" \ "\xe1\xc0\x5c\xc2\xba\x49\x34\x17\x31\x2e\xd4\x5e\x6b\xd8\xcd\x70" \ "\xf7\xa2\xbe\x7d\xd3\x6d\x3e\xa2\xdd\x9b\x4d\x77\xb9\xb0\x19\xd9" \ "\x62\x85\x29\x99\xef\xfa\x80\xab\xac\xa4\x53\x79\x33\xe1\xde\x5e" \ "\x79\xb3\x91\xe9\x6d\x49\x6e\x59\x07\x5d\x54\x8d\x57\x27\xf0\x65" \ "\x62\x7d\x63\x11\x5b\xa4\x54\x37\x69\xa9\x45\xaf\x77\xbf\x72\xe0" \ "\x7c\x05\xca\x7d\x68\x69\x30\xb8\x02\xb5\x5f\x79\xca\x65\xbe\x94" \ "\x4a\xf0\xe9\x56\xa3\xe1\x3e\xa0\xf3\x87\x03\xae\xed\x6a\x19\x23" \ "\x61\xed\x9d\x2a\xc0\xdd\x51\x70\x0f\x3b\x5c\x1b\x0c\x87\x22\xc4" \ "\x50\x94\xe1\x79\xdd\x53\xe1\x7a\xf4\x97\x23\x14\x84\xb1\x33\x4a" \ "\x6c\x8c\x1b\x27\xc5\xc5\xeb\xd1\xf1\x33\xa6\xc8\xe2\xda\x02\x99" \ "\xc3\xbc\x3a\x72\x2a\x7c\xcc\x0a\x25\xdf\x45\xc8\xda\xe0\x71\x95" \ "\xa0\xd4\xc5\x5c\x41\x59\x1b\x28\x5e\xcd\x27\x95\x54\x87\x41\x58" \ "\xc1\xc9\x60\x14\xa0\x94\xd3\x71\xe5\x18\xe6\x12\x81\x63\x76\x54" \ "\x99\x05\x24\x94\x19\xbb\x28\xcd\x36\x2e\x72\x9d\x04\xf6\xc1\x1a" \ "\x4f\x66\xa5\xb5\x1a\x4d\x09\xe1\xdc\x66\x3c\xa7\x29\x9b\x2b\xe4" \ "\xf3\x89\x6c\xea\x50\xc7\x30\x19\xff\xb0\x8f\x44\x04\x9b\x7f\x25" \ "\x67\x1e\x09\x1a\x48\xfb\xe2\xd7\xa7\x92\x40\x80\x7f\x85\x6a\x89" \ "\x71\x3a\xb4\x2c\x87\x6b\xc0\x36\xb2\x14\xcc\x9c\x96\xc6\x9a\x19" \ "\xd3\xd2\x50\x1b\x69\xd4\x2a\x36\xf5\x5b\x3d\x7d\x13\x50\xab\x5a" \ "\x13\x5b\x66\xf5\xa7\x5f\x4d\x9c\x4d\xca\x9a\x08\x69\xa4\xb5\x60" \ "\x6c\x7d\xeb\x90\xba\x5a\xd7\x38\x40\xb5\x9b\x02\x0a\x6c\x93\xf8" \ "\xb9\xd7\x49\xe1\xe1\x64\x40\xaa\xd8\x16\x6a\x1a\xd9\x3f\x50\xa2" \ "\x8b\x73\xa8\x41\x22\x1e\x1b\xda\xc8\x2e\xe5\xb3\xb1\xed\xa2\xe7" \ "\x36\x9a\xdb\xd7\x55\x75\xac\xc1\xad\xb0\x62\x3b\x60\xdc\xe4\x6e" \ "\x9f\xb9\x2f\x80\xee\x74\xa7\x68\xdd\xbe\xfc\xb6\xbb\x61\x0a\xef" \ "\x16\xec\x60\xde\xa0\xab\x77\xdb\x08\x8d\x6f\xe1\xea\x7b\xa2\xfc" \ "\xee\xf7\x24\xfe\x1d\x8d\x7b\x0a\x1c\x3f\x1e\x25\x38\x4d\xda\x79" \ "\xc6\x8a\x29\x7c\x55\xf2\xdb\x14\xa9\x2b\x56\xa1\x87\x5b\xfc\xe2" \ "\x18\xcf\xb8\xc6\x37\xce\xf1\x8e\x7b\xfc\xe3\x20\x0f\xb9\xc8\x47" \ "\x4e\x72\xfd\x69\x48\xe2\xdf\x81\x27\x1c\x4b\x7e\x27\x3f\x62\xd0" \ "\x09\xbf\x66\xf9\x14\x5c\xfe\x44\x3e\xca\xdc\x85\x01\x07\xb7\xcd" \ "\x6f\x0e\xeb\x6b\x0b\xbc\xcb\x31\xff\xef\x78\xce\x0f\x6e\x8a\x84" \ "\xf3\xfc\x04\x6a\x10\xf6\x19\xab\x7c\x74\x0f\xb4\x9b\xe8\x5b\xfd" \ "\x70\xd3\x4d\x29\x6f\xa8\x2b\x22\xd7\x23\xf7\xb9\xd5\x0b\x83\x75" \ "\x8b\x6b\x7d\xeb\xda\x29\x75\xb1\x95\x0e\xf6\x49\x74\x7d\xb1\x4f" \ "\x2f\x3b\x9d\x2c\xd9\xcb\xb4\x6f\xb1\x0e\xb7\xaa\x90\x71\x23\x3d" \ "\xbf\xc2\xb0\xbd\x88\xdb\x26\x4f\xc5\x82\xde\x01\x8c\x51\x8e\xef" \ "\x35\xe2\xf5\x05\x81\x6e\x34\x83\x47\x77\x81\x79\xe7\x8f\xd1\xe1" \ "\x53\xf7\x58\x88\x7d\x6e\x64\xc7\x12\xe0\x87\x92\x74\x52\x3c\x3e" \ "\x5f\x91\xdf\xc6\xe4\x3f\xfa\xf5\x06\x6d\xde\x7a\x08\xbc\xfc\xcd" \ "\x86\x6e\x99\x58\x25\x5e\xb0\x14\xbc\xf7\x4e\x1a\xe5\x66\x01\x89" \ "\x5e\x84\xa4\x7f\xe7\xe7\x6d\x91\x79\x40\x3c\xfa\x52\xb1\x9f\x0b" \ "\x93\x5a\xaf\x9d\xdb\x0f\x6f\x7a\xaf\xff\x66\xab\xec\x2c\xc3\xce" \ "\x47\x7b\xf6\x55\xa8\xfa\x85\xf5\xed\xf6\x98\x49\x46\xf9\x54\x21" \ "\x7e\x7c\xd9\xe0\xfb\x32\xf0\x3e\xd5\x1f\x87\x58\xf5\x51\xa6\x27" \ "\xe9\x0f\xb7\xf9\x3f\xd8\xbe\x0c\xa0\xff\x91\x2c\x97\x1c\xfc\xc1" \ "\xf7\x46\xed\x4b\x3f\x75\x1b\x59\xcd\xfb\x0d\x5b\x7b\xfb\x37\xd0" \ "\x7c\xf1\x83\xe0\xfa\x7b\xb1\x3f\xff\xad\x97\x96\x7e\x50\x90\x3f" \ "\x37\xf3\x77\x12\x5e\xa0\x7f\x36\x12\x39\x01\x58\x3a\xc9\x30\x79" \ "\xff\x37\x10\xc8\x07\x6f\x49\x42\x80\x8c\xf5\x4c\x07\x78\x03\xc1" \ "\x02\x7f\xd5\x54\x5c\x13\x38\x73\xbb\xd2\x7f\x33\x90\x26\x10\xc8" \ "\x73\x78\x46\x5a\xf8\x87\x14\xe6\x97\x81\xc1\xf6\x1a\x90\x33\x5a" \ "\x26\xc8\x25\x38\xc2\x5c\xeb\xd7\x05\x25\xb8\x82\x65\x70\x28\x0a" \ "\xb5\x80\x32\x21\x83\xb5\xb0\x1f\xa1\x64\x83\xce\x80\x83\xc4\x20" \ "\x78\x3e\xe0\x3f\x5e\x62\x81\xc8\x82\x44\x8e\x47\x71\x98\x26\x2b" \ "\x01\x72\x37\x3c\x78\x78\xa9\x97\x7b\xf4\xa3\x6c\xdd\x20\x24\xcc" \ "\xd2\x84\xb2\xd0\x80\x46\x63\x7c\x9d\xb1\x73\xb5\x60\x1f\x52\x17" \ "\x10\x57\x82\x85\x83\x66\x85\x24\x78\x77\xa0\x60\x1f\xdf\xf2\x82" \ "\x5b\xc0\x36\xac\x52\x43\x4c\xa7\x09\xf6\x51\x01\xa7\x97\x16\x49" \ "\x03\x7e\x0e\xc4\x81\x61\x93\x15\xf6\x10\x86\xf9\xa2\x85\x2b\x64" \ "\x86\x5f\x56\x04\x14\xc0\x87\x12\x53\x22\x6f\x24\x2a\x15\x90\x29" \ "\x92\xf6\x47\x80\x38\x38\x40\x30\x01\x6a\x78\x32\xb9\xe2\x87\xa8" \ "\xb2\x78\x37\xc0\x70\x70\x70\x76\x14\xd8\x6c\x91\xe0\x56\xaa\xa2" \ "\x74\x52\xe8\x0a\x14\xb5\x0b\xc7\xff\x04\x5f\x85\x76\x29\xa3\xf6" \ "\x81\x23\xc0\x6c\xe3\x80\x06\x91\xa8\x04\x62\x88\x58\xfc\x11\x8b" \ "\xa2\x20\x2e\x8d\x58\x0e\x50\xa2\x8a\xe9\x30\x87\xba\xb8\x6f\xd6" \ "\x82\x87\x28\xf0\x8a\x27\xc4\x28\x30\x06\x8c\x77\xb1\x52\xa1\x35" \ "\x82\xd0\x13\x53\x06\x76\x24\xe3\x46\x4d\xc2\x88\x04\xab\xa2\x13" \ "\xb4\xa8\x09\xd0\xd1\x49\xb9\xd8\x72\x2d\x51\x8d\xb5\xb0\x65\xc9" \ "\x33\x87\x8d\xb1\x26\xca\xe8\x4a\xa6\x97\x15\x5f\x88\x01\x64\xd8" \ "\x09\xbd\xd8\x0b\xee\xc5\x8d\x64\x26\x8d\xc9\xb2\x57\x4b\x65\x33" \ "\x58\xe3\x15\xcd\x01\x8e\x3f\x43\x25\xe9\xf8\x03\x31\x68\x54\x5f" \ "\x55\x01\xd1\xf8\x0f\x54\x32\x8e\x5b\xd0\x8f\x89\xf6\x2a\x0d\x45" \ "\x52\x53\xe2\x63\xee\xa8\x67\x44\x80\x4e\x04\xc9\x5a\x4c\xf2\x5a" \ "\x44\x48\x29\x47\xc1\x00\xf8\xe8\x06\x4d\xb2\x8f\x05\xd0\x90\x86" \ "\x26\x04\x18\xa9\x24\x15\x19\x12\xfe\x36\x44\xd5\x20\x56\xb6\x73" \ "\x24\xb8\x85\x45\x98\x10\x90\x08\x09\x24\xfb\x38\x92\x40\xe3\x92" \ "\xc0\xf4\x23\x9a\x25\x93\x33\x39\x3e\xab\x96\x0f\x38\x09\x34\x1c" \ "\x39\x09\xeb\xf8\x08\x12\xd9\x4b\x3f\x79\x75\x35\xb2\x8f\xd8\x44" \ "\x93\xc2\x90\x20\x11\xd9\x8a\xd1\xff\xa4\x94\x43\x90\x20\x48\x99" \ "\x94\x82\xc2\x32\xa8\x87\x4d\x19\xd9\x06\x1e\x79\x0c\x7d\xe5\x4d" \ "\x4d\x79\x95\x8f\x05\x96\xd8\x44\x65\x81\x25\x0f\x5b\xc9\x24\x45" \ "\xa9\x08\x67\x69\x46\x9a\xb1\x58\x50\x19\x57\xe1\x71\x59\x3d\x79" \ "\x36\x59\xd9\x06\x61\x29\x0f\x73\x79\x36\x84\x48\x1c\x95\xf5\x94" \ "\x9e\xc8\x97\x3c\x39\x5b\x7b\x39\x1b\x7d\x19\x4d\xfd\xb4\x1a\x43" \ "\x59\x4e\x75\xc9\x06\x6b\xe9\x02\x9a\xd5\x5a\x5f\x19\x98\xea\xc2" \ "\x80\xad\xf5\x96\x42\xd0\x98\x08\x28\x99\xc9\xe5\x59\xbb\x91\x98" \ "\xe5\x64\x99\x07\xb2\x1b\x9a\x15\x94\x96\xa2\x82\xc2\xd7\x95\x82" \ "\x79\x8a\xd8\x05\x5a\xc3\x35\x84\xb3\x71\x63\xc3\xb5\x98\xd4\x47" \ "\x98\xac\x59\x99\xa6\x99\x5f\xf9\x80\x99\x4c\xa2\x26\x88\xe9\x99" \ "\x91\xc5\x9b\xb8\x89\x97\xc3\x05\x9a\x20\x19\x5c\x85\x19\x4d\x69" \ "\x39\x09\x06\xc9\x15\x0a\x41\x9a\x95\x82\x26\x79\x99\x0a\x91\x89" \ "\x04\xce\xd9\x28\xb2\xc9\x06\xd1\x89\x0a\x3e\x56\x9d\x8c\x72\x9d" \ "\x49\x51\x60\xb5\xc9\x59\xc4\x19\x9a\x0b\xb6\x92\xa7\x95\x9c\x94" \ "\x60\x9c\xc7\x39\x4c\xe8\x39\x70\xe5\xe9\x9b\x86\xf9\x67\xef\x49" \ "\x99\x9c\x25\x81\xed\x15\x11\xdc\xff\x39\x28\x63\x14\x9c\xf9\xb0" \ "\x9c\x45\x34\x6c\xfc\x99\x9b\xf5\x19\x6e\xd2\x45\x4e\xe5\x64\x80" \ "\xcf\x97\x5d\x8b\xd5\x9e\x40\x39\x9f\x4e\xb3\xa0\xe2\x05\x1c\xea" \ "\x65\x59\x08\xea\x18\xc9\xa9\x9b\xff\xe1\x9d\x8b\x10\xa0\xa8\xa9" \ "\x4c\x1a\xaa\x95\xbc\x75\x11\xfe\xf9\x43\xd3\x89\x9f\x1c\xaa\x99" \ "\xc3\x34\x67\x9b\x81\x9e\xd9\x99\x2e\xe3\x89\x6b\x27\x8a\xa2\xda" \ "\x56\x27\x18\xba\x12\x3a\xd1\xa2\xd0\x52\xa2\xf4\x98\xa0\x9c\x43" \ "\x94\xf8\x25\xa1\xbb\x44\x4b\x1f\xea\x06\x35\xda\x3a\xcd\x58\x4a" \ "\x7a\x32\xa2\xa2\x44\x3f\xa5\xf4\xa2\xff\x78\x9f\x54\x51\xa4\x40" \ "\xfa\xa3\x50\xca\xa4\x5f\xc4\xa0\x80\xa1\x9e\x41\x2a\x45\x3a\x2a" \ "\xa2\x10\x56\x1d\x58\xe4\xa4\x45\xa0\xa4\x4b\x01\x8e\x38\x2a\x48" \ "\x14\xa6\x65\xf9\x67\x44\x62\xfa\x92\xb7\x81\xa5\x40\x90\x9f\xf4" \ "\x61\x2c\xb3\xb1\x66\x72\xda\x2c\x69\x7a\x9a\x7b\x71\xa6\x7d\x02" \ "\xa7\x96\xb7\x1b\x7e\x0a\x04\xe7\xb8\x40\x5d\xda\xa3\x7a\xda\x51" \ "\x3e\x34\xa4\x71\x40\xa6\x4f\x21\x6c\xc6\x38\x57\xad\x22\xa5\x26" \ "\x50\xa8\xdf\xd9\x42\x81\x4a\x0a\x77\x7a\x03\xde\xc9\xa7\xce\xe8" \ "\x2a\x9c\xfa\x62\x1a\x95\x7a\xae\xff\xc2\xa8\x57\x51\x7b\x8f\x3a" \ "\x7a\xb4\x22\xa9\xc1\xd8\x7b\xac\xd3\xa6\x4e\x99\x59\xe4\x71\x8b" \ "\xdb\x45\x2b\x83\xaa\x18\xaf\x28\xab\xf9\x72\xa9\xb1\x90\xa9\x8e" \ "\x78\x1f\x96\x08\x2e\xba\x5a\x0a\xb5\xaa\x18\x94\x08\x3d\xaa\xda" \ "\x0b\xc1\x8a\x3c\xe6\xe4\x22\xa7\xea\x27\xae\x2a\x1d\x19\x2a\x92" \ "\xbc\x3a\x0d\xcf\xba\x1d\x35\x22\xa6\x5d\x86\x8a\xdf\x33\xad\x55" \ "\x50\xad\xbd\xd2\x1f\xc7\x1a\x7f\xdf\x13\xae\x2c\x60\x87\x86\xb8" \ "\x0f\x5e\xe4\x77\xe0\xb5\x8b\x02\x44\xae\xe5\xea\xad\x1f\x71\x5b" \ "\xe6\x33\xac\xa2\x09\x76\x21\x91\xac\x22\xd6\x3d\xf8\xea\x1e\x78" \ "\x13\x7a\x07\x35\x6f\x3d\xa1\xa8\x33\xe5\xae\x17\x03\xaf\xe9\xd9" \ "\x66\xfb\x6a\x2b\x04\x2b\x03\xe6\xca\x2b\xa5\xfa\x41\x0b\x4b\x03" \ "\xc5\xaa\x6e\x57\x41\xa9\xd8\x27\x2f\x02\x3b\x59\x65\x61\xb0\xa6" \ "\x41\x28\xac\xd8\x2a\x6f\x91\xb1\x5a\x41\x29\x50\x08\x9c\x6f\xc1" \ "\xb1\xc9\xd0\x53\x22\x2b\x06\xbb\x06\x43\x11\x9b\x06\x63\xa2\x9a" \ "\xe7\x01\x43\x9f\xea\x16\xf2\x93\xb0\x4a\xf0\xa6\x35\xc4\xad\x25" \ "\x33\x8a\x1b\x06\x9e\x30\xc4\xb3\x4b\x61\x84\xa5\x30\x21\x49\x18" \ "\xad\x55\x24\xb4\x3e\x08\x89\x62\xff\xa4\xb4\x4b\xfb\x00\x40\x88" \ "\x66\x4f\x5b\x1c\x9e\x56\xb3\x53\x1b\x66\x55\xfb\xb2\x37\xb7\xb2" \ "\x09\xe1\xb4\x4f\xcb\xb5\x09\x81\xab\x57\xab\x9d\xd0\xd6\xac\x63" \ "\x5b\x13\xdc\x66\xb6\x67\x6b\x7d\x38\x4b\x6a\x5e\x3b\x81\x28\x5b" \ "\x09\x6f\x3b\x7f\x60\xfb\x15\x9a\xb8\xb6\x02\x75\x70\x6a\x8b\xb7" \ "\x34\x10\xb7\x46\xc6\xb7\x85\x50\xb7\x9d\x51\x48\x80\x7b\x06\x0d" \ "\x5b\xb5\x73\x9b\x7d\x6a\x17\x04\x84\x5b\xb8\x51\xe0\xb7\xfa\xb5" \ "\xb7\x8e\xdb\x77\x90\x6b\xb7\xbf\xca\x22\x89\xeb\x21\x6d\x5b\x27" \ "\x30\xf7\x2b\x84\x26\xaa\x8b\x8b\x9d\xa1\xb8\x70\x86\x27\x88\x28" \ "\x24\xb8\xc3\x87\xae\xb7\xd0\x4e\xbd\x93\xa8\xa1\x8b\x2a\x87\x88" \ "\x88\xf7\xa7\x88\x75\x44\x60\x41\x34\xb1\xaf\x0b\xb2\x45\x74\xb8" \ "\xb9\x7b\x2a\x65\x54\xb9\xbd\xdb\x05\xbd\x84\xbb\xc1\xcb\x23\x14" \ "\x5a\xbc\x02\x34\x5b\xc0\x8b\xbc\x9b\x15\x6a\xc4\xcb\xbc\xae\x01" \ "\x6c\xcf\x0b\xbd\x72\x51\x6f\xd3\x4b\xbd\xf1\xaa\x70\x25\x8b\xbd" \ "\x11\x93\x71\xbc\xcb\xbd\x1d\xca\x71\xdb\x0b\xbe\xce\x15\x72\xd7" \ "\x4b\xbe\x74\xc8\x73\x1f\x8b\xbe\x3d\x38\x81\xe3\xcb\xbe\x7e\xb0" \ "\xb4\xeb\x0b\xbf\x1b\x74\xb6\x95\x58\x47\xbf\x7f\x30\xb9\x0a\x30" \ "\xbf\xf8\xbb\x04\xfa\x1b\x01\xef\xdb\xbf\xcd\xfb\xbf\x89\x78\xbf" \ "\x02\x7c\x56\x04\xec\x74\x8d\x47\xbf\x56\xdb\x74\x86\xd2\xbb\xa3" \ "\x9b\xc0\x0c\xab\x68\x69\x4b\x46\x12\xdc\x73\x0b\xfc\x3d\x5c\x78" \ "\xc1\xdd\x40\xb4\xcc\xb3\x77\x5a\xcb\xc1\xfa\x72\x72\x75\xf4\x47" \ "\x9c\x02\x30\x47\x2b\xc2\x2a\xbc\xc2\x2c\xdc\xc2\x2e\x0c\x6f\x09" \ "\x00\x00\x3b\x00" #define HTS_DATA_BACK_GIF_LEN 4243 #define HTS_DATA_FADE_GIF \ "\x47\x49\x46\x38\x39\x61\x8\x0\x8\x0\xf7\x0\x0\x0\x0\x0\x0\x0\x33\x0\x0\x66\x0\x0\x99\x0\x0\xcc\x0\x0\xff\x0\x33\x0\x0\x33\x33\x0\x33\x66\x0\x33\x99\x0\x33\xcc\x0\x33\xff\x0\x66\x0\x0\x66\x33\x0\x66\x66\x0\x66\x99\x0\x66\xcc\x0\x66\xff\x0\x99\x0\x0\x99\x33\x0\x99\x66\x0\x99\x99\x0\x99\xcc\x0\x99\xff\x0\xcc\x0\x0\xcc\x33\x0\xcc\x66\x0\xcc\x99\x0\xcc\xcc"\ "\x0\xcc\xff\x0\xff\x0\x0\xff\x33\x0\xff\x66\x0\xff\x99\x0\xff\xcc\x0\xff\xff\x33\x0\x0\x33\x0\x33\x33\x0\x66\x33\x0\x99\x33\x0\xcc\x33\x0\xff\x33\x33\x0\x33\x33\x33\x33\x33\x66\x33\x33\x99\x33\x33\xcc\x33\x33\xff\x33\x66\x0\x33\x66\x33\x33\x66\x66\x33\x66\x99\x33\x66\xcc\x33\x66\xff\x33\x99\x0\x33\x99\x33\x33\x99\x66\x33\x99\x99\x33\x99\xcc\x33\x99\xff\x33\xcc\x0\x33\xcc\x33\x33"\ "\xcc\x66\x33\xcc\x99\x33\xcc\xcc\x33\xcc\xff\x33\xff\x0\x33\xff\x33\x33\xff\x66\x33\xff\x99\x33\xff\xcc\x33\xff\xff\x66\x0\x0\x66\x0\x33\x66\x0\x66\x66\x0\x99\x66\x0\xcc\x66\x0\xff\x66\x33\x0\x66\x33\x33\x66\x33\x66\x66\x33\x99\x66\x33\xcc\x66\x33\xff\x66\x66\x0\x66\x66\x33\x66\x66\x66\x66\x66\x99\x66\x66\xcc\x66\x66\xff\x66\x99\x0\x66\x99\x33\x66\x99\x66\x66\x99\x99\x66\x99\xcc\x66\x99"\ "\xff\x66\xcc\x0\x66\xcc\x33\x66\xcc\x66\x66\xcc\x99\x66\xcc\xcc\x66\xcc\xff\x66\xff\x0\x66\xff\x33\x66\xff\x66\x66\xff\x99\x66\xff\xcc\x66\xff\xff\x99\x0\x0\x99\x0\x33\x99\x0\x66\x99\x0\x99\x99\x0\xcc\x99\x0\xff\x99\x33\x0\x99\x33\x33\x99\x33\x66\x99\x33\x99\x99\x33\xcc\x99\x33\xff\x99\x66\x0\x99\x66\x33\x99\x66\x66\x99\x66\x99\x99\x66\xcc\x99\x66\xff\x99\x99\x0\x99\x99\x33\x99\x99\x66"\ "\x99\x99\x99\x99\x99\xcc\x99\x99\xff\x99\xcc\x0\x99\xcc\x33\x99\xcc\x66\x99\xcc\x99\x99\xcc\xcc\x99\xcc\xff\x99\xff\x0\x99\xff\x33\x99\xff\x66\x99\xff\x99\x99\xff\xcc\x99\xff\xff\xcc\x0\x0\xcc\x0\x33\xcc\x0\x66\xcc\x0\x99\xcc\x0\xcc\xcc\x0\xff\xcc\x33\x0\xcc\x33\x33\xcc\x33\x66\xcc\x33\x99\xcc\x33\xcc\xcc\x33\xff\xcc\x66\x0\xcc\x66\x33\xcc\x66\x66\xcc\x66\x99\xcc\x66\xcc\xcc\x66\xff\xcc"\ "\x99\x0\xcc\x99\x33\xcc\x99\x66\xcc\x99\x99\xcc\x99\xcc\xcc\x99\xff\xcc\xcc\x0\xcc\xcc\x33\xcc\xcc\x66\xcc\xcc\x99\xcc\xcc\xcc\xcc\xcc\xff\xcc\xff\x0\xcc\xff\x33\xcc\xff\x66\xcc\xff\x99\xcc\xff\xcc\xcc\xff\xff\xff\x0\x0\xff\x0\x33\xff\x0\x66\xff\x0\x99\xff\x0\xcc\xff\x0\xff\xff\x33\x0\xff\x33\x33\xff\x33\x66\xff\x33\x99\xff\x33\xcc\xff\x33\xff\xff\x66\x0\xff\x66\x33\xff\x66\x66\xff\x66"\ "\x99\xff\x66\xcc\xff\x66\xff\xff\x99\x0\xff\x99\x33\xff\x99\x66\xff\x99\x99\xff\x99\xcc\xff\x99\xff\xff\xcc\x0\xff\xcc\x33\xff\xcc\x66\xff\xcc\x99\xff\xcc\xcc\xff\xcc\xff\xff\xff\x0\xff\xff\x33\xff\xff\x66\xff\xff\x99\xff\xff\xcc\xff\xff\xff\x21\xe\x9\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0"\ "\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x0\x21\xf9\x4\x1\x0\x0\xd8\x0\x2c\x0\x0\x0\x0\x8\x0\x8\x0\x0\x8"\ "\x19\x0\xaf\x61\x13\x48\x10\xdb\xc0\x83\x4\xb\x16\x44\x88\x50\xe1\x41\x86\x9\x21\x1a\x74\x78\x2d\x20\x0\x3b\xff" #define HTS_DATA_FADE_GIF_LEN 828 #endif httrack-3.49.5/src/md5.c0000644000175000017500000002041414336470674011634 00000000000000/* * This code implements the MD5 message-digest algorithm. * The algorithm is due to Ron Rivest. This code was * written by Colin Plumb in 1993, no copyright is claimed. * This code is in the public domain; do with it what you wish. * * Equivalent code is available from RSA Data Security, Inc. * This code has been tested against that, and is equivalent, * except that you don't need to include two pages of legalese * with every copy. * * To compute the message digest of a chunk of bytes, declare an * MD5Context structure, pass it to MD5Init, call MD5Update as * needed on buffers full of bytes, and then call MD5Final, which * will fill a supplied 16-byte array with the digest. */ /* #include "config.h" */ #include /* for memcpy() */ #include "md5.h" static void byteReverse(unsigned char *buf, unsigned longs); /* * Note: this code is harmless on little-endian machines. */ #define byteSwap(a, b) do { \ a ^= b; \ b ^= a; \ a ^= b; \ } while(0) static void byteReverse(unsigned char *buf, unsigned longs) { /*uint32 t; */ do { /* t = (uint32) ((unsigned) buf[3] << 8 | buf[2]) << 16 | ((unsigned) buf[1] << 8 | buf[0]); *(uint32 *) buf = t; */ byteSwap(buf[0], buf[3]); byteSwap(buf[1], buf[2]); buf += 4; } while(--longs); } /* * Start MD5 accumulation. Set bit count to 0 and buffer to mysterious * initialization constants. */ void MD5Init(struct MD5Context *ctx, int brokenEndian) { ctx->buf[0] = 0x67452301; ctx->buf[1] = 0xefcdab89; ctx->buf[2] = 0x98badcfe; ctx->buf[3] = 0x10325476; ctx->bits[0] = 0; ctx->bits[1] = 0; /*#ifdef WORDS_BIGENDIAN */ if (brokenEndian) { ctx->doByteReverse = 0; } else { ctx->doByteReverse = 1; } /*#else ctx->doByteReverse = 0; #endif */ } /* * Update context to reflect the concatenation of another buffer full * of bytes. */ void MD5Update(struct MD5Context *ctx, unsigned char const *buf, unsigned len) { uint32 t; /* Update bitcount */ t = ctx->bits[0]; if ((ctx->bits[0] = t + ((uint32) len << 3)) < t) ctx->bits[1]++; /* Carry from low to high */ ctx->bits[1] += len >> 29; t = (t >> 3) & 0x3f; /* Bytes already in shsInfo->data */ /* Handle any leading odd-sized chunks */ if (t) { unsigned char *p = ctx->in.ui8 + t; t = 64 - t; if (len < t) { memcpy(p, buf, len); return; } memcpy(p, buf, t); if (ctx->doByteReverse) byteReverse(ctx->in.ui8, 16); MD5Transform(ctx->buf, ctx->in.ui32); buf += t; len -= t; } /* Process data in 64-byte chunks */ while(len >= 64) { memcpy(ctx->in.ui8, buf, 64); if (ctx->doByteReverse) byteReverse(ctx->in.ui8, 16); MD5Transform(ctx->buf, ctx->in.ui32); buf += 64; len -= 64; } /* Handle any remaining bytes of data. */ memcpy(ctx->in.ui8, buf, len); } /* * Final wrapup - pad to 64-byte boundary with the bit pattern * 1 0* (64-bit count of bits processed, MSB-first) */ void MD5Final(unsigned char digest[16], struct MD5Context *ctx) { unsigned count; unsigned char *p; /* Compute number of bytes mod 64 */ count = (ctx->bits[0] >> 3) & 0x3F; /* Set the first char of padding to 0x80. This is safe since there is always at least one byte free */ p = ctx->in.ui8 + count; *p++ = 0x80; /* Bytes of padding needed to make 64 bytes */ count = 64 - 1 - count; /* Pad out to 56 mod 64 */ if (count < 8) { /* Two lots of padding: Pad the first block to 64 bytes */ memset(p, 0, count); if (ctx->doByteReverse) byteReverse(ctx->in.ui8, 16); MD5Transform(ctx->buf, ctx->in.ui32); /* Now fill the next block with 56 bytes */ memset(ctx->in.ui8, 0, 56); } else { /* Pad block to 56 bytes */ memset(p, 0, count - 8); } if (ctx->doByteReverse) byteReverse(ctx->in.ui8, 14); /* Append length in bits and transform */ /* Note: see patch for PAM from Tomas Mraz */ ctx->in.ui32[14] = ctx->bits[0]; ctx->in.ui32[15] = ctx->bits[1]; /*((uint32 *) ctx->in)[14] = ctx->bits[0]; ((uint32 *) ctx->in)[15] = ctx->bits[1]; */ MD5Transform(ctx->buf, ctx->in.ui32); if (ctx->doByteReverse) byteReverse((unsigned char *) ctx->buf, 4); memcpy(digest, ctx->buf, 16); memset(ctx, 0, sizeof(*ctx)); /* In case it's sensitive */ } /* The four core functions - F1 is optimized somewhat */ /* #define F1(x, y, z) (x & y | ~x & z) */ #define F1(x, y, z) (z ^ (x & (y ^ z))) #define F2(x, y, z) F1(z, x, y) #define F3(x, y, z) (x ^ y ^ z) #define F4(x, y, z) (y ^ (x | ~z)) /* This is the central step in the MD5 algorithm. */ #define MD5STEP(f, w, x, y, z, data, s) \ ( w += f(x, y, z) + data, w = w<>(32-s), w += x ) /* * The core of the MD5 algorithm, this alters an existing MD5 hash to * reflect the addition of 16 longwords of new data. MD5Update blocks * the data and converts bytes into longwords for this routine. */ void MD5Transform(uint32 buf[4], uint32 const in[16]) { register uint32 a, b, c, d; a = buf[0]; b = buf[1]; c = buf[2]; d = buf[3]; MD5STEP(F1, a, b, c, d, in[0] + 0xd76aa478, 7); MD5STEP(F1, d, a, b, c, in[1] + 0xe8c7b756, 12); MD5STEP(F1, c, d, a, b, in[2] + 0x242070db, 17); MD5STEP(F1, b, c, d, a, in[3] + 0xc1bdceee, 22); MD5STEP(F1, a, b, c, d, in[4] + 0xf57c0faf, 7); MD5STEP(F1, d, a, b, c, in[5] + 0x4787c62a, 12); MD5STEP(F1, c, d, a, b, in[6] + 0xa8304613, 17); MD5STEP(F1, b, c, d, a, in[7] + 0xfd469501, 22); MD5STEP(F1, a, b, c, d, in[8] + 0x698098d8, 7); MD5STEP(F1, d, a, b, c, in[9] + 0x8b44f7af, 12); MD5STEP(F1, c, d, a, b, in[10] + 0xffff5bb1, 17); MD5STEP(F1, b, c, d, a, in[11] + 0x895cd7be, 22); MD5STEP(F1, a, b, c, d, in[12] + 0x6b901122, 7); MD5STEP(F1, d, a, b, c, in[13] + 0xfd987193, 12); MD5STEP(F1, c, d, a, b, in[14] + 0xa679438e, 17); MD5STEP(F1, b, c, d, a, in[15] + 0x49b40821, 22); MD5STEP(F2, a, b, c, d, in[1] + 0xf61e2562, 5); MD5STEP(F2, d, a, b, c, in[6] + 0xc040b340, 9); MD5STEP(F2, c, d, a, b, in[11] + 0x265e5a51, 14); MD5STEP(F2, b, c, d, a, in[0] + 0xe9b6c7aa, 20); MD5STEP(F2, a, b, c, d, in[5] + 0xd62f105d, 5); MD5STEP(F2, d, a, b, c, in[10] + 0x02441453, 9); MD5STEP(F2, c, d, a, b, in[15] + 0xd8a1e681, 14); MD5STEP(F2, b, c, d, a, in[4] + 0xe7d3fbc8, 20); MD5STEP(F2, a, b, c, d, in[9] + 0x21e1cde6, 5); MD5STEP(F2, d, a, b, c, in[14] + 0xc33707d6, 9); MD5STEP(F2, c, d, a, b, in[3] + 0xf4d50d87, 14); MD5STEP(F2, b, c, d, a, in[8] + 0x455a14ed, 20); MD5STEP(F2, a, b, c, d, in[13] + 0xa9e3e905, 5); MD5STEP(F2, d, a, b, c, in[2] + 0xfcefa3f8, 9); MD5STEP(F2, c, d, a, b, in[7] + 0x676f02d9, 14); MD5STEP(F2, b, c, d, a, in[12] + 0x8d2a4c8a, 20); MD5STEP(F3, a, b, c, d, in[5] + 0xfffa3942, 4); MD5STEP(F3, d, a, b, c, in[8] + 0x8771f681, 11); MD5STEP(F3, c, d, a, b, in[11] + 0x6d9d6122, 16); MD5STEP(F3, b, c, d, a, in[14] + 0xfde5380c, 23); MD5STEP(F3, a, b, c, d, in[1] + 0xa4beea44, 4); MD5STEP(F3, d, a, b, c, in[4] + 0x4bdecfa9, 11); MD5STEP(F3, c, d, a, b, in[7] + 0xf6bb4b60, 16); MD5STEP(F3, b, c, d, a, in[10] + 0xbebfbc70, 23); MD5STEP(F3, a, b, c, d, in[13] + 0x289b7ec6, 4); MD5STEP(F3, d, a, b, c, in[0] + 0xeaa127fa, 11); MD5STEP(F3, c, d, a, b, in[3] + 0xd4ef3085, 16); MD5STEP(F3, b, c, d, a, in[6] + 0x04881d05, 23); MD5STEP(F3, a, b, c, d, in[9] + 0xd9d4d039, 4); MD5STEP(F3, d, a, b, c, in[12] + 0xe6db99e5, 11); MD5STEP(F3, c, d, a, b, in[15] + 0x1fa27cf8, 16); MD5STEP(F3, b, c, d, a, in[2] + 0xc4ac5665, 23); MD5STEP(F4, a, b, c, d, in[0] + 0xf4292244, 6); MD5STEP(F4, d, a, b, c, in[7] + 0x432aff97, 10); MD5STEP(F4, c, d, a, b, in[14] + 0xab9423a7, 15); MD5STEP(F4, b, c, d, a, in[5] + 0xfc93a039, 21); MD5STEP(F4, a, b, c, d, in[12] + 0x655b59c3, 6); MD5STEP(F4, d, a, b, c, in[3] + 0x8f0ccc92, 10); MD5STEP(F4, c, d, a, b, in[10] + 0xffeff47d, 15); MD5STEP(F4, b, c, d, a, in[1] + 0x85845dd1, 21); MD5STEP(F4, a, b, c, d, in[8] + 0x6fa87e4f, 6); MD5STEP(F4, d, a, b, c, in[15] + 0xfe2ce6e0, 10); MD5STEP(F4, c, d, a, b, in[6] + 0xa3014314, 15); MD5STEP(F4, b, c, d, a, in[13] + 0x4e0811a1, 21); MD5STEP(F4, a, b, c, d, in[4] + 0xf7537e82, 6); MD5STEP(F4, d, a, b, c, in[11] + 0xbd3af235, 10); MD5STEP(F4, c, d, a, b, in[2] + 0x2ad7d2bb, 15); MD5STEP(F4, b, c, d, a, in[9] + 0xeb86d391, 21); buf[0] += a; buf[1] += b; buf[2] += c; buf[3] += d; } httrack-3.49.5/src/htsencoding.c0000644000175000017500000002225614336470674013462 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Encoding conversion functions */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #include "htscharset.h" #include "htsencoding.h" #include "htssafe.h" /* static int decode_entity(const unsigned int hash, const size_t len); */ #include "htsentities.h" /* hexadecimal conversion */ static int get_hex_value(char c) { if (c >= '0' && c <= '9') return c - '0'; else if (c >= 'a' && c <= 'f') return (c - 'a' + 10); else if (c >= 'A' && c <= 'F') return (c - 'A' + 10); else return -1; } /* Numerical Recipes, see */ #define HASH_PRIME ( 1664525 ) #define HASH_CONST ( 1013904223 ) #define HASH_ADD(HASH, C) do { \ (HASH) *= HASH_PRIME; \ (HASH) += HASH_CONST; \ (HASH) += (C); \ } while(0) int hts_unescapeEntitiesWithCharset(const char *src, char *dest, const size_t max, const char *charset) { size_t i, j, ampStart, ampStartDest; int uc; int hex; unsigned int hash; assertf(max != 0); for(i = 0, j = 0, ampStart = (size_t) -1, ampStartDest = 0, uc = -1, hex = 0, hash = 0 ; src[i] != '\0' ; i++) { /* start of entity */ if (src[i] == '&') { ampStart = i; ampStartDest = j; hash = 0; uc = -1; } /* inside a potential entity */ else if (ampStart != (size_t) -1) { /* &#..; entity */ if (ampStart + 1 == i && src[ampStart + 1] == '#') { uc = 0; hex = 0; } /* &#x..; entity */ else if (ampStart + 2 == i && src[ampStart + 1] == '#' && src[ampStart + 2] == 'x') { hex = 1; } /* end of entity */ else if (src[i] == ';') { size_t len; /* decode entity */ if (uc == -1) { /* &foo; */ uc = decode_entity(hash, /*&src[ampStart + 1],*/ i - ampStart - 1); /* FIXME: TEMPORARY HACK FROM PREVIOUS VERSION TO BE INVESTIGATED */ if (uc == 160) { uc = 32; } } /* end */ ampStart = (size_t) -1; /* success ? */ if (uc > 0) { const size_t maxOut = max - ampStartDest; /* write at position */ if (charset != NULL && hts_isCharsetUTF8(charset)) { len = hts_writeUTF8(uc, &dest[ampStartDest], maxOut); } else { size_t ulen; char buffer[32]; len = 0; if ( ( ulen = hts_writeUTF8(uc, buffer, sizeof(buffer)) ) != 0) { char *s; buffer[ulen] = '\0'; s = hts_convertStringFromUTF8(buffer, strlen(buffer), charset); if (s != NULL) { const size_t sLen = strlen(s); if (sLen < maxOut) { /* Do not copy \0. */ memcpy(&dest[ampStartDest], s, sLen); len = sLen; } free(s); } } } if (len > 0) { /* new dest position */ j = ampStartDest + len; /* do not copy ; */ continue; } } } /* numerical entity */ else if (uc != -1) { /* decimal */ if (!hex) { if (src[i] >= '0' && src[i] <= '9') { const int h = src[i] - '0'; uc *= 10; uc += h; } else { /* abandon */ ampStart = (size_t) -1; } } /* hex */ else { const int h = get_hex_value(src[i]); if (h != -1) { uc *= 16; uc += h; } else { /* abandon */ ampStart = (size_t) -1; } } } /* alphanumerical entity */ else { /* alphanum and not too far ('ϑ' is the longest) */ if (i <= ampStart + 10 && ( (src[i] >= '0' && src[i] <= '9') || (src[i] >= 'A' && src[i] <= 'Z') || (src[i] >= 'a' && src[i] <= 'z') ) ) { /* compute hash */ HASH_ADD(hash, (unsigned char) src[i]); } else { /* abandon */ ampStart = (size_t) -1; } } } /* copy */ if (j + 1 > max) { /* overflow */ return -1; } if (src != dest || i != j) { dest[j] = src[i]; } j++; } dest[j] = '\0'; return 0; } int hts_unescapeEntities(const char *src, char *dest, const size_t max) { return hts_unescapeEntitiesWithCharset(src, dest, max, "UTF-8"); } int hts_unescapeUrlSpecial(const char *src, char *dest, const size_t max, const int flags) { size_t i, j, lastI, lastJ, k, utfBufferJ, utfBufferSize; int seenQuery = 0; char utfBuffer[32]; assertf(src != dest); assertf(max != 0); for(i = 0, j = 0, k = 0, utfBufferJ = 0, utfBufferSize = 0, lastI = (size_t) -1, lastJ = (size_t) -1 ; src[i] != '\0' ; i++) { char c = src[i]; unsigned char cUtf = (unsigned char) c; /* Replacement for ' ' */ if (c == '+' && seenQuery) { c = cUtf = ' '; k = 0; /* cancel any sequence */ } /* Escape sequence start */ else if (c == '%') { /* last known position of % written on destination copy blindly c, we'll rollback later */ lastI = i; lastJ = j; } /* End of sequence seen */ else if (i >= 2 && i == lastI + 2) { const int a1 = get_hex_value(src[lastI + 1]); const int a2 = get_hex_value(src[lastI + 2]); if (a1 != -1 && a2 != -1) { const char ec = a1*16 + a2; /* new character */ cUtf = (unsigned char) ec; /* Shortcut for ASCII (do not unescape non-printable) */ if ( (cUtf < 0x80 && cUtf >= 32) && ( flags & UNESCAPE_URL_NO_ASCII ) == 0 ) { /* Rollback new write position and character */ j = lastJ; c = ec; } } else { k = 0; /* cancel any sequence */ } } /* ASCII (and not in %xx) */ else if (cUtf < 0x80 && i != lastI + 1) { k = 0; /* cancel any sequence */ if (c == '?' && !seenQuery) { seenQuery = 1; } } /* UTF-8 sequence in progress (either a raw or a %xx character) */ if (cUtf >= 0x80) { /* Leading UTF ? */ if (HTS_IS_LEADING_UTF8(cUtf)) { k = 0; /* cancel any sequence */ } /* Copy */ if (k < sizeof(utfBuffer)) { /* First character */ if (k == 0) { /* New destination-centric offset of utf-8 buffer beginning */ if (lastI != (size_t) -1 && i == lastI + 2) { /* just read a %xx */ utfBufferJ = lastJ; /* position of % */ } else { utfBufferJ = j; /* current position otherwise */ } /* Sequence length */ utfBufferSize = hts_getUTF8SequenceLength(cUtf); } /* Copy */ utfBuffer[k++] = cUtf; /* Flush UTF-8 buffer when completed. */ if (k == utfBufferSize) { const size_t nRead = hts_readUTF8(utfBuffer, utfBufferSize, NULL); /* Reset UTF-8 buffer in all cases. */ k = 0; /* Was the character read successfully ? */ if (nRead == utfBufferSize) { /* Rollback write position to sequence start write position */ j = utfBufferJ; /* Copy full character sequence */ memcpy(&dest[j], utfBuffer, utfBufferSize); j += utfBufferSize; /* Skip current character */ continue; } } } } /* Check for overflow */ if (j + 1 > max) { return -1; } /* Copy current */ dest[j++] = c; } dest[j] = '\0'; return 0; } int hts_unescapeUrl(const char *src, char *dest, const size_t max) { return hts_unescapeUrlSpecial(src, dest, max, 0); } httrack-3.49.5/src/punycode.c0000644000175000017500000003325314336470674013002 00000000000000/* punycode.c from RFC 3492 http://www.nicemice.net/idn/ Adam M. Costello http://www.nicemice.net/amc/ This is ANSI C code (C89) implementing Punycode (RFC 3492). */ #include "punycode.h" /******************/ /* Implementation */ #include /*** Bootstring parameters for Punycode ***/ enum { base = 36, tmin = 1, tmax = 26, skew = 38, damp = 700, initial_bias = 72, initial_n = 0x80, delimiter = 0x2D }; /* basic(cp) tests whether cp is a basic code point: */ #define basic(cp) ((punycode_uint)(cp) < 0x80) /* delim(cp) tests whether cp is a delimiter: */ #define delim(cp) ((cp) == delimiter) /* decode_digit(cp) returns the numeric value of a basic code */ /* point (for use in representing integers) in the range 0 to */ /* base-1, or base if cp is does not represent a value. */ static punycode_uint decode_digit(punycode_uint cp) { return cp - 48 < 10 ? cp - 22 : cp - 65 < 26 ? cp - 65 : cp - 97 < 26 ? cp - 97 : base; } /* encode_digit(d,flag) returns the basic code point whose value */ /* (when used for representing integers) is d, which needs to be in */ /* the range 0 to base-1. The lowercase form is used unless flag is */ /* nonzero, in which case the uppercase form is used. The behavior */ /* is undefined if flag is nonzero and digit d has no uppercase form. */ static char encode_digit(punycode_uint d, int flag) { return d + 22 + 75 * (d < 26) - ((flag != 0) << 5); /* 0..25 map to ASCII a..z or A..Z */ /* 26..35 map to ASCII 0..9 */ } /* flagged(bcp) tests whether a basic code point is flagged */ /* (uppercase). The behavior is undefined if bcp is not a */ /* basic code point. */ #define flagged(bcp) ((punycode_uint)(bcp) - 65 < 26) /* encode_basic(bcp,flag) forces a basic code point to lowercase */ /* if flag is zero, uppercase if flag is nonzero, and returns */ /* the resulting code point. The code point is unchanged if it */ /* is caseless. The behavior is undefined if bcp is not a basic */ /* code point. */ static char encode_basic(punycode_uint bcp, int flag) { bcp -= (bcp - 97 < 26) << 5; return bcp + ((!flag && (bcp - 65 < 26)) << 5); } /*** Platform-specific constants ***/ /* maxint is the maximum value of a punycode_uint variable: */ static const punycode_uint maxint = -1; /* Because maxint is unsigned, -1 becomes the maximum value. */ /*** Bias adaptation function ***/ static punycode_uint adapt(punycode_uint delta, punycode_uint numpoints, int firsttime) { punycode_uint k; delta = firsttime ? delta / damp : delta >> 1; /* delta >> 1 is a faster way of doing delta / 2 */ delta += delta / numpoints; for(k = 0; delta > ((base - tmin) * tmax) / 2; k += base) { delta /= base - tmin; } return k + (base - tmin + 1) * delta / (delta + skew); } /*** Main encode function ***/ enum punycode_status punycode_encode(punycode_uint input_length, const punycode_uint input[], const unsigned char case_flags[], punycode_uint * output_length, char output[]) { punycode_uint n, delta, h, b, out, max_out, bias, j, m, q, k, t; /* Initialize the state: */ n = initial_n; delta = out = 0; max_out = *output_length; bias = initial_bias; /* Handle the basic code points: */ for(j = 0; j < input_length; ++j) { if (basic(input[j])) { if (max_out - out < 2) return punycode_big_output; output[out++] = case_flags ? encode_basic(input[j], case_flags[j]) : input[j]; } /* else if (input[j] < n) return punycode_bad_input; */ /* (not needed for Punycode with unsigned code points) */ } h = b = out; /* h is the number of code points that have been handled, b is the */ /* number of basic code points, and out is the number of characters */ /* that have been output. */ if (b > 0) output[out++] = delimiter; /* Main encoding loop: */ while(h < input_length) { /* All non-basic code points < n have been */ /* handled already. Find the next larger one: */ for(m = maxint, j = 0; j < input_length; ++j) { /* if (basic(input[j])) continue; */ /* (not needed for Punycode) */ if (input[j] >= n && input[j] < m) m = input[j]; } /* Increase delta enough to advance the decoder's */ /* state to , but guard against overflow: */ if (m - n > (maxint - delta) / (h + 1)) return punycode_overflow; delta += (m - n) * (h + 1); n = m; for(j = 0; j < input_length; ++j) { /* Punycode does not need to check whether input[j] is basic: */ if (input[j] < n /* || basic(input[j]) */ ) { if (++delta == 0) return punycode_overflow; } if (input[j] == n) { /* Represent delta as a generalized variable-length integer: */ for(q = delta, k = base;; k += base) { if (out >= max_out) return punycode_big_output; t = k <= bias /* + tmin */ ? tmin : /* +tmin not needed */ k >= bias + tmax ? tmax : k - bias; if (q < t) break; output[out++] = encode_digit(t + (q - t) % (base - t), 0); q = (q - t) / (base - t); } output[out++] = encode_digit(q, case_flags && case_flags[j]); bias = adapt(delta, h + 1, h == b); delta = 0; ++h; } } ++delta, ++n; } *output_length = out; return punycode_success; } /*** Main decode function ***/ enum punycode_status punycode_decode(punycode_uint input_length, const char input[], punycode_uint * output_length, punycode_uint output[], unsigned char case_flags[]) { punycode_uint n, out, i, max_out, bias, b, j, in, oldi, w, k, digit, t; /* Initialize the state: */ n = initial_n; out = i = 0; max_out = *output_length; bias = initial_bias; /* Handle the basic code points: Let b be the number of input code */ /* points before the last delimiter, or 0 if there is none, then */ /* copy the first b code points to the output. */ for(b = j = 0; j < input_length; ++j) if (delim(input[j])) b = j; if (b > max_out) return punycode_big_output; for(j = 0; j < b; ++j) { if (case_flags) case_flags[out] = flagged(input[j]); if (!basic(input[j])) return punycode_bad_input; output[out++] = input[j]; } /* Main decoding loop: Start just after the last delimiter if any */ /* basic code points were copied; start at the beginning otherwise. */ for(in = b > 0 ? b + 1 : 0; in < input_length; ++out) { /* in is the index of the next character to be consumed, and */ /* out is the number of code points in the output array. */ /* Decode a generalized variable-length integer into delta, */ /* which gets added to i. The overflow checking is easier */ /* if we increase i as we go, then subtract off its starting */ /* value at the end to obtain delta. */ for(oldi = i, w = 1, k = base;; k += base) { if (in >= input_length) return punycode_bad_input; digit = decode_digit(input[in++]); if (digit >= base) return punycode_bad_input; if (digit > (maxint - i) / w) return punycode_overflow; i += digit * w; t = k <= bias /* + tmin */ ? tmin : /* +tmin not needed */ k >= bias + tmax ? tmax : k - bias; if (digit < t) break; if (w > maxint / (base - t)) return punycode_overflow; w *= (base - t); } bias = adapt(i - oldi, out + 1, oldi == 0); /* i was supposed to wrap around from out+1 to 0, */ /* incrementing n each time, so we'll fix that now: */ if (i / (out + 1) > maxint - n) return punycode_overflow; n += i / (out + 1); i %= (out + 1); /* Insert n at position i of the output: */ /* not needed for Punycode: */ /* if (decode_digit(n) <= base) return punycode_invalid_input; */ if (out >= max_out) return punycode_big_output; if (case_flags) { memmove(case_flags + i + 1, case_flags + i, out - i); /* Case of last character determines uppercase flag: */ case_flags[i] = flagged(input[in - 1]); } memmove(output + i + 1, output + i, (out - i) * sizeof *output); output[i++] = n; } *output_length = out; return punycode_success; } #ifdef PUNYCODE_COSTELLO_RFC3492_INCLUDE_TEST #define PUNYCODE_COSTELLO_RFC3492_INCLUDE_TEST /******************************************************************/ /* Wrapper for testing (would normally go in a separate .c file): */ #include #include #include #include /* For testing, we'll just set some compile-time limits rather than */ /* use malloc(), and set a compile-time option rather than using a */ /* command-line option. */ enum { unicode_max_length = 256, ace_max_length = 256 }; static void usage(char **argv) { fprintf(stderr, "\n" "%s -e reads code points and writes a Punycode string.\n" "%s -d reads a Punycode string and writes code points.\n" "\n" "Input and output are plain text in the native character set.\n" "Code points are in the form u+hex separated by whitespace.\n" "Although the specification allows Punycode strings to contain\n" "any characters from the ASCII repertoire, this test code\n" "supports only the printable characters, and needs the Punycode\n" "string to be followed by a newline.\n" "The case of the u in u+hex is the force-to-uppercase flag.\n", argv[0], argv[0]); exit(EXIT_FAILURE); } static void fail(const char *msg) { fputs(msg, stderr); exit(EXIT_FAILURE); } static const char too_big[] = "input or output is too large, recompile with larger limits\n"; static const char invalid_input[] = "invalid input\n"; static const char overflow[] = "arithmetic overflow\n"; static const char io_error[] = "I/O error\n"; #endif /* The following string is used to convert printable */ /* characters between ASCII and the native charset: */ #ifdef PUNYCODE_COSTELLO_RFC3492_INCLUDE_MAIN static const char print_ascii[] = "\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n" "\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n" " !\"#$%&'()*+,-./" "0123456789:;<=>?" "@ABCDEFGHIJKLMNO" "PQRSTUVWXYZ[\\]^_" "`abcdefghijklmno" "pqrstuvwxyz{|}~\n"; int main(int argc, char **argv) { enum punycode_status status; int r; unsigned int input_length, output_length, j; unsigned char case_flags[unicode_max_length]; if (argc != 2) usage(argv); if (argv[1][0] != '-') usage(argv); if (argv[1][2] != 0) usage(argv); if (argv[1][1] == 'e') { punycode_uint input[unicode_max_length]; unsigned long codept; char output[ace_max_length + 1], uplus[3]; int c; /* Read the input code points: */ input_length = 0; for(;;) { r = scanf("%2s%lx", uplus, &codept); if (ferror(stdin)) fail(io_error); if (r == EOF || r == 0) break; if (r != 2 || uplus[1] != '+' || codept > (punycode_uint) - 1) { fail(invalid_input); } if (input_length == unicode_max_length) fail(too_big); if (uplus[0] == 'u') case_flags[input_length] = 0; else if (uplus[0] == 'U') case_flags[input_length] = 1; else fail(invalid_input); input[input_length++] = codept; } /* Encode: */ output_length = ace_max_length; status = punycode_encode(input_length, input, case_flags, &output_length, output); if (status == punycode_bad_input) fail(invalid_input); if (status == punycode_big_output) fail(too_big); if (status == punycode_overflow) fail(overflow); assert(status == punycode_success); /* Convert to native charset and output: */ for(j = 0; j < output_length; ++j) { c = output[j]; assert(c >= 0 && c <= 127); if (print_ascii[c] == 0) fail(invalid_input); output[j] = print_ascii[c]; } output[j] = 0; r = puts(output); if (r == EOF) fail(io_error); return EXIT_SUCCESS; } if (argv[1][1] == 'd') { char input[ace_max_length + 2], *p, *pp; punycode_uint output[unicode_max_length]; /* Read the Punycode input string and convert to ASCII: */ fgets(input, ace_max_length + 2, stdin); if (ferror(stdin)) fail(io_error); if (feof(stdin)) fail(invalid_input); input_length = strlen(input) - 1; if (input[input_length] != '\n') fail(too_big); input[input_length] = 0; for(p = input; *p != 0; ++p) { pp = strchr(print_ascii, *p); if (pp == 0) fail(invalid_input); *p = pp - print_ascii; } /* Decode: */ output_length = unicode_max_length; status = punycode_decode(input_length, input, &output_length, output, case_flags); if (status == punycode_bad_input) fail(invalid_input); if (status == punycode_big_output) fail(too_big); if (status == punycode_overflow) fail(overflow); assert(status == punycode_success); /* Output the result: */ for(j = 0; j < output_length; ++j) { r = printf("%s+%04lX\n", case_flags[j] ? "U" : "u", (unsigned long) output[j]); if (r < 0) fail(io_error); } return EXIT_SUCCESS; } usage(argv); return EXIT_SUCCESS; /* not reached, but quiets compiler warning */ } #endif httrack-3.49.5/src/htscharset.c0000644000175000017500000010654114336470674013325 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Charset conversion functions */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #include "htscharset.h" #include "htsbase.h" #include "punycode.h" #include "htssafe.h" #ifdef _WIN32 #include typedef unsigned __int32 uint32_t; typedef unsigned __int64 uint64_t; #elif (defined(SOLARIS) || defined(sun) || defined(HAVE_INTTYPES_H) \ || defined(BSD) || defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__FreeBSD_kernel__)) #include #else #include #endif #include int hts_isStringAscii(const char *s, size_t size) { size_t i; for(i = 0; i < size; i++) { const unsigned char c = (const unsigned char) s[i]; if (c >= 0x80) { return 0; } } return 1; } #define IS_ALNUM(C) ( ((C) >= 'A' && (C) <= 'Z') || ((C) >= 'a' && (C) <= 'z') || ((C) >= '0' && (C) <= '9') ) #define CHAR_LOWER(C) ( ((C) >= 'A' && (C) <= 'Z') ? ((C) + 'a' - 'A') : (C) ) static int hts_equalsAlphanum(const char *a, const char *b) { size_t i, j; for(i = 0, j = 0;; i++, j++) { /* Skip non-alnum */ for(; a[i] != '\0' && !IS_ALNUM(a[i]); i++) ; for(; b[j] != '\0' && !IS_ALNUM(b[j]); j++) ; /* Compare */ if (CHAR_LOWER(a[i]) != CHAR_LOWER(b[j])) { break; } /* End of string ? (note: a[i] == b[j]) */ else if (a[i] == '\0') { return 1; } } return 0; } #undef IS_ALNUM #undef CHAR_LOWER /* Copy the memory region [s .. s + size - 1 ] as a \0-terminated string. */ static char *hts_stringMemCopy(const char *s, size_t size) { char *dest = malloc(size + 1); if (dest != NULL) { memcpy(dest, s, size); dest[size] = '\0'; return dest; } return NULL; } #ifdef _WIN32 typedef struct wincodepage_t wincodepage_t; struct wincodepage_t { UINT codepage; const char *name; }; /* See */ static const wincodepage_t codepages[] = { {37, "ibm037"}, {437, "ibm437"}, {500, "ibm500"}, {708, "asmo-708"}, {720, "dos-720"}, {737, "ibm737"}, {775, "ibm775"}, {850, "ibm850"}, {852, "ibm852"}, {855, "ibm855"}, {857, "ibm857"}, {858, "ibm00858"}, {860, "ibm860"}, {861, "ibm861"}, {862, "dos-862"}, {863, "ibm863"}, {864, "ibm864"}, {865, "ibm865"}, {866, "cp866"}, {869, "ibm869"}, {870, "ibm870"}, {874, "windows-874"}, {875, "cp875"}, {932, "shift_jis"}, {936, "gb2312"}, {949, "ks_c_5601-1987"}, {950, "big5"}, {1026, "ibm1026"}, {1047, "ibm01047"}, {1140, "ibm01140"}, {1141, "ibm01141"}, {1142, "ibm01142"}, {1143, "ibm01143"}, {1144, "ibm01144"}, {1145, "ibm01145"}, {1146, "ibm01146"}, {1147, "ibm01147"}, {1148, "ibm01148"}, {1149, "ibm01149"}, {1200, "utf-16"}, {1201, "unicodefffe"}, {1250, "windows-1250"}, {1251, "windows-1251"}, {1252, "windows-1252"}, {1253, "windows-1253"}, {1254, "windows-1254"}, {1255, "windows-1255"}, {1256, "windows-1256"}, {1257, "windows-1257"}, {1258, "windows-1258"}, {1361, "johab"}, {10000, "macintosh"}, {10001, "x-mac-japanese"}, {10002, "x-mac-chinesetrad"}, {10003, "x-mac-korean"}, {10004, "x-mac-arabic"}, {10005, "x-mac-hebrew"}, {10006, "x-mac-greek"}, {10007, "x-mac-cyrillic"}, {10008, "x-mac-chinesesimp"}, {10010, "x-mac-romanian"}, {10017, "x-mac-ukrainian"}, {10021, "x-mac-thai"}, {10029, "x-mac-ce"}, {10079, "x-mac-icelandic"}, {10081, "x-mac-turkish"}, {10082, "x-mac-croatian"}, {12000, "utf-32"}, {12001, "utf-32be"}, {20000, "x-chinese_cns"}, {20001, "x-cp20001"}, {20002, "x_chinese-eten"}, {20003, "x-cp20003"}, {20004, "x-cp20004"}, {20005, "x-cp20005"}, {20105, "x-ia5"}, {20106, "x-ia5-german"}, {20107, "x-ia5-swedish"}, {20108, "x-ia5-norwegian"}, {20127, "us-ascii"}, {20261, "x-cp20261"}, {20269, "x-cp20269"}, {20273, "ibm273"}, {20277, "ibm277"}, {20278, "ibm278"}, {20280, "ibm280"}, {20284, "ibm284"}, {20285, "ibm285"}, {20290, "ibm290"}, {20297, "ibm297"}, {20420, "ibm420"}, {20423, "ibm423"}, {20424, "ibm424"}, {20833, "x-ebcdic-koreanextended"}, {20838, "ibm-thai"}, {20866, "koi8-r"}, {20871, "ibm871"}, {20880, "ibm880"}, {20905, "ibm905"}, {20924, "ibm00924"}, {20932, "euc-jp"}, {20936, "x-cp20936"}, {20949, "x-cp20949"}, {21025, "cp1025"}, {21866, "koi8-u"}, {28591, "iso-8859-1"}, {28592, "iso-8859-2"}, {28593, "iso-8859-3"}, {28594, "iso-8859-4"}, {28595, "iso-8859-5"}, {28596, "iso-8859-6"}, {28597, "iso-8859-7"}, {28598, "iso-8859-8"}, {28599, "iso-8859-9"}, {28603, "iso-8859-13"}, {28605, "iso-8859-15"}, {29001, "x-europa"}, {38598, "iso-8859-8-i"}, {50220, "iso-2022-jp"}, {50221, "csiso2022jp"}, {50222, "iso-2022-jp"}, {50225, "iso-2022-kr"}, {50227, "x-cp50227"}, {50229, "iso-2022-cn"}, {51932, "euc-jp"}, {51936, "euc-cn"}, {51949, "euc-kr"}, {52936, "hz-gb-2312"}, {54936, "gb18030"}, {57002, "x-iscii-de"}, {57003, "x-iscii-be"}, {57004, "x-iscii-ta"}, {57005, "x-iscii-te"}, {57006, "x-iscii-as"}, {57007, "x-iscii-or"}, {57008, "x-iscii-ka"}, {57009, "x-iscii-ma"}, {57010, "x-iscii-gu"}, {57011, "x-iscii-pa"}, {65000, "utf-7"}, {65001, "utf-8"}, {0, NULL} }; /* Get a Windows codepage, by its name. Return 0 upon error. */ UINT hts_getCodepage(const char *name) { int id; for(id = 0; codepages[id].name != NULL; id++) { /* Compare the two strings, lowercase and alphanum only (ISO88591 == iso-8859-1) */ if (hts_equalsAlphanum(name, codepages[id].name)) { return codepages[id].codepage; } } /* Not found */ return 0; } LPWSTR hts_convertStringToUCS2(const char *s, int size, UINT cp, int *pwsize) { /* Size in wide chars of the output */ const int wsize = MultiByteToWideChar(cp, 0, (LPCSTR) s, size, NULL, 0); if (wsize > 0) { LPSTR uoutput = NULL; LPWSTR woutput = malloc((wsize + 1) * sizeof(WCHAR)); if (woutput != NULL && MultiByteToWideChar(cp, 0, (LPCSTR) s, size, woutput, wsize) == wsize) { const int usize = WideCharToMultiByte(CP_UTF8, 0, woutput, wsize, NULL, 0, NULL, FALSE); if (usize > 0) { woutput[wsize] = 0x0; if (pwsize != NULL) *pwsize = wsize; return woutput; } } if (woutput != NULL) free(woutput); } return NULL; } LPWSTR hts_convertUTF8StringToUCS2(const char *s, int size, int *pwsize) { return hts_convertStringToUCS2(s, size, CP_UTF8, pwsize); } char *hts_convertUCS2StringToCP(LPWSTR woutput, int wsize, UINT cp) { const int usize = WideCharToMultiByte(cp, 0, woutput, wsize, NULL, 0, NULL, FALSE); if (usize > 0) { char *const uoutput = malloc((usize + 1) * sizeof(char)); if (uoutput != NULL) { if (WideCharToMultiByte (cp, 0, woutput, wsize, uoutput, usize, NULL, FALSE) == usize) { uoutput[usize] = '\0'; return uoutput; } else { free(uoutput); } } } return NULL; } char *hts_convertUCS2StringToUTF8(LPWSTR woutput, int wsize) { return hts_convertUCS2StringToCP(woutput, wsize, CP_UTF8); } char *hts_convertStringCPToUTF8(const char *s, size_t size, UINT cp) { /* Empty string ? */ if (size == 0) { return hts_stringMemCopy(s, size); } /* Already UTF-8 ? */ if (cp == CP_UTF8 || hts_isStringAscii(s, size)) { return hts_stringMemCopy(s, size); } /* Other (valid) charset */ else if (cp != 0) { /* Size in wide chars of the output */ int wsize; LPWSTR woutput = hts_convertStringToUCS2(s, (int) size, cp, &wsize); if (woutput != NULL) { char *const uoutput = hts_convertUCS2StringToUTF8(woutput, wsize); free(woutput); return uoutput; } } /* Error, charset not found! */ return NULL; } char *hts_convertStringCPFromUTF8(const char *s, size_t size, UINT cp) { /* Empty string ? */ if (size == 0) { return hts_stringMemCopy(s, size); } /* Already UTF-8 ? */ if (cp == CP_UTF8 || hts_isStringAscii(s, size)) { return hts_stringMemCopy(s, size); } /* Other (valid) charset */ else if (cp != 0) { /* Size in wide chars of the output */ int wsize; LPWSTR woutput = hts_convertStringToUCS2(s, (int) size, CP_UTF8, &wsize); if (woutput != NULL) { char *const uoutput = hts_convertUCS2StringToCP(woutput, wsize, cp); free(woutput); return uoutput; } } /* Error, charset not found! */ return NULL; } char *hts_convertStringToUTF8(const char *s, size_t size, const char *charset) { const UINT cp = hts_getCodepage(charset); return hts_convertStringCPToUTF8(s, size, cp); } char *hts_convertStringFromUTF8(const char *s, size_t size, const char *charset) { const UINT cp = hts_getCodepage(charset); return hts_convertStringCPFromUTF8(s, size, cp); } char *hts_convertStringSystemToUTF8(const char *s, size_t size) { return hts_convertStringCPToUTF8(s, size, GetACP()); } #else #include #if ( defined(HTS_USEICONV) && ( HTS_USEICONV == 0 ) ) #define DISABLE_ICONV #endif #ifndef DISABLE_ICONV #include #else #include "htscodepages.h" /* decode from a codepage to UTF-8 */ static char* hts_codepageToUTF8(const char *codepage, const char *s) { /* find the given codepage */ size_t i; for(i = 0 ; table_mappings[i].name != NULL && !hts_equalsAlphanum(table_mappings[i].name, codepage) ; i++) ; /* found ; decode */ if (table_mappings[i].name != NULL) { size_t j, k; char *dest = NULL; size_t capa = 0; #define MAX_UTF 8 for(j = 0, k = 0 ; s[j] != '\0' ; j++) { const unsigned char c = (unsigned char) s[j]; const hts_UCS4 uc = table_mappings[i].table[c]; const size_t max = k + MAX_UTF; if (capa < max) { for(capa = 16 ; capa < max ; capa <<= 1) ; dest = realloc(dest, capa); if (dest == NULL) { return NULL; } } if (dest != NULL) { const size_t len = hts_writeUTF8(uc, &dest[k], MAX_UTF); k += len; assertf(k < capa); } } dest[k] = '\0'; return dest; #undef MAX_UTF } return NULL; } #endif static char *hts_convertStringCharset(const char *s, size_t size, const char *to, const char *from) { /* Empty string ? */ if (size == 0) { return strdup(""); } /* Already on correct charset ? */ if (hts_equalsAlphanum(from, to)) { return hts_stringMemCopy(s, size); } #ifndef DISABLE_ICONV /* Find codepage */ else { const iconv_t cp = iconv_open(to, from); if (cp != (iconv_t) - 1) { char *inbuf = (char*) (uintptr_t) s; /* ugly iconv api, sheesh */ size_t inbytesleft = size; size_t outbufCapa = 0; char *outbuf = NULL; size_t outbytesleft = 0; size_t finalSize; /* Initial size to around the string size */ for(outbufCapa = 16; outbufCapa < size + 1; outbufCapa *= 2) ; outbuf = malloc(outbufCapa); outbytesleft = outbufCapa; /* Convert */ while(outbuf != NULL && inbytesleft != 0) { const size_t offset = outbufCapa - outbytesleft; char *outbufCurrent = outbuf + offset; const size_t ret = iconv(cp, &inbuf, &inbytesleft, &outbufCurrent, &outbytesleft); if (ret == (size_t) - 1) { if (errno == E2BIG) { const size_t used = outbufCapa - outbytesleft; outbufCapa *= 2; outbuf = realloc(outbuf, outbufCapa); if (outbuf == NULL) { break; } outbytesleft = outbufCapa - used; } else { free(outbuf); outbuf = NULL; break; } } } /* Final size ? */ finalSize = outbufCapa - outbytesleft; /* Terminating \0 */ if (outbuf != NULL && finalSize + 1 >= outbufCapa) { outbuf = realloc(outbuf, finalSize + 1); } if (outbuf != NULL) outbuf[finalSize] = '\0'; /* Close codepage */ iconv_close(cp); /* Return result (may be NULL) */ return outbuf; } } #else /* Limited codepage decoding support only. */ if (hts_isCharsetUTF8(to)) { return hts_codepageToUTF8(from, s); } #endif /* Error, charset not found! */ return NULL; } char *hts_convertStringToUTF8(const char *s, size_t size, const char *charset) { /* Empty string ? */ if (size == 0) { return strdup(""); } /* Already UTF-8 ? */ if (hts_isCharsetUTF8(charset) || hts_isStringAscii(s, size)) { return hts_stringMemCopy(s, size); } /* Find codepage */ else { return hts_convertStringCharset(s, size, "utf-8", charset); } } char *hts_convertStringFromUTF8(const char *s, size_t size, const char *charset) { /* Empty string ? */ if (size == 0) { return strdup(""); } /* Already UTF-8 ? */ if (hts_isCharsetUTF8(charset) || hts_isStringAscii(s, size)) { return hts_stringMemCopy(s, size); } /* Find codepage */ else { return hts_convertStringCharset(s, size, charset, "utf-8"); } } #endif HTS_STATIC char *hts_getCharsetFromContentType(const char *mime) { /* text/html; charset=utf-8 */ const char *const charset = "charset"; char *pos = strstr(mime, charset); if (pos != NULL) { /* Skip spaces */ int eq = 0; for(pos += strlen(charset); *pos == ' ' || *pos == '=' || *pos == '"' || *pos == '\''; pos++) { if (*pos == '=') { eq = 1; } } if (eq == 1) { int len; for(len = 0; pos[len] == ' ' || pos[len] == ';' || pos[len] == '"' || *pos == '\''; pos++) ; if (len != 0) { char *const s = malloc(len + 1); int i; for(i = 0; i < len; i++) { s[i] = pos[i]; } s[len] = '\0'; return s; } } } return NULL; } #ifdef _WIN32 #define strcasecmp(a,b) stricmp(a,b) #define strncasecmp(a,b,n) strnicmp(a,b,n) #endif static int is_space(char c) { return c == ' ' || c == '\t' || c == '\r' || c == '\n'; } static int is_space_or_equal(char c) { return is_space(c) || c == '='; } static int is_space_or_equal_or_quote(char c) { return is_space_or_equal(c) || c == '"' || c == '\''; } size_t hts_stringLengthUTF8(const char *s) { const unsigned char *const bytes = (const unsigned char *) s; size_t i, len; for(i = 0, len = 0; bytes[i] != '\0'; i++) { const unsigned char c = bytes[i]; if (HTS_IS_LEADING_UTF8(c)) { /* ASCII or leading byte */ len++; } } return len; } size_t hts_copyStringUTF8(char *dest, const char *src, size_t size) { const unsigned char *const bytes = (const unsigned char *) src; size_t i, mark; for(i = 0, mark = 0; ( i == 0 || bytes[i + 1] != '\0' ) && i <= size; i++) { const unsigned char c = bytes[i]; dest[i] = c; if (HTS_IS_LEADING_UTF8(c)) { mark = i; } } dest[mark] = '\0'; return mark; } size_t hts_appendStringUTF8(char *dest, const char *src, size_t nBytes) { const size_t size = strlen(dest); return hts_copyStringUTF8(dest + size, src, nBytes); } int hts_isCharsetUTF8(const char *charset) { return charset != NULL && ( strcasecmp(charset, "utf-8") == 0 || strcasecmp(charset, "utf8") == 0 ); } char *hts_getCharsetFromMeta(const char *html, size_t size) { int i; /* */ for(i = 0; i < size; i++) { if (html[i] == '<' && strncasecmp(&html[i + 1], "meta", 4) == 0 && is_space(html[i + 5])) { /* Skip spaces */ for(i += 5; is_space(html[i]); i++) ; if (strncasecmp(&html[i], "HTTP-EQUIV", 10) == 0 && is_space_or_equal(html[i + 10])) { for(i += 10; is_space_or_equal_or_quote(html[i]); i++) ; if (strncasecmp(&html[i], "CONTENT-TYPE", 12) == 0) { for(i += 12; is_space_or_equal_or_quote(html[i]); i++) ; if (strncasecmp(&html[i], "CONTENT", 7) == 0 && is_space_or_equal(html[i + 7])) { for(i += 7; is_space_or_equal_or_quote(html[i]); i++) ; /* Skip content-type */ for(; i < size && html[i] != ';' && html[i] != '"' && html[i] != '\''; i++) ; /* Expect charset attribute here */ if (html[i] == ';') { for(i++; is_space(html[i]); i++) ; /* Look for charset */ if (strncasecmp(&html[i], "charset", 7) == 0 && is_space_or_equal(html[i + 7])) { int len; for(i += 7; is_space_or_equal(html[i]) || html[i] == '\''; i++) ; /* Charset */ for(len = 0; i + len < size && html[i + len] != '"' && html[i + len] != '\'' && html[i + len] != ' '; len++) ; /* No error ? */ if (len != 0 && i < size) { char *const s = malloc(len + 1); int j; for(j = 0; j < len; j++) { s[j] = html[i + j]; } s[len] = '\0'; return s; } } } } } } } } return NULL; } /* UTF-8 helpers */ /* Number of leading zeros. Returns a value between 0 and 8. */ static unsigned int nlz8(unsigned char x) { unsigned int b = 0; if (x & 0xf0) { x >>= 4; } else { b += 4; } if (x & 0x0c) { x >>= 2; } else { b += 2; } if (! (x & 0x02) ) { b++; } return b; } /* Emit the Unicode character 'UC' (internal) See 7 U+0000 U+007F 1 0xxxxxxx 11 U+0080 U+07FF 2 110xxxxx 16 U+0800 U+FFFF 3 1110xxxx 21 U+10000 U+1FFFFF 4 11110xxx 26 U+200000 U+3FFFFFF 5 111110xx 31 U+4000000 U+7FFFFFFF 6 1111110x */ #define ADD_FIRST_SEQ(UC, LEN, EMITTER) do { \ /* first octet */ \ const unsigned char lead = \ /* leading bits: LEN "1" bits */ \ ~ ( ( 1 << (unsigned) ( 8 - LEN ) ) - 1 ) \ /* encoded bits */ \ | ( (UC) >> (unsigned) ( ( LEN - 1 ) * 6 ) ); \ EMITTER(lead); \ } while(0) #define ADD_NEXT_SEQ(UC, SHIFT, EMITTER) do { \ /* further bytes are encoding 6 bits */ \ const unsigned char next = \ 0x80 | ( ( (UC) >> SHIFT ) & 0x3f ); \ EMITTER(next); \ } while(0) /* UC is a constant. EMITTER is a macro function taking an unsigned int. */ #define EMIT_UNICODE(UC, EMITTER) do { \ if ((UC) < 0x80) { \ EMITTER(((unsigned char) (UC))); \ } else if ((UC) < 0x0800) { \ ADD_FIRST_SEQ(UC, 2, EMITTER); \ ADD_NEXT_SEQ(UC, 0, EMITTER); \ } else if ((UC) < 0x10000) { \ ADD_FIRST_SEQ(UC, 3, EMITTER); \ ADD_NEXT_SEQ(UC, 6, EMITTER); \ ADD_NEXT_SEQ(UC, 0, EMITTER); \ } else if ((UC) < 0x200000) { \ ADD_FIRST_SEQ(UC, 4, EMITTER); \ ADD_NEXT_SEQ(UC, 12, EMITTER); \ ADD_NEXT_SEQ(UC, 6, EMITTER); \ ADD_NEXT_SEQ(UC, 0, EMITTER); \ } else if ((UC) < 0x4000000) { \ ADD_FIRST_SEQ(UC, 5, EMITTER); \ ADD_NEXT_SEQ(UC, 18, EMITTER); \ ADD_NEXT_SEQ(UC, 12, EMITTER); \ ADD_NEXT_SEQ(UC, 6, EMITTER); \ ADD_NEXT_SEQ(UC, 0, EMITTER); \ } else { \ ADD_FIRST_SEQ(UC, 6, EMITTER); \ ADD_NEXT_SEQ(UC, 24, EMITTER); \ ADD_NEXT_SEQ(UC, 18, EMITTER); \ ADD_NEXT_SEQ(UC, 12, EMITTER); \ ADD_NEXT_SEQ(UC, 6, EMITTER); \ ADD_NEXT_SEQ(UC, 0, EMITTER); \ } \ } while(0) #undef READ_LOOP #define READ_LOOP(C, READER, EMITTER, CLEARED) \ do { \ unsigned int uc_ = \ (C) & ( (1 << (CLEARED - 1)) - 1 ); \ int i_; \ /* loop should be unrolled by compiler */ \ for(i_ = 0 ; i_ < 7 - CLEARED ; i_++) { \ const int c_ = (READER); \ /* continuation byte 10xxxxxx */ \ if (c_ != -1 && ( c_ >> 6 ) == 0x2) { \ uc_ <<= 6; \ uc_ |= (c_ & 0x3f); \ } else { \ uc_ = (unsigned int) -1; \ break; \ } \ } \ EMITTER(((int) uc_)); \ } while(0) /* READER is a macro returning an int (-1 for error). EMITTER is a macro function taking an int (-1 for error). */ #define READ_UNICODE(READER, EMITTER) do { \ const unsigned int f_ = \ (unsigned int) (READER); \ /* 1..8 */ \ const unsigned int c_ = \ nlz8((unsigned char)~f_); \ /* ascii */ \ switch(c_) { \ case 0: \ EMITTER(((int)f_)); \ break; \ /* 110xxxxx 10xxxxxx */ \ case 2: \ READ_LOOP(f_, READER, EMITTER, 6); \ break; \ case 3: \ READ_LOOP(f_, READER, EMITTER, 5); \ break; \ case 4: \ READ_LOOP(f_, READER, EMITTER, 4); \ break; \ case 5: \ READ_LOOP(f_, READER, EMITTER, 3); \ break; \ case 6: \ READ_LOOP(f_, READER, EMITTER, 2); \ break; \ /* unexpected continuation/bogus */ \ default: \ EMITTER(-1); \ break; \ } \ } while(0) /* Sample. */ #if 0 int main(int argc, char **argv) { int i; int hex = 0; #define READ_INT(DEST) \ ( ( !hex && sscanf(argv[i], "%d", &(DEST)) == 1) \ || (hex && sscanf(argv[i], "%x", &(DEST)) == 1 ) ) for(i = 1 ; i < argc ; i++) { unsigned int uc, from, to; if (strcmp(argv[i], "--hex") == 0) { hex = 1; } else if (strcmp(argv[i], "--decimal") == 0) { hex = 0; } else if (strcmp(argv[i], "--decode") == 0) { #define RD fgetc_unlocked(stdin) #define WR(C) do { \ if (C != -1) { \ printf("%04x\n", C); \ } else if (!feof(stdin)) { \ fprintf(stderr, "read error\n"); \ exit(EXIT_FAILURE); \ } \ } while(0) while(!feof(stdin)) { READ_UNICODE(RD, WR); } #undef RD #undef WR } else if (strcmp(argv[i], "-range") == 0 && i + 2 < argc && (++i, 1) && READ_INT(from) && (++i, 1) && READ_INT(to) ) { unsigned int i; for(i = from ; i < to ; i++) { #define EM(C) fputc_unlocked(C, stdout) EMIT_UNICODE(i, EM); #undef EM } } else if (READ_INT(uc)) { #define EM(C) fputc_unlocked(C, stdout) EMIT_UNICODE(uc, EM); #undef EM } else { return EXIT_FAILURE; } } return EXIT_SUCCESS; } #endif /* IDNA helpers. */ #undef ADD_BYTE #undef INCREASE_CAPA #define INCREASE_CAPA() do { \ capa = capa < 16 ? 16 : ( capa << 1 ); \ dest = realloc(dest, capa*sizeof(dest[0])); \ if (dest == NULL) { \ return NULL; \ } \ } while(0) #define ADD_BYTE(C) do { \ if (capa == destSize) { \ INCREASE_CAPA(); \ } \ dest[destSize++] = (C); \ } while(0) #define FREE_BUFFER() do { \ if (dest != NULL) { \ free(dest); \ dest = NULL; \ } \ } while(0) char *hts_convertStringUTF8ToIDNA(const char *s, size_t size) { char *dest = NULL; size_t capa = 0, destSize = 0; size_t i, startSeg; int nonAsciiFound; for(i = startSeg = 0, nonAsciiFound = 0 ; i <= size ; i++) { const unsigned char c = i < size ? (unsigned char) s[i] : 0; /* separator (ending, url segment, scheme, path segment, query string) */ if (c == 0 || c == '.' || c == ':' || c == '/' || c == '?') { /* non-empty segment */ if (startSeg != i) { /* IDNA ? */ if (nonAsciiFound) { const size_t segSize = i - startSeg; const unsigned char *segData = (const unsigned char*) &s[startSeg]; punycode_uint *segInt = NULL; size_t j, utfSeq, segOutputSize; punycode_uint output_length; punycode_status status; /* IDNA prefix */ ADD_BYTE('x'); ADD_BYTE('n'); ADD_BYTE('-'); ADD_BYTE('-'); /* copy utf-8 to integers. note: buffer is sufficient! */ segInt = (punycode_uint*) malloc(segSize*sizeof(punycode_uint)); if (segInt == NULL) { FREE_BUFFER(); return NULL; } for(j = 0, segOutputSize = 0, utfSeq = (size_t) -1 ; j <= segSize ; j++) { const unsigned char c = j < segSize ? segData[j] : 0; /* character start (ascii, or utf-8 leading sequence) */ if (HTS_IS_LEADING_UTF8(c)) { /* commit sequence ? */ if (utfSeq != (size_t) -1) { /* Reader: can read bytes up to j */ #define RD ( utfSeq < j ? segData[utfSeq++] : -1 ) /* Writer: upon error, return FFFD (replacement character) */ #define WR(C) do { \ if ((C) != -1) { \ /* copy character */ \ assertf(segOutputSize < segSize); \ segInt[segOutputSize++] = (C); \ } \ /* In case of error, abort. */ \ else { \ FREE_BUFFER(); \ return NULL; \ } \ } while(0) /* Read/Write Unicode character. */ READ_UNICODE(RD, WR); #undef RD #undef WR /* not anymore in sequence */ utfSeq = (size_t) -1; } /* ascii ? */ if (c < 0x80) { assertf(segOutputSize < segSize); segInt[segOutputSize] = c; if (c != 0) { segOutputSize++; } } /* new UTF8 sequence */ else { utfSeq = j; } } } /* encode */ output_length = (punycode_uint) ( capa - destSize ); while((status = punycode_encode((punycode_uint) segOutputSize, segInt, NULL, &output_length, &dest[destSize])) == punycode_big_output) { INCREASE_CAPA(); output_length = (punycode_uint) ( capa - destSize ); } /* cleanup */ free(segInt); /* success ? */ if (status == punycode_success) { destSize += output_length; } else { FREE_BUFFER(); return NULL; } } /* copy ascii segment otherwise */ else { size_t j; for(j = startSeg ; j < i ; j++) { const char c = s[j]; ADD_BYTE(c); } } } /* next segment start */ startSeg = i + 1; nonAsciiFound = 0; /* add separator (including terminating \0) */ ADD_BYTE(c); } /* found non-ascii */ else if (c >= 0x80) { nonAsciiFound = 1; } } return dest; } int hts_isStringIDNA(const char *s, size_t size) { size_t i, startSeg; for(i = startSeg = 0 ; i <= size ; i++) { const unsigned char c = i < size ? s[i] : 0; if (c == 0 || c == '.' || c == ':' || c == '/' || c == '?') { const size_t segSize = i - startSeg; /* IDNA segment ? */ if (segSize > 4 && strncasecmp(&s[startSeg], "xn--", 4) == 0) { return 1; } /* next segment start */ startSeg = i + 1; } } return 0; } char *hts_convertStringIDNAToUTF8(const char *s, size_t size) { char *dest = NULL; size_t capa = 0, destSize = 0; size_t i, startSeg; for(i = startSeg = 0 ; i <= size ; i++) { const unsigned char c = i < size ? s[i] : 0; if (c == 0 || c == '.' || c == ':' || c == '/' || c == '?') { const size_t segSize = i - startSeg; /* IDNA segment ? */ if (segSize > 4 && strncasecmp(&s[startSeg], "xn--", 4) == 0) { punycode_status status; punycode_uint output_capa; punycode_uint output_length; punycode_uint *output_dest; /* encode. pre-reserve buffer. */ for(output_capa = 16 ; output_capa < segSize ; output_capa <<= 1) ; output_dest = (punycode_uint*) malloc(output_capa*sizeof(punycode_uint)); if (output_dest == NULL) { FREE_BUFFER(); return NULL; } for(output_length = output_capa ; (status = punycode_decode((punycode_uint) segSize - 4, &s[startSeg + 4], &output_length, output_dest, NULL)) == punycode_big_output ; ) { output_capa <<= 1; output_dest = (punycode_uint*) realloc(output_dest, output_capa*sizeof(punycode_uint)); if (output_dest == NULL) { FREE_BUFFER(); return NULL; } output_length = output_capa; } /* success ? */ if (status == punycode_success) { punycode_uint j; for(j = 0 ; j < output_length ; j++) { const punycode_uint uc = output_dest[j]; if (uc < 0x80) { ADD_BYTE((char) uc); } else { /* emiter (byte per byte) */ #define EM(C) do { \ if (C != -1) { \ ADD_BYTE(C); \ } else { \ FREE_BUFFER(); \ return NULL; \ } \ } while(0) /* Emit codepoint */ EMIT_UNICODE(uc, EM); #undef EM } } } /* cleanup */ free(output_dest); /* error ? */ if (status != punycode_success) { FREE_BUFFER(); return NULL; } } else { size_t j; for(j = startSeg ; j < i ; j++) { const char c = s[j]; ADD_BYTE(c); } } /* next segment start */ startSeg = i + 1; /* add separator (including terminating \0) */ ADD_BYTE(c); } } return dest; } hts_UCS4* hts_convertUTF8StringToUCS4(const char *s, size_t size, size_t *nChars) { const unsigned char *const data = (const unsigned char*) s; size_t i; hts_UCS4 *dest = NULL; size_t capa = 0, destSize = 0; if (nChars != NULL) { *nChars = 0; } for(i = 0 ; i < size ; ) { hts_UCS4 uc; /* Reader: can read bytes up to j */ #define RD ( i < size ? data[i++] : -1 ) /* Writer: upon error, return FFFD (replacement character) */ #define WR(C) uc = (C) != -1 ? (hts_UCS4) (C) : (hts_UCS4) 0xfffd /* Read Unicode character. */ READ_UNICODE(RD, WR); #undef RD #undef WR /* Emit char */ ADD_BYTE(uc); if (nChars != NULL) { (*nChars)++; } } ADD_BYTE('\0'); return dest; } int hts_isStringUTF8(const char *s, size_t size) { const unsigned char *const data = (const unsigned char*) s; size_t i; for(i = 0 ; i < size ; ) { /* Reader: can read bytes up to j */ #define RD ( i < size ? data[i++] : -1 ) /* Writer: upon error, return FFFD (replacement character) */ #define WR(C) if ((C) == -1) { return 0; } /* Read Unicode character. */ READ_UNICODE(RD, WR); #undef RD #undef WR } return 1; } char *hts_convertUCS4StringToUTF8(const hts_UCS4 *s, size_t nChars) { size_t i; char *dest = NULL; size_t capa = 0, destSize = 0; for(i = 0 ; i < nChars ; i++) { const hts_UCS4 uc = s[i]; /* emitter (byte per byte) */ #define EM(C) do { \ if (C != -1) { \ ADD_BYTE(C); \ } else { \ FREE_BUFFER(); \ return NULL; \ } \ } while(0) EMIT_UNICODE(uc, EM); #undef EM } ADD_BYTE('\0'); return dest; } size_t hts_writeUTF8(hts_UCS4 uc, char *dest, size_t size) { size_t offs = 0; #define EM(C) do { \ if (offs + 1 < size) { \ dest[offs++] = C; \ } else { \ return 0; \ } \ } while(0) EMIT_UNICODE(uc, EM); #undef EM return offs; } size_t hts_readUTF8(const char *src, size_t size, hts_UCS4 *puc) { const unsigned char *const data = (const unsigned char*) src; size_t i = 0; int uc = -1; /* Reader: can read bytes up to j */ #define RD ( i < size ? data[i++] : -1 ) /* Writer: upon error, return FFFD (replacement character) */ #define WR(C) uc = (C) /* Read Unicode character. */ READ_UNICODE(RD, WR); #undef RD #undef WR /* Return */ if (uc != -1) { if (puc != NULL) { *puc = (hts_UCS4) uc; } return i; } return 0; } size_t hts_getUTF8SequenceLength(const char lead) { const unsigned char f = (unsigned char) lead; const unsigned int c = nlz8(~f); switch(c) { case 0: /* ASCII */ return 1; break; case 2: case 3: case 4: case 5: case 6: /* UTF-8 */ return c; break; default: /* ERROR */ return 0; break; } } size_t hts_stringLengthUCS4(const hts_UCS4 *s) { size_t i; for(i = 0 ; s[i] != 0 ; i++) ; return i; } #undef ADD_BYTE #undef INCREASE_CAPA httrack-3.49.5/src/htsmodules.c0000644000175000017500000001533614336470674013345 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: htsmodules.c subroutines: */ /* external modules (parsers) */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* Internal engine bytecode */ #define HTS_INTERNAL_BYTECODE #include "htsglobal.h" #include "htsmodules.h" #include "htsopt.h" #include "htsbasenet.h" #include "htslib.h" extern int fspc(httrackp * opt, FILE * fp, const char *type); #ifndef _WIN32 #if HTS_DLOPEN #include #endif #endif /* >>> Put all modules definitions here */ #include "htszlib.h" #include "htsbase.h" /* <<< */ /* >>> Put all modules variables here */ #if 0 t_gzopen gzopen = NULL; t_gzread gzread = NULL; t_gzclose gzclose = NULL; #endif int V6_is_available = HTS_INET6; static char WHAT_is_available[64] = ""; /* <<< */ HTSEXT_API const char *hts_get_version_info(httrackp * opt) { size_t size; int i; strcpy(opt->state.HTbuff, WHAT_is_available); size = strlen(opt->state.HTbuff); for(i = 0; i < opt->libHandles.count; i++) { const char *name = opt->libHandles.handles[i].moduleName; if (name != NULL) { size_t nsize = strlen(name) + sizeof("+"); size += nsize; if (size + 1 >= sizeof(opt->state.HTbuff)) break; strcat(opt->state.HTbuff, "+"); strcat(opt->state.HTbuff, name); } } return opt->state.HTbuff; } static void htspe_log(htsmoduleStruct * str, const char *msg); int hts_parse_externals(htsmoduleStruct * str) { str->wrapper_name = "wrapper-lib"; /* External callback */ if (RUN_CALLBACK1(str->opt, detect, str)) { if (str->wrapper_name == NULL) str->wrapper_name = "wrapper-lib"; /* Blacklisted */ if (multipleStringMatch (str->wrapper_name, StringBuff(str->opt->mod_blacklist))) { return -1; } else { htspe_log(str, str->wrapper_name); return RUN_CALLBACK1(str->opt, parse, str); } } /* Not detected */ return -1; } //static void addCallback(htscallbacks* chain, void* moduleHandle, htscallbacksfncptr exitFnc) { // while(chain->next != NULL) { // chain = chain->next; // } // chain->next = calloct(1, sizeof(htscallbacks)); // assertf(chain->next != NULL); // chain = chain->next; // memset(chain, 0, sizeof(*chain)); // chain->exitFnc = exitFnc; // chain->moduleHandle = moduleHandle; //} void clearCallbacks(htscallbacks * chain_); void clearCallbacks(htscallbacks * chain_) { htscallbacks *chain; chain = chain_; while(chain != NULL) { if (chain->exitFnc != NULL) { (void) chain->exitFnc(); /* result ignored */ chain->exitFnc = NULL; } chain = chain->next; } chain = chain_; while(chain != NULL) { if (chain->moduleHandle != NULL) { #ifdef _WIN32 FreeLibrary(chain->moduleHandle); #else dlclose(chain->moduleHandle); #endif } chain = chain->next; } chain = chain_->next; // Don't free the block #0 while(chain != NULL) { htscallbacks *nextchain = chain->next; freet(chain); chain = nextchain; } chain_->next = NULL; // Empty } void *openFunctionLib(const char *file_) { void *handle; char *file = malloct(strlen(file_) + 32); strcpy(file, file_); #ifdef _WIN32 handle = LoadLibraryA(file); if (handle == NULL) { sprintf(file, "%s.dll", file_); handle = LoadLibraryA(file); } #else handle = dlopen(file, RTLD_LAZY); if (handle == NULL) { sprintf(file, "lib%s.so", file_); handle = dlopen(file, RTLD_LAZY); } #endif freet(file); return handle; } void closeFunctionLib(void *handle) { #ifdef _WIN32 FreeLibrary(handle); #else dlclose(handle); #endif } void *getFunctionPtr(void *handle, const char *fncname_) { if (handle) { void *userfunction = NULL; char *fncname = strdupt(fncname_); /* Strip optional comma */ char *comma; if ((comma = strchr(fncname, ',')) != NULL) { /* empty arg */ *comma++ = '\0'; } /* the function itself */ userfunction = (void *) DynamicGet(handle, (char *) fncname); freet(fncname); return userfunction; } return NULL; } void htspe_init(void) { static int initOk = 0; if (!initOk) { initOk = 1; /* See CVE-2010-5252 */ #if (defined(_WIN32) && (!defined(_DEBUG))) { /* See KB 2389418 "If this parameter is an empty string (""), the call removes the current directory from the default DLL search order" */ BOOL (WINAPI*const k32_SetDllDirectoryA)(LPCSTR) = (BOOL (WINAPI *)(LPCSTR)) GetProcAddress(GetModuleHandle("kernel32.dll"), "SetDllDirectoryA"); if (k32_SetDllDirectoryA != NULL && !k32_SetDllDirectoryA("")) { /* Do no choke on NT or 98SE with KernelEx NT API (James Blough) */ const DWORD dwVersion = GetVersion(); const DWORD dwMajorVersion = (DWORD)(LOBYTE(LOWORD(dwVersion))); const DWORD dwMinorVersion = (DWORD)(HIBYTE(LOWORD(dwVersion))); if (dwMajorVersion >= 5) { assertf(!"SetDllDirectory failed"); } } } #endif /* Options availability */ sprintf(WHAT_is_available, "%s%s%s", V6_is_available ? "" : "-noV6", "", #if HTS_USEOPENSSL "" #else "-nossl" #endif ); } } void htspe_uninit(void) { } static void htspe_log(htsmoduleStruct * str, const char *msg) { const char *savename = str->filename; httrackp *opt = (httrackp *) str->opt; hts_log_print(opt, LOG_DEBUG, "(External module): parsing %s using module %s", savename, msg); } HTSEXT_API const char *hts_is_available(void) { return WHAT_is_available; } httrack-3.49.5/src/htsconcat.c0000644000175000017500000000655114336470674013143 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2013 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Subroutines */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #include #include #include #include "httrack.h" #include "httrack-library.h" // concat, concatne deux chaines et renvoi le rsultat // permet d'allger grandement le code #undef concat HTSEXT_API char *concat(char *catbuff, size_t size, const char *a, const char *b) { size_t max = 0; RUNTIME_TIME_CHECK_SIZE(size); catbuff[0] = '\0'; if (a != NULL && a[0] != '\0') { max += strlen(a); if (max + 1 >= size) { return catbuff; } strcat(catbuff, a); } if (b != NULL && b[0] != '\0') { max += strlen(b); if (max + 1 >= size) { return catbuff; } strcat(catbuff, b); } return catbuff; } // conversion fichier / -> antislash static char *__fconv(char *a) { #if HTS_DOSNAME int i; for(i = 0; a[i] != 0; i++) if (a[i] == '/') // Unix-to-DOS style a[i] = '\\'; #endif return a; } #undef fconcat #undef concat HTSEXT_API char *fconcat(char *catbuff, size_t size, const char *a, const char *b) { RUNTIME_TIME_CHECK_SIZE(size); return __fconv(concat(catbuff, size, a, b)); } #undef fconv HTSEXT_API char *fconv(char *catbuff, size_t size, const char *a) { RUNTIME_TIME_CHECK_SIZE(size); return __fconv(concat(catbuff, size, a, "")); } /* / et \\ en / */ static char *__fslash(char *a) { int i; for(i = 0; a[i] != 0; i++) if (a[i] == '\\') // convertir a[i] = '/'; return a; } #undef fslash char *fslash(char *catbuff, size_t size, const char *a) { RUNTIME_TIME_CHECK_SIZE(size); return __fslash(concat(catbuff, size, a, NULL)); } // extension : html,gif.. HTSEXT_API const char *get_ext(char *catbuff, size_t size, const char *fil) { size_t i, last; RUNTIME_TIME_CHECK_SIZE(size); for(i = 0, last = 0 ; fil[i] != '\0' && fil[i] != '?' ; i++) { if (fil[i] == '.') { last = i + 1; } } if (last != 0 && i > last) { const size_t len = i - last; if (len < size) { catbuff[0] = '\0'; strncat(catbuff, &fil[last], size); return catbuff; } } return ""; } httrack-3.49.5/src/htswrap.c0000644000175000017500000000407314336470674012642 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: httrack.c subroutines: */ /* wrapper system (for shell */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* Internal engine bytecode */ #define HTS_INTERNAL_BYTECODE #include "htswrap.h" #include "htshash.h" #include "coucal.h" #include "htslib.h" HTSEXT_API int htswrap_init(void) { // LEGACY return 1; } HTSEXT_API int htswrap_free(void) { // LEGACY return 1; } HTSEXT_API int htswrap_add(httrackp * opt, const char *name, void *fct) { return hts_set_callback((t_hts_htmlcheck_callbacks *) opt->callbacks_fun, name, fct); } HTSEXT_API uintptr_t htswrap_read(httrackp * opt, const char *name) { return (uintptr_t) hts_get_callback((t_hts_htmlcheck_callbacks *) opt-> callbacks_fun, name); } httrack-3.49.5/src/htszlib.c0000644000175000017500000001233314360553245012620 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Unpacking subroutines using Jean-loup Gailly's Zlib */ /* for http compressed data */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* Internal engine bytecode */ #define HTS_INTERNAL_BYTECODE /* specific definitions */ #include "htsbase.h" #include "htscore.h" #include "htszlib.h" #if HTS_USEZLIB /* zlib */ /* #include #include "htszlib.h" */ /* Unpack file into a new file Return value: size of the new file, or -1 if an error occurred */ /* Note: utf-8 */ int hts_zunpack(char *filename, char *newfile) { int ret = -1; if (filename != NULL && newfile != NULL) { if (filename[0] && newfile[0]) { char catbuff[CATBUFF_SIZE]; FILE *const in = FOPEN(fconv(catbuff, sizeof(catbuff), filename), "rb"); const int fd = in != NULL ? fileno(in) : -1; const int dup_fd = fd != -1 ? dup(fd) : -1; // Note: we must dup to be able to flose cleanly. const gzFile gz = dup_fd != -1 ? gzdopen(dup_fd, "rb") : NULL; if (gz) { FILE *const fpout = FOPEN(fconv(catbuff, sizeof(catbuff), newfile), "wb"); int size = 0; if (fpout) { int nr; do { char BIGSTK buff[1024]; nr = gzread(gz, buff, sizeof(buff)); if (nr > 0) { size += nr; if (fwrite(buff, 1, nr, fpout) != nr) nr = size = -1; } } while(nr > 0); fclose(fpout); } else size = -1; gzclose(gz); ret = (int) size; } if (in != NULL) { fclose(in); } } } return ret; } int hts_extract_meta(const char *path) { char catbuff[CATBUFF_SIZE]; unzFile zFile = unzOpen(fconcat(catbuff, sizeof(catbuff), path, "hts-cache/new.zip")); zipFile zFileOut = zipOpen(fconcat(catbuff, sizeof(catbuff), path, "hts-cache/meta.zip"), 0); if (zFile != NULL && zFileOut != NULL) { if (unzGoToFirstFile(zFile) == Z_OK) { zip_fileinfo fi; unz_file_info ufi; char BIGSTK filename[HTS_URLMAXSIZE * 4]; char BIGSTK comment[8192]; memset(comment, 0, sizeof(comment)); // for truncated reads memset(&fi, 0, sizeof(fi)); memset(&ufi, 0, sizeof(ufi)); do { int readSizeHeader; filename[0] = '\0'; comment[0] = '\0'; if (unzOpenCurrentFile(zFile) == Z_OK) { if ((readSizeHeader = unzGetLocalExtrafield(zFile, comment, sizeof(comment) - 2)) > 0 && unzGetCurrentFileInfo(zFile, &ufi, filename, sizeof(filename) - 2, NULL, 0, NULL, 0) == Z_OK) { comment[readSizeHeader] = '\0'; fi.dosDate = ufi.dosDate; fi.internal_fa = ufi.internal_fa; fi.external_fa = ufi.external_fa; if (zipOpenNewFileInZip(zFileOut, filename, &fi, NULL, 0, NULL, 0, NULL, /* comment */ Z_DEFLATED, Z_DEFAULT_COMPRESSION) == Z_OK) { if (zipWriteInFileInZip(zFileOut, comment, (int) strlen(comment)) != Z_OK) { } if (zipCloseFileInZip(zFileOut) != Z_OK) { } } } unzCloseCurrentFile(zFile); } } while(unzGoToNextFile(zFile) == Z_OK); } zipClose(zFileOut, "Meta-data extracted by HTTrack/" HTTRACK_VERSION); unzClose(zFile); return 1; } return 0; } const char *hts_get_zerror(int err) { switch (err) { case UNZ_OK: return "no error"; break; case UNZ_END_OF_LIST_OF_FILE: return "end of list of file"; break; case UNZ_ERRNO: return (const char *) strerror(errno); break; case UNZ_PARAMERROR: return "parameter error"; break; case UNZ_BADZIPFILE: return "bad zip file"; break; case UNZ_INTERNALERROR: return "internal error"; break; case UNZ_CRCERROR: return "crc error"; break; default: return "unknown error"; break; } } #endif httrack-3.49.5/src/htsmd5.c0000644000175000017500000000670714336470674012364 00000000000000 /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: htsmd5.c subroutines: */ /* generate a md5 hash */ /* */ /* Written March 1993 by Branko Lankester */ /* Modified June 1993 by Colin Plumb for altered md5.c. */ /* Modified October 1995 by Erik Troan for RPM */ /* Modified 2000 by Xavier Roche for domd5mem */ /* ------------------------------------------------------------ */ /* Internal engine bytecode */ #define HTS_INTERNAL_BYTECODE #include #include #include #include #include "htsmd5.h" #include "md5.h" #include "htssafe.h" int domd5mem(const char *buf, size_t len, char *digest, int asAscii) { int endian = 1; unsigned char bindigest[16]; struct MD5Context ctx; MD5Init(&ctx, *((char *) &endian)); MD5Update(&ctx, (const unsigned char *) buf, (unsigned int) len); MD5Final(bindigest, &ctx); if (!asAscii) { memcpy(digest, bindigest, 16); } else { sprintf(digest, "%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x" "%02x%02x%02x%02x%02x", bindigest[0], bindigest[1], bindigest[2], bindigest[3], bindigest[4], bindigest[5], bindigest[6], bindigest[7], bindigest[8], bindigest[9], bindigest[10], bindigest[11], bindigest[12], bindigest[13], bindigest[14], bindigest[15]); } return 0; } unsigned long int md5sum32(const char *buff) { union { char md5digest[16]; unsigned long int hash; } u; domd5mem(buff, strlen(buff), u.md5digest, 0); return u.hash; } void md5selftest(void) { static const char str1[] = "The quick brown fox jumps over the lazy dog\n"; static const char str1m[] = "37c4b87edffc5d198ff5a185cee7ee09"; static const char str2[] = "Hello"; static const char str2m[] = "8b1a9953c4611296a827abf8c47804d7"; char digest[64]; #define MDCHECK(VAR, VARMD) do { \ memset(digest, 0xCC, sizeof(digest)); \ domd5mem(VAR, sizeof(VAR) - 1, digest, 1); \ if (strcmp(digest, VARMD) != 0) { \ fprintf(stderr, \ "error: md5 selftest failed: '%s' => '%s' (!= '%s')\n", \ VAR, digest, VARMD); \ assert(! "md5 selftest failed"); \ } \ } while(0) MDCHECK(str1, str1m); MDCHECK(str2, str2m); #undef MDCHECK fprintf(stderr, "md5 selftest succeeded\n"); } httrack-3.49.5/src/htsbauth.c0000644000175000017500000003323614336470674012777 00000000000000/* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: httrack.c subroutines: */ /* basic authentication: password storage */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* Internal engine bytecode */ #define HTS_INTERNAL_BYTECODE #include "htsbauth.h" /* specific definitions */ #include "htsglobal.h" #include "htslib.h" #include "htscore.h" /* END specific definitions */ // gestion des cookie // ajoute, dans l'ordre // !=0 : erreur int cookie_add(t_cookie * cookie, const char *cook_name, const char *cook_value, const char *domain, const char *path) { char buffer[8192]; char *a = cookie->data; char *insert; char cook[16384]; // effacer éventuel cookie en double cookie_del(cookie, cook_name, domain, path); if (strlen(cook_value) > 1024) return -1; // trop long if (strlen(cook_name) > 256) return -1; // trop long if (strlen(domain) > 256) return -1; // trop long if (strlen(path) > 256) return -1; // trop long if (strlen(cookie->data) + strlen(cook_value) + strlen(cook_name) + strlen(domain) + strlen(path) + 256 > cookie->max_len) return -1; // impossible d'ajouter insert = a; // insérer ici while(*a) { if (strlen(cookie_get(buffer, a, 2)) < strlen(path)) // long. path (le + long est prioritaire) a = cookie->data + strlen(cookie->data); // fin else { a = strchr(a, '\n'); // prochain champ if (a == NULL) a = cookie->data + strlen(cookie->data); // fin else a++; while(*a == '\n') a++; insert = a; // insérer ici } } // construction du cookie strcpybuff(cook, domain); strcatbuff(cook, "\t"); strcatbuff(cook, "TRUE"); strcatbuff(cook, "\t"); strcatbuff(cook, path); strcatbuff(cook, "\t"); strcatbuff(cook, "FALSE"); strcatbuff(cook, "\t"); strcatbuff(cook, "1999999999"); strcatbuff(cook, "\t"); strcatbuff(cook, cook_name); strcatbuff(cook, "\t"); strcatbuff(cook, cook_value); strcatbuff(cook, "\n"); if (!((strlen(cookie->data) + strlen(cook)) < cookie->max_len)) return -1; // impossible d'ajouter cookie_insert(insert, cook); #if DEBUG_COOK printf("add_new cookie: name=\"%s\" value=\"%s\" domain=\"%s\" path=\"%s\"\n", cook_name, cook_value, domain, path); //printf(">>>cook: %s<<<\n",cookie->data); #endif return 0; } // effacer cookie si existe int cookie_del(t_cookie * cookie, const char *cook_name, const char *domain, const char *path) { char *a, *b; b = cookie_find(cookie->data, cook_name, domain, path); if (b) { a = cookie_nextfield(b); cookie_delete(b, a - b); #if DEBUG_COOK printf("deleted old cookie: %s %s %s\n", cook_name, domain, path); #endif } return 0; } // Matches wildcard cookie domains that start with a dot // chk_dom: the domain stored in the cookie (potentially wildcard). // domain: query domain static int cookie_cmp_wildcard_domain(const char *chk_dom, const char *domain) { const size_t n = strlen(chk_dom); const size_t m = strlen(domain); const size_t l = n < m ? n : m; size_t i; for (i = l - 1; i >= 0; i--) { if (chk_dom[n - i - 1] != domain[m - i - 1]) { return 1; } } if (m < n && chk_dom[0] == '.') { return 0; } else if (m != n) { return 1; } return 0; } // rechercher cookie à partir de la position s (par exemple s=cookie.data) // renvoie pointeur sur ligne, ou NULL si introuvable // path est aligné à droite et cook_name peut être vide (chercher alors tout cookie) // .doubleclick.net TRUE / FALSE 1999999999 id A char *cookie_find(char *s, const char *cook_name, const char *domain, const char *path) { char buffer[8192]; char *a = s; while(*a) { int t; if (strnotempty(cook_name) == 0) t = 1; // accepter par défaut else t = (strcmp(cookie_get(buffer, a, 5), cook_name) == 0); // tester si même nom if (t) { // même nom ou nom qualconque // const char *chk_dom = cookie_get(buffer, a, 0); // domaine concerné par le cookie if ((strlen(chk_dom) <= strlen(domain) && strcmp(chk_dom, domain + strlen(domain) - strlen(chk_dom)) == 0) || !cookie_cmp_wildcard_domain(chk_dom, domain)) { // même domaine // const char *chk_path = cookie_get(buffer, a, 2); // chemin concerné par le cookie if (strlen(chk_path) <= strlen(path)) { if (strncmp(path, chk_path, strlen(chk_path)) == 0) { // même chemin return a; } } } } a = cookie_nextfield(a); } return NULL; } // renvoie prochain champ char *cookie_nextfield(char *a) { char *b = a; a = strchr(a, '\n'); // prochain champ if (a == NULL) a = b + strlen(b); // fin else a++; while(*a == '\n') a++; return a; } // lire cookies.txt // lire également (Windows seulement) les *@*.txt (cookies IE copiés) // !=0 : erreur int cookie_load(t_cookie * cookie, const char *fpath, const char *name) { char catbuff[CATBUFF_SIZE]; char buffer[8192]; // cookie->data[0]='\0'; // Fusionner d'abord les éventuels cookies IE #ifdef _WIN32 { WIN32_FIND_DATAA find; HANDLE h; char pth[MAX_PATH + 32]; strcpybuff(pth, fpath); strcatbuff(pth, "*@*.txt"); h = FindFirstFileA((char *) pth, &find); if (h != INVALID_HANDLE_VALUE) { do { if (!(find.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)) if (!(find.dwFileAttributes & FILE_ATTRIBUTE_SYSTEM)) { FILE *fp = fopen(fconcat(catbuff, sizeof(catbuff), fpath, find.cFileName), "rb"); if (fp) { char cook_name[256]; char cook_value[1000]; char domainpathpath[512]; char dummy[512]; // lien_adrfil af; // chemin (/) int cookie_merged = 0; // // Read all cookies while(!feof(fp)) { cook_name[0] = cook_value[0] = domainpathpath[0] = dummy[0] = af.adr[0] = af.fil[0] = '\0'; linput(fp, cook_name, 250); if (!feof(fp)) { linput(fp, cook_value, 250); if (!feof(fp)) { int i; linput(fp, domainpathpath, 500); /* Read 6 other useless values */ for(i = 0; !feof(fp) && i < 6; i++) { linput(fp, dummy, 500); } if (strnotempty(cook_name) && strnotempty(cook_value) && strnotempty(domainpathpath)) { if (ident_url_absolute(domainpathpath, &af) >= 0) { cookie_add(cookie, cook_name, cook_value, af.adr, af.fil); cookie_merged = 1; } } } } } fclose(fp); if (cookie_merged) remove(fconcat(catbuff, sizeof(catbuff), fpath, find.cFileName)); } // if fp } } while(FindNextFileA(h, &find)); FindClose(h); } } #endif // Ensuite, cookies.txt { FILE *fp = fopen(fconcat(catbuff, sizeof(catbuff), fpath, name), "rb"); if (fp) { char BIGSTK line[8192]; while((!feof(fp)) && (((int) strlen(cookie->data)) < cookie->max_len)) { rawlinput(fp, line, 8100); if (strnotempty(line)) { if (strlen(line) < 8000) { if (line[0] != '#') { char domain[256]; // domaine cookie (.netscape.com) char path[256]; // chemin (/) char cook_name[1024]; // nom cookie (MYCOOK) char BIGSTK cook_value[8192]; // valeur (ID=toto,S=1234) strcpybuff(domain, cookie_get(buffer, line, 0)); // host strcpybuff(path, cookie_get(buffer, line, 2)); // path strcpybuff(cook_name, cookie_get(buffer, line, 5)); // name strcpybuff(cook_value, cookie_get(buffer, line, 6)); // value #if DEBUG_COOK printf("%s\n", line); #endif cookie_add(cookie, cook_name, cook_value, domain, path); } } } } fclose(fp); return 0; } } return -1; } // écrire cookies.txt // !=0 : erreur int cookie_save(t_cookie * cookie, const char *name) { char catbuff[CATBUFF_SIZE]; if (strnotempty(cookie->data)) { char BIGSTK line[8192]; FILE *fp = fopen(fconv(catbuff, sizeof(catbuff), name), "wb"); if (fp) { char *a = cookie->data; fprintf(fp, "# HTTrack Website Copier Cookie File" LF "# This file format is compatible with Netscape cookies" LF); do { a += binput(a, line, 8000); fprintf(fp, "%s" LF, line); } while(strnotempty(line)); fclose(fp); return 0; } } else return 0; return -1; } // insertion chaine ins avant s void cookie_insert(char *s, const char *ins) { char *buff; if (strnotempty(s) == 0) { // rien à faire, juste concat strcatbuff(s, ins); } else { buff = (char *) malloct(strlen(s) + 1); if (buff) { strcpybuff(buff, s); // copie temporaire strcpybuff(s, ins); // insérer strcatbuff(s, buff); // copier freet(buff); } } } // destruction chaine dans s position pos void cookie_delete(char *s, size_t pos) { char *buff; if (strnotempty(s + pos) == 0) { // rien à faire, effacer s[0] = '\0'; } else { buff = (char *) malloct(strlen(s + pos) + 1); if (buff) { strcpybuff(buff, s + pos); // copie temporaire strcpybuff(s, buff); // copier freet(buff); } } } // renvoie champ param de la chaine cookie_base // ex: cookie_get("ceci estunexemple",1) renvoi "un" const char *cookie_get(char *buffer, const char *cookie_base, int param) { const char *limit; while(*cookie_base == '\n') cookie_base++; limit = strchr(cookie_base, '\n'); if (!limit) limit = cookie_base + strlen(cookie_base); if (limit) { if (param) { int i; for(i = 0; i < param; i++) { if (cookie_base) { cookie_base = strchr(cookie_base, '\t'); // prochain tab if (cookie_base) cookie_base++; } } } if (cookie_base) { if (cookie_base < limit) { const char *a = cookie_base; while((*a) && (*a != '\t') && (*a != '\n')) a++; buffer[0] = '\0'; strncatbuff(buffer, cookie_base, (int) (a - cookie_base)); return buffer; } else return ""; } else return ""; } else return ""; } // fin cookies // -- basic auth -- /* déclarer un répertoire comme possédant une authentification propre */ int bauth_add(t_cookie * cookie, const char *adr, const char *fil, const char *auth) { char buffer[HTS_URLMAXSIZE * 2]; if (cookie) { if (!bauth_check(cookie, adr, fil)) { // n'existe pas déja bauth_chain *chain = &cookie->auth; char *prefix = bauth_prefix(buffer, adr, fil); /* fin de la chaine */ while(chain->next) chain = chain->next; chain->next = (bauth_chain *) calloc(sizeof(bauth_chain), 1); if (chain->next) { chain = chain->next; chain->next = NULL; strcpybuff(chain->auth, auth); strcpybuff(chain->prefix, prefix); return 1; } } } return 0; } /* tester adr et fil, et retourner authentification si nécessaire */ /* sinon, retourne NULL */ char *bauth_check(t_cookie * cookie, const char *adr, const char *fil) { char buffer[HTS_URLMAXSIZE * 2]; if (cookie) { bauth_chain *chain = &cookie->auth; char *prefix = bauth_prefix(buffer, adr, fil); while(chain) { if (strnotempty(chain->prefix)) { if (strncmp(prefix, chain->prefix, strlen(chain->prefix)) == 0) { return chain->auth; } } chain = chain->next; } } return NULL; } char *bauth_prefix(char *prefix, const char *adr, const char *fil) { char *a; strcpybuff(prefix, jump_identification_const(adr)); strcatbuff(prefix, fil); a = strchr(prefix, '?'); if (a) *a = '\0'; if (strchr(prefix, '/')) { a = prefix + strlen(prefix) - 1; while(*a != '/') a--; *(a + 1) = '\0'; } return prefix; } httrack-3.49.5/src/htsindex.c0000644000175000017500000003633614336470674013007 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: htsindex.c */ /* keyword indexing system (search index) */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* Internal engine bytecode */ #define HTS_INTERNAL_BYTECODE #include "htsindex.h" #include "htsglobal.h" #include "htslib.h" #if HTS_MAKE_KEYWORD_INDEX #include "htshash.h" #include "coucal.h" /* Keyword Indexer Parameters */ // Maximum length for a keyword #define KEYW_LEN 50 // Minimum length for a keyword - MUST NOT BE NULL!!! #define KEYW_MIN_LEN 3 // What characters to accept? - MUST NOT BE EMPTY AND MUST NOT CONTAIN THE SPACE (32) CHARACTER!!! #define KEYW_ACCEPT "abcdefghijklmnopqrstuvwxyz0123456789-_." // Convert A to a, and so on.. to avoid case problems in indexing // This can be a generic table, containing characters that are in fact not accepted by KEYW_ACCEPT // MUST HAVE SAME SIZES!! #define KEYW_TRANSCODE_FROM (\ "ABCDEFGHIJKLMNOPQRSTUVWXYZ" \ "àâä" \ "ÀÂÄ" \ "éèêë" \ "ÈÈÊË" \ "ìîï" \ "ÌÎÏ" \ "òôö" \ "ÒÔÖ" \ "ùûü" \ "ÙÛÜ" \ "ÿ" \ ) #define KEYW_TRANSCODE_TO ( \ "abcdefghijklmnopqrstuvwxyz" \ "aaa" \ "aaa" \ "eeee" \ "eeee" \ "iii" \ "iii" \ "ooo" \ "ooo" \ "uuu" \ "uuu" \ "y" \ ) // These (accepted) characters will be ignored at beginning of a keyword #define KEYW_IGNORE_BEG "-_." // These (accepted) characters will be stripped if at the end of a keyword #define KEYW_STRIP_END "-_." // Words beginning with these (accepted) characters will be ignored #define KEYW_NOT_BEG "0123456789" // Treat these characters as space characters - MUST NOT BE EMPTY!!! #define KEYW_SPACE " ',;:!?\"\x0d\x0a\x09\x0b\x0c" // Common words (the,for..) detector // If a word represents more than KEYW_USELESS1K (%1000) of total words, then ignore it // 5 (0.5%) #define KEYW_USELESS1K 5 // If a word is present in more than KEYW_USELESS1KPG (%1000) pages, then ignore it // 800 (80%) #define KEYW_USELESS1KPG 800 // This number will be reduced by index hit for sorting purpose // leave it as it is here if you don't REALLY know what you are doing // Yes, I may be the only person, maybe #define KEYW_SORT_MAXCOUNT 999999999 /* End of Keyword Indexer Parameters */ int strcpos(const char *adr, char c); int mystrcmp(const void *_e1, const void *_e2); // Global variables int hts_index_init = 1; int hts_primindex_size = 0; FILE *fp_tmpproject = NULL; int hts_primindex_words = 0; #endif /* Init index */ void index_init(const char *indexpath) { #if HTS_MAKE_KEYWORD_INDEX /* remove(concat(indexpath,"index.txt")); */ hts_index_init = 1; hts_primindex_size = 0; hts_primindex_words = 0; fp_tmpproject = tmpfile(); #endif } /* Indexing system A little bit dirty, (quick'n dirty, in fact) But should be okay on most cases Tags and javascript handled (ignored) */ /* Note: utf-8 */ int index_keyword(const char *html_data, LLint size, const char *mime, const char *filename, const char *indexpath) { #if HTS_MAKE_KEYWORD_INDEX char catbuff[CATBUFF_SIZE]; int intag = 0, inscript = 0, incomment = 0; char keyword[KEYW_LEN + 32]; int i = 0; // //int WordIndexSize = 1024; coucal WordIndexHash = NULL; FILE *tmpfp = NULL; // // Check parameters if (!html_data) return 0; if (!size) return 0; if (!mime) return 0; if (!filename) return 0; // Init ? if (hts_index_init) { UNLINK(concat(catbuff, sizeof(catbuff), indexpath, "index.txt")); UNLINK(concat(catbuff, sizeof(catbuff), indexpath, "sindex.html")); hts_index_init = 0; } // Check MIME type if (is_html_mime_type(mime)) { inscript = 0; } // FIXME - temporary fix for image/svg+xml (svg) // "IN XML" (html like, in fact :) ) else if ((strfield2(mime, "image/svg+xml")) || (strfield2(mime, "image/svg-xml"))) { inscript = 0; } else if ((strfield2(mime, "application/x-javascript")) || (strfield2(mime, "text/css")) ) { inscript = 1; //} else if (strfield2(mime, "text/vnd.wap.wml")) { // humm won't work in many cases // inscript=0; } else return 0; // Temporary file tmpfp = tmpfile(); if (!tmpfp) return 0; // Create hash structure // Hash tables rulez da world! WordIndexHash = coucal_new(0); if (!WordIndexHash) return 0; // Start indexing this page keyword[0] = '\0'; while(i < size) { if (strfield(html_data + i, "")) { incomment = 0; } else if (html_data[i] == '<') { if (!inscript) intag = 1; } else if (html_data[i] == '>') { intag = 0; } else { // Okay, parse keywords if ((!inscript) && (!incomment) && (!intag)) { char cchar = html_data[i]; int pos; int len = (int) strlen(keyword); // Replace (ignore case, and so on..) if ((pos = strcpos(KEYW_TRANSCODE_FROM, cchar)) >= 0) cchar = KEYW_TRANSCODE_TO[pos]; if (strchr(KEYW_ACCEPT, cchar)) { /* Ignore some characters at beginning */ if ((len > 0) || (!strchr(KEYW_IGNORE_BEG, cchar))) { keyword[len++] = cchar; keyword[len] = '\0'; } } else if ((strchr(KEYW_SPACE, cchar)) || (!cchar)) { /* Avoid these words */ if (len > 0) { if (strchr(KEYW_NOT_BEG, keyword[0])) { keyword[(len = 0)] = '\0'; } } /* Strip ending . and so */ { int ok = 0; while((len = (int) strlen(keyword)) && (!ok)) { if (strchr(KEYW_STRIP_END, keyword[len - 1])) { /* strip it */ keyword[len - 1] = '\0'; } else ok = 1; } } /* Store it ? */ if (len >= KEYW_MIN_LEN) { hts_primindex_words++; if (coucal_inc(WordIndexHash, keyword)) { /* added new */ fprintf(tmpfp, "%s\n", keyword); } } keyword[(len = 0)] = '\0'; } else /* Invalid */ keyword[(len = 0)] = '\0'; if (len > KEYW_LEN) { keyword[(len = 0)] = '\0'; } } } i++; } // Reset temp file fseek(tmpfp, 0, SEEK_SET); // Process indexing for this page { //FILE* fp=NULL; //fp=fopen(concat(indexpath,"index.txt"),"ab"); if (fp_tmpproject) { while(!feof(tmpfp)) { char line[KEYW_LEN + 32]; linput(tmpfp, line, KEYW_LEN + 2); if (strnotempty(line)) { intptr_t e = 0; if (coucal_read(WordIndexHash, line, &e)) { //if (e) { char BIGSTK savelst[HTS_URLMAXSIZE * 2]; e++; /* 0 means "once" */ if (strncmp((const char *) fslash(catbuff, sizeof(catbuff), (const char *) indexpath), filename, strlen(indexpath)) == 0) // couper strcpybuff(savelst, filename + strlen(indexpath)); else strcpybuff(savelst, filename); // Add entry for this file and word fprintf(fp_tmpproject, "%s %d %s\n", line, (int) (KEYW_SORT_MAXCOUNT - e), savelst); hts_primindex_size++; //} } } } //fclose(fp); } } // Delete temp file fclose(tmpfp); tmpfp = NULL; // Clear hash table coucal_delete(&WordIndexHash); #endif return 1; } /* Sort index! */ /* Note: NOT utf-8 */ void index_finish(const char *indexpath, int mode) { #if HTS_MAKE_KEYWORD_INDEX char catbuff[CATBUFF_SIZE]; char **tab; char *blk; off_t size = fpsize(fp_tmpproject); if (size > 0) { //FILE* fp=fopen(concat(indexpath,"index.txt"),"rb"); if (fp_tmpproject) { tab = (char **) malloct(sizeof(char *) * (hts_primindex_size + 2)); if (tab) { blk = malloct(size + 4); if (blk) { fseek(fp_tmpproject, 0, SEEK_SET); if ((INTsys) fread(blk, 1, size, fp_tmpproject) == size) { char *a = blk, *b; int index = 0; int i; FILE *fp; while((b = strchr(a, '\n')) && (index < hts_primindex_size)) { tab[index++] = a; *b = '\0'; a = b + 1; } // Sort it! qsort(tab, index, sizeof(char *), mystrcmp); // Delete fp_tmpproject fclose(fp_tmpproject); fp_tmpproject = NULL; // Write new file if (mode == 1) // TEXT fp = fopen(concat(catbuff, sizeof(catbuff), indexpath, "index.txt"), "wb"); else // HTML fp = fopen(concat(catbuff, sizeof(catbuff), indexpath, "sindex.html"), "wb"); if (fp) { char current_word[KEYW_LEN + 32]; char word[KEYW_LEN + 32]; int hit; int total_hit = 0; int total_line = 0; int last_pos = 0; char word0 = '\0'; current_word[0] = '\0'; if (mode == 2) { // HTML for(i = 0; i < index; i++) { if (word0 != tab[i][0]) { word0 = tab[i][0]; fprintf(fp, " %c\r\n", word0, word0); } } word0 = '\0'; fprintf(fp, "

\r\n"); fprintf(fp, "\r\n\r\n\r\n\r\n"); if (word0 != word[0]) { word0 = word[0]; fprintf(fp, "\r\n", word0); fprintf(fp, "\r\n", word0); } fprintf(fp, "\r\n\r\n\r\n
wordlocation\r\n"); } for(i = 0; i < index; i++) { if (sscanf(tab[i], "%s %d", word, &hit) == 2) { char *a = strchr(tab[i], ' '); if (a) a = strchr(a + 1, ' '); if (a++) { /* Yes, a++, not ++a :) */ hit = KEYW_SORT_MAXCOUNT - hit; if (strcmp(word, current_word)) { /* New word */ if (total_hit) { if (mode == 1) // TEXT fprintf(fp, "\t=%d\r\n", total_hit); //else // HTML // fprintf(fp,"
(%d total hits)\r\n",total_hit); if ((((total_hit * 1000) / hts_primindex_words) >= KEYW_USELESS1K) || (((total_line * 1000) / index) >= KEYW_USELESS1KPG) ) { fseek(fp, last_pos, SEEK_SET); if (mode == 1) // TEXT fprintf(fp, "\tignored (%d)\r\n", ((total_hit * 1000) / hts_primindex_words)); else fprintf(fp, "(ignored) [%d hits]
\r\n", total_hit); } else { if (mode == 1) // TEXT fprintf(fp, "\t(%d)\r\n", ((total_hit * 1000) / hts_primindex_words)); //else // HTML // fprintf(fp,"(%d)\r\n",((total_hit*1000)/hts_primindex_words)); } } if (mode == 1) // TEXT fprintf(fp, "%s\r\n", word); else { // HTML fprintf(fp, "
%c
%s\r\n", word); } fflush(fp); last_pos = ftell(fp); strcpybuff(current_word, word); total_hit = total_line = 0; } total_hit += hit; total_line++; if (mode == 1) // TEXT fprintf(fp, "\t%d %s\r\n", hit, a); else // HTML fprintf(fp, "%s [%d hits]
\r\n", a, a, hit); } } } if (mode == 2) // HTML fprintf(fp, "
\r\n"); fclose(fp); } } freet(blk); } freet(tab); } } //qsort } if (fp_tmpproject) fclose(fp_tmpproject); fp_tmpproject = NULL; #endif } /* Subroutines */ #if HTS_MAKE_KEYWORD_INDEX int strcpos(const char *adr, char c) { const char *apos = strchr(adr, c); if (apos) return (int) (apos - adr); else return -1; } int mystrcmp(const void *_e1, const void *_e2) { const char *const*const e1 = (const char *const*) _e1; const char *const*const e2 = (const char *const*) _e2; return strcmp(*e1, *e2); } #endif httrack-3.49.5/src/htsthread.c0000644000175000017500000001236514336470674013143 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Threads */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* Internal engine bytecode */ #define HTS_INTERNAL_BYTECODE #include "htsglobal.h" #include "htsbase.h" #include "htsthread.h" #include "httrack-library.h" #if USE_BEGINTHREAD #ifdef _WIN32 #include #endif #endif static int process_chain = 0; static htsmutex process_chain_mutex = HTSMUTEX_INIT; HTSEXT_API void htsthread_wait(void) { htsthread_wait_n(0); } HTSEXT_API void htsthread_wait_n(int n_wait) { #if USE_BEGINTHREAD int wait = 0; do { hts_mutexlock(&process_chain_mutex); wait = (process_chain > n_wait); hts_mutexrelease(&process_chain_mutex); if (wait) Sleep(100); } while(wait); #endif } /* ensure initialized */ HTSEXT_API void htsthread_init(void) { #if USE_BEGINTHREAD #if (defined(_DEBUG) || defined(DEBUG)) assertf(process_chain == 0); #endif if (process_chain_mutex == HTSMUTEX_INIT) { hts_mutexinit(&process_chain_mutex); } #endif } HTSEXT_API void htsthread_uninit(void) { htsthread_wait(); #if USE_BEGINTHREAD hts_mutexfree(&process_chain_mutex); #endif } typedef struct hts_thread_s { void *arg; void (*fun) (void *arg); } hts_thread_s; #ifdef _WIN32 static unsigned int __stdcall hts_entry_point(void *tharg) #else static void *hts_entry_point(void *tharg) #endif { hts_thread_s *s_args = (hts_thread_s *) tharg; void *const arg = s_args->arg; void (*fun) (void *arg) = s_args->fun; free(tharg); hts_mutexlock(&process_chain_mutex); process_chain++; assertf(process_chain > 0); hts_mutexrelease(&process_chain_mutex); /* run */ fun(arg); hts_mutexlock(&process_chain_mutex); process_chain--; assertf(process_chain >= 0); hts_mutexrelease(&process_chain_mutex); #ifdef _WIN32 return 0; #else return NULL; #endif } /* create a thread */ HTSEXT_API int hts_newthread(void (*fun) (void *arg), void *arg) { hts_thread_s *s_args = malloc(sizeof(hts_thread_s)); assertf(s_args != NULL); s_args->arg = arg; s_args->fun = fun; #ifdef _WIN32 { unsigned int idt; HANDLE handle = (HANDLE) _beginthreadex(NULL, 0, hts_entry_point, s_args, 0, &idt); if (handle == 0) { free(s_args); return -1; } else { /* detach the thread from the main process so that is can be independent */ CloseHandle(handle); } } #else { const size_t stackSize = 1024 * 1024 * 8; pthread_attr_t attr; pthread_t handle = 0; int retcode; if (pthread_attr_init(&attr) != 0 || pthread_attr_setstacksize(&attr, stackSize) != 0 || (retcode = pthread_create(&handle, &attr, hts_entry_point, s_args)) != 0) { free(s_args); return -1; } else { /* detach the thread from the main process so that is can be independent */ pthread_detach(handle); pthread_attr_destroy(&attr); } } #endif return 0; } #if USE_BEGINTHREAD /* Note: new 3.41 cleaned up functions. */ HTSEXT_API void hts_mutexinit(htsmutex * mutex) { htsmutex_s *smutex = malloct(sizeof(htsmutex_s)); #ifdef _WIN32 smutex->handle = CreateMutex(NULL, FALSE, NULL); #else pthread_mutex_init(&smutex->handle, 0); #endif *mutex = smutex; } HTSEXT_API void hts_mutexfree(htsmutex * mutex) { if (mutex != NULL && *mutex != NULL) { #ifdef _WIN32 CloseHandle((*mutex)->handle); #else pthread_mutex_destroy(&((*mutex)->handle)); #endif freet(*mutex); *mutex = NULL; } } HTSEXT_API void hts_mutexlock(htsmutex * mutex) { assertf(mutex != NULL); if (*mutex == HTSMUTEX_INIT) { /* must be initialized */ hts_mutexinit(mutex); } assertf(*mutex != NULL); #ifdef _WIN32 assertf((*mutex)->handle != NULL); WaitForSingleObject((*mutex)->handle, INFINITE); #else pthread_mutex_lock(&(*mutex)->handle); #endif } HTSEXT_API void hts_mutexrelease(htsmutex * mutex) { assertf(mutex != NULL && *mutex != NULL); #ifdef _WIN32 assertf((*mutex)->handle != NULL); ReleaseMutex((*mutex)->handle); #else pthread_mutex_unlock(&(*mutex)->handle); #endif } #endif httrack-3.49.5/src/htsalias.c0000644000175000017500000004752414336470674012772 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: htsalias.c subroutines: */ /* alias for command-line options and config files */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* Internal engine bytecode */ #define HTS_INTERNAL_BYTECODE #include "htsbase.h" #include "htsalias.h" #include "htsglobal.h" #include "htslib.h" #define _NOT_NULL(a) ( (a!=NULL) ? (a) : "" ) // COPY OF cmdl_ins in htsmain.c // Insert a command in the argc/argv #define cmdl_ins(token,argc,argv,buff,ptr) \ { \ int i; \ for(i=argc;i>0;i--)\ argv[i]=argv[i-1];\ } \ argv[0]=(buff+ptr); \ strcpybuff(argv[0],token); \ ptr += (int) (strlen(argv[0])+1); \ argc++ // END OF COPY OF cmdl_ins in htsmain.c /* Aliases for command-line and config file definitions These definitions can be used: in command line: --sockets=8 --cache=0 --sockets 8 --cache off --nocache -c8 -C0 in config file: sockets=8 cache=0 set sockets 8 cache off */ /* single : no options param : this option allows a number parameter (1, for example) and can be mixed with other options (R1C1c8) param1 : this option must be alone, and needs one distinct parameter (-P ) param0 : this option must be alone, but the parameter should be put together (+*.gif) */ const char *hts_optalias[][4] = { /* {"","","",""}, */ {"path", "-O", "param1", "output path"}, {"mirror", "-w", "single", ""}, {"mirror-wizard", "-W", "single", ""}, {"get-files", "-g", "single", ""}, {"quiet", "-q", "single", ""}, {"mirrorlinks", "-Y", "single", ""}, {"proxy", "-P", "param1", "proxy name:port"}, {"bind", "-%b", "param1", "hostname to bind"}, {"httpproxy-ftp", "-%f", "param", ""}, {"depth", "-r", "param", ""}, {"recurse-levels", "-r", "param", ""}, {"ext-depth", "-%e", "param", ""}, {"max-files", "-m", "param", ""}, {"max-size", "-M", "param", ""}, {"max-time", "-E", "param", ""}, {"max-rate", "-A", "param", ""}, {"max-pause", "-G", "param", ""}, {"sockets", "-c", "param", "number of simultaneous connections allowed"}, {"socket", "-c", "param", "number of simultaneous connections allowed"}, {"connection", "-c", "param", "number of simultaneous connections allowed"}, {"connection-per-second", "-%c", "param", "number of connection per second allowed"}, {"timeout", "-T", "param", ""}, {"retries", "-R", "param", "number of retries for non-fatal errors"}, {"min-rate", "-J", "param", ""}, {"host-control", "-H", "param", ""}, {"extended-parsing", "-%P", "param", ""}, {"near", "-n", "single", ""}, {"delayed-type-check", "-%N", "single", ""}, {"cached-delayed-type-check", "-%D", "single", ""}, {"delayed-type-check-always", "-%N2", "single", ""}, {"disable-security-limits", "-%!", "single", ""}, {"test", "-t", "single", ""}, {"list", "-%L", "param1", ""}, {"urllist", "-%S", "param1", ""}, {"language", "-%l", "param1", ""}, {"lang", "-%l", "param1", ""}, {"accept", "-%a", "param1", ""}, {"headers", "-%X", "param1", ""}, {"structure", "-N", "param", ""}, {"user-structure", "-N", "param1", ""}, {"long-names", "-L", "param", ""}, {"keep-links", "-K", "param", ""}, {"mime-html", "-%M", "single", ""}, {"mht", "-%M", "single", ""}, {"replace-external", "-x", "single", ""}, {"disable-passwords", "-%x", "single", ""}, {"disable-password", "-%x", "single", ""}, {"include-query-string", "-%q", "single", ""}, {"generate-errors", "-o", "single", ""}, {"do-not-generate-errors", "-o0", "single", ""}, {"purge-old", "-X", "param", ""}, {"cookies", "-b", "param", ""}, {"check-type", "-u", "param", ""}, {"assume", "-%A", "param1", ""}, {"mimetype", "-%A", "param1", ""}, {"parse-java", "-j", "param", ""}, {"protocol", "-@i", "param", ""}, {"robots", "-s", "param", ""}, {"http-10", "-%h", "single", ""}, {"http-1.0", "-%h", "single", ""}, {"keep-alive", "-%k", "single", ""}, {"build-top-index", "-%i", "single", ""}, {"disable-compression", "-%z", "single", ""}, {"tolerant", "-%B", "single", ""}, {"updatehack", "-%s", "single", ""}, {"sizehack", "-%s", "single", ""}, {"urlhack", "-%u", "single", ""}, {"user-agent", "-F", "param1", "user-agent identity"}, {"referer", "-%R", "param1", "default referer URL"}, {"from", "-%E", "param1", "from email address"}, {"footer", "-%F", "param1", ""}, {"cache", "-C", "param", "number of retries for non-fatal errors"}, {"store-all-in-cache", "-k", "single", ""}, {"do-not-recatch", "-%n", "single", ""}, {"do-not-log", "-Q", "single", ""}, {"extra-log", "-z", "single", ""}, {"debug-log", "-Z", "single", ""}, {"verbose", "-v", "single", ""}, {"file-log", "-f", "single", ""}, {"single-log", "-f2", "single", ""}, {"index", "-I", "single", ""}, {"search-index", "-%I", "single", ""}, {"priority", "-p", "param", ""}, {"debug-headers", "-%H", "single", ""}, {"userdef-cmd", "-V", "param1", ""}, {"callback", "-%W", "param1", "plug an external callback"}, {"wrapper", "-%W", "param1", "plug an external callback"}, {"structure", "-N", "param1", "user-defined structure"}, {"usercommand", "-V", "param1", "user-defined command"}, {"display", "-%v", "single", "show files transferred and other funny realtime information"}, {"dos83", "-L0", "single", ""}, {"iso9660", "-L2", "single", ""}, {"disable-module", "-%w", "param1", ""}, {"no-background-on-suspend", "-y0", "single", ""}, {"background-on-suspend", "-y", "single", ""}, {"utf8-conversion", "-%T", "single", ""}, {"no-utf8-conversion", "-%T0", "single", ""}, /* */ /* DEPRECATED */ {"stay-on-same-dir", "-S", "single", "stay on the same directory - DEPRECATED"}, {"can-go-down", "-D", "single", "can only go down into subdirs - DEPRECATED"}, {"can-go-up", "-U", "single", "can only go to upper directories- DEPRECATED"}, {"can-go-up-and-down", "-B", "single", "can both go up&down into the directory structure - DEPRECATED"}, {"stay-on-same-address", "-a", "single", "stay on the same address - DEPRECATED"}, {"stay-on-same-domain", "-d", "single", "stay on the same principal domain - DEPRECATED"}, {"stay-on-same-tld", "-l", "single", "stay on the same TLD (eg: .com) - DEPRECATED"}, {"go-everywhere", "-e", "single", "go everywhere on the web - DEPRECATED"}, /* Badly documented */ {"debug-testfilters", "-#0", "param1", "debug: test filters"}, {"advanced-flushlogs", "-#f", "single", ""}, {"advanced-maxfilters", "-#F", "param", "maximum number of scan rules"}, {"version", "-#h", "single", ""}, {"debug-scanstdin", "-#K", "single", ""}, {"advanced-maxlinks", "-#L", "param", "maximum number of links (0 to disable limit)"}, {"advanced-progressinfo", "-#p", "single", "deprecated"}, {"catch-url", "-#P", "single", "catch complex URL through proxy"}, /*{"debug-oldftp","-#R","single",""}, */ {"debug-xfrstats", "-#T", "single", ""}, {"advanced-wait", "-#u", "single", ""}, {"debug-ratestats", "-#Z", "single", ""}, {"fast-engine", "-#X", "single", "Enable fast routines"}, {"debug-overflows", "-#X0", "single", "Attempt to detect buffer overflows"}, {"debug-cache", "-#C", "param1", "List files in the cache"}, {"extract-cache", "-#C", "single", "Extract meta-data"}, {"debug-parsing", "-#d", "single", "debug: test parser"}, {"repair-cache", "-#R", "single", "repair the damaged cache ZIP file"}, {"repair", "-#R", "single", ""}, /* STANDARD ALIASES */ {"spider", "-p0C0I0t", "single", ""}, {"testsite", "-p0C0I0t", "single", ""}, {"testlinks", "-r1p0C0I0t", "single", ""}, {"test", "-r1p0C0I0t", "single", ""}, {"bookmark", "-r1p0C0I0t", "single", ""}, {"mirror", "-w", "single", ""}, {"testscan", "-p0C0I0Q", "single", ""}, {"scan", "-p0C0I0Q", "single", ""}, {"check", "-p0C0I0Q", "single", ""}, {"skeleton", "-p1", "single", ""}, {"preserve", "-%p", "single", ""}, {"get", "-qg", "single", ""}, {"update", "-iC2", "single", ""}, {"continue", "-iC1", "single", ""}, {"restart", "-iC1", "single", ""}, {"continue", "-i", "single", ""}, /* for help alias */ {"sucker", "-r999", "single", ""}, {"help", "-h", "single", ""}, {"documentation", "-h", "single", ""}, {"doc", "-h", "single", ""}, {"wide", "-c32", "single", ""}, {"tiny", "-c1", "single", ""}, {"ultrawide", "-c48", "single", ""}, {"http10", "-%h", "single", ""}, {"filelist", "-%L", "single", ""}, {"list", "-%L", "single", ""}, {"filterlist", "-%S", "single", ""}, /* END OF ALIASES */ /* Filters */ {"allow", "+", "param0", "allow filter"}, {"deny", "-", "param0", "deny filter"}, /* */ /* URLs */ {"add", "", "param0", "add URLs"}, /* */ /* Internal */ {"catchurl", "--catchurl", "single", "catch complex URL through proxy"}, {"updatehttrack", "--updatehttrack", "single", "update HTTrack Website Copier"}, {"clean", "--clean", "single", "clean up log files and cache"}, {"tide", "--clean", "single", "clean up log files and cache"}, {"autotest", "-#T", "single", ""}, /* */ {"", "", "", ""} }; /* Check for alias in command-line argc,argv as in main() n_arg argument position return_argv a char[2][] where to put result return_error buffer in case of syntax error return value: number of arguments treated (0 if error) */ int optalias_check(int argc, const char *const *argv, int n_arg, int *return_argc, char **return_argv, char *return_error) { return_error[0] = '\0'; *return_argc = 1; if (argv[n_arg][0] == '-') if (argv[n_arg][1] == '-') { char command[1000]; char param[1000]; char addcommand[256]; /* */ char *position; int need_param = 1; //int return_param=0; int pos; command[0] = param[0] = addcommand[0] = '\0'; /* --sockets=8 */ if ((position = strchr(argv[n_arg], '='))) { /* Copy command */ strncatbuff(command, argv[n_arg] + 2, (int) (position - (argv[n_arg] + 2))); /* Copy parameter */ strcpybuff(param, position + 1); } /* --nocache */ else if (strncmp(argv[n_arg] + 2, "no", 2) == 0) { strcpybuff(command, argv[n_arg] + 4); strcpybuff(param, "0"); } /* --sockets 8 */ else { if (strncmp(argv[n_arg] + 2, "wide-", 5) == 0) { strcpybuff(addcommand, "c32"); strcpybuff(command, strchr(argv[n_arg] + 2, '-') + 1); } else if (strncmp(argv[n_arg] + 2, "tiny-", 5) == 0) { strcpybuff(addcommand, "c1"); strcpybuff(command, strchr(argv[n_arg] + 2, '-') + 1); } else strcpybuff(command, argv[n_arg] + 2); need_param = 2; } /* Now solve the alias */ pos = optalias_find(command); if (pos >= 0) { /* Copy real name */ strcpybuff(command, hts_optalias[pos][1]); /* With parameters? */ if (strncmp(hts_optalias[pos][2], "param", 5) == 0) { /* Copy parameters? */ if (need_param == 2) { if ((n_arg + 1 >= argc) || (argv[n_arg + 1][0] == '-')) { /* no supplemental parameter */ sprintf(return_error, "Syntax error:\n\tOption %s needs to be followed by a parameter: %s \n\t%s\n", command, command, _NOT_NULL(optalias_help(command))); return 0; } strcpybuff(param, argv[n_arg + 1]); need_param = 2; } } else need_param = 1; /* Final result */ /* Must be alone (-P /tmp) */ if (strcmp(hts_optalias[pos][2], "param1") == 0) { strcpybuff(return_argv[0], command); strcpybuff(return_argv[1], param); *return_argc = 2; /* 2 parameters returned */ } /* Alone with parameter (+*.gif) */ else if (strcmp(hts_optalias[pos][2], "param0") == 0) { /* Command */ strcpybuff(return_argv[0], command); strcatbuff(return_argv[0], param); } /* Together (-c8) */ else { /* Command */ strcpybuff(return_argv[0], command); /* Parameters accepted */ if (strncmp(hts_optalias[pos][2], "param", 5) == 0) { /* --cache=off or --index=on */ if (strcmp(param, "off") == 0) strcatbuff(return_argv[0], "0"); else if (strcmp(param, "on") == 0) { // on is the default // strcatbuff(return_argv[0],"1"); } else strcatbuff(return_argv[0], param); } *return_argc = 1; /* 1 parameter returned */ } } else { sprintf(return_error, "Unknown option: %s\n", command); return 0; } return need_param; } /* Check -O */ { int pos; if ((pos = optreal_find(argv[n_arg])) >= 0) { if ((strcmp(hts_optalias[pos][2], "param1") == 0) || (strcmp(hts_optalias[pos][2], "param0") == 0)) { if ((n_arg + 1 >= argc) || (argv[n_arg + 1][0] == '-')) { /* no supplemental parameter */ sprintf(return_error, "Syntax error:\n\tOption %s needs to be followed by a parameter: %s \n\t%s\n", argv[n_arg], argv[n_arg], _NOT_NULL(optalias_help(argv[n_arg]))); return 0; } /* Copy parameters */ strcpybuff(return_argv[0], argv[n_arg]); strcpybuff(return_argv[1], argv[n_arg + 1]); /* And return */ *return_argc = 2; /* 2 parameters returned */ return 2; /* 2 parameters used */ } } } /* Copy and return other unknown option */ strcpybuff(return_argv[0], argv[n_arg]); return 1; } /* Finds the option alias and returns the index, or -1 if failed */ int optalias_find(const char *token) { if (token[0] != '\0') { int i = 0; while(hts_optalias[i][0][0] != '\0') { if (strcmp(token, hts_optalias[i][0]) == 0) { return i; } i++; } } return -1; } /* Finds the real option and returns the index, or -1 if failed */ int optreal_find(const char *token) { if (token[0] != '\0') { int i = 0; while(hts_optalias[i][0][0] != '\0') { if (strcmp(token, hts_optalias[i][1]) == 0) { return i; } i++; } } return -1; } const char *optreal_value(int p) { return hts_optalias[p][1]; } const char *optalias_value(int p) { return hts_optalias[p][0]; } const char *opttype_value(int p) { return hts_optalias[p][2]; } const char *opthelp_value(int p) { return hts_optalias[p][3]; } /* Help for option , empty if not available, or NULL if unknown */ const char *optalias_help(const char *token) { int pos = optalias_find(token); if (pos >= 0) return hts_optalias[pos][3]; else return NULL; } /* Include a file to the current command line */ /* example: set sockets 8 index on allow *.gif deny ad.* */ /* Note: NOT utf-8 */ int optinclude_file(const char *name, int *argc, char **argv, char *x_argvblk, int *x_ptr) { FILE *fp; fp = fopen(name, "rb"); if (fp) { char line[256]; int insert_after = 1; /* first, insert after program filename */ while(!feof(fp)) { char *a, *b; int result; /* read line */ linput(fp, line, 250); hts_lowcase(line); if (strnotempty(line)) { /* no comment line: # // ; */ if (strchr("#/;", line[0]) == NULL) { /* right trim */ a = line + strlen(line) - 1; while(is_realspace(*a)) *(a--) = '\0'; /* jump "set " and spaces */ a = line; while(is_realspace(*a)) a++; if (strncmp(a, "set", 3) == 0) { if (is_realspace(*(a + 3))) { a += 4; } } while(is_realspace(*a)) a++; /* delete = ("sockets=8") */ if ((b = strchr(a, '='))) *b = ' '; /* isolate option and parameter */ b = a; while((!is_realspace(*b)) && (*b)) b++; if (*b) { *b = '\0'; b++; } /* a is now the option, b the parameter */ { int return_argc; char return_error[256]; char _tmp_argv[4][HTS_CDLMAXSIZE]; char *tmp_argv[4]; tmp_argv[0] = _tmp_argv[0]; tmp_argv[1] = _tmp_argv[1]; tmp_argv[2] = _tmp_argv[2]; tmp_argv[3] = _tmp_argv[3]; strcpybuff(_tmp_argv[0], "--"); strcatbuff(_tmp_argv[0], a); strcpybuff(_tmp_argv[1], b); result = optalias_check(2, (const char *const *) tmp_argv, 0, &return_argc, (tmp_argv + 2), return_error); if (!result) { printf("%s\n", return_error); } else { int insert_after_argc; /* Insert parameters BUT so that they can be in the same order */ /* temporary argc: Number of parameters after minus insert_after_argc */ insert_after_argc = (*argc) - insert_after; cmdl_ins((tmp_argv[2]), insert_after_argc, (argv + insert_after), x_argvblk, (*x_ptr)); *argc = insert_after_argc + insert_after; insert_after++; /* Second one */ if (return_argc > 1) { insert_after_argc = (*argc) - insert_after; cmdl_ins((tmp_argv[3]), insert_after_argc, (argv + insert_after), x_argvblk, (*x_ptr)); *argc = insert_after_argc + insert_after; insert_after++; } /* increment to nbr of used parameters */ /* insert_after+=result; */ } } } } } fclose(fp); return 1; } return 0; } /* Get home directory, '.' if failed */ /* example: /home/smith */ const char *hts_gethome(void) { const char *home = getenv("HOME"); if (home) return home; else return "."; } /* Convert ~/foo into /home/smith/foo */ void expand_home(String * str) { if (StringSub(*str, 1) == '~') { char BIGSTK tempo[HTS_URLMAXSIZE * 2]; strcpybuff(tempo, hts_gethome()); strcatbuff(tempo, StringBuff(*str) + 1); StringCopy(*str, tempo); } } httrack-3.49.5/src/htswizard.c0000644000175000017500000010546114336470674013174 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: httrack.c subroutines: */ /* wizard system (accept/refuse links) */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* Internal engine bytecode */ #define HTS_INTERNAL_BYTECODE #include "htscore.h" #include "htswizard.h" /* specific definitions */ #include "htsbase.h" #include /* END specific definitions */ // libérer filters[0] pour insérer un élément dans filters[0] #define HT_INSERT_FILTERS0 do {\ int i;\ if (*opt->filters.filptr > 0) {\ for(i = (*opt->filters.filptr)-1 ; i>=0 ; i--) {\ strcpybuff((*opt->filters.filters)[i+1],(*opt->filters.filters)[i]);\ }\ }\ (*opt->filters.filters)[0][0]='\0';\ (*opt->filters.filptr)++;\ assertf((*opt->filters.filptr) < opt->maxfilter); \ } while(0) typedef struct htspair_t { const char *tag; const char *attr; } htspair_t; /* "embedded" */ htspair_t hts_detect_embed[] = { {"img", "src"}, {"link", "href"}, /* embedded script hack */ {"script", ".src"}, /* style */ {"style", "import"}, {NULL, NULL} }; /* Internal */ static int hts_acceptlink_(httrackp * opt, int ptr, const char *adr, const char *fil, const char *tag, const char *attribute, int *set_prio_to, int *just_test_it); /* httrackp opt bloc d'options int ptr,int lien_tot,lien_url** liens relatif aux liens char* adr,char* fil adresse/fichier à tester char** filters,int filptr,int filter_max relatif aux filtres robots_wizard* robots relatif aux robots int* set_prio_to callback obligatoire "capturer ce lien avec prio=N-1" int* just_test_it callback optionnel "ne faire que tester ce lien éventuellement" retour: 0 accepté 1 refusé -1 pas d'avis */ int hts_acceptlink(httrackp * opt, int ptr, const char *adr, const char *fil, const char *tag, const char *attribute, int *set_prio_to, int *just_test_it) { int forbidden_url = hts_acceptlink_(opt, ptr, adr, fil, tag, attribute, set_prio_to, just_test_it); int prev_prio = set_prio_to ? *set_prio_to : 0; // -------------------- PHASE 6 -------------------- { int test_url = RUN_CALLBACK3(opt, check_link, adr, fil, forbidden_url); if (test_url != -1) { forbidden_url = test_url; if (set_prio_to) *set_prio_to = prev_prio; } } return forbidden_url; } static int cmp_token(const char *tag, const char *cmp) { int p; return (strncasecmp(tag, cmp, (p = (int) strlen(cmp))) == 0 && !isalnum((unsigned char) tag[p])); } static int hts_acceptlink_(httrackp * opt, int ptr, const char *adr, const char *fil, const char *tag, const char *attribute, int *set_prio_to, int *just_test_it) { int forbidden_url = -1; int meme_adresse; int embedded_triggered = 0; #define _FILTERS (*opt->filters.filters) #define _FILTERS_PTR (opt->filters.filptr) #define _ROBOTS ((robots_wizard*)opt->robotsptr) int may_set_prio_to = 0; // -------------------- PHASE 0 -------------------- /* Infos */ hts_log_print(opt, LOG_DEBUG, "wizard test begins: %s%s", adr, fil); /* Already exists? Then, we know that we knew that this link had to be known */ if (adr[0] != '\0' && fil[0] != '\0' && opt->hash != NULL && hash_read(opt->hash, adr, fil, 1) >= 0) { return 0; /* Yokai */ } // -------------------- PRELUDE OF PHASE 3-BIS -------------------- /* Built-in known tags (, ..) */ if (forbidden_url != 0 && opt->nearlink && tag != NULL && attribute != NULL) { int i; for(i = 0; hts_detect_embed[i].tag != NULL; i++) { if (cmp_token(tag, hts_detect_embed[i].tag) && cmp_token(attribute, hts_detect_embed[i].attr) ) { embedded_triggered = 1; break; } } } // -------------------- PHASE 1 -------------------- /* Doit-on traiter les non html? */ if ((opt->getmode & 2) == 0) { // non on ne doit pas if (!ishtml(opt, fil)) { // non il ne faut pas //adr[0]='\0'; // ne pas traiter ce lien, pas traiter forbidden_url = 1; // interdire récupération du lien hts_log_print(opt, LOG_DEBUG, "non-html file ignored at %s : %s", adr, fil); } } /* Niveau 1: ne pas parser suivant! */ if (ptr > 0) { if ((heap(ptr)->depth <= 0) || (heap(ptr)->depth <= 1 && !embedded_triggered)) { forbidden_url = 1; // interdire récupération du lien hts_log_print(opt, LOG_DEBUG, "file from too far level ignored at %s : %s", adr, fil); } } /* en cas d'échec en phase 1, retour immédiat! */ if (forbidden_url == 1) { return forbidden_url; } // -------------------- PHASE 2 -------------------- // ------------------------------------------------------ // doit-on traiter ce lien?.. vérifier droits de déplacement meme_adresse = strfield2(adr, urladr()); if (meme_adresse) hts_log_print(opt, LOG_DEBUG, "Compare addresses: %s=%s", adr, urladr()); else hts_log_print(opt, LOG_DEBUG, "Compare addresses: %s!=%s", adr, urladr()); if (meme_adresse) { // même adresse { // tester interdiction de descendre // MODIFIE : en cas de remontée puis de redescente, il se pouvait qu'on ne puisse pas atteindre certains fichiers // problème: si un fichier est virtuellement accessible via une page mais dont le lien est sur une autre *uniquement*.. char BIGSTK tempo[HTS_URLMAXSIZE * 2]; char BIGSTK tempo2[HTS_URLMAXSIZE * 2]; tempo[0] = tempo2[0] = '\0'; // note (up/down): on calcule à partir du lien primaire, ET du lien précédent. // ex: si on descend 2 fois on peut remonter 1 fois if (lienrelatif(tempo, fil, heap(heap(ptr)->premier)->fil) == 0) { if (lienrelatif(tempo2, fil, heap(ptr)->fil) == 0) { hts_log_print(opt, LOG_DEBUG, "build relative links to test: %s %s (with %s and %s)", tempo, tempo2, heap(heap(ptr)->premier)->fil, heap(ptr)->fil); // si vient de primary, ne pas tester lienrelatif avec (car host "différent") /*if (heap(heap(ptr)->premier) == 0) { // vient de primary } */ // NEW: finalement OK, sauf pour les moved repérés par link_import // PROBLEME : annulé a cause d'un lien éventuel isolé accepté..qui entrainerait un miroir // (test même niveau (NOUVEAU à cause de certains problèmes de filtres non intégrés)) // NEW if ((tempo[0] != '\0' && tempo[1] != '\0' && strchr(tempo + 1, '/') == 0) || (tempo2[0] != '\0' && tempo2[1] != '\0' && strchr(tempo2 + 1, '/') == 0) ) { if (!heap(ptr)->link_import) { // ne résulte pas d'un 'moved' forbidden_url = 0; hts_log_print(opt, LOG_DEBUG, "same level link authorized: %s%s", adr, fil); } } // down if ((strncmp(tempo, "../", 3)) || (strncmp(tempo2, "../", 3))) { // pas montée sinon ne nbous concerne pas int test1, test2; if (!strncmp(tempo, "../", 3)) test1 = 0; else test1 = (strchr(tempo + ((*tempo == '/') ? 1 : 0), '/') != NULL); if (!strncmp(tempo2, "../", 3)) test2 = 0; else test2 = (strchr(tempo2 + ((*tempo2 == '/') ? 1 : 0), '/') != NULL); if ((test1) && (test2)) { // on ne peut que descendre if ((opt->seeker & 1) == 0) { // interdiction de descendre forbidden_url = 1; hts_log_print(opt, LOG_DEBUG, "lower link canceled: %s%s", adr, fil); } else { // autorisé à priori - NEW if (!heap(ptr)->link_import) { // ne résulte pas d'un 'moved' forbidden_url = 0; hts_log_print(opt, LOG_DEBUG, "lower link authorized: %s%s", adr, fil); } } } else if ((test1) || (test2)) { // on peut descendre pour accéder au lien if ((opt->seeker & 1) != 0) { // on peut descendre - NEW if (!heap(ptr)->link_import) { // ne résulte pas d'un 'moved' forbidden_url = 0; hts_log_print(opt, LOG_DEBUG, "lower link authorized: %s%s", adr, fil); } } } } // up if ((!strncmp(tempo, "../", 3)) && (!strncmp(tempo2, "../", 3))) { // impossible sans monter if ((opt->seeker & 2) == 0) { // interdiction de monter forbidden_url = 1; hts_log_print(opt, LOG_DEBUG, "upper link canceled: %s%s", adr, fil); } else { // autorisé à monter - NEW if (!heap(ptr)->link_import) { // ne résulte pas d'un 'moved' forbidden_url = 0; hts_log_print(opt, LOG_DEBUG, "upper link authorized: %s%s", adr, fil); } } } else if ((!strncmp(tempo, "../", 3)) || (!strncmp(tempo2, "../", 3))) { // Possible en montant if ((opt->seeker & 2) != 0) { // autorisé à monter - NEW if (!heap(ptr)->link_import) { // ne résulte pas d'un 'moved' forbidden_url = 0; hts_log_print(opt, LOG_DEBUG, "upper link authorized: %s%s", adr, fil); } } // sinon autorisé en descente } } else { hts_log_print(opt, LOG_ERROR, "Error building relative link %s and %s", fil, heap(ptr)->fil); } } else { hts_log_print(opt, LOG_ERROR, "Error building relative link %s and %s", fil, heap(heap(ptr)->premier)->fil); } } // tester interdiction de descendre? { // tester interdiction de monter char BIGSTK tempo[HTS_URLMAXSIZE * 2]; char BIGSTK tempo2[HTS_URLMAXSIZE * 2]; if (lienrelatif(tempo, fil, heap(heap(ptr)->premier)->fil) == 0) { if (lienrelatif(tempo2, fil, heap(ptr)->fil) == 0) { } else { hts_log_print(opt, LOG_ERROR, "Error building relative link %s and %s", fil, heap(ptr)->fil); } } else { hts_log_print(opt, LOG_ERROR, "Error building relative link %s and %s", fil, heap(heap(ptr)->premier)->fil); } } // fin tester interdiction de monter } else { // adresse différente, sortir? //if (!opt->wizard) { // mode non wizard // doit-on traiter ce lien?.. vérifier droits de sortie switch ((opt->travel & 255)) { case 0: if (!opt->wizard) // mode non wizard forbidden_url = 1; break; // interdicton de sortir au dela de l'adresse case 1:{ // sortie sur le même dom.xxx size_t i = strlen(adr) - 1; size_t j = strlen(urladr()) - 1; if ((i > 0) && (j > 0)) { while((i > 0) && (adr[i] != '.')) i--; while((j > 0) && (urladr()[j] != '.')) j--; if ((i > 0) && (j > 0)) { i--; j--; while((i > 0) && (adr[i] != '.')) i--; while((j > 0) && (urladr()[j] != '.')) j--; } } if ((i > 0) && (j > 0)) { if (!strfield2(adr + i, urladr() + j)) { // != if (!opt->wizard) { // mode non wizard //printf("refused: %s\n",adr); forbidden_url = 1; // pas même domaine hts_log_print(opt, LOG_DEBUG, "foreign domain link canceled: %s%s", adr, fil); } } else { if (opt->wizard) { // mode wizard forbidden_url = 0; // même domaine hts_log_print(opt, LOG_DEBUG, "same domain link authorized: %s%s", adr, fil); } } } else forbidden_url = 1; } break; case 2:{ // sortie sur le même .xxx size_t i = strlen(adr) - 1; size_t j = strlen(urladr()) - 1; while((i > 0) && (adr[i] != '.')) i--; while((j > 0) && (urladr()[j] != '.')) j--; if ((i > 0) && (j > 0)) { if (!strfield2(adr + i, urladr() + j)) { // !- if (!opt->wizard) { // mode non wizard //printf("refused: %s\n",adr); forbidden_url = 1; // pas même .xx hts_log_print(opt, LOG_DEBUG, "foreign location link canceled: %s%s", adr, fil); } } else { if (opt->wizard) { // mode wizard forbidden_url = 0; // même domaine hts_log_print(opt, LOG_DEBUG, "same location link authorized: %s%s", adr, fil); } } } else forbidden_url = 1; } break; case 7: // everywhere!! if (opt->wizard) { // mode wizard forbidden_url = 0; break; } } // switch // ANCIENNE POS -- récupérer les liens à côtés d'un lien (nearlink) } // fin test adresse identique/différente // -------------------- PHASE 3 -------------------- // récupérer les liens à côtés d'un lien (nearlink) (nvelle pos) if (forbidden_url != 0 && opt->nearlink) { if (!ishtml(opt, fil)) { // non html //printf("ok %s%s\n",ad,fil); forbidden_url = 0; // autoriser may_set_prio_to = 1 + 1; // set prio to 1 (parse but skip urls) if near is the winner hts_log_print(opt, LOG_DEBUG, "near link authorized: %s%s", adr, fil); } } // -------------------- PHASE 3-BIS -------------------- /* Built-in known tags (, ..) */ if (forbidden_url != 0 && embedded_triggered) { forbidden_url = 0; // autoriser may_set_prio_to = 1 + 1; // set prio to 1 (parse but skip urls) if near is the winner hts_log_print(opt, LOG_DEBUG, "near link authorized (friendly tag): %s%s", adr, fil); } // -------------------- PHASE 4 -------------------- // ------------------------------------------------------ // Si wizard, il se peut qu'on autorise ou qu'on interdise // un lien spécial avant même de tester sa position, sa hiérarchie etc. // peut court-circuiter le forbidden_url précédent if (opt->wizard) { // le wizard entre en action.. // int question = 1; // poser une question int force_mirror = 0; // pour mirror links int filters_answer = 0; // décision prise par les filtres char BIGSTK l[HTS_URLMAXSIZE * 2]; char BIGSTK lfull[HTS_URLMAXSIZE * 2]; if (forbidden_url != -1) question = 0; // pas de question, résolu // former URL complète du lien actuel strcpybuff(l, jump_identification_const(adr)); if (*fil != '/') strcatbuff(l, "/"); strcatbuff(l, fil); // full version (http://foo:bar@www.foo.com/bar.html) if (!link_has_authority(adr)) strcpybuff(lfull, "http://"); else lfull[0] = '\0'; strcatbuff(lfull, adr); if (*fil != '/') strcatbuff(lfull, "/"); strcatbuff(lfull, fil); // tester filters (URLs autorisées ou interdites explicitement) // si lien primaire on saute le joker, on est pas lémur if (ptr == 0) { // lien primaire, autoriser question = 1; // la question sera résolue automatiquement forbidden_url = 0; may_set_prio_to = 0; // clear may-set flag } else { // eternal depth first // vérifier récursivité extérieure if (opt->extdepth > 0) { if ( /*question && */ (ptr > 0) && (!force_mirror)) { // well, this is kinda a hak // we don't want to mirror EVERYTHING, and we have to decide where to stop // there is no way yet to tag "external" links, and therefore links that are // "weak" (authorized depth < external depth) are just not considered for external // hack if (heap(ptr)->depth > opt->extdepth) { // *set_prio_to = opt->extdepth + 1; *set_prio_to = 1 + (opt->extdepth); may_set_prio_to = 0; // clear may-set flag forbidden_url = 0; // autorisé question = 0; // résolution auto if (question) { hts_log_print(opt, LOG_DEBUG, "(wizard) ambiguous link accepted (external depth): link %s at %s%s", l, urladr(), urlfil()); } else { hts_log_print(opt, LOG_DEBUG, "(wizard) forced to accept link (external depth): link %s at %s%s", l, urladr(), urlfil()); } } } } // filters { int jok; const char *mdepth = ""; // filters, 0=sait pas 1=ok -1=interdit { int jokDepth1 = 0, jokDepth2 = 0; int jok1 = 0, jok2 = 0; jok1 = fa_strjoker( /*url */ 0, _FILTERS, *_FILTERS_PTR, lfull, NULL, NULL, &jokDepth1); jok2 = fa_strjoker( /*url */ 0, _FILTERS, *_FILTERS_PTR, l, NULL, NULL, &jokDepth2); if (jok2 == 0) { // #2 doesn't know jok = jok1; // then, use #1 mdepth = _FILTERS[jokDepth1]; } else if (jok1 == 0) { // #1 doesn't know jok = jok2; // then, use #2 mdepth = _FILTERS[jokDepth2]; } else if (jokDepth1 >= jokDepth2) { // #1 matching rule is "after" #2, then it is prioritary jok = jok1; mdepth = _FILTERS[jokDepth1]; } else { // #2 matching rule is "after" #1, then it is prioritary jok = jok2; mdepth = _FILTERS[jokDepth2]; } } if (jok == 1) { // autorisé filters_answer = 1; // décision prise par les filtres question = 0; // ne pas poser de question, autorisé forbidden_url = 0; // URL autorisée may_set_prio_to = 0; // clear may-set flag hts_log_print(opt, LOG_DEBUG, "(wizard) explicit authorized (%s) link: link %s at %s%s", mdepth, l, urladr(), urlfil()); } else if (jok == -1) { // forbidden filters_answer = 1; // décision prise par les filtres question = 0; // ne pas poser de question: forbidden_url = 1; // URL interdite hts_log_print(opt, LOG_DEBUG, "(wizard) explicit forbidden (%s) link: link %s at %s%s", mdepth, l, urladr(), urlfil()); } // sinon on touche à rien } } // vérifier mode mirror links if (question) { if (opt->mirror_first_page) { // mode mirror links if (heap(ptr)->precedent == 0) { // parent=primary! forbidden_url = 0; // autorisé may_set_prio_to = 0; // clear may-set flag question = 1; // résolution auto force_mirror = 5; // mirror (5) hts_log_print(opt, LOG_DEBUG, "(wizard) explicit mirror link: link %s at %s%s", l, urladr(), urlfil()); } } } // on doit poser la question.. peut on la poser? // (oui je sais quel preuve de délicatesse, merci merci) if ((question) && (ptr > 0) && (!force_mirror)) { if (opt->wizard == 2) { // éliminer tous les liens non répertoriés comme autorisés (ou inconnus) question = 0; forbidden_url = 1; hts_log_print(opt, LOG_DEBUG, "(wizard) ambiguous forbidden link: link %s at %s%s", l, urladr(), urlfil()); } } // vérifier robots.txt if (opt->robots) { int r = checkrobots(_ROBOTS, adr, fil); if (r == -1) { // interdiction #if DEBUG_ROBOTS printf("robots.txt forbidden: %s%s\n", adr, fil); #endif // question résolue, par les filtres, et mode robot non strict if ((!question) && (filters_answer) && (opt->robots == 1) && (forbidden_url != 1)) { r = 0; // annuler interdiction des robots if (!forbidden_url) { hts_log_print(opt, LOG_DEBUG, "Warning link followed against robots.txt: link %s at %s%s", l, adr, fil); } } if (r == -1) { // interdire forbidden_url = 1; question = 0; hts_log_print(opt, LOG_DEBUG, "(robots.txt) forbidden link: link %s at %s%s", l, adr, fil); } } } if (!question) { if (!forbidden_url) { hts_log_print(opt, LOG_DEBUG, "(wizard) shared foreign domain link: link %s at %s%s", l, urladr(), urlfil()); } else { hts_log_print(opt, LOG_DEBUG, "(wizard) cancelled foreign domain link: link %s at %s%s", l, urladr(), urlfil()); } #if BDEBUG==3 printf("at %s in %s, wizard says: url %s ", urladr(), urlfil(), l); if (forbidden_url) printf("cancelled"); else printf(">SHARED<"); printf("\n"); #endif } /* en cas de question, ou lien primaire (enregistrer autorisations) */ if (question || (ptr == 0)) { const char *s; int n = 0; // si primaire (plus bas) alors ... if ((ptr != 0) && (force_mirror == 0)) { char BIGSTK tempo[HTS_URLMAXSIZE * 2]; tempo[0] = '\0'; strcatbuff(tempo, adr); strcatbuff(tempo, fil); s = RUN_CALLBACK1(opt, query3, tempo); if (strnotempty(s) == 0) // entrée n = 0; else if (isdigit((unsigned char) *s)) sscanf(s, "%d", &n); else { switch (*s) { case '*': n = -1; break; case '!': n = -999; { /*char *a; int i; a=copie_de_adr-128; if (aseeker & 1) == 0) { // interdiction de descendre n = 7; } else { n = 5; // autoriser miroir répertoires descendants (lien primaire) } } else // forcer valeur (sub-wizard) n = force_mirror; } /* sanity check - reallocate filters HERE */ if ((*_FILTERS_PTR) + 1 >= opt->maxfilter) { opt->maxfilter += HTS_FILTERSINC; if (filters_init(&_FILTERS, opt->maxfilter, HTS_FILTERSINC) == 0) { printf("PANIC! : Too many filters : >%d [%d]\n", (*_FILTERS_PTR), __LINE__); fflush(stdout); hts_log_print(opt, LOG_PANIC, "Too many filters, giving up..(>%d)", (*_FILTERS_PTR)); hts_log_print(opt, LOG_INFO, "To avoid that: use #F option for more filters (example: -#F5000)"); assertf("too many filters - giving up" == NULL); // wild.. } } // here we have enough room for a new filter if necessary switch (n) { case -1: // sauter tout le reste forbidden_url = 1; opt->wizard = 2; // sauter tout le reste break; case 0: // interdire les mêmes liens: adr/fil forbidden_url = 1; HT_INSERT_FILTERS0; // insérer en 0 strcpybuff(_FILTERS[0], "-"); strcatbuff(_FILTERS[0], jump_identification_const(adr)); if (*fil != '/') strcatbuff(_FILTERS[0], "/"); strcatbuff(_FILTERS[0], fil); break; case 1: // éliminer répertoire entier et sous rép: adr/path/ * forbidden_url = 1; { size_t i = strlen(fil) - 1; while((fil[i] != '/') && (i > 0)) i--; if (fil[i] == '/') { HT_INSERT_FILTERS0; // insérer en 0 strcpybuff(_FILTERS[0], "-"); strcatbuff(_FILTERS[0], jump_identification_const(adr)); if (*fil != '/') strcatbuff(_FILTERS[0], "/"); strncatbuff(_FILTERS[0], fil, i); if (_FILTERS[0][strlen(_FILTERS[0]) - 1] != '/') strcatbuff(_FILTERS[0], "/"); strcatbuff(_FILTERS[0], "*"); } } // ** ... break; case 2: // adresse adr* forbidden_url = 1; HT_INSERT_FILTERS0; // insérer en 0 strcpybuff(_FILTERS[0], "-"); strcatbuff(_FILTERS[0], jump_identification_const(adr)); strcatbuff(_FILTERS[0], "*"); break; case 3: // ** A FAIRE forbidden_url = 1; /* { int i=strlen(adr)-1; while((adr[i]!='/') && (i>0)) i--; if (i>0) { } } */ break; // case 4: // same link // PAS BESOIN!! /*HT_INSERT_FILTERS0; // insérer en 0 strcpybuff(_FILTERS[0],"+"); strcatbuff(_FILTERS[0],adr); if (*fil!='/') strcatbuff(_FILTERS[0],"/"); strcatbuff(_FILTERS[0],fil); */ // étant donné le renversement wizard/primary filter (les primary autorisent up/down ET interdisent) // il faut éviter d'un lien isolé effectue un miroir total.. *set_prio_to = 0 + 1; // niveau de récursion=0 (pas de miroir) break; case 5: // autoriser répertoire entier et fils if ((opt->seeker & 2) == 0) { // interdiction de monter size_t i = strlen(fil) - 1; while((fil[i] != '/') && (i > 0)) i--; if (fil[i] == '/') { HT_INSERT_FILTERS0; // insérer en 0 strcpybuff(_FILTERS[0], "+"); strcatbuff(_FILTERS[0], jump_identification_const(adr)); if (*fil != '/') strcatbuff(_FILTERS[0], "/"); strncatbuff(_FILTERS[0], fil, i + 1); strcatbuff(_FILTERS[0], "*"); } } else { // autoriser domaine alors!! HT_INSERT_FILTERS0; // insérer en 0 strcpybuff(filters[filptr],"+"); strcpybuff(_FILTERS[0], "+"); strcatbuff(_FILTERS[0], jump_identification_const(adr)); strcatbuff(_FILTERS[0], "*"); } break; case 6: // same domain HT_INSERT_FILTERS0; // insérer en 0 strcpybuff(filters[filptr],"+"); strcpybuff(_FILTERS[0], "+"); strcatbuff(_FILTERS[0], jump_identification_const(adr)); strcatbuff(_FILTERS[0], "*"); break; // case 7: // autoriser ce répertoire { size_t i = strlen(fil) - 1; while((fil[i] != '/') && (i > 0)) i--; if (fil[i] == '/') { HT_INSERT_FILTERS0; // insérer en 0 strcpybuff(_FILTERS[0], "+"); strcatbuff(_FILTERS[0], jump_identification_const(adr)); if (*fil != '/') strcatbuff(_FILTERS[0], "/"); strncatbuff(_FILTERS[0], fil, i + 1); strcatbuff(_FILTERS[0], "*[file]"); } } break; case 50: // on fait rien break; } // switch } // test du wizard sur l'url } // fin du test wizard.. // -------------------- PHASE 5 -------------------- // lien non autorisé, peut-on juste le tester? if (just_test_it) { if (forbidden_url == 1) { if (opt->travel & 256) { // tester tout de même if (strfield(adr, "ftp://") == 0) { // PAS ftp! forbidden_url = 1; // oui oui toujours interdit (note: sert à rien car ==1 mais c pour comprendre) *just_test_it = 1; // mais on teste hts_log_print(opt, LOG_DEBUG, "Testing link %s%s", adr, fil); } } } //adr[0]='\0'; // cancel } // -------------------- FINAL PHASE -------------------- // Test if the "Near" test won if (may_set_prio_to && forbidden_url == 0) { *set_prio_to = may_set_prio_to; } return forbidden_url; #undef _FILTERS #undef _FILTERS_PTR #undef _ROBOTS } int hts_acceptmime(httrackp * opt, int ptr, const char *adr, const char *fil, const char *mime) { #define _FILTERS (*opt->filters.filters) #define _FILTERS_PTR (opt->filters.filptr) #define _ROBOTS ((robots_wizard*)opt->robotsptr) int forbidden_url = -1; const char *mdepth = ""; int jokDepth = 0; int jok = 0; /* Authorized ? */ jok = fa_strjoker( /*mime */ 1, _FILTERS, *_FILTERS_PTR, mime, NULL, NULL, &jokDepth); if (jok != 0) { mdepth = _FILTERS[jokDepth]; if (jok == 1) { // autorisé forbidden_url = 0; // URL autorisée hts_log_print(opt, LOG_DEBUG, "(wizard) explicit authorized (%s) link %s%s: mime '%s'", mdepth, adr, fil, mime); } else if (jok == -1) { // forbidden forbidden_url = 1; // URL interdite hts_log_print(opt, LOG_DEBUG, "(wizard) explicit forbidden (%s) link %s%s: mime '%s'", mdepth, adr, fil, mime); } // sinon on touche à rien } /* userdef test */ { int test_url = RUN_CALLBACK4(opt, check_mime, adr, fil, mime, forbidden_url); if (test_url != -1) { forbidden_url = test_url; } } return forbidden_url; #undef _FILTERS #undef _FILTERS_PTR #undef _ROBOTS } // tester taille int hts_testlinksize(httrackp * opt, const char *adr, const char *fil, LLint size) { int jok = 0; if (size >= 0) { char BIGSTK l[HTS_URLMAXSIZE * 2]; char BIGSTK lfull[HTS_URLMAXSIZE * 2]; if (size >= 0) { LLint sz = size; int size_flag = 0; // former URL complète du lien actuel strcpybuff(l, jump_identification_const(adr)); if (*fil != '/') strcatbuff(l, "/"); strcatbuff(l, fil); // if (!link_has_authority(adr)) strcpybuff(lfull, "http://"); else lfull[0] = '\0'; strcatbuff(lfull, adr); if (*fil != '/') strcatbuff(l, "/"); strcatbuff(lfull, fil); // filters, 0=sait pas 1=ok -1=interdit { int jokDepth1 = 0, jokDepth2 = 0; int jok1 = 0, jok2 = 0; LLint sz1 = size, sz2 = size; int size_flag1 = 0, size_flag2 = 0; jok1 = fa_strjoker( /*url */ 0, *opt->filters.filters, *opt->filters.filptr, lfull, &sz1, &size_flag1, &jokDepth1); jok2 = fa_strjoker( /*url */ 0, *opt->filters.filters, *opt->filters.filptr, l, &sz2, &size_flag2, &jokDepth2); if (jok2 == 0) { // #2 doesn't know jok = jok1; // then, use #1 sz = sz1; size_flag = size_flag1; } else if (jok1 == 0) { // #1 doesn't know jok = jok2; // then, use #2 sz = sz2; size_flag = size_flag2; } else if (jokDepth1 >= jokDepth2) { // #1 matching rule is "after" #2, then it is prioritary jok = jok1; sz = sz1; size_flag = size_flag1; } else { // #2 matching rule is "after" #1, then it is prioritary jok = jok2; sz = sz2; size_flag = size_flag2; } } // log if (jok == 1) { hts_log_print(opt, LOG_DEBUG, "File confirmed (size test): %s%s (" LLintP ")", adr, fil, (LLint) (size)); } else if (jok == -1) { if (size_flag) { /* interdit à cause de la taille */ hts_log_print(opt, LOG_DEBUG, "File cancelled due to its size: %s%s (" LLintP ", limit: " LLintP ")", adr, fil, (LLint) (size), (LLint) (sz)); } else { jok = 1; } } } } return jok; } #undef HT_INSERT_FILTERS0 httrack-3.49.5/src/htstools.c0000644000175000017500000010545714336470674013041 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: httrack.c subroutines: */ /* various tools (filename analyzing ..) */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* Internal engine bytecode */ #define HTS_INTERNAL_BYTECODE /* String */ #include #include "htscore.h" #include "htstools.h" #include "htsstrings.h" #include "htscharset.h" #ifdef _WIN32 #include "windows.h" #else #include #ifdef HAVE_UNISTD_H #include #endif #include #endif // Portable directory find functions #ifndef HTS_DEF_FWSTRUCT_find_handle_struct #define HTS_DEF_FWSTRUCT_find_handle_struct typedef struct find_handle_struct find_handle_struct; #endif #ifdef _WIN32 struct find_handle_struct { WIN32_FIND_DATAA hdata; HANDLE handle; }; #else struct find_handle_struct { DIR *hdir; struct dirent *dirp; STRUCT_STAT filestat; char path[2048]; }; #endif //#ifndef HTS_DEF_FWSTRUCT_topindex_chain //#define HTS_DEF_FWSTRUCT_topindex_chain //typedef struct topindex_chain topindex_chain; //#endif //struct topindex_chain { // int level; /* sort level */ // char *category; /* category */ // char name[2048]; /* path */ // struct topindex_chain *next; /* next element */ //}; /* Tools */ static int ehexh(char c) { if ((c >= '0') && (c <= '9')) return c - '0'; if ((c >= 'a') && (c <= 'f')) c -= ('a' - 'A'); if ((c >= 'A') && (c <= 'F')) return (c - 'A' + 10); return 0; } static int ehex(const char *s) { return 16 * ehexh(*s) + ehexh(*(s + 1)); } static void unescapehttp(const char *s, String * tempo) { size_t i; for(i = 0; s[i] != '\0'; i++) { if (s[i] == '%' && s[i + 1] == '%') { i++; StringAddchar(*tempo, '%'); } else if (s[i] == '%') { char hc; i++; hc = (char) ehex(s + i); StringAddchar(*tempo, (char) hc); i++; // sauter 2 caractères finalement } else if (s[i] == '+') { StringAddchar(*tempo, ' '); } else StringAddchar(*tempo, s[i]); } } // forme à partir d'un lien et du contexte (origin_fil et origin_adr d'où il est tiré) adr et fil // [adr et fil sont des buffers de 1ko] // 0 : ok // -1 : erreur // -2 : protocole non supporté (ftp) int ident_url_relatif(const char *lien, const char *origin_adr, const char *origin_fil, lien_adrfil* const adrfil) { int ok = 0; int scheme = 0; assertf(adrfil != NULL); adrfil->adr[0] = '\0'; adrfil->fil[0] = '\0'; //effacer buffers // lien non vide! if (strnotempty(lien) == 0) return -1; // erreur! // Scheme? { const char *a = lien; while(isalpha((unsigned char) *a)) a++; if (*a == ':') scheme = 1; } // filtrer les parazites (mailto & cie) // scheme+authority (//) if ((strfield(lien, "http://")) // scheme+// || (strfield(lien, "file://")) // scheme+// || (strncmp(lien, "//", 2) == 0) // // sans scheme (-> default) ) { if (ident_url_absolute(lien, adrfil) == -1) { ok = -1; // erreur URL } } else if (strfield(lien, "ftp://")) { // Note: ftp:foobar.gif is not valid if (ftp_available()) { // ftp supporté if (ident_url_absolute(lien, adrfil) == -1) { ok = -1; // erreur URL } } else { ok = -2; // non supporté } #if HTS_USEOPENSSL } else if (strfield(lien, "https://")) { // Note: ftp:foobar.gif is not valid if (ident_url_absolute(lien, adrfil) == -1) { ok = -1; // erreur URL } #endif } else if ((scheme) && ((!strfield(lien, "http:")) && (!strfield(lien, "https:")) && (!strfield(lien, "ftp:")) )) { ok = -1; // unknown scheme } else { // c'est un lien relatif // On forme l'URL complète à partie de l'url actuelle // et du chemin actuel si besoin est. // sanity check if (origin_adr == NULL || origin_fil == NULL || *origin_adr == '\0' || *origin_fil == '\0') { return -1; } // copier adresse if (((int) strlen(origin_adr) < HTS_URLMAXSIZE) && ((int) strlen(origin_fil) < HTS_URLMAXSIZE) && ((int) strlen(lien) < HTS_URLMAXSIZE)) { /* patch scheme if necessary */ if (strfield(lien, "http:")) { lien += 5; strcpybuff(adrfil->adr, jump_protocol_const(origin_adr)); // même adresse ; protocole vide (http) } else if (strfield(lien, "https:")) { lien += 6; strcpybuff(adrfil->adr, "https://"); // même adresse forcée en https strcatbuff(adrfil->adr, jump_protocol_const(origin_adr)); } else if (strfield(lien, "ftp:")) { lien += 4; strcpybuff(adrfil->adr, "ftp://"); // même adresse forcée en ftp strcatbuff(adrfil->adr, jump_protocol_const(origin_adr)); } else { strcpybuff(adrfil->adr, origin_adr); // même adresse ; et même éventuel protocole } if (*lien != '/') { // sinon c'est un lien absolu if (*lien == '\0') { strcpybuff(adrfil->fil, origin_fil); } else if (*lien == '?') { // example: a href="?page=2" char *a; strcpybuff(adrfil->fil, origin_fil); a = strchr(adrfil->fil, '?'); if (a) *a = '\0'; strcatbuff(adrfil->fil, lien); } else { const char *a = strchr(origin_fil, '?'); if (a == NULL) a = origin_fil + strlen(origin_fil); while((*a != '/') && (a > origin_fil)) a--; if (*a == '/') { // ok on a un '/' if ((((int) (a - origin_fil)) + 1 + strlen(lien)) < HTS_URLMAXSIZE) { // copier chemin strncpy(adrfil->fil, origin_fil, ((int) (a - origin_fil)) + 1); *(adrfil->fil + ((int) (a - origin_fil)) + 1) = '\0'; // copier chemin relatif if (((int) strlen(adrfil->fil) + (int) strlen(lien)) < HTS_URLMAXSIZE) { strcatbuff(adrfil->fil, lien + ((*lien == '/') ? 1 : 0)); // simplifier url pour les ../ fil_simplifie(adrfil->fil); } else ok = -1; // erreur } else { // erreur ok = -1; // erreur URL } } else { // erreur ok = -1; // erreur URL } } } else { // chemin absolu // copier chemin directement strcatbuff(adrfil->fil, lien); fil_simplifie(adrfil->fil); } // *lien!='/' } else ok = -1; } // test news: etc. // case insensitive pour adresse { char *a = jump_identification(adrfil->adr); while(*a) { if ((*a >= 'A') && (*a <= 'Z')) *a += 'a' - 'A'; a++; } } // IDNA / RFC 3492 (Punycode) handling for HTTP(s) if (!link_has_authority(adrfil->adr) || strfield(adrfil->adr, "https:")) { char *const a = jump_identification(adrfil->adr); // Non-ASCII characters (theorically forbidden, but browsers are lenient) if (!hts_isStringAscii(a, strlen(a))) { char *const idna = hts_convertStringUTF8ToIDNA(a, strlen(a)); if (idna != NULL) { if (strlen(idna) < HTS_URLMAXSIZE) { strcpybuff(a, idna); } free(idna); } } } return ok; } // créer dans s, à partir du chemin courant curr_fil, le lien vers link (absolu) // un ident_url_relatif a déja été fait avant, pour que link ne soit pas un chemin relatif int lienrelatif(char *s, const char *link, const char *curr_fil) { char BIGSTK _curr[HTS_URLMAXSIZE * 2]; char BIGSTK newcurr_fil[HTS_URLMAXSIZE * 2], newlink[HTS_URLMAXSIZE * 2]; char *curr; //int n=0; char *a; int slash = 0; // newcurr_fil[0] = '\0'; newlink[0] = '\0'; // // patch: éliminer les ? (paramètres) sinon bug { const char *a; if ((a = strchr(curr_fil, '?'))) { strncatbuff(newcurr_fil, curr_fil, (int) (a - curr_fil)); curr_fil = newcurr_fil; } if ((a = strchr(link, '?'))) { strncatbuff(newlink, link, (int) (a - link)); link = newlink; } } // recopier uniquement le chemin courant curr = _curr; strcpybuff(curr, curr_fil); if ((a = strchr(curr, '?')) == NULL) // couper au ? (params) a = curr + strlen(curr) - 1; // pas de params: aller à la fin while((*a != '/') && (a > curr)) a--; // chercher dernier / du chemin courant if (*a == '/') *(a + 1) = '\0'; // couper dernier / // "effacer" s s[0] = '\0'; // sauter ce qui est commun aux 2 chemins { const char *l; if (*link == '/') link++; // sauter slash if (*curr == '/') curr++; l = link; //c=curr; // couper ce qui est commun while((streql(*link, *curr)) && (*link != 0)) { link++; curr++; } // mais on veut un répertoirer entier! // si on a /toto/.. et /toto2/.. on ne veut pas sauter /toto ! while(((*link != '/') || (*curr != '/')) && (link > l)) { link--; curr--; } //if (*link=='/') link++; //if (*curr=='/') curr++; } // calculer la profondeur du répertoire courant et remonter // LES ../ ONT ETE SIMPLIFIES a = curr; if (*a == '/') a++; while(*a) if (*(a++) == '/') strcatbuff(s, "../"); //if (strlen(s)==0) strcatbuff(s,"/"); if (slash) strcatbuff(s, "/"); // garder absolu!! // on est dans le répertoire de départ, copier strcatbuff(s, link + ((*link == '/') ? 1 : 0)); /* Security check */ if (strlen(s) >= HTS_URLMAXSIZE) return -1; // on a maintenant une chaine de la forme ../../test/truc.html return 0; } /* Is the link absolute (http://www..) or relative (/bar/foo.html) ? */ int link_has_authority(const char *lien) { const char *a = lien; if (isalpha((unsigned char) *a)) { // Skip scheme? while(isalpha((unsigned char) *a)) a++; if (*a == ':') a++; else return 0; } if (strncmp(a, "//", 2) == 0) return 1; return 0; } int link_has_authorization(const char *lien) { const char *adr = jump_protocol_const(lien); const char *firstslash = strchr(adr, '/'); const char *detect = strchr(adr, '@'); if (firstslash) { if (detect) { return (detect < firstslash); } } else { return (detect != NULL); } return 0; } // conversion chemin de fichier/dossier vers 8-3 ou ISO9660 void long_to_83(int mode, char *n83, char *save) { n83[0] = '\0'; while(*save) { char fn83[256], fnl[256]; size_t i, j; fn83[0] = fnl[0] = '\0'; for(i = j = 0 ; save[i] && save[i] != '/' ; i++) { if (j + 1 < sizeof(fnl)) { fnl[j++] = save[i]; } } fnl[j] = '\0'; // conversion longfile_to_83(mode, fn83, fnl); strcatbuff(n83, fn83); save += i; if (*save == '/') { strcatbuff(n83, "/"); save++; } } } // conversion nom de fichier/dossier isolé vers 8-3 ou ISO9660 void longfile_to_83(int mode, char *n83, char *save) { int j = 0, max = 0; int i = 0; char nom[256]; char ext[256]; nom[0] = ext[0] = '\0'; switch (mode) { case 1: max = 8; break; case 2: max = 31; break; default: max = 8; break; } /* No starting . */ if (save[0] == '.') { save[0] = '_'; } /* No multiple dots */ { char *last_dot = strrchr(save, '.'); char *dot; while((dot = strchr(save, '.'))) { *dot = '_'; } if (last_dot) { *last_dot = '.'; } } /* Avoid: (ISO9660, but also suitable for 8-3) (Thanks to jonat@cellcast.com for te hint) /:;?\#*~ 0x00-0x1f and 0x80-0xff */ for(i = 0, j = 0; save[i] != 0; i++) { char a = save[i]; if (a >= 'a' && a <= 'z') { a -= 'a' - 'A'; } else if (! ((a >= 'A' && a <= 'Z') || (a >= '0' && a <= '9') || a == '_' || a == '.')) { if (j != 0 && save[j - 1] == '_') { continue; // avoid __ } a = '_'; } save[j++] = a; } save[j] = '\0'; i = j = 0; while((i < max) && (save[j]) && (save[j] != '.')) { if (save[j] != ' ') { nom[i] = save[j]; i++; } j++; } // recopier nom nom[i] = '\0'; if (save[j]) { // il reste au moins un point i = (int) strlen(save) - 1; while((i > 0) && (save[i] != '.') && (save[i] != '/')) i--; // rechercher dernier . if (save[i] == '.') { // point! int j = 0; i++; while((j < 3) && (save[i])) { if (save[i] != ' ') { ext[j] = save[i]; j++; } i++; } ext[j] = '\0'; } } // corriger vers 8-3 n83[0] = '\0'; strncatbuff(n83, nom, max); if (strnotempty(ext)) { strcatbuff(n83, "."); strncatbuff(n83, ext, 3); } } // écrire backblue.gif /* Note: utf-8 */ int verif_backblue(httrackp * opt, const char *base) { int ret = 0; // if (!base) { // init opt->state.verif_backblue_done = 0; return 0; } if ((!opt->state.verif_backblue_done) || (fsize_utf8(fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), base, "backblue.gif")) != HTS_DATA_BACK_GIF_LEN)) { FILE *fp = filecreate(&opt->state.strc, fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), base, "backblue.gif")); opt->state.verif_backblue_done = 1; if (fp) { if (fwrite(HTS_DATA_BACK_GIF, HTS_DATA_BACK_GIF_LEN, 1, fp) != HTS_DATA_BACK_GIF_LEN) ret = 1; fclose(fp); usercommand(opt, 0, NULL, fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), base, "backblue.gif"), "", ""); } else ret = 1; // fp = filecreate(&opt->state.strc, fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), base, "fade.gif")); if (fp) { if (fwrite(HTS_DATA_FADE_GIF, HTS_DATA_FADE_GIF_LEN, 1, fp) != HTS_DATA_FADE_GIF_LEN) ret = 1; fclose(fp); usercommand(opt, 0, NULL, fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), base, "fade.gif"), "", ""); } else ret = 1; } return ret; } // flag int verif_external(httrackp * opt, int nb, int test) { const int flag = 1 << nb; int *const status = &opt->state.verif_external_status; if (!test) *status &= ~flag; // reset else if ((*status & flag) == 0) { *status |= flag; return 1; } return 0; } // recherche chaîne de type truc= // renvoi décalage à effectuer ou 0 si non trouvé /* SECTION OPTIMISEE: #define rech_tageq(adr,s) ( \ ( (*(adr-1)=='<') || (is_space(*(adr-1))) ) ? \ ( (streql(*adr,*s)) ? \ (__rech_tageq(adr,s)) \ : 0 \ ) \ : 0\ ) */ /* HTS_INLINE int rech_tageq(const char* adr,const char* s) { if ( (*(adr-1)=='<') || (is_space(*(adr-1))) ) { // ') { break; } else { /* note: bogus for bogus foo = bar */ if (token == NULL) { if (strncasecmp(&adr[p], s, s_len) == 0 && (is_realspace(adr[p + s_len]) || adr[p + s_len] == '=') ) { for(p += s_len; is_realspace(adr[p]) || adr[p] == '='; p++) ; return p; } token = &adr[p]; } } } else if (adr[p] == quot) { quot = 0; } } return 0; } HTS_INLINE int rech_endtoken(const char *adr, const char **start) { char quote = '\0'; int length = 0; while(is_space(*adr)) adr++; if (*adr == '"' || *adr == '\'') quote = *adr++; *start = adr; while(*adr != 0 && *adr != quote && (quote != '\0' || !is_space(*adr))) { length++; adr++; } return length; } // same, but check beginning of adr with s (for ) HTS_INLINE int __rech_tageqbegdigits(const char *adr, const char *s) { int p; p = strfield(adr, s); if (p) { while(isdigit((unsigned char) adr[p])) p++; // jump digits while(is_space(adr[p])) p++; if (adr[p] == '=') { return p + 1; } } return 0; } // tag sans = HTS_INLINE int rech_sampletag(const char *adr, const char *s) { int p; if ((*(adr - 1) == '<') || (is_space(*(adr - 1)))) { // 0) { if (is_hypertext_mime(opt, type, "")) { if (maxhtml > 0) { if (size > maxhtml) ok = 0; } } else { if (maxnhtml > 0) { if (size > maxnhtml) ok = 0; } } } return (!ok); } static int sortTopIndexFnc(const void *a_, const void *b_) { int cmp; const topindex_chain *const*const a = (const topindex_chain *const*) a_; const topindex_chain *const*const b = (const topindex_chain *const*) b_; /* Category first, then name */ if ((cmp = (*a)->level - (*b)->level) == 0) { if ((cmp = strcmpnocase((*a)->category, (*b)->category)) == 0) { cmp = strcmpnocase((*a)->name, (*b)->name); } } return cmp; } typedef struct hts_template_format_buf { FILE *fp; char *buffer; size_t size; size_t offset; } hts_template_format_buf; // note: upstream arg list MUST be NULL-terminated for safety // returns a negative value upon error static int hts_template_formatv(hts_template_format_buf *buf, const char *format, va_list args) { #undef FPUTC #undef FPUTS #define FPUTC(C) do { \ if (buf->fp != NULL) { \ assertf(buf->buffer == NULL); \ if (fputc(C, buf->fp) < 0) { \ return -1; \ } \ } else { \ assertf(buf->buffer != NULL); \ if (buf->offset + 1 < buf->size) { \ buf->buffer[buf->offset++] = (C); \ } else { \ return -1; \ } \ } \ } while(0) #define FPUTS(S) do { \ size_t i; \ const char *const str_ = (S); \ assertf(str_ != NULL); \ for(i = 0 ; str_[i] != '\0' ; i++) { \ FPUTC(str_[i]); \ } \ } while(0) if (buf != NULL && format != NULL) { const char *arg_expanded[32]; size_t i, nbArgs, posArgs; /* Expand internal code args. */ const char *str; for(nbArgs = 0 ; ( str = va_arg(args, const char*) ) != NULL ; nbArgs++) { assertf(nbArgs < sizeof(arg_expanded)/sizeof(arg_expanded[0])); arg_expanded[nbArgs] = str; } /* Expand user-injected format string. */ for(posArgs = 0, i = 0 ; format[i] != '\0' ; i++) { const unsigned char c = format[i]; if (c == '%') { const unsigned char cFormat = format[++i]; switch(cFormat) { case '%': FPUTC('%'); break; case 's': if (posArgs < nbArgs) { assertf(arg_expanded[posArgs] != NULL); FPUTS(arg_expanded[posArgs]); posArgs++; } else { FPUTS("???"); /* error (args overflow) */ } break; default: /* ignored */ FPUTC('%'); FPUTC(cFormat); break; } } else { FPUTC(c); } } /* Terminating NULL. */ if (buf->buffer != NULL) { buf->buffer[buf->offset] = 0; } return 1; } else { return -1; } #undef FPUTC #undef FPUTS } // note: upstream arg list MUST be NULL-terminated for safety // returns a negative value upon error int hts_template_format(FILE *const out, const char *format, ...) { int success; hts_template_format_buf buf = { NULL, NULL, 0, 0 }; va_list args; buf.fp = out; va_start(args, format); success = hts_template_formatv(&buf, format, args); va_end(args); return success; } // note: upstream arg list MUST be NULL-terminated for safety // returns a negative value upon error int hts_template_format_str(char *buffer, size_t size, const char *format, ...) { int success; hts_template_format_buf buf = { NULL, NULL, 0, 0 }; va_list args; buf.buffer = buffer; buf.size = size; va_start(args, format); success = hts_template_formatv(&buf, format, args); va_end(args); return success; } /* Note: NOT utf-8 */ HTSEXT_API int hts_buildtopindex(httrackp * opt, const char *path, const char *binpath) { FILE *fpo; int retval = 0; char BIGSTK rpath[1024 * 2]; char *toptemplate_header = NULL, *toptemplate_body = NULL, *toptemplate_footer = NULL, *toptemplate_bodycat = NULL; char catbuff[CATBUFF_SIZE]; // et templates html toptemplate_header = readfile_or(fconcat(catbuff, sizeof(catbuff), binpath, "templates/topindex-header.html"), HTS_INDEX_HEADER); toptemplate_body = readfile_or(fconcat(catbuff, sizeof(catbuff), binpath, "templates/topindex-body.html"), HTS_INDEX_BODY); toptemplate_bodycat = readfile_or(fconcat(catbuff, sizeof(catbuff), binpath, "templates/topindex-bodycat.html"), HTS_INDEX_BODYCAT); toptemplate_footer = readfile_or(fconcat(catbuff, sizeof(catbuff), binpath, "templates/topindex-footer.html"), HTS_INDEX_FOOTER); if (toptemplate_header && toptemplate_body && toptemplate_footer && toptemplate_bodycat) { strcpybuff(rpath, path); if (rpath[0]) { if (rpath[strlen(rpath) - 1] == '/') rpath[strlen(rpath) - 1] = '\0'; } fpo = fopen(fconcat(catbuff, sizeof(catbuff), rpath, "/index.html"), "wb"); if (fpo) { find_handle h; verif_backblue(opt, concat(catbuff, sizeof(catbuff), rpath, "/")); // générer gif // Header hts_template_format(fpo, toptemplate_header, "", /* EOF */ NULL); /* Find valid project names */ h = hts_findfirst(rpath); if (h) { struct topindex_chain *chain = NULL; struct topindex_chain *startchain = NULL; String iname = STRING_EMPTY; int chainSize = 0; do { if (hts_findisdir(h)) { StringCopy(iname, rpath); StringCat(iname, "/"); StringCat(iname, hts_findgetname(h)); StringCat(iname, "/index.html"); if (fexist(StringBuff(iname))) { int level = 0; char *category = NULL; struct topindex_chain *oldchain = chain; /* Check for an existing category */ StringCopy(iname, rpath); StringCat(iname, "/"); StringCat(iname, hts_findgetname(h)); StringCat(iname, "/hts-cache/winprofile.ini"); if (fexist(StringBuff(iname))) { category = hts_getcategory(StringBuff(iname)); if (category != NULL) { if (*category == '\0') { freet(category); category = NULL; } } } if (category == NULL) { category = strdupt("No categories"); level = 1; } chain = calloc(sizeof(struct topindex_chain), 1); chainSize++; if (!startchain) { startchain = chain; } if (chain) { if (oldchain) { oldchain->next = chain; } chain->next = NULL; strcpybuff(chain->name, hts_findgetname(h)); chain->category = category; chain->level = level; } } } } while(hts_findnext(h)); hts_findclose(h); StringFree(iname); /* Sort chain */ { struct topindex_chain **sortedElts = (struct topindex_chain **) calloct(sizeof(topindex_chain *), chainSize); assertf(sortedElts != NULL); if (sortedElts != NULL) { int i; const char *category = ""; /* Build array */ struct topindex_chain *chain = startchain; for(i = 0; i < chainSize; i++) { assertf(chain != NULL); sortedElts[i] = chain; chain = chain->next; } qsort(sortedElts, chainSize, sizeof(topindex_chain *), sortTopIndexFnc); /* Build sorted index */ for(i = 0; i < chainSize; i++) { char BIGSTK hname[HTS_URLMAXSIZE * 2]; escape_uri_utf(sortedElts[i]->name, hname, sizeof(hname)); /* Changed category */ if (strcmp(category, sortedElts[i]->category) != 0) { category = sortedElts[i]->category; hts_template_format(fpo, toptemplate_bodycat, category, /* EOF */ NULL); } hts_template_format(fpo, toptemplate_body, hname, sortedElts[i]->name, /* EOF */ NULL); } /* Wipe elements */ for(i = 0; i < chainSize; i++) { freet(sortedElts[i]->category); freet(sortedElts[i]); sortedElts[i] = NULL; } freet(sortedElts); /* Return value */ retval = 1; } } } // Footer hts_template_format(fpo, toptemplate_footer, "", /* EOF */ NULL); fclose(fpo); } } if (toptemplate_header) freet(toptemplate_header); if (toptemplate_body) freet(toptemplate_body); if (toptemplate_footer) freet(toptemplate_footer); if (toptemplate_body) freet(toptemplate_body); return retval; } /* Note: NOT utf-8 */ HTSEXT_API char *hts_getcategory(const char *filename) { String categ = STRING_EMPTY; if (fexist(filename)) { FILE *fp = fopen(filename, "rb"); if (fp != NULL) { int done = 0; while(!feof(fp) && !done) { char BIGSTK line[1024]; int n = linput(fp, line, sizeof(line) - 2); if (n > 0) { if (strfield(line, "category=")) { unescapehttp(line + 9, &categ); done = 1; } } } fclose(fp); } } return StringBuffRW(categ); } /* Note: NOT utf-8 */ HTSEXT_API char *hts_getcategories(char *path, int type) { String categ = STRING_EMPTY; String profiles = STRING_EMPTY; char *rpath = path; find_handle h; coucal hashCateg = NULL; if (rpath[0]) { if (rpath[strlen(rpath) - 1] == '/') { rpath[strlen(rpath) - 1] = '\0'; /* note: patching stored (inhash) value */ } } h = hts_findfirst(rpath); if (h) { String iname = STRING_EMPTY; if (type == 1) { hashCateg = coucal_new(0); coucal_set_name(hashCateg, "hashCateg"); StringCat(categ, "Test category 1"); StringCat(categ, "\r\nTest category 2"); } do { if (hts_findisdir(h)) { char BIGSTK line2[1024]; StringCopy(iname, rpath); StringCat(iname, "/"); StringCat(iname, hts_findgetname(h)); StringCat(iname, "/hts-cache/winprofile.ini"); if (fexist(StringBuff(iname))) { if (type == 1) { FILE *fp = fopen(StringBuff(iname), "rb"); if (fp != NULL) { int done = 0; while(!feof(fp) && !done) { int n = linput(fp, line2, sizeof(line2) - 2); if (n > 0) { if (strfield(line2, "category=")) { if (*(line2 + 9)) { if (!coucal_read(hashCateg, line2 + 9, NULL)) { coucal_write(hashCateg, line2 + 9, 0); if (StringLength(categ) > 0) { StringCat(categ, "\r\n"); } unescapehttp(line2 + 9, &categ); } } done = 1; } } } line2[0] = '\0'; fclose(fp); } } else { if (StringLength(profiles) > 0) { StringCat(profiles, "\r\n"); } StringCat(profiles, hts_findgetname(h)); } } } } while(hts_findnext(h)); hts_findclose(h); StringFree(iname); } if (hashCateg) { coucal_delete(&hashCateg); hashCateg = NULL; } if (type == 1) return StringBuffRW(categ); else return StringBuffRW(profiles); } // Portable directory find functions /* // Example: find_handle h = hts_findfirst("/tmp"); if (h) { do { if (hts_findisfile(h)) printf("File: %s (%d octets)\n",hts_findgetname(h),hts_findgetsize(h)); else if (hts_findisdir(h)) printf("Dir: %s\n",hts_findgetname(h)); } while(hts_findnext(h)); hts_findclose(h); } */ HTSEXT_API find_handle hts_findfirst(char *path) { if (path) { if (strnotempty(path)) { find_handle_struct *find = (find_handle_struct *) calloc(1, sizeof(find_handle_struct)); if (find) { memset(find, 0, sizeof(find_handle_struct)); #ifdef _WIN32 { char BIGSTK rpath[1024 * 2]; strcpybuff(rpath, path); if (rpath[0]) { if (rpath[strlen(rpath) - 1] != '\\') strcatbuff(rpath, "\\"); } strcatbuff(rpath, "*.*"); find->handle = FindFirstFileA(rpath, &find->hdata); if (find->handle != INVALID_HANDLE_VALUE) return find; } #else strcpybuff(find->path, path); { if (find->path[0]) { if (find->path[strlen(find->path) - 1] != '/') strcatbuff(find->path, "/"); } } find->hdir = opendir(path); if (find->hdir != NULL) { if (hts_findnext(find) == 1) return find; } #endif free((void *) find); } } } return NULL; } HTSEXT_API int hts_findnext(find_handle find) { if (find) { #ifdef _WIN32 if ((FindNextFileA(find->handle, &find->hdata))) return 1; #else char catbuff[CATBUFF_SIZE]; memset(&(find->filestat), 0, sizeof(find->filestat)); if ((find->dirp = readdir(find->hdir))) if (find->dirp->d_name) if (!STAT (concat(catbuff, sizeof(catbuff), find->path, find->dirp->d_name), &find->filestat)) return 1; #endif } return 0; } HTSEXT_API int hts_findclose(find_handle find) { if (find) { #ifdef _WIN32 if (find->handle) { FindClose(find->handle); find->handle = NULL; } #else if (find->hdir) { closedir(find->hdir); find->hdir = NULL; } #endif free((void *) find); } return 0; } HTSEXT_API char *hts_findgetname(find_handle find) { if (find) { #ifdef _WIN32 return find->hdata.cFileName; #else if (find->dirp) return find->dirp->d_name; #endif } return NULL; } HTSEXT_API int hts_findgetsize(find_handle find) { if (find) { #ifdef _WIN32 return find->hdata.nFileSizeLow; #else return find->filestat.st_size; #endif } return -1; } HTSEXT_API int hts_findisdir(find_handle find) { if (find) { if (!hts_findissystem(find)) { #ifdef _WIN32 if (find->hdata.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) return 1; #else if (S_ISDIR(find->filestat.st_mode)) return 1; #endif } } return 0; } HTSEXT_API int hts_findisfile(find_handle find) { if (find) { if (!hts_findissystem(find)) { #ifdef _WIN32 if (!(find->hdata.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)) return 1; #else if (S_ISREG(find->filestat.st_mode)) return 1; #endif } } return 0; } HTSEXT_API int hts_findissystem(find_handle find) { if (find) { #ifdef _WIN32 if (find->hdata. dwFileAttributes & (FILE_ATTRIBUTE_SYSTEM | FILE_ATTRIBUTE_HIDDEN | FILE_ATTRIBUTE_TEMPORARY)) return 1; else if ((!strcmp(find->hdata.cFileName, "..")) || (!strcmp(find->hdata.cFileName, "."))) return 1; #else if ((S_ISCHR(find->filestat.st_mode)) || (S_ISBLK(find->filestat.st_mode)) || (S_ISFIFO(find->filestat.st_mode)) || (S_ISSOCK(find->filestat.st_mode)) ) return 1; else if ((!strcmp(find->dirp->d_name, "..")) || (!strcmp(find->dirp->d_name, "."))) return 1; #endif } return 0; } httrack-3.49.5/src/htsrobots.c0000644000175000017500000000703614336470674013203 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: httrack.c subroutines: */ /* robots.txt (website robot file) */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* Internal engine bytecode */ #define HTS_INTERNAL_BYTECODE /* specific definitions */ #include "htscore.h" #include "htsbase.h" #include "htslib.h" /* END specific definitions */ #include "htsrobots.h" // -- robots -- // fil="" : vérifier si règle déja enregistrée int checkrobots(robots_wizard * robots, const char *adr, const char *fil) { while(robots) { if (strfield2(robots->adr, adr)) { if (fil[0]) { int ptr = 0; char line[250]; if (strnotempty(robots->token)) { do { ptr += binput(robots->token + ptr, line, 200); if (line[0] == '/') { // absolu if (strfield(fil, line)) { // commence avec ligne return -1; // interdit } } else { // relatif if (strstrcase(fil, line)) { return -1; } } } while((strnotempty(line)) && (ptr < (int) strlen(robots->token))); } } else { return -1; } } robots = robots->next; } return 0; } int checkrobots_set(robots_wizard * robots, const char *adr, const char *data) { if (((int) strlen(adr)) >= sizeof(robots->adr) - 2) return 0; if (((int) strlen(data)) >= sizeof(robots->token) - 2) return 0; while(robots) { if (strfield2(robots->adr, adr)) { // entrée existe strcpybuff(robots->token, data); #if DEBUG_ROBOTS printf("robots.txt: set %s to %s\n", adr, data); #endif return -1; } else if (!robots->next) { robots->next = (robots_wizard *) calloct(1, sizeof(robots_wizard)); if (robots->next) { robots->next->next = NULL; strcpybuff(robots->next->adr, adr); strcpybuff(robots->next->token, data); #if DEBUG_ROBOTS printf("robots.txt: new set %s to %s\n", adr, data); #endif } #if DEBUG_ROBOTS else printf("malloc error!!\n"); #endif } robots = robots->next; } return 0; } void checkrobots_free(robots_wizard * robots) { if (robots->next) { checkrobots_free(robots->next); freet(robots->next); robots->next = NULL; } } // -- robots -- httrack-3.49.5/src/htsname.c0000644000175000017500000016565514357323623012621 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: httrack.c subroutines: */ /* savename routine (compute output filename) */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* Internal engine bytecode */ #define HTS_INTERNAL_BYTECODE #include "htscore.h" #include "htsname.h" #include "md5.h" #include "htsmd5.h" #include "htstools.h" #include "htscharset.h" #include "htsencoding.h" #include #define ADD_STANDARD_PATH \ { /* ajout nom */\ char BIGSTK buff[HTS_URLMAXSIZE*2];\ buff[0]='\0';\ strncatbuff(buff,start_pos,nom_pos - start_pos);\ url_savename_addstr(afs->save, buff);\ } #define ADD_STANDARD_NAME(shortname) \ { /* ajout nom */\ char BIGSTK buff[HTS_URLMAXSIZE*2];\ standard_name(buff,dot_pos,nom_pos,fil_complete,(shortname));\ url_savename_addstr(afs->save, buff);\ } /* Avoid stupid DOS system folders/file such as 'nul' */ /* Based on linux/fs/umsdos/mangle.c */ static const char *hts_tbdev[] = { "/prn", "/con", "/aux", "/nul", "/lpt1", "/lpt2", "/lpt3", "/lpt4", "/com1", "/com2", "/com3", "/com4", "/clock$", "/emmxxxx0", "/xmsxxxx0", "/setverxx", "" }; #define URLSAVENAME_WAIT_FOR_AVAILABLE_SOCKET() do { \ int prev = opt->state._hts_in_html_parsing; \ while(back_pluggable_sockets_strict(sback, opt) <= 0) { \ opt->state. _hts_in_html_parsing = 6; \ /* Wait .. */ \ back_wait(sback,opt,cache,0); \ /* Transfer rate */ \ engine_stats(); \ /* Refresh various stats */ \ HTS_STAT.stat_nsocket=back_nsoc(sback); \ HTS_STAT.stat_errors=fspc(opt,NULL,"error"); \ HTS_STAT.stat_warnings=fspc(opt,NULL,"warning"); \ HTS_STAT.stat_infos=fspc(opt,NULL,"info"); \ HTS_STAT.nbk=backlinks_done(sback,opt->liens,opt->lien_tot,ptr); \ HTS_STAT.nb=back_transferred(HTS_STAT.stat_bytes,sback); \ /* Check */ \ { \ if (!RUN_CALLBACK7(opt, loop, sback->lnk, sback->count,-1,ptr,opt->lien_tot,(int) (time_local()-HTS_STAT.stat_timestart),&HTS_STAT)) { \ return -1; \ } \ } \ } \ opt->state._hts_in_html_parsing = prev; \ } while(0) /* Strip all // */ static void cleanDoubleSlash(char *s) { int i, j; for(i = 0, j = 0; s[i] != '\0'; i++) { if (s[i] == '/' && i != 0 && s[i - 1] == '/') { continue; } if (i != j) { s[j] = s[i]; } j++; } // terminating \0 if (i != j) { s[j] = s[i]; } } /* Strip all ending . or ' ' (windows-forbidden) */ static void cleanEndingSpaceOrDot(char *s) { int i, j, lastWriteEnd; for(i = 0, j = 0, lastWriteEnd = 0; i == 0 || s[i - 1] != '\0'; i++) { if (s[i] == '/' || s[i] == '\0') { // Last write was not good, revert if (j != lastWriteEnd) { j = lastWriteEnd; } } if (i != j) { s[j] = s[i]; } j++; // Commit good candidate for terminating character if (s[i] != ' ' && s[i] != '.') { lastWriteEnd = j; } } } // forme le nom du fichier à sauver (save) à partir de fil et adr // système intelligent, qui renomme en cas de besoin (exemple: deux INDEX.HTML et index.html) int url_savename(lien_adrfilsave *const afs, lien_adrfil *const former, const char *referer_adr, const char *referer_fil, httrackp * opt, struct_back * sback, cache_back * cache, hash_struct * hash, int ptr, int numero_passe, const lien_back * headers) { char catbuff[CATBUFF_SIZE]; const int is_redirect = headers != NULL && HTTP_IS_REDIRECT(headers->r.statuscode); const char *mime_type = headers != NULL && !is_redirect ? headers->r.contenttype : NULL; /*const char* mime_type = ( headers && HTTP_IS_OK(headers->r.statuscode) ) ? headers->r.contenttype : NULL; */ lien_back *const back = sback->lnk; /* */ char BIGSTK fil[HTS_URLMAXSIZE * 2]; /* ="" */ const char *const adr_complete = afs->af.adr; const char *const fil_complete = afs->af.fil; /*char BIGSTK normadr_[HTS_URLMAXSIZE*2]; */ char BIGSTK normadr_[HTS_URLMAXSIZE * 2], normfil_[HTS_URLMAXSIZE * 2]; enum { PROTOCOL_HTTP, PROTOCOL_HTTPS, PROTOCOL_FTP, PROTOCOL_FILE, PROTOCOL_UNKNOWN }; static const char *protocol_str[] = { "http", "https", "ftp", "file", "unknown" }; int protocol = PROTOCOL_HTTP; const char *const adr = jump_identification_const(adr_complete); // copy of fil, used for lookups (see urlhack) const char *normadr = adr; const char *normfil = fil_complete; const char *const print_adr = jump_protocol_const(adr); const char *start_pos = NULL, *nom_pos = NULL, *dot_pos = NULL; // Position nom et point // pour changement d'extension ou de nom (content-disposition) int ext_chg = 0, ext_chg_delayed = 0; int is_html = 0; char ext[256]; int max_char = 0; //CLEAR fil[0] = ext[0] = '\0'; afs->save[0] = '\0'; /* 8-3 ? */ switch (opt->savename_83) { case 1: // 8-3 max_char = 8; break; case 2: // Level 2 File names may be up to 31 characters. max_char = 31; break; default: max_char = 8; break; } // normalize the URL: // www.foo.com -> foo.com // www-42.foo.com -> foo.com // foo.com/bar//foobar -> foo.com/bar/foobar if (opt->urlhack) { // copy of adr (without protocol), used for lookups (see urlhack) normadr = adr_normalized(adr, normadr_); normfil = fil_normalized(fil_complete, normfil_); } else { if (link_has_authority(adr_complete)) { // https or other protocols : in "http/" subfolder char *pos = strchr(adr_complete, ':'); if (pos != NULL) { normadr_[0] = '\0'; strncatbuff(normadr_, adr_complete, (int) (pos - adr_complete)); strcatbuff(normadr_, "://"); strcatbuff(normadr_, normadr); normadr = normadr_; } } } // à afficher sans ftp:// if (strfield(adr_complete, "https:")) { protocol = PROTOCOL_HTTPS; } else if (strfield(adr_complete, "ftp:")) { protocol = PROTOCOL_FTP; } else if (strfield(adr_complete, "file:")) { protocol = PROTOCOL_FILE; } else { protocol = PROTOCOL_HTTP; } // court-circuit pour lien primaire if (strnotempty(adr) == 0) { if (strcmp(fil_complete, "primary") == 0) { strcatbuff(afs->save, "primary.html"); return 0; } } /* Declare adr (IDNA-decoded if necessary) */ #define DECLARE_ADR(FINAL_ADR) \ char *idna_adr =\ /* http or https */\ (\ protocol == PROTOCOL_HTTP\ || protocol == PROTOCOL_HTTPS \ )\ /* and contains IDNA */\ && hts_isStringIDNA(adr_complete, strlen(print_adr))\ ? hts_convertStringIDNAToUTF8(print_adr, strlen(print_adr))\ : NULL;\ const char *const FINAL_ADR = idna_adr != NULL \ ? idna_adr : ( protocol == PROTOCOL_FILE ? "file" : print_adr ) /* Release adr */ #define RELEASE_ADR() do {\ if (idna_adr != NULL) {\ free(idna_adr);\ idna_adr = NULL;\ }\ } while(0) // vérifier que le nom n'a pas déja été calculé (si oui le renvoyer tel que) // vérifier que le nom n'est pas déja pris... // NOTE: si on cherche /toto/ et que /toto est trouvé on le prend (et réciproquqment) ** // ** if (opt->liens != NULL) { int i; i = hash_read(hash, normadr, normfil, HASH_STRUCT_ADR_PATH); // recherche table 1 (adr+fil) if (i >= 0) { // ok, trouvé strcpybuff(afs->save, heap(i)->sav); return 0; } i = hash_read(hash, normadr, normfil, HASH_STRUCT_ORIGINAL_ADR_PATH); // recherche table 2 (former->adr+former->fil) if (i >= 0) { // ok, trouvé // copier location moved! strcpybuff(afs->af.adr, heap(i)->adr); strcpybuff(afs->af.fil, heap(i)->fil); // et save strcpybuff(afs->save, heap(i)->sav); // copier (formé à partir du nouveau lien!) return 0; } // chercher sans / ou avec / dans former { char BIGSTK fil_complete_patche[HTS_URLMAXSIZE * 2]; strcpybuff(fil_complete_patche, normfil); // Version avec ou sans / if (fil_complete_patche[strlen(fil_complete_patche) - 1] == '/') fil_complete_patche[strlen(fil_complete_patche) - 1] = '\0'; else strcatbuff(fil_complete_patche, "/"); i = hash_read(hash, normadr, fil_complete_patche, HASH_STRUCT_ORIGINAL_ADR_PATH); // recherche table 2 (former->adr+former->fil) if (i >= 0) { // écraser fil et adr (pas former->fil?????) strcpybuff(afs->af.adr, heap(i)->adr); strcpybuff(afs->af.fil, heap(i)->fil); // écrire save strcpybuff(afs->save, heap(i)->sav); return 0; } } } // vérifier la non présence de paramètres dans le nom de fichier // si il y en a, les supprimer (ex: truc.cgi?subj=aspirateur) // néanmoins, gardé pour vérifier la non duplication (voir après) { char *a; a = strchr(fil_complete, '?'); if (a != NULL) { strncatbuff(fil, fil_complete, a - fil_complete); } else { strcpybuff(fil, fil_complete); } } // decode remaining % (normally not necessary; already done in htsparse.c) // this will NOT decode buggy %xx (ie. not UTF-8) ones if (hts_unescapeUrl(fil, catbuff, sizeof(catbuff)) == 0) { strcpybuff(fil, catbuff); } else { hts_log_print(opt, LOG_WARNING, "could not URL-decode string '%s'", fil); } /* replace shtml to html.. */ if (opt->savename_delayed == 2) is_html = -1; /* ALWAYS delay type */ else is_html = ishtml(opt, fil); switch (is_html) { /* .html,.shtml,.. */ case 1: if ((strfield2(get_ext(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), fil), "html") == 0) && (strfield2(get_ext(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), fil), "htm") == 0) ) { strcpybuff(ext, "html"); ext_chg = 1; } break; case 0: if (!strnotempty(ext)) { if (is_userknowntype(opt, fil)) { // mime known by user char BIGSTK mime[1024]; mime[0] = ext[0] = '\0'; get_userhttptype(opt, mime, fil); if (strnotempty(mime)) { give_mimext(ext, mime); if (strnotempty(ext)) { ext_chg = 1; } } } } break; } // si option check_type activée if (is_html < 0 && opt->check_type && !ext_chg) { int ishtest = 0; if (protocol != PROTOCOL_FILE && protocol != PROTOCOL_FTP ) { // tester type avec requète HEAD si on ne connait pas le type du fichier if (!((opt->check_type == 1) && (fil[strlen(fil) - 1] == '/'))) // slash doit être html? if (opt->savename_delayed == 2 || (ishtest = ishtml(opt, fil)) < 0) { // on ne sait pas si c'est un html ou un fichier.. // lire dans le cache htsblk r = cache_read_including_broken(opt, cache, adr, fil); // test uniquement if (r.statuscode != -1) { // pas d'erreur de lecture cache char s[32]; s[0] = '\0'; hts_log_print(opt, LOG_DEBUG, "Testing link type (from cache) %s%s", adr_complete, fil_complete); if (!HTTP_IS_REDIRECT(r.statuscode)) { if (strnotempty(r.cdispo)) { /* filename given */ ext_chg = 2; /* change filename */ strcpybuff(ext, r.cdispo); } else if (!may_unknown2(opt, r.contenttype, fil)) { // on peut patcher à priori? give_mimext(s, r.contenttype); // obtenir extension if (strnotempty(s) > 0) { // on a reconnu l'extension ext_chg = 1; strcpybuff(ext, s); } } } #ifdef DEFAULT_BIN_EXT // no extension and potentially bogus else if (ishtest == -2) { ext_chg = 1; strcpybuff(ext, DEFAULT_BIN_EXT + 1); } #endif // } else if (opt->savename_delayed != 2 && is_userknowntype(opt, fil)) { /* PATCH BY BRIAN SCHRÖDER. Lookup mimetype not only by extension, but also by filename */ /* Note: "foo.cgi => text/html" means that foo.cgi shall have the text/html MIME file type, that is, ".html" */ char BIGSTK mime[1024]; mime[0] = ext[0] = '\0'; get_userhttptype(opt, mime, fil); if (strnotempty(mime)) { give_mimext(ext, mime); if (strnotempty(ext)) { ext_chg = 1; } } } // note: if savename_delayed is enabled, the naming will be temporary (and slightly invalid!) // note: if we are about to stop (opt->state.stop), back_add() will fail later else if (opt->savename_delayed != 0 && !opt->state.stop) { // Check if the file is ready in backing. We basically take the same logic as later. // FIXME: we should cleanup and factorize this unholy mess if (headers != NULL && headers->status >= 0 && !is_redirect) { if (strnotempty(headers->r.cdispo)) { /* filename given */ ext_chg = 2; /* change filename */ strcpybuff(ext, headers->r.cdispo); } else if (!may_unknown2(opt, headers->r.contenttype, headers->url_fil)) { // on peut patcher à priori? (pas interdit ou pas de type) char s[16]; s[0] = '\0'; give_mimext(s, headers->r.contenttype); // obtenir extension if (strnotempty(s) > 0) { // on a reconnu l'extension ext_chg = 1; strcpybuff(ext, s); } } } else if (mime_type != NULL) { ext[0] = '\0'; if (*mime_type) { give_mimext(ext, mime_type); } if (strnotempty(ext)) { char mime_from_file[128]; mime_from_file[0] = 0; get_httptype(opt, mime_from_file, fil, 1); if (!strnotempty(mime_from_file) || strcasecmp(mime_type, mime_from_file) != 0) { /* different mime for this type */ /* type change not forbidden (or no extension at all) */ if (!may_unknown2(opt, mime_type, fil)) { ext_chg = 1; } #ifdef DEFAULT_BIN_EXT // no extension and potentially bogus else if (ishtml(opt, fil) == -2) { ext_chg = 1; strcpybuff(ext, DEFAULT_BIN_EXT + 1); } #endif } else { ext_chg = 0; } } } else { /* Avoid collisions (no collisionning detection) */ sprintf(ext, "%x.%s", opt->state.delayedId++, DELAYED_EXT); ext_chg = 1; ext_chg_delayed = 1; /* due to naming system */ } } // test imposible dans le cache, faire une requête else { // int hihp = opt->state._hts_in_html_parsing; int has_been_moved = 0; lien_adrfil current; /* Ensure we don't use too many sockets by using a "testing" one If we have only 1 simultaneous connection authorized, wait for pending download Wait for an available slot */ URLSAVENAME_WAIT_FOR_AVAILABLE_SOCKET(); /* Rock'in */ current.adr[0] = current.fil[0] = '\0'; opt->state._hts_in_html_parsing = 2; // test hts_log_print(opt, LOG_DEBUG, "Testing link type %s%s", adr_complete, fil_complete); strcpybuff(current.adr, adr_complete); strcpybuff(current.fil, fil_complete); // ajouter dans le backing le fichier en mode test // savename: rien car en mode test if (back_add (sback, opt, cache, current.adr, current.fil, BACK_ADD_TEST, referer_adr, referer_fil, 1) != -1) { int b; b = back_index(opt, sback, current.adr, current.fil, BACK_ADD_TEST); if (b >= 0) { int stop_looping = 0; int petits_tours = 0; int get_test_request = 0; // en cas de bouclage sur soi même avec HEAD, tester avec GET.. parfois c'est la cause des problèmes do { // temps à attendre, et remplir autant que l'on peut le cache (backing) if (back[b].status > 0) { back_wait(sback, opt, cache, 0); } if (ptr >= 0) { back_fillmax(sback, opt, cache, ptr, numero_passe); } // on est obligé d'appeler le shell pour le refresh.. // Transfer rate engine_stats(); // Refresh various stats HTS_STAT.stat_nsocket = back_nsoc(sback); HTS_STAT.stat_errors = fspc(opt, NULL, "error"); HTS_STAT.stat_warnings = fspc(opt, NULL, "warning"); HTS_STAT.stat_infos = fspc(opt, NULL, "info"); HTS_STAT.nbk = backlinks_done(sback, opt->liens, opt->lien_tot, ptr); HTS_STAT.nb = back_transferred(HTS_STAT.stat_bytes, sback); if (!RUN_CALLBACK7 (opt, loop, sback->lnk, sback->count, b, ptr, opt->lien_tot, (int) (time_local() - HTS_STAT.stat_timestart), &HTS_STAT)) { return -1; } else if (opt->state._hts_cancel || !back_checkmirror(opt)) { // cancel 2 ou 1 (cancel parsing) back_delete(opt, cache, sback, b); // cancel test stop_looping = 1; } // traitement des 304,303.. if (back[b].status <= 0) { if (HTTP_IS_REDIRECT(back[b].r.statuscode)) { // agh moved.. un tit tour de plus if ((petits_tours < 5) && former != NULL) { // on va pas tourner en rond non plus! if (strnotempty(back[b].r.location)) { // location existe! char BIGSTK mov_url[HTS_URLMAXSIZE * 2]; lien_adrfil moved; mov_url[0] = moved.adr[0] = moved.fil[0] = '\0'; // strcpybuff(mov_url, back[b].r.location); // copier URL if (ident_url_relatif (mov_url, current.adr, current.fil, &moved) >= 0) { // si non bouclage sur soi même, ou si test avec GET non testé if ((strcmp(moved.adr, current.adr)) || (strcmp(moved.fil, current.fil)) || (get_test_request == 0)) { // bouclage? if ((!strcmp(moved.adr, current.adr)) && (!strcmp(moved.fil, current.fil))) get_test_request = 1; // faire requète avec GET // recopier former->adr/fil? if (former != NULL) { if (strnotempty(former->adr) == 0) { // Pas déja noté strcpybuff(former->adr, current.adr); strcpybuff(former->fil, current.fil); } } // check explicit forbidden - don't follow 3xx in this case { int set_prio_to = 0; if (hts_acceptlink(opt, ptr, moved.adr, moved.fil, NULL, NULL, &set_prio_to, NULL) == 1) { /* forbidden */ has_been_moved = 1; back_maydelete(opt, cache, sback, b); // ok strcpybuff(current.adr, moved.adr); strcpybuff(current.fil, moved.fil); mov_url[0] = '\0'; stop_looping = 1; } } // ftp: stop! if (strfield(mov_url, "ftp://") ) { // ftp, ok on arrête has_been_moved = 1; back_maydelete(opt, cache, sback, b); // ok strcpybuff(current.adr, moved.adr); strcpybuff(current.fil, moved.fil); stop_looping = 1; } else if (*mov_url) { const char *methode; if (!get_test_request) methode = BACK_ADD_TEST; // tester avec HEAD else { methode = BACK_ADD_TEST2; // tester avec GET hts_log_print(opt, LOG_WARNING, "Loop with HEAD request (during prefetch) at %s%s", current.adr, current.fil); } // Ajouter URLSAVENAME_WAIT_FOR_AVAILABLE_SOCKET(); if (back_add(sback, opt, cache, moved.adr, moved.fil, methode, referer_adr, referer_fil, 1) != -1) { // OK hts_log_print(opt, LOG_DEBUG, "(during prefetch) %s (%d) to link %s at %s%s", back[b].r.msg, back[b].r.statuscode, back[b].r.location, current.adr, current.fil); // libérer emplacement backing actuel et attendre le prochain back_maydelete(opt, cache, sback, b); strcpybuff(current.adr, moved.adr); strcpybuff(current.fil, moved.fil); b = back_index(opt, sback, current.adr, current.fil, methode); if (!get_test_request) has_been_moved = 1; // sinon ne pas forcer has_been_moved car non déplacé petits_tours++; // } else { // sinon on fait rien et on s'en va.. (ftp etc) hts_log_print(opt, LOG_DEBUG, "Warning: Savename redirect backing error at %s%s", moved.adr, moved.fil); } } } else { hts_log_print(opt, LOG_WARNING, "Unable to test %s%s (loop to same filename)", adr_complete, fil_complete); } } } } else { // arrêter les frais hts_log_print(opt, LOG_WARNING, "Unable to test %s%s (loop)", adr_complete, fil_complete); } } // ok, leaving } } while(!stop_looping && back[b].status > 0 && back[b].status < 1000); // Si non déplacé, forcer type? if (!has_been_moved) { if (back[b].r.statuscode != -10) { // erreur if (strnotempty(back[b].r.contenttype) == 0) strcpybuff(back[b].r.contenttype, "text/html"); // message d'erreur en html // Finalement on, renvoie un erreur, pour ne toucher à rien dans le code // libérer emplacement backing } { // pas d'erreur, changer type? char s[16]; s[0] = '\0'; if (strnotempty(back[b].r.cdispo)) { /* filename given */ ext_chg = 2; /* change filename */ strcpybuff(ext, back[b].r.cdispo); } else if (!may_unknown2(opt, back[b].r.contenttype, back[b].url_fil)) { // on peut patcher à priori? (pas interdit ou pas de type) give_mimext(s, back[b].r.contenttype); // obtenir extension if (strnotempty(s) > 0) { // on a reconnu l'extension ext_chg = 1; strcpybuff(ext, s); } } #ifdef DEFAULT_BIN_EXT // no extension and potentially bogus else if (ishtest == -2) { ext_chg = 1; strcpybuff(ext, DEFAULT_BIN_EXT + 1); } #endif } } // FIN Si non déplacé, forcer type? // libérer emplacement backing back_maydelete(opt, cache, sback, b); // --- --- --- // oops, a été déplacé.. on recalcule en récursif (osons!) if (has_been_moved) { // copier adr, fil (optionnel, mais sinon marche pas pour le rip) strcpybuff(afs->af.adr, current.adr); strcpybuff(afs->af.fil, current.fil); // copier adr, fil return url_savename(afs, NULL, referer_adr, referer_fil, opt, sback, cache, hash, ptr, numero_passe, NULL); } // --- --- --- } } else { printf ("PANIC! : Savename Crash adding error, unexpected error found.. [%d]\n", __LINE__); #if BDEBUG==1 printf("error while savename crash adding\n"); #endif hts_log_print(opt, LOG_ERROR, "Unexpected savename backing error at %s%s", adr, fil_complete); } // restaurer opt->state._hts_in_html_parsing = hihp; } // caché? } } } // - - - DEBUT NOMMAGE - - - // Donner nom par défaut? if (fil[strlen(fil) - 1] == '/') { if (!strfield(adr_complete, "ftp://") ) { strcatbuff(fil, DEFAULT_HTML); // nommer page par défaut!! } else { if (!opt->proxy.active) strcatbuff(fil, DEFAULT_FTP); // nommer page par défaut (texte) else strcatbuff(fil, DEFAULT_HTML); // nommer page par défaut (à priori ici html depuis un proxy http) } } // Changer extension? // par exemple, php3 sera sauvé en html, cgi en html ou gif, xbm etc.. selon les cas if (ext_chg && !opt->no_type_change) { // changer ext char *a = fil + strlen(fil) - 1; if ((opt->debug > 1) && (opt->log != NULL)) { if (ext_chg == 1) hts_log_print(opt, LOG_DEBUG, "Changing link extension %s%s to .%s", adr_complete, fil_complete, ext); else hts_log_print(opt, LOG_DEBUG, "Changing link name %s%s to %s", adr_complete, fil_complete, ext); } if (ext_chg == 1) { while((a > fil) && (*a != '.') && (*a != '/')) a--; if (*a == '.') *a = '\0'; // couper strcatbuff(fil, "."); // recopier point } else { while((a > fil) && (*a != '/')) a--; if (*a == '/') a++; *a = '\0'; } strcatbuff(fil, ext); // copier ext/nom } // Rechercher premier / et dernier . { const char *a = fil + strlen(fil) - 1; // passer structures start_pos = fil; while((a > fil) && (*a != '/') && (*a != '\\')) { if (*a == '.') // point? noter position if (!dot_pos) dot_pos = a; a--; } if ((*a == '/') || (*a == '\\')) a++; nom_pos = a; } // un nom de fichier est généré // s'il existe déja, alors on le mofifie légèrement // ajouter nom du site éventuellement en premier if (opt->savename_type == -1) { // utiliser savename_userdef! (%h%p/%n%q.%t) const char *a = StringBuff(opt->savename_userdef); char *b = afs->save; /*char *nom_pos=NULL,*dot_pos=NULL; // Position nom et point */ char tok; /* { // Rechercher premier / char* a=fil+strlen(fil)-1; // passer structures while(((int) a>(int) fil) && (*a != '/') && (*a != '\\')) { if (*a == '.') // point? noter position if (!dot_pos) dot_pos=a; a--; } if ((*a=='/') || (*a=='\\')) a++; nom_pos = a; } */ // Construire nom while((*a) && (((int) (b - afs->save)) < HTS_URLMAXSIZE)) { // parser, et pas trop long.. if (*a == '%') { int short_ver = 0; a++; if (*a == 's') { short_ver = 1; a++; } *b = '\0'; switch (tok = *a++) { case '[': // %[param:prefix_if_not_empty:suffix_if_not_empty:empty_replacement:notfound_replacement] if (strchr(a, ']')) { int pos = 0; char name[5][256]; char *c = name[0]; for(pos = 0; pos < 5; pos++) { name[pos][0] = '\0'; } pos = 0; while(*a != '\0' && *a != ']') { if (pos < 5) { if (*a == ':') { // next token c = name[++pos]; a++; } else { *c++ = *a++; *c = '\0'; } } } if (*a == ']') { a++; } strcatbuff(name[0], "="); /* param=.. */ c = strchr(fil_complete, '?'); /* parameters exists */ if (c) { char *cp; while((cp = strstr(c + 1, name[0])) && *(cp - 1) != '?' && *(cp - 1) != '&') { /* finds [?&]param= */ c = cp; } if (cp) { c = cp + strlen(name[0]); /* jumps "param=" */ strcpybuff(b, name[1]); /* prefix */ b += strlen(b); if (*c != '\0' && *c != '&') { char *d = name[0]; /* */ while(*c != '\0' && *c != '&') { *d++ = *c++; } *d = '\0'; d = unescape_http(catbuff, sizeof(catbuff), name[0]); if (d && *d) { strcpybuff(b, d); /* value */ b += strlen(b); } else { strcpybuff(b, name[3]); /* empty replacement if any */ b += strlen(b); } } else { strcpybuff(b, name[3]); /* empty replacement if any */ b += strlen(b); } strcpybuff(b, name[2]); /* suffix */ b += strlen(b); } else { strcpybuff(b, name[4]); /* not found replacement if any */ b += strlen(b); } } else { strcpybuff(b, name[4]); /* not found replacement if any */ b += strlen(b); } } break; case '%': *b++ = '%'; break; case 'n': // nom sans ext *b = '\0'; if (dot_pos) { if (!short_ver) // Noms longs strncatbuff(b, nom_pos, (int) (dot_pos - nom_pos)); else strncatbuff(b, nom_pos, min((int) (dot_pos - nom_pos), 8)); } else { if (!short_ver) // Noms longs strcpybuff(b, nom_pos); else strncatbuff(b, nom_pos, 8); } b += strlen(b); // pointer à la fin break; case 'N': // nom avec ext // RECOPIE NOM + EXT *b = '\0'; if (dot_pos) { if (!short_ver) // Noms longs strncatbuff(b, nom_pos, (int) (dot_pos - nom_pos)); else strncatbuff(b, nom_pos, min((int) (dot_pos - nom_pos), 8)); } else { if (!short_ver) // Noms longs strcpybuff(b, nom_pos); else strncatbuff(b, nom_pos, 8); } b += strlen(b); // pointer à la fin *b = '.'; ++b; // RECOPIE NOM + EXT *b = '\0'; if (dot_pos) { if (!short_ver) // Noms longs strcpybuff(b, dot_pos + 1); else strncatbuff(b, dot_pos + 1, 3); } else { if (!short_ver) // Noms longs strcpybuff(b, DEFAULT_EXT + 1); // pas de.. else strcpybuff(b, DEFAULT_EXT_SHORT + 1); // pas de.. } b += strlen(b); // pointer à la fin // break; case 't': // ext *b = '\0'; if (dot_pos) { if (!short_ver) // Noms longs strcpybuff(b, dot_pos + 1); else strncatbuff(b, dot_pos + 1, 3); } else { if (!short_ver) // Noms longs strcpybuff(b, DEFAULT_EXT + 1); // pas de.. else strcpybuff(b, DEFAULT_EXT_SHORT + 1); // pas de.. } b += strlen(b); // pointer à la fin break; case 'p': // path sans dernier / *b = '\0'; if (nom_pos != fil + 1) { // pas: /index.html (chemin nul) if (!short_ver) { // Noms longs strncatbuff(b, fil, (int) (nom_pos - fil) - 1); } else { char BIGSTK pth[HTS_URLMAXSIZE * 2], n83[HTS_URLMAXSIZE * 2]; pth[0] = n83[0] = '\0'; // strncatbuff(pth, fil, (int) (nom_pos - fil) - 1); long_to_83(opt->savename_83, n83, pth); strcpybuff(b, n83); } } b += strlen(b); // pointer à la fin break; case 'h': // host (IDNA decoded if suitable) // IDNA / RFC 3492 (Punycode) handling for HTTP(s) { DECLARE_ADR(final_adr); /* Copy address */ *b = '\0'; if (!short_ver) strcpybuff(b, final_adr); else strcpybuff(b, final_adr); /* release */ RELEASE_ADR(); } b += strlen(b); // pointer à la fin break; case 'H': // host, raw (old mode) *b = '\0'; if (protocol == PROTOCOL_FILE) { if (!short_ver) // Noms longs strcpybuff(b, "localhost"); else strcpybuff(b, "local"); } else { if (!short_ver) // Noms longs strcpybuff(b, print_adr); else strncatbuff(b, print_adr, 8); } b += strlen(b); // pointer à la fin break; case 'M': /* host/address?query MD5 (128-bits) */ *b = '\0'; { char digest[32 + 2]; char BIGSTK buff[HTS_URLMAXSIZE * 2]; digest[0] = buff[0] = '\0'; strcpybuff(buff, adr); strcatbuff(buff, fil_complete); domd5mem(buff, strlen(buff), digest, 1); strcpybuff(b, digest); } b += strlen(b); // pointer à la fin break; case 'Q': case 'q': /* query MD5 (128-bits/16-bits) GENERATED ONLY IF query string exists! */ { char md5[32 + 2]; *b = '\0'; strncatbuff(b, url_md5(md5, fil_complete), (tok == 'Q') ? 32 : 4); b += strlen(b); // pointer à la fin } break; case 'r': case 'R': // protocol *b = '\0'; strcatbuff(b, protocol_str[protocol]); b += strlen(b); // pointer à la fin break; /* Patch by Juan Fco Rodriguez to get the full query string */ case 'k': { char *d = strchr(fil_complete, '?'); if (d != NULL) { strcatbuff(b, d); b += strlen(b); } } break; } } else *b++ = *a++; } *b++ = '\0'; // // Types prédéfinis // } // // Structure originale else if (opt->savename_type % 100 == 0) { /* recopier www.. */ if (opt->savename_type != 100) { if (((opt->savename_type / 1000) % 2) == 0) { // >1000 signifie "pas de www/" DECLARE_ADR(final_adr); // adresse url if (!opt->savename_83) { // noms longs (et pas de .) strcatbuff(afs->save, final_adr); } else { // noms 8-3 if (strlen(final_adr) > 4) { if (strfield(final_adr, "www.")) hts_appendStringUTF8(afs->save, final_adr + 4, max_char); else hts_appendStringUTF8(afs->save, final_adr, max_char); } else hts_appendStringUTF8(afs->save, final_adr, max_char); } /* release */ RELEASE_ADR(); if (*fil != '/') strcatbuff(afs->save, "/"); } } hts_lowcase(afs->save); /* // ne sert à rien car a déja été filtré normalement if ((*fil=='.') && (*(fil+1)=='/')) // ./index.html ** // url_savename_addstr(save,fil+2); else // index.html ou /index.html url_savename_addstr(save,fil); if (save[strlen(save)-1]=='/') strcatbuff(save,DEFAULT_HTML); // nommer page par défaut!! */ /* add name */ ADD_STANDARD_PATH; ADD_STANDARD_NAME(0); } // // Structure html/image else { // dossier "web" ou "www.xxx" ? if (((opt->savename_type / 1000) % 2) == 0) { // >1000 signifie "pas de www/" if ((opt->savename_type / 100) % 2) { DECLARE_ADR(final_adr); if (!opt->savename_83) { // noms longs strcatbuff(afs->save, final_adr); strcatbuff(afs->save, "/"); } else { // noms 8-3 if (strlen(final_adr) > 4) { if (strfield(final_adr, "www.")) hts_appendStringUTF8(afs->save, final_adr + 4, max_char); else hts_appendStringUTF8(afs->save, final_adr, max_char); strcatbuff(afs->save, "/"); } else { hts_appendStringUTF8(afs->save, final_adr, max_char); strcatbuff(afs->save, "/"); } } /* release */ RELEASE_ADR(); } else { strcatbuff(afs->save, "web/"); // répertoire général } } // si un html à coup sûr if ((ext_chg != 0) ? (ishtml_ext(ext) == 1) : (ishtml(opt, fil) == 1)) { if (opt->savename_type % 100 == 2) { // html/ strcatbuff(afs->save, "html/"); } } else { if ((opt->savename_type % 100 == 1) || (opt->savename_type % 100 == 2)) { // html & images strcatbuff(afs->save, "images/"); } } switch (opt->savename_type % 100) { case 4: case 5:{ // séparer par types const char *a = fil + strlen(fil) - 1; // passer structures while((a > fil) && (*a != '/') && (*a != '\\')) a--; if ((*a == '/') || (*a == '\\')) a++; // html? if ((ext_chg != 0) ? (ishtml_ext(ext) == 1) : (ishtml(opt, fil) == 1)) { if (opt->savename_type % 100 == 5) strcatbuff(afs->save, "html/"); } else { const char *a = fil + strlen(fil) - 1; while((a > fil) && (*a != '/') && (*a != '.')) a--; if (*a != '.') strcatbuff(afs->save, "other"); else strcatbuff(afs->save, a + 1); strcatbuff(afs->save, "/"); } /*strcatbuff(save,a); */ /* add name */ ADD_STANDARD_NAME(0); } break; case 99:{ // 'codé' .. c'est un gadget size_t i; size_t j; const char *a; char C[] = "ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789_-"; int L; // pseudo-CRC sur fil et adr pour initialiser générateur aléatoire.. unsigned int s = 0; L = (int) strlen(C); for(i = 0; fil_complete[i] != '\0'; i++) { s += (unsigned int) fil_complete[i]; } for(i = 0; adr_complete[i] != '\0'; i++) { s += (unsigned int) adr_complete[i]; } srand(s); j = strlen(afs->save); for(i = 0; i < 8; i++) { char c = C[(rand() % L)]; afs->save[i + j] = c; } afs->save[i + j] = '\0'; // ajouter extension a = fil + strlen(fil) - 1; while((a > fil) && (*a != '/') && (*a != '.')) a--; if (*a == '.') { strcatbuff(afs->save, a); // ajouter } } break; default:{ // noms sans les noms des répertoires // ne garder que le nom, pas la structure /* char* a=fil+strlen(fil)-1; while(((int) a>(int) fil) && (*a != '/') && (*a != '\\')) a--; if ((*a=='/') || (*a=='\\')) a++; strcatbuff(save,a); */ /* add name */ ADD_STANDARD_NAME(0); } break; } hts_lowcase(afs->save); if (afs->save[strlen(afs->save) - 1] == '/') strcatbuff(afs->save, DEFAULT_HTML); // nommer page par défaut!! } // vérifier qu'on ne doit pas forcer l'extension // par exemple, asp sera sauvé en html, cgi en html ou gif, xbm etc.. selon les cas /*if (ext_chg) { char* a=save+strlen(save)-1; while(((int) a>(int) save) && (*a!='.') && (*a!='/')) a--; if (*a=='.') *a='\0'; // couper // recopier extension strcatbuff(save,"."); strcatbuff(save,ext); // copier ext } */ // Not used anymore unless non-delayed types. // de même en cas de manque d'extension on en place une de manière forcée.. // cela évite les /chez/toto et les /chez/toto/index.html incompatibles if (opt->savename_type != -1 && opt->savename_delayed != 2) { char *a = afs->save + strlen(afs->save) - 1; while((a > afs->save) && (*a != '.') && (*a != '/')) a--; if (*a != '.') { // agh pas de point //strcatbuff(save,".none"); // a éviter strcatbuff(afs->save, ".html"); // préférable! hts_log_print(opt, LOG_DEBUG, "Default HTML type set for %s%s => %s", adr_complete, fil_complete, afs->save); } } // effacer pass au besoin pour les autentifications // (plus la peine : masqué au début) /* { char* a = jump_identification(afs->save); if (a!=afs->save) { char BIGSTK tempo[HTS_URLMAXSIZE*2]; char *b; tempo[0]='\0'; strcpybuff(tempo,"["); b=strchr(save,':'); if (!b) b=strchr(save,'@'); if (b) strncatbuff(tempo,save,(int) b-(int) a); strcatbuff(tempo,"]"); strcatbuff(tempo,a); strcpybuff(save,a); } } */ // éviter les / au début (cause: N100) if (afs->save[0] == '/') { char BIGSTK tempo[HTS_URLMAXSIZE * 2]; strcpybuff(tempo, afs->save + 1); strcpybuff(afs->save, tempo); } /* Cleanup reserved or forbidden characters. */ { size_t i; for(i = 0 ; afs->save[i] != '\0' ; i++) { unsigned char c = (unsigned char) afs->save[i]; if (c < 32 // control || c == 127 // unwise || c == '~' // unix unwise || c == '\\' // windows separator || c == ':' // windows forbidden || c == '*' // windows forbidden || c == '?' // windows forbidden || c == '\"' // windows forbidden || c == '<' // windows forbidden || c == '>' // windows forbidden || c == '|' // windows forbidden //|| c == '@' // ? || ( opt->savename_83 == 2 // CDROM && ( c == '-' || c == '=' || c == '+' ) ) ) { afs->save[i] = '_'; } } } // éliminer les // (comme ftp://) cleanDoubleSlash(afs->save); #if HTS_OVERRIDE_DOS_FOLDERS /* Replace /foo/nul/bar by /foo/nul_/bar */ { int i = 0; while(hts_tbdev[i][0]) { const char *a = afs->save; while((a = strstrcase(a, hts_tbdev[i]))) { switch ((int) a[strlen(hts_tbdev[i])]) { case '\0': case '/': case '.': { char BIGSTK tempo[HTS_URLMAXSIZE * 2]; tempo[0] = '\0'; strncatbuff(tempo, afs->save, (int) (a - afs->save) + strlen(hts_tbdev[i])); strcatbuff(tempo, "_"); strcatbuff(tempo, a + strlen(hts_tbdev[i])); strcpybuff(afs->save, tempo); } break; } a += strlen(hts_tbdev[i]); } i++; } } /* Strip ending . or ' ' forbidden on windoz */ cleanEndingSpaceOrDot(afs->save); #endif // conversion 8-3 .. y compris pour les répertoires if (opt->savename_83) { char BIGSTK n83[HTS_URLMAXSIZE * 2]; long_to_83(opt->savename_83, n83, afs->save); strcpybuff(afs->save, n83); } // enforce stricter ISO9660 compliance (bug reported by Steffo Carlsson) // Level 1 File names are restricted to 8 characters with a 3 character extension, // upper case letters, numbers and underscore; maximum depth of directories is 8. // This will be our "DOS mode" // L2: 31 characters // A-Z,0-9,_ if (opt->savename_83 > 0) { char *a, *last; for(last = afs->save + strlen(afs->save) - 1; last != afs->save && *last != '/' && *last != '\\' && *last != '.'; last--) ; if (*last != '.') { last = NULL; } for(a = afs->save; *a != '\0'; a++) { if (*a >= 'a' && *a <= 'z') { *a -= 'a' - 'A'; } else if (*a == '.') { if (a != last) { *a = '_'; } } else if (! ((*a >= 'A' && *a <= 'Z') || (*a >= '0' && *a <= '9') || *a == '_' || *a == '/' || *a == '\\')) { *a = '_'; } } } /* ensure that there is no ../ (potential vulnerability) */ fil_simplifie(afs->save); /* convert name to UTF-8 ? Note: already done while parsing. */ //if (charset != NULL && charset[0] != '\0') { // char *const s = hts_convertStringToUTF8(save, (int) strlen(save), charset); // if (s != NULL) { // hts_log_print(opt, LOG_DEBUG, // "engine: save-name: charset conversion from '%s' to '%s' using charset '%s'", // save, s, charset); // strcpybuff(save, s); // free(s); // } //} /* callback */ RUN_CALLBACK5(opt, savename, adr_complete, fil_complete, referer_adr, referer_fil, afs->save); hts_log_print(opt, LOG_DEBUG, "engine: save-name: local name: %s%s -> %s", adr, fil, afs->save); /* Ensure that the MANDATORY "temporary" extension is set */ if (ext_chg_delayed) { char *ptr; char *lastDot = NULL; for(ptr = afs->save; *ptr != 0; ptr++) { if (*ptr == '.') { lastDot = ptr; } else if (*ptr == '/' || *ptr == '\\') { lastDot = NULL; } } if (lastDot == NULL) { strcatbuff(afs->save, "." DELAYED_EXT); } else if (!IS_DELAYED_EXT(afs->save)) { strcatbuff(lastDot, "." DELAYED_EXT); } } // enforce 260-character path limit before inserting destination path // note: 12 characters at least for WIN32, and 12 for ".99.delayed" // (MSDN) "When using an API to create a directory, the specified path // cannot be so long that you cannot append an 8.3 file name // (that is, the directory name cannot exceed MAX_PATH minus 12)." #define HTS_MAX_PATH_LEN ( 260 - 12 - 12 ) #define MIN_LAST_SEG_RESERVE 12 #define MAX_LAST_SEG_RESERVE 24 #define MAX_SEG_LEN 48 if (hts_stringLengthUTF8(afs->save) + hts_stringLengthUTF8(StringBuff(opt->path_html_utf8)) >= HTS_MAX_PATH_LEN) { // convert to Unicode (much simpler) size_t wsaveLen; hts_UCS4 *const wsave = hts_convertUTF8StringToUCS4(afs->save, strlen(afs->save), &wsaveLen); if (wsave != NULL) { const size_t parentLen = hts_stringLengthUTF8(StringBuff(opt->path_html_utf8)); // parent path length is not insane (otherwise, ignore and pick 200 as // suffix length) const size_t maxLen = parentLen < HTS_MAX_PATH_LEN - HTS_MAX_PATH_LEN / 4 ? HTS_MAX_PATH_LEN - parentLen : HTS_MAX_PATH_LEN; size_t i, j, lastSeg, lastSegSize, dirSize; char *saveFinal; // pick up last segment for(i = 0, lastSeg = 0; wsave[i] != '\0'; i++) { if (wsave[i] == '/') { lastSeg = i + 1; } } lastSegSize = wsaveLen - lastSeg; if (lastSegSize > MAX_LAST_SEG_RESERVE) { lastSegSize = MAX_LAST_SEG_RESERVE; } else if (lastSegSize < MIN_LAST_SEG_RESERVE) { lastSegSize = MIN_LAST_SEG_RESERVE; } // add as much pathes as we can. // note: i is in bytes, iUtf in characters for(i = 0, j = 0, dirSize = 0 ; i + 1 < lastSeg && j + lastSegSize < maxLen; i++) { // reset segment counting if (wsave[i] == '/') { dirSize = 0; } // copy if not too long if (dirSize < MAX_SEG_LEN) { wsave[j++] = wsave[i]; dirSize++; } } // last segment wsave[j++] = '/'; #define MAX_UTF8_SEQ_CHARS 4 for(i = lastSeg; wsave[i] != '\0' && j < maxLen; i++) { wsave[j++] = wsave[i]; } // terminating \0 wsave[j++] = '\0'; // copy final name and cleanup saveFinal = hts_convertUCS4StringToUTF8(wsave, j); if (saveFinal != NULL) { strcpybuff(afs->save, saveFinal); free(saveFinal); } else { hts_log_print(opt, LOG_ERROR, "Could not revert to UTF-8: %s%s", adr_complete, fil_complete); } free(wsave); // log in debug hts_log_print(opt, LOG_DEBUG, "Too long filename shortened: %s%s => %s", adr_complete, fil_complete, afs->save); } else { hts_log_print(opt, LOG_ERROR, "Could not read UTF-8: %s", afs->save); } // Re-check again ending space or dot after cut (see bug #5) cleanEndingSpaceOrDot(afs->save); } #undef MAX_UTF8_SEQ_CHARS #undef MIN_LAST_SEG_RESERVE #undef HTS_MAX_PATH_LEN // chemin primaire éventuel A METTRE AVANT if (strnotempty(StringBuff(opt->path_html_utf8))) { char BIGSTK tempo[HTS_URLMAXSIZE * 2]; strcpybuff(tempo, StringBuff(opt->path_html_utf8)); strcatbuff(tempo, afs->save); strcpybuff(afs->save, tempo); } // vérifier que le nom n'est pas déja pris... if (opt->liens != NULL) { int nom_ok; do { int i; // nom_ok = 1; // à priori bon // on part de la fin pour optimiser, plus les opti de taille pour // aller encore plus vite.. #if DEBUG_SAVENAME printf("\nStart search\n"); #endif i = hash_read(hash, afs->save, NULL, HASH_STRUCT_FILENAME); // lecture type 0 (sav) if (i >= 0) { int sameAdr = (strfield2(heap(i)->adr, normadr) != 0); int sameFil; // NO - URL hack is only for stripping // and www. //if (opt->urlhack != 0) // sameFil = ( strfield2(heap(i)->fil, normfil) != 0); //else sameFil = (strcmp(heap(i)->fil, normfil) == 0); if (sameAdr && sameFil) { // ok c'est le même lien, adresse déja définie /* Take the existing name not to screw up with cAsE sEnSiTiViTy of Linux/Unix */ if (strcmp(heap(i)->sav, afs->save) != 0) { strcpybuff(afs->save, heap(i)->sav); } i = 0; #if DEBUG_SAVENAME printf("\nOK ALREADY DEFINED\n", 13, i); #endif } else { // utilisé par un AUTRE, changer de nom char BIGSTK tempo[HTS_URLMAXSIZE * 2]; char *a = afs->save + strlen(afs->save) - 1; char *b; int n = 2; char collisionSeparator = ((opt->savename_83 != 2) ? '-' : '_'); tempo[0] = '\0'; #if DEBUG_SAVENAME printf("\nWRONG CASE UNMATCH : \n%s\n%s, REDEFINE\n", heap(i)->fil, fil_complete); #endif nom_ok = 0; i = 0; while((a > afs->save) && (*a != '.') && (*a != '\\') && (*a != '/')) a--; if (*a == '.') strncatbuff(tempo, afs->save, a - afs->save); else strcatbuff(tempo, afs->save); // tester la présence d'un -xx (ex: index-2.html -> index-3.html) b = tempo + strlen(tempo) - 1; while(isdigit((unsigned char) *b)) b--; if (*b == collisionSeparator) { sscanf(b + 1, "%d", &n); *b = '\0'; // couper n++; // plus un } // en plus il faut gérer le 8-3 .. pas facile le client if (opt->savename_83) { int max; char *a = tempo + strlen(tempo) - 1; while((a > tempo) && (*a != '/')) a--; if (*a == '/') a++; max = max_char - 1 - nombre_digit(n); if ((int) strlen(a) > max) *(a + max) = '\0'; // couper sinon il n'y aura pas la place! } // ajouter -xx (ex: index.html -> index-2.html) sprintf(tempo + strlen(tempo), "%c%d", collisionSeparator, n); // ajouter extension if (*a == '.') strcatbuff(tempo, a); strcpybuff(afs->save, tempo); //printf("switched: %s\n",save); } // if } #if DEBUG_SAVENAME printf("\nEnd search, %s\n", fil_complete); #endif } while(!nom_ok); } //printf("'%s' %s %s\n",save,adr,fil); return 0; } /* nom avec md5 urilisé partout */ void standard_name(char *b, const char *dot_pos, const char *nom_pos, const char *fil, int short_ver) { char md5[32 + 2]; b[0] = '\0'; /* Nom */ if (dot_pos) { if (!short_ver) // Noms longs strncatbuff(b, nom_pos, (dot_pos - nom_pos)); else strncatbuff(b, nom_pos, min(dot_pos - nom_pos, 8)); } else { if (!short_ver) // Noms longs strcatbuff(b, nom_pos); else strncatbuff(b, nom_pos, 8); } /* MD5 - 16 bits */ strncatbuff(b, url_md5(md5, fil), 4); /* Ext */ if (dot_pos) { strcatbuff(b, "."); if (!short_ver) // Noms longs strcatbuff(b, dot_pos + 1); else strncatbuff(b, dot_pos + 1, 3); } // Allow extensionless #ifdef DO_NOT_ALLOW_EXTENSIONLESS else { if (!short_ver) // Noms longs strcatbuff(b, DEFAULT_EXT); else strcatbuff(b, DEFAULT_EXT_SHORT); } #endif } /* Petit md5 */ char *url_md5(char *digest, const char *fil) { char *a; digest[0] = '\0'; a = strchr(fil, '?'); if (a) { if (strlen(a)) { char BIGSTK buff[HTS_URLMAXSIZE * 2]; a++; digest[0] = buff[0] = '\0'; strcatbuff(buff, a); /* query string MD5 */ domd5mem(buff, strlen(buff), digest, 1); } } return digest; } // interne à url_savename: ajoute une chaîne à une autre avec \ -> / void url_savename_addstr(char *d, const char *s) { int i = (int) strlen(d); while(*s) { if (*s == '\\') // remplacer \ par des / d[i++] = '/'; else d[i++] = *s; s++; } d[i] = '\0'; } /* "filename" should be at least 64 bytes. */ void url_savename_refname(const char *adr, const char *fil, char *filename) { unsigned char bindigest[16]; struct MD5Context ctx; MD5Init(&ctx, 0); MD5Update(&ctx, (const unsigned char *) adr, (int) strlen(adr)); MD5Update(&ctx, (const unsigned char *) ",", 1); MD5Update(&ctx, (const unsigned char *) fil, (int) strlen(fil)); MD5Final(bindigest, &ctx); sprintf(filename, CACHE_REFNAME "/" "%02x%02x%02x%02x%02x%02x%02x%02x" "%02x%02x%02x%02x%02x%02x%02x%02x" ".ref", bindigest[0], bindigest[1], bindigest[2], bindigest[3], bindigest[4], bindigest[5], bindigest[6], bindigest[7], bindigest[8], bindigest[9], bindigest[10], bindigest[11], bindigest[12], bindigest[13], bindigest[14], bindigest[15]); } /* note: return a local filename */ char *url_savename_refname_fullpath(httrackp * opt, const char *adr, const char *fil) { char digest_filename[64]; url_savename_refname(adr, fil, digest_filename); return fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), digest_filename); } /* remove refname if any */ void url_savename_refname_remove(httrackp * opt, const char *adr, const char *fil) { char *filename = url_savename_refname_fullpath(opt, adr, fil); (void) UNLINK(filename); } httrack-3.49.5/src/htscoremain.c0000644000175000017500000036162614360553246013472 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: opt->c subroutines: */ /* main routine (first called) */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* Internal engine bytecode */ #define HTS_INTERNAL_BYTECODE #include "htscoremain.h" #include "htsglobal.h" #include "htscore.h" #include "htsdefines.h" #include "htsalias.h" #include "htswrap.h" #include "htsmodules.h" #include "htszlib.h" #include "htscharset.h" #include "htsencoding.h" #include "htsmd5.h" #include #if USE_BEGINTHREAD #ifdef _WIN32 #include #endif #endif #ifdef _WIN32 #else #ifndef HTS_DO_NOT_USE_UID /* setuid */ #include #ifdef HAVE_UNISTD_H #include #endif #endif #endif /* Resolver */ extern int IPV6_resolver; // Add a command in the argc/argv #define cmdl_add(token,argc,argv,buff,ptr) \ argv[argc]=(buff+ptr); \ strcpybuff(argv[argc],token); \ ptr += (int) (strlen(argv[argc])+2); \ argc++ // Insert a command in the argc/argv #define cmdl_ins(token,argc,argv,buff,ptr) \ { \ int i; \ for(i=argc;i>0;i--)\ argv[i]=argv[i-1];\ } \ argv[0]=(buff+ptr); \ strcpybuff(argv[0],token); \ ptr += (int) (strlen(argv[0])+2); \ argc++ #define htsmain_free() do { \ if (url != NULL) { \ free(url); \ } \ } while(0) #define ensureUrlCapacity(url, urlsize, size) do { \ if (urlsize < size || url == NULL) { \ urlsize = size; \ if (url == NULL) { \ url = (char*) malloct(urlsize); \ if (url != NULL) url[0]='\0'; \ } else { \ url = (char*) realloct(url, urlsize); \ } \ if (url == NULL) { \ HTS_PANIC_PRINTF("* memory exhausted"); \ htsmain_free(); \ return -1; \ } \ } \ } while(0) #ifdef HTS_CRASH_TEST static __attribute__ ((noinline)) void fourty_two(void) { char *const ptr = (char*) (uintptr_t) 0x42; (*ptr)++; } static __attribute__ ((noinline)) void do_really_crash(void) { fourty_two(); } static __attribute__ ((noinline)) void do_crash(void) { do_really_crash(); } #endif HTSEXT_API int hts_main(int argc, char **argv) { httrackp *opt = hts_create_opt(); int ret = hts_main2(argc, argv, opt); hts_free_opt(opt); return ret; } // very minimalistic internal tests static void basic_selftests(void) { // BUG 756328 const char *const source = "/intent/tweet?url=https%3A%2F%2Fwww.httrack.com%2Fvacatures%2F1562519%2Fmedewerker-data-services&text=Medewerker+Data+Services&via=httrackcom"; char buffer[1024]; fil_normalized(source, buffer); // MD5 selftests md5selftest(); } static int hts_main_internal(int argc, char **argv, httrackp * opt); // Main, récupère les paramètres et appelle le robot HTSEXT_API int hts_main2(int argc, char **argv, httrackp * opt) { int code; // Set ended state (3.48-14) hts_mutexlock(&opt->state.lock); opt->state.is_ended = 0; hts_mutexrelease(&opt->state.lock); code = hts_main_internal(argc, argv, opt); // Set ended state (3.48-14) hts_mutexlock(&opt->state.lock); opt->state.is_ended = 1; hts_mutexrelease(&opt->state.lock); return code; } static int hts_main_internal(int argc, char **argv, httrackp * opt) { char **x_argv = NULL; // Patch pour argv et argc: en cas de récupération de ligne de commande char *x_argvblk = NULL; // (reprise ou update) int x_ptr = 0; // offset // int argv_url = -1; // ==0 : utiliser cache et doit.log char *argv_firsturl = NULL; // utilisé pour nommage par défaut char *url = NULL; // URLS séparées par un espace int url_sz = 65535; //char url[65536]; // URLS séparées par un espace // the parametres int httrack_logmode = 3; // ONE log file ensureUrlCapacity(url, url_sz, 65536); // Create options _DEBUG_HEAD = 0; // pas de debuggage en têtes /* command max-size check (3.43 ; 3.42-4) */ { int i; for(i = 0; i < argc; i++) { if (strlen(argv[i]) >= HTS_CDLMAXSIZE) { HTS_PANIC_PRINTF("argument too long"); htsmain_free(); return -1; } } } /* Init root dir */ hts_rootdir(argv[0]); #ifdef _WIN32 #else /* Terminal is a tty, may ask questions and display funny information */ if (isatty(1)) { opt->quiet = 0; opt->verbosedisplay = 1; } /* Not a tty, no stdin input or funny output! */ else { opt->quiet = 1; opt->verbosedisplay = 0; } #endif // Binary program path? #ifndef HTS_HTTRACKDIR { char catbuff[CATBUFF_SIZE]; char *path = fslash(catbuff, sizeof(catbuff), argv[0]); char *a; if ((a = strrchr(path, '/'))) { StringCopyN(opt->path_bin, argv[0], a - path); } } #else StringCopy(opt->path_bin, HTS_HTTRACKDIR); #endif /* filter CR, LF, TAB.. */ { int na; for(na = 1; na < argc; na++) { char *a; while((a = strchr(argv[na], '\x0d'))) *a = ' '; while((a = strchr(argv[na], '\x0a'))) *a = ' '; while((a = strchr(argv[na], 9))) *a = ' '; /* equivalent to "empty parameter" */ if ((strcmp(argv[na], HTS_NOPARAM) == 0) || (strcmp(argv[na], HTS_NOPARAM2) == 0)) // (none) strcpybuff(argv[na], "\"\""); if (strncmp(argv[na], "-&", 2) == 0) argv[na][1] = '%'; } } /* create x_argvblk buffer for transformed command line */ { int current_size = 0; int size; int na; for(na = 0; na < argc; na++) current_size += (int) (strlen(argv[na]) + 1); if ((size = fsize("config")) > 0) current_size += size; x_argvblk = (char *) malloct(current_size + 32768); if (x_argvblk == NULL) { HTS_PANIC_PRINTF("Error, not enough memory"); htsmain_free(); return -1; } x_argvblk[0] = '\0'; x_ptr = 0; /* Create argv */ x_argv = (char **) malloct(sizeof(char *) * (argc + 1024)); } /* Create new argc/argv, replace alias, count URLs, treat -h, -q, -i */ { char BIGSTK _tmp_argv[2][HTS_CDLMAXSIZE]; char BIGSTK tmp_error[HTS_CDLMAXSIZE]; char *tmp_argv[2]; int tmp_argc; int x_argc = 0; int na; tmp_argv[0] = _tmp_argv[0]; tmp_argv[1] = _tmp_argv[1]; // argv_url = 0; /* pour comptage */ // cmdl_add(argv[0], x_argc, x_argv, x_argvblk, x_ptr); na = 1; /* commencer après nom_prg */ while(na < argc) { int result = 1; tmp_argv[0][0] = tmp_argv[1][0] = '\0'; /* Vérifier argv[] non vide */ if (strnotempty(argv[na])) { /* Vérifier Commande (alias) */ result = optalias_check(argc, (const char *const *) argv, na, &tmp_argc, (char **) tmp_argv, tmp_error); if (!result) { HTS_PANIC_PRINTF(tmp_error); htsmain_free(); return -1; } /* Copier */ cmdl_add(tmp_argv[0], x_argc, x_argv, x_argvblk, x_ptr); if (tmp_argc > 1) { cmdl_add(tmp_argv[1], x_argc, x_argv, x_argvblk, x_ptr); } /* Compter URLs et détecter -i,-q.. */ if (tmp_argc == 1) { /* pas -P & co */ if (!cmdl_opt(tmp_argv[0])) { /* pas -c0 & co */ if (argv_url < 0) argv_url = 0; // -1==force -> 1=one url already detected, wipe all previous options //if (argv_url>=0) { argv_url++; if (!argv_firsturl) argv_firsturl = x_argv[x_argc - 1]; //} } else { if (strcmp(tmp_argv[0], "-h") == 0) { help(argv[0], !opt->quiet); htsmain_free(); return 0; } else if (strcmp(tmp_argv[0], "-#h") == 0) { printf("HTTrack version " HTTRACK_VERSION "%s\n", hts_get_version_info(opt)); return 0; } else { if (strncmp(tmp_argv[0], "--", 2)) { /* pas */ if ((strchr(tmp_argv[0], 'q') != NULL)) opt->quiet = 1; // ne pas poser de questions! (nohup par exemple) if ((strchr(tmp_argv[0], 'i') != NULL)) { // doit.log! argv_url = -1; /* forcer */ opt->quiet = 1; } } else if (strcmp(tmp_argv[0] + 2, "quiet") == 0) { opt->quiet = 1; // ne pas poser de questions! (nohup par exemple) } else if (strcmp(tmp_argv[0] + 2, "continue") == 0) { argv_url = -1; /* forcer */ opt->quiet = 1; } } } } else if (tmp_argc == 2) { if ((strcmp(tmp_argv[0], "-%L") == 0)) { // liste d'URLs if (argv_url < 0) argv_url = 0; // -1==force -> 1=one url already detected, wipe all previous options //if (argv_url>=0) argv_url++; /* forcer */ } } } na += result; } if (argv_url < 0) argv_url = 0; /* Nouveaux argc et argv */ argv = x_argv; argc = x_argc; } // Option O and includerc { int loops = 0; while(loops < 2) { char *com; int na; for(na = 1; na < argc; na++) { if (argv[na][0] == '"') { char BIGSTK tempo[HTS_CDLMAXSIZE]; strcpybuff(tempo, argv[na] + 1); if (tempo[strlen(tempo) - 1] != '"') { char BIGSTK s[HTS_CDLMAXSIZE]; sprintf(s, "Missing quote in %s", argv[na]); HTS_PANIC_PRINTF(s); htsmain_free(); return -1; } tempo[strlen(tempo) - 1] = '\0'; strcpybuff(argv[na], tempo); } if (cmdl_opt(argv[na])) { // option com = argv[na] + 1; while(*com) { switch (*com) { case 'O': // output path if ((na + 1 >= argc) || (argv[na + 1][0] == '-')) { HTS_PANIC_PRINTF ("Option O needs to be followed by a blank space, and a path (or path,path)"); printf("Example: -O /binary/\n"); printf("Example: -O /binary/,/log/\n"); htsmain_free(); return -1; } else { int i /*, j */ ; int inQuote; String *path; int noDbl = 0; if (com[1] == '1') { /* only 1 arg */ com++; noDbl = 1; } na++; StringClear(opt->path_html); StringClear(opt->path_log); for(i = 0 /*, j = 0 */ , inQuote = 0, path = &opt->path_html; argv[na][i] != 0; i++) { if (argv[na][i] == '"') { if (inQuote) inQuote = 0; else inQuote = 1; } else if (!inQuote && !noDbl && argv[na][i] == ',') { //StringAddchar(path, '\0'); //j = 0; path = &opt->path_log; } else { StringAddchar(*path, argv[na][i]); //path[j++] = argv[na][i]; } } //path[j++] = '\0'; if (StringLength(opt->path_log) == 0) { StringCopyS(opt->path_log, opt->path_html); } check_path(&opt->path_log, argv_firsturl); if (check_path(&opt->path_html, argv_firsturl)) { opt->dir_topindex = 1; // rebuilt top index } //printf("-->%s\n%s\n",StringBuff(opt->path_html),StringBuff(opt->path_log)); } break; } // switch com++; } // while } // arg } // for // Convert path to UTF-8 #ifdef _WIN32 { char *const path = hts_convertStringSystemToUTF8(StringBuff(opt->path_html), (int) StringLength(opt->path_html)); if (path != NULL) { StringCopy(opt->path_html_utf8, path); free(path); } else { StringCopyN(opt->path_html_utf8, StringBuff(opt->path_html), StringLength(opt->path_html)); } } #else // Assume UTF-8 filesystem. StringCopyN(opt->path_html_utf8, StringBuff(opt->path_html), StringLength(opt->path_html)); #endif /* if doit.log exists, or if new URL(s) defined, then DO NOT load standard config files */ /* (config files are added in doit.log) */ #if DEBUG_STEPS printf("Loading httrackrc/doit.log\n"); #endif /* recreate a doit.log (no old doit.log or new URLs (and parameters)) */ if ((strnotempty(StringBuff(opt->path_log))) || (strnotempty(StringBuff(opt->path_html)))) loops++; // do not loop once again and do not include rc file (O option exists) else { if ((!fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/doit.log"))) || (argv_url > 0)) { if (!optinclude_file (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), HTS_HTTRACKRC), &argc, argv, x_argvblk, &x_ptr)) if (!optinclude_file(HTS_HTTRACKRC, &argc, argv, x_argvblk, &x_ptr)) { if (!optinclude_file (fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), hts_gethome(), "/" HTS_HTTRACKRC), &argc, argv, x_argvblk, &x_ptr)) { #ifdef HTS_HTTRACKCNF optinclude_file(HTS_HTTRACKCNF, &argc, argv, x_argvblk, &x_ptr); #endif } } } else loops++; // do not loop once again } loops++; } // while } // traiter -O /* load doit.log and insert in current command line */ if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/doit.log")) && (argv_url <= 0)) { FILE *fp = fopen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/doit.log"), "rb"); if (fp) { int insert_after = 1; /* insérer après nom au début */ // char BIGSTK buff[8192]; char *p, *lastp; linput(fp, buff, 8000); fclose(fp); fp = NULL; p = buff; do { int insert_after_argc; // read next lastp = p; if (p) { p = next_token(p, 1); if (p) { *p = 0; // null p++; } } /* Insert parameters BUT so that they can be in the same order */ if (lastp) { if (strnotempty(lastp)) { insert_after_argc = argc - insert_after; cmdl_ins(lastp, insert_after_argc, (argv + insert_after), x_argvblk, x_ptr); argc = insert_after_argc + insert_after; insert_after++; } } } while(lastp != NULL); //fclose(fp); } } // Existence d'un cache - pas de new mais un old.. renommer #if DEBUG_STEPS printf("Checking cache\n"); #endif if (!fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.zip"))) { if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.zip"))) { rename(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.zip"), fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.zip")); } } else if ((!fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.dat"))) || (!fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.ndx")))) { if ((fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.dat"))) && (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.ndx")))) { remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.dat")); remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.ndx")); //remove(fconcat(StringBuff(opt->path_log),"hts-cache/new.lst")); rename(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.dat"), fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.dat")); rename(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.ndx"), fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.ndx")); //rename(fconcat(StringBuff(opt->path_log),"hts-cache/old.lst"),fconcat(StringBuff(opt->path_log),"hts-cache/new.lst")); } } /* Interrupted mirror detected */ if (!opt->quiet) { if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-in_progress.lock"))) { /* Old cache */ if ((fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.dat"))) && (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.ndx")))) { if (opt->log != NULL) { fprintf(opt->log, "Warning!\n"); fprintf(opt->log, "An aborted mirror has been detected!\nThe current temporary cache is required for any update operation and only contains data downloaded during the last aborted session.\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\nThis can easily be done here by erasing the hts-cache/new.* files\n"); fprintf(opt->log, "Please restart HTTrack with --continue (-iC1) option to override this message!\n"); } return 0; } } } // remplacer "macros" comme --spider // permet de lancer httrack sans a avoir à se rappeler de syntaxes comme p0C0I0Qc32 .. #if DEBUG_STEPS printf("Checking last macros\n"); #endif { int i; for(i = 0; i < argc; i++) { #if DEBUG_STEPS printf("Checking #%d:\n", argv[i]); printf("%s\n", argv[i]); #endif if (argv[i][0] == '-') { if (argv[i][1] == '-') { // --xxx if ((strfield2(argv[i] + 2, "clean")) || (strfield2(argv[i] + 2, "tide"))) { // nettoyer strcpybuff(argv[i] + 1, ""); if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-log.txt"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-log.txt")); if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-err.txt"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-err.txt")); if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_html), "index.html"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_html), "index.html")); /* */ if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.zip"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.zip")); if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.zip"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.zip")); if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.dat"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.dat")); if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.ndx"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.ndx")); if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.dat"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.dat")); if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.ndx"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.ndx")); if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.lst"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.lst")); if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.lst"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.lst")); if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.txt"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.txt")); if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.txt"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.txt")); if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/doit.log"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/doit.log")); if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-in_progress.lock"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-in_progress.lock")); rmdir(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache")); // } else if (strfield2(argv[i] + 2, "catchurl")) { // capture d'URL via proxy temporaire! argv_url = 1; // forcer a passer les parametres strcpybuff(argv[i] + 1, "#P"); // } else if (strfield2(argv[i] + 2, "updatehttrack")) { #ifdef _WIN32 char s[HTS_CDLMAXSIZE + 256]; sprintf(s, "%s not available in this version", argv[i]); HTS_PANIC_PRINTF(s); htsmain_free(); return -1; #else #if 0 char _args[8][256]; char *args[8]; printf("Cheking for updates...\n"); strcpybuff(_args[0], argv[0]); strcpybuff(_args[1], "--get"); sprintf(_args[2], HTS_UPDATE_WEBSITE, 0, ""); strcpybuff(_args[3], "--quickinfo"); args[0] = _args[0]; args[1] = _args[1]; args[2] = _args[2]; args[3] = _args[3]; args[4] = NULL; if (execvp(args[0], args) == -1) { } #endif #endif } // else { char s[HTS_CDLMAXSIZE + 256]; sprintf(s, "%s not recognized", argv[i]); HTS_PANIC_PRINTF(s); htsmain_free(); return -1; } } } } } // Compter urls/jokers /* if (argv_url<=0) { int na; argv_url=0; for(na=1;naquiet); htsmain_free(); return 0; } else { if ((strchr(argv[na],'q')!=NULL)) opt->quiet=1; // ne pas poser de questions! (nohup par exemple) if ((strchr(argv[na],'i')!=NULL)) { // doit.log! argv_url=0; na=argc; } } } } */ // Ici on ajoute les arguments qui ont été appelés avant au cas où on récupère une session // Exemple: httrack www.truc.fr -L0 puis ^C puis httrack sans URL : ajouter URL précédente /* if (argv_url==0) { //if ((fexist(fconcat(StringBuff(opt->path_log),"hts-cache/new.dat"))) && (fexist(fconcat(StringBuff(opt->path_log),"hts-cache/new.ndx")))) { // il existe déja un cache précédent.. renommer if (fexist(fconcat(StringBuff(opt->path_log),"hts-cache/doit.log"))) { // un cache est présent x_argvblk=(char*) calloct(32768,1); if (x_argvblk!=NULL) { FILE* fp; int x_argc; //strcpybuff(x_argvblk,"httrack "); fp=fopen(fconcat(StringBuff(opt->path_log),"hts-cache/doit.log"),"rb"); if (fp) { linput(fp,x_argvblk+strlen(x_argvblk),8192); fclose(fp); fp=NULL; } // calculer arguments selon derniers arguments x_argv[0]=argv[0]; x_argc=1; { char* p=x_argvblk; do { x_argv[x_argc++]=p; //p=strstr(p," "); // exemple de chaine: "echo \"test\"" c:\a "\$0" p=next_token(p,1); // prochain token if (p) { *p=0; // octet nul (tableau) p++; } } while(p!=NULL); } // recopier arguments actuels (pointeurs uniquement) { int na; for(na=1;naquiet=1; // ne pas poser de questions! (nohup par exemple) } } } */ // Pas d'URL #if DEBUG_STEPS printf("Checking URLs\n"); #endif if (argv_url == 0) { // Présence d'un cache, que faire?.. if ((fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.zip"))) || (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.dat")) && fexist(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.ndx"))) ) { // il existe déja un cache précédent.. renommer if (fexist(fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/doit.log"))) { // un cache est présent if (x_argvblk != NULL) { int m; // établir mode - mode cache: 1 (cache valide) 2 (cache à vérifier) if (fexist(fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-in_progress.lock"))) { // cache prioritaire m = 1; } else { m = 2; } opt->cache = m; if (opt->quiet == 0) { // sinon on continue automatiquement HT_REQUEST_START; HT_PRINT("A cache (hts-cache/) has been found in the directory "); HT_PRINT(StringBuff(opt->path_log)); HT_PRINT(LF); if (m == 1) { HT_PRINT("That means that a transfer has been aborted" LF); HT_PRINT("OK to Continue "); } else { HT_PRINT("That means you can update faster the remote site(s)" LF); HT_PRINT("OK to Update "); } HT_PRINT("httrack "); HT_PRINT(x_argvblk); HT_PRINT("?" LF); HT_REQUEST_END; if (!ask_continue(opt)) { htsmain_free(); return 0; } } } else { HTS_PANIC_PRINTF("Error, not enough memory"); htsmain_free(); return -1; } } else { // log existe pas HTS_PANIC_PRINTF("A cache has been found, but no command line"); printf ("Please launch httrack with proper parameters to reuse the cache\n"); htsmain_free(); return -1; } } else { // aucune URL définie et pas de cache if (opt->quiet) { help(argv[0], !opt->quiet); htsmain_free(); return -1; } else { help_wizard(opt); htsmain_free(); return -1; } htsmain_free(); return 0; } } else { // plus de 2 paramètres // un fichier log existe? if (fexist(fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-in_progress.lock"))) { // fichier lock? //char s[32]; opt->cache = 1; // cache prioritaire if (opt->quiet == 0) { if ((fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.zip"))) || (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.dat")) && fexist(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.ndx"))) ) { HT_REQUEST_START; HT_PRINT("There is a lock-file in the directory "); HT_PRINT(StringBuff(opt->path_log)); HT_PRINT(LF "That means that a mirror has not been terminated" LF); HT_PRINT("Be sure you call httrack with proper parameters" LF); HT_PRINT("(The cache allows you to restart faster the transfer)" LF); HT_REQUEST_END; if (!ask_continue(opt)) { htsmain_free(); return 0; } } } } else if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_html), "index.html"))) { //char s[32]; opt->cache = 2; // cache vient après test de validité if (opt->quiet == 0) { if ((fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.zip"))) || (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.dat")) && fexist(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.ndx"))) ) { HT_REQUEST_START; HT_PRINT ("There is an index.html and a hts-cache folder in the directory "); HT_PRINT(StringBuff(opt->path_log)); HT_PRINT(LF "A site may have been mirrored here, that could mean that you want to update it" LF); HT_PRINT("Be sure parameters are ok" LF); HT_REQUEST_END; if (!ask_continue(opt)) { htsmain_free(); return 0; } } else { HT_REQUEST_START; HT_PRINT("There is an index.html in the directory "); HT_PRINT(StringBuff(opt->path_log)); HT_PRINT(" but no cache" LF); HT_PRINT("There is an index.html in the directory, but no cache" LF); HT_PRINT("A site may have been mirrored here, and erased.." LF); HT_PRINT("Be sure parameters are ok" LF); HT_REQUEST_END; if (!ask_continue(opt)) { htsmain_free(); return 0; } } } } } // Treat parameters // Traiter les paramètres #if DEBUG_STEPS printf("Analyze parameters\n"); #endif { char *com; int na; for(na = 1; na < argc; na++) { if (argv[na][0] == '"') { char BIGSTK tempo[HTS_CDLMAXSIZE + 256]; strcpybuff(tempo, argv[na] + 1); if (tempo[strlen(tempo) - 1] != '"') { char s[HTS_CDLMAXSIZE + 256]; sprintf(s, "Missing quote in %s", argv[na]); HTS_PANIC_PRINTF(s); htsmain_free(); return -1; } tempo[strlen(tempo) - 1] = '\0'; strcpybuff(argv[na], tempo); } if (cmdl_opt(argv[na])) { // option com = argv[na] + 1; while(*com) { switch (*com) { case ' ': case 9: case '-': case '\0': break; // case 'h': help(argv[0], 0); htsmain_free(); return 0; // déja fait normalement // case 'g': // récupérer un (ou plusieurs) fichiers isolés opt->wizard = 2; // le wizard on peut plus s'en passer.. //opt->wizard=0; // pas de wizard opt->cache = 0; // ni de cache opt->makeindex = 0; // ni d'index httrack_logmode = 1; // erreurs à l'écran opt->savename_type = 1003; // mettre dans le répertoire courant opt->depth = 0; // ne pas explorer la page opt->accept_cookie = 0; // pas de cookies opt->robots = 0; // pas de robots break; case 'w': opt->wizard = 2; // wizard 'soft' (ne pose pas de questions) opt->travel = 0; opt->seeker = 1; break; case 'W': opt->wizard = 1; // Wizard-Help (pose des questions) opt->travel = 0; opt->seeker = 1; break; case 'r': // n'est plus le recurse get bestial mais wizard itou! if (isdigit((unsigned char) *(com + 1))) { sscanf(com + 1, "%d", &opt->depth); while(isdigit((unsigned char) *(com + 1))) com++; } else opt->depth = 3; break; /* case 'r': opt->wizard=0; if (isdigit((unsigned char)*(com+1))) { sscanf(com+1,"%d",&opt->depth); while(isdigit((unsigned char)*(com+1))) com++; } else opt->depth=3; break; */ // // note: les tests opt->depth sont pour éviter de faire // un miroir du web (:-O) accidentelement ;-) case 'a': /*if (opt->depth==9999) opt->depth=3; */ opt->travel = 0 + (opt->travel & 256); break; case 'd': /*if (opt->depth==9999) opt->depth=3; */ opt->travel = 1 + (opt->travel & 256); break; case 'l': /*if (opt->depth==9999) opt->depth=3; */ opt->travel = 2 + (opt->travel & 256); break; case 'e': /*if (opt->depth==9999) opt->depth=3; */ opt->travel = 7 + (opt->travel & 256); break; case 't': opt->travel |= 256; break; case 'n': opt->nearlink = 1; break; case 'x': opt->external = 1; break; // case 'U': opt->seeker = 2; break; case 'D': opt->seeker = 1; break; case 'S': opt->seeker = 0; break; case 'B': opt->seeker = 3; break; // case 'Y': opt->mirror_first_page = 1; break; // case 'q': case 'i': opt->quiet = 1; break; // case 'Q': httrack_logmode = 0; opt->debug = LOG_NOTICE; break; case 'v': httrack_logmode = 1; break; case 'f': httrack_logmode = 2; if (*(com + 1) == '2') httrack_logmode = 3; while(isdigit((unsigned char) *(com + 1))) com++; break; // //case 'A': opt->urlmode=1; break; //case 'R': opt->urlmode=2; break; case 'K': opt->urlmode = 0; if (isdigit((unsigned char) *(com + 1))) { sscanf(com + 1, "%d", &opt->urlmode); if (opt->urlmode == 0) { // in fact K0 ==> K2 // and K ==> K0 opt->urlmode = 2; } while(isdigit((unsigned char) *(com + 1))) com++; } //if (*(com+1)=='0') { opt->urlmode=2; com++; } break; // case 'c': if (isdigit((unsigned char) *(com + 1))) { sscanf(com + 1, "%d", &opt->maxsoc); while(isdigit((unsigned char) *(com + 1))) com++; opt->maxsoc = max(opt->maxsoc, 1); // FORCER A 1 } else opt->maxsoc = 4; break; // case 'p': sscanf(com + 1, "%d", &opt->getmode); while(isdigit((unsigned char) *(com + 1))) com++; break; // case 'G': sscanf(com + 1, LLintP, &opt->fragment); while(isdigit((unsigned char) *(com + 1))) com++; break; case 'M': sscanf(com + 1, LLintP, &opt->maxsite); while(isdigit((unsigned char) *(com + 1))) com++; break; case 'm': // -m,10000 variant if (*(com + 1) != ',') { sscanf(com + 1, LLintP, &opt->maxfile_nonhtml); while(isdigit((unsigned char) *(com + 1))) com++; } if (*(com + 1) == ',' && isdigit((unsigned char) *(com + 2))) { com++; sscanf(com + 1, LLintP, &opt->maxfile_html); while(isdigit((unsigned char) *(com + 1))) com++; } else opt->maxfile_html = -1; break; // case 'T': sscanf(com + 1, "%d", &opt->timeout); while(isdigit((unsigned char) *(com + 1))) com++; break; case 'J': sscanf(com + 1, "%d", &opt->rateout); while(isdigit((unsigned char) *(com + 1))) com++; break; case 'R': sscanf(com + 1, "%d", &opt->retry); while(isdigit((unsigned char) *(com + 1))) com++; break; case 'E': sscanf(com + 1, "%d", &opt->maxtime); while(isdigit((unsigned char) *(com + 1))) com++; break; case 'H': sscanf(com + 1, "%d", &opt->hostcontrol); while(isdigit((unsigned char) *(com + 1))) com++; break; case 'A': sscanf(com + 1, "%d", &opt->maxrate); while(isdigit((unsigned char) *(com + 1))) com++; break; case 'j': opt->parsejava = HTSPARSE_DEFAULT; if (isdigit((unsigned char) *(com + 1))) { sscanf(com + 1, "%d", &opt->parsejava); while(isdigit((unsigned char) *(com + 1))) com++; } break; // case 'I': opt->makeindex = 1; if (*(com + 1) == '0') { opt->makeindex = 0; com++; } break; // case 'X': opt->delete_old = 1; if (*(com + 1) == '0') { opt->delete_old = 0; com++; } break; // case 'y': opt->background_on_suspend = 1; if (*(com + 1) == '0') { opt->background_on_suspend = 0; com++; } break; // case 'b': sscanf(com + 1, "%d", &opt->accept_cookie); while(isdigit((unsigned char) *(com + 1))) com++; break; // case 'N': if (strcmp(argv[na], "-N") == 0) { // Tout seul if ((na + 1 >= argc) || (argv[na + 1][0] == '-')) { // erreur HTS_PANIC_PRINTF ("Option N needs a number, or needs to be followed by a blank space, and a string"); printf("Example: -N4\n"); htsmain_free(); return -1; } else { na++; if (strlen(argv[na]) >= 127) { HTS_PANIC_PRINTF("Userdef structure string too long"); htsmain_free(); return -1; } StringCopy(opt->savename_userdef, argv[na]); if (StringLength(opt->savename_userdef) > 0) opt->savename_type = -1; // userdef! else opt->savename_type = 0; // -N "" : par défaut } } else { sscanf(com + 1, "%d", &opt->savename_type); while(isdigit((unsigned char) *(com + 1))) com++; } break; case 'L': { sscanf(com + 1, "%d", &opt->savename_83); switch (opt->savename_83) { case 0: // 8-3 (ISO9660 L1) opt->savename_83 = 1; break; case 1: opt->savename_83 = 0; break; default: // 2 == ISO9660 (ISO9660 L2) opt->savename_83 = 2; break; } while(isdigit((unsigned char) *(com + 1))) com++; } break; case 's': if (isdigit((unsigned char) *(com + 1))) { sscanf(com + 1, "%d", &opt->robots); while(isdigit((unsigned char) *(com + 1))) com++; } else opt->robots = 1; #if DEBUG_ROBOTS printf("robots.txt mode set to %d\n", opt->robots); #endif break; case 'o': sscanf(com + 1, "%d", &opt->errpage); while(isdigit((unsigned char) *(com + 1))) com++; break; case 'u': sscanf(com + 1, "%d", &opt->check_type); while(isdigit((unsigned char) *(com + 1))) com++; break; // case 'C': if (isdigit((unsigned char) *(com + 1))) { sscanf(com + 1, "%d", &opt->cache); while(isdigit((unsigned char) *(com + 1))) com++; } else opt->cache = 1; break; case 'k': opt->all_in_cache = 1; break; // case 'z': if (opt->debug > LOG_INFO) { opt->debug = LOG_DEBUG; /* -Zz */ } else { opt->debug = LOG_INFO; } break; // petit debug case 'Z': if (opt->debug >= LOG_DEBUG) { opt->debug = LOG_TRACE; /* -Zz */ } else { opt->debug = LOG_DEBUG; } break; // GROS debug // case '&': case '%':{ // deuxième jeu d'options com++; switch (*com) { case 'M': opt->mimehtml = 1; if (*(com + 1) == '0') { opt->mimehtml = 0; com++; } break; case 'k': opt->nokeepalive = 0; if (*(com + 1) == '0') { opt->nokeepalive = 1; com++; } break; case 'x': opt->passprivacy = 1; if (*(com + 1) == '0') { opt->passprivacy = 0; com++; } break; // No passwords in html files case 'q': opt->includequery = 1; if (*(com + 1) == '0') { opt->includequery = 0; com++; } break; // No passwords in html files case 'I': opt->kindex = 1; if (isdigit((unsigned char) *(com + 1))) { sscanf(com + 1, "%d", &opt->kindex); while(isdigit((unsigned char) *(com + 1))) com++; } break; // Keyword Index case 'c': sscanf(com + 1, "%f", &opt->maxconn); while(isdigit((unsigned char) *(com + 1)) || *(com + 1) == '.') com++; break; case 'e': sscanf(com + 1, "%d", &opt->extdepth); while(isdigit((unsigned char) *(com + 1))) com++; break; case 'B': opt->tolerant = 1; if (*(com + 1) == '0') { opt->tolerant = 0; com++; } break; // HTTP/1.0 notamment case 'h': opt->http10 = 1; if (*(com + 1) == '0') { opt->http10 = 0; com++; } break; // HTTP/1.0 case 'z': opt->nocompression = 1; if (*(com + 1) == '0') { opt->nocompression = 0; com++; } break; // pas de compression case 'f': opt->ftp_proxy = 1; if (*(com + 1) == '0') { opt->ftp_proxy = 0; com++; } break; // proxy http pour ftp case 'P': opt->parseall = 1; if (*(com + 1) == '0') { opt->parseall = 0; com++; } break; // tout parser case 'n': opt->norecatch = 1; if (*(com + 1) == '0') { opt->norecatch = 0; com++; } break; // ne pas reprendre fichiers effacés localement case 's': opt->sizehack = 1; if (*(com + 1) == '0') { opt->sizehack = 0; com++; } break; // hack sur content-length case 'u': opt->urlhack = 1; if (*(com + 1) == '0') { opt->urlhack = 0; com++; } break; // url hack case 'v': opt->verbosedisplay = 2; if (isdigit((unsigned char) *(com + 1))) { sscanf(com + 1, "%d", &opt->verbosedisplay); while(isdigit((unsigned char) *(com + 1))) com++; } break; case 'i': opt->dir_topindex = 1; if (*(com + 1) == '0') { opt->dir_topindex = 0; com++; } break; case 'N': opt->savename_delayed = 2; if (isdigit((unsigned char) *(com + 1))) { sscanf(com + 1, "%d", &opt->savename_delayed); while(isdigit((unsigned char) *(com + 1))) com++; } break; case 'D': opt->delayed_cached = 1; if (*(com + 1) == '0') { opt->delayed_cached = 0; com++; } break; // url hack case 'T': opt->convert_utf8 = 1; if (*(com + 1) == '0') { opt->convert_utf8 = 0; com++; } break; // convert to utf-8 case '!': opt->bypass_limits = 1; if (*(com + 1) == '0') { opt->bypass_limits = 0; com++; } break; case 'w': // disable specific plugin if ((na + 1 >= argc) || (argv[na + 1][0] == '-')) { HTS_PANIC_PRINTF ("Option %w needs to be followed by a blank space, and a module name"); printf("Example: -%%w htsswf\n"); htsmain_free(); return -1; } else { na++; StringCat(opt->mod_blacklist, argv[na]); StringCat(opt->mod_blacklist, "\n"); } break; // preserve: no footer, original links case 'p': StringClear(opt->footer); opt->urlmode = 4; break; case 'L': // URL list if ((na + 1 >= argc) || (argv[na + 1][0] == '-')) { HTS_PANIC_PRINTF ("Option %L needs to be followed by a blank space, and a text filename"); printf("Example: -%%L \"mylist.txt\"\n"); htsmain_free(); return -1; } else { na++; if (strlen(argv[na]) >= 254) { HTS_PANIC_PRINTF("File list string too long"); htsmain_free(); return -1; } StringCopy(opt->filelist, argv[na]); } break; case 'b': // bind if ((na + 1 >= argc) || (argv[na + 1][0] == '-')) { HTS_PANIC_PRINTF ("Option %b needs to be followed by a blank space, and a local hostname"); printf("Example: -%%b \"ip4.localhost\"\n"); htsmain_free(); return -1; } else { na++; if (strlen(argv[na]) >= 254) { HTS_PANIC_PRINTF("Hostname string too long"); htsmain_free(); return -1; } StringCopy(opt->proxy.bindhost, argv[na]); } break; case 'S': // Scan Rules list if ((na + 1 >= argc) || (argv[na + 1][0] == '-')) { HTS_PANIC_PRINTF ("Option %S needs to be followed by a blank space, and a text filename"); printf("Example: -%%S \"myfilterlist.txt\"\n"); htsmain_free(); return -1; } else { off_t fz; na++; fz = fsize(argv[na]); if (fz < 0) { HTS_PANIC_PRINTF("File url list could not be opened"); htsmain_free(); return -1; } else { FILE *fp = fopen(argv[na], "rb"); if (fp != NULL) { int cl = (int) strlen(url); ensureUrlCapacity(url, url_sz, cl + fz + 8192); if (cl > 0) { /* don't stick! (3.43) */ url[cl] = ' '; cl++; } if (fread(url + cl, 1, fz, fp) != fz) { HTS_PANIC_PRINTF("File url list could not be read"); htsmain_free(); return -1; } fclose(fp); *(url + cl + fz) = '\0'; } } } break; case 'A': // assume if ((na + 1 >= argc) || (argv[na + 1][0] == '-')) { HTS_PANIC_PRINTF ("Option %A needs to be followed by a blank space, and a filesystemtype=mimetype/mimesubtype parameters"); printf("Example: -%%A php3=text/html,asp=text/html\n"); htsmain_free(); return -1; } else { na++; // --assume standard if (strcmp(argv[na], "standard") == 0) { StringCopy(opt->mimedefs, "\n"); StringCat(opt->mimedefs, HTS_ASSUME_STANDARD); StringCat(opt->mimedefs, "\n"); } else { char *a; //char* b = StringBuff(opt->mimedefs) + StringLength(opt->mimedefs); for(a = argv[na]; *a != '\0'; a++) { if (*a == ';') { /* next one */ StringAddchar(opt->mimedefs, '\n'); //*b++ = '\n'; } else if (*a == ',' || *a == '\n' || *a == '\r' || *a == '\t') { StringAddchar(opt->mimedefs, ' '); //*b++ = ' '; } else { StringAddchar(opt->mimedefs, *a); //*b++ = *a; } } StringAddchar(opt->mimedefs, '\n'); //*b++ = '\n'; /* next def */ //*b++ = '\0'; } } break; // case 'l': // Accept-language if ((na + 1 >= argc) || (argv[na + 1][0] == '-')) { HTS_PANIC_PRINTF ("Option %l needs to be followed by a blank space, and an ISO language code"); printf("Example: -%%l \"en\"\n"); htsmain_free(); return -1; } else { na++; if (strlen(argv[na]) >= 62) { HTS_PANIC_PRINTF("Lang list string too long"); htsmain_free(); return -1; } StringCopy(opt->lang_iso, argv[na]); } break; // case 'a': // Accept if ((na + 1 >= argc) || (argv[na + 1][0] == '-')) { HTS_PANIC_PRINTF ("Option %a needs to be followed by a blank space, and a list of formats"); printf("Example: -%%a \"text/html,*/*;q=0.1\"\n"); htsmain_free(); return -1; } else { na++; if (strlen(argv[na]) >= 256) { HTS_PANIC_PRINTF("Accept list string too long"); htsmain_free(); return -1; } StringCopy(opt->accept, argv[na]); } break; // case 'X': // HTTP header line if ((na + 1 >= argc) || (argv[na + 1][0] == '-')) { HTS_PANIC_PRINTF ("Option %X needs to be followed by a blank space, and a raw HTTP header line"); printf("Example: -%%X \"X-Magic: 42\"\n"); htsmain_free(); return -1; } else { na++; if (argv[na][0] == '\0') { HTS_PANIC_PRINTF("Empty string given"); htsmain_free(); return -1; } else if (strlen(argv[na]) >= 256) { HTS_PANIC_PRINTF("Header line string too long"); htsmain_free(); return -1; } StringCat(opt->headers, argv[na]); StringCat(opt->headers, "\r\n"); /* separator */ } break; // case 'F': // footer id if ((na + 1 >= argc) || (argv[na + 1][0] == '-')) { HTS_PANIC_PRINTF ("Option %F needs to be followed by a blank space, and a footer string"); printf ("Example: -%%F \"\"\n"); htsmain_free(); return -1; } else { na++; if (strlen(argv[na]) >= 254) { HTS_PANIC_PRINTF("Footer string too long"); htsmain_free(); return -1; } StringCopy(opt->footer, argv[na]); } break; case 'H': // debug headers _DEBUG_HEAD = 1; break; case 'O': printf ("Warning option -%%O is no longer supported\n"); break; case 'U': // setuid ; removed because insane HTS_PANIC_PRINTF ("Option %U is no longer supported"); htsmain_free(); return -1; break; case 'W': // Wrapper callback // --wrapper check-link=obj.so:check_link if ((na + 1 >= argc) || (argv[na + 1][0] == '-')) { HTS_PANIC_PRINTF ("Option %W needs to be followed by a blank space, and a =: field"); printf("Example: -%%W check-link=checklink.so:check\n"); htsmain_free(); return -1; } else { char *pos; na++; for(pos = argv[na]; *pos != '\0' && *pos != '=' && *pos != ',' && *pos != ':'; pos++) ; /* httrack --wrapper callback[,foo] */ if (*pos == 0 || *pos == ',' || *pos == ':') { int ret; char *moduleName; if (*pos == ',' || *pos == ':') { *pos = '\0'; moduleName = strdupt(argv[na]); *pos = ','; /* foce seperator to ',' */ } else { moduleName = strdupt(argv[na]); } ret = plug_wrapper(opt, moduleName, argv[na]); freet(moduleName); if (ret == 0) { char BIGSTK tmp[1024 * 2]; sprintf(tmp, "option %%W : unable to plug the module %s (returncode != 1)", argv[na]); HTS_PANIC_PRINTF(tmp); htsmain_free(); return -1; } else if (ret == -1) { char BIGSTK tmp[1024 * 2]; int last_errno = errno; sprintf(tmp, "option %%W : unable to load the module %s: %s (check the library path ?)", argv[na], strerror(last_errno)); HTS_PANIC_PRINTF(tmp); htsmain_free(); return -1; } } /* Old style */ /* httrack --wrapper save-name=callback:process,string */ else if (*pos == '=') { fprintf(stderr, "Syntax error in option %%W : the old (<3.41) API is no more supported!\n"); HTS_PANIC_PRINTF ("Syntax error in option %W : the old (<3.41) API is no more supported!"); printf("Example: -%%W check-link=checklink.so:check\n"); htsmain_free(); return -1; } else { HTS_PANIC_PRINTF ("Syntax error in option %W : this function needs to be followed by a blank space, and a module name"); printf("Example: -%%W check-link=checklink.so:check\n"); htsmain_free(); return -1; } } break; case 'R': // Referer if ((na + 1 >= argc) || (argv[na + 1][0] == '-')) { HTS_PANIC_PRINTF ("Option %R needs to be followed by a blank space, and a referer URL"); printf("Example: -%%R \"http://www.example.com/\"\n"); htsmain_free(); return -1; } else { na++; if (strlen(argv[na]) >= 254) { HTS_PANIC_PRINTF("Referer URL too long"); htsmain_free(); return -1; } StringCopy(opt->referer, argv[na]); } break; case 'E': // From Email address if ((na + 1 >= argc) || (argv[na + 1][0] == '-')) { HTS_PANIC_PRINTF ("Option %E needs to be followed by a blank space, and an email"); printf("Example: -%%E \"postmaster@example.com\"\n"); htsmain_free(); return -1; } else { na++; if (strlen(argv[na]) >= 254) { HTS_PANIC_PRINTF("From email too long"); htsmain_free(); return -1; } StringCopy(opt->from, argv[na]); } break; case 't': /* do not change type (ending) of filenames according to the MIME type */ opt->no_type_change = 1; if (*(com+1)=='0') { opt->no_type_change = 0; com++; } break; default:{ char s[HTS_CDLMAXSIZE + 256]; sprintf(s, "invalid option %%%c\n", *com); HTS_PANIC_PRINTF(s); htsmain_free(); return -1; } break; } } break; // case '@':{ // troisième jeu d'options com++; switch (*com) { case 'i': #if HTS_INET6==0 printf ("Warning, option @i has no effect (v6 routines not compiled)\n"); #else { int res = 0; if (isdigit((unsigned char) *(com + 1))) { sscanf(com + 1, "%d", &res); while(isdigit((unsigned char) *(com + 1))) com++; } switch (res) { case 1: case 4: IPV6_resolver = 1; break; case 2: case 6: IPV6_resolver = 2; break; case 0: IPV6_resolver = 0; break; default: printf("Unknown flag @i%d\n", res); htsmain_free(); return -1; break; } } #endif break; default:{ char s[HTS_CDLMAXSIZE + 256]; sprintf(s, "invalid option %%%c\n", *com); HTS_PANIC_PRINTF(s); htsmain_free(); return -1; } break; //case 's': opt->sslengine=1; if (isdigit((unsigned char)*(com+1))) { sscanf(com+1,"%d",&opt->sslengine); while(isdigit((unsigned char)*(com+1))) com++; } break; } } break; // case '#':{ // non documenté com++; switch (*com) { case 'C': // list cache files : httrack -#C '*spid*.gif' will attempt to find the matching file { int hasFilter = 0; int found = 0; char *filter = NULL; cache_back cache; coucal cache_hashtable = coucal_new(0); int sendb = 0; if (isdigit((unsigned char) *(com + 1))) { sscanf(com + 1, "%d", &sendb); while(isdigit((unsigned char) *(com + 1))) com++; } else sendb = 0; if (!((na + 1 >= argc) || (argv[na + 1][0] == '-'))) { na++; hasFilter = 1; filter = argv[na]; } memset(&cache, 0, sizeof(cache_back)); cache.type = 1; // cache? cache.log = stdout; // log? cache.errlog = stderr; // err log? cache.ptr_ant = cache.ptr_last = 0; // pointeur pour anticiper cache.hashtable = (void *) cache_hashtable; /* copy backcache hash */ cache.ro = 1; /* read only */ if (cache.hashtable) { lien_adrfilsave afs; char BIGSTK url[HTS_URLMAXSIZE * 2]; char linepos[256]; int pos; char *cacheNdx = readfile(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.ndx")); cache_init(&cache, opt); /* load cache */ if (cacheNdx != NULL) { char firstline[256]; char *a = cacheNdx; a += cache_brstr(a, firstline); a += cache_brstr(a, firstline); while(a != NULL) { a = strchr(a + 1, '\n'); /* start of line */ if (a) { htsblk r; /* */ a++; /* read "host/file" */ a += binput(a, afs.af.adr, HTS_URLMAXSIZE); a += binput(a, afs.af.fil, HTS_URLMAXSIZE); url[0] = '\0'; if (!link_has_authority(afs.af.adr)) strcatbuff(url, "http://"); strcatbuff(url, afs.af.adr); strcatbuff(url, afs.af.fil); /* read position */ a += binput(a, linepos, 200); sscanf(linepos, "%d", &pos); if (!hasFilter || (strjoker(url, filter, NULL, NULL) != NULL) ) { r = cache_read_ro(opt, &cache, afs.af.adr, afs.af.fil, "", NULL); // lire entrée cache + data if (r.statuscode != -1) { // No errors found++; if (!hasFilter) { fprintf(stdout, "%s%s%s\r\n", (link_has_authority(afs.af.adr)) ? "" : "http://", afs.af.adr, afs.af.fil); } else { char msg[256], cdate[256]; infostatuscode(msg, r.statuscode); time_gmt_rfc822(cdate); fprintf(stdout, "HTTP/1.1 %d %s\r\n", r.statuscode, r.msg[0] ? r.msg : msg); fprintf(stdout, "X-Host: %s\r\n", afs.af.adr); fprintf(stdout, "X-File: %s\r\n", afs.af.fil); fprintf(stdout, "X-URL: %s%s%s\r\n", (link_has_authority(afs.af.adr)) ? "" : "http://", afs.af.adr, afs.af.fil); if (url_savename (&afs, /*former */ NULL, /*referer_adr */ NULL, /*referer_fil */ NULL, /*opt */ opt, /*sback */ NULL, /*cache */ &cache, /*hash */ NULL, /*ptr */ 0, /*numero_passe */ 0, /*mime_type */ NULL) != -1) { if (fexist(afs.save)) { fprintf(stdout, "Content-location: %s\r\n", afs.save); } } fprintf(stdout, "Date: %s\r\n", cdate); fprintf(stdout, "Server: HTTrack Website Copier/" HTTRACK_VERSION "\r\n"); if (r.lastmodified[0]) { fprintf(stdout, "Last-Modified: %s\r\n", r.lastmodified); } if (r.etag[0]) { fprintf(stdout, "Etag: %s\r\n", r.etag); } if (r.totalsize >= 0) { fprintf(stdout, "Content-Length: " LLintP "\r\n", r.totalsize); } fprintf(stdout, "X-Content-Length: " LLintP "\r\n", (r.size >= 0) ? r.size : (-r.size)); if (r.contenttype >= 0) { fprintf(stdout, "Content-Type: %s\r\n", r.contenttype); } if (r.cdispo[0]) { fprintf(stdout, "Content-Disposition: %s\r\n", r.cdispo); } if (r.contentencoding[0]) { fprintf(stdout, "Content-Encoding: %s\r\n", r.contentencoding); } if (r.is_chunk) { fprintf(stdout, "Transfer-Encoding: chunked\r\n"); } #if HTS_USEOPENSSL if (r.ssl) { fprintf(stdout, "X-SSL: yes\r\n"); } #endif if (r.is_write) { fprintf(stdout, "X-Direct-To-Disk: yes\r\n"); } if (r.compressed) { fprintf(stdout, "X-Compressed: yes\r\n"); } if (r.notmodified) { fprintf(stdout, "X-Not-Modified: yes\r\n"); } if (r.is_chunk) { fprintf(stdout, "X-Chunked: yes\r\n"); } fprintf(stdout, "\r\n"); /* Send the body */ if (sendb && r.adr) { fprintf(stdout, "%s\r\n", r.adr); } } } } } } freet(cacheNdx); } } if (!found) { fprintf(stderr, "No cache entry found%s%s%s\r\n", (hasFilter) ? " for '" : "", (hasFilter) ? filter : "", (hasFilter) ? "'" : ""); } return 0; } break; case 'E': // extract cache if (!hts_extract_meta(StringBuff(opt->path_log))) { fprintf(stderr, "* error extracting meta-data\n"); return 1; } fprintf(stderr, "* successfully extracted meta-data\n"); return 0; break; case 'X': fprintf(stderr, "warning: option has no effect\n"); if (*(com + 1) == '0') { com++; } break; case 'R': { char *name; uLong repaired = 0; uLong repairedBytes = 0; if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.zip"))) { name = fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.zip"); } else if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.zip"))) { name = fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.zip"); } else { fprintf(stderr, "* error: no cache found in %s\n", fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.zip")); return 1; } fprintf(stderr, "Cache: trying to repair %s\n", name); if (unzRepair (name, fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/repair.zip"), fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/repair.tmp"), &repaired, &repairedBytes) == Z_OK) { unlink(name); rename(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/repair.zip"), name); fprintf(stderr, "Cache: %d bytes successfully recovered in %d entries\n", (int) repairedBytes, (int) repaired); } else { fprintf(stderr, "Cache: could not repair the cache\n"); } } return 0; break; case '~': /* internal lib test */ HTS_PANIC_PRINTF ("Option #~ is disabled for security reasons"); //Disabled because choke on GCC 4.3 (toni from links2linux.de) //{ // char thisIsATestYouShouldSeeAnError[12]; // const char *const bufferOverflowTest = "0123456789012345678901234567890123456789"; // strcpybuff(thisIsATestYouShouldSeeAnError, bufferOverflowTest); // return 0; //} break; case 'f': opt->flush = 1; break; case 'h': printf("HTTrack version " HTTRACK_VERSION "%s\n", hts_get_version_info(opt)); return 0; break; case 'p': /* opt->aff_progress=1; deprecated */ break; case 'S': opt->shell = 1; break; // stdin sur un shell case 'K': opt->keyboard = 1; break; // vérifier stdin // case 'L': sscanf(com + 1, "%d", &opt->maxlink); while(isdigit((unsigned char) *(com + 1))) com++; break; case 'F': sscanf(com + 1, "%d", &opt->maxfilter); while(isdigit((unsigned char) *(com + 1))) com++; break; case 'Z': opt->makestat = 1; break; case 'T': opt->maketrack = 1; break; case 'u': sscanf(com + 1, "%d", &opt->waittime); while(isdigit((unsigned char) *(com + 1))) com++; break; /*case 'R': // ohh ftp, catch->ftpget HTS_PANIC_PRINTF("Unexpected internal error with -#R command"); htsmain_free(); return -1; break; */ case 'P':{ // catchurl help_catchurl(StringBuff(opt->path_log)); htsmain_free(); return 0; } break; case '0': /* test #0 : filters */ if (na + 2 >= argc) { HTS_PANIC_PRINTF ("Option #0 needs to be followed by a filter string and a string"); printf("Example: '-#0' '*.gif' 'foo.gif'\n"); htsmain_free(); return -1; } else { if (strjoker(argv[na + 2], argv[na + 1], NULL, NULL)) printf("%s does match %s\n", argv[na + 2], argv[na + 1]); else printf("%s does NOT match %s\n", argv[na + 2], argv[na + 1]); htsmain_free(); return 0; } break; case '1': /* test #1 : fil_simplifie */ if (na + 1 >= argc) { HTS_PANIC_PRINTF("Option #1 needs to be followed by an URL"); printf("Example: '-#1' ./foo/bar/../foobar\n"); htsmain_free(); return -1; } else { fil_simplifie(argv[na + 1]); printf("simplified=%s\n", argv[na + 1]); htsmain_free(); return 0; } break; case '2': // mimedefs if (na + 1 >= argc) { HTS_PANIC_PRINTF("Option #2 needs to be followed by an URL"); printf("Example: '-#2' /foo/bar.php\n"); htsmain_free(); return -1; } else { char mime[256]; // initialiser mimedefs //get_userhttptype(opt,1,opt->mimedefs,NULL); // check mime[0] = '\0'; get_httptype(opt, mime, argv[na + 1], 0); if (mime[0] != '\0') { char ext[256]; printf("%s is '%s'\n", argv[na + 1], mime); ext[0] = '\0'; give_mimext(ext, mime); if (ext[0]) { printf("and its local type is '.%s'\n", ext); } } else { printf("%s is of an unknown MIME type\n", argv[na + 1]); } htsmain_free(); return 0; } break; case '3': // charset tests: httrack -#3 "iso-8859-1" "café" if (++na + 1 < argc) { char *s = hts_convertStringToUTF8(argv[na+1], strlen(argv[na+1]), argv[na]); if (s != NULL) { printf("%s\n", s); free(s); } else { fprintf(stderr, "invalid string for charset %s\n", argv[na]); } na += 2; } else { fprintf(stderr, "Option #3 needs to be followed by a charset and a string"); } htsmain_free(); return 0; break; case '4': // IDNA encoder: httrack -#4 "www.café.com" if (++na < argc) { char *s = hts_convertStringUTF8ToIDNA(argv[na], strlen(argv[na])); if (s != NULL) { printf("%s\n", s); free(s); } else { fprintf(stderr, "invalid string '%s'\n", argv[na]); } na += 1; } else { fprintf(stderr, "Option #4 needs to be followed by an IDNA string"); } htsmain_free(); return 0; break; case '5': // IDNA encoder: httrack -#5 if (++na < argc) { char *s = hts_convertStringIDNAToUTF8(argv[na], strlen(argv[na])); if (s != NULL) { printf("%s\n", s); free(s); } else { fprintf(stderr, "invalid string '%s'\n", argv[na]); } na += 1; } else { fprintf(stderr, "Option #5 needs to be followed by an IDNA string"); } htsmain_free(); return 0; break; case '6': // entities: httrack -#6 "&foo;" ["encoding"] if (++na < argc) { char *const s = strdup(argv[na]); const char *const enc = na + 1 < argc ? argv[na + 1] : "UTF-8"; if (s != NULL && hts_unescapeEntitiesWithCharset(s, s, strlen(s), enc) == 0) { printf("%s\n", s); free(s); } else { fprintf(stderr, "invalid string '%s'\n", argv[na]); } na += 1; } else { fprintf(stderr, "Option #6 needs to be followed by a string"); } htsmain_free(); return 0; break; case '7': // hashtable selftest: httrack -#7 nb_entries basic_selftests(); if (++na < argc) { char *const snum = strdup(argv[na]); unsigned long count = 0; const char *const names[] = { "", "add", "delete", "dry-add", "dry-del", "test-exists", "test-not-exist" }; const struct { enum { DO_END, DO_ADD, DO_DEL, DO_DRY_ADD, DO_DRY_DEL, TEST_ADD, TEST_DEL } type; size_t modulus; size_t offset; } bench[] = { { DO_ADD, 4, 0 }, /* add 4/0 */ { TEST_ADD, 4, 0 }, /* check 4/0 */ { TEST_DEL, 4, 1 }, /* check 4/1 */ { TEST_DEL, 4, 2 }, /* check 4/2 */ { TEST_DEL, 4, 3 }, /* check 4/3 */ { DO_DRY_DEL, 4, 1 }, /* del 4/1 */ { DO_DRY_DEL, 4, 2 }, /* del 4/2 */ { DO_DRY_DEL, 4, 3 }, /* del 4/3 */ { DO_ADD, 4, 1 }, /* add 4/1 */ { DO_DRY_ADD, 4, 1 }, /* add 4/1 */ { TEST_ADD, 4, 0 }, /* check 4/0 */ { TEST_ADD, 4, 1 }, /* check 4/1 */ { TEST_DEL, 4, 2 }, /* check 4/2 */ { TEST_DEL, 4, 3 }, /* check 4/3 */ { DO_ADD, 4, 2 }, /* add 4/2 */ { DO_DRY_DEL, 4, 3 }, /* del 4/3 */ { DO_ADD, 4, 3 }, /* add 4/3 */ { DO_DEL, 4, 3 }, /* del 4/3 */ { TEST_ADD, 4, 0 }, /* check 4/0 */ { TEST_ADD, 4, 1 }, /* check 4/1 */ { TEST_ADD, 4, 2 }, /* check 4/2 */ { TEST_DEL, 4, 3 }, /* check 4/3 */ { DO_DEL, 4, 0 }, /* del 4/0 */ { DO_DEL, 4, 1 }, /* del 4/1 */ { DO_DEL, 4, 2 }, /* del 4/2 */ /* empty here */ { TEST_DEL, 1, 0 }, /* check */ { DO_ADD, 4, 0 }, /* add 4/0 */ { DO_ADD, 4, 1 }, /* add 4/1 */ { DO_ADD, 4, 2 }, /* add 4/2 */ { DO_DEL, 42, 0 }, /* add 42/0 */ { TEST_DEL, 42, 0 }, /* check 42/0 */ { TEST_ADD, 42, 2 }, /* check 42/2 */ { DO_END } }; char *buff = NULL; const char **strings = NULL; /* produce key #i */ #define FMT() \ char buffer[256]; \ const char *name; \ const long expected = (long) i * 1664525 + 1013904223; \ do { \ if (strings == NULL) { \ snprintf(buffer, sizeof(buffer), \ "http://www.example.com/website/sample/for/hashtable/" \ "%ld/index.html?foo=%ld&bar", \ (long) i, (long) (expected)); \ name = buffer; \ } else { \ name = strings[i]; \ } \ } while(0) /* produce random patterns, or read from a file */ if (sscanf(snum, "%lu", &count) != 1) { const off_t size = fsize(snum); FILE *fp = fopen(snum, "rb"); if (fp != NULL) { buff = malloc(size); if (buff != NULL && fread(buff, 1, size, fp) == size) { size_t capa = 0; size_t i, last; for(i = 0, last = 0, count = 0 ; i < size ; i++) { if (buff[i] == 10 || buff[i] == 0) { buff[i] = '\0'; if (capa == count) { if (capa == 0) { capa = 16; } else { capa <<= 1; } strings = (const char **) realloc((void*) strings, capa*sizeof(char*)); } strings[count++] = &buff[last]; last = i + 1; } } } fclose(fp); } } /* successfully read */ if (count > 0) { coucal hashtable = coucal_new(0); size_t loop; for(loop = 0 ; bench[loop].type != DO_END ; loop++) { size_t i; for(i = bench[loop].offset ; i < (size_t) count ; i += bench[loop].modulus) { int result; FMT(); if (bench[loop].type == DO_ADD || bench[loop].type == DO_DRY_ADD) { size_t k; result = coucal_write(hashtable, name, (uintptr_t) expected); for(k = 0 ; k < /* stash_size*2 */ 32 ; k++) { (void) coucal_write(hashtable, name, (uintptr_t) expected); } /* revert logic */ if (bench[loop].type == DO_DRY_ADD) { result = result ? 0 : 1; } } else if (bench[loop].type == DO_DEL || bench[loop].type == DO_DRY_DEL) { size_t k; result = coucal_remove(hashtable, name); for(k = 0 ; k < /* stash_size*2 */ 32 ; k++) { (void) coucal_remove(hashtable, name); } /* revert logic */ if (bench[loop].type == DO_DRY_DEL) { result = result ? 0 : 1; } } else if (bench[loop].type == TEST_ADD || bench[loop].type == TEST_DEL) { intptr_t value = -1; result = coucal_readptr(hashtable, name, &value); if (bench[loop].type == TEST_ADD && result && value != expected) { fprintf(stderr, "value failed for %s (expected %ld, got %ld)\n", name, (long) expected, (long) value); exit(EXIT_FAILURE); } /* revert logic */ if (bench[loop].type == TEST_DEL) { result = result ? 0 : 1; } } if (!result) { fprintf(stderr, "failed %s{%d/+%d} test on loop %ld" " at offset %ld for %s\n", names[bench[loop].type], (int) bench[loop].modulus, (int) bench[loop].offset, (long) loop, (long) i, name); exit(EXIT_FAILURE); } } } coucal_delete(&hashtable); fprintf(stderr, "all hashtable tests were successful!\n"); } else { fprintf(stderr, "Malformed number\n"); exit(EXIT_FAILURE); } #undef FMT } else { fprintf(stderr, "Option #7 needs to be followed by a number"); exit(EXIT_FAILURE); } htsmain_free(); return 0; break; case '!': HTS_PANIC_PRINTF ("Option #! is disabled for security reasons"); htsmain_free(); return -1; break; case 'd': opt->parsedebug = 1; break; /* autotest */ case 't': /* not yet implemented */ fprintf(stderr, "** AUTOCHECK OK\n"); return 0; break; #ifdef HTS_CRASH_TEST case 'c': /* crash test */ do_crash(); break; #endif default: printf("Internal option %c not recognized\n", *com); break; } } break; case 'O': // output path while(isdigit(com[1])) { com++; } na++; // sauter, déja traité break; case 'P': // proxy if ((na + 1 >= argc) || (argv[na + 1][0] == '-')) { HTS_PANIC_PRINTF ("Option P needs to be followed by a blank space, and a proxy proxy:port or user:id@proxy:port"); printf("Example: -P proxy.myhost.com:8080\n"); htsmain_free(); return -1; } else { char *a; na++; opt->proxy.active = 1; // Rechercher MAIS en partant de la fin à cause de user:pass@proxy:port a = argv[na] + strlen(argv[na]) - 1; // a=strstr(argv[na],":"); // port while((a > argv[na]) && (*a != ':') && (*a != '@')) a--; if (*a == ':') { // un port est présent, :port sscanf(a + 1, "%d", &opt->proxy.port); StringCopyN(opt->proxy.name, argv[na], (int) (a - argv[na])); } else { // opt->proxy.port = 8080; StringCopy(opt->proxy.name, argv[na]); } } break; case 'F': // user-agent field if ((na + 1 >= argc) || (argv[na + 1][0] == '-')) { HTS_PANIC_PRINTF ("Option F needs to be followed by a blank space, and a user-agent name"); printf("Example: -F \"my_user_agent/1.0\"\n"); htsmain_free(); return -1; } else { na++; if (strlen(argv[na]) >= 126) { HTS_PANIC_PRINTF("User-agent length too long"); htsmain_free(); return -1; } StringCopy(opt->user_agent, argv[na]); if (StringNotEmpty(opt->user_agent)) opt->user_agent_send = 1; else opt->user_agent_send = 0; // -F "" désactive l'option } break; // case 'V': // execute command if ((na + 1 >= argc) || (argv[na + 1][0] == '-')) { HTS_PANIC_PRINTF ("Option V needs to be followed by a system-command string"); printf("Example: -V \"tar uvf some.tar \\$0\"\n"); htsmain_free(); return -1; } else { na++; if (strlen(argv[na]) >= 2048) { HTS_PANIC_PRINTF("System-command length too long"); htsmain_free(); return -1; } StringCopy(opt->sys_com, argv[na]); if (StringNotEmpty(opt->sys_com)) opt->sys_com_exec = 1; else opt->sys_com_exec = 0; // -V "" désactive l'option } break; // default:{ char s[HTS_CDLMAXSIZE + 256]; sprintf(s, "invalid option %c\n", *com); HTS_PANIC_PRINTF(s); htsmain_free(); return -1; } break; } // switch com++; } // while } else { // URL/filters char catbuff[CATBUFF_SIZE]; const int urlSize = (int) strlen(argv[na]); const int capa = (int) (strlen(url) + urlSize + 32); assertf(urlSize < HTS_URLMAXSIZE); if (urlSize < HTS_URLMAXSIZE) { ensureUrlCapacity(url, url_sz, capa); if (strnotempty(url)) strcatbuff(url, " "); // espace de séparation append_escape_spc_url(unescape_http_unharm(catbuff, sizeof(catbuff), argv[na], 1), url, url_sz); } } // if argv=- etc. } // for } #if BDEBUG==3 printf("URLs/filters=%s\n", url); #endif #if DEBUG_STEPS printf("Analyzing parameters done\n"); #endif #ifdef _WIN32 #else #ifndef HTS_DO_NOT_USE_UID /* Check we do not run as r00t */ { uid_t userid = getuid(); if (userid == 0) { /* running as r00t */ printf("WARNING! You are running this program as root!\n"); printf ("It might be a good idea to run as a different user\n"); } } #endif #endif //printf("WARNING! This is *only* a beta-release of HTTrack\n"); io_flush; #if DEBUG_STEPS printf("Cache & log settings\n"); #endif // on utilise le cache.. // en cas de présence des deux versions, garder la version la plus avancée, // cad la version contenant le plus de fichiers if (opt->cache) { if (fexist(fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-in_progress.lock"))) { // problemes.. if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.dat"))) { if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.zip"))) { if (fsize (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.zip")) < 32768) { if (fsize (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.zip")) > 65536) { if (fsize (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.zip")) > fsize(fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt-> path_log), "hts-cache/new.zip"))) { remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.zip")); rename(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.zip"), fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.zip")); } } } } } else if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.dat")) && fexist(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.ndx"))) { if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.dat")) && fexist(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.ndx"))) { // switcher si new<32Ko et old>65Ko (tailles arbitraires) ? // ce cas est peut être une erreur ou un crash d'un miroir ancien, prendre // alors l'ancien cache if (fsize (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.dat")) < 32768) { if (fsize (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.dat")) > 65536) { if (fsize (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.dat")) > fsize(fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt-> path_log), "hts-cache/new.dat"))) { remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.dat")); remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.ndx")); rename(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.dat"), fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.dat")); rename(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.ndx"), fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.ndx")); //} else { // ne rien faire // remove("hts-cache/old.dat"); // remove("hts-cache/old.ndx"); } } } } } } } // Débuggage des en têtes if (_DEBUG_HEAD) { ioinfo = fopen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-ioinfo.txt"), "wb"); } { char n_lock[256]; // on peut pas avoir un affichage ET un fichier log // ca sera pour la version 2 if (httrack_logmode == 1) { opt->log = stdout; opt->errlog = stderr; } else if (httrack_logmode >= 2) { // deux fichiers log structcheck(StringBuff(opt->path_log)); if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-log.txt"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-log.txt")); if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-err.txt"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-err.txt")); /* Check FS directory structure created */ structcheck(StringBuff(opt->path_log)); opt->log = fopen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-log.txt"), "w"); if (httrack_logmode == 2) opt->errlog = fopen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-err.txt"), "w"); else opt->errlog = opt->log; if (opt->log == NULL) { char s[HTS_CDLMAXSIZE + 256]; sprintf(s, "Unable to create log file %s", fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-log.txt")); HTS_PANIC_PRINTF(s); htsmain_free(); return -1; } else if (opt->errlog == NULL) { char s[HTS_CDLMAXSIZE + 256]; sprintf(s, "Unable to create log file %s", fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-err.txt")); HTS_PANIC_PRINTF(s); htsmain_free(); return -1; } } else { opt->log = NULL; opt->errlog = NULL; } // un petit lock-file pour indiquer un miroir en cours, ainsi qu'un éventuel fichier log { FILE *fp = NULL; //int n=0; char t[256]; time_local_rfc822(t); // faut bien que ca serve quelque part l'heure RFC1945 arf' /* readme for information purpose */ { FILE *fp = fopen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/readme.txt"), "wb"); if (fp) { fprintf(fp, "What's in this folder?" LF); fprintf(fp, "" LF); fprintf(fp, "This folder (hts-cache) has been generated by WinHTTrack " HTTRACK_VERSION "%s" LF, hts_get_version_info(opt)); fprintf(fp, "and is used for updating this website." LF); fprintf(fp, "(The HTML website structure is stored here to allow fast updates)" LF "" LF); fprintf(fp, "DO NOT delete this folder unless you do not want to update the mirror in the future!!" LF); fprintf(fp, "(you can safely delete old.zip and old.lst files, however)" LF); fprintf(fp, "" LF); fprintf(fp, HTS_LOG_SECURITY_WARNING); fclose(fp); } } strcpybuff(n_lock, fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-in_progress.lock")); //sprintf(n_lock,fconcat(OPT_GET_BUFF(opt), StringBuff(opt->path_log),"hts-in_progress.lock"),n); /*do { if (!n) sprintf(n_lock,fconcat(OPT_GET_BUFF(opt), StringBuff(opt->path_log),"hts-in_progress.lock"),n); else sprintf(n_lock,fconcat(OPT_GET_BUFF(opt), StringBuff(opt->path_log),"hts-in_progress%d.lock"),n); n++; } while((fexist(n_lock)) && opt->quiet); if (fexist(n_lock)) { if (!recuperer) { remove(n_lock); } } */ // vérifier existence de la structure structcheck(fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_html), "/")); structcheck(fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "/")); // reprise/update if (opt->cache) { FILE *fp; int i; #ifdef _WIN32 mkdir(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache")); #else mkdir(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache"), HTS_PROTECT_FOLDER); #endif fp = fopen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/doit.log"), "wb"); if (fp) { for(i = 0 + 1; i < argc; i++) { if (((strchr(argv[i], ' ') != NULL) || (strchr(argv[i], '"') != NULL) || (strchr(argv[i], '\\') != NULL)) && (argv[i][0] != '"')) { size_t j; fprintf(fp, "\""); for(j = 0; argv[i][j] != '\0'; j++) { if (argv[i][j] == 34) fprintf(fp, "\\\""); else if (argv[i][j] == '\\') fprintf(fp, "\\\\"); else fprintf(fp, "%c", argv[i][j]); } fprintf(fp, "\""); } else if (strnotempty(argv[i]) == 0) { // "" fprintf(fp, "\"\""); } else { // non critique fprintf(fp, "%s", argv[i]); } if (i < argc - 1) fprintf(fp, " "); } fprintf(fp, LF); fprintf(fp, "File generated automatically on %s, do NOT edit" LF, t); fprintf(fp, LF); fprintf(fp, "To update a mirror, just launch httrack without any parameters" LF); fprintf(fp, "The existing cache will be used (and modified)" LF); fprintf(fp, "To have other options, retype all parameters and launch HTTrack" LF); fprintf(fp, "To continue an interrupted mirror, just launch httrack without any parameters" LF); fprintf(fp, LF); fclose(fp); fp = NULL; //} else if (opt->debug>1) { // printf("! FileOpen error, \"%s\"\n",strerror(errno)); } } // petit message dans le lock if ((fp = fopen(n_lock, "wb")) != NULL) { int i; fprintf(fp, "Mirror in progress since %s .. please wait!" LF, t); for(i = 0; i < argc; i++) { if (strchr(argv[i], ' ') == NULL) fprintf(fp, "%s ", argv[i]); else // entre "" fprintf(fp, "\"%s\" ", argv[i]); } fprintf(fp, LF); fprintf(fp, "To pause the engine: create an empty file named 'hts-stop.lock'" LF); #if USE_BEGINTHREAD fprintf(fp, "PID=%d\n", (int) getpid()); #ifndef _WIN32 fprintf(fp, "UID=%d\n", (int) getuid()); fprintf(fp, "GID=%d\n", (int) getuid()); #endif fprintf(fp, "START=%d\n", (int) time(NULL)); #endif fclose(fp); fp = NULL; } // fichier log if (opt->log) { int i; fprintf(opt->log, "HTTrack" HTTRACK_VERSION "%s launched on %s at %s" LF, hts_get_version_info(opt), t, url); fprintf(opt->log, "("); for(i = 0; i < argc; i++) { #ifdef _WIN32 char *carg = hts_convertStringSystemToUTF8(argv[i], (int) strlen(argv[i])); char *arg = carg != NULL ? carg : argv[i]; #else const char *arg = argv[i]; #endif if (strchr(arg, ' ') == NULL || strchr(arg, '\"') != NULL) fprintf(opt->log, "%s ", arg); else // entre "" (si espace(s) et pas déja de ") fprintf(opt->log, "\"%s\" ", arg); #ifdef _WIN32 if (carg != NULL) free(carg); #endif } fprintf(opt->log, ")" LF); fprintf(opt->log, LF); fprintf(opt->log, "Information, Warnings and Errors reported for this mirror:" LF); fprintf(opt->log, HTS_LOG_SECURITY_WARNING); fprintf(opt->log, LF); } if (httrack_logmode) { printf("Mirror launched on %s by HTTrack Website Copier/" HTTRACK_VERSION "%s " HTTRACK_AFF_AUTHORS "" LF, t, hts_get_version_info(opt)); if (opt->wizard == 0) { printf ("mirroring %s with %d levels, %d sockets,t=%d,s=%d,logm=%d,lnk=%d,mdg=%d\n", url, opt->depth, opt->maxsoc, opt->travel, opt->seeker, httrack_logmode, opt->urlmode, opt->getmode); } else { // the magic wizard printf("mirroring %s with the wizard help..\n", url); } } } io_flush; /* Enforce limits to avoid bandwidth abuse. The bypass_limits should only be used by administrators and experts. */ if (!opt->bypass_limits) { if (opt->maxsoc <= 0 || opt->maxsoc > 8) { opt->maxsoc = 8; hts_log_print(opt, LOG_WARNING, "* security warning: maximum number of simultaneous connections limited to %d to avoid server overload", (int) opt->maxsoc); } if (opt->maxrate <= 0 || opt->maxrate > 10000000) { opt->maxrate = 10000000; hts_log_print(opt, LOG_WARNING, "* security warning: maximum bandwidth limited to %d to avoid server overload", (int) opt->maxrate); } if (opt->maxconn <= 0 || opt->maxconn > 5.0) { opt->maxconn = 5.0; hts_log_print(opt, LOG_WARNING, "* security warning: maximum number of connections per second limited to %f to avoid server overload", (float) opt->maxconn); } } else { hts_log_print(opt, LOG_WARNING, "* security warning: !!! BYPASSING SECURITY LIMITS - MONITOR THIS SESSION WITH EXTREME CARE !!!"); } /* Info for wrappers */ hts_log_print(opt, LOG_DEBUG, "engine: init"); /* Init external */ RUN_CALLBACK_NOARG(opt, init); // détourner SIGHUP etc. #if DEBUG_STEPS printf("Launching the mirror\n"); #endif // Lancement du miroir // ------------------------------------------------------------ opt->state._hts_in_mirror = 1; if (httpmirror(url, opt) == 0) { printf ("Error during operation (see log file), site has not been successfully mirrored\n"); } else { if (opt->shell) { HTT_REQUEST_START; HT_PRINT("TRANSFER DONE" LF); HTT_REQUEST_END} else { printf("Done.\n"); } } opt->state._hts_in_mirror = 0; // ------------------------------------------------------------ // // Build top index if (opt->dir_topindex) { char BIGSTK rpath[1024 * 2]; char *a; strcpybuff(rpath, StringBuff(opt->path_html)); if (rpath[0]) { if (rpath[strlen(rpath) - 1] == '/') rpath[strlen(rpath) - 1] = '\0'; } a = strrchr(rpath, '/'); if (a) { *a = '\0'; hts_buildtopindex(opt, rpath, StringBuff(opt->path_bin)); hts_log_print(opt, LOG_INFO, "Top index rebuilt (done)"); } } if (opt->state.exit_xh == 1) { if (opt->log) { fprintf(opt->log, "* * MIRROR ABORTED! * *\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\nThis can easily be done here by erasing the hts-cache/new.* files]\n"); } } /* Not or cleanly interrupted; erase hts-cache/ref temporary directory */ if (opt->state.exit_xh == 0) { // erase ref files if not interrupted DIR *dir; struct dirent *entry; for(dir = opendir(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), CACHE_REFNAME)); dir != NULL && (entry = readdir(dir)) != NULL;) { if (entry->d_name[0] != '\0' && entry->d_name[0] != '.') { char *f = OPT_GET_BUFF(opt); sprintf(f, "%s/%s", CACHE_REFNAME, entry->d_name); (void) unlink(fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), f)); } } if (dir != NULL) { (void) closedir(dir); } (void) rmdir(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), CACHE_REFNAME)); } /* Info for wrappers */ hts_log_print(opt, LOG_DEBUG, "engine: free"); /* UnInit */ RUN_CALLBACK_NOARG(opt, uninit); if (httrack_logmode != 1) { if (opt->errlog == opt->log) opt->errlog = NULL; if (opt->log) { fclose(opt->log); opt->log = NULL; } if (opt->errlog) { fclose(opt->errlog); opt->errlog = NULL; } } // Débuggage des en têtes if (_DEBUG_HEAD) { if (ioinfo) { fclose(ioinfo); } } // supprimer lock remove(n_lock); } if (x_argvblk) freet(x_argvblk); if (x_argv) freet(x_argv); if (url) freet(url); #ifdef HTS_TRACE_MALLOC hts_freeall(); #endif printf("Thanks for using HTTrack!\n"); io_flush; htsmain_free(); return 0; // OK } // main() subroutines // vérifier chemin path int check_path(String * s, char *defaultname) { int i; int return_value = 0; // Replace name: ~/mywebsites/# -> /home/foo/mywebsites/# expand_home(s); for(i = 0; i < (int) StringLength(*s); i++) // conversion \ -> / if (StringSub(*s, i) == '\\') StringSubRW(*s, i) = '/'; // remove ending / if (StringNotEmpty(*s) && StringRight(*s, 1) == '/') StringPopRight(*s); // Replace name: /home/foo/mywebsites/# -> /home/foo/mywebsites/wonderfulsite if (StringNotEmpty(*s)) { if (StringRight(*s, 1) == '#') { if (strnotempty((defaultname ? defaultname : ""))) { char *a = strchr(defaultname, '#'); // we never know.. if (a) *a = '\0'; StringPopRight(*s); StringCat(*s, defaultname); } else { StringClear(*s); // Clear path (no name/default url given) } return_value = 1; // expanded } } // ending / if (StringNotEmpty(*s) && StringRight(*s, 1) != '/') // ajouter slash à la fin StringCat(*s, "/"); return return_value; } // détermine si l'argument est une option int cmdl_opt(char *s) { if (s[0] == '-') { // c'est peut être une option if (strchr(s, '.') != NULL && strchr(s, '%') == NULL) return 0; // sans doute un -www.truc.fr (note: -www n'est pas compris) else if (strchr(s, '/') != NULL) return 0; // idem, -*cgi-bin/ else if (strchr(s, '*') != NULL) return 0; // joker, idem else return 1; } else return 0; } httrack-3.49.5/src/htslib.c0000644000175000017500000051720614360553246012440 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Subroutines */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* Internal engine bytecode */ #define HTS_INTERNAL_BYTECODE // Fichier librairie .c #include "htscore.h" /* specific definitions */ #include "htsbase.h" #include "htsnet.h" #include "htsbauth.h" #include "htsthread.h" #include "htsback.h" #include "htswrap.h" #include "htsmd5.h" #include "htsmodules.h" #include "htscharset.h" #include "htsencoding.h" #ifdef _WIN32 #include #else #ifdef HAVE_SYS_TYPES_H #include #endif #ifdef HAVE_SYS_STAT_H #include #endif #ifdef HAVE_UNISTD_H #include #endif #endif /* _WIN32 */ #include #include #include #include #ifndef _WIN32 #include #else #include #endif #include // pour utimbuf #ifdef _WIN32 #include #else #include #endif /* _WIN32 */ #include #ifdef __ANDROID__ #define timezone 0 #endif /* END specific definitions */ /* Windows might be missing va_copy */ #ifdef _WIN32 #ifndef va_copy #define va_copy(dst, src) ((dst) = (src)) #endif #endif // Debugging #if _HTS_WIDE FILE *DEBUG_fp = NULL; #endif /* variables globales */ int _DEBUG_HEAD; FILE *ioinfo; #if HTS_USEOPENSSL SSL_CTX *openssl_ctx = NULL; #endif int IPV6_resolver = 0; /* détection complémentaire */ const char *hts_detect[] = { "archive", "background", "data", // OBJECT "data-src", "data-srcset", "dynsrc", "lowsrc", "profile", // element META "src", "swurl", "url", "usemap", "longdesc", // accessibility "xlink:href", // xml/svg tag "poster", // HTML5 "" }; /* détecter début */ const char *hts_detectbeg[] = { "hotspot", /* hotspot1=..,hotspot2=.. */ "" }; /* ne pas détcter de liens dedans */ const char *hts_nodetect[] = { "accept-charset", "accesskey", "action", "align", "alt", "axes", "axis", "char", "charset", "cite", "class", "classid", "code", "color", "datetime", "dir", "enctype", "face", "height", "id", "lang", "language", "media", "method", "name", "prompt", "scheme", "size", "style", "target", "title", "type", "valign", "version", "width", "" }; /* détection de mini-code javascript */ /* ALSO USED: detection based on the name: onXXX="" where XXX starts with upper case letter */ const char *hts_detect_js[] = { "onAbort", "onBlur", "onChange", "onClick", "onDblClick", "onDragDrop", "onError", "onFocus", "onKeyDown", "onKeyPress", "onKeyUp", "onLoad", "onMouseDown", "onMouseMove", "onMouseOut", "onMouseOver", "onMouseUp", "onMove", "onReset", "onResize", "onSelect", "onSubmit", "onUnload", "style", /* hack for CSS code data */ "" }; const char *hts_main_mime[] = { "application", "audio", "image", "message", "multipart", "text", "video", "" }; /* détection "...URL=" */ const char *hts_detectURL[] = { "content", "" }; /* tags où l'URL doit être réécrite mais non capturée */ const char *hts_detectandleave[] = { "action", "" }; /* ne pas renommer les types renvoyés (souvent types inconnus) */ const char *hts_mime_keep[] = { "application/octet-stream", "text/plain", "application/xml", "text/xml", "" }; /* bogus servers returns these mime types when the extension is seen within the filename */ const char *hts_mime_bogus_multiple[] = { "application/x-wais-source", /* src (src.rpm) */ "" }; /* pas de type mime connu, mais extension connue */ const char *hts_ext_dynamic[] = { "php3", "php", "php4", "php2", "cgi", "asp", "jsp", "pl", /*"exe", */ "cfm", "nsf", /* lotus */ "" }; /* types MIME note: application/octet-stream should not be used here */ const char *hts_mime[][2] = { {"application/acad", "dwg"}, {"application/arj", "arj"}, {"application/clariscad", "ccad"}, {"application/drafting", "drw"}, {"application/dxf", "dxf"}, {"application/excel", "xls"}, {"application/i-deas", "unv"}, {"application/iges", "isg"}, {"application/iges", "iges"}, {"application/mac-binhex40", "hqx"}, {"application/mac-compactpro", "cpt"}, {"application/msword", "doc"}, {"application/msword", "w6w"}, {"application/msword", "word"}, {"application/mswrite", "wri"}, /*{"application/octet-stream","dms"}, */ /*{"application/octet-stream","lzh"}, */ /*{"application/octet-stream","lha"}, */ /*{"application/octet-stream","bin"}, */ {"application/oda", "oda"}, {"application/pdf", "pdf"}, {"application/postscript", "ps"}, {"application/postscript", "ai"}, {"application/postscript", "eps"}, {"application/powerpoint", "ppt"}, {"application/pro_eng", "prt"}, {"application/pro_eng", "part"}, {"application/rtf", "rtf"}, {"application/set", "set"}, {"application/sla", "stl"}, {"application/smil", "smi"}, {"application/smil", "smil"}, {"application/smil", "sml"}, {"application/solids", "sol"}, {"application/STEP", "stp"}, {"application/STEP", "step"}, {"application/vda", "vda"}, {"application/x-authorware-map", "aam"}, {"application/x-authorware-seg", "aas"}, {"application/x-authorware-bin", "aab"}, {"application/x-bzip2", "bz2"}, {"application/x-cocoa", "cco"}, {"application/x-csh", "csh"}, {"application/x-director", "dir"}, {"application/x-director", "dcr"}, {"application/x-director", "dxr"}, {"application/x-mif", "mif"}, {"application/x-dvi", "dvi"}, {"application/x-gzip", "gz"}, {"application/x-gzip", "gzip"}, {"application/x-hdf", "hdf"}, {"application/x-javascript", "js"}, {"application/x-koan", "skp"}, {"application/x-koan", "skd"}, {"application/x-koan", "skt"}, {"application/x-koan", "skm"}, {"application/x-latex", "latex"}, {"application/x-netcdf", "nc"}, {"application/x-netcdf", "cdf"}, /* {"application/x-sh","sh"}, */ /* {"application/x-csh","csh"}, */ /* {"application/x-ksh","ksh"}, */ {"application/x-shar", "shar"}, {"application/x-stuffit", "sit"}, {"application/x-tcl", "tcl"}, {"application/x-tex", "tex"}, {"application/x-texinfo", "texinfo"}, {"application/x-texinfo", "texi"}, {"application/x-troff", "t"}, {"application/x-troff", "tr"}, {"application/x-troff", "roff"}, {"application/x-troff-man", "man"}, {"application/x-troff-me", "ms"}, {"application/x-wais-source", "src"}, {"application/zip", "zip"}, {"application/x-zip-compressed", "zip"}, {"application/x-bcpio", "bcpio"}, {"application/x-cdlink", "vcd"}, {"application/x-cpio", "cpio"}, {"application/x-gtar", "tgz"}, {"application/x-gtar", "gtar"}, {"application/x-shar", "shar"}, {"application/x-shockwave-flash", "swf"}, {"application/x-sv4cpio", "sv4cpio"}, {"application/x-sv4crc", "sv4crc"}, {"application/x-tar", "tar"}, {"application/x-ustar", "ustar"}, {"application/x-winhelp", "hlp"}, {"application/xml", "xml"}, {"audio/midi", "mid"}, {"audio/midi", "midi"}, {"audio/midi", "kar"}, {"audio/mpeg", "mp3"}, {"audio/mpeg", "mpga"}, {"audio/mpeg", "mp2"}, {"audio/basic", "au"}, {"audio/basic", "snd"}, {"audio/x-aiff", "aif"}, {"audio/x-aiff", "aiff"}, {"audio/x-aiff", "aifc"}, {"audio/x-pn-realaudio", "rm"}, {"audio/x-pn-realaudio", "ram"}, {"audio/x-pn-realaudio", "ra"}, {"audio/x-pn-realaudio-plugin", "rpm"}, {"audio/x-wav", "wav"}, {"chemical/x-pdb", "pdb"}, {"chemical/x-pdb", "xyz"}, {"drawing/x-dwf", "dwf"}, {"image/gif", "gif"}, {"image/ief", "ief"}, {"image/jpeg", "jpg"}, {"image/jpeg", "jpe"}, {"image/jpeg", "jpeg"}, {"image/pict", "pict"}, {"image/png", "png"}, {"image/tiff", "tiff"}, {"image/tiff", "tif"}, {"image/svg+xml", "svg"}, {"image/svg-xml", "svg"}, {"image/x-cmu-raster", "ras"}, {"image/x-freehand", "fh4"}, {"image/x-freehand", "fh7"}, {"image/x-freehand", "fh5"}, {"image/x-freehand", "fhc"}, {"image/x-freehand", "fh"}, {"image/x-portable-anymap", "pnm"}, {"image/x-portable-bitmap", "pgm"}, {"image/x-portable-pixmap", "ppm"}, {"image/x-rgb", "rgb"}, {"image/x-xbitmap", "xbm"}, {"image/x-xpixmap", "xpm"}, {"image/x-xwindowdump", "xwd"}, {"model/mesh", "msh"}, {"model/mesh", "mesh"}, {"model/mesh", "silo"}, {"multipart/x-zip", "zip"}, {"multipart/x-gzip", "gzip"}, {"text/css", "css"}, {"text/html", "html"}, {"text/html", "htm"}, {"text/plain", "txt"}, {"text/plain", "g"}, {"text/plain", "h"}, {"text/plain", "c"}, {"text/plain", "cc"}, {"text/plain", "hh"}, {"text/plain", "m"}, {"text/plain", "f90"}, {"text/richtext", "rtx"}, {"text/tab-separated-values", "tsv"}, {"text/x-setext", "etx"}, {"text/x-sgml", "sgml"}, {"text/x-sgml", "sgm"}, {"text/xml", "xml"}, {"text/xml", "dtd"}, {"video/mpeg", "mpeg"}, {"video/mpeg", "mpg"}, {"video/mpeg", "mpe"}, {"video/quicktime", "qt"}, {"video/quicktime", "mov"}, {"video/x-msvideo", "avi"}, {"video/x-sgi-movie", "movie"}, {"x-conference/x-cooltalk", "ice"}, /*{"application/x-httpd-cgi","cgi"}, */ {"x-world/x-vrml", "wrl"}, /* More from w3schools.com */ {"application/envoy", "evy"}, {"application/fractals", "fif"}, {"application/futuresplash", "spl"}, {"application/hta", "hta"}, {"application/internet-property-stream", "acx"}, {"application/msword", "dot"}, {"application/olescript", "axs"}, {"application/pics-rules", "prf"}, {"application/pkcs10", "p10"}, {"application/pkix-crl", "crl"}, {"application/set-payment-initiation", "setpay"}, {"application/set-registration-initiation", "setreg"}, {"application/vnd.ms-excel", "xls"}, {"application/vnd.ms-excel", "xla"}, {"application/vnd.ms-excel", "xlc"}, {"application/vnd.ms-excel", "xlm"}, {"application/vnd.ms-excel", "xlt"}, {"application/vnd.ms-excel", "xlw"}, {"application/vnd.ms-pkicertstore", "sst"}, {"application/vnd.ms-pkiseccat", "cat"}, {"application/vnd.ms-powerpoint", "ppt"}, {"application/vnd.ms-powerpoint", "pot"}, {"application/vnd.ms-powerpoint", "pps"}, {"application/vnd.ms-project", "mpp"}, {"application/vnd.ms-works", "wcm"}, {"application/vnd.ms-works", "wdb"}, {"application/vnd.ms-works", "wks"}, {"application/vnd.ms-works", "wps"}, {"application/vnd.oasis.opendocument.chart", "odc"}, {"application/vnd.oasis.opendocument.database", "odb"}, {"application/vnd.oasis.opendocument.formula", "odf"}, {"application/vnd.oasis.opendocument.graphics", "odg"}, {"application/vnd.oasis.opendocument.graphics-template", "otg"}, {"application/vnd.oasis.opendocument.image", "odi"}, {"application/vnd.oasis.opendocument.presentation", "odp"}, {"application/vnd.oasis.opendocument.presentation-template", "otp"}, {"application/vnd.oasis.opendocument.spreadsheet", "ods"}, {"application/vnd.oasis.opendocument.spreadsheet-template", "ots"}, {"application/vnd.oasis.opendocument.text", "odt"}, {"application/vnd.oasis.opendocument.text-master", "odm"}, {"application/vnd.oasis.opendocument.text-template", "ott"}, {"application/vnd.oasis.opendocument.text-web", "oth"}, {"application/vnd.openxmlformats-officedocument.presentationml.presentation", "pptx"}, {"application/vnd.openxmlformats-officedocument.presentationml.slide", "sldx"}, {"application/vnd.openxmlformats-officedocument.presentationml.slideshow", "ppsx"}, {"application/vnd.openxmlformats-officedocument.presentationml.template", "potx"}, {"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet", "xlsx"}, {"application/vnd.openxmlformats-officedocument.spreadsheetml.template", "xltx"}, {"application/vnd.openxmlformats-officedocument.wordprocessingml.document", "docx"}, {"application/vnd.openxmlformats-officedocument.wordprocessingml.template", "dotx"}, {"application/x-compress", "z"}, {"application/x-compressed", "tgz"}, {"application/x-internet-signup", "ins"}, {"application/x-internet-signup", "isp"}, {"application/x-iphone", "iii"}, {"application/x-javascript", "js"}, {"application/x-msaccess", "mdb"}, {"application/x-mscardfile", "crd"}, {"application/x-msclip", "clp"}, {"application/x-msmediaview", "m13"}, {"application/x-msmediaview", "m14"}, {"application/x-msmediaview", "mvb"}, {"application/x-msmetafile", "wmf"}, {"application/x-msmoney", "mny"}, {"application/x-mspublisher", "pub"}, {"application/x-msschedule", "scd"}, {"application/x-msterminal", "trm"}, {"application/x-perfmon", "pma"}, {"application/x-perfmon", "pmc"}, {"application/x-perfmon", "pml"}, {"application/x-perfmon", "pmr"}, {"application/x-perfmon", "pmw"}, {"application/x-pkcs12", "p12"}, {"application/x-pkcs12", "pfx"}, {"application/x-pkcs7-certificates", "p7b"}, {"application/x-pkcs7-certificates", "spc"}, {"application/x-pkcs7-certreqresp", "p7r"}, {"application/x-pkcs7-mime", "p7c"}, {"application/x-pkcs7-mime", "p7m"}, {"application/x-pkcs7-signature", "p7s"}, {"application/x-troff-me", "me"}, {"application/x-x509-ca-cert", "cer"}, {"application/x-x509-ca-cert", "crt"}, {"application/x-x509-ca-cert", "der"}, {"application/ynd.ms-pkipko", "pko"}, {"audio/mid", "mid"}, {"audio/mid", "rmi"}, {"audio/mpeg", "mp3"}, {"audio/x-mpegurl", "m3u"}, {"image/bmp", "bmp"}, {"image/cis-cod", "cod"}, {"image/pipeg", "jfif"}, {"image/x-cmx", "cmx"}, {"image/x-icon", "ico"}, {"image/x-portable-bitmap", "pbm"}, {"message/rfc822", "mht"}, {"message/rfc822", "mhtml"}, {"message/rfc822", "nws"}, {"text/css", "css"}, {"text/h323", "323"}, {"text/html", "stm"}, {"text/iuls", "uls"}, {"text/plain", "bas"}, {"text/scriptlet", "sct"}, {"text/webviewhtml", "htt"}, {"text/x-component", "htc"}, {"text/x-vcard", "vcf"}, {"video/mpeg", "mp2"}, {"video/mpeg", "mpa"}, {"video/mpeg", "mpv2"}, {"video/x-la-asf", "lsf"}, {"video/x-la-asf", "lsx"}, {"video/x-ms-asf", "asf"}, {"video/x-ms-asf", "asr"}, {"video/x-ms-asf", "asx"}, {"video/x-ms-wmv", "wmv"}, {"x-world/x-vrml", "flr"}, {"x-world/x-vrml", "vrml"}, {"x-world/x-vrml", "wrz"}, {"x-world/x-vrml", "xaf"}, {"x-world/x-vrml", "xof"}, /* Various */ {"application/ogg", "ogg"}, {"application/x-java-vm", "class"}, {"application/x-bittorrent","torrent"}, {"", ""} }; // Reserved (RFC2396) #define CIS(c,ch) ( ((unsigned char)(c)) == (ch) ) #define CHAR_RESERVED(c) ( CIS(c,';') \ || CIS(c,'/') \ || CIS(c,'?') \ || CIS(c,':') \ || CIS(c,'@') \ || CIS(c,'&') \ || CIS(c,'=') \ || CIS(c,'+') \ || CIS(c,'$') \ || CIS(c,',') ) //#define CHAR_RESERVED(c) ( strchr(";/?:@&=+$,",(unsigned char)(c)) != 0 ) // Delimiters (RFC2396) #define CHAR_DELIM(c) ( CIS(c,'<') \ || CIS(c,'>') \ || CIS(c,'#') \ || CIS(c,'%') \ || CIS(c,'\"') ) //#define CHAR_DELIM(c) ( strchr("<>#%\"",(unsigned char)(c)) != 0 ) // Unwise (RFC2396) #define CHAR_UNWISE(c) ( CIS(c,'{') \ || CIS(c,'}') \ || CIS(c,'|') \ || CIS(c,'\\') \ || CIS(c,'^') \ || CIS(c,'[') \ || CIS(c,']') \ || CIS(c,'`') ) //#define CHAR_UNWISE(c) ( strchr("{}|\\^[]`",(unsigned char)(c)) != 0 ) // Special (escape chars) (RFC2396 + >127 ) #define CHAR_LOW(c) ( ((unsigned char)(c) <= 31) ) #define CHAR_HIG(c) ( ((unsigned char)(c) >= 127) ) #define CHAR_SPECIAL(c) ( CHAR_LOW(c) || CHAR_HIG(c) ) // We try to avoid them and encode them instead #define CHAR_XXAVOID(c) ( CIS(c,' ') \ || CIS(c,'*') \ || CIS(c,'\'') \ || CIS(c,'\"') \ || CIS(c,'&') \ || CIS(c,'!') ) //#define CHAR_XXAVOID(c) ( strchr(" *'\"!",(unsigned char)(c)) != 0 ) #define CHAR_MARK(c) ( CIS(c,'-') \ || CIS(c,'_') \ || CIS(c,'.') \ || CIS(c,'!') \ || CIS(c,'~') \ || CIS(c,'*') \ || CIS(c,'\'') \ || CIS(c,'(') \ || CIS(c,')') ) //#define CHAR_MARK(c) ( strchr("-_.!~*'()",(unsigned char)(c)) != 0 ) // conversion éventuelle / vers antislash #ifdef _WIN32 char *antislash(char *catbuff, const char *s) { char *a; strcpybuff(catbuff, s); while(a = strchr(catbuff, '/')) *a = '\\'; return catbuff; } #endif // Initialize a htsblk structure void hts_init_htsblk(htsblk * r) { memset(r, 0, sizeof(htsblk)); // effacer r->soc = INVALID_SOCKET; r->msg[0] = '\0'; r->statuscode = STATUSCODE_INVALID; r->totalsize = -1; } // ouvre une liaison http, envoie une requète GET et réceptionne le header // retour: socket T_SOC http_fopen(httrackp * opt, const char *adr, const char *fil, htsblk * retour) { // / GET, traiter en-tête return http_xfopen(opt, 0, 1, 1, NULL, adr, fil, retour); } // ouverture d'une liaison http, envoi d'une requète // mode: 0 GET 1 HEAD [2 POST] // treat: traiter header? // waitconnect: attendre le connect() // note: dans retour, on met les params du proxy T_SOC http_xfopen(httrackp * opt, int mode, int treat, int waitconnect, const char *xsend, const char *adr, const char *fil, htsblk * retour) { //htsblk retour; //int bufl=TAILLE_BUFFER; // 8Ko de buffer T_SOC soc = INVALID_SOCKET; char BIGSTK tempo_fil[HTS_URLMAXSIZE * 2]; //char *p,*q; // retour prédéfini: erreur if (retour) { retour->adr = NULL; retour->size = 0; retour->msg[0] = '\0'; retour->statuscode = STATUSCODE_NON_FATAL; // a priori erreur non fatale } #if HDEBUG printf("adr=%s\nfichier=%s\n", adr, fil); #endif // ouvrir liaison #if HDEBUG printf("Création d'une socket sur %s\n", adr); #endif #if CNXDEBUG printf("..newhttp\n"); #endif /* connexion */ if (retour) { if ((!(retour->req.proxy.active)) || ((strcmp(adr, "file://") == 0) || (strncmp(adr, "https://", 8) == 0) ) ) { /* pas de proxy, ou non utilisable ici */ soc = newhttp(opt, adr, retour, -1, waitconnect); } else { soc = newhttp(opt, retour->req.proxy.name, retour, retour->req.proxy.port, waitconnect); // ouvrir sur le proxy à la place } } else { soc = newhttp(opt, adr, NULL, -1, waitconnect); } // copier index socket retour if (retour) retour->soc = soc; /* Check for errors */ if (soc == INVALID_SOCKET) { if (retour) { if (retour->msg) { if (!strnotempty(retour->msg)) { #ifdef _WIN32 int last_errno = WSAGetLastError(); sprintf(retour->msg, "Connect error: %s", strerror(last_errno)); #else int last_errno = errno; sprintf(retour->msg, "Connect error: %s", strerror(last_errno)); #endif } } } } // -------------------- // court-circuit (court circuite aussi le proxy..) // LOCAL_SOCKET_ID est une pseudo-socket locale if (soc == LOCAL_SOCKET_ID) { retour->is_file = 1; // fichier local if (mode == 0) { // GET // Test en cas de file:///C|... if (!fexist (fconv(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), unescape_http(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), fil)))) if (fexist (fconv (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), unescape_http(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), fil + 1)))) { strcpybuff(tempo_fil, fil + 1); fil = tempo_fil; } // Ouvrir retour->totalsize = fsize(fconv(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), unescape_http(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), fil))); // taille du fichier retour->msg[0] = '\0'; soc = INVALID_SOCKET; if (retour->totalsize < 0) strcpybuff(retour->msg, "Unable to open local file"); else { // Note: On passe par un FILE* (plus propre) //soc=open(fil,O_RDONLY,0); // en lecture seule! retour->fp = FOPEN(fconv(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), unescape_http(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), fil)), "rb"); // ouvrir if (retour->fp == NULL) soc = INVALID_SOCKET; else soc = LOCAL_SOCKET_ID; } retour->soc = soc; if (soc != INVALID_SOCKET) { retour->statuscode = HTTP_OK; // OK strcpybuff(retour->msg, "OK"); guess_httptype(opt, retour->contenttype, fil); } else if (strnotempty(retour->msg) == 0) strcpybuff(retour->msg, "Unable to open local file"); return soc; // renvoyer } else { // HEAD ou POST : interdit sur un local!!!! (c'est idiot!) strcpybuff(retour->msg, "Unexpected Head/Post local request"); soc = INVALID_SOCKET; // erreur retour->soc = soc; return soc; } } // -------------------- if (soc != INVALID_SOCKET) { char rcvd[1100]; rcvd[0] = '\0'; #if HDEBUG printf("Ok, connexion réussie, id=%d\n", soc); #endif // connecté? if (waitconnect) { http_sendhead(opt, NULL, mode, xsend, adr, fil, NULL, NULL, retour); } if (soc != INVALID_SOCKET) { #if HDEBUG printf("Attente de la réponse:\n"); #endif // si GET (réception d'un fichier), réceptionner en-tête d'abord, // et ensuite le corps // si POST on ne réceptionne rien du tout, c'est après que l'on fera // une réception standard pour récupérer l'en tête if ((treat) && (waitconnect)) { // traiter (attendre!) en-tête // Réception de la status line et de l'en-tête (norme RFC1945) // status-line à récupérer finput(soc, rcvd, 1024); if (strnotempty(rcvd) == 0) finput(soc, rcvd, 1024); // "certains serveurs buggés envoient un \n au début" (RFC) // traiter status-line treatfirstline(retour, rcvd); #if HDEBUG printf("Status-Code=%d\n", retour->statuscode); #endif // en-tête // header // ** !attention! HTTP/0.9 non supporté do { finput(soc, rcvd, 1024); #if HDEBUG printf(">%s\n", rcvd); #endif if (strnotempty(rcvd)) treathead(NULL, NULL, NULL, retour, rcvd); // traiter } while(strnotempty(rcvd)); //rcvsize=-1; // forCER CHARGEMENT INCONNU //if (retour) // retour->totalsize=rcvsize; } else { // si GET, on recevra l'en tête APRES //rcvsize=-1; // on ne connait pas la taille de l'en-tête if (retour) retour->totalsize = -1; } } } return soc; } /* Buffer printing */ typedef struct buff_struct { /** Buffer **/ char *buffer; /** Buffer capacity in bytes **/ size_t capacity; /** Buffer write position ; MUST point to a valid \0. **/ size_t pos; } buff_struct; static void print_buffer(buff_struct*const str, const char *format, ...) HTS_PRINTF_FUN(2, 3); /* Prints on a static buffer. asserts in case of overflow. */ static void print_buffer(buff_struct*const str, const char *format, ...) { size_t result; va_list args; size_t remaining; char *position; /* Security check. */ assertf(str != NULL); assertf(str->pos < str->capacity); /* Print */ position = &str->buffer[str->pos]; remaining = str->capacity - str->pos; va_start(args, format); result = (size_t) vsnprintf(position, remaining, format, args); va_end(args); assertf(result < remaining); /* Increment. */ str->pos += strlen(position); assertf(str->pos < str->capacity); } // envoi d'une requète int http_sendhead(httrackp * opt, t_cookie * cookie, int mode, const char *xsend, const char *adr, const char *fil, const char *referer_adr, const char *referer_fil, htsblk * retour) { char BIGSTK buffer_head_request[8192]; buff_struct bstr = { buffer_head_request, sizeof(buffer_head_request), 0 }; //int use_11=0; // HTTP 1.1 utilisé int direct_url = 0; // ne pas analyser l'url (exemple: ftp://) const char *search_tag = NULL; // Initialize buffer buffer_head_request[0] = '\0'; // header Date //strcatbuff(buff,"Date: "); //time_gmt_rfc822(buff); // obtenir l'heure au format rfc822 //sendc("\n"); //strcatbuff(buff,buff); // possibilité non documentée: >post: et >postfile: // si présence d'un tag >post: alors executer un POST // exemple: http://www.someweb.com/test.cgi?foo>post:posteddata=10&foo=5 // si présence d'un tag >postfile: alors envoyer en tête brut contenu dans le fichier en question // exemple: http://www.someweb.com/test.cgi?foo>postfile:post0.txt search_tag = strstr(fil, POSTTOK ":"); if (!search_tag) { search_tag = strstr(fil, POSTTOK "file:"); if (search_tag) { // postfile if (mode == 0) { // GET! FILE *fp = FOPEN(unescape_http(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), search_tag + strlen(POSTTOK) + 5), "rb"); if (fp) { char BIGSTK line[1100]; char BIGSTK protocol[256], url[HTS_URLMAXSIZE * 2], method[256]; linput(fp, line, 1000); if (sscanf(line, "%s %s %s", method, url, protocol) == 3) { size_t ret; // selon que l'on a ou pas un proxy if (retour->req.proxy.active) { print_buffer(&bstr, "%s http://%s%s %s\r\n", method, adr, url, protocol); } else { print_buffer(&bstr, "%s %s %s\r\n", method, url, protocol); } // lire le reste en brut ret = fread(&bstr.buffer[bstr.pos], bstr.capacity - bstr.pos, 1, fp); if ((int) ret < 0) { return -1; } bstr.pos += strlen(&bstr.buffer[bstr.pos]); } fclose(fp); } } } } // Fin postfile if (bstr.pos == 0) { // PAS POSTFILE // Type de requète? if ((search_tag) && (mode == 0)) { print_buffer(&bstr, "POST "); } else if (mode == 0) { // GET print_buffer(&bstr, "GET "); } else { // if (mode==1) { if (!retour->req.http11) // forcer HTTP/1.0 print_buffer(&bstr, "GET "); // certains serveurs (cgi) buggent avec HEAD else print_buffer(&bstr, "HEAD "); } // si on gère un proxy, il faut une Absolute URI: on ajoute avant http://www.adr.dom if (retour->req.proxy.active && (strncmp(adr, "https://", 8) != 0)) { if (!link_has_authority(adr)) { // default http #if HDEBUG printf("Proxy Use: for %s%s proxy %d port %d\n", adr, fil, retour->req.proxy.name, retour->req.proxy.port); #endif print_buffer(&bstr, "http://%s", jump_identification_const(adr)); } else { // ftp:// en proxy http #if HDEBUG printf("Proxy Use for ftp: for %s%s proxy %d port %d\n", adr, fil, retour->req.proxy.name, retour->req.proxy.port); #endif direct_url = 1; // ne pas analyser user/pass print_buffer(&bstr, "%s", adr); } } // NOM DU FICHIER // on slash doit être présent en début, sinon attention aux bad request! (400) if (*fil != '/') print_buffer(&bstr, "/"); { char BIGSTK tempo[HTS_URLMAXSIZE * 2]; tempo[0] = '\0'; if (search_tag) strncatbuff(tempo, fil, (int) (search_tag - fil)); else strcpybuff(tempo, fil); inplace_escape_check_url(tempo, sizeof(tempo)); print_buffer(&bstr, "%s", tempo); // avec échappement } // protocole if (!retour->req.http11) { // forcer HTTP/1.0 //use_11=0; print_buffer(&bstr, " HTTP/1.0\x0d\x0a"); } else { // Requète 1.1 //use_11=1; print_buffer(&bstr, " HTTP/1.1\x0d\x0a"); } /* supplemental data */ if (xsend) print_buffer(&bstr, "%s", xsend); // éventuelles autres lignes // tester proxy authentication if (retour->req.proxy.active) { if (link_has_authorization(retour->req.proxy.name)) { // et hop, authentification proxy! const char *a = jump_identification_const(retour->req.proxy.name); const char *astart = jump_protocol_const(retour->req.proxy.name); char autorisation[1100]; char user_pass[256]; autorisation[0] = user_pass[0] = '\0'; // strncatbuff(user_pass, astart, (int) (a - astart) - 1); strcpybuff(user_pass, unescape_http(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), user_pass)); code64((unsigned char *) user_pass, (int) strlen(user_pass), (unsigned char *) autorisation, 0); print_buffer(&bstr, "Proxy-Authorization: Basic %s"H_CRLF, autorisation); #if HDEBUG printf("Proxy-Authenticate, %s (code: %s)\n", user_pass, autorisation); #endif } } // Referer? if (referer_adr != NULL && referer_fil != NULL && strnotempty(referer_adr) && strnotempty(referer_fil) ) { // non vide if ((strcmp(referer_adr, "file://") != 0) && ( /* no https referer to http urls */ (strncmp(referer_adr, "https://", 8) != 0) /* referer is not https */ ||(strncmp(adr, "https://", 8) == 0) /* or referer AND addresses are https */ ) ) { // PAS file:// print_buffer(&bstr, "Referer: http://%s%s"H_CRLF, jump_identification_const(referer_adr), referer_fil); } } // HTTP field: referer else if (strnotempty(retour->req.referer)) { print_buffer(&bstr, "Referer: %s"H_CRLF, retour->req.referer); } // POST? if (mode == 0) { // GET! if (search_tag) { print_buffer(&bstr, "Content-length: %d" H_CRLF, (int) (strlen (unescape_http (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), search_tag + strlen(POSTTOK) + 1)))); } } // gestion cookies? if (cookie) { char buffer[8192]; char *b = cookie->data; int cook = 0; int max_cookies = 8; do { b = cookie_find(b, "", jump_identification_const(adr), fil); // prochain cookie satisfaisant aux conditions if (b != NULL) { max_cookies--; if (!cook) { print_buffer(&bstr, "Cookie: $Version=1; "); cook = 1; } else print_buffer(&bstr, "; "); print_buffer(&bstr, "%s", cookie_get(buffer, b, 5)); print_buffer(&bstr, "=%s", cookie_get(buffer, b, 6)); print_buffer(&bstr, "; $Path=%s", cookie_get(buffer, b, 2)); b = cookie_nextfield(b); } } while(b != NULL && max_cookies > 0); if (cook) { // on a envoyé un (ou plusieurs) cookie? print_buffer(&bstr, H_CRLF); #if DEBUG_COOK printf("Header:\n%s\n", bstr.buffer); #endif } } // gérer le keep-alive (garder socket) if (retour->req.http11 && !retour->req.nokeepalive) { print_buffer(&bstr, "Connection: keep-alive" H_CRLF); } else { print_buffer(&bstr, "Connection: close" H_CRLF); } { const char *real_adr = jump_identification_const(adr); // Mandatory per RFC2616 if (!direct_url) { // pas ftp:// par exemple print_buffer(&bstr, "Host: %s"H_CRLF, real_adr); } // HTTP field: from if (strnotempty(retour->req.from)) { // HTTP from print_buffer(&bstr, "From: %s" H_CRLF, retour->req.from); } // Présence d'un user-agent? if (retour->req.user_agent_send && strnotempty(retour->req.user_agent)) { print_buffer(&bstr, "User-Agent: %s" H_CRLF, retour->req.user_agent); } // Accept if (strnotempty(retour->req.accept)) { print_buffer(&bstr, "Accept: %s" H_CRLF, retour->req.accept); } // Accept-language if (strnotempty(retour->req.lang_iso)) { print_buffer(&bstr, "Accept-Language: %s"H_CRLF, retour->req.lang_iso); } // Compression accepted ? if (retour->req.http11) { #if HTS_USEZLIB if ((!retour->req.range_used) && (!retour->req.nocompression)) print_buffer(&bstr, "Accept-Encoding: " "gzip" /* gzip if the preffered encoding */ ", " "identity;q=0.9" H_CRLF); else print_buffer(&bstr, "Accept-Encoding: identity" H_CRLF); /* no compression */ #else print_buffer(&bstr, "Accept-Encoding: identity" H_CRLF); /* no compression */ #endif } /* Authentification */ { char autorisation[1100]; const char *a; autorisation[0] = '\0'; if (link_has_authorization(adr)) { // ohh une authentification! const char *a = jump_identification_const(adr); const char *astart = jump_protocol_const(adr); if (!direct_url) { // pas ftp:// par exemple char user_pass[256]; user_pass[0] = '\0'; strncatbuff(user_pass, astart, (int) (a - astart) - 1); strcpybuff(user_pass, unescape_http(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), user_pass)); code64((unsigned char *) user_pass, (int) strlen(user_pass), (unsigned char *) autorisation, 0); if (strcmp(fil, "/robots.txt")) /* pas robots.txt */ bauth_add(cookie, astart, fil, autorisation); } } else if ((a = bauth_check(cookie, real_adr, fil))) strcpybuff(autorisation, a); /* On a une autorisation a donner? */ if (strnotempty(autorisation)) { print_buffer(&bstr, "Authorization: Basic %s"H_CRLF, autorisation); } } } //strcatbuff(buff,"Accept-Charset: iso-8859-1,*,utf-8\n"); // Custom header(s) if (strnotempty(retour->req.headers)) { print_buffer(&bstr, "%s", retour->req.headers); } // CRLF de fin d'en tête print_buffer(&bstr, H_CRLF); // données complémentaires? if (search_tag) if (mode == 0) // GET! print_buffer(&bstr, "%s", unescape_http(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), search_tag + strlen(POSTTOK) + 1)); } #if HDEBUG #endif if (_DEBUG_HEAD) { if (ioinfo) { fprintf(ioinfo, "[%d] request for %s%s:\r\n", retour->debugid, jump_identification_const(adr), fil); fprintfio(ioinfo, bstr.buffer, "<<< "); fprintf(ioinfo, "\r\n"); fflush(ioinfo); } } // Fin test pas postfile // // Callback { int test_head = RUN_CALLBACK6(opt, sendhead, bstr.buffer, adr, fil, referer_adr, referer_fil, retour); if (test_head != 1) { deletesoc_r(retour); strcpybuff(retour->msg, "Header refused by external wrapper"); retour->soc = INVALID_SOCKET; } } // Envoi HTS_STAT.last_request = mtime_local(); if (sendc(retour, bstr.buffer) < 0) { // ERREUR, socket rompue?... deletesoc_r(retour); // fermer tout de même // et tenter de reconnecter strcpybuff(retour->msg, "Write error"); retour->soc = INVALID_SOCKET; } // RX'98 return 0; } // traiter 1ere ligne d'en tête void treatfirstline(htsblk * retour, const char *rcvd) { const char *a = rcvd; // exemple: // HTTP/1.0 200 OK if (*a) { // note: certains serveurs buggés renvoient HTTP/1.0\n200 OK ou " HTTP/1.0 200 OK" while((*a == ' ') || (*a == 10) || (*a == 13) || (*a == 9)) a++; // épurer espaces au début if (strfield(a, "HTTP/")) { // sauter HTTP/1.x while((*a != ' ') && (*a != '\0') && (*a != 10) && (*a != 13) && (*a != 9)) a++; if (*a != '\0') { while((*a == ' ') || (*a == 10) || (*a == 13) || (*a == 9)) a++; // épurer espaces if ((*a >= '0') && (*a <= '9')) { sscanf(a, "%d", &(retour->statuscode)); // sauter 200 while((*a != ' ') && (*a != '\0') && (*a != 10) && (*a != 13) && (*a != 9)) a++; while((*a == ' ') || (*a == 10) || (*a == 13) || (*a == 9)) a++; // épurer espaces if ((strlen(a) > 1) && (strlen(a) < 64)) // message retour strcpybuff(retour->msg, a); else infostatuscode(retour->msg, retour->statuscode); // type MIME par défaut2 strcpybuff(retour->contenttype, HTS_HYPERTEXT_DEFAULT_MIME); } else { // pas de code! retour->statuscode = STATUSCODE_INVALID; strcpybuff(retour->msg, "Unknown response structure"); } } else { // euhh?? retour->statuscode = STATUSCODE_INVALID; strcpybuff(retour->msg, "Unknown response structure"); } } else { if (*a == '<') { /* This is dirty .. */ retour->statuscode = HTTP_OK; retour->keep_alive = 0; strcpybuff(retour->msg, "Unknown, assuming junky server"); strcpybuff(retour->contenttype, HTS_HYPERTEXT_DEFAULT_MIME); } else if (strnotempty(a)) { retour->statuscode = STATUSCODE_INVALID; strcpybuff(retour->msg, "Unknown (not HTTP/xx) response structure"); } else { /* This is dirty .. */ retour->statuscode = HTTP_OK; retour->keep_alive = 0; strcpybuff(retour->msg, "Unknown, assuming junky server"); strcpybuff(retour->contenttype, HTS_HYPERTEXT_DEFAULT_MIME); } } } else { // vide! /* retour->statuscode=STATUSCODE_INVALID; strcpybuff(retour->msg,"Empty reponse or internal error"); */ /* This is dirty .. */ retour->statuscode = HTTP_OK; strcpybuff(retour->msg, "Unknown, assuming junky server"); strcpybuff(retour->contenttype, HTS_HYPERTEXT_DEFAULT_MIME); } } // traiter ligne par ligne l'en tête // gestion des cookies void treathead(t_cookie * cookie, const char *adr, const char *fil, htsblk * retour, char *rcvd) { int p; if ((p = strfield(rcvd, "Content-length:")) != 0) { #if HDEBUG printf("ok, Content-length: détecté\n"); #endif if (sscanf(rcvd + p, LLintP, &(retour->totalsize)) == 1) { if (retour->totalsize == 0) { retour->empty = 1; } } } else if ((p = strfield(rcvd, "Content-Disposition:")) != 0) { while(is_realspace(*(rcvd + p))) p++; // sauter espaces if ((int) strlen(rcvd + p) < 250) { // pas trop long? char tmp[256]; char *a = NULL, *b = NULL; strcpybuff(tmp, rcvd + p); a = strstr(tmp, "filename="); if (a) { a += strlen("filename="); while(is_space(*a)) a++; //a=strchr(a,'"'); if (a) { char *c = NULL; //a++; /* jump " */ while((c = strchr(a, '/'))) /* skip all / (see RFC2616) */ a = c + 1; //b=strchr(a+1,'"'); b = a + strlen(a) - 1; while(is_space(*b)) b--; b++; if (b) { *b = '\0'; if ((int) strlen(a) < 200) { // pas trop long? strcpybuff(retour->cdispo, a); } } } } } } else if ((p = strfield(rcvd, "Last-Modified:")) != 0) { while(is_realspace(*(rcvd + p))) p++; // sauter espaces if ((int) strlen(rcvd + p) < 64) { // pas trop long? //struct tm* tm_time=convert_time_rfc822(rcvd+p); strcpybuff(retour->lastmodified, rcvd + p); } } else if ((p = strfield(rcvd, "Date:")) != 0) { if (strnotempty(retour->lastmodified) == 0) { /* pas encore de last-modified */ while(is_realspace(*(rcvd + p))) p++; // sauter espaces if ((int) strlen(rcvd + p) < 64) { // pas trop long? //struct tm* tm_time=convert_time_rfc822(rcvd+p); strcpybuff(retour->lastmodified, rcvd + p); } } } else if ((p = strfield(rcvd, "Etag:")) != 0) { /* Etag */ if (retour) { while(is_realspace(*(rcvd + p))) p++; // sauter espaces if ((int) strlen(rcvd + p) < 64) // pas trop long? strcpybuff(retour->etag, rcvd + p); else // erreur.. ignorer retour->etag[0] = '\0'; } } // else if ((p=strfield(rcvd,"Transfer-Encoding: chunked"))!=0) { // chunk! else if ((p = strfield(rcvd, "Transfer-Encoding:")) != 0) { // chunk! while(is_realspace(*(rcvd + p))) p++; // sauter espaces if (strfield(rcvd + p, "chunked")) { retour->is_chunk = 1; // chunked //retour->http11=2; // chunked #if HDEBUG printf("ok, Transfer-Encoding: détecté\n"); #endif } } else if ((p = strfield(rcvd, "Content-type:")) != 0) { if (retour) { char tempo[1100]; // éviter les text/html; charset=foo { char *a = strchr(rcvd + p, ';'); if (a) { // extended information *a = '\0'; a++; while(is_space(*a)) a++; if (strfield(a, "charset")) { a += 7; while(is_space(*a)) a++; if (*a == '=') { a++; while(is_space(*a)) a++; if (*a == '\"') a++; while(is_space(*a)) a++; if (*a) { char *chs = a; while(*a && !is_space(*a) && *a != '\"' && *a != ';') a++; *a = '\0'; if (*chs) { if (strlen(chs) < sizeof(retour->charset) - 2) { strcpybuff(retour->charset, chs); } } } } } } } sscanf(rcvd + p, "%s", tempo); if (strlen(tempo) < sizeof(retour->contenttype) - 2) // pas trop long!! strcpybuff(retour->contenttype, tempo); else strcpybuff(retour->contenttype, "application/octet-stream-unknown"); // erreur } } else if ((p = strfield(rcvd, "Content-Range:")) != 0) { // Content-Range: bytes 0-70870/70871 const char *a; for(a = rcvd + p; is_space(*a); a++) ; if (strncasecmp(a, "bytes ", 6) == 0) { for(a += 6; is_space(*a); a++) ; if (sscanf (a, LLintP "-" LLintP "/" LLintP, &retour->crange_start, &retour->crange_end, &retour->crange) != 3) { retour->crange_start = 0; retour->crange_end = 0; retour->crange = 0; a = strchr(rcvd + p, '/'); if (a != NULL) { a++; if (sscanf(a, LLintP, &retour->crange) == 1) { retour->crange_start = 0; retour->crange_end = retour->crange - 1; } else { retour->crange = 0; } } } } } else if ((p = strfield(rcvd, "Connection:")) != 0) { char *a = rcvd + p; while(is_space(*a)) a++; if (*a) { if (strfield(a, "Keep-Alive")) { if (!retour->keep_alive) { retour->keep_alive_max = 10; retour->keep_alive_t = 15; } retour->keep_alive = 1; } else { retour->keep_alive = 0; } } } else if ((p = strfield(rcvd, "Keep-Alive:")) != 0) { char *a = rcvd + p; while(is_space(*a)) a++; if (*a) { char *p; retour->keep_alive = 1; retour->keep_alive_max = 10; retour->keep_alive_t = 15; if ((p = strstr(a, "timeout="))) { p += strlen("timeout="); sscanf(p, "%d", &retour->keep_alive_t); } if ((p = strstr(a, "max="))) { p += strlen("max="); sscanf(p, "%d", &retour->keep_alive_max); } if (retour->keep_alive_max <= 1 || retour->keep_alive_t < 1) { retour->keep_alive = 0; } } } else if ((p = strfield(rcvd, "TE:")) != 0) { char *a = rcvd + p; while(is_space(*a)) a++; if (*a) { if (strfield(a, "trailers")) { retour->keep_alive_trailers = 1; } } } else if ((p = strfield(rcvd, "Content-Encoding:")) != 0) { if (retour) { char tempo[1100]; char *a = rcvd + p; while(is_space(*a)) a++; { char *a = strchr(rcvd + p, ';'); if (a) *a = '\0'; } sscanf(a, "%s", tempo); if (strlen(tempo) < 64) // pas trop long!! strcpybuff(retour->contentencoding, tempo); else retour->contentencoding[0] = '\0'; // erreur #if HTS_USEZLIB /* Check known encodings */ if (retour->contentencoding[0]) { if ((strfield2(retour->contentencoding, "gzip")) || (strfield2(retour->contentencoding, "x-gzip")) /* || (strfield2(retour->contentencoding, "compress")) || (strfield2(retour->contentencoding, "x-compress")) */ || (strfield2(retour->contentencoding, "deflate")) || (strfield2(retour->contentencoding, "x-deflate")) ) { retour->compressed = 1; } } #endif } } else if ((p = strfield(rcvd, "Location:")) != 0) { if (retour) { if (retour->location) { while(is_realspace(*(rcvd + p))) p++; // sauter espaces if ((int) strlen(rcvd + p) < HTS_URLMAXSIZE) // pas trop long? strcpybuff(retour->location, rcvd + p); else // erreur.. ignorer retour->location[0] = '\0'; } } } else if (((p = strfield(rcvd, "Set-Cookie:")) != 0) && (cookie)) { // ohh un cookie char *a = rcvd + p; // pointeur char domain[256]; // domaine cookie (.netscape.com) char path[256]; // chemin (/) char cook_name[256]; // nom cookie (MYCOOK) char BIGSTK cook_value[8192]; // valeur (ID=toto,S=1234) #if DEBUG_COOK printf("set-cookie detected\n"); #endif while(*a) { char *token_st, *token_end; char *value_st, *value_end; char name[256]; char BIGSTK value[8192]; int next = 0; name[0] = value[0] = '\0'; // // initialiser cookie lu actuellement if (adr) strcpybuff(domain, jump_identification_const(adr)); // domaine strcpybuff(path, "/"); // chemin (/) strcpybuff(cook_name, ""); // nom cookie (MYCOOK) strcpybuff(cook_value, ""); // valeur (ID=toto,S=1234) // boucler jusqu'au prochain cookie ou la fin do { char *start_loop = a; while(is_space(*a)) a++; // sauter espaces token_st = a; // départ token while((!is_space(*a)) && (*a) && (*a != ';') && (*a != '=')) a++; // arrêter si espace, point virgule token_end = a; while(is_space(*a)) a++; // sauter espaces if (*a == '=') { // name=value a++; while(is_space(*a)) a++; // sauter espaces value_st = a; while((*a != ';') && (*a)) a++; // prochain ; //while( ((*a!='"') || (*(a-1)=='\\')) && (*a)) a++; // prochain " (et pas \") value_end = a; //if (*a==';') { // finit par un ; // vérifier débordements if ((((int) (token_end - token_st)) < 200) && (((int) (value_end - value_st)) < 8000) && (((int) (token_end - token_st)) > 0) && (((int) (value_end - value_st)) > 0)) { int name_len = (int) (token_end - token_st); int value_len = (int) (value_end - value_st); name[0] = '\0'; value[0] = '\0'; strncatbuff(name, token_st, name_len); strncatbuff(value, value_st, value_len); #if DEBUG_COOK printf("detected cookie-av: name=\"%s\" value=\"%s\"\n", name, value); #endif if (strfield2(name, "domain")) { if (value_len < sizeof(domain) - 1) { strcpybuff(domain, value); } else { cook_name[0] = 0; break; } } else if (strfield2(name, "path")) { if (value_len < sizeof(path) - 1) { strcpybuff(path, value); } else { cook_name[0] = 0; break; } } else if (strfield2(name, "max-age")) { // ignoré.. } else if (strfield2(name, "expires")) { // ignoré.. } else if (strfield2(name, "version")) { // ignoré.. } else if (strfield2(name, "comment")) { // ignoré } else if (strfield2(name, "secure")) { // ne devrait pas arriver ici // ignoré } else { if (value_len < sizeof(cook_value) - 1 && name_len < sizeof(cook_name) - 1) { if (strnotempty(cook_name) == 0) { // noter premier: nom et valeur cookie strcpybuff(cook_name, name); strcpybuff(cook_value, value); } else { // prochain cookie a = start_loop; // on devra recommencer à cette position next = 1; // enregistrer } } else { cook_name[0] = 0; break; } } } } if (!next) { while((*a != ';') && (*a)) a++; // prochain while(*a == ';') a++; // sauter ; } } while((*a) && (!next)); if (strnotempty(cook_name)) { // cookie? #if DEBUG_COOK printf ("new cookie: name=\"%s\" value=\"%s\" domain=\"%s\" path=\"%s\"\n", cook_name, cook_value, domain, path); #endif cookie_add(cookie, cook_name, cook_value, domain, path); } } } } // transforme le message statuscode en chaîne HTSEXT_API void infostatuscode(char *msg, int statuscode) { switch (statuscode) { // Erreurs HTTP, selon RFC case 100: strcpybuff(msg, "Continue"); break; case 101: strcpybuff(msg, "Switching Protocols"); break; case 200: strcpybuff(msg, "OK"); break; case 201: strcpybuff(msg, "Created"); break; case 202: strcpybuff(msg, "Accepted"); break; case 203: strcpybuff(msg, "Non-Authoritative Information"); break; case 204: strcpybuff(msg, "No Content"); break; case 205: strcpybuff(msg, "Reset Content"); break; case 206: strcpybuff(msg, "Partial Content"); break; case 300: strcpybuff(msg, "Multiple Choices"); break; case 301: strcpybuff(msg, "Moved Permanently"); break; case 302: strcpybuff(msg, "Moved Temporarily"); break; case 303: strcpybuff(msg, "See Other"); break; case 304: strcpybuff(msg, "Not Modified"); break; case 305: strcpybuff(msg, "Use Proxy"); break; case 306: strcpybuff(msg, "Undefined 306 error"); break; case 307: strcpybuff(msg, "Temporary Redirect"); break; case 400: strcpybuff(msg, "Bad Request"); break; case 401: strcpybuff(msg, "Unauthorized"); break; case 402: strcpybuff(msg, "Payment Required"); break; case 403: strcpybuff(msg, "Forbidden"); break; case 404: strcpybuff(msg, "Not Found"); break; case 405: strcpybuff(msg, "Method Not Allowed"); break; case 406: strcpybuff(msg, "Not Acceptable"); break; case 407: strcpybuff(msg, "Proxy Authentication Required"); break; case 408: strcpybuff(msg, "Request Time-out"); break; case 409: strcpybuff(msg, "Conflict"); break; case 410: strcpybuff(msg, "Gone"); break; case 411: strcpybuff(msg, "Length Required"); break; case 412: strcpybuff(msg, "Precondition Failed"); break; case 413: strcpybuff(msg, "Request Entity Too Large"); break; case 414: strcpybuff(msg, "Request-URI Too Large"); break; case 415: strcpybuff(msg, "Unsupported Media Type"); break; case 416: strcpybuff(msg, "Requested Range Not Satisfiable"); break; case 417: strcpybuff(msg, "Expectation Failed"); break; case 500: strcpybuff(msg, "Internal Server Error"); break; case 501: strcpybuff(msg, "Not Implemented"); break; case 502: strcpybuff(msg, "Bad Gateway"); break; case 503: strcpybuff(msg, "Service Unavailable"); break; case 504: strcpybuff(msg, "Gateway Time-out"); break; case 505: strcpybuff(msg, "HTTP Version Not Supported"); break; // default: if (strnotempty(msg) == 0) strcpybuff(msg, "Unknown error"); break; } } // check if data is available int check_readinput(htsblk * r) { if (r->soc != INVALID_SOCKET) { fd_set fds; // poll structures struct timeval tv; // structure for select const int soc = (int) r->soc; assertf(soc == r->soc); FD_ZERO(&fds); FD_SET(soc, &fds); tv.tv_sec = 0; tv.tv_usec = 0; select(soc + 1, &fds, NULL, NULL, &tv); if (FD_ISSET(soc, &fds)) return 1; else return 0; } else return 0; } // check if data is available int check_readinput_t(T_SOC soc, int timeout) { if (soc != INVALID_SOCKET) { fd_set fds; // poll structures struct timeval tv; // structure for select const int isoc = (int) soc; assertf(isoc == soc); FD_ZERO(&fds); FD_SET(isoc, &fds); tv.tv_sec = timeout; tv.tv_usec = 0; select(isoc + 1, &fds, NULL, NULL, &tv); if (FD_ISSET(isoc, &fds)) return 1; else return 0; } else return 0; } // idem, sauf qu'ici on peut choisir la taille max de données à recevoir // SI bufl==0 alors le buffer est censé être de 8kos, et on recoit par bloc de lignes // en éliminant les cr (ex: header), arrêt si double-lf // SI bufl==-1 alors le buffer est censé être de 8kos, et on recoit ligne par ligne // en éliminant les cr (ex: header), arrêt si double-lf // Note: les +1 dans les malloc sont dûs à l'octet nul rajouté en fin de fichier LLint http_xfread1(htsblk * r, int bufl) { int nl = -1; // EOF if (r->totalsize >= 0 && r->size == r->totalsize) { return READ_EOF; } if (bufl > 0) { if (!r->is_write) { // stocker en mémoire if (r->totalsize >= 0) { // totalsize déterminé ET ALLOUE if (r->adr == NULL) { r->adr = (char *) malloct((size_t) r->totalsize + 1); r->size = 0; } if (r->adr != NULL) { // lecture const size_t req_size = r->totalsize - r->size; nl = req_size > 0 ? hts_read(r, r->adr + ((int) r->size), (int) req_size) : 0; /* NO 32 bit overlow possible here (no 4GB html!) */ // nouvelle taille if (nl >= 0) r->size += nl; /* if (r->size >= r->totalsize) nl = -1; // break */ r->adr[r->size] = '\0'; // caractère NULL en fin au cas où l'on traite des HTML } } else { // inconnu.. // réserver de la mémoire? if (r->adr == NULL) { #if HDEBUG printf("..alloc xfread\n"); #endif r->adr = (char *) malloct(bufl + 1); r->size = 0; } else { #if HDEBUG printf("..realloc xfread1\n"); #endif r->adr = (char *) realloct(r->adr, (int) r->size + bufl + 1); } if (r->adr != NULL) { // lecture nl = hts_read(r, r->adr + (int) r->size, bufl); if (nl > 0) { // resize r->adr = (char *) realloct(r->adr, (int) r->size + nl + 1); // nouvelle taille r->size += nl; // octet nul if (r->adr) r->adr[r->size] = '\0'; } // sinon on a fini #if HDEBUG else if (nl < 0) printf("..end read (%d)\n", nl); #endif } #if HDEBUG else printf("..-> error\n"); #endif } // pas de adr=erreur if (r->adr == NULL) nl = READ_ERROR; } else { // stocker sur disque char *buff; buff = (char *) malloct(bufl); if (buff != NULL) { // lecture nl = hts_read(r, buff, bufl); // nouvelle taille if (nl > 0) { r->size += nl; if (fwrite(buff, 1, nl, r->out) != nl) { r->statuscode = STATUSCODE_INVALID; strcpybuff(r->msg, "Write error on disk"); nl = READ_ERROR; } } //if ((nl < 0) || ((r->totalsize>0) && (r->size >= r->totalsize))) // nl=-1; // break // libérer bloc tempo freet(buff); } else nl = READ_ERROR; if ((nl < 0) && (r->out != NULL)) { fflush(r->out); } } // stockage disque ou mémoire } else if (bufl == -2) { // force reserve if (r->adr == NULL) { r->adr = (char *) malloct(8192); r->size = 0; return 0; } return -1; } else { // réception d'un en-tête octet par octet int count = 256; int tot_nl = 0; int lf_detected = 0; int at_beginning = 1; do { nl = READ_INTERNAL_ERROR; count--; if (r->adr == NULL) { r->adr = (char *) malloct(8192); r->size = 0; } if (r->adr != NULL) { if (r->size < 8190) { // lecture nl = hts_read(r, r->adr + r->size, 1); if (nl > 0) { // exit if: // lf detected AND already detected before // or // lf detected AND first character read if (*(r->adr + r->size) == 10) { if (lf_detected || (at_beginning) || (bufl < 0)) count = -1; lf_detected = 1; } if (*(r->adr + r->size) != 13) { // sauter caractères 13 if ((*(r->adr + r->size) != 10) && (*(r->adr + r->size) != 13) ) { // restart for new line lf_detected = 0; } (r->size)++; at_beginning = 0; } *(r->adr + r->size) = '\0'; // terminer par octet nul } } } if (nl >= 0) { tot_nl += nl; if (!check_readinput(r)) count = -1; } } while((nl >= 0) && (count > 0)); if (nl >= 0) { nl = tot_nl; } } // EOF if (r->totalsize >= 0 && r->size == r->totalsize) { return READ_EOF; } else { return nl; } } // teste si une URL (validité, header, taille) // retourne 200 ou le code d'erreur (404=NOT FOUND, etc) // en cas de moved xx, dans location // abandonne désormais au bout de 30 secondes (aurevoir les sites // qui nous font poireauter 5 heures..) -> -2=timeout htsblk http_test(httrackp * opt, const char *adr, const char *fil, char *loc) { T_SOC soc; htsblk retour; //int rcvsize=-1; //char* rcv=NULL; // adresse de retour //int bufl=TAILLE_BUFFER; // 8Ko de buffer TStamp tl; int timeout = 30; // timeout pour un check (arbitraire) // ** // pour abandonner un site trop lent tl = time_local(); loc[0] = '\0'; hts_init_htsblk(&retour); //memset(&retour, 0, sizeof(htsblk)); // effacer retour.location = loc; // si non nul, contiendra l'adresse véritable en cas de moved xx //soc=http_fopen(adr,fil,&retour,NULL); // ouvrir, + header // on ouvre en head, et on traite l'en tête soc = http_xfopen(opt, 1, 0, 1, NULL, adr, fil, &retour); // ouvrir HEAD, + envoi header if (soc != INVALID_SOCKET) { int e = 0; // tant qu'on a des données, et qu'on ne recoit pas deux LF, et que le timeout n'arrie pas do { if (http_xfread1(&retour, 0) < 0) e = 1; else { if (retour.adr != NULL) { if ((retour.adr[retour.size - 1] != 10) || (retour.adr[retour.size - 2] != 10)) e = 1; } } if (!e) { if ((time_local() - tl) >= timeout) { e = -1; } } } while(!e); if (e == 1) { if (adr != NULL) { int ptr = 0; char rcvd[1100]; // note: en gros recopie du traitement de back_wait() // // ---------------------------------------- // traiter en-tête! // status-line à récupérer ptr += binput(retour.adr + ptr, rcvd, 1024); if (strnotempty(rcvd) == 0) ptr += binput(retour.adr + ptr, rcvd, 1024); // "certains serveurs buggés envoient un \n au début" (RFC) // traiter status-line treatfirstline(&retour, rcvd); #if HDEBUG printf("(Buffer) Status-Code=%d\n", retour.statuscode); #endif // en-tête // header // ** !attention! HTTP/0.9 non supporté do { ptr += binput(retour.adr + ptr, rcvd, 1024); #if HDEBUG printf("(buffer)>%s\n", rcvd); #endif if (strnotempty(rcvd)) treathead(NULL, NULL, NULL, &retour, rcvd); // traiter } while(strnotempty(rcvd)); // ---------------------------------------- // libérer mémoire if (retour.adr != NULL) { freet(retour.adr); retour.adr = NULL; } } } else { retour.statuscode = STATUSCODE_TIMEOUT; strcpybuff(retour.msg, "Timeout While Testing"); } #if HTS_DEBUG_CLOSESOCK DEBUG_W("http_test: deletehttp\n"); #endif deletehttp(&retour); retour.soc = INVALID_SOCKET; } return retour; } // Crée un lien (http) vers une adresse internet iadr // retour: structure (adresse, taille, message si erreur (si !adr)) // peut ouvrir avec des connect() non bloquants: waitconnect=0/1 T_SOC newhttp(httrackp * opt, const char *_iadr, htsblk * retour, int port, int waitconnect) { T_SOC soc; // descipteur de la socket if (strcmp(_iadr, "file://") != 0) { /* non fichier */ SOCaddr server; const char *error = "unknown error"; // tester un éventuel id:pass et virer id:pass@ si détecté const char *const iadr = jump_identification_const(_iadr); SOCaddr_clear(server); #if HDEBUG printf("gethostbyname\n"); #endif // tester un éventuel port if (port == -1) { const char *a = jump_toport_const(iadr); #if HTS_USEOPENSSL if (retour->ssl) port = 443; else port = 80; // port par défaut #else port = 80; // port par défaut #endif if (a != NULL) { char BIGSTK iadr2[HTS_URLMAXSIZE * 2]; int i = -1; iadr2[0] = '\0'; sscanf(a + 1, "%d", &i); if (i != -1) { port = (unsigned short int) i; } // adresse véritable (sans :xx) strncatbuff(iadr2, iadr, (int) (a - iadr)); // adresse sans le :xx hts_dns_resolve2(opt, iadr2, &server, &error); } else { // adresse normale (port par défaut par la suite) hts_dns_resolve2(opt, iadr, &server, &error); } } else { // port défini hts_dns_resolve2(opt, iadr, &server, &error); } if (!SOCaddr_is_valid(server)) { #if DEBUG printf("erreur gethostbyname\n"); #endif if (retour && retour->msg) { #ifdef _WIN32 snprintf(retour->msg, sizeof(retour->msg), "Unable to get server's address: %s", error); #else snprintf(retour->msg, sizeof(retour->msg), "Unable to get server's address: %s", error); #endif } return INVALID_SOCKET; } // make a copy for external clients SOCaddr_copy_SOCaddr(retour->address, server); retour->address_size = SOCaddr_size(retour->address); // créer ("attachement") une socket (point d'accès) internet,en flot #if HDEBUG printf("socket\n"); #endif #if HTS_WIDE_DEBUG DEBUG_W("socket\n"); #endif soc = (T_SOC) socket(SOCaddr_sinfamily(server), SOCK_STREAM, 0); if (retour != NULL) { retour->debugid = HTS_STAT.stat_sockid++; } #if HTS_WIDE_DEBUG DEBUG_W("socket()=%d\n" _(int) soc); #endif if (soc == INVALID_SOCKET) { if (retour && retour->msg) { #ifdef _WIN32 int last_errno = WSAGetLastError(); sprintf(retour->msg, "Unable to create a socket: %s", strerror(last_errno)); #else int last_errno = errno; sprintf(retour->msg, "Unable to create a socket: %s", strerror(last_errno)); #endif } return INVALID_SOCKET; // erreur création socket impossible } // bind this address if (retour != NULL && strnotempty(retour->req.proxy.bindhost)) { const char *error = "unknown error"; SOCaddr bind_addr; if (hts_dns_resolve2(opt, retour->req.proxy.bindhost, &bind_addr, &error) == NULL || bind(soc, &SOCaddr_sockaddr(bind_addr), SOCaddr_size(bind_addr)) != 0) { if (retour && retour->msg) { #ifdef _WIN32 snprintf(retour->msg, sizeof(retour->msg), "Unable to bind the specificied server address: %s", error); #else snprintf(retour->msg, sizeof(retour->msg), "Unable to bind the specificied server address: %s", error); #endif } deletesoc(soc); return INVALID_SOCKET; } } // structure: connexion au domaine internet, port 80 (ou autre) SOCaddr_initport(server, port); #if HDEBUG printf("==%d\n", soc); #endif // connexion non bloquante? if (!waitconnect) { #ifdef _WIN32 unsigned long p = 1; // non bloquant if (ioctlsocket(soc, FIONBIO, &p)) { const int last_errno = WSAGetLastError(); snprintf(retour->msg, sizeof(retour->msg), "Non-blocking socket failed: %s", strerror(last_errno)); deletesoc(soc); return INVALID_SOCKET; } #else const int flags = fcntl(soc, F_GETFL, 0); if (flags == -1 || fcntl(soc, F_SETFL, flags | O_NONBLOCK) == -1) { snprintf(retour->msg, sizeof(retour->msg), "Non-blocking socket failed: %s", strerror(errno)); deletesoc(soc); return INVALID_SOCKET; } #endif } // Connexion au serveur lui même #if HDEBUG printf("connect\n"); #endif HTS_STAT.last_connect = mtime_local(); #if HTS_WIDE_DEBUG DEBUG_W("connect\n"); #endif if (connect(soc, &SOCaddr_sockaddr(server), SOCaddr_size(server)) != 0) { // bloquant if (waitconnect) { #if HDEBUG printf("unable to connect!\n"); #endif if (retour != NULL && retour->msg) { #ifdef _WIN32 const int last_errno = WSAGetLastError(); sprintf(retour->msg, "Unable to connect to the server: %s", strerror(last_errno)); #else const int last_errno = errno; sprintf(retour->msg, "Unable to connect to the server: %s", strerror(last_errno)); #endif } /* Close the socket and notify the error!!! */ deletesoc(soc); return INVALID_SOCKET; } } #if HTS_WIDE_DEBUG DEBUG_W("connect done\n"); #endif #if HDEBUG printf("connexion établie\n"); #endif // A partir de maintenant, on peut envoyer et recevoir des données // via le flot identifié par soc (socket): write(soc,adr,taille) et // read(soc,adr,taille) } else { // on doit ouvrir un fichier local! // il sera géré de la même manière qu'une socket (c'est idem!) soc = LOCAL_SOCKET_ID; // pseudo-socket locale.. // soc sera remplacé lors d'un http_fopen() par un handle véritable! } // teste fichier local ou http return soc; } // couper http://www.truc.fr/pub/index.html -> www.truc.fr /pub/index.html // retour=-1 si erreur. // si file://... alors adresse=file:// (et coupe le ?query dans ce cas) int ident_url_absolute(const char *url, lien_adrfil *adrfil) { int pos = 0; int scheme = 0; // effacer adrfil->adr et adrfil->fil adrfil->adr[0] = adrfil->fil[0] = '\0'; #if HDEBUG printf("protocol: %s\n", url); #endif // Scheme? { const char *a = url; while(isalpha((unsigned char) *a)) a++; if (*a == ':') scheme = 1; } // 1. optional scheme ":" if ((pos = strfield(url, "file:"))) { // fichier local!! (pour les tests) //!!p+=3; strcpybuff(adrfil->adr, "file://"); } else if ((pos = strfield(url, "http:"))) { // HTTP //!!p+=3; } else if ((pos = strfield(url, "ftp:"))) { // FTP strcpybuff(adrfil->adr, "ftp://"); // FTP!! //!!p+=3; #if HTS_USEOPENSSL } else if ((pos = strfield(url, "https:"))) { // HTTPS strcpybuff(adrfil->adr, "https://"); #endif } else if (scheme) { return -1; // erreur non reconnu } else pos = 0; // 2. optional "//" authority if (strncmp(url + pos, "//", 2) == 0) pos += 2; // (url+pos) now points to the path (not net path) //## if (adrfil->adr[0]!=lOCAL_CHAR) { // adrfil->adresse normale http if (!strfield(adrfil->adr, "file:")) { // PAS adrfil->file:// const char *p, *q; p = url + pos; // p pointe sur le début de l'adrfil->adresse, ex: www.truc.fr/sommaire/index.html q = strchr(jump_identification_const(p), '/'); if (q == 0) q = strchr(jump_identification_const(p), '?'); // http://www.foo.com?bar=1 if (q == 0) q = p + strlen(p); // pointe sur \0 // q pointe sur le chemin, ex: index.html?query=recherche // chemin www... trop long!! if ((((int) (q - p))) > HTS_URLMAXSIZE) { //strcpybuff(retour.msg,"Path too long"); return -1; // erreur } // recopier adrfil->adresse www.. strncatbuff(adrfil->adr, p, ((int) (q - p))); // *( adrfil->adr+( ((int) q) - ((int) p) ) )=0; // faut arrêter la fumette! // recopier chemin /pub/.. if (q[0] != '/') // page par défaut (/) strcatbuff(adrfil->fil, "/"); strcatbuff(adrfil->fil, q); // SECURITE: // simplifier url pour les ../ fil_simplifie(adrfil->fil); } else { // localhost adrfil->file:// const char *p; size_t i; char *a; p = url + pos; if (*p == '/' || *p == '\\') { /* adrfil->file:///.. */ strcatbuff(adrfil->fil, p); // fichier local ; adrfil->adr="#" } else { if (p[1] != ':') { strcatbuff(adrfil->fil, "//"); /* adrfil->file://server/foo */ strcatbuff(adrfil->fil, p); } else { strcatbuff(adrfil->fil, p); // adrfil->file://C:\.. } } a = strchr(adrfil->fil, '?'); if (a) *a = '\0'; /* couper query (inutile pour adrfil->file:// lors de la requête) */ // adrfil->filtrer les \\ -> / pour les fichiers DOS for(i = 0; adrfil->fil[i] != '\0'; i++) if (adrfil->fil[i] == '\\') adrfil->fil[i] = '/'; } // no hostname if (!strnotempty(adrfil->adr)) return -1; // erreur non reconnu // nommer au besoin.. (non utilisé normalement) if (!strnotempty(adrfil->fil)) strcpybuff(adrfil->fil, "default-index.html"); // case insensitive pour adrfil->adresse { char *a = jump_identification(adrfil->adr); while(*a) { if ((*a >= 'A') && (*a <= 'Z')) *a += 'a' - 'A'; a++; } } return 0; } /* simplify ../ and ./ */ void fil_simplifie(char *f) { char *a, *b; char *rollback[128]; int rollid = 0; char lc = '/'; int query = 0; int wasAbsolute = (*f == '/'); for(a = b = f; *a != '\0';) { if (*a == '?') query = 1; if (query == 0 && lc == '/' && a[0] == '.' && a[1] == '/') { /* foo/./bar or ./foo */ a += 2; } else if (query == 0 && lc == '/' && a[0] == '.' && a[1] == '.' && (a[2] == '/' || a[2] == '\0')) { /* foo/../bar or ../foo or .. */ if (a[2] == '\0') a += 2; else a += 3; if (rollid > 1) { rollid--; b = rollback[rollid - 1]; } else { /* too many ../ */ rollid = 0; b = f; if (wasAbsolute) b++; /* after the / */ } } else { *b++ = lc = *a; if (*a == '/') { rollback[rollid++] = b; if (rollid >= 127) { *f = '\0'; /* ERROR */ break; } } a++; } } *b = '\0'; if (*f == '\0') { if (wasAbsolute) { f[0] = '/'; f[1] = '\0'; } else { f[0] = '.'; f[1] = '/'; f[2] = '\0'; } } } // fermer liaison fichier ou socket void deletehttp(htsblk * r) { #if HTS_DEBUG_CLOSESOCK DEBUG_W("deletehttp: (htsblk*) 0x%p\n" _(void *)r); #endif #if HTS_USEOPENSSL /* Free OpenSSL structures */ if (r->ssl_con) { SSL_shutdown(r->ssl_con); SSL_free(r->ssl_con); r->ssl_con = NULL; } #endif if (r->soc != INVALID_SOCKET) { if (r->is_file) { if (r->fp) fclose(r->fp); r->fp = NULL; } else { if (r->soc != LOCAL_SOCKET_ID) deletesoc_r(r); } r->soc = INVALID_SOCKET; } } // free the addr buffer // always returns 1 int deleteaddr(htsblk * r) { if (r->adr != NULL) { freet(r->adr); r->adr = NULL; } if (r->headers != NULL) { freet(r->headers); r->headers = NULL; } return 1; } // fermer une socket void deletesoc(T_SOC soc) { if (soc != INVALID_SOCKET && soc != LOCAL_SOCKET_ID) { #if HTS_WIDE_DEBUG DEBUG_W("close %d\n" _(int) soc); #endif #ifdef _WIN32 if (closesocket(soc) != 0) { int err = WSAGetLastError(); fprintf(stderr, "* error closing socket %d: %s\n", soc, strerror(err)); } #else if (close(soc) != 0) { const int err = errno; fprintf(stderr, "* error closing socket %d: %s\n", soc, strerror(err)); } #endif #if HTS_WIDE_DEBUG DEBUG_W(".. done\n"); #endif } } /* Will also clean other things */ void deletesoc_r(htsblk * r) { #if HTS_USEOPENSSL if (r->ssl_con) { SSL_shutdown(r->ssl_con); // SSL_CTX_set_quiet_shutdown(r->ssl_con->ctx, 1); SSL_free(r->ssl_con); r->ssl_con = NULL; } #endif if (r->soc != INVALID_SOCKET) { deletesoc(r->soc); r->soc = INVALID_SOCKET; } } // renvoi le nombre de secondes depuis 1970 TStamp time_local(void) { return ((TStamp) time(NULL)); } // number of millisec since 1970 HTSEXT_API TStamp mtime_local(void) { #ifndef _WIN32 struct timeval tv; if (gettimeofday(&tv, NULL) != 0) { assert(! "gettimeofday"); } return (TStamp) (((TStamp) tv.tv_sec * (TStamp) 1000) + ((TStamp) tv.tv_usec / (TStamp) 1000000)); #else struct timeb B; ftime(&B); return (TStamp) (((TStamp) B.time * (TStamp) 1000) + ((TStamp) B.millitm)); #endif } // convertit un nombre de secondes en temps (chaine) void sec2str(char *st, TStamp t) { int j, h, m, s; j = (int) (t / (3600 * 24)); t -= ((TStamp) j) * (3600 * 24); h = (int) (t / (3600)); t -= ((TStamp) h) * 3600; m = (int) (t / 60); t -= ((TStamp) m) * 60; s = (int) t; if (j > 0) sprintf(st, "%d days, %d hours %d minutes %d seconds", j, h, m, s); else if (h > 0) sprintf(st, "%d hours %d minutes %d seconds", h, m, s); else if (m > 0) sprintf(st, "%d minutes %d seconds", m, s); else sprintf(st, "%d seconds", s); } // idem, plus court (chaine) HTSEXT_API void qsec2str(char *st, TStamp t) { int j, h, m, s; j = (int) (t / (3600 * 24)); t -= ((TStamp) j) * (3600 * 24); h = (int) (t / (3600)); t -= ((TStamp) h) * 3600; m = (int) (t / 60); t -= ((TStamp) m) * 60; s = (int) t; if (j > 0) sprintf(st, "%dd,%02dh,%02dmin%02ds", j, h, m, s); else if (h > 0) sprintf(st, "%dh,%02dmin%02ds", h, m, s); else if (m > 0) sprintf(st, "%dmin%02ds", m, s); else sprintf(st, "%ds", s); } // heure actuelle, GMT, format rfc (taille buffer 256o) void time_gmt_rfc822(char *s) { time_t tt; struct tm *A; tt = time(NULL); A = gmtime(&tt); if (A == NULL) A = localtime(&tt); time_rfc822(s, A); } // heure actuelle, format rfc (taille buffer 256o) void time_local_rfc822(char *s) { time_t tt; struct tm *A; tt = time(NULL); A = localtime(&tt); time_rfc822_local(s, A); } /* convertir une chaine en temps */ struct tm *convert_time_rfc822(struct tm *result, const char *s) { char months[] = "jan feb mar apr may jun jul aug sep oct nov dec"; char str[256]; char *a; /* */ int result_mm = -1; int result_dd = -1; int result_n1 = -1; int result_n2 = -1; int result_n3 = -1; int result_n4 = -1; /* */ if ((int) strlen(s) > 200) return NULL; strcpybuff(str, s); hts_lowcase(str); /* éliminer :,- */ while((a = strchr(str, '-'))) *a = ' '; while((a = strchr(str, ':'))) *a = ' '; while((a = strchr(str, ','))) *a = ' '; /* tokeniser */ a = str; while(*a) { char *first, *last; char tok[256]; /* découper mot */ while(*a == ' ') a++; /* sauter espaces */ first = a; while((*a) && (*a != ' ')) a++; last = a; tok[0] = '\0'; if (first != last) { char *pos; strncatbuff(tok, first, (int) (last - first)); /* analyser */ if ((pos = strstr(months, tok))) { /* month always in letters */ result_mm = ((int) (pos - months)) / 4; } else { int number; if (sscanf(tok, "%d", &number) == 1) { /* number token */ if (result_dd < 0) /* day always first number */ result_dd = number; else if (result_n1 < 0) result_n1 = number; else if (result_n2 < 0) result_n2 = number; else if (result_n3 < 0) result_n3 = number; else if (result_n4 < 0) result_n4 = number; } /* sinon, bruit de fond(+1GMT for exampel) */ } } } if ((result_n1 >= 0) && (result_mm >= 0) && (result_dd >= 0) && (result_n2 >= 0) && (result_n3 >= 0) && (result_n4 >= 0)) { if (result_n4 >= 1000) { /* Sun Nov 6 08:49:37 1994 */ result->tm_year = result_n4 - 1900; result->tm_hour = result_n1; result->tm_min = result_n2; result->tm_sec = max(result_n3, 0); } else { /* Sun, 06 Nov 1994 08:49:37 GMT or Sunday, 06-Nov-94 08:49:37 GMT */ result->tm_hour = result_n2; result->tm_min = result_n3; result->tm_sec = max(result_n4, 0); if (result_n1 <= 50) /* 00 means 2000 */ result->tm_year = result_n1 + 100; else if (result_n1 < 1000) /* 99 means 1999 */ result->tm_year = result_n1; else /* 2000 */ result->tm_year = result_n1 - 1900; } result->tm_isdst = 0; /* assume GMT */ result->tm_yday = -1; /* don't know */ result->tm_wday = -1; /* don't know */ result->tm_mon = result_mm; result->tm_mday = result_dd; return result; } return NULL; } static time_t getGMT(struct tm *tm) { time_t t = timegm(tm); if (t != (time_t) - 1 && t != (time_t) 0) { return (time_t) t; } return (time_t) -1; } /* sets file time. -1 if error */ /* Note: utf-8 */ int set_filetime(const char *file, struct tm *tm_time) { time_t t = getGMT(tm_time); if (t != (time_t) - 1) { STRUCT_UTIMBUF tim; memset(&tim, 0, sizeof(tim)); tim.actime = tim.modtime = t; return UTIME(file, &tim); } return -1; } /* sets file time from RFC822 date+time, -1 if error*/ /* Note: utf-8 */ int set_filetime_rfc822(const char *file, const char *date) { struct tm buffer; struct tm *tm_s = convert_time_rfc822(&buffer, date); if (tm_s) { return set_filetime(file, tm_s); } else return -1; } /* Note: utf-8 */ int get_filetime_rfc822(const char *file, char *date) { STRUCT_STAT buf; date[0] = '\0'; if (STAT(file, &buf) == 0) { struct tm *A; time_t tt = buf.st_mtime; A = gmtime(&tt); if (A == NULL) A = localtime(&tt); if (A != NULL) { time_rfc822(date, A); return 1; } } return 0; } // heure au format rfc (taille buffer 256o) void time_rfc822(char *s, struct tm *A) { if (A == NULL) { int localtime_returned_null = 0; assertf(localtime_returned_null); } strftime(s, 256, "%a, %d %b %Y %H:%M:%S GMT", A); } // heure locale au format rfc (taille buffer 256o) void time_rfc822_local(char *s, struct tm *A) { if (A == NULL) { int localtime_returned_null = 0; assertf(localtime_returned_null); } strftime(s, 256, "%a, %d %b %Y %H:%M:%S", A); } // conversion en b,Kb,Mb HTSEXT_API char *int2bytes(strc_int2bytes2 * strc, LLint n) { char **a = int2bytes2(strc, n); strcpybuff(strc->catbuff, a[0]); strcatbuff(strc->catbuff, a[1]); return strc->catbuff; } // conversion en b/s,Kb/s,Mb/s HTSEXT_API char *int2bytessec(strc_int2bytes2 * strc, long int n) { char buff[256]; char **a = int2bytes2(strc, n); strcpybuff(buff, a[0]); strcatbuff(buff, a[1]); return concat(strc->catbuff, sizeof(strc->catbuff), buff, "/s"); } HTSEXT_API char *int2char(strc_int2bytes2 * strc, int n) { sprintf(strc->buff2, "%d", n); return strc->buff2; } // conversion en b,Kb,Mb, nombre et type séparés // limite: 2.10^9.10^6B /* See http://physics.nist.gov/cuu/Units/binary.html */ #define ToLLint(a) ((LLint)(a)) #define ToLLintKiB (ToLLint(1024)) #define ToLLintMiB (ToLLintKiB*ToLLintKiB) #ifdef HTS_LONGLONG #define ToLLintGiB (ToLLintKiB*ToLLintKiB*ToLLintKiB) #define ToLLintTiB (ToLLintKiB*ToLLintKiB*ToLLintKiB*ToLLintKiB) #define ToLLintPiB (ToLLintKiB*ToLLintKiB*ToLLintKiB*ToLLintKiB*ToLLintKiB) #endif HTSEXT_API char **int2bytes2(strc_int2bytes2 * strc, LLint n) { if (n < ToLLintKiB) { sprintf(strc->buff1, "%d", (int) (LLint) n); strcpybuff(strc->buff2, "B"); } else if (n < ToLLintMiB) { sprintf(strc->buff1, "%d,%02d", (int) ((LLint) (n / ToLLintKiB)), (int) ((LLint) ((n % ToLLintKiB) * 100) / ToLLintKiB)); strcpybuff(strc->buff2, "KiB"); } #ifdef HTS_LONGLONG else if (n < ToLLintGiB) { sprintf(strc->buff1, "%d,%02d", (int) ((LLint) (n / (ToLLintMiB))), (int) ((LLint) (((n % (ToLLintMiB)) * 100) / (ToLLintMiB)))); strcpybuff(strc->buff2, "MiB"); } else if (n < ToLLintTiB) { sprintf(strc->buff1, "%d,%02d", (int) ((LLint) (n / (ToLLintGiB))), (int) ((LLint) (((n % (ToLLintGiB)) * 100) / (ToLLintGiB)))); strcpybuff(strc->buff2, "GiB"); } else if (n < ToLLintPiB) { sprintf(strc->buff1, "%d,%02d", (int) ((LLint) (n / (ToLLintTiB))), (int) ((LLint) (((n % (ToLLintTiB)) * 100) / (ToLLintTiB)))); strcpybuff(strc->buff2, "TiB"); } else { sprintf(strc->buff1, "%d,%02d", (int) ((LLint) (n / (ToLLintPiB))), (int) ((LLint) (((n % (ToLLintPiB)) * 100) / (ToLLintPiB)))); strcpybuff(strc->buff2, "PiB"); } #else else { sprintf(strc->buff1, "%d,%02d", (int) ((LLint) (n / (ToLLintMiB))), (int) ((LLint) (((n % (ToLLintMiB)) * 100) / (ToLLintMiB)))); strcpybuff(strc->buff2, "MiB"); } #endif strc->buffadr[0] = strc->buff1; strc->buffadr[1] = strc->buff2; return strc->buffadr; } #ifdef _WIN32 #else // ignore sigpipe? int sig_ignore_flag(int setflag) { // flag ignore static int flag = 0; /* YES, this one is true static */ if (setflag >= 0) flag = setflag; return flag; } #endif // envoi de texte (en têtes généralement) sur la socket soc int sendc(htsblk * r, const char *s) { int n, ssz = (int) strlen(s); #ifdef _WIN32 #else sig_ignore_flag(1); #endif #if HDEBUG write(0, s, ssz); #endif #if HTS_USEOPENSSL if (r->ssl) { n = SSL_write(r->ssl_con, s, ssz); } else #endif n = send(r->soc, s, ssz, 0); #ifdef _WIN32 #else sig_ignore_flag(0); #endif return (n == ssz) ? n : -1; } // Remplace read int finput(T_SOC fd, char *s, int max) { char c; int j = 0; do { //c=fgetc(fp); if (read((int) fd, &c, 1) <= 0) { c = 0; } if (c != 0) { switch (c) { case 10: c = 0; break; case 13: break; // sauter ces caractères default: s[j++] = c; break; } } } while((c != 0) && (j < max - 1)); s[j] = '\0'; return j; } // Like linput, but in memory (optimized) int binput(char *buff, char *s, int max) { int count = 0; int destCount = 0; // Note: \0 will return 1 while(destCount < max && buff != NULL && buff[count] != '\0' && buff[count] != '\n') { if (buff[count] != '\r') { s[destCount++] = buff[count]; } count++; } s[destCount] = '\0'; // then return the supplemental jump offset return count + 1; } // Lecture d'une ligne (peut être unicode à priori) int linput(FILE * fp, char *s, int max) { int c; int j = 0; do { c = fgetc(fp); if (c != EOF) { switch (c) { case 13: break; // sauter CR case 10: c = -1; break; case 9: case 12: break; // sauter ces caractères default: s[j++] = (char) c; break; } } } while((c != -1) && (c != EOF) && (j < (max - 1))); s[j] = '\0'; return j; } int linputsoc(T_SOC soc, char *s, int max) { int c; int j = 0; do { unsigned char ch; if (recv(soc, &ch, 1, 0) == 1) { c = ch; } else { c = EOF; } if (c != EOF) { switch (c) { case 13: break; // sauter CR case 10: c = -1; break; case 9: case 12: break; // sauter ces caractères default: s[j++] = (char) c; break; } } } while((c != -1) && (c != EOF) && (j < (max - 1))); s[j] = '\0'; return j; } int linputsoc_t(T_SOC soc, char *s, int max, int timeout) { if (check_readinput_t(soc, timeout)) { return linputsoc(soc, s, max); } return -1; } int linput_trim(FILE * fp, char *s, int max) { int rlen = 0; char *ls = (char *) malloct(max + 1); s[0] = '\0'; if (ls) { char *a; // lire ligne rlen = linput(fp, ls, max); if (rlen) { // sauter espaces et tabs en fin while((rlen > 0) && ((ls[max(rlen - 1, 0)] == ' ') || (ls[max(rlen - 1, 0)] == '\t'))) ls[--rlen] = '\0'; // sauter espaces en début a = ls; while((rlen > 0) && ((*a == ' ') || (*a == '\t'))) { a++; rlen--; } if (rlen > 0) { memcpy(s, a, rlen); // can copy \0 chars s[rlen] = '\0'; } } // freet(ls); } return rlen; } int linput_cpp(FILE * fp, char *s, int max) { int rlen = 0; s[0] = '\0'; do { int ret; if (rlen > 0) if (s[rlen - 1] == '\\') s[--rlen] = '\0'; // couper \ final // lire ligne ret = linput_trim(fp, s + rlen, max - rlen); if (ret > 0) rlen += ret; } while((s[max(rlen - 1, 0)] == '\\') && (rlen < max)); return rlen; } // idem avec les car spéciaux void rawlinput(FILE * fp, char *s, int max) { int c; int j = 0; do { c = fgetc(fp); if (c != EOF) { switch (c) { case 13: break; // sauter CR case 10: c = -1; break; default: s[j++] = (char) c; break; } } } while((c != -1) && (c != EOF) && (j < (max - 1))); s[j++] = '\0'; } //cherche chaine, case insensitive const char *strstrcase(const char *s, const char *o) { while(*s && strfield(s, o) == 0) s++; if (*s == '\0') return NULL; return s; } // Unicode detector // See http://www.unicode.org/unicode/reports/tr28/ // (sect Table 3.1B. Legal UTF-8 Byte Sequences) typedef struct { unsigned int pos; unsigned char data[4]; } t_auto_seq; // char between a and b #define CHAR_BETWEEN(c, a, b) ( (c) >= 0x##a ) && ( (c) <= 0x##b ) // sequence start #define SEQBEG ( inseq == 0 ) // in this block #define BLK(n,a, b) ( (seq.pos >= n) && ((err = CHAR_BETWEEN(seq.data[n], a, b))) ) #define ELT(n,a) BLK(n,a,a) // end #define SEQEND ((ok = 1)) // sequence started, character will fail if error #define IN_SEQ ( (inseq = 1) ) // decoding error #define BAD_SEQ ( (ok == 0) && (inseq != 0) && (!err) ) // no sequence started #define NO_SEQ ( inseq == 0 ) // is this block an UTF unicode textfile? // 0 : no // 1 : yes // -1: don't know int is_unicode_utf8(const char *buffer_, const size_t size) { const unsigned char *buffer = (const unsigned char *) buffer_; t_auto_seq seq; size_t i; int is_utf = -1; RUNTIME_TIME_CHECK_SIZE(size); seq.pos = 0; for(i = 0; i < size; i++) { unsigned int ok = 0; unsigned int inseq = 0; unsigned int err = 0; seq.data[seq.pos] = buffer[i]; /**/ if (SEQBEG && BLK(0, 00, 7F) && IN_SEQ && SEQEND) { } else if (SEQBEG && BLK(0, C2, DF) && IN_SEQ && BLK(1, 80, BF) && SEQEND) { } else if (SEQBEG && ELT(0, E0) && IN_SEQ && BLK(1, A0, BF) && BLK(2, 80, BF) && SEQEND) { } else if (SEQBEG && BLK(0, E1, EC) && IN_SEQ && BLK(1, 80, BF) && BLK(2, 80, BF) && SEQEND) { } else if (SEQBEG && ELT(0, ED) && IN_SEQ && BLK(1, 80, 9F) && BLK(2, 80, BF) && SEQEND) { } else if (SEQBEG && BLK(0, EE, EF) && IN_SEQ && BLK(1, 80, BF) && BLK(2, 80, BF) && SEQEND) { } else if (SEQBEG && ELT(0, F0) && IN_SEQ && BLK(1, 90, BF) && BLK(2, 80, BF) && BLK(3, 80, BF) && SEQEND) { } else if (SEQBEG && BLK(0, F1, F3) && IN_SEQ && BLK(1, 80, BF) && BLK(2, 80, BF) && BLK(3, 80, BF) && SEQEND) { } else if (SEQBEG && ELT(0, F4) && IN_SEQ && BLK(1, 80, 8F) && BLK(2, 80, BF) && BLK(3, 80, BF) && SEQEND) { } else if (NO_SEQ) { // bad, unknown return 0; } /* */ /* Error */ if (BAD_SEQ) { return 0; } /* unicode character */ if (seq.pos > 0) is_utf = 1; /* Next */ if (ok) seq.pos = 0; else seq.pos++; /* Internal error */ if (seq.pos >= 4) return 0; } return is_utf; } void map_characters(unsigned char *buffer, unsigned int size, unsigned int *map) { unsigned int i; memset(map, 0, sizeof(unsigned int) * 256); for(i = 0; i < size; i++) { map[buffer[i]]++; } } // le fichier est-il un fichier html? // 0 : non // 1 : oui // -1 : on sait pas // -2 : on sait pas, pas d'extension int ishtml(httrackp * opt, const char *fil) { /* User-defined MIME types (overrides ishtml()) */ char BIGSTK fil_noquery[HTS_URLMAXSIZE * 2]; char mime[256]; char *a; strcpybuff(fil_noquery, fil); if ((a = strchr(fil_noquery, '?')) != NULL) { *a = '\0'; } if (get_userhttptype(opt, mime, fil_noquery)) { if (is_html_mime_type(mime)) { return 1; } else { return 0; } } if (!strnotempty(fil_noquery)) { return -2; } /* Search for known ext */ for(a = fil_noquery + strlen(fil_noquery) - 1; *a != '.' && *a != '/' && a > fil_noquery; a--) ; if (*a == '.') { // a une extension char BIGSTK fil_noquery[HTS_URLMAXSIZE * 2]; char *b; int ret; char *dotted = a; fil_noquery[0] = '\0'; a++; // pointer sur extension strncatbuff(fil_noquery, a, HTS_URLMAXSIZE); b = strchr(fil_noquery, '?'); if (b) *b = '\0'; ret = ishtml_ext(fil_noquery); // retour if (ret == -1) { switch (is_knowntype(opt, dotted)) { case 1: ret = 0; // connu, non html break; case 2: ret = 1; // connu, html break; default: ret = -1; // inconnu.. break; } } return ret; } else return -2; // indéterminé, par exemple /truc } // idem, mais pour uniquement l'extension int ishtml_ext(const char *a) { int html = 0; // if (strfield2(a, "html")) html = 1; else if (strfield2(a, "htm")) html = 1; else if (strfield2(a, "shtml")) html = 1; else if (strfield2(a, "phtml")) html = 1; else if (strfield2(a, "htmlx")) html = 1; else if (strfield2(a, "shtm")) html = 1; else if (strfield2(a, "phtm")) html = 1; else if (strfield2(a, "htmx")) html = 1; // // insuccès.. else { #if 1 html = -1; // inconnu.. #else // XXXXXX not suitable (ext) switch (is_knownext(a)) { case 1: html = 0; // connu, non html break; case 2: html = 1; // connu, html break; default: html = -1; // inconnu.. break; } #endif } return html; } // error (404,500..) int ishttperror(int err) { switch (err / 100) { case 4: case 5: return 1; break; } return 0; } /* Declare a non-const version of FUN */ #define DECLARE_NON_CONST_VERSION(FUN) \ char *FUN(char *source) { \ const char *const ret = FUN ##_const(source); \ return ret != NULL ? source + ( ret - source ) : NULL; \ } // retourne le pointeur ou le pointeur + offset si il existe dans la chaine un @ signifiant // une identification HTSEXT_API const char *jump_identification_const(const char *source) { const char *a, *trytofind; if (strcmp(source, "file://") == 0) return source; // rechercher dernier @ (car parfois email transmise dans adresse!) // mais sauter ftp:// éventuel a = jump_protocol_const(source); trytofind = strrchr_limit(a, '@', strchr(a, '/')); return trytofind != NULL ? trytofind : a; } HTSEXT_API DECLARE_NON_CONST_VERSION(jump_identification) HTSEXT_API const char *jump_normalized_const(const char *source) { if (strcmp(source, "file://") == 0) return source; source = jump_identification_const(source); if (strfield(source, "www") && source[3] != '\0') { if (source[3] == '.') { // www.foo.com -> foo.com source += 4; } else { // www-4.foo.com -> foo.com const char *a = source + 3; while(*a && (isdigit(*a) || *a == '-')) a++; if (*a == '.') { source = a + 1; } } } return source; } HTSEXT_API DECLARE_NON_CONST_VERSION(jump_normalized) static int sortNormFnc(const void *a_, const void *b_) { const char *const*const a = (const char *const*) a_; const char *const*const b = (const char *const*) b_; return strcmp(*a + 1, *b + 1); } HTSEXT_API char *fil_normalized(const char *source, char *dest) { char lastc = 0; int gotquery = 0; int ampargs = 0; size_t i, j; char *query = NULL; for(i = j = 0; source[i] != '\0'; i++) { if (!gotquery && source[i] == '?') gotquery = ampargs = 1; if ((!gotquery && lastc == '/' && source[i] == '/') // foo//bar -> foo/bar ) { } else { if (gotquery && source[i] == '&') { ampargs++; } dest[j++] = source[i]; } lastc = source[i]; } dest[j++] = '\0'; /* Sort arguments (&foo=1&bar=2 == &bar=2&foo=1) */ if (ampargs > 1) { char **amps = malloct(ampargs * sizeof(char *)); char *copyBuff = NULL; size_t qLen = 0; assertf(amps != NULL); gotquery = 0; for(i = j = 0; dest[i] != '\0'; i++) { if ((gotquery && dest[i] == '&') || (!gotquery && dest[i] == '?')) { if (!gotquery) { gotquery = 1; query = &dest[i]; qLen = strlen(query); } assertf(j < ampargs); amps[j++] = &dest[i]; dest[i] = '\0'; } } assertf(gotquery); assertf(j == ampargs); /* Sort 'em all */ qsort(amps, ampargs, sizeof(char *), sortNormFnc); /* Replace query by sorted query */ copyBuff = malloct(qLen + 1); assertf(copyBuff != NULL); copyBuff[0] = '\0'; for(i = 0; i < ampargs; i++) { if (i == 0) strcatbuff(copyBuff, "?"); else strcatbuff(copyBuff, "&"); strcatbuff(copyBuff, amps[i] + 1); } assertf(strlen(copyBuff) == qLen); strcpybuff(query, copyBuff); /* Cleanup */ freet(amps); freet(copyBuff); } return dest; } #define endwith(a) ( (len >= (sizeof(a)-1)) ? ( strncmp(dest, a+len-(sizeof(a)-1), sizeof(a)-1) == 0 ) : 0 ); HTSEXT_API char *adr_normalized(const char *source, char *dest) { /* not yet too aggressive (no com<->net<->org checkings) */ strcpybuff(dest, jump_normalized_const(source)); return dest; } #undef endwith // find port (:80) or NULL if not found // can handle IPV6 addresses HTSEXT_API const char *jump_toport_const(const char *source) { const char *a, *trytofind; a = jump_identification_const(source); trytofind = strrchr_limit(a, ']', strchr(source, '/')); // find last ] (http://[3ffe:b80:1234::1]:80/foo.html) a = strchr((trytofind) ? trytofind : a, ':'); return a; } HTSEXT_API DECLARE_NON_CONST_VERSION(jump_toport) // strrchr, but not too far const char *strrchr_limit(const char *s, char c, const char *limit) { if (limit == NULL) { const char *p = strrchr(s, c); return p ? (p + 1) : NULL; } else { const char *a = NULL, *p; for(;;) { p = strchr((a) ? a : s, c); if ((p >= limit) || (p == NULL)) return a; a = p + 1; } } } // retourner adr sans ftp:// const char *jump_protocol_const(const char *source) { int p; // scheme // "Comparisons of scheme names MUST be case-insensitive" (RFC2616) if ((p = strfield(source, "http:"))) source += p; else if ((p = strfield(source, "ftp:"))) source += p; else if ((p = strfield(source, "https:"))) source += p; else if ((p = strfield(source, "file:"))) source += p; // net_path if (strncmp(source, "//", 2) == 0) source += 2; return source; } DECLARE_NON_CONST_VERSION(jump_protocol) // codage base 64 a vers b void code64(unsigned char *a, int size_a, unsigned char *b, int crlf) { int i1 = 0, i2 = 0, i3 = 0, i4 = 0; int loop = 0; unsigned long int store; int n; const char _hts_base64[] = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; while(size_a-- > 0) { // 24 bits n = 1; store = *a++; if (size_a-- > 0) { n = 2; store <<= 8; store |= *a++; } if (size_a-- > 0) { n = 3; store <<= 8; store |= *a++; } if (n == 3) { i4 = store & 63; i3 = (store >> 6) & 63; i2 = (store >> 12) & 63; i1 = (store >> 18) & 63; } else if (n == 2) { store <<= 2; i3 = store & 63; i2 = (store >> 6) & 63; i1 = (store >> 12) & 63; } else { store <<= 4; i2 = store & 63; i1 = (store >> 6) & 63; } *b++ = _hts_base64[i1]; *b++ = _hts_base64[i2]; if (n >= 2) *b++ = _hts_base64[i3]; else *b++ = '='; if (n >= 3) *b++ = _hts_base64[i4]; else *b++ = '='; if (crlf && ((loop += 3) % 60) == 0) { *b++ = '\r'; *b++ = '\n'; } } *b++ = '\0'; } // return the hex character value, or -1 on error. static HTS_INLINE int ehexh(const char c) { if (c >= '0' && c <= '9') return c - '0'; else if (c >= 'a' && c <= 'f') return (c - 'a' + 10); else if (c >= 'A' && c <= 'F') return (c - 'A' + 10); else return -1; } // return the two-hex character value, or -1 on error. static HTS_INLINE int ehex(const char *s) { const int c1 = ehexh(s[0]); if (c1 >= 0) { const int c2 = ehexh(s[1]); if (c2 >= 0) { return 16*c1 + c2; } } return -1; } void unescape_amp(char *s) { if (hts_unescapeEntities(s, s, strlen(s) + 1) != 0) { assertf(! "error escaping html entities"); } } // remplacer %20 par ' ', etc.. // buffer MAX 1Ko HTSEXT_API char *unescape_http(char *const catbuff, const size_t size, const char *const s) { size_t i, j; RUNTIME_TIME_CHECK_SIZE(size); for(i = 0, j = 0; s[i] != '\0' && j + 1 < size ; i++) { int h; if (s[i] == '%' && (h = ehex(&s[i + 1])) >= 0) { catbuff[j++] = (char) h; i += 2; } else catbuff[j++] = s[i]; } catbuff[j++] = '\0'; return catbuff; } // unescape in URL/URI ONLY what has to be escaped, to form a standard URL/URI // DOES NOT DECODE %25 (part of CHAR_DELIM) // no_high & 1: decode high chars // no_high & 2: decode space HTSEXT_API char *unescape_http_unharm(char *const catbuff, const size_t size, const char *s, const int no_high) { size_t i, j; RUNTIME_TIME_CHECK_SIZE(size); for(i = 0, j = 0; s[i] != '\0' && j + 1 < size ; i++) { if (s[i] == '%') { const int nchar = ehex(&s[i + 1]); const int test = ( CHAR_RESERVED(nchar) && nchar != '+' ) /* %2B => + (not in query!) */ || CHAR_DELIM(nchar) || CHAR_UNWISE(nchar) || CHAR_LOW(nchar) /* CHAR_SPECIAL */ || ( CHAR_XXAVOID(nchar) && ( nchar != ' ' || ( no_high & 2) == 0 ) ) || ( ( no_high & 1 ) && CHAR_HIG(nchar) ) ; if (!test && nchar >= 0) { /* can safely unescape */ catbuff[j++] = (char) nchar; i += 2; } else { catbuff[j++] = '%'; } } else { catbuff[j++] = s[i]; } } catbuff[j++] = '\0'; return catbuff; } // remplacer " par %xx etc.. // buffer MAX 1Ko HTSEXT_API size_t escape_spc_url(const char *const src, char *const dest, const size_t size) { return x_escape_http(src, dest, size, 2); } // smith / john -> smith%20%2f%20john HTSEXT_API size_t escape_in_url(const char *const src, char *const dest, const size_t size) { return x_escape_http(src, dest, size, 1); } // smith / john -> smith%20/%20john HTSEXT_API size_t escape_uri(const char *const src, char *const dest, const size_t size) { return x_escape_http(src, dest, size, 3); } HTSEXT_API size_t escape_uri_utf(const char *const src, char *const dest, const size_t size) { return x_escape_http(src, dest, size, 30); } HTSEXT_API size_t escape_check_url(const char *const src, char *const dest, const size_t size) { return x_escape_http(src, dest, size, 0); } // same as escape_check_url, but returns char* HTSEXT_API char *escape_check_url_addr(const char *const src, char *const dest, const size_t size) { escape_check_url(src, dest, size); return dest; } // Same as above, but appending to "dest" #undef DECLARE_APPEND_ESCAPE_VERSION #define DECLARE_APPEND_ESCAPE_VERSION(NAME) \ HTSEXT_API size_t append_ ##NAME(const char *const src, char *const dest, const size_t size) { \ const size_t len = strnlen(dest, size); \ assertf(len < size); \ return NAME(src, dest + len, size - len); \ } DECLARE_APPEND_ESCAPE_VERSION(escape_in_url) DECLARE_APPEND_ESCAPE_VERSION(escape_spc_url) DECLARE_APPEND_ESCAPE_VERSION(escape_uri_utf) DECLARE_APPEND_ESCAPE_VERSION(escape_check_url) DECLARE_APPEND_ESCAPE_VERSION(escape_uri) #undef DECLARE_APPEND_ESCAPE_VERSION // Same as above, but in-place #undef DECLARE_INPLACE_ESCAPE_VERSION #define DECLARE_INPLACE_ESCAPE_VERSION(NAME) \ HTSEXT_API size_t inplace_ ##NAME(char *const dest, const size_t size) { \ char buffer[256]; \ const size_t len = strnlen(dest, size); \ const int in_buffer = len + 1 < sizeof(buffer); \ char *src = in_buffer ? buffer : malloct(len + 1); \ size_t ret; \ assertf(src != NULL); \ assertf(len < size); \ memcpy(src, dest, len + 1); \ ret = NAME(src, dest, size); \ if (!in_buffer) { \ freet(src); \ } \ return ret; \ } DECLARE_INPLACE_ESCAPE_VERSION(escape_in_url) DECLARE_INPLACE_ESCAPE_VERSION(escape_spc_url) DECLARE_INPLACE_ESCAPE_VERSION(escape_uri_utf) DECLARE_INPLACE_ESCAPE_VERSION(escape_check_url) DECLARE_INPLACE_ESCAPE_VERSION(escape_uri) #undef DECLARE_INPLACE_ESCAPE_VERSION HTSEXT_API size_t make_content_id(const char *const adr, const char *const fil, char *const dest, const size_t size) { char *a; size_t esc_size = escape_in_url(adr, dest, size); esc_size += escape_in_url(fil, dest + esc_size, size - esc_size); RUNTIME_TIME_CHECK_SIZE(size); for(a = dest ; (a = strchr(a, '%')) != NULL ; a++) { *a = 'X'; } return esc_size; } // strip all control characters HTSEXT_API void escape_remove_control(char *const s) { size_t i, j; for(i = 0, j = 0 ; s[i] != '\0' ; i++) { const unsigned char c = (unsigned char) s[i]; if (c >= 32) { if (i != j) { assertf(j < i); s[j] = s[i]; } j++; } } } #undef ADD_CHAR #define ADD_CHAR(C) do { \ assertf(j < size); \ if (j + 1 == size) { \ dest[j] = '\0'; \ return size; \ } \ dest[j++] = (C); \ } while(0) /* Returns the number of characters written (not taking in account the terminating \0), or 'size' upon overflow. */ HTSEXT_API size_t x_escape_http(const char *const s, char *const dest, const size_t size, const int mode) { static const char hex[] = "0123456789abcdef"; size_t i, j; RUNTIME_TIME_CHECK_SIZE(size); // Out-of-bound. // Previous character is supposed to be the terminating \0. if (size == 0) { return 0; } for(i = 0, j = 0 ; s[i] != '\0' ; i++) { const unsigned char c = (unsigned char) s[i]; int test = 0; if (mode == 0) test = c == '"' || c == ' ' || CHAR_SPECIAL(c); else if (mode == 1) test = CHAR_RESERVED(c) || CHAR_DELIM(c) || CHAR_UNWISE(c) || CHAR_SPECIAL(c) || CHAR_XXAVOID(c) || CHAR_MARK(c); else if (mode == 2) test = c == ' '; // n'escaper que espace else if (mode == 3) // échapper que ce qui est nécessaire test = CHAR_SPECIAL(c) || CHAR_XXAVOID(c); else if (mode == 30) // échapper que ce qui est nécessaire test = (c != '/' && CHAR_RESERVED(c)) || CHAR_DELIM(c) || CHAR_UNWISE(c) || CHAR_SPECIAL(c) || CHAR_XXAVOID(c); if (!test) { ADD_CHAR(c); } else { ADD_CHAR('%'); ADD_CHAR(hex[c / 16]); ADD_CHAR(hex[c % 16]); } } assertf(j < size); dest[j] = '\0'; return j; } HTSEXT_API size_t escape_for_html_print(const char *const s, char *const dest, const size_t size) { size_t i, j; RUNTIME_TIME_CHECK_SIZE(size); for(i = 0, j = 0 ; s[i] != '\0' ; i++) { const unsigned char c = (unsigned char) s[i]; if (c == '&') { ADD_CHAR('&'); ADD_CHAR('a'); ADD_CHAR('m'); ADD_CHAR('p'); ADD_CHAR(';'); } else { ADD_CHAR(c); } } assertf(j < size); dest[j] = '\0'; return j; } HTSEXT_API size_t escape_for_html_print_full(const char *const s, char *const dest, const size_t size) { static const char hex[] = "0123456789abcdef"; size_t i, j; RUNTIME_TIME_CHECK_SIZE(size); for(i = 0, j = 0 ; s[i] != '\0' ; i++) { const unsigned char c = (unsigned char) s[i]; if (c == '&') { ADD_CHAR('&'); ADD_CHAR('a'); ADD_CHAR('m'); ADD_CHAR('p'); ADD_CHAR(';'); } else if (CHAR_HIG(c)) { ADD_CHAR('&'); ADD_CHAR('#'); ADD_CHAR('x'); ADD_CHAR(hex[c / 16]); ADD_CHAR(hex[c % 16]); ADD_CHAR(';'); } else { ADD_CHAR(c); } } assertf(j < size); dest[j] = '\0'; return j; } #undef ADD_CHAR // conversion minuscules, avec buffer char *convtolower(char *catbuff, const char *a) { strcpybuff(catbuff, a); hts_lowcase(catbuff); // lower case return catbuff; } // conversion en minuscules void hts_lowcase(char *s) { size_t i; for(i = 0; s[i] != '\0'; i++) if ((s[i] >= 'A') && (s[i] <= 'Z')) s[i] += ('a' - 'A'); } // remplacer un caractère d'une chaîne dans une autre void hts_replace(char *s, char from, char to) { char *a; while((a = strchr(s, from)) != NULL) { *a = to; } } // deviner type d'un fichier local.. // ex: fil="toto.gif" -> s="image/gif" void guess_httptype(httrackp * opt, char *s, const char *fil) { get_httptype(opt, s, fil, 1); } // idem // flag: 1 si toujours renvoyer un type HTSEXT_API void get_httptype(httrackp * opt, char *s, const char *fil, int flag) { // userdef overrides get_httptype if (get_userhttptype(opt, s, fil)) { return; } // regular tests if (ishtml(opt, fil) == 1) { strcpybuff(s, "text/html"); } else { /* Check html -> text/html */ const char *a = fil + strlen(fil) - 1; while((*a != '.') && (*a != '/') && (a > fil)) a--; if (*a == '.' && strlen(a) < 32) { int j = 0; a++; while(strnotempty(hts_mime[j][1])) { if (strfield2(hts_mime[j][1], a)) { if (hts_mime[j][0][0] != '*') { // Une correspondance existe strcpybuff(s, hts_mime[j][0]); return; } } j++; } if (flag) sprintf(s, "application/%s", a); } else { if (flag) strcpybuff(s, "application/octet-stream"); } } } // get type of fil (php) // s: buffer (text/html) or NULL // return: 1 if known by user int get_userhttptype(httrackp * opt, char *s, const char *fil) { if (s != NULL) { if (s) s[0] = '\0'; if (fil == NULL || *fil == '\0') return 0; #if 1 if (StringLength(opt->mimedefs) > 0) { /* Check --assume foooo/foo/bar.cgi=text/html, then foo/bar.cgi=text/html, then bar.cgi=text/html */ /* also: --assume baz,bar,foooo/foo/bar.cgi=text/html */ /* start from path beginning */ do { const char *next; const char *mimedefs = StringBuff(opt->mimedefs); /* loop through mime definitions : \nfoo=bar\nzoo=baz\n.. */ while(*mimedefs != '\0') { const char *segment = fil + 1; if (*mimedefs == '\n') { mimedefs++; } /* compare current segment with user's definition */ do { int i; /* check current item */ for(i = 0; mimedefs[i] != '\0' /* end of all defs */ && mimedefs[i] != ' ' /* next item in left list */ && mimedefs[i] != '=' /* end of left list */ && mimedefs[i] != '\n' /* end of this def (?) */ && mimedefs[i] == segment[i] /* same item */ ; i++) ; /* success */ if ((mimedefs[i] == '=' || mimedefs[i] == ' ') && segment[i] == '\0') { int i2; while(mimedefs[i] != 0 && mimedefs[i] != '\n' && mimedefs[i] != '=') i++; if (mimedefs[i] == '=') { i++; for(i2 = 0; mimedefs[i + i2] != '\n' && mimedefs[i + i2] != '\0'; i2++) { s[i2] = mimedefs[i + i2]; } s[i2] = '\0'; return 1; /* SUCCESS! */ } } /* next item in list */ for(mimedefs += i; *mimedefs != '\0' && *mimedefs != '\n' && *mimedefs != '=' && *mimedefs != ' '; mimedefs++) ; if (*mimedefs == ' ') { mimedefs++; } } while(*mimedefs != '\0' && *mimedefs != '\n' && *mimedefs != '='); /* next user-def */ for(; *mimedefs != '\0' && *mimedefs != '\n'; mimedefs++) ; } /* shorten segment */ next = strchr(fil + 1, '/'); if (next == NULL) { /* ext tests */ next = strchr(fil + 1, '.'); } fil = next; } while(fil != NULL); } #else if (*buffer) { char BIGSTK search[1024]; char *detect; sprintf(search, "\n%s=", ext); // php=text/html detect = strstr(*buffer, search); if (!detect) { sprintf(search, "\n%s\n", ext); // php\ncgi=text/html detect = strstr(*buffer, search); } if (detect) { detect = strchr(detect, '='); if (detect) { detect++; if (s) { char *a; a = strchr(detect, '\n'); if (a) { strncatbuff(s, detect, (int) (a - detect)); } } return 1; } } } #endif } return 0; } // renvoyer extesion d'un type mime.. // ex: "image/gif" -> gif void give_mimext(char *s, const char *st) { int ok = 0; int j = 0; s[0] = '\0'; while((!ok) && (strnotempty(hts_mime[j][1]))) { if (strfield2(hts_mime[j][0], st)) { if (hts_mime[j][1][0] != '*') { // Une correspondance existe strcpybuff(s, hts_mime[j][1]); ok = 1; } } j++; } // wrap "x" mimetypes, such as: // application/x-mp3 // or // application/mp3 if (!ok) { int p; const char *a = NULL; if ((p = strfield(st, "application/x-"))) a = st + p; else if ((p = strfield(st, "application/"))) a = st + p; if (a) { if ((int) strlen(a) >= 1) { if ((int) strlen(a) <= 4) { strcpybuff(s, a); ok = 1; } } } } } // extension connue?.. // 0 : non // 1 : oui // 2 : html HTSEXT_API int is_knowntype(httrackp * opt, const char *fil) { char catbuff[CATBUFF_SIZE]; const char *ext; int j = 0; if (!fil) return 0; ext = get_ext(catbuff, sizeof(catbuff), fil); while(strnotempty(hts_mime[j][1])) { if (strfield2(hts_mime[j][1], ext)) { if (is_html_mime_type(hts_mime[j][0])) return 2; else return 1; } j++; } // Known by user? return (is_userknowntype(opt, fil)); } // known type?.. // 0 : no // 1 : yes // 2 : html // setdefs : set mime buffer: // file=(char*) "asp=text/html\nphp=text/html\n" HTSEXT_API int is_userknowntype(httrackp * opt, const char *fil) { char BIGSTK mime[1024]; if (!fil) return 0; if (!strnotempty(fil)) return 0; mime[0] = '\0'; get_userhttptype(opt, mime, fil); if (!strnotempty(mime)) return 0; else if (is_html_mime_type(mime)) return 2; else return 1; } // page dynamique? // is_dyntype(get_ext("foo.asp")) HTSEXT_API int is_dyntype(const char *fil) { int j = 0; if (!fil) return 0; if (!strnotempty(fil)) return 0; while(strnotempty(hts_ext_dynamic[j])) { if (strfield2(hts_ext_dynamic[j], fil)) { return 1; } j++; } return 0; } // types critiques qui ne doivent pas être changés car renvoyés par des serveurs qui ne // connaissent pas le type int may_unknown(httrackp * opt, const char *st) { int j = 0; // types média if (may_be_hypertext_mime(opt, st, "")) { return 1; } while(strnotempty(hts_mime_keep[j])) { if (strfield2(hts_mime_keep[j], st)) { // trouvé return 1; } j++; } return 0; } /* returns 1 if the mime/filename seems to be bogus because of badly recognized multiple extension ; such as "application/x-wais-source" for "httrack-3.42-1.el5.src.rpm" reported by Hippy Dave 08/2008 (3.43) */ int may_bogus_multiple(httrackp * opt, const char *mime, const char *filename) { int j; for(j = 0; strnotempty(hts_mime_bogus_multiple[j]); j++) { if (strfield2(hts_mime_bogus_multiple[j], mime)) { /* found mime type in suspicious list */ char ext[64]; ext[0] = '\0'; give_mimext(ext, mime); if (ext[0] != 0) { /* we have an extension for that */ const size_t ext_size = strlen(ext); const char *file = strrchr(filename, '/'); /* fetch terminal filename */ if (file != NULL) { int i; for(i = 0; file[i] != 0; i++) { if (i > 0 && file[i - 1] == '.' && strncasecmp(&file[i], ext, ext_size) == 0 && (file[i + ext_size] == 0 || file[i + ext_size] == '.' || file[i + ext_size] == '?')) { return 1; /* is ambiguous */ } } } } return 0; } } return 0; } /* filename extension should not be changed because potentially bogus ; replaces may_unknown() (3.43) */ int may_unknown2(httrackp * opt, const char *mime, const char *filename) { int ret = may_unknown(opt, mime); if (ret == 0) { ret = may_bogus_multiple(opt, mime, filename); } return ret; } // -- Utils fichiers // pretty print for i/o void fprintfio(FILE * fp, const char *buff, const char *prefix) { char nl = 1; while(*buff) { switch (*buff) { case 13: break; case 10: fprintf(fp, "\r\n"); nl = 1; break; default: if (nl) fprintf(fp, "%s", prefix); nl = 0; fputc(*buff, fp); } buff++; } } /* Le fichier existe-t-il? (ou est-il accessible?) */ /* Note: NOT utf-8 */ /* Note: preserve errno */ int fexist(const char *s) { char catbuff[CATBUFF_SIZE]; const int err = errno; struct stat st; memset(&st, 0, sizeof(st)); if (stat(fconv(catbuff, sizeof(catbuff), s), &st) == 0) { if (S_ISREG(st.st_mode)) { return 1; } else { return 0; } } errno = err; return 0; } /* Le fichier existe-t-il? (ou est-il accessible?) */ /* Note: utf-8 */ /* Note: preserve errno */ int fexist_utf8(const char *s) { char catbuff[CATBUFF_SIZE]; const int err = errno; STRUCT_STAT st; memset(&st, 0, sizeof(st)); if (STAT(fconv(catbuff, sizeof(catbuff), s), &st) == 0) { if (S_ISREG(st.st_mode)) { return 1; } else { return 0; } } errno = err; return 0; } /* Taille d'un fichier, -1 si n'existe pas */ /* Note: NOT utf-8 */ off_t fsize(const char *s) { struct stat st; if (!strnotempty(s)) // nom vide: erreur return -1; if (stat(s, &st) == 0 && S_ISREG(st.st_mode)) { return st.st_size; } else { return -1; } } /* Taille d'un fichier, -1 si n'existe pas */ /* Note: utf-8 */ off_t fsize_utf8(const char *s) { STRUCT_STAT st; if (!strnotempty(s)) // nom vide: erreur return -1; if (STAT(s, &st) == 0 && S_ISREG(st.st_mode)) { return st.st_size; } else { return -1; } } off_t fpsize(FILE * fp) { off_t oldpos, size; if (!fp) return -1; #ifdef HTS_FSEEKO oldpos = ftello(fp); #else oldpos = ftell(fp); #endif fseek(fp, 0, SEEK_END); #ifdef HTS_FSEEKO size = ftello(fp); fseeko(fp, oldpos, SEEK_SET); #else size = ftell(fp); fseek(fp, oldpos, SEEK_SET); #endif return size; } /* root dir, with ending / */ typedef struct { char path[1024 + 4]; int init; } hts_rootdir_strc; HTSEXT_API const char *hts_rootdir(char *file) { static hts_rootdir_strc strc = { "", 0 }; if (file) { if (!strc.init) { strc.path[0] = '\0'; strc.init = 1; if (strnotempty(file)) { const size_t file_len = strlen(file); char *a; assertf(file_len < sizeof(strc.path)); strcpybuff(strc.path, file); while((a = strrchr(strc.path, '\\'))) *a = '/'; if ((a = strrchr(strc.path, '/'))) { *(a + 1) = '\0'; } else strc.path[0] = '\0'; } if (!strnotempty(strc.path)) { if (getcwd(strc.path, sizeof(strc.path)) == NULL) strc.path[0] = '\0'; else strcatbuff(strc.path, "/"); } } return NULL; } else if (strc.init) return strc.path; else return ""; } HTSEXT_API hts_stat_struct HTS_STAT; // // return number of downloadable bytes, depending on rate limiter // see engine_stats() routine, too // this routine works quite well for big files and regular ones, but apparently the rate limiter has // some problems with very small files (rate too high) LLint check_downloadable_bytes(int rate) { if (rate > 0) { TStamp time_now; TStamp elapsed_useconds; LLint bytes_transferred_during_period; LLint left; // get the older timer int id_timer = (HTS_STAT.istat_idlasttimer + 1) % 2; time_now = mtime_local(); elapsed_useconds = time_now - HTS_STAT.istat_timestart[id_timer]; // NO totally stupid - elapsed_useconds+=1000; // for the next second, too bytes_transferred_during_period = (HTS_STAT.HTS_TOTAL_RECV - HTS_STAT.istat_bytes[id_timer]); left = ((rate * elapsed_useconds) / 1000) - bytes_transferred_during_period; if (left <= 0) left = 0; return left; } else return TAILLE_BUFFER; } // // 0 : OK // 1 : slow down #if 0 int HTS_TOTAL_RECV_CHECK(int var) { if (HTS_STAT.HTS_TOTAL_RECV_STATE) return 1; /* { if (HTS_STAT.HTS_TOTAL_RECV_STATE==3) { var = min(var,32); Sleep(250); } else if (HTS_STAT.HTS_TOTAL_RECV_STATE==2) { var = min(var,256); Sleep(100); } else { var/=2; if (var<=0) var=1; Sleep(50); } } */ return 0; } #endif // Lecture dans buff de size octets au maximum en utilisant la socket r (structure htsblk) // returns: // >0 : data received // == 0 : not yet data // <0: error or no data: READ_ERROR, READ_EOF or READ_TIMEOUT int hts_read(htsblk * r, char *buff, int size) { int retour; // return read(soc,buff,size); if (r->is_file) { #if HTS_WIDE_DEBUG DEBUG_W("read(%p, %d, %d)\n" _(void *)buff _(int) size _(int) r->fp); #endif if (r->fp) { retour = (int) fread(buff, 1, size, r->fp); if (retour == 0) // can happen with directories (!) retour = READ_ERROR; } else retour = READ_ERROR; } else { #if HTS_WIDE_DEBUG DEBUG_W("recv(%d, %p, %d)\n" _(int) r->soc _(void *)buff _(int) size); if (r->soc == INVALID_SOCKET) printf("!!WIDE_DEBUG ERROR, soc==INVALID hts_read\n"); #endif //HTS_TOTAL_RECV_CHECK(size); // Diminuer au besoin si trop de données reçues #if HTS_USEOPENSSL if (r->ssl) { retour = SSL_read(r->ssl_con, buff, size); if (retour <= 0) { int err_code = SSL_get_error(r->ssl_con, retour); if ((err_code == SSL_ERROR_WANT_READ) || (err_code == SSL_ERROR_WANT_WRITE) ) { retour = 0; /* no data yet (ssl cache) */ } else if (err_code == SSL_ERROR_ZERO_RETURN) { retour = READ_EOF; /* completed */ } else { retour = READ_ERROR; /* eof or error */ } } } else { #endif retour = recv(r->soc, buff, size, 0); if (retour == 0) { retour = READ_EOF; } else if (retour < 0) { retour = READ_ERROR; } } if (retour > 0) // compter flux entrant HTS_STAT.HTS_TOTAL_RECV += retour; #if HTS_USEOPENSSL } #endif #if HTS_WIDE_DEBUG DEBUG_W("recv/read done (%d bytes)\n" _(int) retour); #endif return retour; } // -- Gestion cache DNS -- // 'RX98 // 'capsule' contenant uniquement le cache t_dnscache *hts_cache(httrackp * opt) { assertf(opt != NULL); if (opt->state.dns_cache == NULL) { opt->state.dns_cache = (t_dnscache *) malloct(sizeof(t_dnscache)); memset(opt->state.dns_cache, 0, sizeof(t_dnscache)); } assertf(opt->state.dns_cache != NULL); /* first entry is NULL */ assertf(opt->state.dns_cache->iadr == NULL); return opt->state.dns_cache; } // Free DNS cache. void hts_cache_free(t_dnscache *const root) { if (root != NULL) { t_dnscache *cache; for(cache = root; cache != NULL; ) { t_dnscache *const next = cache->next; cache->next = NULL; freet(cache); cache = next; } } } // lock le cache dns pour tout opération d'ajout // plus prudent quand plusieurs threads peuvent écrire dedans.. // -1: status? 0: libérer 1:locker // MUST BE LOCKED // routine pour le cache - retour optionnel à donner à chaque fois // NULL: nom non encore testé dans le cache // si h_length==0 alors le nom n'existe pas dans le dns static SOCaddr* hts_ghbn(const t_dnscache *cache, const char *const iadr, SOCaddr *const addr) { assertf(addr != NULL); assertf(iadr != NULL); if (*iadr == '\0') { return NULL; } /* first entry is empty */ if (cache->iadr == NULL) { cache = cache->next; } for(; cache != NULL; cache = cache->next) { assertf(cache != NULL); assertf(cache->iadr != NULL); assertf(cache->iadr == (const char*) cache + sizeof(t_dnscache)); if (strcmp(cache->iadr, iadr) == 0) { // ok trouvé if (cache->host_length != 0) { // entrée valide assertf(cache->host_length <= sizeof(cache->host_addr)); SOCaddr_copyaddr2(*addr, cache->host_addr, cache->host_length); return addr; } else { // erreur dans le dns, déja vérifié SOCaddr_clear(*addr); return addr; } } } return NULL; } static SOCaddr* hts_dns_resolve_nocache2_(const char *const hostname, SOCaddr *const addr, const char **error) { { #if HTS_INET6==0 /* IPv4 resolver */ struct hostent *const hp = gethostbyname(hostname); if (hp != NULL) { SOCaddr_copyaddr2(addr, hp->h_addr_list[0], hp->h_length); return SOCaddr_is_valid(addr) ? &addr : NULL; } else { SOCaddr_clear(*addr); } #else /* IPv6 resolver */ struct addrinfo *res = NULL; struct addrinfo hints; int gerr; SOCaddr_clear(*addr); memset(&hints, 0, sizeof(hints)); if (IPV6_resolver == 1) // V4 only (for bogus V6 entries) hints.ai_family = PF_INET; else if (IPV6_resolver == 2) // V6 only (for testing V6 only) hints.ai_family = PF_INET6; else // V4 + V6 hints.ai_family = PF_UNSPEC; hints.ai_socktype = SOCK_STREAM; hints.ai_protocol = IPPROTO_TCP; if ( ( gerr = getaddrinfo(hostname, NULL, &hints, &res) ) == 0) { if (res != NULL) { if (res->ai_addr != NULL && res->ai_addrlen != 0) { SOCaddr_copyaddr2(*addr, res->ai_addr, res->ai_addrlen); } } } else { if (error != NULL) { *error = gai_strerror(gerr); } } if (res) { freeaddrinfo(res); } #endif } return SOCaddr_is_valid(*addr) ? addr : NULL; } HTSEXT_API SOCaddr* hts_dns_resolve_nocache2(const char *const hostname, SOCaddr *const addr, const char **error) { /* Protection */ if (!strnotempty(hostname)) { return NULL; } /* Strip [] if any : [3ffe:b80:1234:1::1] The resolver doesn't seem to handle IP6 addresses in brackets */ if ((hostname[0] == '[') && (hostname[strlen(hostname) - 1] == ']')) { SOCaddr *ret; size_t size = strlen(hostname); char *copy = malloct(size + 1); assertf(copy != NULL); copy[0] = '\0'; strncat(copy, hostname + 1, size - 2); ret = hts_dns_resolve_nocache2_(copy, addr, error); freet(copy); return ret; } else { return hts_dns_resolve_nocache2_(hostname, addr, error); } } HTSEXT_API SOCaddr* hts_dns_resolve_nocache(const char *const hostname, SOCaddr *const addr) { return hts_dns_resolve_nocache2(hostname, addr, NULL); } HTSEXT_API int check_hostname_dns(const char *const hostname) { SOCaddr buffer; return hts_dns_resolve_nocache(hostname, &buffer) != NULL; } // Needs locking // cache dns interne à HTS // ** FREE A FAIRE sur la chaine static SOCaddr* hts_dns_resolve_(httrackp * opt, const char *_iadr, SOCaddr *const addr, const char **error) { char BIGSTK iadr[HTS_URLMAXSIZE * 2]; t_dnscache *cache = hts_cache(opt); // adresse du cache SOCaddr *sa; assertf(opt != NULL); assertf(_iadr != NULL); assertf(addr != NULL); strcpybuff(iadr, jump_identification_const(_iadr)); // couper éventuel : { char *a; if ((a = jump_toport(iadr))) *a = '\0'; } /* get IP from the dns cache */ sa = hts_ghbn(cache, iadr, addr); if (sa != NULL) { return SOCaddr_is_valid(*sa) ? sa : NULL; } else { // non présent dans le cache dns, tester const size_t iadr_len = strlen(iadr) + 1; // find queue for(; cache->next != NULL; cache = cache->next) ; #if DEBUGDNS printf("resolving (not cached) %s\n", iadr); #endif sa = hts_dns_resolve_nocache2(iadr, addr, error); // calculer IP host #if HTS_WIDE_DEBUG DEBUG_W("gethostbyname done\n"); #endif /* attempt to store new entry */ cache->next = malloct(sizeof(t_dnscache) + iadr_len); if (cache->next != NULL) { t_dnscache *const next = cache->next; char *const block = (char*) cache->next; char *const str = block + sizeof(t_dnscache); memcpy(str, iadr, iadr_len); next->iadr = str; if (sa != NULL) { next->host_length = SOCaddr_size(*sa); assertf(next->host_length <= sizeof(next->host_addr)); memcpy(next->host_addr, &SOCaddr_sockaddr(*sa), next->host_length); } else { next->host_length = 0; // non existant dans le dns } next->next = NULL; return sa; } /* return result if any */ return sa; } // retour hp du cache } SOCaddr* hts_dns_resolve2(httrackp * opt, const char *_iadr, SOCaddr *const addr, const char **error) { SOCaddr *ret; hts_mutexlock(&opt->state.lock); ret = hts_dns_resolve_(opt, _iadr, addr, error); hts_mutexrelease(&opt->state.lock); return ret; } SOCaddr* hts_dns_resolve(httrackp * opt, const char *_iadr, SOCaddr *const addr) { return hts_dns_resolve2(opt, _iadr, addr, NULL); } // --- Tracage des mallocs() --- #ifdef HTS_TRACE_MALLOC //#define htsLocker(A, N) htsLocker(A, N) #define htsLocker(A, N) do {} while(0) static mlink trmalloc = { NULL, 0, 0, NULL }; static int trmalloc_id = 0; static htsmutex *mallocMutex = NULL; static void hts_meminit(void) { //if (mallocMutex == NULL) { // mallocMutex = calloc(sizeof(*mallocMutex), 1); // htsLocker(mallocMutex, -999); //} } void *hts_malloc(size_t len) { void *adr; hts_meminit(); htsLocker(mallocMutex, 1); assertf(len > 0); adr = hts_xmalloc(len, 0); htsLocker(mallocMutex, 0); return adr; } void *hts_calloc(size_t len, size_t len2) { void *adr; hts_meminit(); assertf(len > 0); assertf(len2 > 0); htsLocker(mallocMutex, 1); adr = hts_xmalloc(len, len2); htsLocker(mallocMutex, 0); memset(adr, 0, len * len2); return adr; } void *hts_strdup(char *str) { size_t size = str ? strlen(str) : 0; char *adr = (char *) hts_malloc(size + 1); assertf(adr != NULL); strcpy(adr, str ? str : ""); return adr; } void *hts_xmalloc(size_t len, size_t len2) { mlink *lnk = (mlink *) calloc(1, sizeof(mlink)); assertf(lnk != NULL); assertf(len > 0); assertf(len2 >= 0); if (lnk) { void *r = NULL; int size, bsize = sizeof(t_htsboundary); if (len2) size = len * len2; else size = len; size += ((bsize - (size % bsize)) % bsize); /* check alignement */ r = malloc(size + bsize * 2); assertf(r != NULL); if (r) { *((t_htsboundary *) ((char *) r)) = *((t_htsboundary *) ((char *) r + size + bsize)) = htsboundary; ((char *) r) += bsize; /* boundary */ lnk->adr = r; lnk->len = size; lnk->id = trmalloc_id++; lnk->next = trmalloc.next; trmalloc.next = lnk; return r; } else { free(lnk); } } return NULL; } void hts_free(void *adr) { mlink *lnk = &trmalloc; int bsize = sizeof(t_htsboundary); assertf(adr != NULL); if (!adr) { return; } htsLocker(mallocMutex, 1); while(lnk->next != NULL) { if (lnk->next->adr == adr) { mlink *blk_free = lnk->next; assertf(blk_free->id != -1); assertf(*((t_htsboundary *) ((char *) adr - bsize)) == htsboundary); assertf(*((t_htsboundary *) ((char *) adr + blk_free->len)) == htsboundary); lnk->next = lnk->next->next; free((void *) blk_free); //blk_free->id=-1; free((char *) adr - bsize); htsLocker(mallocMutex, 0); return; } lnk = lnk->next; assertf(lnk->next != NULL); } free(adr); htsLocker(mallocMutex, 0); } void *hts_realloc(void *adr, size_t len) { int bsize = sizeof(t_htsboundary); len += ((bsize - (len % bsize)) % bsize); /* check alignement */ if (adr != NULL) { mlink *lnk = &trmalloc; htsLocker(mallocMutex, 1); while(lnk->next != NULL) { if (lnk->next->adr == adr) { { mlink *blk_free = lnk->next; assertf(blk_free->id != -1); assertf(*((t_htsboundary *) ((char *) adr - bsize)) == htsboundary); assertf(*((t_htsboundary *) ((char *) adr + blk_free->len)) == htsboundary); } adr = realloc((char *) adr - bsize, len + bsize * 2); assertf(adr != NULL); lnk->next->adr = (char *) adr + bsize; lnk->next->len = len; *((t_htsboundary *) ((char *) adr)) = *((t_htsboundary *) ((char *) adr + len + bsize)) = htsboundary; htsLocker(mallocMutex, 0); return (char *) adr + bsize; } lnk = lnk->next; assertf(lnk->next != NULL); } htsLocker(mallocMutex, 0); } return hts_malloc(len); } mlink *hts_find(char *adr) { char *stkframe = (char *) &stkframe; mlink *lnk = &trmalloc; int bsize = sizeof(t_htsboundary); assertf(adr != NULL); if (!adr) { return NULL; } htsLocker(mallocMutex, 1); while(lnk->next != NULL) { if (adr >= lnk->next->adr && adr <= lnk->next->adr + lnk->next->len) { /* found */ htsLocker(mallocMutex, 0); return lnk->next; } lnk = lnk->next; } htsLocker(mallocMutex, 0); { int depl = (int) (adr - stkframe); if (depl < 0) depl = -depl; //assertf(depl < 512000); /* near the stack frame.. doesn't look like malloc but stack variable */ return NULL; } } // check the malloct() and calloct() trace stack void hts_freeall(void) { int bsize = sizeof(t_htsboundary); while(trmalloc.next) { #if MEMDEBUG printf("* block %d\t not released: at %d\t (%d\t bytes)\n", trmalloc.next->id, trmalloc.next->adr, trmalloc.next->len); #endif if (trmalloc.next->id != -1) { free((char *) trmalloc.next->adr - bsize); } } } #endif // -- divers // // cut path and project name // patch also initial path void cut_path(char *fullpath, char *path, char *pname) { path[0] = pname[0] = '\0'; if (strnotempty(fullpath)) { if ((fullpath[strlen(fullpath) - 1] == '/') || (fullpath[strlen(fullpath) - 1] == '\\')) fullpath[strlen(fullpath) - 1] = '\0'; if (strlen(fullpath) > 1) { char *a; while((a = strchr(fullpath, '\\'))) *a = '/'; // remplacer par / a = fullpath + strlen(fullpath) - 2; while((*a != '/') && (a > fullpath)) a--; if (*a == '/') a++; strcpybuff(pname, a); strncatbuff(path, fullpath, (int) (a - fullpath)); } } } // -- Gestion protocole ftp -- #ifdef _WIN32 int ftp_available(void) { return 1; } #else int ftp_available(void) { return 1; // ok! //return 0; // SOUS UNIX, PROBLEMESs } #endif static void hts_debug_log_print(const char *format, ...); static int hts_dgb_init = 0; static FILE *hts_dgb_init_fp = NULL; HTSEXT_API void hts_debug(int level) { hts_dgb_init = level; if (hts_dgb_init > 0) { hts_debug_log_print("hts_debug() called"); } } static FILE *hts_dgb_(void) { if (hts_dgb_init_fp == NULL) { if ((hts_dgb_init & 0x80) == 0) { hts_dgb_init_fp = stderr; } else { hts_dgb_init_fp = FOPEN("hts-debug.txt", "wb"); if (hts_dgb_init_fp != NULL) { fprintf(hts_dgb_init_fp, "* Creating file\r\n"); } } } return hts_dgb_init_fp; } static void hts_debug_log_print(const char *format, ...) { if (hts_dgb_init > 0) { const int error = errno; FILE *const fp = hts_dgb_(); va_list args; assertf(format != NULL); va_start(args, format); (void) vfprintf(fp, format, args); va_end(args); fputs("\n", fp); fflush(fp); errno = error; } } HTSEXT_API const char* hts_version(void) { return HTTRACK_VERSIONID; } static int ssl_vulnerable(const char *version) { #ifdef _WIN32 static const char *const match = "OpenSSL 1.0.1"; const size_t match_len = strlen(match); if (version != NULL && strncmp(version, match, match_len) == 0) { // CVE-2014-0160 // "OpenSSL 1.0.1g 7 Apr 2014" const char minor = version[match_len]; return minor == ' ' || ( minor >= 'a' && minor <= 'f' ); } #endif return 0; } /* user abort callback */ htsErrorCallback htsCallbackErr = NULL; HTSEXT_API void hts_set_error_callback(htsErrorCallback handler) { htsCallbackErr = handler; } HTSEXT_API htsErrorCallback hts_get_error_callback(void) { return htsCallbackErr; } static void default_coucal_asserthandler(void *arg, const char* exp, const char* file, int line) { abortf_(exp, file, line); } static int get_loglevel_from_coucal(coucal_loglevel level) { switch(level) { case coucal_log_critical: return LOG_PANIC; break; case coucal_log_warning: return LOG_WARNING; break; case coucal_log_info: return LOG_INFO; break; case coucal_log_debug: return LOG_DEBUG; break; case coucal_log_trace: return LOG_TRACE; break; default: return LOG_ERROR; break; } } /* log to default console */ static void default_coucal_loghandler(void *arg, coucal_loglevel level, const char* format, va_list args) { if (level <= coucal_log_warning) { fprintf(stderr, "** warning: "); } vfprintf(stderr, format, args); fprintf(stderr, "\n"); } /* log to project log */ static void htsopt_coucal_loghandler(void *arg, coucal_loglevel level, const char* format, va_list args) { httrackp *const opt = (httrackp*) arg; if (opt != NULL && opt->log != NULL) { hts_log_vprint(opt, get_loglevel_from_coucal(level), format, args); } else { default_coucal_loghandler(NULL, level, format, args); } } /* attach hashtable logger to project log */ void hts_set_hash_handler(coucal hashtable, httrackp *opt) { /* Init hashtable default assertion handler. */ coucal_set_assert_handler(hashtable, htsopt_coucal_loghandler, default_coucal_asserthandler, opt); } static int hts_init_ok = 0; HTSEXT_API int hts_init(void) { const char *dbg_env; /* */ if (hts_init_ok) return 1; hts_init_ok = 1; /* enable debugging ? */ dbg_env = getenv("HTS_LOG"); if (dbg_env != NULL && *dbg_env != 0) { int level = 0; if (sscanf(dbg_env, "%d", &level) == 1) { hts_debug(level); } } hts_debug_log_print("entering hts_init()"); /* debug */ /* Init hashtable default assertion handler. */ coucal_set_global_assert_handler(default_coucal_loghandler, default_coucal_asserthandler); /* Init threads (lazy init) */ htsthread_init(); /* Ensure external modules are loaded */ hts_debug_log_print("calling htspe_init()"); /* debug */ htspe_init(); /* module load (lazy) */ /* MD5 Auto-test */ { char digest[32 + 2]; const char *atest = "MD5 Checksum Autotest"; digest[0] = '\0'; domd5mem(atest, strlen(atest), digest, 1); /* a42ec44369da07ace5ec1d660ba4a69a */ if (strcmp(digest, "a42ec44369da07ace5ec1d660ba4a69a") != 0) { int fatal_broken_md5 = 0; assertf(fatal_broken_md5); } } hts_debug_log_print("initializing SSL"); /* debug */ #if HTS_USEOPENSSL /* Initialize the OpensSSL library */ if (!openssl_ctx) { const char *version; SSL_load_error_strings(); SSL_library_init(); // Check CVE-2014-0160. version = SSLeay_version(SSLEAY_VERSION); if (ssl_vulnerable(version)) { fprintf(stderr, "SSLeay_version(SSLEAY_VERSION) == '%s'\n", version); abortLog("unable to initialize TLS: OpenSSL version seems vulnerable to heartbleed bug (CVE-2014-0160)"); assertf("OpenSSL version seems vulnerable to heartbleed bug (CVE-2014-0160)" == NULL); } // OpenSSL_add_all_algorithms(); openssl_ctx = SSL_CTX_new(SSLv23_client_method()); if (!openssl_ctx) { fprintf(stderr, "fatal: unable to initialize TLS: SSL_CTX_new(SSLv23_client_method)\n"); abortLog("unable to initialize TLS: SSL_CTX_new(SSLv23_client_method)"); assertf("unable to initialize TLS" == NULL); } } #endif hts_debug_log_print("ending hts_init()"); /* debug */ return 1; } /* will not free thread env. */ HTSEXT_API int hts_uninit(void) { /* hts_init() is a lazy initializer, with limited a allocation (one or two mutexes) ; we won't free anything here as the .h semantic was never being very clear */ return 1; } HTSEXT_API int hts_uninit_module(void) { if (!hts_init_ok) return 1; htsthread_uninit(); htspe_uninit(); hts_init_ok = 0; return 1; } // legacy. do not use HTSEXT_API int hts_log(httrackp * opt, const char *prefix, const char *msg) { if (opt->log != NULL) { fspc(opt, opt->log, prefix); fprintf(opt->log, "%s" LF, msg); return 0; } return 1; /* Error */ } static void (*hts_log_print_callback)(httrackp * opt, int type, const char *format, va_list args) = NULL; HTSEXT_API void hts_set_log_vprint_callback(void (*callback)(httrackp * opt, int type, const char *format, va_list args)) { hts_log_print_callback = callback; } HTSEXT_API void hts_log_vprint(httrackp * opt, int type, const char *format, va_list args) { assertf(format != NULL); if (hts_log_print_callback != NULL) { va_list args_copy; va_copy(args_copy, args); hts_log_print_callback(opt, type, format, args); va_end(args_copy); } if (opt != NULL && opt->log != NULL) { const int save_errno = errno; const char *s_type = "unknown"; const int level = type & 0xff; // Check log level if (opt->debug < level) { return; } switch (level) { case LOG_TRACE: s_type = "trace"; break; case LOG_DEBUG: s_type = "debug"; break; case LOG_INFO: s_type = "info"; break; case LOG_NOTICE: case LOG_WARNING: s_type = "warning"; break; case LOG_ERROR: s_type = "error"; break; case LOG_PANIC: s_type = "panic"; break; } fspc(opt, opt->log, s_type); (void) vfprintf(opt->log, format, args); if ((type & LOG_ERRNO) != 0) { fprintf(opt->log, ": %s", strerror(save_errno)); } fputs(LF, opt->log); if (opt->flush) { fflush(opt->log); } errno = save_errno; } } HTSEXT_API void hts_log_print(httrackp * opt, int type, const char *format, ...) { va_list args; assertf(format != NULL); va_start(args, format); hts_log_vprint(opt, type, format, args); va_end(args); } HTSEXT_API void set_wrappers(httrackp * opt) { // LEGACY } HTSEXT_API int plug_wrapper(httrackp * opt, const char *moduleName, const char *argv) { void *handle = openFunctionLib(moduleName); if (handle != NULL) { t_hts_plug plug = (t_hts_plug) getFunctionPtr(handle, "hts_plug"); t_hts_unplug unplug = (t_hts_unplug) getFunctionPtr(handle, "hts_unplug"); if (plug != NULL) { int ret = plug(opt, argv); if (hts_dgb_init > 0 && opt->log != NULL) { hts_debug_log_print("plugged module '%s' (return code=%d)", moduleName, ret); } if (ret == 1) { /* Success! */ opt->libHandles.handles = (htslibhandle *) realloct(opt->libHandles.handles, (opt->libHandles.count + 1) * sizeof(htslibhandle)); opt->libHandles.handles[opt->libHandles.count].handle = handle; opt->libHandles.handles[opt->libHandles.count].moduleName = strdupt(moduleName); opt->libHandles.count++; return 1; } else { hts_debug_log_print ("* note: error while running entry point 'hts_plug' in %s", moduleName); if (unplug) unplug(opt); } } else { int last_errno = errno; hts_debug_log_print("* note: can't find entry point 'hts_plug' in %s: %s", moduleName, strerror(last_errno)); } closeFunctionLib(handle); return 0; } else { int last_errno = errno; hts_debug_log_print("* note: can't load %s: %s", moduleName, strerror(last_errno)); } return -1; } static void unplug_wrappers(httrackp * opt) { if (opt->libHandles.handles != NULL) { int i; for(i = 0; i < opt->libHandles.count; i++) { if (opt->libHandles.handles[i].handle != NULL) { /* hts_unplug(), the dll exit point (finalizer) */ t_hts_unplug unplug = (t_hts_unplug) getFunctionPtr(opt->libHandles.handles[i].handle, "hts_unplug"); if (unplug != NULL) unplug(opt); closeFunctionLib(opt->libHandles.handles[i].handle); opt->libHandles.handles[i].handle = NULL; } if (opt->libHandles.handles[i].moduleName != NULL) { freet(opt->libHandles.handles[i].moduleName); opt->libHandles.handles[i].moduleName = NULL; } } freet(opt->libHandles.handles); opt->libHandles.handles = NULL; opt->libHandles.count = 0; } } int multipleStringMatch(const char *s, const char *match) { int ret = 0; String name = STRING_EMPTY; if (match == NULL || s == NULL || *s == 0) return 0; for(; *match != 0; match++) { StringClear(name); for(; *match != 0 && *match != '\n'; match++) { StringAddchar(name, *match); } if (StringLength(name) > 0 && strstr(s, StringBuff(name)) != NULL) { ret = 1; break; } } StringFree(name); return ret; } HTSEXT_API httrackp *hts_create_opt(void) { #if ( defined(_WIN32) || defined(__ANDROID__) ) static const char *defaultModules[] = { "htsswf", "htsjava", "httrack-plugin", NULL }; #else static const char *defaultModules[] = { "libhtsswf.so.1", "libhtsjava.so.2", "httrack-plugin", NULL }; #endif httrackp *opt = malloc(sizeof(httrackp)); /* default options */ memset(opt, 0, sizeof(httrackp)); opt->size_httrackp = sizeof(httrackp); /* mutexes */ hts_mutexinit(&opt->state.lock); /* custom wrappers */ opt->libHandles.count = 0; /* default settings */ opt->wizard = 2; // wizard automatique opt->quiet = 0; // questions // opt->travel = 0; // même adresse opt->depth = 9999; // mirror total par défaut opt->extdepth = 0; // mais pas à l'extérieur opt->seeker = 1; // down opt->urlmode = 2; // relatif par défaut opt->no_type_change = 0; // change file types opt->debug = LOG_NOTICE; // small log opt->getmode = 3; // linear scan opt->maxsite = -1; // taille max site (aucune) opt->maxfile_nonhtml = -1; // taille max fichier non html opt->maxfile_html = -1; // idem pour html opt->maxsoc = 4; // nbre socket max opt->fragment = -1; // pas de fragmentation opt->nearlink = 0; // ne pas prendre les liens non-html "adjacents" opt->makeindex = 1; // faire un index opt->kindex = 0; // index 'keyword' opt->delete_old = 1; // effacer anciens fichiers opt->background_on_suspend = 1; // Background the process if Control Z calls signal suspend. opt->makestat = 0; // pas de fichier de stats opt->maketrack = 0; // ni de tracking opt->timeout = 120; // timeout par défaut (2 minutes) opt->cache = 1; // cache prioritaire opt->shell = 0; // pas de shell par defaut opt->proxy.active = 0; // pas de proxy opt->user_agent_send = 1; // envoyer un user-agent StringCopy(opt->user_agent, "Mozilla/4.5 (compatible; HTTrack 3.0x; Windows 98)"); StringCopy(opt->referer, ""); StringCopy(opt->from, ""); opt->savename_83 = 0; // noms longs par défaut opt->savename_type = 0; // avec structure originale opt->savename_delayed = 2; // hard delayed type (default) opt->delayed_cached = 1; // cached delayed type (default) opt->mimehtml = 0; // pas MIME-html opt->parsejava = HTSPARSE_DEFAULT; // parser classes opt->hostcontrol = 0; // PAS de control host pour timeout et traffic jammer opt->retry = 2; // 2 retry par défaut opt->errpage = 1; // copier ou générer une page d'erreur en cas d'erreur (404 etc.) opt->check_type = 1; // vérifier type si inconnu (cgi,asp..) SAUF / considéré comme html opt->all_in_cache = 0; // ne pas tout stocker en cache opt->robots = 2; // traiter les robots.txt opt->external = 0; // liens externes normaux opt->passprivacy = 0; // mots de passe dans les fichiers opt->includequery = 1; // include query-string par défaut opt->mirror_first_page = 0; // pas mode mirror links opt->accept_cookie = 1; // gérer les cookies opt->cookie = NULL; opt->http10 = 0; // laisser http/1.1 opt->nokeepalive = 0; // pas keep-alive opt->nocompression = 0; // pas de compression opt->tolerant = 0; // ne pas accepter content-length incorrect opt->parseall = 1; // tout parser (tags inconnus, par exemple) opt->parsedebug = 0; // pas de mode débuggage opt->norecatch = 0; // ne pas reprendre les fichiers effacés par l'utilisateur opt->verbosedisplay = 0; // pas d'animation texte opt->sizehack = 0; // size hack opt->urlhack = 1; // url hack (normalizer) StringCopy(opt->footer, HTS_DEFAULT_FOOTER); opt->ftp_proxy = 1; // proxy http pour ftp opt->convert_utf8 = 1; // convert html to UTF-8 StringCopy(opt->filelist, ""); StringCopy(opt->lang_iso, "en, *"); StringCopy(opt->accept, "text/html,image/png,image/jpeg,image/pjpeg,image/x-xbitmap,image/svg+xml,image/gif;q=0.9,*/*;q=0.1"); StringCopy(opt->headers, ""); StringCopy(opt->mimedefs, "\n"); // aucun filtre mime (\n IMPORTANT) StringClear(opt->mod_blacklist); // opt->log = stdout; opt->errlog = stderr; opt->flush = 1; // flush sur les fichiers log //opt->aff_progress=0; opt->keyboard = 0; // StringCopy(opt->path_html, ""); StringCopy(opt->path_html_utf8, ""); StringCopy(opt->path_log, ""); StringCopy(opt->path_bin, ""); // opt->maxlink = 100000; // 100,000 liens max par défaut opt->maxfilter = 200; // 200 filtres max par défaut opt->maxcache = 1048576 * 32; // a peu près 32Mo en cache max -- OPTION NON PARAMETRABLE POUR L'INSTANT -- //opt->maxcache_anticipate=256; // maximum de liens à anticiper opt->maxtime = -1; // temps max en secondes opt->maxrate = 100000; // taux maxi opt->maxconn = 5.0; // nombre connexions/s opt->waittime = -1; // wait until.. hh*3600+mm*60+ss // opt->exec = ""; opt->is_update = 0; // not an update (yet) opt->dir_topindex = 0; // do not built top index (yet) // opt->bypass_limits = 0; // enforce limits by default opt->state.stop = 0; // stopper opt->state.exit_xh = 0; // abort // opt->state.is_ended = 0; /* Alocated buffers */ opt->callbacks_fun = (t_hts_htmlcheck_callbacks *) malloct(sizeof(t_hts_htmlcheck_callbacks)); memset(opt->callbacks_fun, 0, sizeof(t_hts_htmlcheck_callbacks)); /* Preload callbacks : java and flash parser, and the automatic user-defined callback */ { int i; for(i = 0; defaultModules[i] != NULL; i++) { int ret = plug_wrapper(opt, defaultModules[i], defaultModules[i]); if (ret == 0) { /* Module aborted initialization */ /* Ignored. */ } } } return opt; } HTSEXT_API size_t hts_sizeof_opt(void) { return sizeof(httrackp); } HTSEXT_API void hts_free_opt(httrackp * opt) { if (opt != NULL) { /* Alocated callbacks */ if (opt->callbacks_fun != NULL) { int i; t_hts_htmlcheck_callbacks_item *items = (t_hts_htmlcheck_callbacks_item *) opt->callbacks_fun; const int size = (int) sizeof(t_hts_htmlcheck_callbacks) / sizeof(t_hts_htmlcheck_callbacks_item); assertf(sizeof(t_hts_htmlcheck_callbacks_item) * size == sizeof(t_hts_htmlcheck_callbacks)); /* Free all linked lists */ for(i = 0; i < size; i++) { t_hts_callbackarg *carg, *next_carg; for(carg = items[i].carg; carg != NULL && (next_carg = carg->prev.carg, carg != NULL); carg = next_carg) { hts_free(carg); } } freet(opt->callbacks_fun); opt->callbacks_fun = NULL; } /* Close library handles */ unplug_wrappers(opt); /* Cache */ if (opt->state.dns_cache != NULL) { t_dnscache *root; hts_mutexlock(&opt->state.lock); root = opt->state.dns_cache; opt->state.dns_cache = NULL; hts_mutexrelease(&opt->state.lock); hts_cache_free(root); } /* Cancel chain */ if (opt->state.cancel != NULL) { htsoptstatecancel *cancel; for(cancel = opt->state.cancel; cancel != NULL;) { htsoptstatecancel *next = cancel->next; if (cancel->url != NULL) { freet(cancel->url); } freet(cancel); cancel = next; } opt->state.cancel = NULL; } /* Free strings */ StringFree(opt->proxy.name); StringFree(opt->proxy.bindhost); StringFree(opt->savename_userdef); StringFree(opt->user_agent); StringFree(opt->referer); StringFree(opt->from); StringFree(opt->lang_iso); StringFree(opt->sys_com); StringFree(opt->mimedefs); StringFree(opt->filelist); StringFree(opt->urllist); StringFree(opt->footer); StringFree(opt->mod_blacklist); StringFree(opt->path_html); StringFree(opt->path_html_utf8); StringFree(opt->path_log); StringFree(opt->path_bin); /* mutexes */ hts_mutexfree(&opt->state.lock); /* Free structure */ free(opt); } } // TEMPORARY - PUT THIS STRUCTURE INSIDE httrackp ! const hts_stat_struct* hts_get_stats(httrackp * opt) { if (opt == NULL) { return NULL; } HTS_STAT.stat_nsocket = 0; HTS_STAT.stat_errors = fspc(opt, NULL, "error"); HTS_STAT.stat_warnings = fspc(opt, NULL, "warning"); HTS_STAT.stat_infos = fspc(opt, NULL, "info"); HTS_STAT.nbk = 0; HTS_STAT.nb = 0; return &HTS_STAT; } // defaut wrappers static void __cdecl htsdefault_init(t_hts_callbackarg * carg) { } static void __cdecl htsdefault_uninit(t_hts_callbackarg * carg) { // hts_freevar(); } static int __cdecl htsdefault_start(t_hts_callbackarg * carg, httrackp * opt) { return 1; } static int __cdecl htsdefault_chopt(t_hts_callbackarg * carg, httrackp * opt) { return 1; } static int __cdecl htsdefault_end(t_hts_callbackarg * carg, httrackp * opt) { return 1; } static int __cdecl htsdefault_preprocesshtml(t_hts_callbackarg * carg, httrackp * opt, char **html, int *len, const char *url_adresse, const char *url_fichier) { return 1; } static int __cdecl htsdefault_postprocesshtml(t_hts_callbackarg * carg, httrackp * opt, char **html, int *len, const char *url_adresse, const char *url_fichier) { return 1; } static int __cdecl htsdefault_checkhtml(t_hts_callbackarg * carg, httrackp * opt, char *html, int len, const char *url_adresse, const char *url_fichier) { return 1; } static int __cdecl htsdefault_loop(t_hts_callbackarg * carg, httrackp * opt, lien_back * back, int back_max, int back_index, int lien_n, int lien_tot, int stat_time, hts_stat_struct * stats) { // appelé à chaque boucle de HTTrack return 1; } static const char *__cdecl htsdefault_query(t_hts_callbackarg * carg, httrackp * opt, const char *question) { return ""; } static const char *__cdecl htsdefault_query2(t_hts_callbackarg * carg, httrackp * opt, const char *question) { return ""; } static const char *__cdecl htsdefault_query3(t_hts_callbackarg * carg, httrackp * opt, const char *question) { return ""; } static int __cdecl htsdefault_check(t_hts_callbackarg * carg, httrackp * opt, const char *adr, const char *fil, int status) { return -1; } static int __cdecl htsdefault_check_mime(t_hts_callbackarg * carg, httrackp * opt, const char *adr, const char *fil, const char *mime, int status) { return -1; } static void __cdecl htsdefault_pause(t_hts_callbackarg * carg, httrackp * opt, const char *lockfile) { while(fexist(lockfile)) { Sleep(1000); } } static void __cdecl htsdefault_filesave(t_hts_callbackarg * carg, httrackp * opt, const char *file) { } static void __cdecl htsdefault_filesave2(t_hts_callbackarg * carg, httrackp * opt, const char *adr, const char *file, const char *sav, int is_new, int is_modified, int not_updated) { } static int __cdecl htsdefault_linkdetected(t_hts_callbackarg * carg, httrackp * opt, char *link) { return 1; } static int __cdecl htsdefault_linkdetected2(t_hts_callbackarg * carg, httrackp * opt, char *link, const char *start_tag) { return 1; } static int __cdecl htsdefault_xfrstatus(t_hts_callbackarg * carg, httrackp * opt, lien_back * back) { return 1; } static int __cdecl htsdefault_savename(t_hts_callbackarg * carg, httrackp * opt, const char *adr_complete, const char *fil_complete, const char *referer_adr, const char *referer_fil, char *save) { return 1; } static int __cdecl htsdefault_sendhead(t_hts_callbackarg * carg, httrackp * opt, char *buff, const char *adr, const char *fil, const char *referer_adr, const char *referer_fil, htsblk * outgoing) { return 1; } static int __cdecl htsdefault_receivehead(t_hts_callbackarg * carg, httrackp * opt, char *buff, const char *adr, const char *fil, const char *referer_adr, const char *referer_fil, htsblk * incoming) { return 1; } static int __cdecl htsdefault_detect(t_hts_callbackarg * carg, httrackp * opt, htsmoduleStruct * str) { return 0; } static int __cdecl htsdefault_parse(t_hts_callbackarg * carg, httrackp * opt, htsmoduleStruct * str) { return 0; } /* Default internal dummy callbacks */ const t_hts_htmlcheck_callbacks default_callbacks = { {htsdefault_init, NULL}, {htsdefault_uninit, NULL}, {htsdefault_start, NULL}, {htsdefault_end, NULL}, {htsdefault_chopt, NULL}, {htsdefault_preprocesshtml, NULL}, {htsdefault_postprocesshtml, NULL}, {htsdefault_checkhtml, NULL}, {htsdefault_query, NULL}, {htsdefault_query2, NULL}, {htsdefault_query3, NULL}, {htsdefault_loop, NULL}, {htsdefault_check, NULL}, {htsdefault_check_mime, NULL}, {htsdefault_pause, NULL}, {htsdefault_filesave, NULL}, {htsdefault_filesave2, NULL}, {htsdefault_linkdetected, NULL}, {htsdefault_linkdetected2, NULL}, {htsdefault_xfrstatus, NULL}, {htsdefault_savename, NULL}, {htsdefault_sendhead, NULL}, {htsdefault_receivehead, NULL}, {htsdefault_detect, NULL}, {htsdefault_parse, NULL} }; #define CALLBACK_OP(CB, NAME, OPERATION, S, FUN) do { \ if (strcmp(NAME, S) == 0) { \ OPERATION(t_hts_htmlcheck_ ##FUN, (CB)->FUN.fun); \ } \ } while(0) #define DISPATCH_CALLBACK(CB, NAME, OPERATION) do { \ CALLBACK_OP(CB, NAME, OPERATION, "init", init); \ CALLBACK_OP(CB, NAME, OPERATION, "free", uninit); \ CALLBACK_OP(CB, NAME, OPERATION, "start", start); \ CALLBACK_OP(CB, NAME, OPERATION, "end", end); \ CALLBACK_OP(CB, NAME, OPERATION, "change-options", chopt); \ CALLBACK_OP(CB, NAME, OPERATION, "preprocess-html", preprocess); \ CALLBACK_OP(CB, NAME, OPERATION, "postprocess-html", postprocess); \ CALLBACK_OP(CB, NAME, OPERATION, "check-html", check_html); \ CALLBACK_OP(CB, NAME, OPERATION, "query", query); \ CALLBACK_OP(CB, NAME, OPERATION, "query2", query2); \ CALLBACK_OP(CB, NAME, OPERATION, "query3", query3); \ CALLBACK_OP(CB, NAME, OPERATION, "loop", loop); \ CALLBACK_OP(CB, NAME, OPERATION, "check-link", check_link); \ CALLBACK_OP(CB, NAME, OPERATION, "check-mime", check_mime); \ CALLBACK_OP(CB, NAME, OPERATION, "pause", pause); \ CALLBACK_OP(CB, NAME, OPERATION, "save-file", filesave); \ CALLBACK_OP(CB, NAME, OPERATION, "save-file2", filesave2); \ CALLBACK_OP(CB, NAME, OPERATION, "link-detected", linkdetected); \ CALLBACK_OP(CB, NAME, OPERATION, "link-detected2", linkdetected2); \ CALLBACK_OP(CB, NAME, OPERATION, "transfer-status", xfrstatus); \ CALLBACK_OP(CB, NAME, OPERATION, "save-name", savename); \ CALLBACK_OP(CB, NAME, OPERATION, "send-header", sendhead); \ CALLBACK_OP(CB, NAME, OPERATION, "receive-header", receivehead); \ } while(0) int hts_set_callback(t_hts_htmlcheck_callbacks * callbacks, const char *name, void *function) { int error = 1; #define CALLBACK_OPERATION(TYPE, FUNCTION) do { \ FUNCTION = (TYPE) function; \ error = 0; \ } while(0) DISPATCH_CALLBACK(callbacks, name, CALLBACK_OPERATION); #undef CALLBACK_OPERATION return error; } void *hts_get_callback(t_hts_htmlcheck_callbacks * callbacks, const char *name) { #define CALLBACK_OPERATION(TYPE, FUNCTION) do { \ return (void*) FUNCTION; \ } while(0) DISPATCH_CALLBACK(callbacks, name, CALLBACK_OPERATION); #undef CALLBACK_OPERATION return NULL; } // end defaut wrappers /* libc stubs */ HTSEXT_API char *hts_strdup(const char *str) { return strdup(str); } HTSEXT_API void *hts_malloc(size_t size) { return malloc(size); } HTSEXT_API void *hts_realloc(void *const data, const size_t size) { return realloc(data, size); } HTSEXT_API void hts_free(void *data) { free(data); } /* Dummy functions */ HTSEXT_API int hts_resetvar(void) { return 0; } #ifdef _WIN32 typedef struct dirent dirent; DIR *opendir(const char *name) { WIN32_FILE_ATTRIBUTE_DATA st; DIR *dir; size_t len; int i; if (name == NULL || *name == '\0') { errno = ENOENT; return NULL; } if (!GetFileAttributesEx(name, GetFileExInfoStandard, &st) || (st.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) == 0) { errno = ENOENT; return NULL; } dir = calloc(sizeof(DIR), 1); if (dir == NULL) { errno = ENOMEM; return NULL; } len = strlen(name); dir->h = INVALID_HANDLE_VALUE; dir->name = malloc(len + 2 + 1); strcpy(dir->name, name); for(i = 0; dir->name[i] != '\0'; i++) { if (dir->name[i] == '/') { dir->name[i] = '\\'; } } strcat(dir->name, "\\*"); return dir; } struct dirent *readdir(DIR * dir) { WIN32_FIND_DATAA find; if (dir->h == INVALID_HANDLE_VALUE) { dir->h = FindFirstFileA(dir->name, &find); } else { if (!FindNextFile(dir->h, &find)) { FindClose(dir->h); dir->h = INVALID_HANDLE_VALUE; } } if (dir->h != INVALID_HANDLE_VALUE) { dir->entry.d_name[0] = 0; strncat(dir->entry.d_name, find.cFileName, HTS_DIRENT_SIZE - 1); return &dir->entry; } errno = ENOENT; return NULL; } int closedir(DIR * dir) { if (dir != NULL) { if (dir->h != INVALID_HANDLE_VALUE) { CloseHandle(dir->h); } if (dir->name != NULL) { free(dir->name); } free(dir); return 0; } errno = EBADF; return -1; } // UTF-8 aware FILE API static void copyWchar(LPWSTR dest, const char *src) { int i; for(i = 0; src[i]; i++) { dest[i] = src[i]; } dest[i] = '\0'; } FILE *hts_fopen_utf8(const char *path, const char *mode) { WCHAR wmode[32]; LPWSTR wpath = hts_convertUTF8StringToUCS2(path, (int) strlen(path), NULL); assertf(strlen(mode) < sizeof(wmode) / sizeof(WCHAR)); copyWchar(wmode, mode); if (wpath != NULL) { FILE *const fp = _wfopen(wpath, wmode); free(wpath); return fp; } else { // Fallback on conversion error. return fopen(path, mode); } } int hts_stat_utf8(const char *path, STRUCT_STAT * buf) { LPWSTR wpath = hts_convertUTF8StringToUCS2(path, (int) strlen(path), NULL); if (wpath != NULL) { const int result = _wstat(wpath, buf); free(wpath); return result; } else { // Fallback on conversion error. return _stat(path, buf); } } int hts_unlink_utf8(const char *path) { LPWSTR wpath = hts_convertUTF8StringToUCS2(path, (int) strlen(path), NULL); if (wpath != NULL) { const int result = _wunlink(wpath); free(wpath); return result; } else { // Fallback on conversion error. return _unlink(path); } } int hts_rename_utf8(const char *oldpath, const char *newpath) { LPWSTR woldpath = hts_convertUTF8StringToUCS2(oldpath, (int) strlen(oldpath), NULL); LPWSTR wnewpath = hts_convertUTF8StringToUCS2(newpath, (int) strlen(newpath), NULL); if (woldpath != NULL && wnewpath != NULL) { const int result = _wrename(woldpath, wnewpath); free(woldpath); free(wnewpath); return result; } else { if (woldpath != NULL) free(woldpath); if (wnewpath != NULL) free(wnewpath); // Fallback on conversion error. return rename(oldpath, newpath); } } int hts_mkdir_utf8(const char *path) { LPWSTR wpath = hts_convertUTF8StringToUCS2(path, (int) strlen(path), NULL); if (wpath != NULL) { const int result = _wmkdir(wpath); free(wpath); return result; } else { // Fallback on conversion error. return _mkdir(path); } } HTSEXT_API int hts_utime_utf8(const char *path, const STRUCT_UTIMBUF * times) { STRUCT_UTIMBUF mtimes = *times; LPWSTR wpath = hts_convertUTF8StringToUCS2(path, (int) strlen(path), NULL); if (wpath != NULL) { const int result = _wutime(wpath, &mtimes); free(wpath); return result; } else { // Fallback on conversion error. return _utime(path, &mtimes); } } #endif // Fin httrack-3.49.5/src/htshelp.c0000644000175000017500000007131214360553245012612 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: httrack.c subroutines: */ /* command-line help system */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* Internal engine bytecode */ #define HTS_INTERNAL_BYTECODE #include "htshelp.h" /* specific definitions */ #include "htsbase.h" #include "htscoremain.h" #include "htscatchurl.h" #include "htslib.h" #include "htsalias.h" #include "htsmodules.h" #ifdef _WIN32 #else #ifdef HAVE_UNISTD_H #include #endif #endif /* END specific definitions */ #define waitkey if (more) { char s[4]; printf("\nMORE.. q to quit\n"); linput(stdin,s,4); if (strcmp(s,"q")==0) quit=1; else printf("Page %d\n\n",++m); } void infomsg(const char *msg) { int l = 0; int m = 0; int more = 0; int quit = 0; int done = 0; // if (msg == NULL) quit = 0; if (msg) { if (!quit) { if (strlen(msg) == 1) { if (msg[0] == '1') { more = 1; return; } } /* afficher alias? */ if (((int) strlen(msg)) > 4) { if (msg[0] == ' ') { if (msg[2] != ' ') { if ((msg[3] == ' ') || (msg[4] == ' ')) { char cmd[32] = "-"; int p = 0; while(cmd[p] == ' ') p++; sscanf(msg + p, "%s", cmd + strlen(cmd)); /* clears cN -> c */ if ((p = (int) strlen(cmd)) > 2) if (cmd[p - 1] == 'N') cmd[p - 1] = '\0'; /* finds alias (if any) */ p = optreal_find(cmd); if (p >= 0) { /* fings type of parameter: number,param,param concatenated,single cmd */ if (strcmp(opttype_value(p), "param") == 0) printf("%s (--%s[=N])\n", msg, optalias_value(p)); else if (strcmp(opttype_value(p), "param1") == 0) printf("%s (--%s )\n", msg, optalias_value(p)); else if (strcmp(opttype_value(p), "param0") == 0) printf("%s (--%s)\n", msg, optalias_value(p)); else printf("%s (--%s)\n", msg, optalias_value(p)); done = 1; } } } } } /* sinon */ if (!done) printf("%s\n", msg); l++; if (l > 20) { l = 0; waitkey; } } } } typedef struct help_wizard_buffers { char urls[HTS_URLMAXSIZE * 2]; char mainpath[256]; char projname[256]; char stropt[2048]; // options char stropt2[2048]; // options longues char strwild[2048]; // wildcards char cmd[4096]; char str[256]; char *argv[256]; } help_wizard_buffers; void help_wizard(httrackp * opt) { help_wizard_buffers *buffers = malloct(sizeof(help_wizard_buffers)); #undef urls #undef mainpath #undef projname #undef stropt #undef stropt2 #undef strwild #undef cmd #undef str #undef argv #define urls (buffers->urls) #define mainpath (buffers->mainpath) #define projname (buffers->projname) #define stropt (buffers->stropt) #define stropt2 (buffers->stropt2) #define strwild (buffers->strwild) #define cmd (buffers->cmd) #define str (buffers->str) #define argv (buffers->argv) //char *urls = (char *) malloct(HTS_URLMAXSIZE * 2); //char *mainpath = (char *) malloct(256); //char *projname = (char *) malloct(256); //char *stropt = (char *) malloct(2048); // options //char *stropt2 = (char *) malloct(2048); // options longues //char *strwild = (char *) malloct(2048); // wildcards //char *cmd = (char *) malloct(4096); //char *str = (char *) malloct(256); //char **argv = (char **) malloct(256 * sizeof(char *)); // char *a; // if (urls == NULL || mainpath == NULL || projname == NULL || stropt == NULL || stropt2 == NULL || strwild == NULL || cmd == NULL || str == NULL || argv == NULL) { fprintf(stderr, "* memory exhausted in %s, line %d\n", __FILE__, __LINE__); return; } urls[0] = mainpath[0] = projname[0] = stropt[0] = stropt2[0] = strwild[0] = cmd[0] = str[0] = '\0'; // strcpybuff(stropt, "-"); mainpath[0] = projname[0] = stropt2[0] = strwild[0] = '\0'; // printf("\n"); printf("Welcome to HTTrack Website Copier (Offline Browser) " HTTRACK_VERSION "%s\n", hts_get_version_info(opt)); printf("Copyright (C) 1998-2017 Xavier Roche and other contributors\n"); #ifdef _WIN32 printf("Note: You are running the commandline version,\n"); printf("run 'WinHTTrack.exe' to get the GUI version.\n"); #endif #ifdef HTTRACK_AFF_WARNING printf("NOTE: " HTTRACK_AFF_WARNING "\n"); #endif #ifdef HTS_PLATFORM_NAME #if USE_BEGINTHREAD printf("[compiled: " HTS_PLATFORM_NAME " - MT]\n"); #else printf("[compiled: " HTS_PLATFORM_NAME "]\n"); #endif #endif printf("To see the option list, enter a blank line or try httrack --help\n"); // // Project name while(strnotempty(projname) == 0) { printf("\n"); printf("Enter project name :"); fflush(stdout); linput(stdin, projname, 250); if (strnotempty(projname) == 0) help("httrack", 1); } // // Path if (strnotempty(hts_gethome())) printf("\nBase path (return=%s/websites/) :", hts_gethome()); else printf("\nBase path (return=current directory) :"); linput(stdin, str, 250); if (!strnotempty(str)) { strcatbuff(str, hts_gethome()); strcatbuff(str, "/websites/"); } if (strnotempty(str)) if ((str[strlen(str) - 1] != '/') && (str[strlen(str) - 1] != '\\')) strcatbuff(str, "/"); strcatbuff(stropt2, "-O \""); strcatbuff(stropt2, str); strcatbuff(stropt2, projname); strcatbuff(stropt2, "\" "); // Créer si ce n'est fait un index.html 1er niveau make_empty_index(str); // printf("\n"); printf("Enter URLs (separated by commas or blank spaces) :"); fflush(stdout); linput(stdin, urls, 250); if (strnotempty(urls)) { while((a = strchr(urls, ','))) *a = ' '; while((a = strchr(urls, '\t'))) *a = ' '; // Action printf("\nAction:\n"); switch (help_query ("Mirror Web Site(s)|Mirror Web Site(s) with Wizard|Just Get Files Indicated|Mirror ALL links in URLs (Multiple Mirror)|Test Links In URLs (Bookmark Test)|Update/Continue a Mirror", 1)) { case 1: break; case 2: strcatbuff(stropt, "W"); break; case 3: strcatbuff(stropt2, "--get "); break; case 4: strcatbuff(stropt2, "--mirrorlinks "); break; case 5: strcatbuff(stropt2, "--testlinks "); break; case 6: strcatbuff(stropt2, "--update "); break; case 0: return; break; } // Proxy printf("\nProxy (return=none) :"); linput(stdin, str, 250); if (strnotempty(str)) { while((a = strchr(str, ' '))) *a = ':'; // port if (!strchr(jump_identification_const(str), ':')) { char str2[256]; printf("\nProxy port (return=8080) :"); linput(stdin, str2, 250); strcatbuff(str, ":"); if (strnotempty(str2) == 0) strcatbuff(str, "8080"); else strcatbuff(str, str2); } strcatbuff(stropt2, "-P "); strcatbuff(stropt2, str); strcatbuff(stropt2, " "); } // Display strcatbuff(stropt2, " -%v "); // Wildcards printf ("\nYou can define wildcards, like: -*.gif +www.*.com/*.zip -*img_*.zip\n"); printf("Wildcards (return=none) :"); linput(stdin, strwild, 250); // Options do { printf ("\nYou can define additional options, such as recurse level (-r), separated by blank spaces\n"); printf("To see the option list, type help\n"); printf("Additional options (return=none) :"); linput(stdin, str, 250); if (strfield2(str, "help")) { help("httrack", 2); } else if (strnotempty(str)) { strcatbuff(stropt2, str); strcatbuff(stropt2, " "); } } while(strfield2(str, "help")); { int argc = 1; int g = 0; int i = 0; // printf("\n"); if (strlen(stropt) == 1) stropt[0] = '\0'; // aucune snprintf(cmd, sizeof(cmd), "%s %s %s %s", urls, stropt, stropt2, strwild); printf("---> Wizard command line: httrack %s\n\n", cmd); printf("Ready to launch the mirror? (Y/n) :"); fflush(stdout); linput(stdin, str, 250); if (strnotempty(str)) { if (!((str[0] == 'y') || (str[0] == 'Y'))) return; } printf("\n"); // couper en morceaux argv[0] = strdup("winhttrack"); argv[1] = cmd; argc++; while(cmd[i]) { if (cmd[i] == '\"') g = !g; if (cmd[i] == ' ') { if (!g) { cmd[i] = '\0'; argv[argc++] = cmd + i + 1; } } i++; } hts_main(argc, argv); } //} else { // help("httrack",1); } /* Free buffers */ free(buffers); #undef urls #undef mainpath #undef projname #undef stropt #undef stropt2 #undef strwild #undef cmd #undef str #undef argv } int help_query(const char *list, int def) { char s[256]; const char *a; int opt; int n = 1; a = list; while(strnotempty(a)) { const char *b = strchr(a, '|'); if (b) { char str[256]; str[0] = '\0'; // strncatbuff(str, a, (int) (b - a)); if (n == def) printf("(enter)\t%d\t%s\n", n++, str); else printf("\t%d\t%s\n", n++, str); a = b + 1; } else a = list + strlen(list); } printf("\t0\tQuit"); do { printf("\n: "); fflush(stdout); linput(stdin, s, 250); } while((strnotempty(s) != 0) && (sscanf(s, "%d", &opt) != 1)); if (strnotempty(s)) return opt; else return def; } // Capture d'URL void help_catchurl(const char *dest_path) { char BIGSTK adr_prox[HTS_URLMAXSIZE * 2]; int port_prox; T_SOC soc = catch_url_init_std(&port_prox, adr_prox); if (soc != INVALID_SOCKET) { char BIGSTK url[HTS_URLMAXSIZE * 2]; char method[32]; char BIGSTK data[32768]; url[0] = method[0] = data[0] = '\0'; // printf ("Okay, temporary proxy installed.\nSet your browser's preferences to:\n\n"); printf("\tProxy's address: \t%s\n\tProxy's port: \t%d\n", adr_prox, port_prox); // if (catch_url(soc, url, method, data)) { char BIGSTK dest[HTS_URLMAXSIZE * 2]; int i = 0; do { snprintf(dest, sizeof(dest), "%s%s%d", dest_path, "hts-post", i); i++; } while(fexist(dest)); { FILE *fp = fopen(dest, "wb"); if (fp) { fwrite(data, strlen(data), 1, fp); fclose(fp); } } // former URL! { char BIGSTK finalurl[HTS_URLMAXSIZE * 2]; inplace_escape_check_url(dest, sizeof(dest)); snprintf(finalurl, sizeof(finalurl), "%s" POSTTOK "file:%s", url, dest); printf("\nThe URL is: \"%s\"\n", finalurl); printf("You can capture it through: httrack \"%s\"\n", finalurl); } } else printf("Unable to analyse the URL\n"); #ifdef _WIN32 closesocket(soc); #else close(soc); #endif } else printf("Unable to create a temporary proxy (no remaining port)\n"); } // Créer un index.html vide void make_empty_index(const char *str) { #if 0 if (!fexist(fconcat(str, "index.html"))) { FILE *fp = fopen(fconcat(str, "index.html"), "wb"); if (fp) { fprintf(fp, "" CRLF); fprintf(fp, "Index is empty!
(File used to index all HTTrack projects)" CRLF); fclose(fp); } } #endif } // mini-aide (h: help) // y void help(const char *app, int more) { char info[2048]; infomsg(""); if (more) infomsg("1"); if (more != 2) { snprintf(info, sizeof(info), "HTTrack version " HTTRACK_VERSION "%s", hts_is_available()); infomsg(info); #ifdef HTTRACK_AFF_WARNING infomsg("NOTE: " HTTRACK_AFF_WARNING); #endif snprintf(info, sizeof(info), "\tusage: %s [-option] [+] [-] [+] [-]", app); infomsg(info); infomsg("\twith options listed below: (* is the default value)"); infomsg(""); } infomsg("General options:"); infomsg (" O path for mirror/logfiles+cache (-O path_mirror[,path_cache_and_logfiles])"); infomsg(""); infomsg("Action options:"); infomsg(" w *mirror web sites"); infomsg(" W mirror web sites, semi-automatic (asks questions)"); infomsg(" g just get files (saved in the current directory)"); infomsg(" i continue an interrupted mirror using the cache"); infomsg (" Y mirror ALL links located in the first level pages (mirror links)"); infomsg(""); infomsg("Proxy options:"); infomsg(" P proxy use (-P proxy:port or -P user:pass@proxy:port)"); infomsg(" %f *use proxy for ftp (f0 don't use)"); infomsg(" %b use this local hostname to make/send requests (-%b hostname)"); infomsg(""); infomsg("Limits options:"); infomsg(" rN set the mirror depth to N (* r9999)"); infomsg(" %eN set the external links depth to N (* %e0)"); infomsg(" mN maximum file length for a non-html file"); infomsg(" mN,N2 maximum file length for non html (N) and html (N2)"); infomsg(" MN maximum overall size that can be uploaded/scanned"); infomsg(" EN maximum mirror time in seconds (60=1 minute, 3600=1 hour)"); infomsg(" AN maximum transfer rate in bytes/seconds (1000=1KB/s max)"); infomsg(" %cN maximum number of connections/seconds (*%c10)"); infomsg (" GN pause transfer if N bytes reached, and wait until lock file is deleted"); infomsg(""); infomsg("Flow control:"); infomsg(" cN number of multiple connections (*c8)"); infomsg (" TN timeout, number of seconds after a non-responding link is shutdown"); infomsg (" RN number of retries, in case of timeout or non-fatal errors (*R1)"); infomsg (" JN traffic jam control, minimum transfert rate (bytes/seconds) tolerated for a link"); infomsg (" HN host is abandoned if: 0=never, 1=timeout, 2=slow, 3=timeout or slow"); infomsg(""); infomsg("Links options:"); infomsg (" %P *extended parsing, attempt to parse all links, even in unknown tags or Javascript (%P0 don't use)"); infomsg (" n get non-html files 'near' an html file (ex: an image located outside)"); infomsg(" t test all URLs (even forbidden ones)"); infomsg (" %L add all URL located in this text file (one URL per line)"); infomsg (" %S add all scan rules located in this text file (one scan rule per line)"); infomsg(""); infomsg("Build options:"); infomsg(" NN structure type (0 *original structure, 1+: see below)"); infomsg(" or user defined structure (-N \"%h%p/%n%q.%t\")"); infomsg (" %N delayed type check, don't make any link test but wait for files download to start instead (experimental) (%N0 don't use, %N1 use for unknown extensions, * %N2 always use)"); infomsg (" %D cached delayed type check, don't wait for remote type during updates, to speedup them (%D0 wait, * %D1 don't wait)"); infomsg(" %M generate a RFC MIME-encapsulated full-archive (.mht)"); infomsg (" LN long names (L1 *long names / L0 8-3 conversion / L2 ISO9660 compatible)"); infomsg (" KN keep original links (e.g. http://www.adr/link) (K0 *relative link, K absolute links, K4 original links, K3 absolute URI links, K5 transparent proxy link)"); infomsg(" x replace external html links by error pages"); infomsg (" %x do not include any password for external password protected websites (%x0 include)"); infomsg (" %q *include query string for local files (useless, for information purpose only) (%q0 don't include)"); infomsg (" o *generate output html file in case of error (404..) (o0 don't generate)"); infomsg(" X *purge old files after update (X0 keep delete)"); infomsg(" %p preserve html files 'as is' (identical to '-K4 -%F \"\"')"); infomsg(" %T links conversion to UTF-8"); infomsg(""); infomsg("Spider options:"); infomsg(" bN accept cookies in cookies.txt (0=do not accept,* 1=accept)"); infomsg (" u check document type if unknown (cgi,asp..) (u0 don't check, * u1 check but /, u2 check always)"); infomsg (" j *parse Java Classes (j0 don't parse, bitmask: |1 parse default, |2 don't parse .class |4 don't parse .js |8 don't be aggressive)"); infomsg (" sN follow robots.txt and meta robots tags (0=never,1=sometimes,* 2=always, 3=always (even strict rules))"); infomsg (" %h force HTTP/1.0 requests (reduce update features, only for old servers or proxies)"); infomsg (" %k use keep-alive if possible, greately reducing latency for small files and test requests (%k0 don't use)"); infomsg (" %B tolerant requests (accept bogus responses on some servers, but not standard!)"); infomsg (" %s update hacks: various hacks to limit re-transfers when updating (identical size, bogus response..)"); infomsg (" %u url hacks: various hacks to limit duplicate URLs (strip //, www.foo.com==foo.com..)"); infomsg (" %A assume that a type (cgi,asp..) is always linked with a mime type (-%A php3,cgi=text/html;dat,bin=application/x-zip)"); infomsg(" shortcut: '--assume standard' is equivalent to -%A " HTS_ASSUME_STANDARD); infomsg (" can also be used to force a specific file type: --assume foo.cgi=text/html"); infomsg (" @iN internet protocol (0=both ipv6+ipv4, 4=ipv4 only, 6=ipv6 only)"); infomsg (" %w disable a specific external mime module (-%w htsswf -%w htsjava)"); infomsg(""); infomsg("Browser ID:"); infomsg (" F user-agent field sent in HTTP headers (-F \"user-agent name\")"); infomsg(" %R default referer field sent in HTTP headers"); infomsg(" %E from email address sent in HTTP headers"); infomsg (" %F footer string in Html code (-%F \"Mirrored [from host %s [file %s [at %s]]]\""); infomsg(" %l preffered language (-%l \"fr, en, jp, *\""); infomsg(" %a accepted formats (-%a \"text/html,image/png;q=0.9,*/*;q=0.1\""); infomsg(" %X additional HTTP header line (-%X \"X-Magic: 42\""); infomsg(""); infomsg("Log, index, cache"); infomsg (" C create/use a cache for updates and retries (C0 no cache,C1 cache is prioritary,* C2 test update before)"); infomsg(" k store all files in cache (not useful if files on disk)"); infomsg(" %n do not re-download locally erased files"); infomsg (" %v display on screen filenames downloaded (in realtime) - * %v1 short version - %v2 full animation"); infomsg(" Q no log - quiet mode"); infomsg(" q no questions - quiet mode"); infomsg(" z log - extra infos"); infomsg(" Z log - debug"); infomsg(" v log on screen"); infomsg(" f *log in files"); infomsg(" f2 one single log file"); infomsg(" I *make an index (I0 don't make)"); infomsg(" %i make a top index for a project folder (* %i0 don't make)"); infomsg(" %I make an searchable index for this mirror (* %I0 don't make)"); infomsg(""); infomsg("Expert options:"); infomsg(" pN priority mode: (* p3)"); infomsg(" p0 just scan, don't save anything (for checking links)"); infomsg(" p1 save only html files"); infomsg(" p2 save only non html files"); infomsg(" *p3 save all files"); infomsg(" p7 get html files before, then treat other files"); infomsg(" S stay on the same directory"); infomsg(" D *can only go down into subdirs"); infomsg(" U can only go to upper directories"); infomsg(" B can both go up&down into the directory structure"); infomsg(" a *stay on the same address"); infomsg(" d stay on the same principal domain"); infomsg(" l stay on the same TLD (eg: .com)"); infomsg(" e go everywhere on the web"); infomsg(" %H debug HTTP headers in logfile"); infomsg(""); infomsg("Guru options: (do NOT use if possible)"); infomsg(" #X *use optimized engine (limited memory boundary checks)"); infomsg(" #0 filter test (-#0 '*.gif' 'www.bar.com/foo.gif')"); infomsg(" #1 simplify test (-#1 ./foo/bar/../foobar)"); infomsg(" #2 type test (-#2 /foo/bar.php)"); infomsg(" #C cache list (-#C '*.com/spider*.gif'"); infomsg(" #R cache repair (damaged cache)"); infomsg(" #d debug parser"); infomsg(" #E extract new.zip cache meta-data in meta.zip"); infomsg(" #f always flush log files"); infomsg(" #FN maximum number of filters"); infomsg(" #h version info"); infomsg(" #K scan stdin (debug)"); infomsg(" #L maximum number of links (-#L1000000)"); infomsg(" #p display ugly progress information"); infomsg(" #P catch URL"); infomsg(" #R old FTP routines (debug)"); infomsg(" #T generate transfer ops. log every minutes"); infomsg(" #u wait time"); infomsg(" #Z generate transfer rate statistics every minutes"); infomsg(""); infomsg ("Dangerous options: (do NOT use unless you exactly know what you are doing)"); infomsg (" %! bypass built-in security limits aimed to avoid bandwidth abuses (bandwidth, simultaneous connections)"); infomsg(" IMPORTANT NOTE: DANGEROUS OPTION, ONLY SUITABLE FOR EXPERTS"); infomsg(" USE IT WITH EXTREME CARE"); infomsg(""); infomsg("Command-line specific options:"); infomsg (" V execute system command after each files ($0 is the filename: -V \"rm \\$0\")"); infomsg (" %W use an external library function as a wrapper (-%W myfoo.so[,myparameters])"); /* infomsg(" %O do a chroot before setuid"); */ infomsg(""); infomsg("Details: Option N"); infomsg(" N0 Site-structure (default)"); infomsg(" N1 HTML in web/, images/other files in web/images/"); infomsg(" N2 HTML in web/HTML, images/other in web/images"); infomsg(" N3 HTML in web/, images/other in web/"); infomsg (" N4 HTML in web/, images/other in web/xxx, where xxx is the file extension (all gif will be placed onto web/gif, for example)"); infomsg(" N5 Images/other in web/xxx and HTML in web/HTML"); infomsg(" N99 All files in web/, with random names (gadget !)"); infomsg(" N100 Site-structure, without www.domain.xxx/"); infomsg (" N101 Identical to N1 except that \"web\" is replaced by the site's name"); infomsg (" N102 Identical to N2 except that \"web\" is replaced by the site's name"); infomsg (" N103 Identical to N3 except that \"web\" is replaced by the site's name"); infomsg (" N104 Identical to N4 except that \"web\" is replaced by the site's name"); infomsg (" N105 Identical to N5 except that \"web\" is replaced by the site's name"); infomsg (" N199 Identical to N99 except that \"web\" is replaced by the site's name"); infomsg(" N1001 Identical to N1 except that there is no \"web\" directory"); infomsg(" N1002 Identical to N2 except that there is no \"web\" directory"); infomsg (" N1003 Identical to N3 except that there is no \"web\" directory (option set for g option)"); infomsg(" N1004 Identical to N4 except that there is no \"web\" directory"); infomsg(" N1005 Identical to N5 except that there is no \"web\" directory"); infomsg(" N1099 Identical to N99 except that there is no \"web\" directory"); infomsg("Details: User-defined option N"); infomsg(" '%n' Name of file without file type (ex: image)"); infomsg(" '%N' Name of file, including file type (ex: image.gif)"); infomsg(" '%t' File type (ex: gif)"); infomsg(" '%p' Path [without ending /] (ex: /someimages)"); infomsg(" '%h' Host name (ex: www.someweb.com)"); infomsg(" '%M' URL MD5 (128 bits, 32 ascii bytes)"); infomsg(" '%Q' query string MD5 (128 bits, 32 ascii bytes)"); infomsg(" '%k' full query string"); infomsg(" '%r' protocol name (ex: http)"); infomsg(" '%q' small query string MD5 (16 bits, 4 ascii bytes)"); infomsg(" '%s?' Short name version (ex: %sN)"); infomsg(" '%[param]' param variable in query string"); infomsg (" '%[param:before:after:empty:notfound]' advanced variable extraction"); infomsg("Details: User-defined option N and advanced variable extraction"); infomsg(" %[param:before:after:empty:notfound]"); infomsg(" param : parameter name"); infomsg(" before : string to prepend if the parameter was found"); infomsg(" after : string to append if the parameter was found"); infomsg (" notfound : string replacement if the parameter could not be found"); infomsg(" empty : string replacement if the parameter was empty"); infomsg (" all fields, except the first one (the parameter name), can be empty"); infomsg(""); infomsg("Details: Option K"); infomsg(" K0 foo.cgi?q=45 -> foo4B54.html?q=45 (relative URI, default)"); infomsg (" K -> http://www.foobar.com/folder/foo.cgi?q=45 (absolute URL)"); infomsg(" K3 -> /folder/foo.cgi?q=45 (absolute URI)"); infomsg(" K4 -> foo.cgi?q=45 (original URL)"); infomsg (" K5 -> http://www.foobar.com/folder/foo4B54.html?q=45 (transparent proxy URL)"); infomsg(""); infomsg("Shortcuts:"); infomsg("--mirror *make a mirror of site(s) (default)"); infomsg ("--get get the files indicated, do not seek other URLs (-qg)"); infomsg("--list add all URL located in this text file (-%L)"); infomsg("--mirrorlinks mirror all links in 1st level pages (-Y)"); infomsg("--testlinks test links in pages (-r1p0C0I0t)"); infomsg ("--spider spider site(s), to test links: reports Errors & Warnings (-p0C0I0t)"); infomsg("--testsite identical to --spider"); infomsg ("--skeleton make a mirror, but gets only html files (-p1)"); infomsg("--update update a mirror, without confirmation (-iC2)"); infomsg ("--continue continue a mirror, without confirmation (-iC1)"); infomsg(""); infomsg ("--catchurl create a temporary proxy to capture an URL or a form post URL"); infomsg("--clean erase cache & log files"); infomsg(""); infomsg("--http10 force http/1.0 requests (-%h)"); infomsg(""); infomsg("Details: Option %W: External callbacks prototypes"); infomsg("see htsdefines.h"); infomsg(""); infomsg("example: httrack www.someweb.com/bob/"); infomsg("means: mirror site www.someweb.com/bob/ and only this site"); infomsg(""); infomsg ("example: httrack www.someweb.com/bob/ www.anothertest.com/mike/ +*.com/*.jpg -mime:application/*"); infomsg ("means: mirror the two sites together (with shared links) and accept any .jpg files on .com sites"); infomsg(""); infomsg("example: httrack www.someweb.com/bob/bobby.html +* -r6"); infomsg ("means get all files starting from bobby.html, with 6 link-depth, and possibility of going everywhere on the web"); infomsg(""); infomsg ("example: httrack www.someweb.com/bob/bobby.html --spider -P proxy.myhost.com:8080"); infomsg("runs the spider on www.someweb.com/bob/bobby.html using a proxy"); infomsg(""); infomsg("example: httrack --update"); infomsg("updates a mirror in the current folder"); infomsg(""); infomsg("example: httrack"); infomsg("will bring you to the interactive mode"); infomsg(""); infomsg("example: httrack --continue"); infomsg("continues a mirror in the current folder"); infomsg(""); snprintf(info, sizeof(info), "HTTrack version " HTTRACK_VERSION "%s", hts_is_available()); infomsg(info); infomsg("Copyright (C) 1998-2017 Xavier Roche and other contributors"); #ifdef HTS_PLATFORM_NAME infomsg("[compiled: " HTS_PLATFORM_NAME "]"); #endif infomsg(NULL); // infomsg(" R *relative links (e.g ../link)\n"); // infomsg(" A absolute links (e.g /www.adr/link)\n"); } httrack-3.49.5/src/htshash.c0000644000175000017500000002671014336470674012616 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: httrack.c subroutines: */ /* hash table system (fast index) */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* Internal engine bytecode */ #define HTS_INTERNAL_BYTECODE #include "htsopt.h" #include "htshash.h" /* specific definitions */ #include "htsbase.h" #include "htsglobal.h" #include "htsmd5.h" #include "htscore.h" #include "coucal.h" /* END specific definitions */ /* Specific macros */ #ifndef malloct #define malloct malloc #define freet free #define calloct calloc #define strcpybuff strcpy #endif // GESTION DES TABLES DE HACHAGE // Méthode à 2 clés (adr+fil), 2e cle facultative // hash[no_enregistrement][pos]->hash est un index dans le tableau général liens // type: numero enregistrement - 0 est case insensitive (sav) 1 (adr+fil) 2 (former_adr+former_fil) // recherche dans la table selon nom1,nom2 et le no d'enregistrement /* Key free handler (NOOP) ; addresses are kept */ static void key_freehandler(void *arg, coucal_key value) { } /* Key strdup (pointer copy) */ static coucal_key key_duphandler(void *arg, coucal_key_const name) { union { coucal_key_const roname; coucal_key name; } u; u.roname = name; return u.name; } /* Key sav hashes are using case-insensitive version */ static coucal_hashkeys key_sav_hashes(void *arg, coucal_key_const key) { hash_struct *const hash = (hash_struct*) arg; convtolower(hash->catbuff, (const char*) key); return coucal_hash_string(hash->catbuff); } /* Key sav comparison is case-insensitive */ static int key_sav_equals(void *arg, coucal_key_const a_, coucal_key_const b_) { const char *const a = (const char*) a_; const char *const b = (const char*) b_; return strcasecmp(a, b) == 0; } static const char* key_sav_debug_print(void *arg, coucal_key_const a) { return (const char*) a; } static const char* value_sav_debug_print(void *arg, coucal_value_const a) { return (char*) a.ptr; } /* Pseudo-key (lien_url structure) hash function */ static coucal_hashkeys key_adrfil_hashes_generic(void *arg, coucal_key_const value, const int former) { hash_struct *const hash = (hash_struct*) arg; const lien_url*const lien = (const lien_url*) value; const char *const adr = !former ? lien->adr : lien->former_adr; const char *const fil = !former ? lien->fil : lien->former_fil; const char *const adr_norm = adr != NULL ? ( hash->normalized ? jump_normalized_const(adr) : jump_identification_const(adr) ) : NULL; // copy address assertf(adr_norm != NULL); strcpy(hash->normfil, adr_norm); // copy link assertf(fil != NULL); if (hash->normalized) { fil_normalized(fil, &hash->normfil[strlen(hash->normfil)]); } else { strcpy(&hash->normfil[strlen(hash->normfil)], fil); } // hash return coucal_hash_string(hash->normfil); } /* Pseudo-key (lien_url structure) comparison function */ static int key_adrfil_equals_generic(void *arg, coucal_key_const a_, coucal_key_const b_, const int former) { hash_struct *const hash = (hash_struct*) arg; const int normalized = hash->normalized; const lien_url*const a = (const lien_url*) a_; const lien_url*const b = (const lien_url*) b_; const char *const a_adr = !former ? a->adr : a->former_adr; const char *const b_adr = !former ? b->adr : b->former_adr; const char *const a_fil = !former ? a->fil : a->former_fil; const char *const b_fil = !former ? b->fil : b->former_fil; const char *ja; const char *jb; // safety assertf(a_adr != NULL); assertf(b_adr != NULL); assertf(a_fil != NULL); assertf(b_fil != NULL); // skip scheme and authentication to the domain (possibly without www.) ja = normalized ? jump_normalized_const(a_adr) : jump_identification_const(a_adr); jb = normalized ? jump_normalized_const(b_adr) : jump_identification_const(b_adr); assertf(ja != NULL); assertf(jb != NULL); if (strcasecmp(ja, jb) != 0) { return 0; } // now compare pathes if (normalized) { fil_normalized(a_fil, hash->normfil); fil_normalized(b_fil, hash->normfil2); return strcmp(hash->normfil, hash->normfil2) == 0; } else { return strcmp(a_fil, b_fil) == 0; } } static const char* key_adrfil_debug_print_(void *arg, coucal_key_const a_, const int former) { hash_struct *const hash = (hash_struct*) arg; const lien_url*const a = (const lien_url*) a_; const char *const a_adr = !former ? a->adr : a->former_adr; const char *const a_fil = !former ? a->fil : a->former_fil; snprintf(hash->normfil, sizeof(hash->normfil), "%s%s", a_adr, a_fil); return hash->normfil; } static const char* key_adrfil_debug_print(void *arg, coucal_key_const a_) { return key_adrfil_debug_print_(arg, a_, 0); } static const char* key_former_adrfil_debug_print(void *arg, coucal_key_const a_) { return key_adrfil_debug_print_(arg, a_, 1); } static const char* value_adrfil_debug_print(void *arg, coucal_value_const value) { hash_struct *const hash = (hash_struct*) arg; snprintf(hash->normfil2, sizeof(hash->normfil2), "%d", (int) value.intg); return hash->normfil2; } /* "adr"/"fil" lien_url structure members hashing function */ static coucal_hashkeys key_adrfil_hashes(void *arg, coucal_key_const value_) { return key_adrfil_hashes_generic(arg, value_, 0); } /* "adr"/"fil" lien_url structure members comparison function */ static int key_adrfil_equals(void *arg, coucal_key_const a, coucal_key_const b) { return key_adrfil_equals_generic(arg, a, b, 0); } /* "former_adr"/"former_fil" lien_url structure members hashing function */ static coucal_hashkeys key_former_adrfil_hashes(void *arg, coucal_key_const value_) { return key_adrfil_hashes_generic(arg, value_, 1); } /* "former_adr"/"former_fil" lien_url structure members comparison function */ static int key_former_adrfil_equals(void *arg, coucal_key_const a, coucal_key_const b) { return key_adrfil_equals_generic(arg, a, b, 1); } void hash_init(httrackp *opt, hash_struct * hash, int normalized) { hash->sav = coucal_new(0); hash->adrfil = coucal_new(0); hash->former_adrfil = coucal_new(0); hash->normalized = normalized; hts_set_hash_handler(hash->sav, opt); hts_set_hash_handler(hash->adrfil, opt); hts_set_hash_handler(hash->former_adrfil, opt); coucal_set_name(hash->sav, "hash->sav"); coucal_set_name(hash->adrfil, "hash->adrfil"); coucal_set_name(hash->former_adrfil, "hash->former_adrfil"); /* Case-insensitive comparison ; keys are direct char* filenames */ coucal_value_set_key_handler(hash->sav, key_duphandler, key_freehandler, key_sav_hashes, key_sav_equals, hash); /* URL-style comparison ; keys are lien_url structure pointers casted to char* */ coucal_value_set_key_handler(hash->adrfil, key_duphandler, key_freehandler, key_adrfil_hashes, key_adrfil_equals, hash); coucal_value_set_key_handler(hash->former_adrfil, key_duphandler, key_freehandler, key_former_adrfil_hashes, key_former_adrfil_equals, hash); /* pretty-printing */ coucal_set_print_handler(hash->sav, key_sav_debug_print, value_sav_debug_print, NULL); coucal_set_print_handler(hash->adrfil, key_adrfil_debug_print, value_adrfil_debug_print, hash); coucal_set_print_handler(hash->former_adrfil, key_former_adrfil_debug_print, value_adrfil_debug_print, hash); } void hash_free(hash_struct *hash) { if (hash != NULL) { coucal_delete(&hash->sav); coucal_delete(&hash->adrfil); coucal_delete(&hash->former_adrfil); } } // retour: position ou -1 si non trouvé int hash_read(const hash_struct * hash, const char *nom1, const char *nom2, hash_struct_type type) { intptr_t intvalue; lien_url lien; /* read */ switch(type) { case HASH_STRUCT_FILENAME: if (coucal_read(hash->sav, nom1, &intvalue)) { return (int) intvalue; } else { return -1; } break; case HASH_STRUCT_ADR_PATH: memset(&lien, 0, sizeof(lien)); lien.adr = key_duphandler(NULL, nom1); lien.fil = key_duphandler(NULL, nom2); if (coucal_read(hash->adrfil, (char*) &lien, &intvalue)) { return (int) intvalue; } else { return -1; } break; case HASH_STRUCT_ORIGINAL_ADR_PATH: memset(&lien, 0, sizeof(lien)); lien.former_adr = key_duphandler(NULL, nom1); lien.former_fil = key_duphandler(NULL, nom2); if (coucal_read(hash->former_adrfil, (char*) &lien, &intvalue)) { return (int) intvalue; } else { return -1; } break; default: assertf(! "unexpected case"); return -1; break; } } // enregistrement lien lpos dans les 3 tables hash1..3 void hash_write(hash_struct * hash, size_t lpos) { /* first entry: destination filename (lowercased) */ coucal_write(hash->sav, (*hash->liens)[lpos]->sav, lpos); /* second entry: URL address and path */ coucal_write(hash->adrfil, (*hash->liens)[lpos], lpos); /* third entry: URL address and path before redirect */ if ((*hash->liens)[lpos]->former_adr) { // former_adr existe? coucal_write(hash->former_adrfil, (*hash->liens)[lpos], lpos); } } httrack-3.49.5/src/htsftp.c0000644000175000017500000010262514360553245012455 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: basic FTP protocol manager */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* Internal engine bytecode */ #define HTS_INTERNAL_BYTECODE // Gestion protocole ftp // Version .05 (01/2000) #include "htsftp.h" #include "htscore.h" #include "htsthread.h" #ifdef _WIN32 #else //inet_ntoa #include #endif #ifdef _WIN32 #ifndef __cplusplus // DOS #include /* _beginthread, _endthread */ #endif #endif // ftp mode passif // #if HTS_INET6==0 #define FTP_PASV 1 // #else // no passive mode for v6 // #define FTP_PASV 0 // #endif #define FTP_DEBUG 0 //#define FORK_DEBUG 0 #if USE_BEGINTHREAD void back_launch_ftp(void *pP) { FTPDownloadStruct *pStruct = (FTPDownloadStruct *) pP; if (pStruct == NULL) return; if (pStruct == NULL) { #if FTP_DEBUG printf("[ftp error: no args]\n"); #endif return; } /* Initialize */ hts_init(); // lancer ftp #if FTP_DEBUG printf("[Launching main ftp routine]\n"); #endif run_launch_ftp(pStruct); // prêt pStruct->pBack->status = STATUS_FTP_READY; /* Delete structure */ free(pP); /* Uninitialize */ hts_uninit(); return; } // lancer en back void launch_ftp(FTPDownloadStruct * params) { // DOS #if FTP_DEBUG printf("[Launching main ftp thread]\n"); #endif hts_newthread(back_launch_ftp, (void *) params); } #else #error No more supported #endif // pour l'arrêt du ftp #ifdef _WIN32 #define _T_SOC_close(soc) do { closesocket(soc); soc=INVALID_SOCKET; } while(0) #else #define _T_SOC_close(soc) do { close(soc); soc=INVALID_SOCKET; } while(0) #endif #define _HALT_FTP { \ if ( soc_ctl != INVALID_SOCKET ) _T_SOC_close(soc_ctl); \ if ( soc_servdat != INVALID_SOCKET ) _T_SOC_close(soc_servdat); \ if ( soc_dat != INVALID_SOCKET ) _T_SOC_close(soc_dat); \ } #define _CHECK_HALT_FTP \ if (stop_ftp(back)) { \ _HALT_FTP \ return 0; \ } // la véritable fonction une fois lancées les routines thread/fork int run_launch_ftp(FTPDownloadStruct * pStruct) { lien_back *back = pStruct->pBack; httrackp *opt = pStruct->pOpt; char user[256] = "anonymous"; char pass[256] = "user@"; char line_retr[2048]; int port = 21; #if FTP_PASV int port_pasv = 0; #endif char BIGSTK adr_ip[1024]; char *adr, *real_adr; const char *ftp_filename = ""; int timeout = 300; // timeout int timeout_onfly = 8; // attente réponse supplémentaire int transfer_list = 0; // directory int rest_understood = 0; // rest command understood // T_SOC soc_ctl = INVALID_SOCKET; T_SOC soc_servdat = INVALID_SOCKET; T_SOC soc_dat = INVALID_SOCKET; SOCaddr server_data; // line_retr[0] = adr_ip[0] = '\0'; timeout = 300; // effacer strcpybuff(back->r.msg, ""); back->r.statuscode = 0; back->r.size = 0; // récupérer user et pass si présents, et sauter user:id@ dans adr real_adr = strchr(back->url_adr, ':'); if (real_adr) real_adr++; else real_adr = back->url_adr; while(*real_adr == '/') real_adr++; // sauter / if ((adr = jump_identification(real_adr)) != real_adr) { // user int i = -1; pass[0] = '\0'; do { i++; user[i] = real_adr[i]; } while((real_adr[i] != ':') && (real_adr[i])); user[i] = '\0'; if (real_adr[i] == ':') { // pass int j = -1; i++; // oui on saute aussi le : do { j++; pass[j] = real_adr[i + j]; } while(((&real_adr[i + j + 1]) < adr) && (real_adr[i + j])); pass[j] = '\0'; } } // Calculer RETR { char *a; #if 0 a = back->url_fil + strlen(back->url_fil) - 1; while((a > back->url_fil) && (*a != '/')) a--; if (*a != '/') { a = NULL; } #else a = back->url_fil; #endif if (a != NULL && *a != '\0') { #if 0 a++; // sauter / #endif ftp_filename = a; if (strnotempty(a)) { char catbuff[CATBUFF_SIZE]; char *ua = unescape_http(catbuff, sizeof(catbuff), a); int len_a = (int) strlen(ua); if (len_a > 0 && ua[len_a - 1] == '/') { /* obviously a directory listing */ transfer_list = 1; snprintf(line_retr, sizeof(line_retr), "LIST -A %s", ua); } else if ((strchr(ua, ' ')) || (strchr(ua, '\"')) || (strchr(ua, '\'')) ) { snprintf(line_retr, sizeof(line_retr), "RETR \"%s\"", ua); } else { /* Regular one */ snprintf(line_retr, sizeof(line_retr), "RETR %s", ua); } } else { transfer_list = 1; snprintf(line_retr, sizeof(line_retr), "LIST -A"); } } else { strcpybuff(back->r.msg, "Unexpected PORT error"); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; } } #if FTP_DEBUG printf("Connecting to %s...\n", adr); #endif // connexion { SOCaddr server; char *a; char _adr[256]; const char *error = "unknown error"; _adr[0] = '\0'; //T_SOC soc_ctl; // effacer structure memset(&server, 0, sizeof(server)); // port a = strchr(adr, ':'); // port if (a) { sscanf(a + 1, "%d", &port); strncatbuff(_adr, adr, (int) (a - adr)); } else strcpybuff(_adr, adr); // récupérer adresse résolue strcpybuff(back->info, "host name"); if (hts_dns_resolve2(opt, _adr, &server, &error) == NULL) { snprintf(back->r.msg, sizeof(back->r.msg), "Unable to get server's address: %s", error); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_NON_FATAL; _HALT_FTP return 0; } _CHECK_HALT_FTP; // copie adresse pour cnx data SOCaddr_copy_SOCaddr(server_data, server); // créer ("attachement") une socket (point d'accès) internet,en flot soc_ctl = (T_SOC) socket(SOCaddr_sinfamily(server), SOCK_STREAM, 0); if (soc_ctl == INVALID_SOCKET) { strcpybuff(back->r.msg, "Unable to create a socket"); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; _HALT_FTP return 0; } SOCaddr_initport(server, port); // server.sin_port = htons((unsigned short int) port); // connexion (bloquante, on est en thread) strcpybuff(back->info, "connect"); if (connect(soc_ctl, &SOCaddr_sockaddr(server), SOCaddr_size(server)) != 0) { strcpybuff(back->r.msg, "Unable to connect to the server"); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; _HALT_FTP return 0; #ifdef _WIN32 } #else } #endif _CHECK_HALT_FTP; { char BIGSTK line[1024]; // envoi du login // --USER-- get_ftp_line(soc_ctl, line, sizeof(line), timeout); // en tête _CHECK_HALT_FTP; if (line[0] == '2') { // ok, connecté strcpybuff(back->info, "login: user"); snprintf(line, sizeof(line), "USER %s", user); send_line(soc_ctl, line); get_ftp_line(soc_ctl, line, sizeof(line), timeout); _CHECK_HALT_FTP; if ((line[0] == '3') || (line[0] == '2')) { // --PASS-- if (line[0] == '3') { strcpybuff(back->info, "login: pass"); snprintf(line, sizeof(line), "PASS %s", pass); send_line(soc_ctl, line); get_ftp_line(soc_ctl, line, sizeof(line), timeout); _CHECK_HALT_FTP; } if (line[0] == '2') { // ok send_line(soc_ctl, "TYPE I"); get_ftp_line(soc_ctl, line, sizeof(line), timeout); _CHECK_HALT_FTP; if (line[0] == '2') { // ok } else { strcpybuff(back->r.msg, "TYPE I error"); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; } #if 0 // --CWD-- char *a; a = back->url_fil + strlen(back->url_fil) - 1; while((a > back->url_fil) && (*a != '/')) a--; if (*a == '/') { // ok repéré char BIGSTK target[1024]; target[0] = '\0'; strncatbuff(target, back->url_fil, (int) (a - back->url_fil)); if (strnotempty(target) == 0) strcatbuff(target, "/"); strcpybuff(back->info, "cwd"); snprintf(line, sizeof(line), "CWD %s", target); send_line(soc_ctl, line); get_ftp_line(soc_ctl, line, sizeof(line), timeout); _CHECK_HALT_FTP; if (line[0] == '2') { send_line(soc_ctl, "TYPE I"); get_ftp_line(soc_ctl, line, sizeof(line), timeout); _CHECK_HALT_FTP; if (line[0] == '2') { // ok.. } else { strcpybuff(back->r.msg, "TYPE I error"); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; } } else { snprintf(back->r.msg, sizeof(back->r.msg), "CWD error: %s", linejmp(line)); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; } // sinon on est prêts } else { strcpybuff(back->r.msg, "Unexpected ftp error"); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; } #endif } else { snprintf(back->r.msg, sizeof(back->r.msg), "Bad password: %s", linejmp(line)); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; } } else { snprintf(back->r.msg, sizeof(back->r.msg), "Bad user name: %s", linejmp(line)); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; } } else { snprintf(back->r.msg, sizeof(back->r.msg), "Connection refused: %s", linejmp(line)); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; } // ok, si on est prêts on écoute sur un port et on demande la sauce if (back->r.statuscode != -1) { // // Pré-REST // #if FTP_PASV if (SOCaddr_getproto(server) == '1') { strcpybuff(back->info, "pasv"); snprintf(line, sizeof(line), "PASV"); send_line(soc_ctl, line); get_ftp_line(soc_ctl, line, sizeof(line), timeout); } else { /* ipv6 */ line[0] = '\0'; } _CHECK_HALT_FTP; if (line[0] == '2') { char *a, *b, *c; a = strchr(line, '('); // exemple: 227 Entering Passive Mode (123,45,67,89,177,27) if (a) { // -- analyse de l'adresse IP et du port -- a++; b = strchr(a, ','); if (b) b = strchr(b + 1, ','); if (b) b = strchr(b + 1, ','); if (b) b = strchr(b + 1, ','); c = a; while((c = strchr(c, ','))) *c = '.'; // remplacer , par . if (b) *b = '\0'; // strcpybuff(adr_ip, a); // copier adresse ip // if (b) { a = b + 1; // début du port b = strchr(a, '.'); if (b) { int n1, n2; // *b = '\0'; b++; c = strchr(b, ')'); if (c) { *c = '\0'; if ((sscanf(a, "%d", &n1) == 1) && (sscanf(b, "%d", &n2) == 1) && (strlen(adr_ip) <= 16)) { port_pasv = n2 + (n1 << 8); } } else { deletesoc(soc_dat); soc_dat = INVALID_SOCKET; } // sinon on est prêts } } // -- fin analyse de l'adresse IP et du port -- } else { snprintf(back->r.msg, sizeof(back->r.msg), "PASV incorrect: %s", linejmp(line)); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; } // sinon on est prêts } else { /* * try epsv (ipv6) * */ strcpybuff(back->info, "pasv"); snprintf(line, sizeof(line), "EPSV"); send_line(soc_ctl, line); get_ftp_line(soc_ctl, line, sizeof(line), timeout); _CHECK_HALT_FTP; if (line[0] == '2') { /* got it */ char *a; a = strchr(line, '('); // exemple: 229 Entering Extended Passive Mode (|||6446|) if ((a != NULL) && (*a == '(') && (*(a + 1)) && (*(a + 1) == *(a + 2)) && (*(a + 1) == *(a + 3)) && (isdigit(*(a + 4))) && (*(a + 5)) ) { unsigned int n1 = 0; if (sscanf(a + 4, "%d", &n1) == 1) { if ((n1 < 65535) && (n1 > 0)) { port_pasv = n1; } } } else { snprintf(back->r.msg, sizeof(back->r.msg), "EPSV incorrect: %s", linejmp(line)); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; } } else { snprintf(back->r.msg, sizeof(back->r.msg), "PASV/EPSV error: %s", linejmp(line)); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; } // sinon on est prêts } #else // rien à faire avant #endif #if FTP_PASV if (port_pasv) { #endif // SIZE if (back->r.statuscode != -1) { if (!transfer_list) { char catbuff[CATBUFF_SIZE]; char *ua = unescape_http(catbuff, sizeof(catbuff), ftp_filename); if ((strchr(ua, ' ')) || (strchr(ua, '\"')) || (strchr(ua, '\'')) ) { snprintf(line, sizeof(line), "SIZE \"%s\"", ua); } else { snprintf(line, sizeof(line), "SIZE %s", ua); } // SIZE? strcpybuff(back->info, "size"); send_line(soc_ctl, line); get_ftp_line(soc_ctl, line, sizeof(line), timeout); _CHECK_HALT_FTP; if (line[0] == '2') { // SIZE compris, ALORS tester REST (sinon pas tester: cf probleme des txt.gz decompresses a la volee) char *szstr = strchr(line, ' '); if (szstr) { LLint size = 0; szstr++; if (sscanf(szstr, LLintP, &size) == 1) { back->r.totalsize = size; } } // REST? if (fexist(back->url_sav) && (transfer_list == 0)) { strcpybuff(back->info, "rest"); snprintf(line, sizeof(line), "REST " LLintP, (LLint) fsize(back->url_sav)); send_line(soc_ctl, line); get_ftp_line(soc_ctl, line, sizeof(line), timeout); _CHECK_HALT_FTP; if ((line[0] == '3') || (line[0] == '2')) { // ok rest_understood = 1; } // sinon tant pis } } // sinon tant pis } } #if FTP_PASV } #endif // // Post-REST // #if FTP_PASV // Ok, se connecter if (port_pasv) { SOCaddr server; int server_size = sizeof(server); const char *error = "unknown error"; // effacer structure memset(&server, 0, sizeof(server)); // infos strcpybuff(back->info, "resolv"); // résoudre if (adr_ip[0]) { hts_dns_resolve2(opt, adr_ip, &server, &error); } else { SOCaddr_copy_SOCaddr(server, server_data); } // infos strcpybuff(back->info, "cnxdata"); #if FTP_DEBUG printf("Data: Connecting to %s:%d...\n", adr_ip, port_pasv); #endif if (server_size > 0) { // socket soc_dat = (T_SOC) socket(SOCaddr_sinfamily(server), SOCK_STREAM, 0); if (soc_dat != INVALID_SOCKET) { // structure: connexion au domaine internet, port 80 (ou autre) SOCaddr_initport(server, port_pasv); if (connect(soc_dat, &SOCaddr_sockaddr(server), SOCaddr_size(server)) == 0) { strcpybuff(back->info, "retr"); strcpybuff(line, line_retr); send_line(soc_ctl, line); get_ftp_line(soc_ctl, line, sizeof(line), timeout); _CHECK_HALT_FTP; if (line[0] == '1') { // OK } else { deletesoc(soc_dat); soc_dat = INVALID_SOCKET; // snprintf(back->r.msg, sizeof(back->r.msg), "RETR command error: %s", linejmp(line)); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; } // sinon on est prêts } else { #if FTP_DEBUG printf("Data: unable to connect\n"); #endif deletesoc(soc_dat); soc_dat = INVALID_SOCKET; // strcpybuff(back->r.msg, "Unable to connect"); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; } // sinon on est prêts } else { strcpybuff(back->r.msg, "Unable to create a socket"); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; } // sinon on est prêts } else { snprintf(back->r.msg, sizeof(back->r.msg), "Unable to resolve IP %s: %s", adr_ip, error); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; } // sinon on est prêts } else { snprintf(back->r.msg, sizeof(back->r.msg), "PASV incorrect: %s", linejmp(line)); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; } // sinon on est prêts #else //T_SOC soc_servdat; strcpybuff(back->info, "listening"); if ((soc_servdat = get_datasocket(line, sizeof(line))) != INVALID_SOCKET) { _CHECK_HALT_FTP; send_line(soc_ctl, line); // envoi du RETR get_ftp_line(soc_ctl, line, sizeof(line), timeout); _CHECK_HALT_FTP; if (line[0] == '2') { // ok strcpybuff(back->info, "retr"); strcpybuff(line, line_retr); send_line(soc_ctl, line); get_ftp_line(soc_ctl, line, sizeof(line), timeout); _CHECK_HALT_FTP; if (line[0] == '1') { //T_SOC soc_dat; if ((soc_dat = accept(soc_servdat, NULL, NULL)) == INVALID_SOCKET) { strcpybuff(back->r.msg, "Unable to accept connection"); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; } } else { snprintf(back->r.msg, sizeof(back->r.msg), "RETR command error: %s", linejmp(line)); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; } } else { snprintf(back->r.msg, sizeof(back->r.msg), "PORT command error: %s", linejmp(line)); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; } #ifdef _WIN32 closesocket(soc_servdat); #else close(soc_servdat); #endif } else { strcpybuff(back->r.msg, "Unable to listen to a port"); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; } #endif // // Ok, connexion initiée // if (soc_dat != INVALID_SOCKET) { if (rest_understood) { // REST envoyée et comprise file_notify(opt, back->url_adr, back->url_fil, back->url_sav, 0, 1, 0); back->r.fp = fileappend(&opt->state.strc, back->url_sav); } else { file_notify(opt, back->url_adr, back->url_fil, back->url_sav, 1, 1, 0); back->r.fp = filecreate(&opt->state.strc, back->url_sav); } strcpybuff(back->info, "receiving"); if (back->r.fp != NULL) { char BIGSTK buff[1024]; int len = 1; int read_len = 1024; //HTS_TOTAL_RECV_CHECK(read_len); // Diminuer au besoin si trop de données reçues while((len > 0) && (!stop_ftp(back))) { // attendre les données len = 1; // pas d'erreur pour le moment switch (wait_socket_receive(soc_dat, timeout)) { case -1: strcpybuff(back->r.msg, "FTP read error"); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; len = 0; // fin break; case 0: snprintf(back->r.msg, sizeof(back->r.msg), "Time out (%d)", timeout); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; len = 0; // fin break; } // réception if (len) { len = recv(soc_dat, buff, read_len, 0); if (len > 0) { back->r.size += len; HTS_STAT.HTS_TOTAL_RECV += len; if (back->r.fp) { if ((INTsys) fwrite(buff, 1, (INTsys) len, back->r.fp) != len) { /* int fcheck; if ((fcheck=check_fatal_io_errno())) { opt->state.exit_xh=-1; } */ strcpybuff(back->r.msg, "Write error"); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; len = 0; // error } } else { strcpybuff(back->r.msg, "Unexpected write error"); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; } } else { // Erreur ou terminé // back->status=STATUS_FTP_READY; // fini back->r.statuscode = 0; if (back->r.totalsize > 0 && back->r.size != back->r.totalsize) { back->r.statuscode = STATUSCODE_INVALID; strcpybuff(back->r.msg, "FTP file incomplete"); } } read_len = 1024; //HTS_TOTAL_RECV_CHECK(read_len); // Diminuer au besoin si trop de données reçues } } if (back->r.fp) { fclose(back->r.fp); back->r.fp = NULL; } } else { strcpybuff(back->r.msg, "Unable to write file"); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; } #ifdef _WIN32 closesocket(soc_dat); #else close(soc_dat); #endif // 226 Transfer complete? if (back->r.statuscode != -1) { if (wait_socket_receive(soc_ctl, timeout_onfly) > 0) { // récupérer 226 transfer complete get_ftp_line(soc_ctl, line, sizeof(line), timeout); if (line[0] == '2') { // OK strcpybuff(back->r.msg, "OK"); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = HTTP_OK; } else { snprintf(back->r.msg, sizeof(back->r.msg), "RETR incorrect: %s", linejmp(line)); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; } } else { strcpybuff(back->r.msg, "FTP read error"); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; } } } } } _CHECK_HALT_FTP; strcpybuff(back->info, "quit"); send_line(soc_ctl, "QUIT"); // bye bye get_ftp_line(soc_ctl, NULL, 0, timeout); #ifdef _WIN32 closesocket(soc_ctl); #else close(soc_ctl); #endif } if (back->r.statuscode != -1) { back->r.statuscode = HTTP_OK; strcpybuff(back->r.msg, "OK"); } // back->status=STATUS_FTP_READY; // fini return 0; } // ouverture d'un port T_SOC get_datasocket(char *to_send, size_t to_send_size) { T_SOC soc = INVALID_SOCKET; char h_loc[256 + 2]; to_send[0] = '\0'; if (gethostname(h_loc, 256) == 0) { // host name SOCaddr server; if (hts_dns_resolve_nocache(h_loc, &server) != NULL) { // notre host if ((soc = (T_SOC) socket(SOCaddr_sinfamily(server), SOCK_STREAM, 0)) != INVALID_SOCKET) { if (bind(soc, &SOCaddr_sockaddr(server), SOCaddr_size(server)) == 0) { SOCaddr server2; SOClen len = SOCaddr_capacity(server2); if (getsockname(soc, &SOCaddr_sockaddr(server2), &len) == 0) { // *port=ntohs(server.sin_port); // récupérer port if (listen(soc, 1) >= 0) { #if HTS_INET6==0 unsigned short int a, n1, n2; // calculer port a = SOCaddr_sinport(server2); n1 = (a & 0xff); n2 = ((a >> 8) & 0xff); { char dots[256 + 2]; char dot[256 + 2]; char *a; SOCaddr_inetntoa(dot, 256, server2); // dots[0] = '\0'; strncatbuff(dots, dot, 128); while((a = strchr(dots, '.'))) *a = ','; // virgules! while((a = strchr(dots, ':'))) *a = ','; // virgules! snprintf(to_send, to_send_size, "PORT %s,%d,%d", dots, n1, n2); } #else /* EPRT |1|132.235.1.2|6275| EPRT |2|1080::8:800:200C:417A|5282| */ { char dot[256 + 2]; SOCaddr_inetntoa(dot, 256, server2); snprintf(to_send, to_send_size, "EPRT |%c|%s|%d|", SOCaddr_getproto(server2), dot, SOCaddr_sinport(server2)); } #endif } else { #ifdef _WIN32 closesocket(soc); #else close(soc); #endif soc = INVALID_SOCKET; } } else { #ifdef _WIN32 closesocket(soc); #else close(soc); #endif soc = INVALID_SOCKET; } } else { #ifdef _WIN32 closesocket(soc); #else close(soc); #endif soc = INVALID_SOCKET; } } } } return soc; } #if FTP_DEBUG FILE *dd = NULL; #endif // routines de réception/émission // 0 = ERROR int send_line(T_SOC soc, const char *data) { char BIGSTK line[1024]; if (_DEBUG_HEAD) { if (ioinfo) { fprintf(ioinfo, "---> %s\x0d\x0a", data); fflush(ioinfo); } } #if FTP_DEBUG if (dd == NULL) dd = fopen("toto.txt", "w"); fprintf(dd, "---> %s\x0d\x0a", data); fflush(dd); printf("---> %s", data); fflush(stdout); #endif snprintf(line, sizeof(line), "%s\x0d\x0a", data); if (check_socket_connect(soc) != 1) { #if FTP_DEBUG printf("!SOC WRITE ERROR\n"); #endif return 0; // erreur, plus connecté! } #if FTP_DEBUG { int r = (send(soc, line, strlen(line), 0) == (int) strlen(line)); printf("%s\x0d\x0a", data); fflush(stdout); return r; } #else return (send(soc, line, (int) strlen(line), 0) == (int) strlen(line)); #endif } int get_ftp_line(T_SOC soc, char *ptrline, size_t line_size, int timeout) { char BIGSTK data[1024]; int i, ok, multiline; #if FTP_DEBUG if (dd == NULL) dd = fopen("toto.txt", "w"); #endif data[0] = '\0'; i = ok = multiline = 0; data[3] = '\0'; do { char b; // vérifier données switch (wait_socket_receive(soc, timeout)) { case -1: // erreur de lecture if (ptrline) snprintf(ptrline, line_size, "500 *read error"); return 0; break; case 0: if (ptrline) snprintf(ptrline, line_size, "500 *read timeout (%d)", timeout); return 0; break; } //HTS_TOTAL_RECV_CHECK(dummy); // Diminuer au besoin si trop de données reçues switch (recv(soc, &b, 1, 0)) { //case 0: break; // pas encore --> erreur (on attend)! case 1: HTS_STAT.HTS_TOTAL_RECV += 1; // compter flux entrant if ((b != 10) && (b != 13)) data[i++] = b; break; default: if (ptrline) snprintf(ptrline, line_size, "500 *read error"); return 0; // error break; } if (((b == 13) || (b == 10)) && (i > 0)) { // CR/LF if ((data[3] == '-') || ((multiline) && (!isdigit((unsigned char) data[0]))) ) { data[3] = '\0'; i = 0; multiline = 1; } else ok = 1; // sortir } } while(!ok); data[i++] = '\0'; if (_DEBUG_HEAD) { if (ioinfo) { fprintf(ioinfo, "<--- %s\x0d\x0a", data); fflush(ioinfo); } } #if FTP_DEBUG fprintf(dd, "<--- %s\n", data); fflush(dd); printf("<--- %s\n", data); #endif if (ptrline) snprintf(ptrline, line_size, "%s", data); return (strnotempty(data)); } // sauter NNN char *linejmp(char *line) { if (strlen(line) > 4) return line + 4; else return line; } // test socket: // 0 : no data // 1 : data detected // -1: error int check_socket(T_SOC soc) { fd_set fds, fds_e; // poll structures struct timeval tv; // structure for select FD_ZERO(&fds); FD_ZERO(&fds_e); // socket read FD_SET(soc, &fds); // socket error FD_SET(soc, &fds_e); tv.tv_sec = 0; tv.tv_usec = 0; // poll! select((int) soc + 1, &fds, NULL, &fds_e, &tv); if (FD_ISSET(soc, &fds_e)) { // error detected return -1; } else if (FD_ISSET(soc, &fds)) { return 1; } return 0; } // check if connected int check_socket_connect(T_SOC soc) { fd_set fds, fds_e; // poll structures struct timeval tv; // structure for select FD_ZERO(&fds); FD_ZERO(&fds_e); // socket write FD_SET(soc, &fds); // socket error FD_SET(soc, &fds_e); tv.tv_sec = 0; tv.tv_usec = 0; // poll! select((int) soc + 1, NULL, &fds, &fds_e, &tv); if (FD_ISSET(soc, &fds_e)) { // error detected return -1; } else if (FD_ISSET(soc, &fds)) { return 1; } return 0; } // attendre des données int wait_socket_receive(T_SOC soc, int timeout) { // attendre les données TStamp ltime = time_local(); int r; #if FTP_DEBUG printf("\x0dWaiting for data "); fflush(stdout); #endif while((!(r = check_socket(soc))) && (((int) ((TStamp) (time_local() - ltime))) < timeout)) { Sleep(100); #if FTP_DEBUG printf("."); fflush(stdout); #endif } #if FTP_DEBUG printf("\x0dreturn: %d\x0d", r); fflush(stdout); #endif return r; } // cancel reçu? int stop_ftp(lien_back * back) { if (back->stop_ftp) { strcpybuff(back->r.msg, "Cancelled by User"); // back->status=STATUS_FTP_READY; // fini back->r.statuscode = STATUSCODE_INVALID; return 1; } return 0; } httrack-3.49.5/src/htsfilters.c0000644000175000017500000002604614336470674013345 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: httrack.c subroutines: */ /* filters ("regexp") */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* Internal engine bytecode */ #define HTS_INTERNAL_BYTECODE // *.gif match all gif files // *[file]/*[file].exe match all exe files with one folder structure // *[A-Z,a-z,0-9,/,?] match letters, nums, / and ? // *[A-Z,a-z,0-9,/,?] // *[>10,<100].gif match all gif files larger than 10KB and smaller than 100KB // *[file,>10,<100].gif FORBIDDEN: you must not mix size test and pattern test #include "htsfilters.h" /* specific definitions */ #include "htsbase.h" #include "htslib.h" #include /* END specific definitions */ // à partir d'un tableau de {"+*.toto","-*.zip","+*.tata"} définit si nom est autorisé // optionnel: taille à contrôller (ou numéro, etc) en pointeur // (en de détection de *size, la taille limite est écrite par dessus *size) // exemple: +-*.gif*[<5] == supprimer GIF si <5KB int fa_strjoker(int type, char **filters, int nfil, const char *nom, LLint * size, int *size_flag, int *depth) { int verdict = 0; // on sait pas int i; LLint sizelimit = 0; if (size) sizelimit = *size; for(i = 0; i < nfil; i++) { LLint sz; int filteroffs = 1; if (strncmp(filters[i] + filteroffs, "mime:", 5) == 0) { if (type == 0) // regular filters continue; filteroffs += 5; // +mime:text/html } else { // mime filters if (type != 0) continue; } if (size) sz = *size; if (strjoker(nom, filters[i] + filteroffs, &sz, size_flag)) { // reconnu if (size) if (sz != *size) sizelimit = sz; if (filters[i][0] == '+') verdict = 1; // autorisé else verdict = -1; // interdit if (depth) *depth = i; } } if (size) *size = sizelimit; return verdict; } // supercomparateur joker (tm) // compare a et b (b=avec joker dedans), case insensitive [voir CI] // renvoi l'adresse de la première lettre de la chaine // (càd *[..]toto.. renvoi adresse de toto dans la chaine) // accepte les délires du genre www.*.*/ * / * truc*.* // cet algo est 'un peu' récursif mais ne consomme pas trop de tm // * = toute lettre // --?-- : spécifique à HTTrack et aux ? HTS_INLINE const char *strjoker(const char *chaine, const char *joker, LLint * size, int *size_flag) { //int err=0; if (strnotempty(joker) == 0) { // fin de chaine joker if (strnotempty(chaine) == 0) // fin aussi pour la chaine: ok return chaine; else if (chaine[0] == '?') return chaine; // --?-- pour les index.html?Choix=2 else return NULL; // non trouvé } // on va progresser en suivant les 'mots' contenus dans le joker // un mot peut être un * ou bien toute autre séquence de lettres if (strcmp(joker, "*") == 0) { // ok, rien après return chaine; } // 1er cas: jokers * ou jokers multiples *[..] if (joker[0] == '*') { // comparer joker+reste (*toto/..) int jmp; // nombre de caractères pour le prochain mot dans joker int cut = 0; // interdire tout caractère superflu char pass[256]; char LEFT = '[', RIGHT = ']'; int unique = 0; switch (joker[1]) { case '[': LEFT = '['; RIGHT = ']'; unique = 0; break; case '(': LEFT = '('; RIGHT = ')'; unique = 1; break; } if ((joker[1] == LEFT) && (joker[2] != LEFT)) { // multijoker (tm) int i; for(i = 0; i < 256; i++) pass[i] = 0; // noms réservés if ((strfield(joker + 2, "file")) || (strfield(joker + 2, "name"))) { for(i = 0; i < 256; i++) pass[i] = 1; pass[(int) '?'] = 0; //pass[(int) ';'] = 0; pass[(int) '/'] = 0; i = 2; { int len = (int) strlen(joker); while((joker[i] != RIGHT) && (joker[i]) && (i < len)) i++; } } else if (strfield(joker + 2, "path")) { for(i = 0; i < 256; i++) pass[i] = 1; pass[(int) '?'] = 0; //pass[(int) ';'] = 0; i = 2; { int len = (int) strlen(joker); while((joker[i] != RIGHT) && (joker[i]) && (i < len)) i++; } } else if (strfield(joker + 2, "param")) { if (chaine[0] == '?') { // il y a un paramètre juste là for(i = 0; i < 256; i++) pass[i] = 1; } // sinon synonyme de 'rien' i = 2; { int len = (int) strlen(joker); while((joker[i] != RIGHT) && (joker[i]) && (i < len)) i++; } } else { // décode les directives comme *[A-Z,âêîôû,0-9] i = 2; if (joker[i] == RIGHT) { // *[] signifie "plus rien après" cut = 1; // caractère supplémentaire interdit } else { int len = (int) strlen(joker); while((joker[i] != RIGHT) && (joker[i]) && (i < len)) { if ((joker[i] == '<') || (joker[i] == '>')) { // *[<10] int lsize = 0; int lverdict; i++; if (sscanf(joker + i, "%d", &lsize) == 1) { if (size) { if (*size >= 0) { if (size_flag) *size_flag = 1; /* a joué */ if (joker[i - 1] == '<') lverdict = (*size < lsize); else lverdict = (*size > lsize); if (!lverdict) { return NULL; // ne correspond pas } else { *size = lsize; return chaine; // ok } } else return NULL; // ne correspond pas } else return NULL; // ne correspond pas (test impossible) // jump while(isdigit((unsigned char) joker[i])) i++; } } else if (joker[i + 1] == '-') { // 2 car, ex: *[A-Z] if ((int) (unsigned char) joker[i + 2] > (int) (unsigned char) joker[i]) { int j; for(j = (int) (unsigned char) joker[i]; j <= (int) (unsigned char) joker[i + 2]; j++) pass[j] = 1; } // else err=1; i += 3; } else { // 1 car, ex: *[ ] if (joker[i + 2] == '\\' && joker[i + 3] != 0) { // escaped char, such as *[\[] or *[\]] i++; } pass[(int) (unsigned char) joker[i]] = 1; i++; } if ((joker[i] == ',') || (joker[i] == ';')) i++; } } } // à sauter dans joker jmp = i; if (joker[i]) jmp++; // } else { // tout autoriser // int i; for(i = 0; i < 256; i++) pass[i] = 1; // tout autoriser jmp = 1; ////if (joker[2]==LEFT) jmp=3; // permet de recher * } { int i, max; const char *adr; // la chaine doit se terminer exactement if (cut) { if (strnotempty(chaine)) return NULL; // perdu else return chaine; // ok } // comparaison en boucle, c'est ca qui consomme huhu.. // le tableau pass[256] indique les caractères ASCII autorisés // tester sans le joker (pas ()+ mais ()*) if (!unique) { if ((adr = strjoker(chaine, joker + jmp, size, size_flag))) { return adr; } } // tester i = 0; if (!unique) max = (int) strlen(chaine); else /* *(a) only match a (not aaaaa) */ max = 1; while(i < (int) max) { if (pass[(int) (unsigned char) chaine[i]]) { // caractère autorisé if ((adr = strjoker(chaine + i + 1, joker + jmp, size, size_flag))) { return adr; } i++; } else i = max + 2; // sortir } // tester chaîne vide if (i != max + 2) // avant c'est ok if ((adr = strjoker(chaine + max, joker + jmp, size, size_flag))) return adr; return NULL; // perdu } } else { // comparer mot+reste (toto*..) if (strnotempty(chaine)) { int jmp = 0, ok = 1; // comparer début de joker et début de chaine while((joker[jmp] != '*') && (joker[jmp]) && (ok)) { // CI : remplacer streql par une comparaison != if (!streql(chaine[jmp], joker[jmp])) { ok = 0; // quitter } jmp++; } // comparaison ok? if (ok) { // continuer la comparaison. if (strjoker(chaine + jmp, joker + jmp, size, size_flag)) return chaine; // retourner 1e lettre } } // strlen(a) return NULL; } // * ou mot return NULL; } // recherche multiple // exemple: find dans un texte de strcpybuff(*[A-Z,a-z],"*[0-9]"); va rechercher la première occurence // d'un strcpy sur une variable ayant un nom en lettres et copiant une chaine de chiffres // ATTENTION!! Eviter les jokers en début, où gare au temps machine! const char *strjokerfind(const char *chaine, const char *joker) { const char *adr; while(*chaine) { if ((adr = strjoker(chaine, joker, NULL, NULL))) { // ok trouvé return adr; } chaine++; } return NULL; } httrack-3.49.5/src/htscatchurl.c0000644000175000017500000001645314336470674013503 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: URL catch .h */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* Internal engine bytecode */ #define HTS_INTERNAL_BYTECODE // Fichier intercepteur d'URL .c /* specific definitions */ /* specific definitions */ #include "htsbase.h" #include "htsnet.h" #include "htslib.h" #include "htscore.h" #include #ifdef _WIN32 #else #include #endif /* END specific definitions */ /* définitions globales */ #include "htsglobal.h" /* htslib */ /*#include "htslib.h"*/ /* catch url */ #include "htscatchurl.h" // URL Link catcher // 0- Init the URL catcher with standard port // catch_url_init(&port,&return_host); HTSEXT_API T_SOC catch_url_init_std(int *port_prox, char *adr_prox) { T_SOC soc; int try_to_listen_to[] = { 8080, 3128, 80, 81, 82, 8081, 3129, 31337, 0, -1 }; int i = 0; do { soc = catch_url_init(&try_to_listen_to[i], adr_prox); *port_prox = try_to_listen_to[i]; i++; } while((soc == INVALID_SOCKET) && (try_to_listen_to[i] >= 0)); return soc; } // 1- Init the URL catcher // catch_url_init(&port,&return_host); HTSEXT_API T_SOC catch_url_init(int *port, /* 128 bytes */ char *adr) { T_SOC soc = INVALID_SOCKET; char h_loc[256]; if (gethostname(h_loc, sizeof(h_loc)) == 0) { // host name SOCaddr server; if (hts_dns_resolve_nocache(h_loc, &server) != NULL) { // notre host if ((soc = (T_SOC) socket(SOCaddr_sinfamily(server), SOCK_STREAM, 0)) != INVALID_SOCKET) { SOCaddr_initport(server, *port); if (bind(soc, &SOCaddr_sockaddr(server), SOCaddr_size(server)) == 0) { SOCaddr server2; SOClen len = SOCaddr_capacity(server2); if (getsockname(soc, &SOCaddr_sockaddr(server2), &len) == 0) { *port = ntohs(SOCaddr_sinport(server)); // récupérer port if (listen(soc, 1) >= 0) { SOCaddr_inetntoa(adr, 128, server2); } else { #ifdef _WIN32 closesocket(soc); #else close(soc); #endif soc = INVALID_SOCKET; } } else { #ifdef _WIN32 closesocket(soc); #else close(soc); #endif soc = INVALID_SOCKET; } } else { #ifdef _WIN32 closesocket(soc); #else close(soc); #endif soc = INVALID_SOCKET; } } } } return soc; } // 2 - Wait for URL // catch_url // returns 0 if error // url: buffer where URL must be stored - or ip:port in case of failure // data: 32Kb HTSEXT_API int catch_url(T_SOC soc, char *url, char *method, char *data) { int retour = 0; // connexion (accept) if (soc != INVALID_SOCKET) { T_SOC soc2; while((soc2 = (T_SOC) accept(soc, NULL, NULL)) == INVALID_SOCKET) ; /* #ifdef _WIN32 closesocket(soc); #else close(soc); #endif */ soc = soc2; /* INFOS */ { SOCaddr server2; SOClen len = SOCaddr_capacity(server2); if (getpeername(soc, &SOCaddr_sockaddr(server2), &len) == 0) { char dot[256 + 2]; SOCaddr_inetntoa(dot, sizeof(dot), server2); sprintf(url, "%s:%d", dot, ntohs(SOCaddr_sinport(server2))); } } /* INFOS */ // réception if (soc != INVALID_SOCKET) { char line[1000]; char protocol[256]; line[0] = protocol[0] = '\0'; // socinput(soc, line, 1000); if (strnotempty(line)) { if (sscanf(line, "%s %s %s", method, url, protocol) == 3) { lien_adrfil af; // méthode en majuscule size_t i; int r = 0; af.adr[0] = af.fil[0] = '\0'; // for(i = 0; method[i] != '\0'; i++) { if ((method[i] >= 'a') && (method[i] <= 'z')) method[i] -= ('a' - 'A'); } // adresse du lien if (ident_url_absolute(url, &af) >= 0) { // Traitement des en-têtes char BIGSTK loc[HTS_URLMAXSIZE * 2]; htsblk blkretour; hts_init_htsblk(&blkretour); //memset(&blkretour, 0, sizeof(htsblk)); // effacer blkretour.location = loc; // si non nul, contiendra l'adresse véritable en cas de moved xx // Lire en têtes restants sprintf(data, "%s %s %s\r\n", method, af.fil, protocol); while(strnotempty(line)) { socinput(soc, line, 1000); treathead(NULL, NULL, NULL, &blkretour, line); // traiter strcatbuff(data, line); strcatbuff(data, "\r\n"); } // CR/LF final de l'en tête inutile car déja placé via la ligne vide juste au dessus //strcatbuff(data,"\r\n"); if (blkretour.totalsize > 0) { int len = (int) min(blkretour.totalsize, 32000); int pos = (int) strlen(data); // Copier le reste (post éventuel) while((len > 0) && ((r = recv(soc, (char *) data + pos, len, 0)) > 0)) { pos += r; len -= r; data[pos] = '\0'; // terminer par NULL } } // Envoyer page sprintf(line, CATCH_RESPONSE); send(soc, line, (int) strlen(line), 0); // OK! retour = 1; } } } // sinon erreur } } if (soc != INVALID_SOCKET) { #ifdef _WIN32 closesocket(soc); /* WSACleanup(); */ #else close(soc); #endif } return retour; } // Lecture de ligne sur socket void socinput(T_SOC soc, char *s, int max) { int c; int j = 0; do { unsigned char b; if (recv(soc, (char *) &b, 1, 0) == 1) { c = b; switch (c) { case 13: break; // sauter CR case 10: c = -1; break; case 9: case 12: break; // sauter ces caractères default: s[j++] = (char) c; break; } } else c = EOF; } while((c != -1) && (c != EOF) && (j < (max - 1))); s[j++] = '\0'; } httrack-3.49.5/src/htscache.c0000644000175000017500000023741114336470674012740 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: httrack.c subroutines: */ /* cache system (index and stores files in cache) */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* Internal engine bytecode */ #define HTS_INTERNAL_BYTECODE #include "htscache.h" /* specific definitions */ #include "htscore.h" #include "htsbasenet.h" #include "htsmd5.h" #include #include "htszlib.h" /* END specific definitions */ // routines de mise en cache /* VERSION 1.0 : ----------- .ndx file file with data (date/time) [ (hostname+filename) (datfile_position_ascii) ] * number_of_links file without data (date/time) [ (hostname+filename) (-datfile_position_ascii) ] * number_of_links .dat file [ file ] * with file= (with data) [ bytes ] * sizeof(htsblk header) [ bytes ] * n(length of file given in htsblk header) file= (without data) [ bytes ] * sizeof(htsblk header) with (name) = ++ VERSION 1.1/1.2 : --------------- .ndx file file with data ("CACHE-1.1") (date/time) [ (hostname+filename) (datfile_position_ascii) ] * number_of_links file without data ("CACHE-1.1") (date/time) [ (hostname+filename) (-datfile_position_ascii) ] * number_of_links .dat file ("CACHE-1.1") [ [Header_1.1] [bytes] * n(length of file given in header) ] * with Header_1.1= (statuscode) (size) (msg) (contenttype) (charset) [version 3] (last-modified) (Etag) location Content-disposition [version 2] hostname [version 4] URI filename [version 4] local filename [version 4] ["SD" (supplemental data)] ["SD" (supplemental data)] ... "HTS" (end of header) (number of bytes of data) (0 if no data written) */ // Nouveau: si != text/html ne stocke que la taille void cache_mayadd(httrackp * opt, cache_back * cache, htsblk * r, const char *url_adr, const char *url_fil, const char *url_save) { hts_log_print(opt, LOG_DEBUG, "File checked by cache: %s", url_adr); // ---stockage en cache--- // stocker dans le cache? if (opt->cache) { if (cache_writable(cache)) { // ensure not a temporary filename (should not happend ?!) if (IS_DELAYED_EXT(url_save)) { hts_log_print(opt, LOG_WARNING, "aborted cache validation: %s%s still has temporary name %s", url_adr, url_fil, url_save); return; } // c'est le seul endroit ou l'on ajoute des elements dans le cache (fichier entier ou header) // on stocke tout fichier "ok", mais également les réponses 404,301,302... if ( #if 1 r->statuscode > 0 #else /* We don't store 5XX errors, because it might be a server problem */ (r->statuscode == HTTP_OK) /* stocker réponse standard, plus */ ||(r->statuscode == 204) /* no content */ ||HTTP_IS_REDIRECT(r->statuscode) /* redirect */ ||(r->statuscode == 401) /* authorization */ ||(r->statuscode == 403) /* unauthorized */ ||(r->statuscode == 404) /* not found */ ||(r->statuscode == 410) /* gone */ #endif ) { /* ne pas stocker si la page générée est une erreur */ if (!r->is_file) { // stocker fichiers (et robots.txt) if (url_save == NULL || (strnotempty(url_save)) || (strcmp(url_fil, "/robots.txt") == 0)) { // ajouter le fichier au cache cache_add(opt, cache, r, url_adr, url_fil, url_save, opt->all_in_cache, StringBuff(opt->path_html_utf8)); // // store a reference NOT to redo the same test zillions of times! // (problem reported by Lars Clausen) // we just store statuscode + location (if any) if (url_save == NULL && r->statuscode / 100 >= 3) { // cached "fast" header doesn't yet exists if (coucal_read (cache->cached_tests, concat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), url_adr, url_fil), NULL) == 0) { char BIGSTK tempo[HTS_URLMAXSIZE * 2]; sprintf(tempo, "%d", (int) r->statuscode); if (r->location != NULL && r->location[0] != '\0') { strcatbuff(tempo, "\n"); strcatbuff(tempo, r->location); } hts_log_print(opt, LOG_DEBUG, "Cached fast-header response: %s%s is %d", url_adr, url_fil, (int) r->statuscode); coucal_add(cache->cached_tests, concat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), url_adr, url_fil), (intptr_t) strdupt(tempo)); } } } } } } } // ---fin stockage en cache--- } #if 1 #define ZIP_FIELD_STRING(headers, headersSize, field, value) do { \ if ( (value != NULL) && (value)[0] != '\0') { \ sprintf(headers + headersSize, "%s: %s\r\n", field, (value != NULL) ? (value) : ""); \ (headersSize) += (int) strlen(headers + headersSize); \ } \ } while(0) #define ZIP_FIELD_INT(headers, headersSize, field, value) do { \ if ( (value != 0) ) { \ sprintf(headers + headersSize, "%s: "LLintP"\r\n", field, (LLint)(value)); \ (headersSize) += (int) strlen(headers + headersSize); \ } \ } while(0) #define ZIP_FIELD_INT_FORCE(headers, headersSize, field, value) do { \ sprintf(headers + headersSize, "%s: "LLintP"\r\n", field, (LLint)(value)); \ (headersSize) += (int) strlen(headers + headersSize); \ } while(0) struct cache_back_zip_entry { unsigned long int hdrPos; unsigned long int size; int compressionMethod; }; #define ZIP_READFIELD_STRING(line, value, refline, refvalue) do { \ if (line[0] != '\0' && strfield2(line, refline)) { \ strcpybuff(refvalue, value); \ line[0] = '\0'; \ } \ } while(0) #define ZIP_READFIELD_INT(line, value, refline, refvalue) do { \ if (line[0] != '\0' && strfield2(line, refline)) { \ int intval = 0; \ sscanf(value, "%d", &intval); \ (refvalue) = intval; \ line[0] = '\0'; \ } \ } while(0) #define ZIP_READFIELD_LLINT(line, value, refline, refvalue) do { \ if (line[0] != '\0' && strfield2(line, refline)) { \ LLint intval = 0; \ sscanf(value, LLintP, &intval); \ (refvalue) = intval; \ line[0] = '\0'; \ } \ } while(0) /* Ajout d'un fichier en cache */ void cache_add(httrackp * opt, cache_back * cache, const htsblk * r, const char *url_adr, const char *url_fil, const char *url_save, int all_in_cache, const char *path_prefix) { char BIGSTK filename[HTS_URLMAXSIZE * 4]; char catbuff[CATBUFF_SIZE]; int dataincache = 0; // put data in cache ? char BIGSTK headers[8192]; int headersSize = 0; //int entryBodySize = 0; //int entryFilenameSize = 0; zip_fileinfo fi; const char *url_save_suffix = url_save; int zErr; // robots.txt hack if (url_save == NULL) { dataincache = 0; // testing links } else { if ((strnotempty(url_save) == 0)) { if (strcmp(url_fil, "/robots.txt") == 0) // robots.txt dataincache = 1; else return; // error (except robots.txt) } /* Data in cache ? */ if (is_hypertext_mime(opt, r->contenttype, url_fil) || (may_be_hypertext_mime(opt, r->contenttype, url_fil) && r->adr != NULL) /* store error messages! */ || !HTTP_IS_OK(r->statuscode) ) { dataincache = 1; } else if (all_in_cache) { dataincache = 1; } } if (r->size < 0) // error return; // data in cache if (dataincache) { assertf(((int) r->size) == r->size); //entryBodySize = (int) r->size; } /* Fields */ headers[0] = '\0'; headersSize = 0; /* */ { const char *message; if (strlen(r->msg) < 32) { message = r->msg; } else { message = "(See X-StatusMessage)"; } /* 64 characters MAX for first line */ sprintf(headers + headersSize, "HTTP/1.%c %d %s\r\n", '1', r->statuscode, message); } headersSize += (int) strlen(headers + headersSize); if (path_prefix != NULL && path_prefix[0] != '\0' && url_save != NULL && url_save[0] != '\0') { int prefixLen = (int) strlen(path_prefix); if (strncmp(url_save, path_prefix, prefixLen) == 0) { url_save_suffix += prefixLen; } } /* Second line MUST ALWAYS be X-In-Cache */ ZIP_FIELD_INT_FORCE(headers, headersSize, "X-In-Cache", dataincache); ZIP_FIELD_INT(headers, headersSize, "X-StatusCode", r->statuscode); ZIP_FIELD_STRING(headers, headersSize, "X-StatusMessage", r->msg); ZIP_FIELD_INT(headers, headersSize, "X-Size", r->size); // size ZIP_FIELD_STRING(headers, headersSize, "Content-Type", r->contenttype); // contenttype ZIP_FIELD_STRING(headers, headersSize, "X-Charset", r->charset); // contenttype ZIP_FIELD_STRING(headers, headersSize, "Last-Modified", r->lastmodified); // last-modified ZIP_FIELD_STRING(headers, headersSize, "Etag", r->etag); // Etag ZIP_FIELD_STRING(headers, headersSize, "Location", r->location); // 'location' pour moved ZIP_FIELD_STRING(headers, headersSize, "Content-Disposition", r->cdispo); // Content-disposition ZIP_FIELD_STRING(headers, headersSize, "X-Addr", url_adr); // Original address ZIP_FIELD_STRING(headers, headersSize, "X-Fil", url_fil); // Original URI filename ZIP_FIELD_STRING(headers, headersSize, "X-Save", url_save_suffix); // Original save filename //entryFilenameSize = (int) ( strlen(url_adr) + strlen(url_fil)); /* Filename */ if (!link_has_authority(url_adr)) { strcpybuff(filename, "http://"); } else { strcpybuff(filename, ""); } strcatbuff(filename, url_adr); strcatbuff(filename, url_fil); /* Time */ memset(&fi, 0, sizeof(fi)); if (r->lastmodified[0] != '\0') { struct tm buffer; struct tm *tm_s = convert_time_rfc822(&buffer, r->lastmodified); if (tm_s) { fi.tmz_date.tm_sec = (uInt) tm_s->tm_sec; fi.tmz_date.tm_min = (uInt) tm_s->tm_min; fi.tmz_date.tm_hour = (uInt) tm_s->tm_hour; fi.tmz_date.tm_mday = (uInt) tm_s->tm_mday; fi.tmz_date.tm_mon = (uInt) tm_s->tm_mon; fi.tmz_date.tm_year = (uInt) tm_s->tm_year; } } /* Open file - NOTE: headers in "comment" */ if ((zErr = zipOpenNewFileInZip((zipFile) cache->zipOutput, filename, &fi, /* Store headers in realtime in the local file directory as extra field In case of crash, we'll be able to recover the whole ZIP file by rescanning it */ headers, (uInt) strlen(headers), NULL, 0, NULL, /* comment */ Z_DEFLATED, Z_DEFAULT_COMPRESSION)) != Z_OK) { int zip_zipOpenNewFileInZip_failed = 0; assertf(zip_zipOpenNewFileInZip_failed); } /* Write data in cache */ if (dataincache) { if (r->is_write == 0) { if (r->size > 0 && r->adr != NULL) { if ((zErr = zipWriteInFileInZip((zipFile) cache->zipOutput, r->adr, (int) r->size)) != Z_OK) { int zip_zipWriteInFileInZip_failed = 0; assertf(zip_zipWriteInFileInZip_failed); } } } else { FILE *fp; // On recopie le fichier->. off_t file_size = fsize_utf8(fconv(catbuff, sizeof(catbuff), url_save)); if (file_size >= 0) { fp = FOPEN(fconv(catbuff, sizeof(catbuff), url_save), "rb"); if (fp != NULL) { char BIGSTK buff[32768]; size_t nl; do { nl = fread(buff, 1, 32768, fp); if (nl > 0) { if ((zErr = zipWriteInFileInZip((zipFile) cache->zipOutput, buff, (int) nl)) != Z_OK) { int zip_zipWriteInFileInZip_failed = 0; assertf(zip_zipWriteInFileInZip_failed); } } } while(nl > 0); fclose(fp); } else { /* Err FIXME - lost file */ } } /* Empty files are OK */ } } /* Close */ if ((zErr = zipCloseFileInZip((zipFile) cache->zipOutput)) != Z_OK) { int zip_zipCloseFileInZip_failed = 0; assertf(zip_zipCloseFileInZip_failed); } /* Flush */ if ((zErr = zipFlush((zipFile) cache->zipOutput)) != 0) { int zip_zipFlush_failed = 0; assertf(zip_zipFlush_failed); } } #else /* Ajout d'un fichier en cache */ void cache_add(httrackp * opt, cache_back * cache, const htsblk * r, char *url_adr, char *url_fil, char *url_save, int all_in_cache) { int pos; char s[256]; char BIGSTK buff[HTS_URLMAXSIZE * 4]; int ok = 1; int dataincache = 0; // donnée en cache? FILE *cache_ndx = cache->ndx; FILE *cache_dat = cache->dat; /*char digest[32+2]; */ /*digest[0]='\0'; */ // Longueur url_save==0? if ((strnotempty(url_save) == 0)) { if (strcmp(url_fil, "/robots.txt") == 0) // robots.txt dataincache = 1; else if (strcmp(url_fil, "/test") == 0) // testing links dataincache = 0; else return; // erreur (sauf robots.txt) } /* if (r->size <= 0) // taille <= 0 return; // refusé.. */ // Mettre les *donées* en cache ? if (is_hypertext_mime(opt, r->contenttype, url_fil)) // html, mise en cache des données et dataincache = 1; // pas uniquement de l'en tête else if (all_in_cache) dataincache = 1; // forcer tout en cache /* calcul md5 ? */ /* if (is_hypertext_mime(opt,r->contenttype)) { // html, calcul MD5 if (r->adr) { domd5mem(r->adr,r->size,digest,1); } } */ // Position fflush(cache_dat); fflush(cache_ndx); pos = ftell(cache_dat); // écrire pointeur seek, adresse, fichier if (dataincache) // patcher sprintf(s, "%d\n", pos); // ecrire tel que (eh oui évite les \0..) else sprintf(s, "%d\n", -pos); // ecrire tel que (eh oui évite les \0..) // data // écrire données en-tête, données fichier /*if (!dataincache) { // patcher r->size=-r->size; // négatif } */ // Construction header ok = 0; if (cache_wint(cache_dat, r->statuscode) != -1 // statuscode && cache_wLLint(cache_dat, r->size) != -1 // size && cache_wstr(cache_dat, r->msg) != -1 // msg && cache_wstr(cache_dat, r->contenttype) != -1 // contenttype && cache_wstr(cache_dat, r->charset) != -1 // contenttype && cache_wstr(cache_dat, r->lastmodified) != -1 // last-modified && cache_wstr(cache_dat, r->etag) != -1 // Etag && cache_wstr(cache_dat, (r->location != NULL) ? r->location : "") != -1 // 'location' pour moved && cache_wstr(cache_dat, r->cdispo) != -1 // Content-disposition && cache_wstr(cache_dat, url_adr) != -1 // Original address && cache_wstr(cache_dat, url_fil) != -1 // Original URI filename && cache_wstr(cache_dat, url_save) != -1 // Original save filename && cache_wstr(cache_dat, r->headers) != -1 // Full HTTP Headers && cache_wstr(cache_dat, "HTS") != -1 // end of header ) { ok = 1; /* ok */ } // Fin construction header /*if ((int) fwrite((char*) &r,1,sizeof(htsblk),cache_dat) == sizeof(htsblk)) { */ if (ok) { if (dataincache) { // mise en cache? if (!r->adr) { /* taille nulle (parfois en cas de 301 */ if (cache_wLLint(cache_dat, 0) == -1) /* 0 bytes */ ok = 0; } else if (r->is_write == 0) { // en mémoire, recopie directe if (cache_wLLint(cache_dat, r->size) != -1) { if (r->size > 0) { // taille>0 if (fwrite(r->adr, 1, r->size, cache_dat) != r->size) ok = 0; } else // taille=0, ne rien écrire ok = 0; } else ok = 0; } else { // recopier fichier dans cache FILE *fp; // On recopie le fichier->. off_t file_size = fsize_utf8(fconv(catbuff, url_save)); if (file_size >= 0) { if (cache_wLLint(cache_dat, file_size) != -1) { fp = FOPEN(fconv(catbuff, url_save), "rb"); if (fp != NULL) { char BIGSTK buff[32768]; ssize_t nl; do { nl = fread(buff, 1, 32768, fp); if (nl > 0) { if (fwrite(buff, 1, nl, cache_dat) != nl) { // erreur nl = -1; ok = 0; } } } while(nl > 0); fclose(fp); } else ok = 0; } else ok = 0; } else ok = 0; } } else { if (cache_wLLint(cache_dat, 0) == -1) /* 0 bytes */ ok = 0; } } else ok = 0; /*if (!dataincache) { // dépatcher r->size=-r->size; } */ // index // adresse+cr+fichier+cr if (ok) { buff[0] = '\0'; strcatbuff(buff, url_adr); strcatbuff(buff, "\n"); strcatbuff(buff, url_fil); strcatbuff(buff, "\n"); cache_wstr(cache_ndx, buff); fwrite(s, 1, strlen(s), cache_ndx); } // si ok=0 on a peut être écrit des données pour rien mais on s'en tape // en cas de plantage, on aura au moins le cache! fflush(cache_dat); fflush(cache_ndx); } #endif htsblk cache_read(httrackp * opt, cache_back * cache, const char *adr, const char *fil, const char *save, char *location) { return cache_readex(opt, cache, adr, fil, save, location, NULL, 0); } htsblk cache_read_ro(httrackp * opt, cache_back * cache, const char *adr, const char *fil, const char *save, char *location) { return cache_readex(opt, cache, adr, fil, save, location, NULL, 1); } htsblk cache_read_including_broken(httrackp * opt, cache_back * cache, const char *adr, const char *fil) { htsblk r = cache_read(opt, cache, adr, fil, NULL, NULL); if (r.statuscode == -1) { lien_back *itemback = NULL; if (back_unserialize_ref(opt, adr, fil, &itemback) == 0) { r = itemback->r; /* cleanup */ back_clear_entry(itemback); /* delete entry content */ freet(itemback); /* delete item */ itemback = NULL; return r; } } return r; } static htsblk cache_readex_old(httrackp * opt, cache_back * cache, const char *adr, const char *fil, const char *save, char *location, char *return_save, int readonly); static htsblk cache_readex_new(httrackp * opt, cache_back * cache, const char *adr, const char *fil, const char *save, char *location, char *return_save, int readonly); // lecture d'un fichier dans le cache // si save==null alors test unqiquement htsblk cache_readex(httrackp * opt, cache_back * cache, const char *adr, const char *fil, const char *save, char *location, char *return_save, int readonly) { if (cache->zipInput != NULL) { return cache_readex_new(opt, cache, adr, fil, save, location, return_save, readonly); } else { return cache_readex_old(opt, cache, adr, fil, save, location, return_save, readonly); } } // lecture d'un fichier dans le cache // si save==null alors test unqiquement static htsblk cache_readex_new(httrackp * opt, cache_back * cache, const char *adr, const char *fil, const char *target_save, char *location, char *return_save, int readonly) { char BIGSTK location_default[HTS_URLMAXSIZE * 2]; char BIGSTK buff[HTS_URLMAXSIZE * 2]; char BIGSTK previous_save[HTS_URLMAXSIZE * 2]; char BIGSTK previous_save_[HTS_URLMAXSIZE * 2]; char catbuff[CATBUFF_SIZE]; intptr_t hash_pos; int hash_pos_return; htsblk r; hts_init_htsblk(&r); //memset(&r, 0, sizeof(htsblk)); r.soc=INVALID_SOCKET; location_default[0] = '\0'; previous_save[0] = previous_save_[0] = '\0'; if (location) { r.location = location; } else { r.location = location_default; } strcpybuff(r.location, ""); strcpybuff(buff, adr); strcatbuff(buff, fil); hash_pos_return = coucal_read(cache->hashtable, buff, &hash_pos); /* avoid errors on data entries */ if (adr[0] == '/' && adr[1] == '/' && adr[2] == '[') { #if HTS_FAST_CACHE hash_pos_return = 0; #else a = NULL; #endif } if (hash_pos_return != 0) { uLong posInZip; if (hash_pos > 0) { posInZip = (uLong) hash_pos; } else { posInZip = (uLong) - hash_pos; } if (unzSetOffset((unzFile) cache->zipInput, posInZip) == Z_OK) { /* Read header (Max 8KiB) */ if (unzOpenCurrentFile((unzFile) cache->zipInput) == Z_OK) { char BIGSTK headerBuff[8192 + 2]; int readSizeHeader; //int totalHeader = 0; int dataincache = 0; /* For BIG comments */ headerBuff[0] = headerBuff[sizeof(headerBuff) - 1] = headerBuff[sizeof(headerBuff) - 2] = headerBuff[sizeof(headerBuff) - 3] = '\0'; if ((readSizeHeader = unzGetLocalExtrafield((unzFile) cache->zipInput, headerBuff, sizeof(headerBuff) - 2)) > 0) /*if (unzGetCurrentFileInfo((unzFile) cache->zipInput, NULL, NULL, 0, NULL, 0, headerBuff, sizeof(headerBuff) - 2) == Z_OK ) */ { int offset = 0; char BIGSTK line[HTS_URLMAXSIZE + 2]; int lineEof = 0; /*readSizeHeader = (int) strlen(headerBuff); */ headerBuff[readSizeHeader] = '\0'; do { char *value; line[0] = '\0'; offset += binput(headerBuff + offset, line, sizeof(line) - 2); if (line[0] == '\0') { lineEof = 1; } value = strchr(line, ':'); if (value != NULL) { *value++ = '\0'; if (*value == ' ' || *value == '\t') value++; ZIP_READFIELD_INT(line, value, "X-In-Cache", dataincache); ZIP_READFIELD_INT(line, value, "X-Statuscode", r.statuscode); ZIP_READFIELD_STRING(line, value, "X-StatusMessage", r.msg); // msg ZIP_READFIELD_LLINT(line, value, "X-Size", r.size); // size ZIP_READFIELD_STRING(line, value, "Content-Type", r.contenttype); // contenttype ZIP_READFIELD_STRING(line, value, "X-Charset", r.charset); // contenttype ZIP_READFIELD_STRING(line, value, "Last-Modified", r.lastmodified); // last-modified ZIP_READFIELD_STRING(line, value, "Etag", r.etag); // Etag ZIP_READFIELD_STRING(line, value, "Location", r.location); // 'location' pour moved ZIP_READFIELD_STRING(line, value, "Content-Disposition", r.cdispo); // Content-disposition //ZIP_READFIELD_STRING(line, value, "X-Addr", ..); // Original address //ZIP_READFIELD_STRING(line, value, "X-Fil", ..); // Original URI filename ZIP_READFIELD_STRING(line, value, "X-Save", previous_save_); // Original save filename } } while(offset < readSizeHeader && !lineEof); //totalHeader = offset; /* Previous entry */ if (previous_save_[0] != '\0') { int pathLen = (int) strlen(StringBuff(opt->path_html_utf8)); if (pathLen != 0 && strncmp(previous_save_, StringBuff(opt->path_html_utf8), pathLen) != 0) { // old (<3.40) buggy format sprintf(previous_save, "%s%s", StringBuff(opt->path_html_utf8), previous_save_); } else { strcpy(previous_save, previous_save_); } } if (return_save != NULL) { strcpybuff(return_save, previous_save); } /* Complete fields */ r.totalsize = r.size; r.adr = NULL; r.out = NULL; r.fp = NULL; /* Do not get data ? Do some final tests. */ if (target_save == NULL) { // si save==null, ne rien charger (juste en tête) if (r.statuscode == HTTP_OK && !is_hypertext_mime(opt, r.contenttype, fil)) { // pas HTML, écrire sur disk directement r.is_write = 1; /* supposed to be on disk (informational) */ } /* Ensure the file is present, because returning a reference to a missing file is useless! */ if (!dataincache) { /* Data are supposed to be on disk */ if (!fexist_utf8(fconv(catbuff, sizeof(catbuff), previous_save))) { // un fichier existe déja if (!opt->norecatch) { hts_log_print(opt, LOG_DEBUG, "Cache: could not find %s", previous_save); r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "Previous cache file not found"); } } } // otherwise, the ZIP file is supposed to be consistent with data. } /* Read data ? */ else { /* ne pas lire uniquement header */ int ok = 0; #if HTS_DIRECTDISK // Not ro, and pure data (not HTML and friends) to be saved now. if (!readonly && r.statuscode == HTTP_OK && !is_hypertext_mime(opt, r.contenttype, fil) && strnotempty(target_save)) { // pas HTML, écrire sur disk directement r.is_write = 1; // écrire // Data is supposed to be on disk if (!dataincache) { r.msg[0] = '\0'; // File exists on disk with declared cache name (this is expected!) if (fexist_utf8(fconv(catbuff, sizeof(catbuff), previous_save))) { // un fichier existe déja // Expected size ? const size_t fsize = fsize_utf8(fconv(catbuff, sizeof(catbuff), previous_save)); if (fsize == r.size) { // Target name is the previous name, and the file looks good: nothing to do! if (strcmp(previous_save, target_save) == 0) { // So far so good ok = 1; // plus rien à faire } // Different filenames: rename now! else { char catbuff2[CATBUFF_SIZE]; if (RENAME (fconv(catbuff, sizeof(catbuff), previous_save), fconv(catbuff2, sizeof(catbuff2), target_save)) == 0) { // So far so good ok = 1; // plus rien à faire hts_log_print(opt, LOG_DEBUG, "File '%s' has been renamed since last mirror to '%s' ; applying changes", previous_save, target_save); } else { r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "Unable to rename file on disk"); } } } else { hts_log_print(opt, LOG_WARNING, "warning: file size on disk (" LLintP ") does not have the expected size (" LLintP "))", (LLint) fsize, (LLint) r.size); } } // File exists with the target name and not previous one ? // Suppose a broken mirror, with a file being renamed: OK else if (fexist_utf8(fconv(catbuff, sizeof(catbuff), target_save))) { // Expected size ? const size_t fsize = fsize_utf8(fconv(catbuff, sizeof(catbuff), target_save)); if (fsize == r.size) { // So far so good ok = 1; // plus rien à faire } else { hts_log_print(opt, LOG_WARNING, "warning: renamed file size on disk (" LLintP ") does not have the expected size (" LLintP "))", (LLint) fsize, (LLint) r.size); } } // File is present and sane ? if (ok) { // Register file not to wipe it later filenote(&opt->state.strc, target_save, NULL); // noter comme connu file_notify(opt, adr, fil, target_save, 0, 0, 1); // data in cache } // Nope else { // Default behavior if (!opt->norecatch) { r.statuscode = STATUSCODE_INVALID; if (r.msg[0] == '\0') { strcpybuff(r.msg, "Previous cache file not found"); } } // Do not recatch broken/erased files else { file_notify(opt, adr, fil, target_save, 1, 0, 0); filecreateempty(&opt->state.strc, target_save); // r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "File deleted by user not recaught"); } } } // Load data from cache (not from a disk file) else { file_notify(opt, adr, fil, target_save, 1, 1, 1); // data in cache r.out = filecreate(&opt->state.strc, target_save); #if HDEBUG printf("direct-disk: %s\n", save); #endif if (r.out != NULL) { char BIGSTK buff[32768 + 4]; LLint size = r.size; if (size > 0) { size_t nl; do { nl = unzReadCurrentFile((unzFile) cache->zipInput, buff, (int) minimum(size, 32768)); if (nl > 0) { size -= nl; if (fwrite(buff, 1, nl, r.out) != nl) { // erreur int last_errno = errno; r.statuscode = STATUSCODE_INVALID; sprintf(r.msg, "Cache Read Error : Read To Disk: %s", strerror(last_errno)); } } } while((nl > 0) && (size > 0) && (r.statuscode != -1)); } fclose(r.out); r.out = NULL; #ifndef _WIN32 chmod(target_save, HTS_ACCESS_FILE); #endif } else { r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "Cache Write Error : Unable to Create File"); //printf("%s\n",save); } } } else #endif { // lire en mémoire // We need to get bytes on memory, but the previous version is (supposed to be) on disk. if (!dataincache) { // Empty previous save name, or file does not exist ? if (!strnotempty(previous_save) || !fexist_utf8(previous_save)) { // Pas de donnée en cache, bizarre car html!!! // Hack: if error page data is missing (pre-3.45 releases), create one. We won't use it anyway. if (!HTTP_IS_OK(r.statuscode)) { const int size = 512; r.adr = malloct(size); sprintf(r.adr, "HTTP Error %u

HTTP Error %u

", r.statuscode, r.statuscode); r.size = strlen(r.adr); assertf(r.size < size); strcpy(r.contenttype, "text/html"); strcpy(r.charset, "utf-8"); // Fake total size, too. r.totalsize = r.size; // Not on disk anymore! r.is_write = 0; } // Otherwise, this is a real error. else { r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "Previous cache file not found (empty filename)"); } } else { /* Read in memory from disk */ FILE *const fp = FOPEN(fconv(catbuff, sizeof(catbuff), previous_save), "rb"); if (fp != NULL) { r.adr = (char *) malloct((int) r.size + 4); if (r.adr != NULL) { if (r.size > 0 && fread(r.adr, 1, (int) r.size, fp) != r.size) { int last_errno = errno; r.statuscode = STATUSCODE_INVALID; sprintf(r.msg, "Read error in cache disk data: %s", strerror(last_errno)); } } else { r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "Read error (memory exhausted) from cache"); } fclose(fp); } else { r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "Read error (unable to open disk file) from cache"); } } } // Data in cache. else { // lire fichier (d'un coup) r.adr = (char *) malloct((int) r.size + 4); if (r.adr != NULL) { if (unzReadCurrentFile((unzFile) cache->zipInput, r.adr, (int) r.size) != r.size) { // erreur freet(r.adr); r.adr = NULL; r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "Cache Read Error : Read Data"); } else *(r.adr + r.size) = '\0'; //printf(">%s status %d\n",back[p].r.contenttype,back[p].r.statuscode); } else { // erreur r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "Cache Memory Error"); } } } } } else { r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "Cache Read Error : Read Header Data"); } unzCloseCurrentFile((unzFile) cache->zipInput); } else { r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "Cache Read Error : Open File"); } } else { r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "Cache Read Error : Bad Offset"); } } else { r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "File Cache Entry Not Found"); } if (!location) { /* don't export internal buffer */ r.location = NULL; } return r; } // lecture d'un fichier dans le cache // si save==null alors test unqiquement static htsblk cache_readex_old(httrackp * opt, cache_back * cache, const char *adr, const char *fil, const char *save, char *location, char *return_save, int readonly) { #if HTS_FAST_CACHE intptr_t hash_pos; int hash_pos_return; #else char *a; #endif char BIGSTK buff[HTS_URLMAXSIZE * 2]; char BIGSTK location_default[HTS_URLMAXSIZE * 2]; char BIGSTK previous_save[HTS_URLMAXSIZE * 2]; char catbuff[CATBUFF_SIZE]; htsblk r; int ok = 0; int header_only = 0; hts_init_htsblk(&r); //memset(&r, 0, sizeof(htsblk)); r.soc=INVALID_SOCKET; if (location) { r.location = location; } else { r.location = location_default; } strcpybuff(r.location, ""); #if HTS_FAST_CACHE strcpybuff(buff, adr); strcatbuff(buff, fil); hash_pos_return = coucal_read(cache->hashtable, buff, &hash_pos); #else buff[0] = '\0'; strcatbuff(buff, "\n"); strcatbuff(buff, adr); strcatbuff(buff, "\n"); strcatbuff(buff, fil); strcatbuff(buff, "\n"); if (cache->use) a = strstr(cache->use, buff); else a = NULL; // forcer erreur #endif /* avoid errors on data entries */ if (adr[0] == '/' && adr[1] == '/' && adr[2] == '[') { #if HTS_FAST_CACHE hash_pos_return = 0; #else a = NULL; #endif } // en cas de succès #if HTS_FAST_CACHE if (hash_pos_return != 0) { #else if (a != NULL) { // OK existe en cache! #endif intptr_t pos; #if DEBUGCA fprintf(stdout, "..cache: %s%s at ", adr, fil); #endif #if HTS_FAST_CACHE pos = hash_pos; /* simply */ #else a += strlen(buff); sscanf(a, "%d", &pos); // lire position #endif #if DEBUGCA printf("%d\n", pos); #endif fflush(cache->olddat); if (fseek(cache->olddat, (long) ((pos > 0) ? pos : (-pos)), SEEK_SET) == 0) { /* Importer cache1.0 */ if (cache->version == 0) { OLD_htsblk old_r; if (fread((char *) &old_r, 1, sizeof(old_r), cache->olddat) == sizeof(old_r)) { // lire tout (y compris statuscode etc) r.statuscode = old_r.statuscode; r.size = old_r.size; // taille fichier strcpybuff(r.msg, old_r.msg); strcpybuff(r.contenttype, old_r.contenttype); ok = 1; /* import ok */ } /* */ /* Cache 1.1 */ } else { char check[256]; LLint size_read; check[0] = '\0'; // cache_rint(cache->olddat, &r.statuscode); cache_rLLint(cache->olddat, &r.size); cache_rstr(cache->olddat, r.msg); cache_rstr(cache->olddat, r.contenttype); if (cache->version >= 3) cache_rstr(cache->olddat, r.charset); cache_rstr(cache->olddat, r.lastmodified); cache_rstr(cache->olddat, r.etag); cache_rstr(cache->olddat, r.location); if (cache->version >= 2) cache_rstr(cache->olddat, r.cdispo); if (cache->version >= 4) { cache_rstr(cache->olddat, previous_save); // adr cache_rstr(cache->olddat, previous_save); // fil previous_save[0] = '\0'; cache_rstr(cache->olddat, previous_save); // save if (return_save != NULL) { strcpybuff(return_save, previous_save); } } if (cache->version >= 5) { r.headers = cache_rstr_addr(cache->olddat); } // cache_rstr(cache->olddat, check); if (strcmp(check, "HTS") == 0) { /* intégrité OK */ ok = 1; } cache_rLLint(cache->olddat, &size_read); /* lire size pour être sûr de la taille déclarée (réécrire) */ if (size_read > 0) { /* si inscrite ici */ r.size = size_read; } else { /* pas de données directement dans le cache, fichier présent? */ if (r.statuscode != HTTP_OK) header_only = 1; /* que l'en tête ici! */ } } /* Remplir certains champs */ r.totalsize = r.size; // lecture du header (y compris le statuscode) /*if (fread((char*) &r,1,sizeof(htsblk),cache->olddat)==sizeof(htsblk)) { // lire tout (y compris statuscode etc) */ if (ok) { // sécurité r.adr = NULL; r.out = NULL; ////r.location=NULL; non, fixée lors des 301 ou 302 r.fp = NULL; if ((r.statuscode >= 0) && (r.statuscode <= 999) && (r.notmodified >= 0) && (r.notmodified <= 9)) { // petite vérif intégrité if ((save) && (!header_only)) { /* ne pas lire uniquement header */ //int to_file=0; r.adr = NULL; r.soc = INVALID_SOCKET; // // r.location=NULL; #if HTS_DIRECTDISK // Court-circuit: // Peut-on stocker le fichier directement sur disque? if (!readonly && r.statuscode == HTTP_OK && !is_hypertext_mime(opt, r.contenttype, fil) && strnotempty(save)) { // pas HTML, écrire sur disk directement int ok = 0; r.is_write = 1; // écrire if (fexist_utf8(fconv(catbuff, sizeof(catbuff), save))) { // un fichier existe déja //if (fsize_utf8(fconv(save))==r.size) { // même taille -- NON tant pis (taille mal declaree) ok = 1; // plus rien à faire filenote(&opt->state.strc, save, NULL); // noter comme connu file_notify(opt, adr, fil, save, 0, 0, 0); //} } if ((pos < 0) && (!ok)) { // Pas de donnée en cache et fichier introuvable : erreur! if (opt->norecatch) { file_notify(opt, adr, fil, save, 1, 0, 0); filecreateempty(&opt->state.strc, save); // r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "File deleted by user not recaught"); ok = 1; // ne pas récupérer (et pas d'erreur) } else { r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "Previous cache file not found"); ok = 1; // ne pas récupérer } } if (!ok) { r.out = filecreate(&opt->state.strc, save); #if HDEBUG printf("direct-disk: %s\n", save); #endif if (r.out != NULL) { char BIGSTK buff[32768 + 4]; size_t size = (size_t) r.size; if (size > 0) { size_t nl; do { nl = fread(buff, 1, minimum(size, 32768), cache->olddat); if (nl > 0) { size -= nl; if (fwrite(buff, 1, nl, r.out) != nl) { // erreur r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "Cache Read Error : Read To Disk"); } } } while((nl > 0) && (size > 0) && (r.statuscode != -1)); } fclose(r.out); r.out = NULL; #ifndef _WIN32 chmod(save, HTS_ACCESS_FILE); #endif } else { r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "Cache Write Error : Unable to Create File"); //printf("%s\n",save); } } } else #endif { // lire en mémoire if (pos < 0) { if (strnotempty(save)) { // Pas de donnée en cache, bizarre car html!!! r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "Previous cache file not found (2)"); } else { /* Read in memory from cache */ if (strnotempty(return_save) && fexist_utf8(return_save)) { FILE *fp = FOPEN(fconv(catbuff, sizeof(catbuff), return_save), "rb"); if (fp != NULL) { r.adr = (char *) malloct((size_t) r.size + 4); if (r.adr != NULL) { if (r.size > 0 && fread(r.adr, 1, (size_t) r.size, fp) != r.size) { r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "Read error in cache disk data"); } } else { r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "Read error (memory exhausted) from cache"); } fclose(fp); } } else { r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "Cache file not found on disk"); } } } else { // lire fichier (d'un coup) r.adr = (char *) malloct((size_t) r.size + 4); if (r.adr != NULL) { if (fread(r.adr, 1, (size_t) r.size, cache->olddat) != r.size) { // erreur freet(r.adr); r.adr = NULL; r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "Cache Read Error : Read Data"); } else *(r.adr + r.size) = '\0'; //printf(">%s status %d\n",back[p].r.contenttype,back[p].r.statuscode); } else { // erreur r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "Cache Memory Error"); } } } } // si save==null, ne rien charger (juste en tête) } else { #if DEBUGCA printf("Cache Read Error : Bad Data"); #endif r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "Cache Read Error : Bad Data"); } } else { // erreur #if DEBUGCA printf("Cache Read Error : Read Header"); #endif r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "Cache Read Error : Read Header"); } } else { #if DEBUGCA printf("Cache Read Error : Seek Failed"); #endif r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "Cache Read Error : Seek Failed"); } } else { #if DEBUGCA printf("File Cache Not Found"); #endif r.statuscode = STATUSCODE_INVALID; strcpybuff(r.msg, "File Cache Entry Not Found"); } if (!location) { /* don't export internal buffer */ r.location = NULL; } return r; } /* write (string1-string2)-data in cache */ /* 0 if failed */ int cache_writedata(FILE * cache_ndx, FILE * cache_dat, const char *str1, const char *str2, char *outbuff, int len) { if (cache_dat) { char BIGSTK buff[HTS_URLMAXSIZE * 4]; char s[256]; int pos; fflush(cache_dat); fflush(cache_ndx); pos = ftell(cache_dat); /* first write data */ if (cache_wint(cache_dat, len) != -1) { // length if (fwrite(outbuff, 1, len, cache_dat) == len) { // data /* then write index */ sprintf(s, "%d\n", pos); buff[0] = '\0'; strcatbuff(buff, str1); strcatbuff(buff, "\n"); strcatbuff(buff, str2); strcatbuff(buff, "\n"); cache_wstr(cache_ndx, buff); if (fwrite(s, 1, strlen(s), cache_ndx) == strlen(s)) { fflush(cache_dat); fflush(cache_ndx); return 1; } } } } return 0; } /* read the data corresponding to (string1-string2) in cache */ /* 0 if failed */ int cache_readdata(cache_back * cache, const char *str1, const char *str2, char **inbuff, int *inlen) { #if HTS_FAST_CACHE if (cache->hashtable) { char BIGSTK buff[HTS_URLMAXSIZE * 4]; intptr_t pos; strcpybuff(buff, str1); strcatbuff(buff, str2); if (coucal_read(cache->hashtable, buff, &pos)) { if (fseek(cache->olddat, (long) ((pos > 0) ? pos : (-pos)), SEEK_SET) == 0) { INTsys len; cache_rint(cache->olddat, &len); if (len > 0) { char *mem_buff = (char *) malloct(len + 4); /* Plus byte 0 */ if (mem_buff) { if (fread(mem_buff, 1, len, cache->olddat) == len) { // lire tout (y compris statuscode etc)*/ *inbuff = mem_buff; *inlen = len; return 1; } else freet(mem_buff); } } } } } #endif *inbuff = NULL; *inlen = 0; return 0; } static int hts_rename(httrackp * opt, const char *a, const char *b) { hts_log_print(opt, LOG_DEBUG, "Cache: rename %s -> %s (%p %p)", a, b, a, b); return rename(a, b); } // renvoyer uniquement en tête, ou NULL si erreur // return NULL upon error, and set -1 to r.statuscode htsblk *cache_header(httrackp * opt, cache_back * cache, const char *adr, const char *fil, htsblk * r) { *r = cache_read(opt, cache, adr, fil, NULL, NULL); // test uniquement if (r->statuscode != -1) return r; else return NULL; } // Initialisation du cache: créer nouveau, renomer ancien, charger.. void cache_init(cache_back * cache, httrackp * opt) { // --- // utilisation du cache: renommer ancien éventuel et charger index hts_log_print(opt, LOG_DEBUG, "Cache: enabled=%d, base=%s, ro=%d", (int) opt->cache, fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/"), (int) cache->ro); if (opt->cache) { #if DEBUGCA printf("cache init: "); #endif if (!cache->ro) { #ifdef _WIN32 mkdir(fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache")); #else mkdir(fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache"), HTS_PROTECT_FOLDER); #endif if ((fexist(fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.zip")))) { // il existe déja un cache précédent.. renommer /* Previous cache from the previous cache version */ #if 0 /* No.. reuse with old httrack releases! */ if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.dat"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.dat")); if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.ndx"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.ndx")); #endif /* Previous cache version */ if ((fexist(fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.dat"))) && (fexist(fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.ndx")))) { // il existe déja un cache précédent.. renommer rename(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.dat"), fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.dat")); rename(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.ndx"), fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.ndx")); } /* Remove OLD cache */ if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.zip"))) { if (remove (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.zip")) != 0) { hts_log_print(opt, LOG_WARNING | LOG_ERRNO, "Cache: error while moving previous cache"); } } /* Rename */ if (hts_rename (opt, fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.zip"), fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.zip")) != 0) { hts_log_print(opt, LOG_WARNING | LOG_ERRNO, "Cache: error while moving previous cache"); } else { hts_log_print(opt, LOG_DEBUG, "Cache: successfully renamed"); } } else if ((fexist(fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.dat"))) && (fexist(fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.ndx")))) { // il existe déja un cache précédent.. renommer #if DEBUGCA printf("work with former cache\n"); #endif if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.dat"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.dat")); if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.ndx"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.ndx")); rename(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.dat"), fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.dat")); rename(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.ndx"), fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.ndx")); } else { // un des deux (ou les deux) fichiers cache absents: effacer l'autre éventuel #if DEBUGCA printf("new cache\n"); #endif if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.dat"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.dat")); if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.ndx"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.ndx")); } } else { hts_log_print(opt, LOG_DEBUG, "Cache: no cache found"); } hts_log_print(opt, LOG_DEBUG, "Cache: size %d", (int) fsize(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.zip"))); // charger index cache précédent if ((!cache->ro && fsize(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.zip")) > 0) || (cache->ro && fsize(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.zip")) > 0) ) { if (!cache->ro) { cache->zipInput = unzOpen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.zip")); } else { cache->zipInput = unzOpen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.zip")); } // Corrupted ZIP file ? Try to repair! if (cache->zipInput == NULL && !cache->ro) { char *name; uLong repaired = 0; uLong repairedBytes = 0; if (!cache->ro) { name = fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.zip"); } else { name = fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.zip"); } hts_log_print(opt, LOG_WARNING, "Cache: damaged cache, trying to repair"); if (unzRepair (name, fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/repair.zip"), fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/repair.tmp"), &repaired, &repairedBytes) == Z_OK) { unlink(name); rename(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/repair.zip"), name); cache->zipInput = unzOpen(name); hts_log_print(opt, LOG_WARNING, "Cache: %d bytes successfully recovered in %d entries", (int) repairedBytes, (int) repaired); } else { hts_log_print(opt, LOG_WARNING, "Cache: could not repair the cache"); } } // Opened ? if (cache->zipInput != NULL) { int zErr; /* Ready directory entries */ if ((zErr = unzGoToFirstFile((unzFile) cache->zipInput)) == Z_OK) { char comment[128]; char BIGSTK filename[HTS_URLMAXSIZE * 4]; int entries = 0; memset(comment, 0, sizeof(comment)); // for truncated reads do { int readSizeHeader = 0; filename[0] = '\0'; comment[0] = '\0'; if (unzOpenCurrentFile((unzFile) cache->zipInput) == Z_OK) { if ((readSizeHeader = unzGetLocalExtrafield((unzFile) cache->zipInput, comment, sizeof(comment) - 2)) > 0 && unzGetCurrentFileInfo((unzFile) cache->zipInput, NULL, filename, sizeof(filename) - 2, NULL, 0, NULL, 0) == Z_OK) { long int pos = (long int) unzGetOffset((unzFile) cache->zipInput); assertf(readSizeHeader < sizeof(comment)); comment[readSizeHeader] = '\0'; entries++; if (pos > 0) { int dataincache = 0; // data in cache ? char *filenameIndex = filename; if (strfield(filenameIndex, "http://")) { filenameIndex += 7; } if (comment[0] != '\0') { int maxLine = 2; char *a = comment; while(*a && maxLine-- > 0) { // parse only few first lines char BIGSTK line[1024]; line[0] = '\0'; a += binput(a, line, sizeof(line) - 2); if (strfield(line, "X-In-Cache:")) { if (strfield2(line, "X-In-Cache: 1")) { dataincache = 1; } else { dataincache = 0; } break; } } } if (dataincache) coucal_add(cache->hashtable, filenameIndex, pos); else coucal_add(cache->hashtable, filenameIndex, -pos); } else { hts_log_print(opt, LOG_WARNING, "Corrupted cache meta entry #%d", (int) entries); } } else { hts_log_print(opt, LOG_WARNING, "Corrupted cache entry #%d", (int) entries); } unzCloseCurrentFile((unzFile) cache->zipInput); } else { hts_log_print(opt, LOG_WARNING, "Corrupted cache entry #%d", (int) entries); } } while(unzGoToNextFile((unzFile) cache->zipInput) == Z_OK); hts_log_print(opt, LOG_DEBUG, "Cache index loaded: %d entries loaded", (int) entries); opt->is_update = 1; // signaler comme update } else { hts_log_print(opt, LOG_WARNING, "Cache: error trying to read the cache: %s", hts_get_zerror(zErr)); } } else { hts_log_print(opt, LOG_WARNING, "Cache: error trying to open the cache"); } } else if ((!cache->ro && fsize(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.dat")) >= 0 && fsize(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.ndx")) > 0) || (cache->ro && fsize(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.dat")) >= 0 && fsize(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.ndx")) > 0) ) { FILE *oldndx = NULL; #if DEBUGCA printf("..load cache\n"); #endif if (!cache->ro) { cache->olddat = fopen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.dat"), "rb"); oldndx = fopen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.ndx"), "rb"); } else { cache->olddat = fopen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.dat"), "rb"); oldndx = fopen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.ndx"), "rb"); } // les deux doivent être ouvrables if ((cache->olddat == NULL) && (oldndx != NULL)) { fclose(oldndx); oldndx = NULL; } if ((cache->olddat != NULL) && (oldndx == NULL)) { fclose(cache->olddat); cache->olddat = NULL; } // lire index if (oldndx != NULL) { int buffl; fclose(oldndx); oldndx = NULL; // lire ndx, et lastmodified if (!cache->ro) { buffl = fsize(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.ndx")); cache->use = readfile(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.ndx")); } else { buffl = fsize(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.ndx")); cache->use = readfile(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.ndx")); } if (cache->use != NULL) { char firstline[256]; char *a = cache->use; a += cache_brstr(a, firstline); if (strncmp(firstline, "CACHE-", 6) == 0) { // Nouvelle version du cache if (strncmp(firstline, "CACHE-1.", 8) == 0) { // Version 1.1x cache->version = (int) (firstline[8] - '0'); // cache 1.x if (cache->version <= 5) { a += cache_brstr(a, firstline); strcpybuff(cache->lastmodified, firstline); } else { hts_log_print(opt, LOG_ERROR, "Cache: version 1.%d not supported, ignoring current cache", cache->version); fclose(cache->olddat); cache->olddat = NULL; freet(cache->use); cache->use = NULL; } } else { // non supporté hts_log_print(opt, LOG_ERROR, "Cache: %s not supported, ignoring current cache", firstline); fclose(cache->olddat); cache->olddat = NULL; freet(cache->use); cache->use = NULL; } /* */ } else { // Vieille version du cache /* */ hts_log_print(opt, LOG_WARNING, "Cache: importing old cache format"); cache->version = 0; // cache 1.0 strcpybuff(cache->lastmodified, firstline); } opt->is_update = 1; // signaler comme update /* Create hash table for the cache (MUCH FASTER!) */ #if HTS_FAST_CACHE if (cache->use) { char BIGSTK line[HTS_URLMAXSIZE * 2]; char linepos[256]; int pos; while((a != NULL) && (a < (cache->use + buffl))) { a = strchr(a + 1, '\n'); /* start of line */ if (a) { a++; /* read "host/file" */ a += binput(a, line, HTS_URLMAXSIZE); a += binput(a, line + strlen(line), HTS_URLMAXSIZE); /* read position */ a += binput(a, linepos, 200); sscanf(linepos, "%d", &pos); coucal_add(cache->hashtable, line, pos); } } /* Not needed anymore! */ freet(cache->use); cache->use = NULL; } #endif } } } else { hts_log_print(opt, LOG_DEBUG, "Cache: no cache found in %s", fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/")); } #if DEBUGCA printf("..create cache\n"); #endif if (!cache->ro) { // ouvrir caches actuels structcheck(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/")); if (1) { /* Create ZIP file cache */ cache->zipOutput = (void *) zipOpen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.zip"), 0); if (cache->zipOutput != NULL) { // supprimer old.lst if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.lst"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.lst")); // renommer if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.lst"))) rename(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.lst"), fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.lst")); // ouvrir cache->lst = fopen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.lst"), "wb"); strcpybuff(opt->state.strc.path, StringBuff(opt->path_html)); opt->state.strc.lst = cache->lst; //{ //filecreate_params tmp; //strcpybuff(tmp.path,StringBuff(opt->path_html)); // chemin //tmp.lst=cache->lst; // fichier lst //filenote("",&tmp); // initialiser filecreate //} // supprimer old.txt if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.txt"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.txt")); // renommer if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.txt"))) rename(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.txt"), fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.txt")); // ouvrir cache->txt = fopen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.txt"), "wb"); if (cache->txt) { fprintf(cache->txt, "date\tsize'/'remotesize\tflags(request:Update,Range state:File response:Modified,Chunked,gZipped)\t"); fprintf(cache->txt, "statuscode\tstatus ('servermsg')\tMIME\tEtag|Date\tURL\tlocalfile\t(from URL)" LF); } } } else { cache->dat = fopen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.dat"), "wb"); cache->ndx = fopen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.ndx"), "wb"); // les deux doivent être ouvrables if ((cache->dat == NULL) && (cache->ndx != NULL)) { fclose(cache->ndx); cache->ndx = NULL; } if ((cache->dat != NULL) && (cache->ndx == NULL)) { fclose(cache->dat); cache->dat = NULL; } if (cache->ndx != NULL) { char s[256]; cache_wstr(cache->dat, "CACHE-1.5"); fflush(cache->dat); cache_wstr(cache->ndx, "CACHE-1.5"); fflush(cache->ndx); // time_gmt_rfc822(s); // date et heure actuelle GMT pour If-Modified-Since.. cache_wstr(cache->ndx, s); fflush(cache->ndx); // un petit fflush au cas où // supprimer old.lst if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.lst"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.lst")); // renommer if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.lst"))) rename(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.lst"), fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.lst")); // ouvrir cache->lst = fopen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.lst"), "wb"); strcpybuff(opt->state.strc.path, StringBuff(opt->path_html)); opt->state.strc.lst = cache->lst; //{ // filecreate_params tmp; // strcpybuff(tmp.path,StringBuff(opt->path_html)); // chemin // tmp.lst=cache->lst; // fichier lst // filenote("",&tmp); // initialiser filecreate //} // supprimer old.txt if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.txt"))) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.txt")); // renommer if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.txt"))) rename(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.txt"), fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.txt")); // ouvrir cache->txt = fopen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.txt"), "wb"); if (cache->txt) { fprintf(cache->txt, "date\tsize'/'remotesize\tflags(request:Update,Range state:File response:Modified,Chunked,gZipped)\t"); fprintf(cache->txt, "statuscode\tstatus ('servermsg')\tMIME\tEtag|Date\tURL\tlocalfile\t(from URL)" LF); } // test // cache_writedata(cache->ndx,cache->dat,"//[TEST]//","test1","TEST PIPO",9); } // cache->ndx!=NULL } //cache->zipOutput != NULL } else { cache->lst = cache->dat = cache->ndx = NULL; } } else { hts_log_print(opt, LOG_DEBUG, "Cache: no cache enabled"); } } // lire un fichier.. (compatible \0) /* Note: NOT utf-8 */ char *readfile(const char *fil) { return readfile2(fil, NULL); } /* Note: NOT utf-8 */ char *readfile2(const char *fil, LLint * size) { char *adr = NULL; char catbuff[CATBUFF_SIZE]; INTsys len = 0; len = fsize(fil); if (len >= 0) { // exists FILE *fp; fp = fopen(fconv(catbuff, sizeof(catbuff), fil), "rb"); if (fp != NULL) { // n'existe pas (!) adr = (char *) malloct(len + 1); if (size != NULL) *size = len; if (adr != NULL) { if (len > 0 && fread(adr, 1, len, fp) != len) { // fichier endommagé ? freet(adr); adr = NULL; } else *(adr + len) = '\0'; } fclose(fp); } } return adr; } /* Note: utf-8 */ char *readfile_utf8(const char *fil) { char *adr = NULL; char catbuff[CATBUFF_SIZE]; const off_t len = fsize_utf8(fil); if (len >= 0) { // exists FILE *const fp = FOPEN(fconv(catbuff, sizeof(catbuff), fil), "rb"); if (fp != NULL) { // n'existe pas (!) adr = (char *) malloct(len + 1); if (adr != NULL) { if (len > 0 && fread(adr, 1, len, fp) != len) { // fichier endommagé ? freet(adr); adr = NULL; } else { adr[len] = '\0'; } } fclose(fp); } } return adr; } /* Note: NOT utf-8 */ char *readfile_or(const char *fil, const char *defaultdata) { const char *realfile = fil; char *ret; char catbuff[CATBUFF_SIZE]; if (!fexist(fil)) realfile = fconcat(catbuff, sizeof(catbuff), hts_rootdir(NULL), fil); ret = readfile(realfile); if (ret) return ret; else { char *adr = malloct(strlen(defaultdata) + 1); if (adr) { strcpybuff(adr, defaultdata); return adr; } } return NULL; } // écriture/lecture d'une chaîne sur un fichier // -1 : erreur, sinon 0 int cache_wstr(FILE * fp, const char *s) { INTsys i; char buff[256 + 4]; i = (s != NULL) ? ((INTsys) strlen(s)) : 0; sprintf(buff, INTsysP "\n", i); if (fwrite(buff, 1, strlen(buff), fp) != strlen(buff)) return -1; if (i > 0 && fwrite(s, 1, i, fp) != i) return -1; return 0; } void cache_rstr(FILE * fp, char *s) { INTsys i; char buff[256 + 4]; linput(fp, buff, 256); sscanf(buff, INTsysP, &i); if (i < 0 || i > 32768) /* error, something nasty happened */ i = 0; if (i > 0) { if ((int) fread(s, 1, i, fp) != i) { int fread_cache_failed = 0; assertf(fread_cache_failed); } } *(s + i) = '\0'; } char *cache_rstr_addr(FILE * fp) { INTsys i; char *addr = NULL; char buff[256 + 4]; linput(fp, buff, 256); sscanf(buff, INTsysP, &i); if (i < 0 || i > 32768) /* error, something nasty happened */ i = 0; if (i > 0) { addr = malloct(i + 1); if (addr != NULL) { if ((int) fread(addr, 1, i, fp) != i) { int fread_cache_failed = 0; assertf(fread_cache_failed); } *(addr + i) = '\0'; } } return addr; } int cache_brstr(char *adr, char *s) { int i; int off; char buff[256 + 4]; off = binput(adr, buff, 256); adr += off; sscanf(buff, "%d", &i); if (i > 0) strncpy(s, adr, i); *(s + i) = '\0'; off += i; return off; } int cache_quickbrstr(char *adr, char *s) { int i; int off; char buff[256 + 4]; off = binput(adr, buff, 256); adr += off; sscanf(buff, "%d", &i); if (i > 0) strncpy(s, adr, i); *(s + i) = '\0'; off += i; return off; } /* idem, mais en int */ int cache_brint(char *adr, int *i) { char s[256]; int r = cache_brstr(adr, s); if (r != -1) sscanf(s, "%d", i); return r; } void cache_rint(FILE * fp, int *i) { char s[256]; cache_rstr(fp, s); sscanf(s, "%d", i); } int cache_wint(FILE * fp, int i) { char s[256]; sprintf(s, "%d", (int) i); return cache_wstr(fp, s); } void cache_rLLint(FILE * fp, LLint * i) { char s[256]; cache_rstr(fp, s); sscanf(s, LLintP, i); } int cache_wLLint(FILE * fp, LLint i) { char s[256]; sprintf(s, LLintP, (LLint) i); return cache_wstr(fp, s); } // -- cache -- httrack-3.49.5/src/htsback.c0000644000175000017500000047625414360534067012601 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: httrack.c subroutines: */ /* backing system (multiple socket download) */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* Internal engine bytecode */ #define HTS_INTERNAL_BYTECODE /* specific definitions */ #include "htsnet.h" #include "htscore.h" #include "htsthread.h" #include /* END specific definitions */ #include "htsback.h" //#ifdef _WIN32 #include "htsftp.h" #if HTS_USEZLIB #include "htszlib.h" #else #error HTS_USEZLIB not defined #endif //#endif #ifdef _WIN32 #ifndef __cplusplus // DOS #include /* _beginthread, _endthread */ #endif #else #endif #define VT_CLREOL "\33[K" /* Slot operations */ static int slot_can_be_cached_on_disk(const lien_back * back); static int slot_can_be_cleaned(const lien_back * back); static int slot_can_be_finalized(httrackp * opt, const lien_back * back); struct_back *back_new(httrackp *opt, int back_max) { int i; struct_back *sback = calloct(1, sizeof(struct_back)); sback->count = back_max; sback->lnk = (lien_back *) calloct((back_max + 1), sizeof(lien_back)); sback->ready = coucal_new(0); hts_set_hash_handler(sback->ready, opt); coucal_set_name(sback->ready, "back_new"); sback->ready_size_bytes = 0; coucal_value_is_malloc(sback->ready, 1); // init for(i = 0; i < sback->count; i++) { sback->lnk[i].r.location = sback->lnk[i].location_buffer; sback->lnk[i].status = STATUS_FREE; sback->lnk[i].r.soc = INVALID_SOCKET; } return sback; } void back_free(struct_back ** sback) { if (sback != NULL && *sback != NULL) { if ((*sback)->lnk != NULL) { freet((*sback)->lnk); (*sback)->lnk = NULL; } if ((*sback)->ready != NULL) { coucal_delete(&(*sback)->ready); (*sback)->ready_size_bytes = 0; } freet(*sback); *sback = NULL; } } void back_delete_all(httrackp * opt, cache_back * cache, struct_back * sback) { if (sback != NULL) { int i; // delete live slots for(i = 0; i < sback->count; i++) { back_delete(opt, cache, sback, i); } // delete stored slots if (sback->ready != NULL) { struct_coucal_enum e = coucal_enum_new(sback->ready); coucal_item *item; while((item = coucal_enum_next(&e))) { #ifndef HTS_NO_BACK_ON_DISK const char *filename = (char *) item->value.ptr; if (filename != NULL) { (void) UNLINK(filename); } #else /* clear entry content (but not yet the entry) */ lien_back *back = (lien_back *) item->value.ptr; back_clear_entry(back); #endif } /* delete hashtable & content */ coucal_delete(&sback->ready); sback->ready_size_bytes = 0; } } } // --- // routines de backing static int back_index_ready(httrackp * opt, struct_back * sback, const char *adr, const char *fil, const char *sav, int getIndex); static int back_index_fetch(httrackp * opt, struct_back * sback, const char *adr, const char *fil, const char *sav, int getIndex); // retourne l'index d'un lien dans un tableau de backing int back_index(httrackp * opt, struct_back * sback, const char *adr, const char *fil, const char *sav) { return back_index_fetch(opt, sback, adr, fil, sav, 1); } static int back_index_fetch(httrackp * opt, struct_back * sback, const char *adr, const char *fil, const char *sav, int getIndex) { lien_back *const back = sback->lnk; const int back_max = sback->count; int index = -1; int i; for(i = 0; i < back_max; i++) { if (back[i].status >= 0 /* not free or alive */ && strfield2(back[i].url_adr, adr) && strcmp(back[i].url_fil, fil) == 0) { if (index == -1) /* first time we meet, store it */ index = i; else if (sav != NULL && strcmp(back[i].url_sav, sav) == 0) { /* oops, check sav too */ index = i; return index; } } } // not found in fast repository - search in the storage hashtable if (index == -1 && sav != NULL) { index = back_index_ready(opt, sback, adr, fil, sav, getIndex); } return index; } /* resurrect stored entry */ static int back_index_ready(httrackp * opt, struct_back * sback, const char *adr, const char *fil, const char *sav, int getIndex) { lien_back *const back = sback->lnk; void *ptr = NULL; if (coucal_read_pvoid(sback->ready, sav, &ptr)) { if (!getIndex) { /* don't "pagefault" the entry */ if (ptr != NULL) { return sback->count; /* (invalid but) positive result */ } else { return -1; /* not found */ } } else if (ptr != NULL) { lien_back *itemback = NULL; #ifndef HTS_NO_BACK_ON_DISK FILE *fp; const char *fileback = (char *) ptr; char catbuff[CATBUFF_SIZE]; if ((fp = FOPEN(fconv(catbuff, sizeof(catbuff), fileback), "rb")) != NULL) { if (back_unserialize(fp, &itemback) != 0) { if (itemback != NULL) { back_clear_entry(itemback); freet(itemback); itemback = NULL; } hts_log_print(opt, LOG_WARNING | LOG_ERRNO, "engine: warning: unserialize error for %s%s (%s)", adr, fil, sav); } fclose(fp); } else { hts_log_print(opt, LOG_WARNING | LOG_ERRNO, "engine: warning: unserialize error for %s%s (%s), file disappeared", adr, fil, sav); } (void) UNLINK(fileback); #else itemback = (lien_back *) ptr; #endif if (itemback != NULL) { // move from hashtable to fast repository int q = back_search(opt, sback); if (q != -1) { deletehttp(&back[q].r); // security check back_move(itemback, &back[q]); back_clear_entry(itemback); /* delete entry content */ freet(itemback); /* delete item */ itemback = NULL; coucal_remove(sback->ready, sav); // delete item sback->ready_size_bytes -= back[q].r.size; /* substract for stats */ back_set_locked(sback, q); /* locked */ return q; } else { hts_log_print(opt, LOG_WARNING, "engine: warning: unserialize error for %s%s (%s): no more space to wakeup frozen slots", adr, fil, sav); } } } } return -1; } static int slot_can_be_cached_on_disk(const lien_back * back) { return (back->status == STATUS_READY && back->locked == 0 && back->url_sav[0] != '\0' && strcmp(back->url_sav, BACK_ADD_TEST) != 0); /* Note: not checking !IS_DELAYED_EXT(back->url_sav) or it will quickly cause the slots to be filled! */ } /* Put all backing entries that are ready in the storage hashtable to spare space and CPU */ int back_cleanup_background(httrackp * opt, cache_back * cache, struct_back * sback) { lien_back *const back = sback->lnk; const int back_max = sback->count; int nclean = 0; int i; for(i = 0; i < back_max; i++) { // ready, not locked and suitable if (slot_can_be_cached_on_disk(&back[i])) { #ifdef HTS_NO_BACK_ON_DISK lien_back *itemback; #endif /* Security check */ int checkIndex = back_index_ready(opt, sback, back[i].url_adr, back[i].url_fil, back[i].url_sav, 1); if (checkIndex != -1) { hts_log_print(opt, LOG_WARNING, "engine: unexpected duplicate file entry: %s%s -> %s (%d '%s') / %s%s -> %s (%d '%s')", back[checkIndex].url_adr, back[checkIndex].url_fil, back[checkIndex].url_sav, back[checkIndex].r.statuscode, back[checkIndex].r.msg, back[i].url_adr, back[i].url_fil, back[i].url_sav, back[i].r.statuscode, back[i].r.msg); back_delete(NULL, NULL, sback, checkIndex); #ifdef _DEBUG /* This should NOT happend! */ { int duplicateEntryInBacklog = 1; assertf(!duplicateEntryInBacklog); } #endif } #ifndef HTS_NO_BACK_ON_DISK /* temporarily serialize the entry on disk */ { int fsz = (int) strlen(back[i].url_sav); char *filename = malloc(fsz + 8 + 1); if (filename != NULL) { FILE *fp; if (opt->getmode != 0) { sprintf(filename, "%s.tmp", back[i].url_sav); } else { sprintf(filename, "%stmpfile%d.tmp", StringBuff(opt->path_html_utf8), opt->state.tmpnameid++); } /* Security check */ if (fexist_utf8(filename)) { hts_log_print(opt, LOG_WARNING, "engine: warning: temporary file %s already exists", filename); } /* Create file and serialize slot */ if ((fp = filecreate(NULL, filename)) != NULL) { if (back_serialize(fp, &back[i]) == 0) { coucal_add_pvoid(sback->ready, back[i].url_sav, filename); filename = NULL; sback->ready_size_bytes += back[i].r.size; /* add for stats */ nclean++; back_clear_entry(&back[i]); /* entry is now recycled */ } else { hts_log_print(opt, LOG_WARNING | LOG_ERRNO, "engine: warning: serialize error for %s%s to %s: write error", back[i].url_adr, back[i].url_fil, filename); } fclose(fp); } else { hts_log_print(opt, LOG_WARNING | LOG_ERRNO, "engine: warning: serialize error for %s%s to %s: open error (%s, %s)", back[i].url_adr, back[i].url_fil, filename, dir_exists(filename) ? "directory exists" : "directory does NOT exist!", fexist_utf8(filename) ? "file already exists!" : "file does not exist"); } if (filename != NULL) free(filename); } else { hts_log_print(opt, LOG_WARNING | LOG_ERRNO, "engine: warning: serialize error for %s%s: memory full", back[i].url_adr, back[i].url_fil); } } #else itemback = calloct(1, sizeof(lien_back)); back_move(&back[i], itemback); coucal_add_pvoid(sback->ready, itemback->url_sav, itemback); nclean++; #endif } } return nclean; } // nombre d'entrées libres dans le backing int back_available(const struct_back * sback) { const lien_back *const back = sback->lnk; const int back_max = sback->count; int i; int nb = 0; for(i = 0; i < back_max; i++) if (back[i].status == STATUS_FREE) /* libre */ nb++; return nb; } // retourne estimation de la taille des html et fichiers stockés en mémoire LLint back_incache(const struct_back * sback) { const lien_back *const back = sback->lnk; const int back_max = sback->count; int i; LLint sum = 0; for(i = 0; i < back_max; i++) if (back[i].status != -1) if (back[i].r.adr) // ne comptabilier que les blocs en mémoire sum += max(back[i].r.size, back[i].r.totalsize); // stored (ready) slots #ifdef HTS_NO_BACK_ON_DISK if (sback->ready != NULL) { struct_coucal_enum e = coucal_enum_new(sback->ready); coucal_item *item; while((item = coucal_enum_next(&e))) { lien_back *ritem = (lien_back *) item->value.ptr; if (ritem->status != -1) if (ritem->r.adr) // ne comptabilier que les blocs en mémoire sum += max(ritem->r.size, ritem->r.totalsize); } } #endif return sum; } // retourne estimation de la taille des html et fichiers stockés en mémoire int back_done_incache(const struct_back * sback) { const lien_back *const back = sback->lnk; const int back_max = sback->count; int i; int n = 0; for(i = 0; i < back_max; i++) if (back[i].status == STATUS_READY) n++; // stored (ready) slots if (sback->ready != NULL) { #ifndef HTS_NO_BACK_ON_DISK n += (int) coucal_nitems(sback->ready); #else struct_coucal_enum e = coucal_enum_new(sback->ready); coucal_item *item; while((item = coucal_enum_next(&e))) { lien_back *ritem = (lien_back *) item->value.ptr; if (ritem->status == STATUS_READY) n++; } #endif } return n; } // le lien a-t-il été mis en backing? HTS_INLINE int back_exist(struct_back * sback, httrackp * opt, const char *adr, const char *fil, const char *sav) { return (back_index_fetch(opt, sback, adr, fil, sav, /*don't fetch */ 0) >= 0); } // nombre de sockets en tâche de fond int back_nsoc(const struct_back * sback) { const lien_back *const back = sback->lnk; const int back_max = sback->count; int n = 0; int i; for(i = 0; i < back_max; i++) if (back[i].status > 0) // only receive n++; return n; } int back_nsoc_overall(const struct_back * sback) { const lien_back *const back = sback->lnk; const int back_max = sback->count; int n = 0; int i; for(i = 0; i < back_max; i++) if (back[i].status > 0 || back[i].status == STATUS_ALIVE) n++; return n; } /* generate temporary file on lien_back */ /* Note: utf-8 */ static int create_back_tmpfile(httrackp * opt, lien_back *const back) { // do not use tempnam() but a regular filename back->tmpfile_buffer[0] = '\0'; if (back->url_sav != NULL && back->url_sav[0] != '\0') { snprintf(back->tmpfile_buffer, sizeof(back->tmpfile_buffer), "%s.z", back->url_sav); back->tmpfile = back->tmpfile_buffer; if (structcheck(back->tmpfile) != 0) { hts_log_print(opt, LOG_WARNING, "can not create directory to %s", back->tmpfile); return -1; } } else { snprintf(back->tmpfile_buffer, sizeof(back->tmpfile_buffer), "%s/tmp%d.z", StringBuff(opt->path_html_utf8), opt->state.tmpnameid++); back->tmpfile = back->tmpfile_buffer; } /* OK */ hts_log_print(opt, LOG_TRACE, "produced temporary name %s", back->tmpfile); return 0; } // objet (lien) téléchargé ou transféré depuis le cache // // fermer les paramètres de transfert, // et notamment vérifier les fichiers compressés (décompresser), callback etc. int back_finalize(httrackp * opt, cache_back * cache, struct_back * sback, const int p) { char catbuff[CATBUFF_SIZE]; lien_back *const back = sback->lnk; const int back_max = sback->count; assertf(p >= 0 && p < back_max); /* Store ? */ if (!back[p].finalized) { back[p].finalized = 1; /* Don't store broken files. Note: check is done before compression. If the file is partial, the next run will attempt to continue it with compression too. */ if (back[p].r.totalsize >= 0 && back[p].r.statuscode > 0 && back[p].r.size != back[p].r.totalsize && !opt->tolerant) { if (back[p].status == STATUS_READY) { hts_log_print(opt, LOG_WARNING, "file not stored in cache due to bogus state (broken size, expected " LLintP " got " LLintP "): %s%s", back[p].r.totalsize, back[p].r.size, back[p].url_adr, back[p].url_fil); } else { hts_log_print(opt, LOG_INFO, "incomplete file not yet stored in cache (expected " LLintP " got " LLintP "): %s%s", back[p].r.totalsize, back[p].r.size, back[p].url_adr, back[p].url_fil); } return -1; } if ((back[p].status == STATUS_READY) // ready && (back[p].r.statuscode > 0) // not internal error ) { if (!back[p].testmode) { // not test mode const char *state = "unknown"; /* décompression */ #if HTS_USEZLIB if (back[p].r.compressed) { if (back[p].r.size > 0) { //if ( (back[p].r.adr) && (back[p].r.size>0) ) { // stats back[p].compressed_size = back[p].r.size; // en mémoire -> passage sur disque if (!back[p].r.is_write) { // do not use tempnam() but a regular filename if (create_back_tmpfile(opt, &back[p]) == 0) { assertf(back[p].tmpfile != NULL); /* note: tmpfile is utf-8 */ back[p].r.out = FOPEN(back[p].tmpfile, "wb"); if (back[p].r.out) { if ((back[p].r.adr) && (back[p].r.size > 0)) { if (fwrite (back[p].r.adr, 1, (size_t) back[p].r.size, back[p].r.out) != back[p].r.size) { back[p].r.statuscode = STATUSCODE_INVALID; strcpybuff(back[p].r.msg, "Write error when decompressing"); } } else { back[p].tmpfile[0] = '\0'; back[p].r.statuscode = STATUSCODE_INVALID; strcpybuff(back[p].r.msg, "Empty compressed file"); } } else { snprintf(back[p].r.msg, sizeof(back[p].r.msg), "Open error when decompressing (can not create temporary file %s)", back[p].tmpfile); back[p].tmpfile[0] = '\0'; back[p].r.statuscode = STATUSCODE_INVALID; } } else { snprintf(back[p].r.msg, sizeof(back[p].r.msg), "Open error when decompressing (can not generate a temporary file)"); } } // fermer fichier sortie if (back[p].r.out != NULL) { fclose(back[p].r.out); back[p].r.out = NULL; } // décompression if (back[p].tmpfile != NULL) { if (back[p].url_sav[0]) { LLint size; file_notify(opt, back[p].url_adr, back[p].url_fil, back[p].url_sav, 1, 1, back[p].r.notmodified); filecreateempty(&opt->state.strc, back[p].url_sav); // filenote & co if ((size = hts_zunpack(back[p].tmpfile, back[p].url_sav)) >= 0) { back[p].r.size = back[p].r.totalsize = size; // fichier -> mémoire if (!back[p].r.is_write) { deleteaddr(&back[p].r); back[p].r.adr = readfile_utf8(back[p].url_sav); if (!back[p].r.adr) { back[p].r.statuscode = STATUSCODE_INVALID; strcpybuff(back[p].r.msg, "Read error when decompressing"); } UNLINK(back[p].url_sav); } } else { back[p].r.statuscode = STATUSCODE_INVALID; strcpybuff(back[p].r.msg, "Error when decompressing"); } } /* ensure that no remaining temporary file exists */ unlink(back[p].tmpfile); back[p].tmpfile = NULL; } // stats HTS_STAT.total_packed += back[p].compressed_size; HTS_STAT.total_unpacked += back[p].r.size; HTS_STAT.total_packedfiles++; // unflag } } #endif /* Write mode to disk */ if (back[p].r.is_write && back[p].r.adr != NULL) { freet(back[p].r.adr); back[p].r.adr = NULL; } /* remove reference file, if any */ if (back[p].r.is_write) { url_savename_refname_remove(opt, back[p].url_adr, back[p].url_fil); } /* ************************************************************************ REAL MEDIA HACK Check if we have to load locally the file ************************************************************************ */ if (back[p].r.statuscode == HTTP_OK) { // OK (ou 304 en backing) if (back[p].r.is_write) { // Written file if (may_be_hypertext_mime(opt, back[p].r.contenttype, back[p].url_fil)) { // to parse! off_t sz; sz = fsize_utf8(back[p].url_sav); if (sz > 0) { // ok, exists! if (sz < 8192) { // ok, small file --> to parse! FILE *fp = FOPEN(back[p].url_sav, "rb"); if (fp) { back[p].r.adr = malloct((size_t) sz + 1); if (back[p].r.adr) { if (fread(back[p].r.adr, 1, sz, fp) == sz) { back[p].r.size = sz; back[p].r.adr[sz] = '\0'; back[p].r.is_write = 0; /* not anymore a direct-to-disk file */ } else { freet(back[p].r.adr); back[p].r.size = 0; back[p].r.adr = NULL; back[p].r.statuscode = STATUSCODE_INVALID; strcpybuff(back[p].r.msg, ".RAM read error"); } fclose(fp); fp = NULL; // remove (temporary) file! UNLINK(fconv(catbuff, sizeof(catbuff), back[p].url_sav)); } if (fp) fclose(fp); } } } } } } /* EN OF REAL MEDIA HACK */ /* Stats */ if (cache->txt) { char flags[32]; char s[256]; time_t tt; struct tm *A; tt = time(NULL); A = localtime(&tt); if (A == NULL) { int localtime_returned_null = 0; assertf(localtime_returned_null); } strftime(s, 250, "%H:%M:%S", A); flags[0] = '\0'; /* input flags */ if (back[p].is_update) strcatbuff(flags, "U"); // update request else strcatbuff(flags, "-"); if (back[p].range_req_size) strcatbuff(flags, "R"); // range request else strcatbuff(flags, "-"); /* state flags */ if (back[p].r.is_file) // direct to disk strcatbuff(flags, "F"); else strcatbuff(flags, "-"); /* output flags */ if (!back[p].r.notmodified) strcatbuff(flags, "M"); // modified else strcatbuff(flags, "-"); if (back[p].r.is_chunk) // chunked strcatbuff(flags, "C"); else strcatbuff(flags, "-"); if (back[p].r.compressed) strcatbuff(flags, "Z"); // gzip else strcatbuff(flags, "-"); /* Err I had to split these.. */ fprintf(cache->txt, "%s\t", s); fprintf(cache->txt, LLintP "/", (LLint) back[p].r.size); fprintf(cache->txt, LLintP, (LLint) back[p].r.totalsize); fprintf(cache->txt, "\t%s\t", flags); } #if HTS_USEZLIB back[p].r.compressed = 0; #endif if (back[p].r.statuscode == HTTP_OK) { if (back[p].r.size >= 0) { if (strcmp(back[p].url_fil, "/robots.txt") != 0) { HTS_STAT.stat_bytes += back[p].r.size; HTS_STAT.stat_files++; hts_log_print(opt, LOG_TRACE, "added file %s%s => %s", back[p].url_adr, back[p].url_fil, back[p].url_sav != NULL ? back[p].url_sav : ""); } if ((!back[p].r.notmodified) && (opt->is_update)) { HTS_STAT.stat_updated_files++; // page modifiée if (back[p].is_update) { hts_log_print(opt, LOG_INFO, "engine: transfer-status: link updated: %s%s -> %s", back[p].url_adr, back[p].url_fil, back[p].url_sav); } else { hts_log_print(opt, LOG_INFO, "engine: transfer-status: link added: %s%s -> %s", back[p].url_adr, back[p].url_fil, back[p].url_sav); } if (cache->txt) { if (back[p].is_update) { state = "updated"; } else { state = "added"; } } } else { hts_log_print(opt, LOG_INFO, "engine: transfer-status: link recorded: %s%s -> %s", back[p].url_adr, back[p].url_fil, back[p].url_sav); if (cache->txt) { if (opt->is_update) state = "untouched"; else state = "added"; } } } else { hts_log_print(opt, LOG_INFO, "engine: transfer-status: empty file? (%d, '%s'): %s%s", back[p].r.statuscode, back[p].r.msg, back[p].url_adr, back[p].url_fil); if (cache->txt) { state = "empty"; } } } else { hts_log_print(opt, LOG_INFO, "engine: transfer-status: link error (%d, '%s'): %s%s", back[p].r.statuscode, back[p].r.msg, back[p].url_adr, back[p].url_fil); if (cache->txt) { state = "error"; } } if (cache->txt) { #undef ESC_URL #define ESC_URL(S) escape_check_url_addr(S, OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt)) fprintf(cache->txt, "%d\t" "%s ('%s')\t" "%s\t" "%s%s\t" "%s%s%s\t%s\t" "(from %s%s%s)" LF, back[p].r.statuscode, state, ESC_URL(back[p].r.msg), ESC_URL(back[p].r.contenttype), ((back[p].r.etag[0]) ? "etag:" : ((back[p].r. lastmodified[0]) ? "date:" : "")), ESC_URL((back[p].r.etag[0]) ? back[p].r. etag : (back[p].r.lastmodified)), (link_has_authority(back[p].url_adr) ? "" : "http://"), ESC_URL(back[p].url_adr), ESC_URL(back[p].url_fil), ESC_URL(back[p].url_sav), (link_has_authority(back[p].referer_adr) || !back[p].referer_adr[0]) ? "" : "http://", ESC_URL(back[p].referer_adr), ESC_URL(back[p].referer_fil) ); #undef ESC_URL if (opt->flush) fflush(cache->txt); } /* Cache */ if (!IS_DELAYED_EXT(back[p].url_sav)) { cache_mayadd(opt, cache, &back[p].r, back[p].url_adr, back[p].url_fil, back[p].url_sav); } else { /* error */ if (!HTTP_IS_OK(back[p].r.statuscode)) { hts_log_print(opt, LOG_DEBUG, "redirect to %s%s", back[p].url_adr, back[p].url_fil); /* Store only header reference */ cache_mayadd(opt, cache, &back[p].r, back[p].url_adr, back[p].url_fil, NULL); } else { /* Partial file, but marked as "ok" ? */ hts_log_print(opt, LOG_WARNING, "file not stored in cache due to bogus state (incomplete type with %s (%d), size " LLintP "): %s%s", back[p].r.msg, back[p].r.statuscode, (LLint) back[p].r.size, back[p].url_adr, back[p].url_fil); } } // status finished callback RUN_CALLBACK1(opt, xfrstatus, &back[p]); return 0; } else { // testmode if (back[p].r.statuscode / 100 >= 3) { /* Store 3XX, 4XX, 5XX test response codes, but NOT 2XX */ /* Cache */ cache_mayadd(opt, cache, &back[p].r, back[p].url_adr, back[p].url_fil, NULL); } } } } return -1; } /* try to keep the connection alive */ int back_letlive(httrackp * opt, cache_back * cache, struct_back * sback, const int p) { lien_back *const back = sback->lnk; const int back_max = sback->count; int checkerror; htsblk *src = &back[p].r; assertf(p >= 0 && p < back_max); if (src && !src->is_file && src->soc != INVALID_SOCKET && src->statuscode >= 0 /* no timeout errors & co */ && src->keep_alive_trailers == 0 /* not yet supported (chunk trailers) */ && !(checkerror = check_sockerror(src->soc)) /*&& !check_sockdata(src->soc) *//* no unexpected data */ ) { htsblk tmp; memset(&tmp, 0, sizeof(tmp)); /* clear everything but connection: switch, close, and reswitch */ back_connxfr(src, &tmp); back_delete(opt, cache, sback, p); //deletehttp(src); back_connxfr(&tmp, src); src->req.flush_garbage = 1; /* ignore CRLF garbage */ return 1; } return 0; } void back_connxfr(htsblk * src, htsblk * dst) { dst->soc = src->soc; src->soc = INVALID_SOCKET; #if HTS_USEOPENSSL dst->ssl = src->ssl; src->ssl = 0; dst->ssl_con = src->ssl_con; src->ssl_con = NULL; #endif dst->keep_alive = src->keep_alive; src->keep_alive = 0; dst->keep_alive_max = src->keep_alive_max; src->keep_alive_max = 0; dst->keep_alive_t = src->keep_alive_t; src->keep_alive_t = 0; dst->debugid = src->debugid; src->debugid = 0; } void back_move(lien_back * src, lien_back * dst) { memcpy(dst, src, sizeof(lien_back)); memset(src, 0, sizeof(lien_back)); src->r.soc = INVALID_SOCKET; src->status = STATUS_FREE; src->r.location = src->location_buffer; dst->r.location = dst->location_buffer; } void back_copy_static(const lien_back * src, lien_back * dst) { memcpy(dst, src, sizeof(lien_back)); dst->r.soc = INVALID_SOCKET; dst->r.adr = NULL; dst->r.headers = NULL; dst->r.out = NULL; dst->r.location = dst->location_buffer; dst->r.fp = NULL; #if HTS_USEOPENSSL dst->r.ssl_con = NULL; #endif } static int back_data_serialize(FILE * fp, const void *data, size_t size) { if (fwrite(&size, 1, sizeof(size), fp) == sizeof(size) && (size == 0 || fwrite(data, 1, size, fp) == size) ) return 0; return 1; /* error */ } static int back_string_serialize(FILE * fp, const char *str) { size_t size = (str != NULL) ? (strlen(str) + 1) : 0; return back_data_serialize(fp, str, size); } static int back_data_unserialize(FILE * fp, void **str, size_t * size) { *str = NULL; if (fread(size, 1, sizeof(*size), fp) == sizeof(*size)) { if (*size == 0) /* serialized NULL ptr */ return 0; *str = malloct(*size + 1); if (*str == NULL) return 1; /* error */ ((char *) *str)[*size] = 0; /* guard byte */ if (fread(*str, 1, *size, fp) == *size) return 0; } return 1; /* error */ } static int back_string_unserialize(FILE * fp, char **str) { size_t dummy; return back_data_unserialize(fp, (void **) str, &dummy); } int back_serialize(FILE * fp, const lien_back * src) { if (back_data_serialize(fp, src, sizeof(lien_back)) == 0 && back_data_serialize(fp, src->r.adr, src->r.adr ? (size_t) src->r.size : 0) == 0 && back_string_serialize(fp, src->r.headers) == 0 && fflush(fp) == 0) return 0; return 1; } int back_unserialize(FILE * fp, lien_back ** dst) { size_t size; *dst = NULL; errno = 0; if (back_data_unserialize(fp, (void **) dst, &size) == 0 && size == sizeof(lien_back)) { (*dst)->tmpfile = NULL; (*dst)->chunk_adr = NULL; (*dst)->r.adr = NULL; (*dst)->r.out = NULL; (*dst)->r.location = (*dst)->location_buffer; (*dst)->r.fp = NULL; (*dst)->r.soc = INVALID_SOCKET; #if HTS_USEOPENSSL (*dst)->r.ssl_con = NULL; #endif if (back_data_unserialize(fp, (void **) &(*dst)->r.adr, &size) == 0) { (*dst)->r.size = size; (*dst)->r.headers = NULL; if (back_string_unserialize(fp, &(*dst)->r.headers) == 0) return 0; /* ok */ if ((*dst)->r.headers != NULL) freet((*dst)->r.headers); } if ((*dst)->r.adr != NULL) freet((*dst)->r.adr); } if (dst != NULL) { freet(*dst); *dst = NULL; } return 1; /* error */ } /* serialize a reference ; used to store references of files being downloaded in case of broken download */ /* Note: NOT utf-8 */ int back_serialize_ref(httrackp * opt, const lien_back * src) { const char *filename = url_savename_refname_fullpath(opt, src->url_adr, src->url_fil); FILE *fp = fopen(filename, "wb"); if (fp == NULL) { #ifdef _WIN32 if (mkdir (fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), CACHE_REFNAME)) == 0) #else if (mkdir (fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), CACHE_REFNAME), S_IRWXU | S_IRWXG | S_IRWXO) == 0) #endif { /* note: local filename */ filename = url_savename_refname_fullpath(opt, src->url_adr, src->url_fil); fp = fopen(filename, "wb"); } } if (fp != NULL) { int ser = back_serialize(fp, src); fclose(fp); return ser; } return 1; } /* unserialize a reference ; used to store references of files being downloaded in case of broken download */ int back_unserialize_ref(httrackp * opt, const char *adr, const char *fil, lien_back ** dst) { const char *filename = url_savename_refname_fullpath(opt, adr, fil); FILE *fp = FOPEN(filename, "rb"); if (fp != NULL) { int ser = back_unserialize(fp, dst); fclose(fp); if (ser != 0) { /* back_unserialize_ref() != 0 does not need cleaning up */ back_clear_entry(*dst); /* delete entry content */ freet(*dst); /* delete item */ *dst = NULL; } return ser; } return 1; } // clear, or leave for keep-alive int back_maydelete(httrackp * opt, cache_back * cache, struct_back * sback, const int p) { lien_back *const back = sback->lnk; const int back_max = sback->count; assertf(p >= 0 && p < back_max); if (p >= 0 && p < back_max) { // on sait jamais.. if ( /* Keep-alive authorized by user */ !opt->nokeepalive /* Socket currently is keep-alive! */ && back[p].r.keep_alive /* Remaining authorized requests */ && back[p].r.keep_alive_max > 1 /* Known keep-alive start (security) */ && back[p].ka_time_start /* We're on time */ && time_local() < back[p].ka_time_start + back[p].r.keep_alive_t /* Connection delay must not exceed keep-alive timeout */ && (opt->maxconn <= 0 || (back[p].r.keep_alive_t > (1.0 / opt->maxconn))) ) { lien_back tmp; strcpybuff(tmp.url_adr, back[p].url_adr); tmp.ka_time_start = back[p].ka_time_start; if (back_letlive(opt, cache, sback, p)) { strcpybuff(back[p].url_adr, tmp.url_adr); back[p].ka_time_start = tmp.ka_time_start; back[p].status = STATUS_ALIVE; // alive & waiting assertf(back[p].ka_time_start != 0); hts_log_print(opt, LOG_DEBUG, "(Keep-Alive): successfully saved #%d (%s)", back[p].r.debugid, back[p].url_adr); return 1; } } back_delete(opt, cache, sback, p); } return 0; } // clear, or leave for keep-alive void back_maydeletehttp(httrackp * opt, cache_back * cache, struct_back * sback, const int p) { lien_back *const back = sback->lnk; const int back_max = sback->count; TStamp lt = 0; assertf(p >= 0 && p < back_max); if (back[p].r.soc != INVALID_SOCKET) { int q; if (back[p].r.soc != INVALID_SOCKET /* security check */ && back[p].r.statuscode >= 0 /* no timeout errors & co */ && back[p].r.keep_alive_trailers == 0 /* not yet supported (chunk trailers) */ /* Socket not in I/O error status */ && !back[p].r.is_file && !check_sockerror(back[p].r.soc) /* Keep-alive authorized by user */ && !opt->nokeepalive /* Socket currently is keep-alive! */ && back[p].r.keep_alive /* Remaining authorized requests */ && back[p].r.keep_alive_max > 1 /* Known keep-alive start (security) */ && back[p].ka_time_start /* We're on time */ && (lt = time_local()) < back[p].ka_time_start + back[p].r.keep_alive_t /* Connection delay must not exceed keep-alive timeout */ && (opt->maxconn <= 0 || (back[p].r.keep_alive_t > (1.0 / opt->maxconn))) /* Available slot in backing */ && (q = back_search(opt, sback)) >= 0) { lien_back tmp; strcpybuff(tmp.url_adr, back[p].url_adr); tmp.ka_time_start = back[p].ka_time_start; deletehttp(&back[q].r); // security check back_connxfr(&back[p].r, &back[q].r); // transfer live connection settings from p to q back[q].ka_time_start = back[p].ka_time_start; // refresh back[p].r.soc = INVALID_SOCKET; strcpybuff(back[q].url_adr, tmp.url_adr); // address back[q].ka_time_start = tmp.ka_time_start; back[q].status = STATUS_ALIVE; // alive & waiting assertf(back[q].ka_time_start != 0); hts_log_print(opt, LOG_DEBUG, "(Keep-Alive): successfully preserved #%d (%s)", back[q].r.debugid, back[q].url_adr); } else { deletehttp(&back[p].r); back[p].r.soc = INVALID_SOCKET; } } } /* attempt to attach a live connection to this slot */ int back_trylive(httrackp * opt, cache_back * cache, struct_back * sback, const int p) { lien_back *const back = sback->lnk; const int back_max = sback->count; assertf(p >= 0 && p < back_max); if (p >= 0 && back[p].status != STATUS_ALIVE) { // we never know.. int i = back_searchlive(opt, sback, back[p].url_adr); // search slot if (i >= 0 && i != p) { deletehttp(&back[p].r); // security check back_connxfr(&back[i].r, &back[p].r); // transfer live connection settings from i to p back[p].ka_time_start = back[i].ka_time_start; back_delete(opt, cache, sback, i); // delete old slot back[p].status = STATUS_CONNECTING; // ready to connect return 1; // success: will reuse live connection } } return 0; } /* search for a live position, or, if not possible, try to return a new one */ int back_searchlive(httrackp * opt, struct_back * sback, const char *search_addr) { lien_back *const back = sback->lnk; const int back_max = sback->count; int i; /* search for a live socket */ for(i = 0; i < back_max; i++) { if (back[i].status == STATUS_ALIVE) { if (strfield2(back[i].url_adr, search_addr)) { /* same location (xxc: check also virtual hosts?) */ if (time_local() < back[i].ka_time_start + back[i].r.keep_alive_t) { return i; } } } } return -1; } int back_search_quick(struct_back * sback) { lien_back *const back = sback->lnk; const int back_max = sback->count; int i; /* try to find an empty place */ for(i = 0; i < back_max; i++) { if (back[i].status == STATUS_FREE) { return i; } } /* oops, can't find a place */ return -1; } int back_search(httrackp * opt, struct_back * sback) { lien_back *const back = sback->lnk; const int back_max = sback->count; int i; /* try to find an empty place */ if ((i = back_search_quick(sback)) != -1) return i; /* couldn't find an empty place, try to requisition a keep-alive place */ for(i = 0; i < back_max; i++) { if (back[i].status == STATUS_ALIVE) { lien_back *const back = sback->lnk; /* close this place */ back_clear_entry(&back[i]); /* Already finalized (this is the night of the living dead) */ /*back_delete(opt,cache,sback, i); */ return i; } } /* oops, can't find a place */ return -1; } void back_set_finished(struct_back * sback, const int p) { lien_back *const back = sback->lnk; const int back_max = sback->count; assertf(p >= 0 && p < back_max); if (p >= 0 && p < sback->count) { // we never know.. /* status: finished (waiting to be validated) */ back[p].status = STATUS_READY; /* finished */ /* close open r/w streams, if any */ if (back[p].r.fp != NULL) { fclose(back[p].r.fp); back[p].r.fp = NULL; } if (back[p].r.out != NULL) { // fermer fichier sortie fclose(back[p].r.out); back[p].r.out = NULL; } } } void back_set_locked(struct_back * sback, const int p) { lien_back *const back = sback->lnk; const int back_max = sback->count; assertf(p >= 0 && p < back_max); if (p >= 0 && p < sback->count) { /* status: locked (in process, do not swap on disk) */ back[p].locked = 1; /* locked */ } } void back_set_unlocked(struct_back * sback, const int p) { lien_back *const back = sback->lnk; const int back_max = sback->count; assertf(p >= 0 && p < back_max); if (p >= 0 && p < sback->count) { /* status: unlocked (can be swapped on disk) */ back[p].locked = 0; /* unlocked */ } } int back_flush_output(httrackp * opt, cache_back * cache, struct_back * sback, const int p) { lien_back *const back = sback->lnk; const int back_max = sback->count; assertf(p >= 0 && p < back_max); if (p >= 0 && p < sback->count) { // on sait jamais.. /* close input file */ if (back[p].r.fp != NULL) { fclose(back[p].r.fp); back[p].r.fp = NULL; } /* fichier de sortie */ if (back[p].r.out != NULL) { // fermer fichier sortie fclose(back[p].r.out); back[p].r.out = NULL; } /* set file time */ if (back[p].r.is_write) { // ecriture directe /* écrire date "remote" */ if (strnotempty(back[p].url_sav) && strnotempty(back[p].r.lastmodified) && fexist_utf8(back[p].url_sav)) // normalement existe si on a un fichier de sortie { set_filetime_rfc822(back[p].url_sav, back[p].r.lastmodified); } /* executer commande utilisateur après chargement du fichier */ //xx usercommand(opt,0,NULL,back[p].url_sav, back[p].url_adr, back[p].url_fil); back[p].r.is_write = 0; } return 1; } return 0; } // effacer entrée int back_delete(httrackp * opt, cache_back * cache, struct_back * sback, const int p) { lien_back *const back = sback->lnk; const int back_max = sback->count; assertf(p >= 0 && p < back_max); if (p >= 0 && p < sback->count) { // on sait jamais.. // Vérificateur d'intégrité #if DEBUG_CHECKINT _CHECKINT(&back[p], "Appel back_delete") #endif #if HTS_DEBUG_CLOSESOCK DEBUG_W("back_delete: #%d\n" _(int) p); #endif // Finalize if (!back[p].finalized) { if ((back[p].status == STATUS_READY) // ready && (!back[p].testmode) // not test mode && (back[p].r.statuscode > 0) // not internal error ) { hts_log_print(opt, LOG_DEBUG, "File '%s%s' -> %s not yet saved in cache - saving now", back[p].url_adr, back[p].url_fil, back[p].url_sav); } if (cache != NULL) { //hts_log_print(opt, LOG_TRACE, "finalizing from back_delete"); back_finalize(opt, cache, sback, p); } } back[p].finalized = 0; // flush output buffers (void) back_flush_output(opt, cache, sback, p); return back_clear_entry(&back[p]); } return 0; } /* ensure that the entry is not locked */ void back_index_unlock(struct_back * sback, const int p) { lien_back *const back = sback->lnk; if (back[p].locked) { back[p].locked = 0; /* not locked anymore */ } } /* the entry is available again */ static void back_set_free(lien_back * back) { back->locked = 0; back->status = STATUS_FREE; } /* delete entry content (clear the entry), but don't unallocate the entry itself */ int back_clear_entry(lien_back * back) { if (back != NULL) { // Libérer tous les sockets, handles, buffers.. if (back->r.soc != INVALID_SOCKET) { #if HTS_DEBUG_CLOSESOCK DEBUG_W("back_delete: deletehttp\n"); #endif deletehttp(&back->r); back->r.soc = INVALID_SOCKET; } if (back->r.adr != NULL) { // reste un bloc à désallouer freet(back->r.adr); back->r.adr = NULL; } if (back->chunk_adr != NULL) { // reste un bloc à désallouer freet(back->chunk_adr); back->chunk_adr = NULL; back->chunk_size = 0; back->chunk_blocksize = 0; back->is_chunk = 0; } // only for security if (back->tmpfile && back->tmpfile[0] != '\0') { (void) unlink(back->tmpfile); back->tmpfile = NULL; } // headers if (back->r.headers != NULL) { freet(back->r.headers); back->r.headers = NULL; } // Tout nettoyer memset(back, 0, sizeof(lien_back)); back->r.soc = INVALID_SOCKET; back->r.location = back->location_buffer; // Le plus important: libérer le champ back_set_free(back); return 1; } return 0; } /* Space left on backing stack */ int back_stack_available(struct_back * sback) { lien_back *const back = sback->lnk; const int back_max = sback->count; int p = 0, n = 0; for(; p < back_max; p++) if (back[p].status == STATUS_FREE) n++; return n; } // ajouter un lien en backing int back_add_if_not_exists(struct_back * sback, httrackp * opt, cache_back * cache, const char *adr, const char *fil, const char *save, const char *referer_adr, const char *referer_fil, int test) { back_clean(opt, cache, sback); /* first cleanup the backlog to ensure that we have some entry left */ if (!back_exist(sback, opt, adr, fil, save)) { return back_add(sback, opt, cache, adr, fil, save, referer_adr, referer_fil, test); } return 0; } int back_add(struct_back * sback, httrackp * opt, cache_back * cache, const char *adr, const char *fil, const char *save, const char *referer_adr, const char *referer_fil, int test) { lien_back *const back = sback->lnk; const int back_max = sback->count; int p = 0; char catbuff[CATBUFF_SIZE]; char catbuff2[CATBUFF_SIZE]; lien_back *itemback = NULL; #if (defined(_DEBUG) || defined(DEBUG)) if (!test && back_exist(sback, opt, adr, fil, save)) { int already_there = 0; hts_log_print(opt, LOG_ERROR, "error: back_add(%s,%s,%s) duplicate", adr, fil, save); } #endif // vérifier cohérence de adr et fil (non vide!) if (strnotempty(adr) == 0) { hts_log_print(opt, LOG_WARNING, "error: adr is empty for back_add"); return -1; // erreur! } if (strnotempty(fil) == 0) { hts_log_print(opt, LOG_WARNING, "error: fil is empty for back_add"); return -1; // erreur! } // FIN vérifier cohérence de adr et fil (non vide!) // stats opt->state.back_add_stats++; // rechercher emplacement back_clean(opt, cache, sback); if ((p = back_search(opt, sback)) >= 0) { back[p].send_too[0] = '\0'; // éventuels paramètres supplémentaires à transmettre au serveur // clear r if (back[p].r.soc != INVALID_SOCKET) { /* we never know */ deletehttp(&back[p].r); } //memset(&(back[p].r), 0, sizeof(htsblk)); hts_init_htsblk(&back[p].r); back[p].r.location = back[p].location_buffer; // créer entrée strcpybuff(back[p].url_adr, adr); strcpybuff(back[p].url_fil, fil); strcpybuff(back[p].url_sav, save); //back[p].links_index = links_index; // copier referer si besoin strcpybuff(back[p].referer_adr, ""); strcpybuff(back[p].referer_fil, ""); if ((referer_adr) && (referer_fil)) { // existe if ((strnotempty(referer_adr)) && (strnotempty(referer_fil))) { // non vide if (referer_adr[0] != '!') { // non détruit if (strcmp(referer_adr, "file://")) { // PAS file:// if (strcmp(referer_adr, "primary")) { // pas referer 1er lien strcpybuff(back[p].referer_adr, referer_adr); strcpybuff(back[p].referer_fil, referer_fil); } } } } } // sav ne sert à rien pour le moment back[p].r.size = 0; // rien n'a encore été chargé back[p].r.adr = NULL; // pas de bloc de mémoire back[p].r.is_write = 0; // à priori stockage en mémoire back[p].maxfile_html = opt->maxfile_html; back[p].maxfile_nonhtml = opt->maxfile_nonhtml; back[p].testmode = test; // mode test? if (!opt->http10) // option "forcer 1.0" désactivée back[p].http11 = 1; // autoriser http/1.1 back[p].head_request = 0; if (strcmp(back[p].url_sav, BACK_ADD_TEST) == 0) // HEAD back[p].head_request = 1; else if (strcmp(back[p].url_sav, BACK_ADD_TEST2) == 0) // test en GET back[p].head_request = 2; // test en get /* Stop requested - abort backing */ /* For update mode: second check after cache lookup not to lose all previous cache data ! */ if (opt->state.stop && !opt->is_update) { back[p].r.statuscode = STATUSCODE_INVALID; // fatal strcpybuff(back[p].r.msg, "mirror stopped by user"); back[p].status = STATUS_READY; // terminé back_set_finished(sback, p); hts_log_print(opt, LOG_WARNING, "File not added due to mirror cancel: %s%s", adr, fil); return 0; } // test "fast header" cache ; that is, tests we did that lead to 3XX/4XX/5XX response codes if (cache->cached_tests != NULL) { intptr_t ptr = 0; if (coucal_read(cache->cached_tests, concat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), adr, fil), &ptr)) { // gotcha if (ptr != 0) { char *text = (char *) ptr; char *lf = strchr(text, '\n'); int code = 0; if (sscanf(text, "%d", &code) == 1) { // got code back[p].r.statuscode = code; back[p].status = STATUS_READY; // terminé if (lf != NULL && *lf != '\0') { // got location ? strcpybuff(back[p].r.location, lf + 1); } return 0; } } } } // tester cache if ((strcmp(adr, "file://")) /* pas fichier */ &&((!test) || (cache->type == 1)) /* cache prioritaire, laisser passer en test! */ &&((strnotempty(save)) || (strcmp(fil, "/robots.txt") == 0))) { // si en test on ne doit pas utiliser le cache sinon telescopage avec le 302.. #if HTS_FAST_CACHE intptr_t hash_pos; int hash_pos_return = 0; #else char *a = NULL; #endif #if HTS_FAST_CACHE if (cache->hashtable) { #else if (cache->use) { #endif char BIGSTK buff[HTS_URLMAXSIZE * 4]; #if HTS_FAST_CACHE strcpybuff(buff, adr); strcatbuff(buff, fil); hash_pos_return = coucal_read(cache->hashtable, buff, &hash_pos); #else buff[0] = '\0'; strcatbuff(buff, "\n"); strcatbuff(buff, adr); strcatbuff(buff, "\n"); strcatbuff(buff, fil); strcatbuff(buff, "\n"); a = strstr(cache->use, buff); #endif // Ok, noté en cache->. mais bien présent dans le cache ou sur disque? #if HTS_FAST_CACHE // negative values when data is not in cache if (hash_pos_return < 0) { #else if (a) { #endif if (!test) { // non mode test #if HTS_FAST_CACHE==0 int pos = -1; a += strlen(buff); sscanf(a, "%d", &pos); // lire position #endif #if HTS_FAST_CACHE==0 if (pos < 0) { // pas de mise en cache data, vérifier existence #endif /* note: no check with IS_DELAYED_EXT() enabled - postcheck by client please! */ if (save[0] != '\0' && !IS_DELAYED_EXT(save) && fsize_utf8(fconv(catbuff, sizeof(catbuff), save)) <= 0) { // fichier final n'existe pas ou est vide! int found = 0; /* It is possible that the file has been moved due to changes in build structure */ { char BIGSTK previous_save[HTS_URLMAXSIZE * 2]; htsblk r; previous_save[0] = '\0'; r = cache_readex(opt, cache, adr, fil, /*head */ NULL, /*bound to back[p] (temporary) */ back[p].location_buffer, previous_save, /*ro */ 1); /* Is supposed to be on disk only */ if (r.is_write && previous_save[0] != '\0') { /* Exists, but with another (old) filename: rename (almost) silently */ if (strcmp(previous_save, save) != 0 && fexist_utf8(fconv(catbuff, sizeof(catbuff), previous_save))) { rename(fconv(catbuff, sizeof(catbuff), previous_save), fconv(catbuff2, sizeof(catbuff2), save)); if (fexist_utf8(fconv(catbuff, sizeof(catbuff), save))) { found = 1; hts_log_print(opt, LOG_DEBUG, "File '%s' has been renamed since last mirror to '%s' ; applying changes", previous_save, save); } else { hts_log_print(opt, LOG_ERROR, "Could not rename '%s' to '%s' ; will have to retransfer it", previous_save, save); } } } back[p].location_buffer[0] = '\0'; } /* Not found ? */ if (!found) { #if HTS_FAST_CACHE hash_pos_return = 0; #else a = NULL; #endif // dévalider car non présent sur disque dans structure originale!!! // sinon, le fichier est ok à priori, mais on renverra un if-modified-since pour // en être sûr if (opt->norecatch) { // tester norecatch if (!fexist_utf8(fconv(catbuff, sizeof(catbuff), save))) { // fichier existe pas mais déclaré: on l'a effacé FILE *fp = FOPEN(fconv(catbuff, sizeof(catbuff), save), "wb"); if (fp) fclose(fp); hts_log_print(opt, LOG_WARNING, "Previous file '%s' not found (erased by user ?), ignoring: %s%s", save, back[p].url_adr, back[p].url_fil); } } else { hts_log_print(opt, LOG_WARNING, "Previous file '%s' not found (erased by user ?), recatching: %s%s", save, back[p].url_adr, back[p].url_fil); } } } // fsize() <= 0 #if HTS_FAST_CACHE==0 } #endif } } // } else { #if HTS_FAST_CACHE hash_pos_return = 0; #else a = NULL; #endif } // Existe pas en cache, ou bien pas de cache présent #if HTS_FAST_CACHE if (hash_pos_return) { // OK existe en cache (et données aussi)! #else if (a != NULL) { // OK existe en cache (et données aussi)! #endif const int cache_is_prioritary = cache->type == 1 || opt->state.stop != 0; if (cache_is_prioritary) { // cache prioritaire (pas de test if-modified..) // dans ce cas on peut également lire des réponses cachées comme 404,302... // lire dans le cache if (!test) back[p].r = cache_read(opt, cache, adr, fil, save, back[p].location_buffer); else back[p].r = cache_read(opt, cache, adr, fil, NULL, back[p].location_buffer); // charger en tête uniquement du cache /* ensure correct location buffer set */ back[p].r.location = back[p].location_buffer; /* Interdiction taille par le wizard? --> détruire */ if (back[p].r.statuscode != -1) { // pas d'erreur de lecture if (!back_checksize(opt, &back[p], 0)) { back[p].status = STATUS_READY; // FINI back_set_finished(sback, p); back[p].r.statuscode = STATUSCODE_TOO_BIG; if (!back[p].testmode) strcpybuff(back[p].r.msg, "Cached file skipped (too big)"); else strcpybuff(back[p].r.msg, "Test: Cached file skipped (too big)"); return 0; } } if (back[p].r.statuscode != -1 || IS_DELAYED_EXT(save)) { // pas d'erreur de lecture ou test retardé if (!test) { hts_log_print(opt, LOG_DEBUG, "File immediately loaded from cache: %s%s", back[p].url_adr, back[p].url_fil); } else { hts_log_print(opt, LOG_DEBUG, "File immediately tested from cache: %s%s", back[p].url_adr, back[p].url_fil); } back[p].r.notmodified = 1; // fichier non modifié back[p].status = STATUS_READY; // OK prêt //file_notify(back[p].url_adr, back[p].url_fil, back[p].url_sav, 0, 0, back[p].r.notmodified); // not modified back_set_finished(sback, p); // finalize transfer if (!test) { if (back[p].r.statuscode > 0) { hts_log_print(opt, LOG_TRACE, "finalizing in back_add"); back_finalize(opt, cache, sback, p); } } return 0; } else { // erreur // effacer r hts_init_htsblk(&back[p].r); //memset(&(back[p].r), 0, sizeof(htsblk)); back[p].r.location = back[p].location_buffer; // et continuer (chercher le fichier) } } else if (cache->type == 2) { // si en cache, demander de tester If-Modified-Since htsblk r; cache_header(opt, cache, adr, fil, &r); /* Interdiction taille par le wizard? */ { LLint save_totalsize = back[p].r.totalsize; back[p].r.totalsize = r.totalsize; if (!back_checksize(opt, &back[p], 1)) { r.statuscode = STATUSCODE_INVALID; // back[p].status = STATUS_READY; // FINI back_set_finished(sback, p); back[p].r.statuscode = STATUSCODE_TOO_BIG; deletehttp(&back[p].r); back[p].r.soc = INVALID_SOCKET; if (!back[p].testmode) strcpybuff(back[p].r.msg, "File too big"); else strcpybuff(back[p].r.msg, "Test: File too big"); return 0; } back[p].r.totalsize = save_totalsize; } if (r.statuscode != -1) { if (r.statuscode == HTTP_OK) { // uniquement des 200 (OK) if (strnotempty(r.etag)) { // ETag (RFC2616) /* - If both an entity tag and a Last-Modified value have been provided by the origin server, SHOULD use both validators in cache-conditional requests. This allows both HTTP/1.0 and HTTP/1.1 caches to respond appropriately. */ if (strnotempty(r.lastmodified)) sprintf(back[p].send_too, "If-None-Match: %s\r\nIf-Modified-Since: %s\r\n", r.etag, r.lastmodified); else sprintf(back[p].send_too, "If-None-Match: %s\r\n", r.etag); } else if (strnotempty(r.lastmodified)) sprintf(back[p].send_too, "If-Modified-Since: %s\r\n", r.lastmodified); else if (strnotempty(cache->lastmodified)) sprintf(back[p].send_too, "If-Modified-Since: %s\r\n", cache->lastmodified); /* this is an update of a file */ if (strnotempty(back[p].send_too)) back[p].is_update = 1; back[p].r.req.nocompression = 1; /* Do not compress when updating! */ } } #if DEBUGCA printf("..is modified test %s\n", back[p].send_too); #endif } } /* Not in cache ; maybe in temporary cache ? Warning: non-movable "url_sav" */ else if (back_unserialize_ref(opt, adr, fil, &itemback) == 0) { const off_t file_size = fsize_utf8(itemback->url_sav); /* Found file on disk */ if (file_size > 0) { char *send_too = back[p].send_too; sprintf(send_too, "Range: bytes=" LLintP "-\r\n", (LLint) file_size); send_too += strlen(send_too); /* add etag information */ if (strnotempty(itemback->r.etag)) { sprintf(send_too, "If-Match: %s\r\n", itemback->r.etag); send_too += strlen(send_too); } /* add date information */ if (strnotempty(itemback->r.lastmodified)) { sprintf(send_too, "If-Unmodified-Since: %s\r\n", itemback->r.lastmodified); send_too += strlen(send_too); } back[p].http11 = 1; /* 1.1 */ back[p].range_req_size = (LLint) file_size; back[p].r.req.range_used = 1; back[p].is_update = 1; /* this is an update of a file */ back[p].r.req.nocompression = 1; /* Do not compress when updating! */ } else { /* broken ; remove */ url_savename_refname_remove(opt, adr, fil); } /* cleanup */ back_clear_entry(itemback); /* delete entry content */ freet(itemback); /* delete item */ itemback = NULL; } /* Not in cache or temporary cache ; found on disk ? (hack) */ else if (fexist_utf8(save)) { const off_t sz = fsize_utf8(save); // Bon, là il est possible que le fichier ait été partiellement transféré // (s'il l'avait été en totalité il aurait été inscrit dans le cache ET existerait sur disque) // PAS de If-Modified-Since, on a pas connaissance des données à la date du cache // On demande juste les données restantes si le date est valide (206), tout sinon (200) if ((ishtml(opt, save) != 1) && (ishtml(opt, back[p].url_fil) != 1)) { // NON HTML (liens changés!!) if (sz > 0) { // Fichier non vide? (question bête, sinon on transfert tout!) char lastmodified[256]; get_filetime_rfc822(save, lastmodified); if (strnotempty(lastmodified)) { /* pas de If-.. possible */ #if DEBUGCA printf("..if unmodified since %s size " LLintP "\n", lastmodified, (LLint) sz); #endif hts_log_print(opt, LOG_DEBUG, "File partially present (" LLintP " bytes): %s%s", (LLint) sz, back[p].url_adr, back[p].url_fil); /* impossible - don't have etag or date if (strnotempty(back[p].r.etag)) { // ETag (RFC2616) sprintf(back[p].send_too,"If-None-Match: %s\r\n",back[p].r.etag); back[p].http11=1; // En tête 1.1 } else if (strnotempty(back[p].r.lastmodified)) { sprintf(back[p].send_too,"If-Unmodified-Since: %s\r\n",back[p].r.lastmodified); back[p].http11=1; // En tête 1.1 } else */ if (strlen(lastmodified)) { sprintf(back[p].send_too, "If-Unmodified-Since: %s\r\nRange: bytes=" LLintP "-\r\n", lastmodified, (LLint) sz); back[p].http11 = 1; // En tête 1.1 back[p].is_update = 1; /* this is an update of a file */ back[p].range_req_size = sz; back[p].r.req.range_used = 1; back[p].r.req.nocompression = 1; } else { hts_log_print(opt, LOG_WARNING, "Could not find timestamp for partially present file, restarting (lost " LLintP " bytes): %s%s", (LLint) sz, back[p].url_adr, back[p].url_fil); } } else { hts_log_print(opt, LOG_NOTICE, "File partially present (" LLintP " bytes) retransferred due to lack of cache: %s%s", (LLint) sz, back[p].url_adr, back[p].url_fil); /* Sinon requête normale... */ back[p].http11 = 0; } } else if (opt->norecatch) { // tester norecatch filenote(&opt->state.strc, save, NULL); // ne pas purger tout de même file_notify(opt, back[p].url_adr, back[p].url_fil, back[p].url_sav, 0, 0, back[p].r.notmodified); back[p].status = STATUS_READY; // OK prêt back_set_finished(sback, p); back[p].r.statuscode = STATUSCODE_INVALID; // erreur strcpybuff(back[p].r.msg, "Null-size file not recaught"); return 0; } } else { hts_log_print(opt, LOG_NOTICE, "HTML file (" LLintP " bytes) retransferred due to lack of cache: %s%s", (LLint) sz, back[p].url_adr, back[p].url_fil); /* Sinon requête normale... */ back[p].http11 = 0; } } } /* Stop requested - abort backing */ if (opt->state.stop) { back[p].r.statuscode = STATUSCODE_INVALID; // fatal strcpybuff(back[p].r.msg, "mirror stopped by user"); back[p].status = STATUS_READY; // terminé back_set_finished(sback, p); hts_log_print(opt, LOG_WARNING, "File not added due to mirror cancel: %s%s", adr, fil); return 0; } { ///htsblk r; non directement dans la structure-réponse! T_SOC soc; // ouvrir liaison, envoyer requète // ne pas traiter ou recevoir l'en tête immédiatement hts_init_htsblk(&back[p].r); //memset(&(back[p].r), 0, sizeof(htsblk)); back[p].r.location = back[p].location_buffer; // recopier proxy if ((back[p].r.req.proxy.active = opt->proxy.active)) { if (StringBuff(opt->proxy.bindhost) != NULL) back[p].r.req.proxy.bindhost = StringBuff(opt->proxy.bindhost); if (StringBuff(opt->proxy.name) != NULL) back[p].r.req.proxy.name = StringBuff(opt->proxy.name); back[p].r.req.proxy.port = opt->proxy.port; } // et user-agent back[p].r.req.user_agent = StringBuff(opt->user_agent); back[p].r.req.referer = StringBuff(opt->referer); back[p].r.req.from = StringBuff(opt->from); back[p].r.req.lang_iso = StringBuff(opt->lang_iso); back[p].r.req.accept = StringBuff(opt->accept); back[p].r.req.headers = StringBuff(opt->headers); back[p].r.req.user_agent_send = opt->user_agent_send; // et http11 back[p].r.req.http11 = back[p].http11; back[p].r.req.nocompression = opt->nocompression; back[p].r.req.nokeepalive = opt->nokeepalive; // mode ftp, court-circuit! if (strfield(back[p].url_adr, "ftp://")) { if (back[p].testmode) { hts_log_print(opt, LOG_DEBUG, "error: forbidden test with ftp link for back_add"); return -1; // erreur pas de test permis } if (!(back[p].r.req.proxy.active && opt->ftp_proxy)) { // connexion directe, gérée en thread FTPDownloadStruct *str = (FTPDownloadStruct *) malloc(sizeof(FTPDownloadStruct)); str->pBack = &back[p]; str->pOpt = opt; /* */ back[p].status = STATUS_FTP_TRANSFER; // connexion ftp #if USE_BEGINTHREAD launch_ftp(str); #else #error Must have pthreads #endif return 0; } } #if HTS_USEOPENSSL else if (strfield(back[p].url_adr, "https://")) { // let's rock back[p].r.ssl = 1; // back[p].r.ssl_soc = NULL; back[p].r.ssl_con = NULL; } #endif if (!back_trylive(opt, cache, sback, p)) { #if HTS_XGETHOST #if HDEBUG printf("back_solve..\n"); #endif back[p].status = STATUS_WAIT_DNS; // tentative de résolution du nom de host soc = INVALID_SOCKET; // pas encore ouverte back_solve(opt, &back[p]); // préparer if (host_wait(opt, &back[p])) { // prêt, par ex fichier ou dispo dans dns #if HDEBUG printf("ok, dns cache ready..\n"); #endif soc = http_xfopen(opt, 0, 0, 0, back[p].send_too, adr, fil, &back[p].r); if (soc == INVALID_SOCKET) { back[p].status = STATUS_READY; // fini, erreur back_set_finished(sback, p); } } // #else // #if CNXDEBUG printf("XFopen..\n"); #endif if (strnotempty(back[p].send_too)) // envoyer un if-modified-since #if HTS_XCONN soc = http_xfopen(0, 0, 0, back[p].send_too, adr, fil, &(back[p].r)); #else soc = http_xfopen(0, 0, 1, back[p].send_too, adr, fil, &(back[p].r)); #endif else #if HTS_XCONN soc = http_xfopen(test, 0, 0, NULL, adr, fil, &(back[p].r)); #else soc = http_xfopen(test, 0, 1, NULL, adr, fil, &(back[p].r)); #endif #endif } else { soc = back[p].r.soc; hts_log_print(opt, LOG_DEBUG, "(Keep-Alive): successfully linked #%d (for %s%s)", back[p].r.debugid, back[p].url_adr, back[p].url_fil); } if (opt->timeout > 0) { // gestion du opt->timeout back[p].timeout = opt->timeout; back[p].timeout_refresh = time_local(); } else { back[p].timeout = -1; // pas de gestion (default) } if (opt->rateout > 0) { // gestion d'un taux minimum de transfert toléré back[p].rateout = opt->rateout; back[p].rateout_time = time_local(); } else { back[p].rateout = -1; // pas de gestion (default) } // Note: on charge les code-page erreurs (erreur 404, etc) dans le cas où cela est // rattrapable (exemple: 301,302 moved xxx -> refresh sur la page!) //if ((back[p].statuscode!=HTTP_OK) || (soc<0)) { // ERREUR HTTP/autre #if CNXDEBUG printf("Xfopen ok, poll..\n"); #endif #if HTS_XGETHOST if (soc != INVALID_SOCKET) if (back[p].status == STATUS_WAIT_DNS) { // pas d'erreur if (!back[p].r.is_file) back[p].status = STATUS_CONNECTING; // connexion en cours else back[p].status = 1; // fichier } #else if (soc == INVALID_SOCKET) { // erreur socket back[p].status = STATUS_READY; // FINI back_set_finished(sback, p); //if (back[p].soc!=INVALID_SOCKET) deletehttp(back[p].soc); back[p].r.soc = INVALID_SOCKET; } else { if (!back[p].r.is_file) #if HTS_XCONN back[p].status = STATUS_CONNECTING; // connexion en cours #else back[p].status = STATUS_WAIT_HEADERS; // chargement en tête en cours #endif else back[p].status = 1; // chargement fichier #if BDEBUG==1 printf("..loading header\n"); #endif } #endif } // note: si il y a erreur (404,etc) status=2 (terminé/échec) mais // le lien est considéré comme traité //if (back[p].soc<0) // erreur // return -1; return 0; } else { if (opt->log != NULL) { hts_log_print(opt, LOG_WARNING, "error: no space left in stack for back_add"); if ((opt->state.debug_state & 1) == 0) { /* debug_state<0> == debug 'no space left in stack' */ int i; hts_log_print(opt, LOG_WARNING, "debug: DUMPING %d BLOCKS", back_max); opt->state.debug_state |= 1; /* once */ /* OUTPUT FULL DEBUG INFORMATION THE FIRST TIME WE SEE THIS VERY ANNOYING BUG, HOPING THAT SOME USER REPORT WILL QUICKLY SOLVE THIS PROBLEM :p */ for(i = 0; i < back_max; i++) { if (back[i].status != -1) { int may_clean = slot_can_be_cleaned(&back[i]); int may_finalize = may_clean && slot_can_be_finalized(opt, &back[i]); int may_serialize = slot_can_be_cached_on_disk(&back[i]); hts_log_print(opt, LOG_DEBUG, "back[%03d]: may_clean=%d, may_finalize_disk=%d, may_serialize=%d:" LF "\t" "finalized(%d), status(%d), locked(%d), delayed(%d), test(%d), " LF "\t" "statuscode(%d), size(%d), is_write(%d), may_hypertext(%d), " LF "\t" "contenttype(%s), url(%s%s), save(%s)", i, may_clean, may_finalize, may_serialize, back[i].finalized, back[i].status, back[i].locked, IS_DELAYED_EXT(back[i].url_sav), back[i].testmode, back[i].r.statuscode, (int) back[i].r.size, back[i].r.is_write, may_be_hypertext_mime(opt, back[i].r. contenttype, back[i]. url_fil), /* */ back[i].r.contenttype, back[i].url_adr, back[i].url_fil, back[i].url_sav ? back[i].url_sav : ""); } } } } return -1; // plus de place } } #if HTS_XGETHOST // attendre que le host (ou celui du proxy) ait été résolu // si c'est un fichier, la résolution est immédiate // idem pour ftp:// void back_solve(httrackp * opt, lien_back * back) { assertf(opt != NULL); assertf(back != NULL); if ((!strfield(back->url_adr, "file://")) && !strfield(back->url_adr, "ftp://") ) { const char *a; if (!(back->r.req.proxy.active)) a = back->url_adr; else a = back->r.req.proxy.name; assertf(a != NULL); a = jump_protocol_const(a); if (check_hostname_dns(a)) { hts_log_print(opt, LOG_DEBUG, "resolved: %s", a); } else { hts_log_print(opt, LOG_DEBUG, "failed to resolve: %s", a); } //if (hts_dnstest(opt, a, 1) == 2) { // non encore testé!.. // hts_log_print(opt, LOG_DEBUG, "resolving in background: %s", a); //} } } // détermine si le host a pu être résolu int host_wait(httrackp * opt, lien_back * back) { // Always synchronous. No more background DNS resolution // (does not really improve performances) return 1; } #endif // élimine les fichiers non html en backing (anticipation) // cleanup non-html files in backing to save backing space // and allow faster "save in cache" operation // also cleanup keep-alive sockets and ensure that not too many sockets are being opened static int slot_can_be_cleaned(const lien_back * back) { return (back->status == STATUS_READY) // ready /* Check autoclean */ && (!back->testmode) // not test mode && (strnotempty(back->url_sav)) // filename exists && (HTTP_IS_OK(back->r.statuscode)) // HTTP "OK" && (back->r.size >= 0) // size>=0 ; } static int slot_can_be_finalized(httrackp * opt, const lien_back * back) { return back->r.is_write // not in memory (on disk, ready) && !is_hypertext_mime(opt, back->r.contenttype, back->url_fil) // not HTML/hypertext && !may_be_hypertext_mime(opt, back->r.contenttype, back->url_fil) // may NOT be parseable mime type /* Has not been added before the heap saw the link, or now exists on heap */ && (!back->early_add || hash_read(opt->hash, back->url_sav, NULL, HASH_STRUCT_FILENAME) >= 0); } void back_clean(httrackp * opt, cache_back * cache, struct_back * sback) { lien_back *const back = sback->lnk; const int back_max = sback->count; int oneMore = ((opt->state._hts_in_html_parsing == 2 && opt->maxsoc >= 2) || (opt->state._hts_in_html_parsing == 1 && opt->maxsoc >= 4)) ? 1 : 0; // testing links int i; for(i = 0; i < back_max; i++) { if (slot_can_be_cleaned(&back[i])) { if (slot_can_be_finalized(opt, &back[i])) { (void) back_flush_output(opt, cache, sback, i); // flush output buffers usercommand(opt, 0, NULL, back[i].url_sav, back[i].url_adr, back[i].url_fil); //if (back[i].links_index >= 0) { // assertf(back[i].links_index < opt->hash->max_lien); // opt->hash->liens[back[i].links_index]->pass2 = -1; // // *back[i].pass2_ptr=-1; // Done! //} /* MANDATORY if we don't want back_fill() to endlessly put the same file on download! */ { int index = hash_read(opt->hash, back[i].url_sav, NULL, HASH_STRUCT_FILENAME ); // lecture type 0 (sav) if (index >= 0) { opt->liens[index]->pass2 = -1; /* DONE! */ } else { hts_log_print(opt, LOG_INFO, "engine: warning: entry cleaned up, but no trace on heap: %s%s (%s)", back[i].url_adr, back[i].url_fil, back[i].url_sav); } } HTS_STAT.stat_background++; hts_log_print(opt, LOG_INFO, "File successfully written in background: %s", back[i].url_sav); back_maydelete(opt, cache, sback, i); // May delete backing entry } else { if (!back[i].finalized) { if (1) { /* Ensure deleted or recycled socket */ /* BUT DO NOT YET WIPE back[i].r.adr */ hts_log_print(opt, LOG_DEBUG, "file %s%s validated (cached, left in memory)", back[i].url_adr, back[i].url_fil); back_maydeletehttp(opt, cache, sback, i); } else { /* NOT YET HANDLED CORRECTLY (READ IN NEW CACHE TO DO) */ /* Lock the entry but do not keep the html data in memory (in cache) */ if (opt->cache) { htsblk r; /* Ensure deleted or recycled socket */ back_maydeletehttp(opt, cache, sback, i); assertf(back[i].r.soc == INVALID_SOCKET); /* Check header */ cache_header(opt, cache, back[i].url_adr, back[i].url_fil, &r); if (r.statuscode == HTTP_OK) { if (back[i].r.soc == INVALID_SOCKET) { /* Delete buffer and sockets */ deleteaddr(&back[i].r); deletehttp(&back[i].r); hts_log_print(opt, LOG_DEBUG, "file %s%s temporarily left in cache to spare memory", back[i].url_adr, back[i].url_fil); } } else { hts_log_print(opt, LOG_WARNING, "Unexpected html cache lookup error during back clean"); } // xxc xxc } } } } } else if (back[i].status == STATUS_ALIVE) { // waiting (keep-alive) if (!back[i].r.keep_alive || back[i].r.soc == INVALID_SOCKET || back[i].r.keep_alive_max < 1 || time_local() >= back[i].ka_time_start + back[i].r.keep_alive_t) { const char *reason = "unknown"; char buffer[128]; if (!back[i].r.keep_alive) { reason = "not keep-alive"; } else if (back[i].r.soc == INVALID_SOCKET) { reason = "closed"; } else if (back[i].r.keep_alive_max < 1) { reason = "keep-alive-max reached"; } else if (time_local() >= back[i].ka_time_start + back[i].r.keep_alive_t) { assertf(back[i].ka_time_start != 0); snprintf(buffer, sizeof(buffer), "keep-alive timeout = %ds)", (int) back[i].r.keep_alive_t); reason = buffer; } hts_log_print(opt, LOG_DEBUG, "(Keep-Alive): live socket #%d (%s) closed (%s)", back[i].r.debugid, back[i].url_adr, reason); back_delete(opt, cache, sback, i); // delete backing entry } } } /* switch connections to live ones */ for(i = 0; i < back_max; i++) { if (back[i].status == STATUS_READY) { // ready if (back[i].r.soc != INVALID_SOCKET) { back_maydeletehttp(opt, cache, sback, i); } } } /* delete sockets if too many keep-alive'd sockets in background */ if (opt->maxsoc > 0) { int max = opt->maxsoc + oneMore; int curr = back_nsoc_overall(sback); if (curr > max) { hts_log_print(opt, LOG_DEBUG, "(Keep-Alive): deleting #%d sockets", curr - max); } for(i = 0; i < back_max && curr > max; i++) { if (back[i].status == STATUS_ALIVE) { back_delete(opt, cache, sback, i); // delete backing entry curr--; } } } /* transfer ready slots to the storage hashtable */ { int nxfr = back_cleanup_background(opt, cache, sback); if (nxfr > 0) { hts_log_print(opt, LOG_DEBUG, "(htsback): %d slots ready moved to background", nxfr); } } } // attente (gestion des buffers des sockets) void back_wait(struct_back * sback, httrackp * opt, cache_back * cache, TStamp stat_timestart) { char catbuff[CATBUFF_SIZE]; lien_back *const back = sback->lnk; const int back_max = sback->count; unsigned int i_mod; T_SOC nfds = INVALID_SOCKET; fd_set fds, fds_c, fds_e; // fds pour lecture, connect (write), et erreur int nsockets; // nbre sockets LLint max_read_bytes; // max bytes read per sockets struct timeval tv; int do_wait = 0; int gestion_timeout = 0; int busy_recv = 0; // pas de données pour le moment int busy_state = 0; // pas de connexions int max_loop; // nombre de boucles max à parcourir.. int max_loop_chk = 0; unsigned int mod_random = (unsigned int) (time_local() + HTS_STAT.HTS_TOTAL_RECV); // max. number of loops max_loop = 8; #if 1 // Cleanup the stack to save space! back_clean(opt, cache, sback); #endif // recevoir tant qu'il y a des données (avec un maximum de max_loop boucles) do_wait = 0; gestion_timeout = 0; do { int max_c; busy_state = busy_recv = 0; #if 0 check_rate(stat_timestart, opt->maxrate); // vérifier taux de transfert #endif // inscrire les sockets actuelles, et rechercher l'ID la plus élevée FD_ZERO(&fds); FD_ZERO(&fds_c); FD_ZERO(&fds_e); nsockets = 0; max_read_bytes = TAILLE_BUFFER; // maximum bytes that can be read nfds = INVALID_SOCKET; max_c = 1; for(i_mod = 0; i_mod < (unsigned int) back_max; i_mod++) { // for(i=0;i nfds) { // ID socket la plus élevée nfds = back[i].r.soc; } } else #endif #if HTS_XGETHOST if (back[i].status == STATUS_WAIT_DNS) { // attente // rien à faire.. } else #endif // poll pour la lecture sur les sockets if ((back[i].status > 0) && (back[i].status < 100)) { // en réception http #if BDEBUG==1 //printf("....socket in progress: %d\n",back[i].r.soc); #endif // non local et non ftp if (!back[i].r.is_file) { //## if (back[i].url_adr[0]!=lOCAL_CHAR) { // vérification de sécurité if (back[i].r.soc != INVALID_SOCKET) { // hey, you never know.. if ( // Do not endlessly wait when receiving SSL http data (Patrick Pfeifer) #if HTS_USEOPENSSL !back[i].r.ssl && #endif back[i].status > 0 && back[i].status < 1000) { do_wait = 1; // noter socket read FD_SET(back[i].r.soc, &fds); // noter socket error FD_SET(back[i].r.soc, &fds_e); // incrémenter nombre de sockets nsockets++; // calculer max if (max_c) { max_c = 0; nfds = back[i].r.soc; } else if (back[i].r.soc > nfds) { // ID socket la plus élevée nfds = back[i].r.soc; } } } else { back[i].r.statuscode = STATUSCODE_CONNERROR; if (back[i].status == STATUS_CONNECTING) strcpybuff(back[i].r.msg, "Connect Error"); else strcpybuff(back[i].r.msg, "Receive Error"); back[i].status = STATUS_READY; // terminé back_set_finished(sback, i); hts_log_print(opt, LOG_WARNING, "Unexpected socket error during pre-loop"); } } } } nfds++; if (do_wait) { // attendre // temps d'attente max: 2.5 seconde tv.tv_sec = HTS_SOCK_SEC; tv.tv_usec = HTS_SOCK_MS; #if BDEBUG==1 printf("..select\n"); #endif // poller les sockets-attention au noyau sous Unix.. #if HTS_WIDE_DEBUG DEBUG_W("select\n"); #endif select((int) nfds, &fds, &fds_c, &fds_e, &tv); #if HTS_WIDE_DEBUG DEBUG_W("select done\n"); #endif } // maximum data which can be received for a socket, if limited if (nsockets) { if (opt->maxrate > 0) { max_read_bytes = (check_downloadable_bytes(opt->maxrate) / nsockets); if (max_read_bytes > TAILLE_BUFFER) { /* limit size */ max_read_bytes = TAILLE_BUFFER; } else if (max_read_bytes < TAILLE_BUFFER) { /* a small pause */ Sleep(10); } } } if (!max_read_bytes) busy_recv = 0; // recevoir les données arrivées for(i_mod = 0; i_mod < (unsigned int) back_max; i_mod++) { // for(i=0;i 0) { if (!back[i].r.is_file) { // not file.. if (back[i].r.soc != INVALID_SOCKET) { // hey, you never know.. int err = FD_ISSET(back[i].r.soc, &fds_e); if (err) { if (back[i].r.soc != INVALID_SOCKET) { #if HTS_DEBUG_CLOSESOCK DEBUG_W("back_wait: deletehttp\n"); #endif deletehttp(&back[i].r); } back[i].r.soc = INVALID_SOCKET; back[i].r.statuscode = STATUSCODE_CONNERROR; if (back[i].status == STATUS_CONNECTING) strcpybuff(back[i].r.msg, "Connect Error"); else strcpybuff(back[i].r.msg, "Receive Error"); if (back[i].status == STATUS_ALIVE) { /* Keep-alive socket */ back_delete(opt, cache, sback, i); } else { back[i].status = STATUS_READY; // terminé back_set_finished(sback, i); } } } } } // ---- FLAG WRITE MIS A UN?: POUR LE CONNECT if (back[i].status == STATUS_CONNECTING) { // attendre connect int dispo = 0; // vérifier l'existance de timeout-check if (!gestion_timeout) if (back[i].timeout > 0) gestion_timeout = 1; // connecté? dispo = FD_ISSET(back[i].r.soc, &fds_c); if (dispo) { // ok connected!! busy_state = 1; #if HTS_USEOPENSSL /* SSL mode */ if (back[i].r.ssl) { // handshake not yet launched if (!back[i].r.ssl_con) { SSL_CTX_set_options(openssl_ctx, SSL_OP_ALL); // new session back[i].r.ssl_con = SSL_new(openssl_ctx); if (back[i].r.ssl_con) { const char* hostname = jump_protocol_const(back[i].url_adr); // some servers expect the hostname on the clienthello (SNI TLS extension) SSL_set_tlsext_host_name(back[i].r.ssl_con, hostname); SSL_clear(back[i].r.ssl_con); if (SSL_set_fd(back[i].r.ssl_con, (int) back[i].r.soc) == 1) { SSL_set_connect_state(back[i].r.ssl_con); back[i].status = STATUS_SSL_WAIT_HANDSHAKE; /* handshake wait */ } else back[i].r.statuscode = STATUSCODE_SSL_HANDSHAKE; } else back[i].r.statuscode = STATUSCODE_SSL_HANDSHAKE; } /* Error */ if (back[i].r.statuscode == STATUSCODE_SSL_HANDSHAKE) { strcpybuff(back[i].r.msg, "bad SSL/TLS handshake"); deletehttp(&back[i].r); back[i].r.soc = INVALID_SOCKET; back[i].r.statuscode = STATUSCODE_NON_FATAL; back[i].status = STATUS_READY; back_set_finished(sback, i); } } #endif #if BDEBUG==1 printf("..connect ok on socket %d\n", back[i].r.soc); #endif if ((back[i].r.soc != INVALID_SOCKET) && (back[i].status == STATUS_CONNECTING)) { /* limit nb. connections/seconds to avoid server overload */ /*if (opt->maxconn>0) { Sleep(1000/opt->maxconn); } */ back[i].ka_time_start = time_local(); if (back[i].timeout > 0) { // refresh timeout si besoin est back[i].timeout_refresh = back[i].ka_time_start; } if (back[i].rateout > 0) { // le taux de transfert de base sur le début de la connexion back[i].rateout_time = back[i].ka_time_start; } // envoyer header //if (strcmp(back[i].url_sav,BACK_ADD_TEST)!=0) // vrai get HTS_STAT.stat_nrequests++; if (!back[i].head_request) http_sendhead(opt, opt->cookie, 0, back[i].send_too, back[i].url_adr, back[i].url_fil, back[i].referer_adr, back[i].referer_fil, &back[i].r); else if (back[i].head_request == 2) // test en GET! http_sendhead(opt, opt->cookie, 0, back[i].send_too, back[i].url_adr, back[i].url_fil, back[i].referer_adr, back[i].referer_fil, &back[i].r); else // test! http_sendhead(opt, opt->cookie, 1, back[i].send_too, back[i].url_adr, back[i].url_fil, back[i].referer_adr, back[i].referer_fil, &back[i].r); back[i].status = STATUS_WAIT_HEADERS; // attendre en tête maintenant } } // attente gethostbyname } #if HTS_USEOPENSSL else if (back[i].status == STATUS_SSL_WAIT_HANDSHAKE) { // wait for SSL handshake /* SSL mode */ if (back[i].r.ssl) { int conn_code; if ((conn_code = SSL_connect(back[i].r.ssl_con)) <= 0) { /* non blocking I/O, will retry */ int err_code = SSL_get_error(back[i].r.ssl_con, conn_code); if ((err_code != SSL_ERROR_WANT_READ) && (err_code != SSL_ERROR_WANT_WRITE) ) { char tmp[256]; tmp[0] = '\0'; ERR_error_string(err_code, tmp); back[i].r.msg[0] = '\0'; strncatbuff(back[i].r.msg, tmp, sizeof(back[i].r.msg) - 2); if (!strnotempty(back[i].r.msg)) { sprintf(back[i].r.msg, "SSL/TLS error %d", err_code); } deletehttp(&back[i].r); back[i].r.soc = INVALID_SOCKET; back[i].r.statuscode = STATUSCODE_NON_FATAL; back[i].status = STATUS_READY; back_set_finished(sback, i); } } else { /* got it! */ back[i].status = STATUS_CONNECTING; // back to waitconnect } } else { strcpybuff(back[i].r.msg, "unexpected SSL/TLS error"); deletehttp(&back[i].r); back[i].r.soc = INVALID_SOCKET; back[i].r.statuscode = STATUSCODE_NON_FATAL; back[i].status = STATUS_READY; back_set_finished(sback, i); } } #endif #if HTS_XGETHOST else if (back[i].status == STATUS_WAIT_DNS) { // attendre gethostbyname #if DEBUGDNS //printf("status 101 for %s\n",back[i].url_adr); #endif if (!gestion_timeout) if (back[i].timeout > 0) gestion_timeout = 1; if (host_wait(opt, &back[i])) { // prêt back[i].status = STATUS_CONNECTING; // attente connexion if (back[i].timeout > 0) { // refresh timeout si besoin est back[i].timeout_refresh = time_local(); } if (back[i].rateout > 0) { // le taux de transfert de base sur le début de la connexion back[i].rateout_time = time_local(); } back[i].r.soc = http_xfopen(opt, 0, 0, 0, back[i].send_too, back[i].url_adr, back[i].url_fil, &(back[i].r)); if (back[i].r.soc == INVALID_SOCKET) { back[i].status = STATUS_READY; // fini, erreur back_set_finished(sback, i); if (back[i].r.soc != INVALID_SOCKET) { #if HTS_DEBUG_CLOSESOCK DEBUG_W("back_wait(2): deletehttp\n"); #endif deletehttp(&back[i].r); } back[i].r.soc = INVALID_SOCKET; back[i].r.statuscode = STATUSCODE_NON_FATAL; if (strnotempty(back[i].r.msg) == 0) strcpybuff(back[i].r.msg, "Unable to resolve host name"); } } // ---- FLAG READ MIS A UN?: POUR LA RECEPTION } #endif #if USE_BEGINTHREAD // ..rien à faire, c'est magic les threads #else else if (back[i].status == STATUS_FTP_TRANSFER) { // en réception ftp if (!fexist(back[i].location_buffer)) { // terminé FILE *fp; fp = FOPEN(fconcat(OPT_GET_BUFF(opt), back[i].location_buffer, ".ok"), "rb"); if (fp) { int j = 0; fscanf(fp, "%d ", &(back[i].r.statuscode)); while(!feof(fp)) { int c = fgetc(fp); if (c != EOF) back[i].r.msg[j++] = c; } back[i].r.msg[j++] = '\0'; fclose(fp); UNLINK(fconcat(OPT_GET_BUFF(opt), back[i].location_buffer, ".ok")); strcpybuff(fconcat (OPT_GET_BUFF(opt), back[i].location_buffer, ".ok"), ""); } else { strcpybuff(back[i].r.msg, "Unknown ftp result, check if file is ok"); back[i].r.statuscode = STATUSCODE_INVALID; } back[i].status = STATUS_READY; back_set_finished(sback, i); // finalize transfer if (back[i].r.statuscode > 0) { hts_log_print(opt, LOG_TRACE, "finalizing ftp"); back_finalize(opt, cache, sback, i); } } } #endif else if (back[i].status == STATUS_FTP_READY) { // ftp ready back[i].status = STATUS_READY; back_set_finished(sback, i); // finalize transfer if (back[i].r.statuscode > 0) { hts_log_print(opt, LOG_TRACE, "finalizing ftp"); back_finalize(opt, cache, sback, i); } } else if ((back[i].status > 0) && (back[i].status < 1000)) { // en réception http int dispo = 0; // vérifier l'existance de timeout-check if (!gestion_timeout) if (back[i].timeout > 0) gestion_timeout = 1; // données dispo? //## if (back[i].url_adr[0]!=lOCAL_CHAR) if (back[i].r.is_file) dispo = 1; #if HTS_USEOPENSSL else if (back[i].r.ssl) dispo = 1; #endif else dispo = FD_ISSET(back[i].r.soc, &fds); // Check transfer rate! if (!max_read_bytes) dispo = 0; // limit transfer rate if (dispo) { // données dispo LLint retour_fread; busy_recv = 1; // on récupère encore #if BDEBUG==1 printf("..data available on socket %d\n", back[i].r.soc); #endif // range size hack old location #if HTS_DIRECTDISK // Court-circuit: // Peut-on stocker le fichier directement sur disque? // Ahh que ca serait vachement mieux et que ahh que la mémoire vous dit merci! if (back[i].status) { if (back[i].r.is_write == 0) { // mode mémoire if (back[i].r.adr == NULL) { // rien n'a été écrit if (!back[i].testmode) { // pas mode test if (strnotempty(back[i].url_sav)) { if (strcmp(back[i].url_fil, "/robots.txt")) { if (back[i].r.statuscode == HTTP_OK) { // 'OK' if (!is_hypertext_mime(opt, back[i].r.contenttype, back[i].url_fil)) { // pas HTML if (opt->getmode & 2) { // on peut ecrire des non html int fcheck = 0; int last_errno = 0; back[i].r.is_write = 1; // écrire if (back[i].r.compressed && /* .gz are *NOT* depacked!! */ strfield(get_ext(catbuff, sizeof(catbuff), back[i].url_sav), "gz") == 0 && strfield(get_ext(catbuff, sizeof(catbuff), back[i].url_sav), "tgz") == 0 ) { if (create_back_tmpfile(opt, &back[i]) == 0) { assertf(back[i].tmpfile != NULL); /* note: tmpfile is utf-8 */ if ((back[i].r.out = FOPEN(back[i].tmpfile, "wb")) == NULL) { last_errno = errno; } } } else { file_notify(opt, back[i].url_adr, back[i].url_fil, back[i].url_sav, 1, 1, back[i].r.notmodified); back[i].r.compressed = 0; if ((back[i].r.out = filecreate(&opt->state.strc, back[i].url_sav)) == NULL) { last_errno = errno; } } if (back[i].r.out == NULL) { errno = last_errno; if ((fcheck = check_fatal_io_errno())) { hts_log_print(opt, LOG_ERROR, "Mirror aborted: disk full or filesystem problems"); opt->state.exit_xh = -1; /* fatal error */ } } #if HDEBUG printf("direct-disk: %s\n", back[i].url_sav); #endif hts_log_print(opt, LOG_DEBUG, "File received from net to disk: %s%s", back[i].url_adr, back[i].url_fil); if (back[i].r.out == NULL) { hts_log_print(opt, LOG_ERROR | LOG_ERRNO, "Unable to save file %s", back[i].url_sav); if (fcheck) { hts_log_print(opt, LOG_ERROR, "* * Fatal write error, giving up"); } back[i].r.is_write = 0; // erreur, abandonner back[i].status = STATUS_READY; // terminé back_set_finished(sback, i); if (back[i].r.soc != INVALID_SOCKET) { deletehttp(&back[i].r); back[i].r.soc = INVALID_SOCKET; } } else { #ifndef _WIN32 chmod(back[i].url_sav, HTS_ACCESS_FILE); #endif /* create a temporary reference file in case of broken mirror */ if (back[i].r.out != NULL && opt->cache != 0) { if (back_serialize_ref(opt, &back[i]) != 0) { hts_log_print(opt, LOG_WARNING, "Could not create temporary reference file for %s%s", back[i].url_adr, back[i].url_fil); } } } } else { // on coupe tout! hts_log_print(opt, LOG_DEBUG, "File cancelled (non HTML): %s%s", back[i].url_adr, back[i].url_fil); back[i].status = STATUS_READY; // terminé back_set_finished(sback, i); if (!back[i].testmode) back[i].r.statuscode = STATUSCODE_INVALID; // EUHH CANCEL else back[i].r.statuscode = STATUSCODE_TEST_OK; // "TEST OK" if (back[i].r.soc != INVALID_SOCKET) { #if HTS_DEBUG_CLOSESOCK DEBUG_W("back_wait(3): deletehttp\n"); #endif deletehttp(&back[i].r); } back[i].r.soc = INVALID_SOCKET; } } } } } } } } } #endif // réception de données depuis socket ou fichier if (back[i].status) { if (back[i].status == STATUS_WAIT_HEADERS) // recevoir par bloc de lignes retour_fread = http_xfread1(&(back[i].r), 0); else if (back[i].status == STATUS_CHUNK_WAIT || back[i].status == STATUS_CHUNK_CR) { // recevoir longueur chunk en hexa caractère par caractère // backuper pour lire dans le buffer chunk htsblk r; memcpy(&r, &(back[i].r), sizeof(htsblk)); back[i].r.is_write = 0; // mémoire back[i].r.adr = back[i].chunk_adr; // adresse back[i].r.size = back[i].chunk_size; // taille taille chunk back[i].r.totalsize = -1; // total inconnu back[i].r.out = NULL; back[i].r.is_file = 0; // // ligne par ligne retour_fread = http_xfread1(&(back[i].r), -1); // modifier et restaurer back[i].chunk_adr = back[i].r.adr; // adresse back[i].chunk_size = back[i].r.size; // taille taille chunk memcpy(&(back[i].r), &r, sizeof(htsblk)); // restaurer véritable r } else if (back[i].is_chunk) { // attention chunk, limiter taille à lire #if CHUNKDEBUG==1 printf("[%d] read %d bytes\n", (int) back[i].r.soc, (int) min(back[i].r.totalsize - back[i].r.size, max_read_bytes)); #endif retour_fread = (int) http_xfread1(&(back[i].r), (int) min(back[i].r.totalsize - back[i].r.size, max_read_bytes)); } else retour_fread = (int) http_xfread1(&(back[i].r), (int) max_read_bytes); } else retour_fread = READ_EOF; // interruption ou annulation interne (peut ne pas être une erreur) // Si réception chunk, tester si on est pas à la fin! if (back[i].status == 1) { if (back[i].is_chunk) { // attendre prochain chunk if (back[i].r.size == back[i].r.totalsize) { // fin chunk! //printf("chunk end at %d\n",back[i].r.size); back[i].status = STATUS_CHUNK_CR; /* fetch ending CRLF */ if (back[i].chunk_adr != NULL) { freet(back[i].chunk_adr); back[i].chunk_adr = NULL; } back[i].chunk_size = 0; retour_fread = 0; // pas d'erreur #if CHUNKDEBUG==1 printf("[%d] waiting for current chunk CRLF..\n", (int) back[i].r.soc); #endif } } else if (back[i].r.keep_alive) { if (back[i].r.size == back[i].r.totalsize) { // fin! retour_fread = READ_EOF; // end } } } if (retour_fread < 0) { // fin réception back[i].status = STATUS_READY; // terminé back_set_finished(sback, i); /*KA back[i].r.soc=INVALID_SOCKET; */ #if CHUNKDEBUG==1 if (back[i].is_chunk) printf ("[%d] must be the last chunk for %s (connection closed) - %d/%d\n", (int) back[i].r.soc, back[i].url_fil, back[i].r.size, back[i].r.totalsize); #endif if (retour_fread < 0 && retour_fread != READ_EOF) { if (back[i].r.size > 0) strcpybuff(back[i].r.msg, "Interrupted transfer"); else strcpybuff(back[i].r.msg, "No data (connection closed)"); back[i].r.statuscode = STATUSCODE_CONNERROR; } else if ((back[i].r.statuscode <= 0) && (strnotempty(back[i].r.msg) == 0)) { #if HDEBUG printf("error interruped: %s\n", back[i].r.adr); #endif if (back[i].r.size > 0) strcpybuff(back[i].r.msg, "Interrupted transfer"); else strcpybuff(back[i].r.msg, "No data (connection closed)"); back[i].r.statuscode = STATUSCODE_CONNERROR; } // Close socket if (back[i].r.soc != INVALID_SOCKET) { #if HTS_DEBUG_CLOSESOCK DEBUG_W("back_wait(4): deletehttp\n"); #endif /*KA deletehttp(&back[i].r); */ back_maydeletehttp(opt, cache, sback, i); } // finalize transfer if (back[i].r.statuscode > 0 && !IS_DELAYED_EXT(back[i].url_sav) ) { hts_log_print(opt, LOG_TRACE, "finalizing regular file"); back_finalize(opt, cache, sback, i); } if (back[i].r.totalsize >= 0) { // tester totalsize //if ((back[i].r.totalsize>=0) && (back[i].status==STATUS_WAIT_HEADERS)) { // tester totalsize if (back[i].r.totalsize != back[i].r.size) { // pas la même! if (!opt->tolerant) { //#if HTS_CL_IS_FATAL deleteaddr(&back[i].r); if (back[i].r.size < back[i].r.totalsize) back[i].r.statuscode = STATUSCODE_CONNERROR; // recatch sprintf(back[i].r.msg, "Incorrect length (" LLintP " Bytes, " LLintP " expected)", (LLint) back[i].r.size, (LLint) back[i].r.totalsize); } else { //#else // Un warning suffira.. hts_log_print(opt, LOG_WARNING, "Incorrect length (" LLintP "!=" LLintP " expected) for %s%s", (LLint) back[i].r.size, (LLint) back[i].r.totalsize, back[i].url_adr, back[i].url_fil); //#endif } } } #if BDEBUG==1 printf("transfer ok\n"); #endif } else if (retour_fread > 0) { // pas d'erreur de réception et data if (back[i].timeout > 0) { // refresh timeout si besoin est back[i].timeout_refresh = time_local(); } // Traitement des en têtes chunks ou en têtes if (back[i].status == STATUS_CHUNK_WAIT || back[i].status == STATUS_CHUNK_CR) { // réception taille chunk en hexa ( après les en têtes, peut ne pas if (back[i].chunk_size > 0 && back[i].chunk_adr[back[i].chunk_size - 1] == 10) { int chunk_size = -1; char chunk_data[64]; if (back[i].chunk_size < 32) { // pas trop gros char *chstrip = back[i].chunk_adr; back[i].chunk_adr[back[i].chunk_size - 1] = '\0'; // octet nul // skip leading spaces or cr while(isspace(*chstrip)) chstrip++; chunk_data[0] = '\0'; strncatbuff(chunk_data, chstrip, sizeof(chunk_data) - 2); // strip chunk-extension while((chstrip = strchr(chunk_data, ';'))) *chstrip = '\0'; while((chstrip = strchr(chunk_data, ' '))) *chstrip = '\0'; while((chstrip = strchr(chunk_data, '\r'))) *chstrip = '\0'; #if CHUNKDEBUG==1 printf("[%d] chunk received and read: %s\n", (int) back[i].r.soc, chunk_data); #endif if (back[i].r.totalsize < 0) back[i].r.totalsize = 0; // initialiser à 0 (-1 == unknown) if (back[i].status == STATUS_CHUNK_WAIT) { // "real" chunk if (sscanf(chunk_data, "%x", &chunk_size) == 1) { if (chunk_size > 0) back[i].chunk_blocksize = chunk_size; /* the data block chunk size */ else back[i].chunk_blocksize = -1; /* ending */ back[i].r.totalsize += chunk_size; // noter taille if (back[i].r.adr != NULL || !back[i].r.is_write) { // Not to disk back[i].r.adr = (char *) realloct(back[i].r.adr, (size_t) back[i].r.totalsize + 1); if (!back[i].r.adr) { if (cache->log != NULL) { hts_log_print(opt, LOG_ERROR, "not enough memory (" LLintP ") for %s%s", (LLint) back[i].r.totalsize, back[i].url_adr, back[i].url_fil); } } } #if CHUNKDEBUG==1 printf("[%d] chunk length: %d - next total " LLintP ":\n", (int) back[i].r.soc, (int) chunk_size, (LLint) back[i].r.totalsize); #endif } else { hts_log_print(opt, LOG_WARNING, "Illegal chunk (%s) for %s%s", back[i].chunk_adr, back[i].url_adr, back[i].url_fil); } } else { /* back[i].status==STATUS_CHUNK_CR : just receiving ending CRLF after data */ if (chunk_data[0] == '\0') { if (back[i].chunk_blocksize > 0) chunk_size = (int) back[i].chunk_blocksize; /* recent data chunk size */ else if (back[i].chunk_blocksize == -1) chunk_size = 0; /* ending chunk */ else chunk_size = 1; /* fake positive size for 1st chunk history */ #if CHUNKDEBUG==1 printf("[%d] chunk CRLF seen\n", (int) back[i].r.soc); #endif } else { hts_log_print(opt, LOG_WARNING, "illegal chunk CRLF (%s) for %s%s", back[i].chunk_adr, back[i].url_adr, back[i].url_fil); #if CHUNKDEBUG==1 printf("[%d] chunk CRLF ERROR!! : '%s'\n", (int) back[i].r.soc, chunk_data); #endif } } } else { hts_log_print(opt, LOG_WARNING, "chunk too big (" LLintP ") for %s%s", (LLint) back[i].chunk_size, back[i].url_adr, back[i].url_fil); } // ok, continuer sur le body // si chunk non nul continuer (ou commencer) if (back[i].status == STATUS_CHUNK_CR && chunk_size > 0) { back[i].status = STATUS_CHUNK_WAIT; /* waiting for next chunk (NN\r\n\r\nNN\r\n..\r\n0\r\n\r\n) */ #if CHUNKDEBUG==1 printf("[%d] waiting for next chunk\n", (int) back[i].r.soc); #endif } else if (back[i].status == STATUS_CHUNK_WAIT && chunk_size == 0) { /* final chunk */ back[i].status = STATUS_CHUNK_CR; /* final CRLF */ #if CHUNKDEBUG==1 printf("[%d] waiting for final CRLF (chunk)\n", (int) back[i].r.soc); #endif } else if (back[i].status == STATUS_CHUNK_WAIT && chunk_size >= 0) { /* will fetch data now */ back[i].status = 1; // continuer body #if CHUNKDEBUG==1 printf("[%d] waiting for body (chunk)\n", (int) back[i].r.soc); #endif } else { /* zero-size-chunk-CRLF (end) or error */ #if CHUNKDEBUG==1 printf("[%d] chunk end, total: %d\n", (int) back[i].r.soc, back[i].r.size); #endif /* End */ //if (back[i].status==STATUS_CHUNK_CR) { back[i].status = STATUS_READY; // fin back_set_finished(sback, i); //} // finalize transfer if not temporary if (!IS_DELAYED_EXT(back[i].url_sav)) { hts_log_print(opt, LOG_TRACE, "finalizing at chunk end"); back_finalize(opt, cache, sback, i); } else { if (back[i].r.statuscode == HTTP_OK) { hts_log_print(opt, LOG_WARNING, "unexpected incomplete type with 200 code at %s%s", back[i].url_adr, back[i].url_fil); } } if (back[i].r.soc != INVALID_SOCKET) { #if HTS_DEBUG_CLOSESOCK DEBUG_W("back_wait(5): deletehttp\n"); #endif /* Error */ if (chunk_size < 0) { deletehttp(&back[i].r); back[i].r.soc = INVALID_SOCKET; deleteaddr(&back[i].r); back[i].r.statuscode = STATUSCODE_INVALID; strcpybuff(back[i].r.msg, "Invalid chunk"); #if CHUNKDEBUG==1 printf("[%d] chunk error\n", (int) back[i].r.soc); #endif } else { /* if chunk_size == 0 */ #if CHUNKDEBUG==1 printf("[%d] all chunks now received\n", (int) back[i].r.soc); #endif /* Tester totalsize en fin de chunk */ if ((back[i].r.totalsize >= 0)) { // tester totalsize if (back[i].r.totalsize != back[i].r.size) { // pas la même! if (!opt->tolerant) { deleteaddr(&back[i].r); back[i].r.statuscode = STATUSCODE_INVALID; strcpybuff(back[i].r.msg, "Incorrect length"); } else { // Un warning suffira.. hts_log_print(opt, LOG_WARNING, "Incorrect length (" LLintP "!=" LLintP " expected) for %s%s", (LLint) back[i].r.size, (LLint) back[i].r.totalsize, back[i].url_adr, back[i].url_fil); } } } /* Oops, trailers! */ if (back[i].r.keep_alive_trailers) { /* fixme (not yet supported) */ } } } } // effacer buffer (chunk en tete) if (back[i].chunk_adr != NULL) { freet(back[i].chunk_adr); back[i].chunk_adr = NULL; back[i].chunk_size = 0; // NO! xxback[i].chunk_blocksize = 0; } } // taille buffer chunk > 1 && LF // } else if (back[i].status == STATUS_WAIT_HEADERS) { // en têtes (avant le chunk si il est présent) // if (back[i].r.size >= 2) { // double LF if (((back[i].r.adr[back[i].r.size - 1] == 10) && (back[i].r.adr[back[i].r.size - 2] == 10)) || (back[i].r.adr[0] == '<') /* bogus server */ ) { char rcvd[2048]; int ptr = 0; int noFreebuff = 0; #if BDEBUG==1 printf("..ok, header received\n"); #endif /* Hack for zero-length headers */ if (back[i].status != 0 && back[i].r.adr[0] != '<') { // ---------------------------------------- // traiter en-tête! // status-line à récupérer ptr += binput(back[i].r.adr + ptr, rcvd, 2000); if (strnotempty(rcvd) == 0) { /* Bogus CRLF, OR recycled connection and trailing chunk CRLF */ ptr += binput(back[i].r.adr + ptr, rcvd, 2000); } // traiter status-line treatfirstline(&back[i].r, rcvd); #if HDEBUG printf("(Buffer) Status-Code=%d\n", back[i].r.statuscode); #endif if (_DEBUG_HEAD) { if (ioinfo) { fprintf(ioinfo, "[%d] response for %s%s:\r\ncode=%d\r\n", back[i].r.debugid, jump_identification_const(back[i].url_adr), back[i].url_fil, back[i].r.statuscode); fprintfio(ioinfo, back[i].r.adr, ">>> "); fprintf(ioinfo, "\r\n"); fflush(ioinfo); } // en-tête } // header // ** !attention! HTTP/0.9 non supporté do { ptr += binput(back[i].r.adr + ptr, rcvd, 2000); #if HDEBUG printf("(buffer)>%s\n", rcvd); #endif /* if (_DEBUG_HEAD) { if (ioinfo) { fprintf(ioinfo,"(buffer)>%s\r\n",rcvd); fflush(ioinfo); } } */ if (strnotempty(rcvd)) treathead(opt->cookie, back[i].url_adr, back[i].url_fil, &back[i].r, rcvd); // traiter // parfois les serveurs buggés renvoient un content-range avec un 200 if (back[i].r.statuscode == HTTP_OK) // 'OK' if (strfield(rcvd, "content-range:")) { // Avec un content-range: relisez les RFC.. // Fake range (the file is complete) if (! (back[i].r.crange_start == 0 && back[i].r.crange_end == back[i].r.crange - 1)) { back[i].r.statuscode = HTTP_PARTIAL_CONTENT; // FORCER A 206 !!!!! } } } while(strnotempty(rcvd)); // ---------------------------------------- } else { // assume text/html, OK treatfirstline(&back[i].r, back[i].r.adr); noFreebuff = 1; } // Callback { int test_head = RUN_CALLBACK6(opt, receivehead, back[i].r.adr, back[i].url_adr, back[i].url_fil, back[i].referer_adr, back[i].referer_fil, &back[i].r); if (test_head != 1) { hts_log_print(opt, LOG_WARNING, "External wrapper aborted transfer, breaking connection: %s%s", back[i].url_adr, back[i].url_fil); back[i].status = STATUS_READY; // FINI back_set_finished(sback, i); deletehttp(&back[i].r); back[i].r.soc = INVALID_SOCKET; strcpybuff(back[i].r.msg, "External wrapper aborted transfer"); back[i].r.statuscode = STATUSCODE_INVALID; } } // Free headers memory now // Actually, save them for informational purpose if (!noFreebuff) { char *block = back[i].r.adr; back[i].r.adr = NULL; deleteaddr(&back[i].r); back[i].r.headers = block; } /* Status code and header-response hacks */ // Check response : 203 == 200 if (back[i].r.statuscode == HTTP_NON_AUTHORITATIVE_INFORMATION) { back[i].r.statuscode = HTTP_OK; // forcer "OK" } else if (back[i].r.statuscode == HTTP_CONTINUE) { back[i].status = STATUS_WAIT_HEADERS; back[i].r.size = 0; back[i].r.totalsize = -1; back[i].chunk_size = 0; back[i].r.statuscode = STATUSCODE_INVALID; back[i].r.msg[0] = '\0'; hts_log_print(opt, LOG_DEBUG, "Status 100 detected for %s%s, continuing headers", back[i].url_adr, back[i].url_fil); continue; } /* Solve "false" 416 problems */ if (back[i].r.statuscode == HTTP_REQUESTED_RANGE_NOT_SATISFIABLE) { // 'Requested Range Not Satisfiable' // Example: // Range: bytes=2830- // -> // Content-Range: bytes */2830 if (back[i].range_req_size == back[i].r.crange) { filenote(&opt->state.strc, back[i].url_sav, NULL); file_notify(opt, back[i].url_adr, back[i].url_fil, back[i].url_sav, 0, 0, back[i].r.notmodified); deletehttp(&back[i].r); back[i].r.soc = INVALID_SOCKET; back[i].status = STATUS_READY; // READY back_set_finished(sback, i); back[i].r.size = back[i].r.totalsize = back[i].range_req_size; back[i].r.statuscode = HTTP_NOT_MODIFIED; // NOT MODIFIED hts_log_print(opt, LOG_DEBUG, "File seems complete (good 416 message), breaking connection: %s%s", back[i].url_adr, back[i].url_fil); } } // transform 406 into 200 ; we'll catch embedded links inside the choice page if (back[i].r.statuscode == 406) { // 'Not Acceptable' back[i].r.statuscode = HTTP_OK; } // 'do not erase already downloaded file' // on an updated file // with an error : consider a 304 error if (!opt->delete_old) { if (HTTP_IS_ERROR(back[i].r.statuscode) && back[i].is_update && !back[i].testmode) { if (back[i].url_sav[0] && fexist_utf8(back[i].url_sav)) { hts_log_print(opt, LOG_DEBUG, "Error ignored %d (%s) because of 'no purge' option for %s%s", back[i].r.statuscode, back[i].r.msg, back[i].url_adr, back[i].url_fil); back[i].r.statuscode = HTTP_NOT_MODIFIED; deletehttp(&back[i].r); back[i].r.soc = INVALID_SOCKET; } } } // Various hacks to limit re-transfers when updating a mirror // Force update if same size detected if (opt->sizehack) { // We already have the file // and ask the remote server for an update // Some servers, especially dynamic pages severs, always // answer that the page has been modified since last visit // And answer with a 200 (OK) response, and the same page // If the size is the same, and the option has been set, we assume // that the file is identical - and therefore let's break the connection if (back[i].is_update) { // mise à jour if (back[i].r.statuscode == HTTP_OK && !back[i].testmode) { // 'OK' htsblk r = cache_read(opt, cache, back[i].url_adr, back[i].url_fil, NULL, NULL); // lire entrée cache if (r.statuscode == HTTP_OK) { // OK pas d'erreur cache LLint len1, len2; len1 = r.totalsize; len2 = back[i].r.totalsize; if (r.size > 0) len1 = r.size; if (len1 >= 0) { if (len1 == len2) { // tailles identiques back[i].r.statuscode = HTTP_NOT_MODIFIED; // forcer NOT MODIFIED deletehttp(&back[i].r); back[i].r.soc = INVALID_SOCKET; hts_log_print(opt, LOG_DEBUG, "File seems complete (same size), breaking connection: %s%s", back[i].url_adr, back[i].url_fil); } } } else { hts_log_print(opt, LOG_WARNING, "File seems complete (same size), but there was a cache read error (%u): %s%s", r.statuscode, back[i].url_adr, back[i].url_fil); } if (r.adr) { freet(r.adr); r.adr = NULL; } } } } // Various hacks to limit re-transfers when updating a mirror // Detect already downloaded file (with another browser, for example) if (opt->sizehack) { if (!back[i].is_update) { // mise à jour if (back[i].r.statuscode == HTTP_OK && !back[i].testmode) { // 'OK' if (!is_hypertext_mime(opt, back[i].r.contenttype, back[i].url_fil)) { // not HTML if (strnotempty(back[i].url_sav)) { // target found int size = fsize_utf8(back[i].url_sav); // target size if (size >= 0) { if (back[i].r.totalsize == size) { // same size! deletehttp(&back[i].r); back[i].r.soc = INVALID_SOCKET; back[i].status = STATUS_READY; // READY back_set_finished(sback, i); back[i].r.size = back[i].r.totalsize; filenote(&opt->state.strc, back[i].url_sav, NULL); file_notify(opt, back[i].url_adr, back[i].url_fil, back[i].url_sav, 0, 0, back[i].r.notmodified); back[i].r.statuscode = HTTP_NOT_MODIFIED; // NOT MODIFIED hts_log_print(opt, LOG_DEBUG, "File seems complete (same size file discovered), breaking connection: %s%s", back[i].url_adr, back[i].url_fil); } } } } } } } // Various hacks to limit re-transfers when updating a mirror // Detect bad range: header if (opt->sizehack) { // We have request for a partial file (with a 'Range: NNN-' header) // and received a complete file notification (200), with 'Content-length: NNN' // it might be possible that we had the complete file // this is the case in *most* cases, so break the connection if (back[i].r.is_write == 0) { // mode mémoire if (back[i].r.adr == NULL) { // rien n'a été écrit if (!back[i].testmode) { // pas mode test if (strnotempty(back[i].url_sav)) { if (strcmp(back[i].url_fil, "/robots.txt")) { if (back[i].r.statuscode == HTTP_OK) { // 'OK' if (!is_hypertext_mime(opt, back[i].r.contenttype, back[i].url_fil)) { // pas HTML if (back[i].r.statuscode == HTTP_OK) { // "OK" if (back[i].range_req_size > 0) { // but Range: requested if (back[i].range_req_size == back[i].r.totalsize) { // And same size #if HTS_DEBUG_CLOSESOCK DEBUG_W ("back_wait(skip_range): deletehttp\n"); #endif deletehttp(&back[i].r); back[i].r.soc = INVALID_SOCKET; back[i].status = STATUS_READY; // READY back_set_finished(sback, i); back[i].r.size = back[i].r.totalsize; filenote(&opt->state.strc, back[i].url_sav, NULL); file_notify(opt, back[i].url_adr, back[i].url_fil, back[i].url_sav, 0, 0, back[i].r.notmodified); back[i].r.statuscode = HTTP_NOT_MODIFIED; // NOT MODIFIED hts_log_print(opt, LOG_DEBUG, "File seems complete (reget failed), breaking connection: %s%s", back[i].url_adr, back[i].url_fil); } } } } } } } } } } } // END - Various hacks to limit re-transfers when updating a mirror /* End of status code and header-response hacks */ /* Interdiction taille par le wizard? */ if (back[i].r.soc != INVALID_SOCKET) { if (!back_checksize(opt, &back[i], 1)) { back[i].status = STATUS_READY; // FINI back_set_finished(sback, i); back[i].r.statuscode = STATUSCODE_TOO_BIG; deletehttp(&back[i].r); back[i].r.soc = INVALID_SOCKET; if (!back[i].testmode) strcpybuff(back[i].r.msg, "File too big"); else strcpybuff(back[i].r.msg, "Test: File too big"); } } /* sinon, continuer */ /* if (back[i].r.soc!=INVALID_SOCKET) { // ok récupérer body? */ // head: terminé if (back[i].head_request) { hts_log_print(opt, LOG_DEBUG, "Tested file: %s%s", back[i].url_adr, back[i].url_fil); #if HTS_DEBUG_CLOSESOCK DEBUG_W("back_wait(head request): deletehttp\n"); #endif // Couper connexion if (!back[i].http11) { /* NO KA */ deletehttp(&back[i].r); back[i].r.soc = INVALID_SOCKET; } back[i].status = STATUS_READY; // terminé back_set_finished(sback, i); } // traiter une éventuelle erreur 304 (cache à jour utilisable) else if (back[i].r.statuscode == HTTP_NOT_MODIFIED) { // document à jour dans le cache // lire dans le cache // ** NOTE: pas de vérif de la taille ici!! #if HTS_DEBUG_CLOSESOCK DEBUG_W("back_wait(file is not modified): deletehttp\n"); #endif /* clear everything but connection: switch, close, and reswitch */ { htsblk tmp; memset(&tmp, 0, sizeof(tmp)); back_connxfr(&back[i].r, &tmp); back[i].r = cache_read(opt, cache, back[i].url_adr, back[i].url_fil, back[i].url_sav, back[i].location_buffer); back[i].r.location = back[i].location_buffer; back_connxfr(&tmp, &back[i].r); } // hack: // In case of 'if-unmodified-since' hack, a 304 status can be sent // then, force 'ok' status if (back[i].r.statuscode == STATUSCODE_INVALID) { if (fexist_utf8(back[i].url_sav)) { back[i].r.statuscode = HTTP_OK; // OK strcpybuff(back[i].r.msg, "OK (cached)"); back[i].r.is_file = 1; back[i].r.totalsize = back[i].r.size = fsize_utf8(back[i].url_sav); get_httptype(opt, back[i].r.contenttype, back[i].url_sav, 1); hts_log_print(opt, LOG_DEBUG, "Not-modified status without cache guessed: %s%s", back[i].url_adr, back[i].url_fil); } } // Status is okay? if (back[i].r.statuscode != -1) { // pas d'erreur de lecture back[i].status = STATUS_READY; // OK prêt back_set_finished(sback, i); back[i].r.notmodified = 1; // NON modifié! hts_log_print(opt, LOG_DEBUG, "File loaded after test from cache: %s%s", back[i].url_adr, back[i].url_fil); // finalize //file_notify(back[i].url_adr, back[i].url_fil, back[i].url_sav, 0, 0, back[i].r.notmodified); // not modified if (back[i].r.statuscode > 0) { hts_log_print(opt, LOG_TRACE, "finalizing after cache load"); back_finalize(opt, cache, sback, i); } #if DEBUGCA printf("..document à jour après requète: %s%s\n", back[i].url_adr, back[i].url_fil); #endif //printf(">%s status %d\n",back[p].r.contenttype,back[p].r.statuscode); } else { // erreur back[i].status = STATUS_READY; // terminé back_set_finished(sback, i); //printf("erreur cache\n"); } /********** NO - must complete the body! ********** */ #if 0 } else if (HTTP_IS_REDIRECT(back[i].r.statuscode) || (back[i].r.statuscode == 412) || (back[i].r.statuscode == 416) ) { // Ne pas prendre le html, erreurs connues et gérées #if HTS_DEBUG_CLOSESOCK DEBUG_W ("back_wait(301,302,303,307,412,416..): deletehttp\n"); #endif // Couper connexion /*KA deletehttp(&back[i].r); back[i].r.soc=INVALID_SOCKET; */ back_maydeletehttp(opt, cache, sback, i); back[i].status = STATUS_READY; // terminé back_set_finished(sback, i); // finalize if (back[i].r.statuscode > 0) { hts_log_print(opt, LOG_TRACE, "finalizing redirect & 4xx"); back_finalize(opt, cache, sback, i); } #endif /********** **************************** ********** */ } else { // il faut aller le chercher // effacer buffer (requète) if (!noFreebuff) { deleteaddr(&back[i].r); back[i].r.size = 0; } // traiter 206 (partial content) // xxc SI CHUNK VERIFIER QUE CA MARCHE?? if (back[i].r.statuscode == 206) { // on nous envoie un morceau (la fin) coz une partie sur disque! off_t sz = fsize_utf8(back[i].url_sav); #if HDEBUG printf("partial content: " LLintP " on disk..\n", (LLint) sz); #endif if (sz >= 0) { if (!is_hypertext_mime(opt, back[i].r.contenttype, back[i].url_sav)) { // pas HTML if (opt->getmode & 2) { // on peut ecrire des non html **sinon ben euhh sera intercepté plus loin, donc rap sur ce qui va sortir** filenote(&opt->state.strc, back[i].url_sav, NULL); // noter fichier comme connu file_notify(opt, back[i].url_adr, back[i].url_fil, back[i].url_sav, 0, 1, back[i].r.notmodified); back[i].r.out = FOPEN(fconv(catbuff, sizeof(catbuff), back[i].url_sav), "ab"); // append if (back[i].r.out && opt->cache != 0) { back[i].r.is_write = 1; // écrire back[i].r.size = sz; // déja écrit back[i].r.statuscode = HTTP_OK; // Forcer 'OK' if (back[i].r.totalsize >= 0) back[i].r.totalsize += sz; // plus en fait fseek(back[i].r.out, 0, SEEK_END); // à la fin /* create a temporary reference file in case of broken mirror */ if (back_serialize_ref(opt, &back[i]) != 0) { hts_log_print(opt, LOG_WARNING, "Could not create temporary reference file for %s%s", back[i].url_adr, back[i].url_fil); } #if HDEBUG printf("continue interrupted file\n"); #endif } else { // On est dans la m** back[i].status = STATUS_READY; // terminé (voir plus loin) back_set_finished(sback, i); strcpybuff(back[i].r.msg, "Can not open partial file"); } } } else { // mémoire FILE *fp = FOPEN(fconv(catbuff, sizeof(catbuff), back[i].url_sav), "rb"); if (fp) { LLint alloc_mem = sz + 1; if (back[i].r.totalsize >= 0) alloc_mem += back[i].r.totalsize; // AJOUTER RESTANT! if (deleteaddr(&back[i].r) && (back[i].r.adr = (char *) malloct((size_t) alloc_mem))) { back[i].r.size = sz; if (back[i].r.totalsize >= 0) back[i].r.totalsize += sz; // plus en fait if ((fread(back[i].r.adr, 1, sz, fp)) != sz) { back[i].status = STATUS_READY; // terminé (voir plus loin) back_set_finished(sback, i); strcpybuff(back[i].r.msg, "Can not read partial file"); } else { back[i].r.statuscode = HTTP_OK; // Forcer 'OK' #if HDEBUG printf("continue in mem interrupted file\n"); #endif } } else { back[i].status = STATUS_READY; // terminé (voir plus loin) back_set_finished(sback, i); strcpybuff(back[i].r.msg, "No memory for partial file"); } fclose(fp); } else { // Argh.. back[i].status = STATUS_READY; // terminé (voir plus loin) back_set_finished(sback, i); strcpybuff(back[i].r.msg, "Can not open partial file"); } } } else { // Non trouvé?? back[i].status = STATUS_READY; // terminé (voir plus loin) back_set_finished(sback, i); strcpybuff(back[i].r.msg, "Can not find partial file"); } // Erreur? if (back[i].status == STATUS_READY) { if (back[i].r.soc != INVALID_SOCKET) { #if HTS_DEBUG_CLOSESOCK DEBUG_W ("back_wait(206 solve problems): deletehttp\n"); #endif deletehttp(&back[i].r); } back[i].r.soc = INVALID_SOCKET; //back[i].r.statuscode=206; ???????? back[i].r.statuscode = STATUSCODE_NON_FATAL; if (strnotempty(back[i].r.msg)) strcpybuff(back[i].r.msg, "Error attempting to solve status 206 (partial file)"); } } if (back[i].status != 0) { // non terminé (erreur) if (!back[i].testmode) { // fichier normal if (back[i].r.empty /* ?? && back[i].r.statuscode==HTTP_OK */ ) { // empty response // Couper connexion back_maydeletehttp(opt, cache, sback, i); /* KA deletehttp(&back[i].r); back[i].r.soc=INVALID_SOCKET; */ back[i].status = STATUS_READY; // terminé back_set_finished(sback, i); if (deleteaddr(&back[i].r) && (back[i].r.adr = (char *) malloct(2))) { back[i].r.adr[0] = 0; } hts_log_print(opt, LOG_TRACE, "finalizing empty"); back_finalize(opt, cache, sback, i); } else if (!back[i].r.is_chunk) { // pas de chunk //if (back[i].r.http11!=2) { // pas de chunk back[i].is_chunk = 0; back[i].status = 1; // start body } else { #if CHUNKDEBUG==1 printf("[%d] chunk encoding detected %s..\n", (int) back[i].r.soc, back[i].url_fil); #endif back[i].is_chunk = 1; back[i].chunk_adr = NULL; back[i].chunk_size = 0; back[i].chunk_blocksize = 0; back[i].status = STATUS_CHUNK_WAIT; // start body wait chunk back[i].r.totalsize = -1; /* devalidate size! (rfc) */ } if (back[i].rateout > 0) { back[i].rateout_time = time_local(); // refresh pour transfer rate } #if HDEBUG printf("(buffer) start body!\n"); #endif } else { // mode test, ne pas passer en 1!! back[i].status = STATUS_READY; // READY back_set_finished(sback, i); #if HTS_DEBUG_CLOSESOCK DEBUG_W("back_wait(test ok): deletehttp\n"); #endif deletehttp(&back[i].r); back[i].r.soc = INVALID_SOCKET; if (back[i].r.statuscode == HTTP_OK) { strcpybuff(back[i].r.msg, "Test: OK"); back[i].r.statuscode = STATUSCODE_TEST_OK; // test réussi } else { // test a échoué, on ne change rien sauf que l'erreur est à titre indicatif char tempo[1000]; strcpybuff(tempo, back[i].r.msg); strcpybuff(back[i].r.msg, "Test: "); strcatbuff(back[i].r.msg, tempo); } } } } /*} */ } // si LF } // r.size>2 } // si == 99 } // si pas d'erreurs #if BDEBUG==1 printf("bytes overall: %d\n", back[i].r.size); #endif } // données dispo // en cas d'erreur cl, supprimer éventuel fichier sur disque #if HTS_REMOVE_BAD_FILES if (back[i].status < 0) { if (!back[i].testmode) { // pas en test UNLINK(back[i].url_sav); // éliminer fichier (endommagé) //printf("&& %s\n",back[i].url_sav); } } #endif /* funny log for commandline users */ //if (!opt->quiet) { // petite animation if (opt->verbosedisplay == 1) { if (back[i].status == STATUS_READY) { if (back[i].r.statuscode == HTTP_OK) printf("* %s%s (" LLintP " bytes) - OK" VT_CLREOL "\r", back[i].url_adr, back[i].url_fil, (LLint) back[i].r.size); else printf("* %s%s (" LLintP " bytes) - %d" VT_CLREOL "\r", back[i].url_adr, back[i].url_fil, (LLint) back[i].r.size, back[i].r.statuscode); fflush(stdout); } } //} } // status>0 } // for // vérifier timeouts if (gestion_timeout) { TStamp act; act = time_local(); // temps en secondes for(i_mod = 0; i_mod < (unsigned int) back_max; i_mod++) { // for(i=0;i 0) { // réception/connexion/.. if (back[i].timeout > 0) { //printf("time check %d\n",((int) (act-back[i].timeout_refresh))-back[i].timeout); if (((int) (act - back[i].timeout_refresh)) >= back[i].timeout) { hts_log_print(opt, LOG_DEBUG, "connection timed out for %s%s", back[i].url_adr, back[i].url_fil); if (back[i].r.soc != INVALID_SOCKET) { #if HTS_DEBUG_CLOSESOCK DEBUG_W("back_wait(timeout): deletehttp\n"); #endif deletehttp(&back[i].r); } back[i].r.soc = INVALID_SOCKET; back[i].r.statuscode = STATUSCODE_TIMEOUT; if (back[i].status == STATUS_CONNECTING) strcpybuff(back[i].r.msg, "Connect Time Out"); else if (back[i].status == STATUS_WAIT_DNS) strcpybuff(back[i].r.msg, "DNS Time Out"); else strcpybuff(back[i].r.msg, "Receive Time Out"); back[i].status = STATUS_READY; // terminé back_set_finished(sback, i); } else if ((back[i].rateout > 0) && (back[i].status < 99)) { if (((int) (act - back[i].rateout_time)) >= HTS_WATCHRATE) { // checker au bout de 15s if ((int) ((back[i].r.size) / (act - back[i].rateout_time)) < back[i].rateout) { // trop lent back[i].status = STATUS_READY; // terminé back_set_finished(sback, i); if (back[i].r.soc != INVALID_SOCKET) { #if HTS_DEBUG_CLOSESOCK DEBUG_W("back_wait(rateout): deletehttp\n"); #endif deletehttp(&back[i].r); } back[i].r.soc = INVALID_SOCKET; back[i].r.statuscode = STATUSCODE_SLOW; strcpybuff(back[i].r.msg, "Transfer Rate Too Low"); } } } } } } } max_loop--; max_loop_chk++; } while((busy_state) && (busy_recv) && (max_loop > 0)); if ((!busy_recv) && (!busy_state)) { if (max_loop_chk >= 1) { Sleep(10); // un tite pause pour éviter les lag.. } } } int back_checksize(httrackp * opt, lien_back * eback, int check_only_totalsize) { LLint size_to_test; if (check_only_totalsize) size_to_test = eback->r.totalsize; else size_to_test = max(eback->r.totalsize, eback->r.size); if (size_to_test >= 0) { /* Interdiction taille par le wizard? */ if (hts_testlinksize(opt, eback->url_adr, eback->url_fil, size_to_test / 1024) == -1) { return 0; /* interdit */ } /* vérifier taille classique (heml et non html) */ if ((istoobig (opt, size_to_test, eback->maxfile_html, eback->maxfile_nonhtml, eback->r.contenttype))) { return 0; /* interdit */ } } return 1; } int back_checkmirror(httrackp * opt) { // Check max size if ((opt->maxsite > 0) && (HTS_STAT.stat_bytes >= opt->maxsite)) { if (!opt->state.stop) { /* not yet stopped */ hts_log_print(opt, LOG_ERROR, "More than " LLintP " bytes have been transferred.. giving up", (LLint) opt->maxsite); /* cancel mirror smoothly */ hts_request_stop(opt, 0); } return 1; /* don'k break mirror too sharply for size limits, but stop requested */ /*return 0; */ } // Check max time if ((opt->maxtime > 0) && ((time_local() - HTS_STAT.stat_timestart) >= opt->maxtime)) { if (!opt->state.stop) { /* not yet stopped */ hts_log_print(opt, LOG_ERROR, "More than %d seconds passed.. giving up", opt->maxtime); /* cancel mirror smoothly */ hts_request_stop(opt, 0); } } return 1; /* Ok, go on */ } // octets transférés + add LLint back_transferred(LLint nb, struct_back * sback) { lien_back *const back = sback->lnk; const int back_max = sback->count; int i; // ajouter octets en instance for(i = 0; i < back_max; i++) if ((back[i].status > 0) && (back[i].status < 99 || back[i].status >= 1000)) nb += back[i].r.size; // stored (ready) slots if (sback->ready != NULL) { #ifndef HTS_NO_BACK_ON_DISK nb += sback->ready_size_bytes; #else struct_coucal_enum e = coucal_enum_new(sback->ready); coucal_item *item; while((item = coucal_enum_next(&e))) { lien_back *ritem = (lien_back *) item->value.ptr; if ((ritem->status > 0) && (ritem->status < 99 || ritem->status >= 1000)) nb += ritem->r.size; } #endif } return nb; } // infos backing // j: 1 afficher sockets 2 afficher autres 3 tout afficher void back_info(struct_back * sback, int i, int j, FILE * fp) { lien_back *const back = sback->lnk; const int back_max = sback->count; assertf(i >= 0 && i < back_max); if (back[i].status >= 0) { char BIGSTK s[HTS_URLMAXSIZE * 2 + 1024]; s[0] = '\0'; back_infostr(sback, i, j, s); strcatbuff(s, LF); fprintf(fp, "%s", s); } } // infos backing // j: 1 afficher sockets 2 afficher autres 3 tout afficher void back_infostr(struct_back * sback, int i, int j, char *s) { lien_back *const back = sback->lnk; const int back_max = sback->count; assertf(i >= 0 && i < back_max); if (back[i].status >= 0) { int aff = 0; if (j & 1) { if (back[i].status == STATUS_CONNECTING) { strcatbuff(s, "CONNECT "); } else if (back[i].status == STATUS_WAIT_HEADERS) { strcatbuff(s, "INFOS "); aff = 1; } else if (back[i].status == STATUS_CHUNK_WAIT || back[i].status == STATUS_CHUNK_CR) { strcatbuff(s, "INFOSC"); // infos chunk aff = 1; } else if (back[i].status > 0) { strcatbuff(s, "RECEIVE "); aff = 1; } } if (j & 2) { if (back[i].status == STATUS_READY) { switch (back[i].r.statuscode) { case 200: strcatbuff(s, "READY "); aff = 1; break; case -1: strcatbuff(s, "ERROR "); aff = 1; break; case -2: strcatbuff(s, "TIMEOUT "); aff = 1; break; case -3: strcatbuff(s, "TOOSLOW "); aff = 1; break; case 400: strcatbuff(s, "BADREQUEST "); aff = 1; break; case 401: case 403: strcatbuff(s, "FORBIDDEN "); aff = 1; break; case 404: strcatbuff(s, "NOT FOUND "); aff = 1; break; case 500: strcatbuff(s, "SERVERROR "); aff = 1; break; default: { char s2[256]; sprintf(s2, "ERROR(%d)", back[i].r.statuscode); strcatbuff(s, s2); } aff = 1; } } } if (aff) { { char BIGSTK s2[HTS_URLMAXSIZE * 2 + 1024]; sprintf(s2, "\"%s", back[i].url_adr); strcatbuff(s, s2); if (back[i].url_fil[0] != '/') strcatbuff(s, "/"); sprintf(s2, "%s\" ", back[i].url_fil); strcatbuff(s, s2); sprintf(s, LLintP " " LLintP " ", (LLint) back[i].r.size, (LLint) back[i].r.totalsize); strcatbuff(s, s2); } } } } // -- backing -- httrack-3.49.5/src/htsparse.c0000644000175000017500000062245014360534067013002 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: htsparse.c parser */ /* html/javascript/css parser */ /* and other parser routines */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* Internal engine bytecode */ #define HTS_INTERNAL_BYTECODE #include #include /* File defs */ #include "htscore.h" /* specific definitions */ #include "htsbase.h" #include "htsnet.h" #include "htsbauth.h" #include "htsmd5.h" #include "htsindex.h" #include "htscharset.h" #include "htsencoding.h" /* external modules */ #include "htsmodules.h" // htswrap_add #include "htswrap.h" // parser #include "htsparse.h" #include "htsback.h" // arrays #include "htsarrays.h" /** Append bytes to the output buffer up to the pointer 'html'. **/ #define HT_add_adr do { \ if ( (opt->getmode & 1) != 0 && ptr > 0 ) { \ const size_t sz_ = html - lastsaved; \ if (sz_ != 0) { \ TypedArrayAppend(output_buffer, lastsaved, sz_); \ lastsaved = html; \ } \ } \ } while(0) /** Append to the output buffer the string 'A'. **/ #define HT_ADD(A) TypedArrayAppend(output_buffer, A, strlen(A)) /** Append to the output buffer the string 'A', html-escaped. **/ #define HT_ADD_HTMLESCAPED_ANY(A, FUNCTION) do { \ if ((opt->getmode & 1) != 0 && ptr>0) { \ const char *const str_ = (A); \ size_t size_; \ /* & is the maximum expansion */ \ TypedArrayEnsureRoom(output_buffer, strlen(str_) * 5 + 1024); \ size_ = FUNCTION(str_, &TypedArrayTail(output_buffer), \ TypedArrayRoom(output_buffer)); \ TypedArraySize(output_buffer) += size_; \ } \ } while(0) /** Append to the output buffer the string 'A', html-escaped for &. **/ #define HT_ADD_HTMLESCAPED(A) HT_ADD_HTMLESCAPED_ANY(A, escape_for_html_print) /** * Append to the output buffer the string 'A', html-escaped for & and * high chars. **/ #define HT_ADD_HTMLESCAPED_FULL(A) HT_ADD_HTMLESCAPED_ANY(A, escape_for_html_print_full) // does nothing #define XH_uninit do {} while(0) #define HT_ADD_END { \ int ok=0;\ if (TypedArraySize(output_buffer) != 0) { \ const size_t ht_len = TypedArraySize(output_buffer); \ const char *const ht_buff = TypedArrayElts(output_buffer); \ char digest[32+2];\ off_t fsize_old = fsize(fconv(OPT_GET_BUFF(opt),OPT_GET_BUFF_SIZE(opt),savename()));\ digest[0] = '\0';\ domd5mem(TypedArrayElts(output_buffer), ht_len, digest, 1);\ if (fsize_old == (off_t) ht_len) { \ int mlen = 0;\ char* mbuff;\ cache_readdata(cache,"//[HTML-MD5]//",savename(),&mbuff,&mlen);\ if (mlen) \ mbuff[mlen]='\0';\ if ((mlen == 32) && (strcmp(((mbuff!=NULL)?mbuff:""),digest)==0)) {\ ok=1;\ hts_log_print(opt, LOG_DEBUG, "File not re-written (md5): %s",savename());\ } else {\ ok=0;\ } \ }\ if (!ok) { \ file_notify(opt,urladr(), urlfil(), savename(), 1, 1, r->notmodified); \ fp=filecreate(&opt->state.strc, savename()); \ if (fp) { \ if (ht_len>0) {\ if (fwrite(ht_buff,1,ht_len,fp) != ht_len) { \ int fcheck;\ if ((fcheck=check_fatal_io_errno())) {\ opt->state.exit_xh=-1;\ }\ if (opt->log) { \ hts_log_print(opt, LOG_ERROR | LOG_ERRNO, "Unable to write HTML file %s", savename());\ if (fcheck) {\ hts_log_print(opt, LOG_ERROR, "* * Fatal write error, giving up");\ }\ }\ }\ }\ fclose(fp); fp=NULL; \ if (strnotempty(r->lastmodified)) \ set_filetime_rfc822(savename(),r->lastmodified); \ } else {\ int fcheck;\ if ((fcheck=check_fatal_io_errno())) {\ hts_log_print(opt, LOG_ERROR, "Mirror aborted: disk full or filesystem problems"); \ opt->state.exit_xh=-1;\ }\ hts_log_print(opt, LOG_ERROR | LOG_ERRNO, "Unable to save file %s", savename());\ if (fcheck) {\ hts_log_print(opt, LOG_ERROR, "* * Fatal write error, giving up");\ }\ }\ } else {\ file_notify(opt,urladr(), urlfil(), savename(), 0, 0, r->notmodified); \ filenote(&opt->state.strc, savename(),NULL); \ }\ if (cache->ndx)\ cache_writedata(cache->ndx,cache->dat,"//[HTML-MD5]//",savename(),digest,(int)strlen(digest));\ } \ TypedArrayFree(output_buffer); \ } #define HT_ADD_FOP // COPY IN HTSCORE.C #define HT_INDEX_END do { \ if (!makeindex_done) { \ if (makeindex_fp) { \ char BIGSTK tempo[1024]; \ if (makeindex_links == 1) { \ char BIGSTK link_escaped[HTS_URLMAXSIZE*2]; \ escape_uri_utf(makeindex_firstlink, link_escaped, sizeof(link_escaped)); \ snprintf(tempo,sizeof(tempo),""CRLF,link_escaped); \ } else \ tempo[0]='\0'; \ hts_template_format(makeindex_fp,template_footer, \ "", \ tempo, /* EOF */ NULL \ ); \ fflush(makeindex_fp); \ fclose(makeindex_fp); /* à ne pas oublier sinon on passe une nuit blanche */ \ makeindex_fp=NULL; \ usercommand(opt,0,NULL,fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_html_utf8),"index.html"),"primary","primary"); \ } \ } \ makeindex_done=1; /* ok c'est fait */ \ } while(0) #define ENGINE_DEFINE_CONTEXT() \ ENGINE_DEFINE_CONTEXT_BASE(); \ /* */ \ htsblk* const r HTS_UNUSED = stre->r_; \ hash_struct* const hash HTS_UNUSED = stre->hash_; \ char* const codebase HTS_UNUSED = stre->codebase; \ char* const base HTS_UNUSED = stre->base; \ /* */ \ const char * const template_header HTS_UNUSED = stre->template_header_; \ const char * const template_body HTS_UNUSED = stre->template_body_; \ const char * const template_footer HTS_UNUSED = stre->template_footer_; \ /* */ \ HTS_UNUSED char* const makeindex_firstlink = stre->makeindex_firstlink_; \ /* */ \ /* */ \ int error = * stre->error_; \ int store_errpage = * stre->store_errpage_; \ /* */ \ int makeindex_done = *stre->makeindex_done_; \ FILE* makeindex_fp = *stre->makeindex_fp_; \ int makeindex_links = *stre->makeindex_links_; \ /* */ \ LLint stat_fragment = *stre->stat_fragment_; \ HTS_UNUSED TStamp makestat_time = stre->makestat_time; \ HTS_UNUSED FILE* makestat_fp = stre->makestat_fp #define ENGINE_SET_CONTEXT() \ ENGINE_SET_CONTEXT_BASE(); \ /* */ \ error = * stre->error_; \ store_errpage = * stre->store_errpage_; \ /* */ \ makeindex_done = *stre->makeindex_done_; \ makeindex_fp = *stre->makeindex_fp_; \ makeindex_links = *stre->makeindex_links_; \ /* */ \ stat_fragment = *stre->stat_fragment_; \ makestat_time = stre->makestat_time; \ makestat_fp = stre->makestat_fp #define ENGINE_LOAD_CONTEXT() \ ENGINE_DEFINE_CONTEXT() #define ENGINE_SAVE_CONTEXT() \ ENGINE_SAVE_CONTEXT_BASE(); \ /* */ \ * stre->error_ = error; \ * stre->store_errpage_ = store_errpage; \ /* */ \ *stre->makeindex_done_ = makeindex_done; \ *stre->makeindex_fp_ = makeindex_fp; \ *stre->makeindex_links_ = makeindex_links; \ /* */ \ *stre->stat_fragment_ = stat_fragment #define _FILTERS (*opt->filters.filters) #define _FILTERS_PTR (opt->filters.filptr) #define _ROBOTS ((robots_wizard*)opt->robotsptr) /* Apply current *adr character for the script automate */ #define AUTOMATE_LOOKUP_CURRENT_ADR() do { \ if (inscript) { \ int new_state_pos; \ new_state_pos=inscript_state[inscript_state_pos][(unsigned char)*html]; \ if (new_state_pos < 0) { \ new_state_pos=inscript_state[inscript_state_pos][INSCRIPT_DEFAULT]; \ } \ assertf(new_state_pos >= 0); \ assertf(new_state_pos*sizeof(inscript_state[0]) < sizeof(inscript_state)); \ inscript_state_pos=new_state_pos; \ } \ } while(0) /* Increment current pointer to 'steps' characters, modifying automate if necessary */ #define INCREMENT_CURRENT_ADR(steps) do { \ int steps__ = (int) ( steps ); \ while(steps__ > 0) { \ html++; \ AUTOMATE_LOOKUP_CURRENT_ADR(); \ steps__ --; \ } \ } while(0) /* Main parser */ int htsparse(htsmoduleStruct * str, htsmoduleStructExtended * stre) { char catbuff[CATBUFF_SIZE]; /* Load engine variables */ ENGINE_LOAD_CONTEXT(); { char *cAddr = r->adr; int cSize = (int) r->size; hts_log_print(opt, LOG_DEBUG, "engine: preprocess-html: %s%s", urladr(), urlfil()); if (RUN_CALLBACK4(opt, preprocess, &cAddr, &cSize, urladr(), urlfil()) == 1) { r->adr = cAddr; r->size = cSize; } } if (RUN_CALLBACK4(opt, check_html, r->adr, (int) r->size, urladr(), urlfil())) { FILE *fp = NULL; // fichier écrit localement const char *html = r->adr; // pointeur (on parcours) const char *lastsaved; // adresse du dernier octet sauvé + 1 hts_log_print(opt, LOG_DEBUG, "scanning file %s%s (%s)..", urladr(), urlfil(), savename()); /* Hack to avoid NULL char problems with C syntax */ /* Yes, some bogus HTML pages can embed null chars and therefore can not be properly handled if this hack is not done */ if (r->adr != NULL) { size_t i; for(i = 0 ; i < (size_t) r->size ; i++) { if (r->adr[i] == '\0') { r->adr[i] = ' '; } } } // Indexing! #if HTS_MAKE_KEYWORD_INDEX if (opt->kindex) { if (index_keyword (r->adr, r->size, r->contenttype, savename(), StringBuff(opt->path_html_utf8))) { hts_log_print(opt, LOG_DEBUG, "indexing file..done"); } else { hts_log_print(opt, LOG_DEBUG, "indexing file..error!"); } } #endif // Now, parsing if ((opt->getmode & 1) && (ptr > 0)) { // récupérer les html sur disque // créer le fichier html local HT_ADD_FOP; // écrire peu à peu le fichier } if (!error) { // output HTML TypedArray(char) output_buffer = EMPTY_TYPED_ARRAY; time_t user_interact_timestamp = 0; int detect_title = 0; // détection du title int back_add_stats = opt->state.back_add_stats; const char *in_media = NULL; // in other media type (real media and so..) int intag = 0; // on est dans un tag int incomment = 0; // dans un ", /* EOF */ NULL); } else makeindex_done = -1; // fait, erreur } if (makeindex_fp != NULL) { char BIGSTK tempo[HTS_URLMAXSIZE * 2]; char BIGSTK s[HTS_URLMAXSIZE * 2]; char *a = NULL; char *b = NULL; s[0] = '\0'; if (p > 0) { a = strchr(html, '>'); if (a != NULL) { a++; while(is_space(*a)) a++; // sauter espaces & co b = strchr(a, '<'); // prochain tag } } if (lienrelatif (tempo, heap(ptr)->sav, concat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_html_utf8), "index.html")) == 0) { detect_title = 1; // ok détecté pour cette page! makeindex_links++; // un de plus strcpybuff(makeindex_firstlink, tempo); // /* Hack */ if (opt->mimehtml) { strcpybuff(makeindex_firstlink, "cid:primary/primary"); } if ((b == a) || (a == NULL) || (b == NULL)) { // pas de titre strcpybuff(s, tempo); } else if ((b - a) < 256) { b--; while(is_space(*b)) b--; strncpy(s, a, b - a + 1); *(s + (b - a) + 1) = '\0'; } // Decode title with encoding if (str->page_charset_ != NULL && *str->page_charset_ != '\0') { char *const sUtf = hts_convertStringToUTF8(s, strlen(s), str->page_charset_); if (sUtf != NULL) { strcpy(s, sUtf); free(sUtf); } } // Body inplace_escape_uri_utf(tempo, sizeof(tempo)); hts_template_format(makeindex_fp, template_body, tempo, s, /* EOF */ NULL); } } } } } } else if (heap(ptr)->depth < opt->depth) { // on a sauté level1+1 et level1 HT_INDEX_END; } } // if (opt->makeindex) } // FIN Construction index.html (sommaire) /* end -- index.html built here */ /* Parse */ if ((*html == '<') /* No starting tag */ &&(!inscript) /* Not in (java)script */ &&(!incomment) /* Not in comment (charset); HT_ADD("\" />"); HT_ADD(eol); } } } } // éliminer les is used somewhere else.. darn those browsers are dirty */ if (!strstr(html, "-->")) { intag = 0; incomment = 0; intag_start_valid = 0; intag_name = NULL; } } #endif } //} } //else if (*adr==34) { // inquote=(inquote?0:1); //} else if (intag || inscript || in_media) { // nous sommes dans un tag/commentaire, tester si on recoit un tag int p_type = 0; int p_nocatch = 0; int p_searchMETAURL = 0; // chercher ..URL= int add_class = 0; // ajouter .class int add_class_dots_to_patch = 0; // number of '.' in code="x.y.z" const char *p_flush = NULL; // ------------------------------------------------------------ // parsing évolé // ------------------------------------------------------------ if (((isalpha((unsigned char) *html)) || (*html == '/') || (inscript) || (in_media) || (inscriptgen))) { // sinon pas la peine de tester.. /* caractère de terminaison pour "miniparsing" javascript=.. ? (ex: ) */ if (inscript_tag) { if (inscript_tag_lastc) { if (*html == inscript_tag_lastc) { /* sortir */ inscript_tag = inscript = 0; incomment = 0; if (opt->parsedebug) { HT_ADD("<@@ /inscript @@>"); } } } } /* automate */ AUTOMATE_LOOKUP_CURRENT_ADR(); // Note: // Certaines pages ne respectent pas le html // notamment les guillements ne sont pas fixés // Nous sommes dans un tag, donc on peut faire un test plus // large pour pouvoi prendre en compte ces particularités // à vérifier: ACTION, CODEBASE, VRML if (in_media) { if (strcmp(in_media, "LNK") == 0) { // real media p = 0; valid_p = 1; } else if (strcmp(in_media, "AAM") == 0) { // AAM if (is_space((unsigned char) html[0]) && !is_space((unsigned char) html[1])) { const char *a = html + 1; int n = 0; int ok = 0; int dot = 0; while(n < HTS_URLMAXSIZE / 2 && a[n] != '\0' && (!is_space((unsigned char) a[n]) || !(ok = 1)) ) { if (a[n] == '.') { dot = n; } n++; } if (ok && dot > 0) { char BIGSTK tmp[HTS_URLMAXSIZE / 2 + 2]; tmp[0] = '\0'; strncat(tmp, a + dot + 1, n - dot - 1); if (is_knowntype(opt, tmp) || ishtml_ext(tmp) != -1) { html++; p = 0; valid_p = 1; unquoted_script = 1; } } } } } else if (ptr > 0) { /* pas première page 0 (primary) */ p = 0; // saut pour le nom de fichier: adresse nom fichier=adr+p // ------------------------------ // détection d'écriture JavaScript. // osons les obj.write et les obj.href=.. ! osons! // note: inscript==1 donc on sautera après les \" if (inscript) { if (inscriptgen) { // on est déja dans un objet générant.. if (*html == scriptgen_q) { // fermeture des " ou ' if (*(html - 1) != '\\') { // non inscriptgen = 0; // ok parsing terminé } } } else { const char *a = NULL; char check_this_fking_line = 0; // parsing code javascript.. char must_be_terminated = 0; // caractère obligatoire de terminaison! int token_size; if (!(token_size = strfield(html, ".writeln"))) // détection ...objet.write[ln]("code html")... token_size = strfield(html, ".write"); if (token_size) { a = html + token_size; while(is_realspace(*a)) a++; // sauter espaces if (*a == '(') { // début parenthèse check_this_fking_line = 2; // à parser! must_be_terminated = ')'; a++; // sauter ( } } // euhh ??? ??? /* else if (strfield(adr,".href")) { // détection ...objet.href="... a=adr+5; while(is_realspace(*a)) a++; // sauter espaces if (*a=='=') { // ohh un égal check_this_fking_line=1; // à noter! must_be_terminated=';'; // et si t'as oublié le ; tu sais pas coder a++; // sauter = } } */ // on a un truc du genre instruction"code généré" dont on parse le code if (check_this_fking_line) { while(is_realspace(*a)) a++; if ((*a == '\'') || (*a == '"')) { // départ de '' ou "" const char *b; scriptgen_q = *a; // quote b = a + 1; // départ de la chaîne // vérifier forme ("code") et pas ("code"+var), ingérable do { if (*a == scriptgen_q && *(a - 1) != '\\') // quote non slash break; // sortie else if (*a == 10 && *(a - 1) != '\\' /* LF and no continue (\) character */ && (*(a - 1) != '\r' || *(a - 2) != '\\')) /* and not CRLF and no .. */ break; else a++; // caractère suivant } while((a - b) < HTS_URLMAXSIZE / 2); if (*a == scriptgen_q) { // fin du quote a++; while(is_realspace(*a)) a++; if (*a == must_be_terminated) { // parenthèse fermante: ("..") // bon, on doit parser une ligne javascript // 1) si check.. ==1 alors c'est un nom de fichier direct, donc // on fixe p sur le saut nécessaire pour atteindre le nom du fichier // et le moteur se débrouillera ensuite tout seul comme un grand // 2) si check==2 c'est un peu plus tordu car là on génére du // code html au sein de code javascript au sein de code html // dans ce cas on doit fixer un flag à un puis ensuite dans la boucle // on devra parser les instructions standard comme debug > 1) && (opt->log != NULL)) { char str[512]; str[0] = '\0'; strncatbuff(str, b, minimum((int) (a - b + 1), 32)); hts_log_print(opt, LOG_DEBUG, "active code (%s) detected in javascript: %s", (check_this_fking_line == 2) ? "parse" : "pickup", str); } } } } } } } // fin detection code générant javascript vers html // ------------------------------ // analyse proprement dite, A HREF=.. etc.. if (!p) { // si dans un tag, et pas dans un script - sauf si on analyse un obj.write(".. if ((intag && (!inscript)) || inscriptgen) { if ((*(html - 1) == '<') || (is_space(*(html - 1)))) { // etc) */ if (p == 0) { int i = 0; while((p == 0) && (strnotempty(hts_detect[i]))) { p = rech_tageq(html, hts_detect[i]); if (p) { /* This is a temporary hack to avoid archive=foo.jar,bar.jar .. */ if (strcmp(hts_detect[i], "archive") == 0) { archivetag_p = 1; } } i++; } } /* Tags supplémentaires en début à vérifier ( etc) */ if (p == 0) { int i = 0; while((p == 0) && (strnotempty(hts_detectbeg[i]))) { p = rech_tageqbegdigits(html, hts_detectbeg[i]); i++; } } /* Tags supplémentaires à vérifier : URL=.. */ if (p == 0) { int i = 0; while((p == 0) && (strnotempty(hts_detectURL[i]))) { p = rech_tageq(html, hts_detectURL[i]); i++; } if (p) { if (intag_ctype == 1) { p = 0; #if 0 //if ((pos=rech_tageq(html, "content"))) { char temp[256]; char *token = NULL; int len = rech_endtoken(html + pos, &token); if (len > 0 && len < sizeof(temp) - 2) { char *chpos; temp[0] = '\0'; strncat(temp, token, len); if ((chpos = strstr(temp, "charset")) && (chpos = strchr(chpos, '=')) ) { chpos++; while(is_space(*chpos)) chpod++; //chpos } } #endif } // else if (intag_ctype == 2) { p_searchMETAURL = 1; } else { p = 0; /* cancel */ } } } /* Tags supplémentaires à vérifier, mais à ne pas capturer */ if (p == 0) { int i = 0; while((p == 0) && (strnotempty(hts_detectandleave[i]))) { p = rech_tageq(html, hts_detectandleave[i]); i++; } if (p) p_nocatch = 1; /* ne pas rechercher */ } /* Evénements */ if (p == 0 && !inscript /* we don't want events inside document.write */ ) { int i = 0; /* détection onLoad etc */ while((p == 0) && (strnotempty(hts_detect_js[i]))) { p = rech_tageq(html, hts_detect_js[i]); i++; } /* non détecté - détecter également les onXxxxx= */ if (p == 0) { if ((*html == 'o') && (*(html + 1) == 'n') && isUpperLetter(*(html + 2))) { p = 0; while(isalpha((unsigned char) html[p]) && (p < 64)) p++; if (p < 64) { while(is_space(html[p])) p++; if (html[p] == '=') p++; else p = 0; } else p = 0; } } /* OK, événement repéré */ if (p) { inscript_tag_lastc = *(html + p); /* à attendre à la fin */ html += p /*+ 1*/; /* saut */ /* On est désormais dans du code javascript */ inscript_name = ""; inscript = inscript_tag = 1; inscript_state_pos = INSCRIPT_START; if (opt->parsedebug) { HT_ADD("<@@ inscript @@>"); } } p = 0; /* quoi qu'il arrive, ne rien démarrer ici */ } // '); if (b != NULL) { if (b - html < 1000) { // au total < 1Ko char BIGSTK tempo[HTS_URLMAXSIZE * 2]; const size_t offset = html - r->adr; char *const modify = &r->adr[offset]; assertf(modify == html); tempo[0] = '\0'; strncatbuff(tempo, a, b - a); strcatbuff(tempo, " "); strncatbuff(tempo, html, a - html - 1); // éventuellement remplire par des espaces pour avoir juste la taille while(strlen(tempo) < (size_t) (b - html)) strcatbuff(tempo, " "); // pas d'erreur? if (strlen(tempo) == b - html) { strncpy(modify, tempo, strlen(tempo)); // PAS d'octet nul à la fin! p = 0; // DEVALIDER!! p_type = 0; add_class = 0; } } } } } } } } // liens à patcher mais pas à charger (ex: codebase) if (p == 0) { // note: si non chargé (ex: ignorer .class) patché tout de même p = rech_tageq(html, "codebase"); if (p) { if ((intag_start_valid) && check_tag(intag_start, "applet")) { // dans un robots) { if ((intag_start_valid) && check_tag(intag_start, "meta")) { if (rech_tageq(html, "name")) { // name=robots.txt char tempo[1100]; char *a; tempo[0] = '\0'; a = strchr(html, '>'); #if DEBUG_ROBOTS printf("robots.txt meta tag detected\n"); #endif if (a) { if (a - html < 999) { strncatbuff(tempo, html, a - html); if (strstrcase(tempo, "content")) { if (strstrcase(tempo, "robots")) { if (strstrcase(tempo, "nofollow")) { #if DEBUG_ROBOTS printf ("robots.txt meta tag: nofollow in %s%s\n", urladr(), urlfil()); #endif nofollow = 1; // NE PLUS suivre liens dans cette page hts_log_print(opt, LOG_WARNING, "Link %s%s not scanned (follow robots meta tag)", urladr(), urlfil()); } } } } } } } } } // entrée dans une applet javascript /*if (!inscript) { // sinon on est dans un obj.write(".. if (p==0) if (rech_sampletag(html,"script")) if (check_tag(intag_start,"script")) { inscript=1; } } */ // Ici on procède à une analyse du code javascript pour tenter de récupérer // certains fichiers évidents. // C'est devenu obligatoire vu le nombre de pages qui intègrent // des images réactives par exemple } } else if (inscript) { #if 0 /* Check // javascript comments */ if (*html == 10 || *html == 13) { inscript_check_comments = 1; inscript_in_comments = 0; } else if (inscript_check_comments) { if (!is_realspace(*html)) { inscript_check_comments = 0; if (html[0] == '/' && html[1] == '/') { inscript_in_comments = 1; } } } #endif /* Parse */ assertf(inscript_name != NULL); if (*html == '/' && ((strfield(html, "/script") && strfield(inscript_name, "script")) || (strfield(html, "/style") && strfield(inscript_name, "style")) ) && inscript_locked == 0) { const char *a = html; //while(is_realspace(*(--a))); while(is_realspace(*a)) a--; a--; if (*a == '<') { // sûr que c'est un tag? inscript = 0; if (opt->parsedebug) { HT_ADD("<@@ /inscript @@>"); } } } else if (inscript_state_pos == INSCRIPT_START /*!inscript_in_comments */ ) { /* Script Analyzing - different types supported: foo="url" foo("url") or foo(url) foo "url" */ char expected = '='; // caractère attendu après const char *expected_end = ";"; int can_avoid_quotes = 0; char quotes_replacement = '\0'; int ensure_not_mime = 0; if (inscript_tag) expected_end = ";\"\'"; // voir a href="javascript:doc.location='foo'" /* Can we parse javascript ? */ if ((opt->parsejava & HTSPARSE_NO_JAVASCRIPT) == 0) { int nc; nc = strfield(html, ".src"); // nom.src="image"; if (!nc && inscript_tag && inscript_tag_lastc == *(html - 1)) nc = strfield(html, "src"); // onXXX='src="image";' if (!nc) nc = strfield(html, ".location"); // document.location="doc" if (!nc) nc = strfield(html, ":location"); // javascript:location="doc" if (!nc) { // location="doc" if ((nc = strfield(html, "location")) && !isspace(*(html - 1)) ) nc = 0; } if (!nc) nc = strfield(html, ".href"); // document.location="doc" if (!nc) if ((nc = strfield(html, ".open"))) { // window.open("doc",.. expected = '('; // parenthèse expected_end = "),"; // fin: virgule ou parenthèse ensure_not_mime = 1; //* ensure the url is not a mime type */ } if (!nc) if ((nc = strfield(html, ".replace"))) { // window.replace("url") expected = '('; // parenthèse expected_end = ")"; // fin: parenthèse } if (!nc) if ((nc = strfield(html, ".link"))) { // window.link("url") expected = '('; // parenthèse expected_end = ")"; // fin: parenthèse } if (!nc && (nc = strfield(html, "url")) && (!isalnum(*(html - 1))) && *(html - 1) != '_') { // url(url) expected = '('; // parenthèse expected_end = ")"; // fin: parenthèse can_avoid_quotes = 1; quotes_replacement = ')'; } if (!nc) if ((nc = strfield(html, "import"))) { // import "url" if (is_space(*(html + nc))) { expected = 0; // no char expected } else nc = 0; } if (nc) { const char *a; a = html + nc; while(is_realspace(*a)) a++; if ((*a == expected) || (!expected)) { if (expected) a++; while(is_realspace(*a)) a++; if ((*a == 34) || (*a == '\'') || (can_avoid_quotes)) { const char *b, *c; int ndelim = 1; if ((*a == 34) || (*a == '\'')) a++; else ndelim = 0; b = a; if (ndelim) { while((*b != 34) && (*b != '\'') && (*b != '\0')) b++; } else { while((*b != quotes_replacement) && (*b != '\0')) b++; } c = b--; c += ndelim; while(*c == ' ') c++; if ((strchr(expected_end, *c)) || (*c == '\n') || (*c == '\r')) { c -= (ndelim + 1); if ((int) (c - a + 1)) { if (ensure_not_mime) { int i = 0; while(a != NULL && hts_main_mime[i] != NULL && hts_main_mime[i][0] != '\0') { int p; if ((p = strfield(a, hts_main_mime[i])) && a[p] == '/') { a = NULL; } i++; } } // Check for bogus links (Vasiliy) if (a != NULL) { const size_t size = c - a + 1; int i; int first = 1; for(i = 0; i < size; i++) { // Suspicious (in code ?), abort. if (a[i] == ',' || a[i] == ';') { if (first) { a = NULL; break; } } // Suspicious, abort. else if (a[i] == '"' || a[i] == '\'' || a[i] == '\t' || a[i] == '\r' || a[i] == '\n') { a = NULL; break; } else if (a[i] != ' ') { first = 0; } } } if (a != NULL) { if ((opt->debug > 1) && (opt->log != NULL)) { char str[512]; str[0] = '\0'; strncatbuff(str, a, minimum((int) (c - a + 1), 32)); hts_log_print(opt, LOG_DEBUG, "link detected in javascript: %s", str); } p = (int) (a - html); // p non nul: TRAITER CHAINE COMME FICHIER if (can_avoid_quotes) { ending_p = quotes_replacement; } } } } } } } } /* HTSPARSE_NO_JAVASCRIPT */ } } } } else { // ptr == 0 //p=rech_tageq(adr,"primary"); // lien primaire, yeah p = 0; // No stupid tag anymore, raw link valid_p = 1; // Valid even if p==0 while((html[p] == '\r') || (html[p] == '\n')) p++; //can_avoid_quotes=1; ending_p = '\r'; } } else if (isspace((unsigned char) *html)) { intag_startattr = html + 1; // attribute in tag (for dirty parsing) } // ------------------------------------------------------------ // dernier recours - parsing "sale" : détection systématique des .gif, etc. // risque: générer de faux fichiers parazites // fix: ne parse plus dans les commentaires // ------------------------------------------------------------ if (opt->parseall && (opt->parsejava & HTSPARSE_NO_AGGRESSIVE) == 0 && (ptr > 0) && (!in_media) /* && (!inscript_in_comments) */ ) { // option parsing "brut" //int incomment_justquit=0; if (!is_realspace(*html)) { int noparse = 0; // Gestion des /* */ #if 0 if (inscript) { if (parseall_incomment) { if ((*html == '/') && (*(html - 1) == '*')) parseall_incomment = 0; incomment_justquit = 1; // ne pas noter dernier caractère } else { if ((*html == '/') && (*(html + 1) == '*')) parseall_incomment = 1; } } else parseall_incomment = 0; #endif /* ensure automate state 0 (not in comments, quotes..) */ if (inscript && (inscript_state_pos != INSCRIPT_INQUOTE && inscript_state_pos != INSCRIPT_INQUOTE2)) { noparse = 1; } /* vérifier que l'on est pas dans un pur */ if ((!intag) && (incomment) && (!inscript)) noparse = 1; /* commentaire */ // recherche d'URLs if (!noparse) { //if ((!parseall_incomment) && (!noparse)) { if (!p) { // non déja trouvé if (html != r->adr) { // >1 caractère // scanner les chaines if ((*html == '\"') || (*html == '\'')) { // "xx.gif" 'xx.gif' if (strchr("=(,", parseall_lastc)) { // exemple: a="img.gif.. (handles comments) const char *a = html; char stop = *html; // " ou ' int count = 0; // sauter caractères a++; // copier while((*a) && (*a != '\'') && (*a != '\"') && (count < HTS_URLMAXSIZE)) { count++; a++; } // ok chaine terminée par " ou ' if ((*a == stop) && (count < HTS_URLMAXSIZE) && (count > 0)) { char c; //char* aend; // //aend=a; // sauver début a++; while(is_taborspace(*a)) a++; c = *a; if (strchr("),;>/+\r\n", c)) { // exemple: ..img.gif"; // le / est pour funct("img.gif" /* URL */); char BIGSTK tempo[HTS_URLMAXSIZE * 2]; char type[256]; int url_ok = 0; // url valide? tempo[0] = '\0'; type[0] = '\0'; // strncatbuff(tempo, html + 1, count); // if ((!strchr(tempo, ' ')) || inscript) { // espace dedans: méfiance! (sauf dans code javascript) int invalid_url = 0; // escape unescape_amp(tempo); // Couper au # ou ? éventuel { char *a = strchr(tempo, '#'); if (a) *a = '\0'; a = strchr(tempo, '?'); if (a) *a = '\0'; } // vérifier qu'il n'y a pas de caractères spéciaux if (!strnotempty(tempo)) invalid_url = 1; else if (strchr(tempo, '*') || strchr(tempo, '<') || strchr(tempo, '>') || strchr(tempo, ',') /* list of files ? */ ||strchr(tempo, '\"') /* potential parsing bug */ ||strchr(tempo, '\'') /* potential parsing bug */ ) invalid_url = 1; else if (tempo[0] == '.' && isalnum(tempo[1])) // ".gif" invalid_url = 1; /* non invalide? */ if (!invalid_url) { // Un plus à la fin? Alors ne pas prendre sauf si extension ("/toto.html#"+tag) if (c != '+') { // PAS de plus à la fin #if 0 char *a; #endif // "Comparisons of scheme names MUST be case-insensitive" (RFC2616) if ((strfield(tempo, "http:")) || (strfield(tempo, "ftp:")) #if HTS_USEOPENSSL || (strfield(tempo, "https:") ) #endif ) // ok pas de problème url_ok = 1; else if (tempo[strlen(tempo) - 1] == '/') { // un slash: ok.. if (inscript) // sinon si pas javascript, méfiance (répertoire style base?) url_ok = 1; } #if 0 else if ((a = strchr(tempo, '/'))) { // un slash: ok.. if (inscript) { // sinon si pas javascript, méfiance (style "text/css") if (strchr(a + 1, '/')) // un seul / : abandon (STYLE type='text/css') if (!strchr(tempo, ' ')) // avoid spaces (too dangerous for comments) url_ok = 1; } } #endif } // Prendre si extension reconnue if (!url_ok) { get_httptype(opt, type, tempo, 0); if (strnotempty(type)) // type reconnu! url_ok = 1; else if (is_dyntype(get_ext(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), tempo))) // reconnu php,cgi,asp.. url_ok = 1; // MAIS pas les foobar@aol.com !! if (strchr(tempo, '@')) url_ok = 0; } // // Ok, cela pourrait être une URL if (url_ok) { // Check if not fodbidden tag (id,name..) if (intag_start_valid) { if (intag_start) if (intag_startattr) if (intag) if (!inscript) if (!incomment) { int i = 0, nop = 0; while((nop == 0) && (strnotempty (hts_nodetect[i]))) { nop = rech_tageq(intag_startattr, hts_nodetect[i]); i++; } // Forbidden tag if (nop) { url_ok = 0; hts_log_print(opt, LOG_DEBUG, "dirty parsing: bad tag avoided: %s", hts_nodetect[i - 1]); } } } // Accepter URL, on la traitera comme une URL normale!! if (url_ok) { valid_p = 1; p = 0; } } } } } } } } } } // p == 0 } // not in comment // plus dans un commentaire if (inscript_state_pos == INSCRIPT_START && inscript_state_pos_prev == INSCRIPT_START) { parseall_lastc = *html; // caractère avant le prochain } } // if realspace } // if parseall // ------------------------------------------------------------ // p!=0 : on a repéré un éventuel lien // ------------------------------------------------------------ // if ((p > 0) || (valid_p)) { // on a repéré un lien //int lien_valide=0; const char *eadr = NULL; /* fin de l'URL */ //char* quote_adr=NULL; /* adresse du ? dans l'adresse */ int ok = 1; char quote = '\0'; int quoteinscript = 0; int noquote = 0; const char *tag_attr_start = html; // si nofollow ou un stop a été déclenché, réécrire tous les liens en externe if ((nofollow) || (opt->state.stop && /* force follow not to lose previous cache data */ !opt->is_update) ) p_nocatch = 1; // écrire codebase avant, flusher avant code if ((p_type == -1) || (p_type == -2)) { if ((opt->getmode & 1) && (ptr > 0)) { HT_add_adr; // refresh } lastsaved = html; // dernier écrit+1 } // sauter espaces // adr+=p; INCREMENT_CURRENT_ADR(p); while((is_space(*html) || (inscriptgen && html[0] == '\\' && is_space(html[1]) ) ) && quote == '\0') { if (!quote) if ((*html == '\"') || (*html == '\'')) { quote = *html; // on doit attendre cela à la fin if (inscriptgen && *(html - 1) == '\\') { quoteinscript = 1; /* will wait for \" */ } } // puis quitter // html++; // sauter les espaces, "" et cie INCREMENT_CURRENT_ADR(1); } /* Stop at \n (LF) if primary links or link lists */ if (ptr == 0 || (in_media && strcmp(in_media, "LNK") == 0)) quote = '\n'; /* s'arrêter que ce soit un ' ou un " : pour document.write('parsedebug) { HT_ADD("<@@ inscript @@>"); } } } if (p_type == 1) { if (*html == '#') { html++; // sauter # pour usemap etc } } eadr = html; // ne pas flusher après code si on doit écrire le codebase avant! if ((p_type != -1) && (p_type != 2) && (p_type != -2)) { if ((opt->getmode & 1) && (ptr > 0)) { HT_add_adr; // refresh } lastsaved = html; // dernier écrit+1 // après on écrira soit les données initiales, // soir une URL/lien modifié! } else if (p_type == -1) p_flush = html; // flusher jusqu'à adr ensuite if (ok != -1) { // continuer // découper le lien do { if ((unsigned char) *eadr < 32) { // caractère de contrôle (ou \0) if (!is_space(*eadr)) ok = 0; } if (eadr - html > HTS_URLMAXSIZE) // ** trop long, >HTS_URLMAXSIZE caractères (on prévoit HTS_URLMAXSIZE autres pour path) ok = -1; // ne pas traiter ce lien if (ok > 0) { //if (*eadr!=' ') { if (is_space(*eadr)) { // guillemets,CR, etc if ((*eadr == quote && (!quoteinscript || *(eadr - 1) == '\\')) // end quote || (noquote && (*eadr == '\"' || *eadr == '\'')) // end at any quote || (!noquote && quote == '\0' && is_realspace(*eadr)) // unquoted href ) // si pas d'attente de quote spéciale ou si quote atteinte ok = 0; } else if (ending_p && (*eadr == ending_p)) ok = 0; else { switch (*eadr) { case '>': if (!quote) { if (!inscript && !in_media) { intag = 0; // PLUS dans un tag! intag_start_valid = 0; intag_name = NULL; } ok = 0; } break; /*case '<': */ case '#': if (*(eadr - 1) != '&') // ( ok = 0; break; // case '?': non! case '\\': if (inscript) ok = 0; break; // \" ou \' point d'arrêt case '?': /*quote_adr=adr; */ break; // noter position query } } //} } eadr++; } while(ok == 1); // Empty link detected if (eadr - html <= 1) { // link empty ok = -1; // No if (*html != '#') { // Not empty+unique # if (eadr - html == 1) { // 1=link empty with delim (end_adr-start_adr) if (quote) { if ((opt->getmode & 1) && (ptr > 0)) { HT_ADD("#"); // We add this for a } } } } } // This is a dirty and horrible hack to avoid parsing an Adobe GoLive bogus tag if (strfield(html, "(Empty Reference!)")) { ok = -1; // No } } if (ok == 0) { // tester un lien char BIGSTK lien[HTS_URLMAXSIZE * 2]; int meme_adresse = 0; // 0 par défaut pour primary //char *copie_de_adr=html; //char* p; // construire lien (découpage) if (eadr - html - 1 < HTS_URLMAXSIZE) { // pas trop long? strncpy(lien, html, eadr - html - 1); lien[eadr - html - 1] = '\0'; //printf("link: %s\n",lien); // supprimer les espaces while((lien[strlen(lien) - 1] == ' ') && (strnotempty(lien))) lien[strlen(lien) - 1] = '\0'; } else lien[0] = '\0'; // erreur // ------------------------------------------------------ // Lien repéré et extrait if (strnotempty(lien) > 0) { // construction du lien lien_adrfilsave afs; int forbidden_url = -1; // lien non interdit (mais non autorisé..) int just_test_it = 0; // mode de test des liens int set_prio_to = 0; // pour capture de page isolée int import_done = 0; // lien importé (ne pas scanner ensuite *à priori*) // afs.af.adr[0] = '\0'; afs.af.fil[0] = '\0'; afs.save[0] = '\0'; // // 0: autorisé // 1: interdit (patcher tout de même adresse) hts_log_print(opt, LOG_DEBUG, "link detected in html (tag): %s", lien); // external check if (!RUN_CALLBACK1(opt, linkdetected, lien) || !RUN_CALLBACK2(opt, linkdetected2, lien, intag_start)) { error = 1; // erreur hts_log_print(opt, LOG_ERROR, "Link %s refused by external wrapper", lien); } #if HTS_STRIP_DOUBLE_SLASH // supprimer les // en / (sauf pour http://) if (opt->urlhack) { char *a, *p, *q; int done = 0; a = strchr(lien, ':'); // http:// if (a) { a++; while(*a == '/') a++; // position après http:// } else { a = lien; // début while(*a == '/') a++; // position après http:// } q = strchr(a, '?'); // ne pas traiter après '?' if (!q) q = a + strlen(a) - 1; while((p = strstr(a, "//")) && (!done)) { // remplacer // par / if (p > q) { // après le ? (toto.cgi?param=1//2.3) done = 1; // stopper } else { char BIGSTK tempo[HTS_URLMAXSIZE * 2]; tempo[0] = '\0'; strncatbuff(tempo, a, p - a); strcatbuff(tempo, p + 1); strcpybuff(a, tempo); // recopier } } } #endif // purger espaces de début et fin, CR,LF résiduels // (IMG SRC="foo.<\n><\t>gif<\t>") { char *a = lien; size_t llen; // strip ending spaces llen = (*a != '\0') ? strlen(a) : 0; while(llen > 0 && is_realspace(lien[llen - 1])) { a[--llen] = '\0'; } // skip leading ones while(is_realspace(*a)) a++; // strip cr, lf, tab inside URL llen = 0; while(*a) { if (*a != '\n' && *a != '\r' && *a != '\t') { lien[llen++] = *a; } a++; } lien[llen] = '\0'; } // commas are forbidden if (archivetag_p) { if (strchr(lien, ',')) { error = 1; // erreur hts_log_print(opt, LOG_DEBUG, "link rejected (multiple-archive) %s", lien); } } /* Unescape/escape %20 and other   */ { // Note: always true (iso-8859-1 as default) const char *const charset = str->page_charset_; const int hasCharset = charset != NULL && *charset != '\0'; char BIGSTK query[HTS_URLMAXSIZE * 2]; // cut query string { char *const a = strchr(lien, '?'); if (a != NULL) { strcpybuff(query, a); *a = '\0'; } else { query[0] = '\0'; } } // Unescape %XX, but not yet high-chars (supposedly encoded with UTF-8) strcpybuff(lien, unescape_http_unharm(catbuff, sizeof(catbuff), lien, 1 | 2)); /* note: '%' is still escaped */ // Force to encode non-printable chars (should never happend) escape_remove_control(lien); // charset conversion for the URI filename, // and not already UTF-8 // (note: not for the query string!) if (hasCharset && !hts_isCharsetUTF8(charset)) { char *const s = hts_convertStringToUTF8(lien, strlen(lien), charset); if (s != NULL) { hts_log_print(opt, LOG_DEBUG, "engine: save-name: '%s' charset conversion from '%s' to '%s'", charset, lien, s); strcpybuff(lien, s); free(s); } } // decode URI entities with UTF-8 charset if (hts_unescapeEntities(lien, lien, strlen(lien) + 1) != 0) { hts_log_print(opt, LOG_WARNING, "could not decode URI '%s' with charset '%s'", lien, charset); } // decode query string entities with page charset if (hasCharset) { if (hts_unescapeEntitiesWithCharset(query, query, strlen(query) + 1, charset) != 0) { hts_log_print(opt, LOG_WARNING, "could not decode query string '%s' with charset '%s'", query, charset); } } // Decode remaining %XX high characters with UTF-8 // but only when this leads to valid UTF-8. // Otherwise, leave them unescaped. if (hts_unescapeUrlSpecial(lien, catbuff, sizeof(catbuff), UNESCAPE_URL_NO_ASCII) == 0) { strcpybuff(lien, catbuff); } else { hts_log_print(opt, LOG_WARNING, "could not URL-decode string '%s'", lien); } // we need to encode query string non-ascii chars, // leaving the encoding as-is (unlike the file part) // and copy back query append_escape_check_url(query, lien, sizeof(lien)); } // convertir les éventuels \ en des / pour éviter des problèmes de reconnaissance! { char *a; for(a = jump_identification(lien); *a != '\0' && *a != '?'; a++) { if (*a == '\\') { *a = '/'; } } } // supprimer le(s) ./ while((lien[0] == '.') && (lien[1] == '/')) { char BIGSTK tempo[HTS_URLMAXSIZE * 2]; strcpybuff(tempo, lien + /* ./ */ 2); strcpybuff(lien, tempo); } if (strnotempty(lien) == 0) // sauf si plus de nom de fichier strcpybuff(lien, "./"); // vérifie les /~machin -> /~machin/ // supposition dangereuse? // OUI!! #if HTS_TILDE_SLASH if (lien[strlen(lien) - 1] != '/') { char *a = lien + strlen(lien) - 1; // éviter aussi index~1.html while(a > lien && (*a != '~') && (*a != '/') && (*a != '.')) a--; if (*a == '~') { strcatbuff(lien, "/"); // ajouter slash } } #endif // APPLET CODE="mixer.MixerApplet.class" --> APPLET CODE="mixer/MixerApplet.class" // yes, this is dirty // but I'm so lazzy.. // and besides the java "code" convention is really a pain in html code if (p_type == -1) { char *a = strrchr(lien, '.'); add_class_dots_to_patch = 0; if (a) { char *b; do { b = strchr(lien, '.'); if ((b != a) && (b)) { add_class_dots_to_patch++; *b = '/'; } } while((b != a) && (b)); } } // éliminer les éventuels :80 (port par défaut!) if (link_has_authority(lien)) { char *a; a = strstr(lien, "//"); // "//" authority if (a) a += 2; else a = lien; // while((*a) && (*a!='/') && (*a!=':')) a++; a = jump_toport(a); if (a) { // port int port = 0; int defport = 80; char *b = a + 1; #if HTS_USEOPENSSL // FIXME //if (strfield(adr, "https:")) { //} #endif while(isdigit((unsigned char) *b)) { port *= 10; port += (int) (*b - '0'); b++; } if (port == defport) { // port 80, default - c'est débile char BIGSTK tempo[HTS_URLMAXSIZE * 2]; tempo[0] = '\0'; strncatbuff(tempo, lien, a - lien); strcatbuff(tempo, a + 3); // sauter :80 strcpybuff(lien, tempo); } } } // filtrer les parazites (mailto & cie) /* if (strfield(lien,"mailto:")) { // ne pas traiter error=1; } else if (strfield(lien,"news:")) { // ne pas traiter error=1; } */ // vérifier que l'on ne doit pas ajouter de .class if (!error) { if (add_class) { char *a = lien + strlen(lien) - 1; while((a > lien) && (*a != '/') && (*a != '.')) a--; if (*a != '.') strcatbuff(lien, ".class"); // ajouter .class else if (!strfield2(a, ".class")) strcatbuff(lien, ".class"); // idem } } // si c'est un chemin, alors vérifier (toto/toto.html -> http://www/toto/) if (!error) { hts_log_print(opt, LOG_DEBUG, "position link check %s", lien); if ((p_type == 2) || (p_type == -2)) { // code ou codebase // Vérifier les codebase=applet (au lieu de applet/) if (p_type == -2) { // codebase if (strnotempty(lien)) { if (lien[strlen(lien) - 1] != '/') { // pas répertoire strcatbuff(lien, "/"); } } } /* base has always authority */ if (p_type == 2 && !link_has_authority(lien)) { char BIGSTK tmp[HTS_URLMAXSIZE * 2]; strcpybuff(tmp, "http://"); strcatbuff(tmp, lien); strcpybuff(lien, tmp); } /* only one ending / (bug on some pages) */ if (strlen(lien) > 2) { size_t len = strlen(lien); while(len > 1 && lien[len - 1] == '/' && lien[len - 2] == '/') /* double // (bug) */ lien[--len] = '\0'; } // copier nom host si besoin est if (!link_has_authority(lien)) { // pas de http:// lien_adrfil af2; // ** euh ident_url_relatif?? if (ident_url_relatif(lien, urladr(), urlfil(), &af2) < 0) { error = 1; } else { strcpybuff(lien, "http://"); strcatbuff(lien, af2.adr); if (*af2.fil != '/') strcatbuff(lien, "/"); strcatbuff(lien, af2.fil); { char *a; a = lien + strlen(lien) - 1; while((*a) && (*a != '/') && (a > lien)) a--; if (*a == '/') { *(a + 1) = '\0'; } } //char BIGSTK tempo[HTS_URLMAXSIZE*2]; //strcpybuff(tempo,"http://"); //strcatbuff(tempo,urladr()); // host //if (*lien!='/') // strcatbuff(tempo,"/"); //strcatbuff(tempo,lien); //strcpybuff(lien,tempo); } } if (!error) { // pas d'erreur? if (p_type == 2) { // code ET PAS codebase char *a = lien + strlen(lien) - 1; char *start_of_filename = jump_identification(lien); if (start_of_filename != NULL && (start_of_filename = strchr(start_of_filename, '/')) != NULL) start_of_filename++; if (start_of_filename == NULL) strcatbuff(lien, "/"); while((a > lien) && (*a) && (*a != '/')) a--; if (*a == '/') { // ok on a repéré le dernier / if (start_of_filename != NULL && a + 1 >= start_of_filename) { *(a + 1) = '\0'; // couper } } else { *lien = '\0'; // éliminer error = 1; // erreur, ne pas poursuivre } } // stocker base ou codebase? switch (p_type) { case 2:{ //if (*lien!='/') strcatbuff(base,"/"); strcpybuff(base, lien); } break; // base case -2:{ //if (*lien!='/') strcatbuff(codebase,"/"); strcpybuff(codebase, lien); } break; // base } hts_log_print(opt, LOG_DEBUG, "code/codebase link %s base %s", lien, base); //printf("base code: %s - %s\n",lien,base); } } else { char *_base; if (p_type == -1) // code (applet) _base = codebase; else _base = base; // ajouter chemin de base href.. if (strnotempty(_base)) { // considérer base if (!link_has_authority(lien)) { // non absolue if (*lien != '/') { // non absolu sur le site (/) if ((strlen(_base) + strlen(lien)) < HTS_URLMAXSIZE) { // mailto: and co: do NOT add base if (ident_url_relatif (lien, urladr(), urlfil(), &afs.af) >= 0) { char BIGSTK tempo[HTS_URLMAXSIZE * 2]; // base est absolue strcpybuff(tempo, _base); strcatbuff(tempo, lien + ((*lien == '/') ? 1 : 0)); strcpybuff(lien, tempo); // patcher en considérant base // ** vérifier que ../ fonctionne (ne doit pas arriver mais bon..) hts_log_print(opt, LOG_DEBUG, "link modified with code/codebase %s", lien); } } else { error = 1; // erreur hts_log_print(opt, LOG_ERROR, "Link %s too long with base href", lien); } } else { lien_adrfil baseaf; if (ident_url_absolute(_base, &baseaf) >= 0) { if ((strlen(baseaf.adr) + strlen(lien)) < HTS_URLMAXSIZE) { char BIGSTK tempo[HTS_URLMAXSIZE * 2]; // base est absolue tempo[0] = '\0'; if (!link_has_authority(baseaf.adr)) { strcatbuff(tempo, "http://"); } strcatbuff(tempo, baseaf.adr); strcatbuff(tempo, lien); strcpybuff(lien, tempo); // patcher en considérant base hts_log_print(opt, LOG_DEBUG, "link modified with code/codebase %s", lien); } else { error = 1; // erreur hts_log_print(opt, LOG_ERROR, "Link %s too long with base href", lien); } } } } } } } // transformer lien quelconque (http, relatif, etc) en une adresse // et un chemin+fichier (adr,fil) if (!error) { int reponse; hts_log_print(opt, LOG_DEBUG, "build relative link %s with %s%s", lien, relativeurladr(), relativeurlfil()); if ((reponse = ident_url_relatif(lien, relativeurladr(), relativeurlfil(), &afs.af)) < 0) { afs.af.adr[0] = '\0'; // erreur if (reponse == -2) { hts_log_print(opt, LOG_WARNING, "Link %s not caught (unknown protocol)", lien); } else { hts_log_print(opt, LOG_DEBUG, "ident_url_relatif failed for %s with %s%s", lien, relativeurladr(), relativeurlfil()); } } else { hts_log_print(opt, LOG_DEBUG, "built relative link %s with %s%s -> %s%s", lien, relativeurladr(), relativeurlfil(), afs.af.adr, afs.af.fil); } } else { hts_log_print(opt, LOG_DEBUG, "link %s not build, error detected before", lien); afs.af.adr[0] = '\0'; } // Le lien doit juste être réécrit, mais ne doit pas générer un lien // exemple:
if (p_nocatch) { forbidden_url = 1; // interdire récupération du lien hts_log_print(opt, LOG_DEBUG, "link forced external at %s%s", afs.af.adr, afs.af.fil); } // Tester si un lien doit être accepté ou refusé (wizard) // forbidden_url=1 : lien refusé // forbidden_url=0 : lien accepté //if ((ptr>0) && (p_type!=2) && (p_type!=-2)) { // tester autorisations? if ((p_type != 2) && (p_type != -2)) { // tester autorisations? if (!p_nocatch) { if (afs.af.adr[0] != '\0') { hts_log_print(opt, LOG_DEBUG, "wizard link test at %s%s..", afs.af.adr, afs.af.fil); forbidden_url = hts_acceptlink(opt, ptr, afs.af.adr, afs.af.fil, intag_name ? intag_name : NULL, intag_name ? tag_attr_start : NULL, &set_prio_to, &just_test_it); hts_log_print(opt, LOG_DEBUG, "result for wizard link test: %d", forbidden_url); } } } // calculer meme_adresse meme_adresse = strfield2(jump_identification_const(afs.af.adr), jump_identification_const(urladr())); // Début partie sauvegarde // ici on forme le nom du fichier à sauver, et on patche l'URL if (afs.af.adr[0] != '\0') { // savename(): simplifier les ../ et autres joyeusetés int r_sv = 0; // En cas de moved, adresse première lien_adrfil former; // afs.save[0] = '\0'; former.adr[0] = '\0'; former.fil[0] = '\0'; // // nom du chemin à sauver si on doit le calculer // note: url_savename peut décider de tester le lien si il le trouve // suspect, et modifier alors adr et fil // dans ce cas on aura une référence directe au lieu des traditionnels // moved en cascade (impossible à reproduire à priori en local, lorsque des fichiers // gif sont impliqués par exemple) if ((p_type != 2) && (p_type != -2)) { // pas base href ou codebase if (forbidden_url != 1) { char BIGSTK last_adr[HTS_URLMAXSIZE * 2]; /* Calc */ last_adr[0] = '\0'; //char last_fil[HTS_URLMAXSIZE*2]=""; strcpybuff(last_adr, afs.af.adr); // ancienne adresse //strcpybuff(last_fil,fil); // ancien chemin r_sv = url_savename(&afs, &former, heap(ptr)->adr, heap(ptr)->fil, opt, sback, cache, hash, ptr, numero_passe, NULL); if (strcmp(jump_identification_const(last_adr), jump_identification_const(afs.af.adr)) != 0) { // a changé // 2e test si moved // Tester si un lien doit être accepté ou refusé (wizard) // forbidden_url=1 : lien refusé // forbidden_url=0 : lien accepté if ((ptr > 0) && (p_type != 2) && (p_type != -2)) { // tester autorisations? if (!p_nocatch) { if (afs.af.adr[0] != '\0') { hts_log_print(opt, LOG_DEBUG, "wizard moved link retest at %s%s..", afs.af.adr, afs.af.fil); forbidden_url = hts_acceptlink(opt, ptr, afs.af.adr, afs.af.fil, intag_name ? intag_name : NULL, intag_name ? tag_attr_start : NULL, &set_prio_to, &just_test_it); hts_log_print(opt, LOG_DEBUG, "result for wizard moved link retest: %d", forbidden_url); } } } //import_done=1; // c'est un import! meme_adresse = 0; // on a changé } } else { strcpybuff(afs.save, ""); // dummy } } // resolve unresolved type if (r_sv != -1 && p_type != 2 && p_type != -2 && forbidden_url == 0 && IS_DELAYED_EXT(afs.save) ) { time_t t; // pas d'erreur, on continue r_sv = hts_wait_delayed(str, &afs, heap(ptr)->adr, heap(ptr)->fil, &former, &forbidden_url); /* User interaction, because hts_wait_delayed can be slow.. (3.43) */ t = time(NULL); if (user_interact_timestamp == 0 || t - user_interact_timestamp > 0) { user_interact_timestamp = t; ENGINE_SAVE_CONTEXT(); { hts_mirror_process_user_interaction(str, stre); } ENGINE_SET_CONTEXT(); } } // record! if (r_sv != -1) { // pas d'erreur, on continue /* log */ if ((opt->debug > 1) && (opt->log != NULL)) { if (forbidden_url != 1) { // le lien va être chargé if ((p_type == 2) || (p_type == -2)) { // base href ou codebase, pas un lien hts_log_print(opt, LOG_DEBUG, "Code/Codebase: %s%s", afs.af.adr, afs.af.fil); } else if ((opt->getmode & 4) == 0) { hts_log_print(opt, LOG_DEBUG, "Record: %s%s -> %s", afs.af.adr, afs.af.fil, afs.save); } else { if (!ishtml(opt, afs.af.fil)) hts_log_print(opt, LOG_DEBUG, "Record after: %s%s -> %s", afs.af.adr, afs.af.fil, afs.save); else hts_log_print(opt, LOG_DEBUG, "Record: %s%s -> %s", afs.af.adr, afs.af.fil, afs.save); } } else hts_log_print(opt, LOG_DEBUG, "External: %s%s", afs.af.adr, afs.af.fil); } /* FIN log */ // écrire lien if ((p_type == 2) || (p_type == -2)) { // base href ou codebase, sauter lastsaved = eadr - 1 + 1; // sauter " } /* */ else if (opt->urlmode == 0) { // URL absolue dans tous les cas if ((opt->getmode & 1) && (ptr > 0)) { // ecrire les html if (!link_has_authority(afs.af.adr)) { HT_ADD("http://"); } else { char *aut = strstr(afs.af.adr, "//"); if (aut) { char tmp[256]; tmp[0] = '\0'; strncatbuff(tmp, afs.af.adr, aut - afs.af.adr); // scheme HT_ADD(tmp); // Protocol HT_ADD("//"); } } if (!opt->passprivacy) { HT_ADD_HTMLESCAPED(jump_protocol_const(afs.af.adr)); // Password } else { HT_ADD_HTMLESCAPED(jump_identification_const(afs.af.adr)); // No Password } if (afs.af.fil[0] != '/') HT_ADD("/"); HT_ADD_HTMLESCAPED(afs.af.fil); } lastsaved = eadr - 1; // dernier écrit+1 (enfin euh apres on fait un ++ alors hein) /* */ } else if (opt->urlmode == 4) { // ne rien faire! /* */ /* leave the link 'as is' */ /* Sinon, dépend de interne/externe */ } else if (forbidden_url == 1) { // le lien ne sera pas chargé, référence externe! if ((opt->getmode & 1) && (ptr > 0)) { if (p_type != -1) { // pas que le nom de fichier (pas classe java) if (!opt->external) { if (!link_has_authority(afs.af.adr)) { HT_ADD("http://"); if (!opt->passprivacy) { HT_ADD_HTMLESCAPED(afs.af.adr); // Password } else { HT_ADD_HTMLESCAPED(jump_identification_const(afs.af.adr)); // No Password } if (afs.af.fil[0] != '/') HT_ADD("/"); HT_ADD_HTMLESCAPED(afs.af.fil); } else { char *aut = strstr(afs.af.adr, "//"); if (aut) { char tmp[256]; tmp[0] = '\0'; strncatbuff(tmp, afs.af.adr, (aut - afs.af.adr)); // scheme HT_ADD(tmp); // Protocol HT_ADD("//"); if (!opt->passprivacy) { HT_ADD_HTMLESCAPED(jump_protocol_const(afs.af.adr)); // Password } else { HT_ADD_HTMLESCAPED(jump_identification_const(afs.af.adr)); // No Password } if (afs.af.fil[0] != '/') HT_ADD("/"); HT_ADD_HTMLESCAPED(afs.af.fil); } } // } else { // fichier/page externe, mais on veut générer une erreur // int patch_it = 0; int add_url = 0; const char *cat_name = NULL; const char *cat_data = NULL; int cat_nb = 0; int cat_data_len = 0; // ajouter lien external switch ((link_has_authority(afs.af.adr)) ? 1 : ((afs.af.fil[strlen(afs.af.fil) - 1] == '/') ? 1 : (ishtml(opt, afs.af.fil)))) { case 1: case -2: // html ou répertoire if (opt->getmode & 1) { // sauver html patch_it = 1; // redirect add_url = 1; // avec link? cat_name = "external.html"; cat_nb = 0; cat_data = HTS_DATA_UNKNOWN_HTML; cat_data_len = HTS_DATA_UNKNOWN_HTML_LEN; } break; default: // inconnu // asp, cgi.. if ((strfield2 (afs.af.fil + max(0, strlen(afs.af.fil) - 4), ".gif")) || (strfield2 (afs.af.fil + max(0, strlen(afs.af.fil) - 4), ".jpg")) || (strfield2 (afs.af.fil + max(0, strlen(afs.af.fil) - 4), ".xbm")) /*|| (ishtml(opt,fil)!=0) */ ) { patch_it = 1; // redirect add_url = 1; // avec link aussi cat_name = "external.gif"; cat_nb = 1; cat_data = HTS_DATA_UNKNOWN_GIF; cat_data_len = HTS_DATA_UNKNOWN_GIF_LEN; } else { /* if (is_dyntype(get_ext(fil))) */ patch_it = 1; // redirect add_url = 1; // avec link? cat_name = "external.html"; cat_nb = 0; cat_data = HTS_DATA_UNKNOWN_HTML; cat_data_len = HTS_DATA_UNKNOWN_HTML_LEN; } break; } // html,gif if (patch_it) { char BIGSTK save[HTS_URLMAXSIZE * 2]; char BIGSTK tempo[HTS_URLMAXSIZE * 2]; strcpybuff(save, StringBuff(opt->path_html_utf8)); strcatbuff(save, cat_name); if (lienrelatif(tempo, save, relativesavename()) == 0) { /* Never escape high-chars (we don't know the encoding!!) */ inplace_escape_uri_utf(tempo, sizeof(tempo)); // escape with %xx //if (!no_esc_utf) // escape_uri(tempo); // escape with %xx //else // escape_uri_utf(tempo); // escape with %xx HT_ADD_HTMLESCAPED(tempo); // page externe if (add_url) { HT_ADD("?link="); // page externe // same as above if (!link_has_authority(afs.af.adr)) { HT_ADD("http://"); if (!opt->passprivacy) { HT_ADD_HTMLESCAPED(afs.af.adr); // Password } else { HT_ADD_HTMLESCAPED(jump_identification_const(afs.af.adr)); // No Password } if (afs.af.fil[0] != '/') HT_ADD("/"); HT_ADD_HTMLESCAPED(afs.af.fil); } else { char *aut = strstr(afs.af.adr, "//"); if (aut) { char tmp[256]; tmp[0] = '\0'; strncatbuff(tmp, afs.af.adr, (aut - afs.af.adr) + 2); // scheme HT_ADD(tmp); if (!opt->passprivacy) { HT_ADD_HTMLESCAPED(jump_protocol_const(afs.af.adr)); // Password } else { HT_ADD_HTMLESCAPED(jump_identification_const(afs.af.adr)); // No Password } if (afs.af.fil[0] != '/') HT_ADD("/"); HT_ADD_HTMLESCAPED(afs.af.fil); } } // } } // écrire fichier? if (verif_external(opt, cat_nb, 1)) { FILE *fp = filecreate(&opt->state.strc, fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt-> path_html_utf8), cat_name)); if (fp) { if (cat_data_len == 0) { // texte verif_backblue(opt, StringBuff(opt-> path_html_utf8)); fprintf(fp, "%s%s", "" LF, cat_data); } else { // data fwrite(cat_data, cat_data_len, 1, fp); } fclose(fp); usercommand(opt, 0, NULL, fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt-> path_html_utf8), cat_name), "", ""); } } } else { // écrire normalement le nom de fichier HT_ADD("http://"); if (!opt->passprivacy) { HT_ADD_HTMLESCAPED(afs.af.adr); // Password } else { HT_ADD_HTMLESCAPED(jump_identification_const(afs.af.adr)); // No Password } if (afs.af.fil[0] != '/') HT_ADD("/"); HT_ADD_HTMLESCAPED(afs.af.fil); } // patcher? } // external } else { // que le nom de fichier (classe java) // en gros recopie de plus bas: copier codebase et base if (p_flush) { char BIGSTK tempo[HTS_URLMAXSIZE * 2]; // <-- ajouté char BIGSTK tempo_pat[HTS_URLMAXSIZE * 2]; // Calculer chemin tempo_pat[0] = '\0'; strcpybuff(tempo, afs.af.fil); // <-- ajouté { char *a = strrchr(tempo, '/'); // Example: we converted code="x.y.z.foo.class" into "x/y/z/foo.class" // we have to do the contrary now if (add_class_dots_to_patch > 0) { while((add_class_dots_to_patch > 0) && (a)) { *a = '.'; // convert "false" java / into . add_class_dots_to_patch--; a = strrchr(tempo, '/'); } // if add_class_dots_to_patch, this is because there is a problem!! if (add_class_dots_to_patch) { hts_log_print(opt, LOG_WARNING, "Error: can not rewind java path %s, check html code", tempo); } } // Cut path/filename if (a) { char BIGSTK tempo2[HTS_URLMAXSIZE * 2]; strcpybuff(tempo2, a + 1); // FICHIER strncatbuff(tempo_pat, tempo, (a - tempo) + 1); // chemin strcpybuff(tempo, tempo2); // fichier } } // érire codebase="chemin" if ((opt->getmode & 1) && (ptr > 0)) { char BIGSTK tempo4[HTS_URLMAXSIZE * 2]; tempo4[0] = '\0'; if (strnotempty(tempo_pat)) { HT_ADD("codebase=\"http://"); if (!opt->passprivacy) { HT_ADD_HTMLESCAPED(afs.af.adr); // Password } else { HT_ADD_HTMLESCAPED(jump_identification_const(afs.af.adr)); // No Password } if (*tempo_pat != '/') HT_ADD("/"); HT_ADD(tempo_pat); HT_ADD("\" "); } strncatbuff(tempo4, lastsaved, p_flush - lastsaved); HT_ADD(tempo4); // refresh code=" HT_ADD(tempo); } } } } lastsaved = eadr - 1; } /* else if (opt->urlmode==1) { // ABSOLU, c'est le cas le moins courant // NE FONCTIONNE PAS!! (et est inutile) if ((opt->getmode & 1) && (ptr>0)) { // ecrire les html // écrire le lien modifié, absolu HT_ADD("file:"); if (*save=='/') HT_ADD(save+1) else HT_ADD(save) } lastsaved=eadr-1; // dernier écrit+1 (enfin euh apres on fait un ++ alors hein) } */ else if (opt->mimehtml) { char BIGSTK cid[HTS_URLMAXSIZE * 3]; HT_ADD("cid:"); make_content_id(afs.af.adr, afs.af.fil, cid, sizeof(cid)); HT_ADD_HTMLESCAPED(cid); lastsaved = eadr - 1; // dernier écrit+1 (enfin euh apres on fait un ++ alors hein) } else if (opt->urlmode == 3) { // URI absolue / if ((opt->getmode & 1) && (ptr > 0)) { // ecrire les html HT_ADD_HTMLESCAPED(afs.af.fil); } lastsaved = eadr - 1; // dernier écrit+1 (enfin euh apres on fait un ++ alors hein) } else if (opt->urlmode == 5) { // transparent proxy URL char BIGSTK tempo[HTS_URLMAXSIZE * 2]; const char *uri; int i; char *pos; if ((opt->getmode & 1) && (ptr > 0)) { // ecrire les html if (!link_has_authority(afs.af.adr)) { HT_ADD("http://"); } else { char *aut = strstr(afs.af.adr, "//"); if (aut) { char tmp[256]; tmp[0] = '\0'; strncatbuff(tmp, afs.af.adr, (aut - afs.af.adr)); // scheme HT_ADD(tmp); // Protocol HT_ADD("//"); } } // filename is taken as URI (ex: "C:\My Website\www.example.com\foo4242.html) uri = afs.save; // .. after stripping the path prefix (ex: "www.example.com\foo4242.html) if (strnotempty(StringBuff(opt->path_html_utf8))) { uri += StringLength(opt->path_html_utf8); for(; uri[0] == '/' || uri[0] == '\\'; uri++) ; } // and replacing all \ by / (ex: "www.example.com/foo4242.html) strcpybuff(tempo, uri); for(i = 0; tempo[i] != '\0'; i++) { if (tempo[i] == '\\') { tempo[i] = '/'; } } // put original query string if any (ex: "www.example.com/foo4242.html?q=45) pos = strchr(afs.af.fil, '?'); if (pos != NULL) { strcatbuff(tempo, pos); } // write it HT_ADD_HTMLESCAPED(tempo); } lastsaved = eadr - 1; // dernier écrit+1 (enfin euh apres on fait un ++ alors hein) } else if (opt->urlmode == 2) { // RELATIF char BIGSTK tempo[HTS_URLMAXSIZE * 2]; tempo[0] = '\0'; // calculer le lien relatif if (lienrelatif(tempo, afs.save, relativesavename()) == 0) { if (!in_media) { // In media (such as real audio): don't patch /* Never escape high-chars (we don't know the encoding!!) */ inplace_escape_uri_utf(tempo, sizeof(tempo)); //if (!no_esc_utf) // escape_uri(tempo); // escape with %xx //else { // /* No escaping at all - remaining upper chars will be escaped below */ // /* FIXME - Should be done in all local cases */ // //x_escape_html(tempo); // //escape_uri_utf(tempo); // FIXME - escape with %xx // //escape_uri(tempo); // escape with %xx //} } hts_log_print(opt, LOG_DEBUG, "relative link at %s build with %s and %s: %s", afs.af.adr, afs.save, relativesavename(), tempo); // lien applet (code) - il faut placer un codebase avant if (p_type == -1) { // que le nom de fichier if (p_flush) { char BIGSTK tempo_pat[HTS_URLMAXSIZE * 2]; tempo_pat[0] = '\0'; { char *a = strrchr(tempo, '/'); // Example: we converted code="x.y.z.foo.class" into "x/y/z/foo.class" // we have to do the contrary now if (add_class_dots_to_patch > 0) { while((add_class_dots_to_patch > 0) && (a)) { *a = '.'; // convert "false" java / into . add_class_dots_to_patch--; a = strrchr(tempo, '/'); } // if add_class_dots_to_patch, this is because there is a problem!! if (add_class_dots_to_patch) { hts_log_print(opt, LOG_WARNING, "Error: can not rewind java path %s, check html code", tempo); } } if (a) { char BIGSTK tempo2[HTS_URLMAXSIZE * 2]; strcpybuff(tempo2, a + 1); strncatbuff(tempo_pat, tempo, a - tempo + 1); // chemin strcpybuff(tempo, tempo2); // fichier } } // érire codebase="chemin" if ((opt->getmode & 1) && (ptr > 0)) { char BIGSTK tempo4[HTS_URLMAXSIZE * 2]; tempo4[0] = '\0'; if (strnotempty(tempo_pat)) { HT_ADD("codebase=\""); HT_ADD_HTMLESCAPED(tempo_pat); HT_ADD("\" "); } strncatbuff(tempo4, lastsaved, p_flush - lastsaved); HT_ADD(tempo4); // refresh code=" } } //lastsaved=adr; // dernier écrit+1 } if ((opt->getmode & 1) && (ptr > 0)) { // convert to local codepage - NOT, already converted into %NN, and passed to the remote server so we do not have anything to do //if (str->page_charset_ != NULL && *str->page_charset_ != '\0') { // char *const local_save = hts_convertStringFromUTF8(tempo, strlen(tempo), str->page_charset_); // if (local_save != NULL) { // strcpybuff(tempo, local_save); // free(local_save); // } else { // if ((opt->debug>1) && (opt->log!=NULL)) { // fprintf(opt->log, "Warning: could not build local charset representation of '%s' in '%s'"LF, tempo, str->page_charset_); // } // } //} // écrire le lien modifié, relatif // Note: escape all chars, even >127 (no UTF) HT_ADD_HTMLESCAPED_FULL(tempo); // Add query-string, for informational purpose only // Useless, because all parameters-pages are saved into different targets if (opt->includequery) { char *a = strchr(lien, '?'); if (a) { HT_ADD_HTMLESCAPED(a); } } } lastsaved = eadr - 1; // dernier écrit+1 (enfin euh apres on fait un ++ alors hein) } else { hts_log_print(opt, LOG_WARNING, "Error building relative link %s and %s", afs.save, relativesavename()); } } // sinon le lien sera écrit normalement #if 0 if (fexist(save)) { // le fichier existe.. adr[0] = '\0'; //if ((opt->debug>0) && (opt->log!=NULL)) { hts_log_print(opt, LOG_WARNING, "Link has already been written on disk, cancelled: %s", save); } #endif /* Security check */ if (strlen(afs.save) >= HTS_URLMAXSIZE) { afs.af.adr[0] = '\0'; hts_log_print(opt, LOG_WARNING, "Link is too long: %s", afs.save); } if ((afs.af.adr[0] != '\0') && (p_type != 2) && (p_type != -2) && (forbidden_url != 1)) { // si le fichier n'existe pas, ajouter à la liste // n'y a-t-il pas trop de liens? if (opt->maxlink > 0 && opt->lien_tot + 1 >= opt->maxlink) { // trop de liens! printf("PANIC! : Too many URLs : >%d [%d]\n", opt->lien_tot, __LINE__); hts_log_print(opt, LOG_PANIC, "Too many URLs, giving up..(>%d)", opt->maxlink); hts_log_print(opt, LOG_INFO, "To avoid that: use #L option for more links (example: -#L1000000)"); if ((opt->getmode & 1) && (ptr > 0)) { if (fp) { fclose(fp); fp = NULL; } } XH_uninit; // désallocation mémoire & buffers return -1; } else { // noter le lien sur la listes des liens à charger int pass_fix, dejafait = 0; // Calculer la priorité de ce lien if ((opt->getmode & 4) == 0) { // traiter html après pass_fix = 0; } else { // vérifier que ce n'est pas un !html if (!ishtml(opt, afs.af.fil)) pass_fix = 1; // priorité inférieure (traiter après) else pass_fix = max(0, numero_passe); // priorité normale } /* If the file seems to be an html file, get depth-1 */ /* if (strnotempty(save)) { if (ishtml(opt,save) == 1) { // descore_prio = 2; } else { // descore_prio = 1; } } */ // vérifier que le lien n'a pas déja été noté // si c'est le cas, alors il faut s'assurer que la priorité associée // au fichier est la plus grande des deux priorités // // On part de la fin et on essaye de se presser (économise temps machine) { int i = hash_read(hash, afs.save, NULL, 0); // lecture type 0 (sav) if (i >= 0) { if ((opt->debug > 1) && (opt->log != NULL)) { if (strcmp(afs.af.adr, heap(i)->adr) != 0 || strcmp(afs.af.fil, heap(i)->fil) != 0) { hts_log_print(opt, LOG_DEBUG, "merging similar links %s%s and %s%s", afs.af.adr, afs.af.fil, heap(i)->adr, heap(i)->fil); } } heap(i)->depth = maximum(heap(i)->depth, heap(ptr)->depth - 1); dejafait = 1; } } // le lien n'a jamais été créé. // cette fois ci, on le crée! if (!dejafait) { // // >>>> CREER LE LIEN <<<< // // enregistrer lien à charger //heap_top()->adr[0]=heap_top()->fil[0]=heap_top()->sav[0]='\0'; // même adresse: l'objet père est l'objet père de l'actuel // DEBUT ROBOTS.TXT AJOUT if (!just_test_it) { if ((!strfield(afs.af.adr, "ftp://")) // non ftp && (!strfield(afs.af.adr, "file://")) ) { // non file if (opt->robots) { // récupérer robots if (ishtml(opt, afs.af.fil) != 0) { // pas la peine pour des fichiers isolés if (checkrobots(_ROBOTS, afs.af.adr, "") != -1) { // robots.txt ? checkrobots_set(_ROBOTS, afs.af.adr, ""); // ajouter entrée vide if (checkrobots(_ROBOTS, afs.af.adr, "") == -1) { // robots.txt ? // enregistrer robots.txt (MACRO) if (!hts_record_link(opt, afs.af.adr, "/robots.txt", "", "", "", NULL)) { if ((opt->getmode & 1) && (ptr > 0)) { if (fp) { fclose(fp); fp = NULL; } } XH_uninit; // désallocation mémoire & buffers return -1; } heap_top()->testmode = 0; // pas mode test heap_top()->link_import = 0; // pas mode import heap_top()->premier = heap_top_index(); heap_top()->precedent = ptr; heap_top()->depth = 0; heap_top()->pass2 = max(0, numero_passe); heap_top()->retry = 0; #if DEBUG_ROBOTS printf ("robots.txt: added file robots.txt for %s\n", adr); #endif hts_log_print(opt, LOG_DEBUG, "robots.txt added at %s", afs.af.adr); } else { hts_log_print(opt, LOG_ERROR, "Unexpected robots.txt error at %d", __LINE__); } } } } } } // FIN ROBOTS.TXT AJOUT // enregistrer if (!hts_record_link(opt, afs.af.adr, afs.af.fil, afs.save, former.adr, former.fil, codebase)) { if ((opt->getmode & 1) && (ptr > 0)) { if (fp) { fclose(fp); fp = NULL; } } XH_uninit; // désallocation mémoire & buffers return -1; } // mode test? if (!just_test_it) heap_top()->testmode = 0; // pas mode test else heap_top()->testmode = 1; // mode test if (!import_done) heap_top()->link_import = 0; // pas mode import else heap_top()->link_import = 1; // mode import // écrire autres paramètres de la structure-lien if ((meme_adresse) && (!import_done) && (heap(ptr)->premier != 0)) heap_top()->premier = heap(ptr)->premier; else // sinon l'objet père est le précédent lui même heap_top()->premier = heap_top_index(); // heap_top()->premier=ptr; heap_top()->precedent = ptr; // noter la priorité if (!set_prio_to) heap_top()->depth = heap(ptr)->depth - 1; else heap_top()->depth = max(0, min(heap(ptr)->depth - 1, set_prio_to - 1)); // PRIORITE NULLE (catch page) // noter pass heap_top()->pass2 = pass_fix; heap_top()->retry = opt->retry; //strcpybuff(heap_top()->adr,adr); //strcpybuff(heap_top()->fil,fil); //strcpybuff(heap_top()->sav,save); if (!just_test_it) { hts_log_print(opt, LOG_DEBUG, "OK, NOTE: %s%s -> %s", heap_top()->adr, heap_top()->fil, heap_top()->sav); } else { hts_log_print(opt, LOG_DEBUG, "OK, TEST: %s%s", heap_top()->adr, heap_top()->fil); } } else { // if !dejafait hts_log_print(opt, LOG_DEBUG, "link has already been recorded, cancelled: %s", afs.save); } } // si pas trop de liens } // si adr[0]!='\0' } // if adr[0]!='\0' } // if adr[0]!='\0' } // if strlen(lien)>0 } // if ok==0 assertf(eadr - html >= 0); // Should not go back if (eadr > html) { INCREMENT_CURRENT_ADR(eadr - 1 - html); } // adr=eadr-1; // ** sauter /* We skipped bytes and skip the " : reset state */ /*if (inscript) { inscript_state_pos = INSCRIPT_START; } */ } // if (p) } // si '<' ou '>' // plus loin html++; // automate will be checked next loop /* Otimization: if we are scanning in HTML data (not in tag or script), then jump to the next starting tag */ if (ptr > 0) { if ((!intag) /* Not in tag */ &&(!inscript) /* Not in (java)script */ &&(!in_media) /* Not in media */ &&(!incomment) /* Not in comment (" CRLF "" CRLF "" "" "Page has moved" CRLF "" CRLF "" CRLF "

Click here...

" CRLF "" CRLF "" CRLF "" CRLF, mov_url, mov_url); // changer la page if (r->adr) { freet(r->adr); r->adr = NULL; } r->adr = rn; r->size = strlen(r->adr); strcpybuff(r->contenttype, "text/html"); } } // get_it==0 } // bloc // erreur HTTP (ex: 404, not found) } else if ((r->statuscode == HTTP_PRECONDITION_FAILED) || (r->statuscode == HTTP_REQUESTED_RANGE_NOT_SATISFIABLE) ) { // Precondition Failed, c'est à dire pour nous redemander TOUT le fichier if (fexist_utf8(heap(ptr)->sav)) { remove(heap(ptr)->sav); // Eliminer } else { hts_log_print(opt, LOG_WARNING, "Unexpected 412/416 error (%s) for %s%s, '%s' could not be found on disk", r->msg, urladr(), urlfil(), heap(ptr)->sav != NULL ? heap(ptr)->sav : ""); } if (!fexist_utf8(heap(ptr)->sav)) { // Bien éliminé? (sinon on boucle..) #if HDEBUG printf("Partial content NOT up-to-date, reget all file for %s\n", heap(ptr)->sav); #endif hts_log_print(opt, LOG_DEBUG, "Partial file reget (%s) for %s%s", r->msg, urladr(), urlfil()); // enregistrer le MEME lien if (hts_record_link(opt, heap(ptr)->adr, heap(ptr)->fil, heap(ptr)->sav, "", "", NULL)) { heap_top()->testmode = heap(ptr)->testmode; // mode test? heap_top()->link_import = 0; // pas mode import heap_top()->depth = heap(ptr)->depth; heap_top()->pass2 = max(heap(ptr)->pass2, numero_passe); heap_top()->retry = heap(ptr)->retry; heap_top()->premier = heap(ptr)->premier; heap_top()->precedent = ptr; // // canceller lien actuel error = 1; hts_invalidate_link(opt, ptr); // invalidate hashtable entry // } else { // oups erreur, plus de mémoire!! XH_uninit; // désallocation mémoire & buffers return 0; } } else { hts_log_print(opt, LOG_ERROR, "Can not remove old file %s", urlfil()); error = 1; } // Error ? if (error) { if (!opt->errpage) { if (r->adr) { // désalloc freet(r->adr); r->adr = NULL; } } } } else if (r->statuscode != HTTP_OK) { int can_retry = 0; // cas où l'on peut reessayer switch (r->statuscode) { //case -1: can_retry=1; break; case STATUSCODE_TIMEOUT: if (opt->hostcontrol) { // timeout et retry épuisés if ((opt->hostcontrol & 1) && (heap(ptr)->retry <= 0)) { hts_log_print(opt, LOG_DEBUG, "Link banned: %s%s", urladr(), urlfil()); host_ban(opt, ptr, sback, jump_identification_const(urladr())); hts_log_print(opt, LOG_DEBUG, "Info: previous log - link banned: %s%s", urladr(), urlfil()); } else can_retry = 1; } else can_retry = 1; break; case STATUSCODE_SLOW: if ((opt->hostcontrol) && (heap(ptr)->retry <= 0)) { // too slow if (opt->hostcontrol & 2) { hts_log_print(opt, LOG_DEBUG, "Link banned: %s%s", urladr(), urlfil()); host_ban(opt, ptr, sback, jump_identification_const(urladr())); hts_log_print(opt, LOG_DEBUG, "Info: previous log - link banned: %s%s", urladr(), urlfil()); } else can_retry = 1; } else can_retry = 1; break; case STATUSCODE_CONNERROR: // connect closed can_retry = 1; break; case STATUSCODE_NON_FATAL: // other (non fatal) error can_retry = 1; break; case STATUSCODE_SSL_HANDSHAKE: // bad SSL handskake can_retry = 1; break; case 408: case 409: case 500: case 502: case 504: can_retry = 1; break; } if (strcmp(heap(ptr)->fil, "/primary") != 0) { // no primary (internal page 0) if ((heap(ptr)->retry <= 0) || (!can_retry)) { // retry épuisés (ou retry impossible) if ((opt->retry > 0) && (can_retry)) { hts_log_print(opt, LOG_ERROR, "\"%s\" (%d) after %d retries at link %s%s (from %s%s)", r->msg, r->statuscode, opt->retry, urladr(), urlfil(), heap(heap(ptr)->precedent)->adr, heap(heap(ptr)->precedent)->fil); } else { if (r->statuscode == STATUSCODE_TEST_OK) { // test OK hts_log_print(opt, LOG_INFO, "Test OK at link %s%s (from %s%s)", urladr(), urlfil(), heap(heap(ptr)->precedent)->adr, heap(heap(ptr)->precedent)->fil); } else { if (strcmp(urlfil(), "/robots.txt")) { // ne pas afficher d'infos sur robots.txt par défaut hts_log_print(opt, LOG_ERROR, "\"%s\" (%d) at link %s%s (from %s%s)", r->msg, r->statuscode, urladr(), urlfil(), heap(heap(ptr)->precedent)->adr, heap(heap(ptr)->precedent)->fil); } else { hts_log_print(opt, LOG_DEBUG, "No robots.txt rules at %s", urladr()); } } } // NO error in trop level // due to the "no connection -> previous restored" hack // This prevent the engine from wiping all data if the website has been deleted (or moved) // since last time (which is quite annoying) if (heap(ptr)->precedent != 0) { // ici on teste si on doit enregistrer la page tout de même if (opt->errpage) { store_errpage = 1; } } else { if (strcmp(urlfil(), "/robots.txt") != 0) { /* This is an error caused by a link entered by the user That is, link(s) entered by user are invalid (404, 500, connect error, proxy error->.) If all links entered are invalid, the session failed and we will attempt to restore the previous one Example: Try to update a website which has been deleted remotely: this may delete the website locally, which is really not desired (especially if the website disappeared!) With this hack, the engine won't wipe local files (how clever) */ HTS_STAT.stat_errors_front++; } } } else { // retry!! hts_log_print(opt, LOG_NOTICE, "Retry after error %d (%s) at link %s%s (from %s%s)", r->statuscode, r->msg, urladr(), urlfil(), heap(heap(ptr)->precedent)->adr, heap(heap(ptr)->precedent)->fil); // redemander fichier if (hts_record_link(opt, urladr(), urlfil(), savename(), "", "", codebase)) { heap_top()->testmode = heap(ptr)->testmode; // mode test? heap_top()->link_import = 0; // pas mode import heap_top()->depth = heap(ptr)->depth; heap_top()->pass2 = max(heap(ptr)->pass2, numero_passe); heap_top()->retry = heap(ptr)->retry - 1; // moins 1 retry! heap_top()->premier = heap(ptr)->premier; heap_top()->precedent = heap(ptr)->precedent; } else { // oups erreur, plus de mémoire!! return 0; } } } else { hts_log_print(opt, LOG_DEBUG, "Info: no robots.txt at %s%s", urladr(), urlfil()); } if (!store_errpage) { if (r->adr) { // désalloc freet(r->adr); r->adr = NULL; } error = 1; // erreur! } // otherwise, consider this is not an error } // FIN rattrapage des 301,302,307.. // ------------------------------------------------------------ } // if !error /* Apply changes */ ENGINE_SAVE_CONTEXT(); return 0; } /* Process pause, link adding.. */ void hts_mirror_process_user_interaction(htsmoduleStruct * str, htsmoduleStructExtended * stre) { int b; /* Load engine variables */ ENGINE_LOAD_CONTEXT(); #if BDEBUG==1 printf("\nBack test..\n"); #endif // pause/lock files { int do_pause = 0; // user pause lockfile : create hts-paused.lock --> HTTrack will be paused if (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-stop.lock"))) { // remove lockfile remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-stop.lock")); if (!fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-stop.lock"))) { do_pause = 1; } } // after receving N bytes, pause if (opt->fragment > 0) { if ((HTS_STAT.stat_bytes - stat_fragment) > opt->fragment) { do_pause = 1; } } // pause? if (do_pause) { hts_log_print(opt, LOG_INFO, "engine: pause requested.."); while(back_nsoc(sback) > 0) { // attendre fin des transferts back_wait(sback, opt, cache, HTS_STAT.stat_timestart); Sleep(200); { back_wait(sback, opt, cache, HTS_STAT.stat_timestart); // Transfer rate engine_stats(); // Refresh various stats HTS_STAT.stat_nsocket = back_nsoc(sback); HTS_STAT.stat_errors = fspc(opt, NULL, "error"); HTS_STAT.stat_warnings = fspc(opt, NULL, "warning"); HTS_STAT.stat_infos = fspc(opt, NULL, "info"); HTS_STAT.nbk = backlinks_done(sback, opt->liens, opt->lien_tot, ptr); HTS_STAT.nb = back_transferred(HTS_STAT.stat_bytes, sback); b = 0; if (!RUN_CALLBACK7 (opt, loop, sback->lnk, sback->count, b, ptr, opt->lien_tot, (int) (time_local() - HTS_STAT.stat_timestart), &HTS_STAT) || !back_checkmirror(opt)) { hts_log_print(opt, LOG_ERROR, "Exit requested by shell or user"); *stre->exit_xh_ = 1; // exit requested XH_uninit; return; } } } // On désalloue le buffer d'enregistrement des chemins créée, au cas où pendant la pause // l'utilisateur ferait un rm -r après avoir effectué un tar // structcheck_init(1); { FILE *fp = fopen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-paused.lock"), "wb"); if (fp) { fspc(NULL, fp, "info"); // dater fprintf(fp, "Pause" LF "HTTrack is paused after retreiving " LLintP " bytes" LF "Delete this file to continue the mirror->.." LF "" LF "", (LLint) HTS_STAT.stat_bytes); fclose(fp); } } stat_fragment = HTS_STAT.stat_bytes; /* Info for wrappers */ hts_log_print(opt, LOG_INFO, "engine: pause: %s", fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-paused.lock")); RUN_CALLBACK1(opt, pause, fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-paused.lock")); } // } // end of pause/lock files // changement dans les préférences if (opt->state._hts_addurl) { lien_adrfilsave add; while(*opt->state._hts_addurl) { char BIGSTK add_url[HTS_URLMAXSIZE * 2]; add.af.adr[0] = add.af.fil[0] = add_url[0] = '\0'; if (!link_has_authority(*opt->state._hts_addurl)) strcpybuff(add_url, "http://"); // ajouter http:// strcatbuff(add_url, *opt->state._hts_addurl); if (ident_url_absolute(add_url, &add.af) >= 0) { // ----Ajout---- // calculer lien et éventuellement modifier addresse/fichier if (url_savename (&add, NULL, NULL, NULL, opt, sback, cache, hash, ptr, numero_passe, NULL) != -1) { if (hash_read(hash, add.save, NULL, HASH_STRUCT_FILENAME) < 0) { // n'existe pas déja // enregistrer lien if (hts_record_link(opt, add.af.adr, add.af.fil, add.save, "", "", NULL)) { heap_top()->testmode = 0; // mode test? heap_top()->link_import = 0; // mode normal heap_top()->depth = opt->depth; heap_top()->pass2 = max(0, numero_passe); heap_top()->retry = opt->retry; heap_top()->premier = heap_top_index(); heap_top()->precedent = heap_top_index(); // hts_log_print(opt, LOG_INFO, "Link added by user: %s%s", add.af.adr, add.af.fil); // } else { // oups erreur, plus de mémoire!! XH_uninit; // désallocation mémoire & buffers return; } } else { hts_log_print(opt, LOG_NOTICE, "Existing link %s%s not added after user request", add.af.adr, add.af.fil); } } } else { hts_log_print(opt, LOG_ERROR, "Error during URL decoding for %s", add_url); } // ----Fin Ajout---- opt->state._hts_addurl++; // suivante } opt->state._hts_addurl = NULL; // libérer _hts_addurl } // si une pause a été demandée if (opt->state._hts_setpause || back_pluggable_sockets_strict(sback, opt) <= 0) { // index du lien actuel int b = back_index(opt, sback, urladr(), urlfil(), savename()); int prev = opt->state._hts_in_html_parsing; if (b < 0) b = 0; // forcer pour les stats while(opt->state._hts_setpause || back_pluggable_sockets_strict(sback, opt) <= 0) { // on fait la pause.. opt->state._hts_in_html_parsing = 6; back_wait(sback, opt, cache, HTS_STAT.stat_timestart); // Transfer rate engine_stats(); // Refresh various stats HTS_STAT.stat_nsocket = back_nsoc(sback); HTS_STAT.stat_errors = fspc(opt, NULL, "error"); HTS_STAT.stat_warnings = fspc(opt, NULL, "warning"); HTS_STAT.stat_infos = fspc(opt, NULL, "info"); HTS_STAT.nbk = backlinks_done(sback, opt->liens, opt->lien_tot, ptr); HTS_STAT.nb = back_transferred(HTS_STAT.stat_bytes, sback); if (!RUN_CALLBACK7 (opt, loop, sback->lnk, sback->count, b, ptr, opt->lien_tot, (int) (time_local() - HTS_STAT.stat_timestart), &HTS_STAT)) { hts_log_print(opt, LOG_ERROR, "Exit requested by shell or user"); *stre->exit_xh_ = 1; // exit requested XH_uninit; return; } Sleep(100); // pause } opt->state._hts_in_html_parsing = prev; } ENGINE_SAVE_CONTEXT(); return; } /* Wait for next file and check 301, 302, .. statuscodes (moved) */ int hts_mirror_wait_for_next_file(htsmoduleStruct * str, htsmoduleStructExtended * stre) { /* Load engine variables */ ENGINE_DEFINE_CONTEXT(); int b; int n; /* This is not supposed to hapen. */ if (heap(ptr)->pass2 == -1) { hts_log_print(opt, LOG_WARNING, "Link is already ready %s%s", urladr(), urlfil()); } /* User interaction */ ENGINE_SAVE_CONTEXT(); { hts_mirror_process_user_interaction(str, stre); } ENGINE_SET_CONTEXT(); /* Done while processing user interactions ? */ if (heap(ptr)->pass2 == -1) { hts_log_print(opt, LOG_DEBUG, "Link is now ready %s%s", urladr(), urlfil()); // We are ready return 2; // goto jump_if_done; } // si le fichier n'est pas en backing, le mettre.. if (!back_exist(str->sback, str->opt, urladr(), urlfil(), savename())) { #if BDEBUG==1 printf("crash backing: %s%s\n", heap(ptr)->adr, heap(ptr)->fil); #endif if (back_add (sback, opt, cache, urladr(), urlfil(), savename(), heap(heap(ptr)->precedent)->adr, heap(heap(ptr)->precedent)->fil, heap(ptr)->testmode) == -1) { printf("PANIC! : Crash adding error, unexpected error found.. [%d]\n", __LINE__); #if BDEBUG==1 printf("error while crash adding\n"); #endif hts_log_print(opt, LOG_ERROR, "Unexpected backing error for %s%s", urladr(), urlfil()); } } #if BDEBUG==1 printf("test number of socks\n"); #endif // ajouter autant de socket qu'on peut ajouter n = opt->maxsoc - back_nsoc(sback); #if BDEBUG==1 printf("%d sockets available for backing\n", n); #endif if ((n > 0) && (!opt->state._hts_setpause)) { // si sockets libre et pas en pause, ajouter // remplir autant que l'on peut le cache (backing) back_fillmax(sback, opt, cache, ptr, numero_passe); } // index du lien actuel { // ------------------------------------------------------------ // attendre que le fichier actuel soit prêt - BOUCLE D'ATTENTE do { /* User interaction */ ENGINE_SAVE_CONTEXT(); { hts_mirror_process_user_interaction(str, stre); } ENGINE_SET_CONTEXT(); // index du lien actuel b = back_index(opt, sback, urladr(), urlfil(), savename()); #if BDEBUG==1 printf("back index %d, waiting\n", b); #endif // Continue to the loop if link still present if (b < 0) break; // Receive data if (back[b].status > 0) back_wait(sback, opt, cache, HTS_STAT.stat_timestart); // Continue to the loop if link still present b = back_index(opt, sback, urladr(), urlfil(), savename()); if (b < 0) break; // Stop the mirror if (!back_checkmirror(opt)) { hts_log_print(opt, LOG_ERROR, "Exit requested by shell or user"); *stre->exit_xh_ = 1; // exit requested XH_uninit; return 0; } // And fill the backing stack if (back[b].status > 0) back_fillmax(sback, opt, cache, ptr, numero_passe); // Continue to the loop if link still present b = back_index(opt, sback, urladr(), urlfil(), savename()); if (b < 0) break; // autres occupations de HTTrack: statistiques, boucle d'attente, etc. if ((opt->makestat) || (opt->maketrack)) { TStamp l = time_local(); if ((int) (l - makestat_time) >= 60) { if (makestat_fp != NULL) { fspc(NULL, makestat_fp, "info"); fprintf(makestat_fp, "Rate= %d (/" LLintP ") \11NewLinks= %d (/%d)" LF, (int) ((HTS_STAT.HTS_TOTAL_RECV - *stre->makestat_total_) / (l - makestat_time)), (LLint) HTS_STAT.HTS_TOTAL_RECV, (int) opt->lien_tot - *stre->makestat_lnk_, (int) opt->lien_tot); fflush(makestat_fp); *stre->makestat_total_ = HTS_STAT.HTS_TOTAL_RECV; *stre->makestat_lnk_ = heap_top_index(); } if (stre->maketrack_fp != NULL) { int i; fspc(NULL, stre->maketrack_fp, "info"); fprintf(stre->maketrack_fp, LF); for(i = 0; i < back_max; i++) { back_info(sback, i, 3, stre->maketrack_fp); } fprintf(stre->maketrack_fp, LF); fflush(stre->maketrack_fp); } makestat_time = l; } } /* cancel links */ { int i; char *s; while((s = hts_cancel_file_pop(opt)) != NULL) { if (strnotempty(s)) { // fichier à canceller for(i = 0; i < back_max; i++) { if ((back[i].status > 0)) { if (strcmp(back[i].url_sav, s) == 0) { // ok trouvé if (back[i].status != 1000) { #if HTS_DEBUG_CLOSESOCK DEBUG_W("user cancel: deletehttp\n"); #endif if (back[i].r.soc != INVALID_SOCKET) deletehttp(&back[i].r); back[i].r.soc = INVALID_SOCKET; back[i].r.statuscode = STATUSCODE_INVALID; strcpybuff(back[i].r.msg, "Cancelled by User"); back[i].status = 0; // terminé back_set_finished(sback, i); } else // cancel ftp.. flag à 1 back[i].stop_ftp = 1; } } } s[0] = '\0'; } freet(s); } // Transfer rate engine_stats(); // Refresh various stats HTS_STAT.stat_nsocket = back_nsoc(sback); HTS_STAT.stat_errors = fspc(opt, NULL, "error"); HTS_STAT.stat_warnings = fspc(opt, NULL, "warning"); HTS_STAT.stat_infos = fspc(opt, NULL, "info"); HTS_STAT.nbk = backlinks_done(sback, opt->liens, opt->lien_tot, ptr); HTS_STAT.nb = back_transferred(HTS_STAT.stat_bytes, sback); if (!RUN_CALLBACK7 (opt, loop, sback->lnk, sback->count, b, ptr, opt->lien_tot, (int) (time_local() - HTS_STAT.stat_timestart), &HTS_STAT)) { hts_log_print(opt, LOG_ERROR, "Exit requested by shell or user"); *stre->exit_xh_ = 1; // exit requested XH_uninit; return 0; } } #if HTS_POLL if ((opt->shell) || (opt->keyboard) || (opt->verbosedisplay) || (!opt->quiet)) { TStamp tl; *stre->info_shell_ = 1; /* Toggle with ENTER */ if (!opt->quiet) { if (check_stdin()) { char com[256]; linput(stdin, com, 200); if (opt->verbosedisplay == 2) opt->verbosedisplay = 1; else opt->verbosedisplay = 2; /* Info for wrappers */ hts_log_print(opt, LOG_INFO, "engine: change-options"); RUN_CALLBACK0(opt, chopt); } } tl = time_local(); // générer un message d'infos sur l'état actuel if (opt->shell) { // si shell if ((tl - *stre->last_info_shell_) > 0) { // toute les 1 sec FILE *fp = stdout; int a = 0; *stre->last_info_shell_ = tl; if (fexist(fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-autopsy"))) { // débuggage: teste si le robot est vivant // (oui je sais un robot vivant.. mais bon.. il a le droit de vivre lui aussi) // (libérons les robots esclaves de l'internet!) remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-autopsy")); fp = fopen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-isalive"), "wb"); a = 1; } if ((*stre->info_shell_) || a) { int i, j; fprintf(fp, "TIME %d" LF, (int) (tl - HTS_STAT.stat_timestart)); fprintf(fp, "TOTAL %d" LF, (int) HTS_STAT.stat_bytes); fprintf(fp, "RATE %d" LF, (int) (HTS_STAT.HTS_TOTAL_RECV / (tl - HTS_STAT.stat_timestart))); fprintf(fp, "SOCKET %d" LF, back_nsoc(sback)); fprintf(fp, "LINK %d" LF, opt->lien_tot); { LLint mem = 0; for(i = 0; i < back_max; i++) if (back[i].r.adr != NULL) mem += back[i].r.size; fprintf(fp, "INMEM " LLintP "" LF, (LLint) mem); } for(j = 0; j < 2; j++) { // passes pour ready et wait for(i = 0; i < back_max; i++) { back_info(sback, i, j + 1, stdout); // maketrack_fp a la place de stdout ?? // ** } } fprintf(fp, LF); if (a) fclose(fp); io_flush; } } } // si shell } // si shell ou keyboard (option) // #endif } while((b >= 0) && (back[max(b, 0)].status > 0)); // If link not found on the stack, it's because it has already been downloaded // in background // Then, skip it and go to the next one if (b < 0) { hts_log_print(opt, LOG_DEBUG, "link #%d is ready, no more on the stack, skipping: %s%s..", ptr, urladr(), urlfil()); // prochain lien // ptr++; return 2; // goto jump_if_done; } #if 0 /* FIXME - finalized HAS NO MORE THIS MEANING */ /* link put in cache by the backing system for memory spare - reclaim */ else if (back[b].finalized) { assertf(back[b].r.adr == NULL); /* read file in cache */ back[b].r = cache_read_ro(opt, cache, back[b].url_adr, back[b].url_fil, back[b].url_sav, back[b].location_buffer); /* ensure correct location buffer set */ back[b].r.location = back[b].location_buffer; if (back[b].r.statuscode == STATUSCODE_INVALID) { hts_log_print(opt, LOG_ERROR, "Unexpected error: %s%s not found anymore in cache", back[b].url_adr, back[b].url_fil); } else { hts_log_print(opt, LOG_DEBUG, "reclaim file %s%s (%d)", back[b].url_adr, back[b].url_fil, back[b].r.statuscode); } } #endif if (!opt->verbosedisplay) { if (!opt->quiet) { static int roll = 0; /* static: ok */ roll = (roll + 1) % 4; printf("%c\x0d", ("/-\\|")[roll]); fflush(stdout); } } else if (opt->verbosedisplay == 1) { if (b >= 0) { if (back[b].r.statuscode == HTTP_OK) printf("%d/%d: %s%s (" LLintP " bytes) - OK\33[K\r", ptr, opt->lien_tot, back[b].url_adr, back[b].url_fil, (LLint) back[b].r.size); else printf("%d/%d: %s%s (" LLintP " bytes) - %d\33[K\r", ptr, opt->lien_tot, back[b].url_adr, back[b].url_fil, (LLint) back[b].r.size, back[b].r.statuscode); } else { hts_log_print(opt, LOG_ERROR, "Link disappeared"); } fflush(stdout); } //} // ------------------------------------------------------------ // Vérificateur d'intégrité #if DEBUG_CHECKINT _CHECKINT(&back[b], "Retour de back_wait, après le while") { int i; for(i = 0; i < back_max; i++) { char si[256]; sprintf(si, "Test global après back_wait, index %d", i); _CHECKINT(&back[i], si) } } #endif // copier structure réponse htsblk if (b >= 0) { memcpy(r, &(back[b].r), sizeof(htsblk)); r->location = stre->loc_; // ne PAS copier location!! adresse, pas de buffer if (back[b].r.location) strcpybuff(r->location, back[b].r.location); back[b].r.adr = NULL; // ne pas faire de desalloc ensuite // libérer emplacement backing back_maydelete(opt, cache, sback, b); } // débug graphique #if BDEBUG==2 { char s[12]; int i = 0; _GOTOXY(1, 1); printf("Rate=%d B/sec\n", (int) (HTS_STAT.HTS_TOTAL_RECV / (time_local() - HTS_STAT.stat_timestart))); while(i < minimum(back_max, 160)) { if (back[i].status > 0) { sprintf(s, "%d", back[i].r.size); } else if (back[i].status == STATUS_READY) { strcpybuff(s, "ENDED"); } else strcpybuff(s, " - "); while(strlen(s) < 8) strcatbuff(s, " "); printf("%s", s); io_flush; i++; } } #endif #if BDEBUG==1 printf("statuscode=%d with %s / msg=%s\n", r->statuscode, r->contenttype, r->msg); #endif } ENGINE_SAVE_CONTEXT(); return 0; } /* Wait for delayed types */ int hts_wait_delayed(htsmoduleStruct * str, lien_adrfilsave *afs, char *parent_adr, char *parent_fil, lien_adrfil *former, int *forbidden_url) { ENGINE_LOAD_CONTEXT_BASE(); hash_struct *const hash = hashptr; int in_error = 0; LLint in_error_size = 0; char in_error_msg[32]; // resolve unresolved type if (opt->savename_delayed != 0 && *forbidden_url == 0 && IS_DELAYED_EXT(afs->save) && !opt->state.stop) { int loops; int continue_loop; hts_log_print(opt, LOG_DEBUG, "Waiting for type to be known: %s%s", afs->af.adr, afs->af.fil); /* Follow while type is unknown and redirects occurs */ for(loops = 0, continue_loop = 1; IS_DELAYED_EXT(afs->save) && continue_loop && loops < 7; loops++) { continue_loop = 0; /* Wait for an available slot */ WAIT_FOR_AVAILABLE_SOCKET(); /* We can lookup directly in the cache to speedup this mess */ if (opt->delayed_cached) { lien_back back; memset(&back, 0, sizeof(back)); back.r = cache_read(opt, cache, afs->af.adr, afs->af.fil, NULL, NULL); // test uniquement if (back.r.statuscode == HTTP_OK && strnotempty(back.r.contenttype)) { // cache found, and aswer is 'OK' hts_log_print(opt, LOG_DEBUG, "Direct type lookup in cache (-%%D1): %s", back.r.contenttype); /* Recompute filename with MIME type */ afs->save[0] = '\0'; url_savename(afs, former, heap(ptr)->adr, heap(ptr)->fil, opt, sback, cache, hash, ptr, numero_passe, &back); /* Recompute authorization with MIME type */ { int new_forbidden_url = hts_acceptmime(opt, ptr, afs->af.adr, afs->af.fil, back.r.contenttype); if (new_forbidden_url != -1) { hts_log_print(opt, LOG_DEBUG, "result for wizard mime test: %d", new_forbidden_url); if (new_forbidden_url == 1) { *forbidden_url = new_forbidden_url; hts_log_print(opt, LOG_DEBUG, "link forbidden because of MIME types restrictions: %s%s", afs->af.adr, afs->af.fil); break; // exit loop } } } /* And exit loop */ break; } } /* Check if the file was recorded already (necessary for redirects) */ if (hash_read(hash, afs->save, NULL, HASH_STRUCT_FILENAME) >= 0) { if (loops == 0) { /* Should not happend */ hts_log_print(opt, LOG_ERROR, "Duplicate entry in hts_wait_delayed() cancelled: %s%s -> %s", afs->af.adr, afs->af.fil, afs->save); } /* Exit loop (we're done) */ continue_loop = 0; break; } /* Add in backing (back_index() will respond correctly) */ if (back_add_if_not_exists (sback, opt, cache, afs->af.adr, afs->af.fil, afs->save, parent_adr, parent_fil, 0) != -1) { int b; b = back_index(opt, sback, afs->af.adr, afs->af.fil, afs->save); if (b < 0) { printf("PANIC! : Crash adding error, unexpected error found.. [%d]\n", __LINE__); XH_uninit; // désallocation mémoire & buffers return -1; } /* We added the link before the parser recorded it -- the background download MUST NOT clean silently this entry! (Petr Gajdusek) */ back[b].early_add = 1; /* Cache read failed because file does not exist (bad delayed name!) Just re-add with the correct name, as we know the MIME now! */ if (back[b].r.statuscode == STATUSCODE_INVALID && back[b].r.adr == NULL) { lien_back delayed_back; //char BIGSTK delayed_ctype[128]; // delayed_ctype[0] = '\0'; // strncatbuff(delayed_ctype, back[b].r.contenttype, sizeof(delayed_ctype) - 1); // copier content-type back_copy_static(&back[b], &delayed_back); /* Delete entry */ back[b].r.statuscode = 0; /* TEMPORARY INVESTIGATE WHY WE FETCHED A SOCKET HERE */ back_maydelete(opt, cache, sback, b); // cancel b = -1; /* Recompute filename with MIME type */ afs->save[0] = '\0'; url_savename(afs, former, heap(ptr)->adr, heap(ptr)->fil, opt, sback, cache, hash, ptr, numero_passe, &delayed_back); /* Recompute authorization with MIME type */ { int new_forbidden_url = hts_acceptmime(opt, ptr, afs->af.adr, afs->af.fil, delayed_back.r.contenttype); if (new_forbidden_url != -1) { hts_log_print(opt, LOG_DEBUG, "result for wizard mime test: %d", *forbidden_url); if (new_forbidden_url == 1) { *forbidden_url = new_forbidden_url; hts_log_print(opt, LOG_DEBUG, "link forbidden because of MIME types restrictions: %s%s", afs->af.adr, afs->af.fil); break; // exit loop } } } /* Re-Add wiht correct type */ if (back_add_if_not_exists (sback, opt, cache, afs->af.adr, afs->af.fil, afs->save, parent_adr, parent_fil, 0) != -1) { b = back_index(opt, sback, afs->af.adr, afs->af.fil, afs->save); } if (b < 0) { printf ("PANIC! : Crash adding error, unexpected error found.. [%d]\n", __LINE__); XH_uninit; // désallocation mémoire & buffers return -1; } /* We added the link before the parser recorded it -- the background download MUST NOT clean silently this entry! (Petr Gajdusek) */ back[b].early_add = 1; hts_log_print(opt, LOG_DEBUG, "Type immediately loaded from cache: %s", delayed_back.r.contenttype); } /* Wait for headers to be received */ if (b >= 0) { back_set_locked(sback, b); // Locked entry } do { if (b < 0) break; // temps à attendre, et remplir autant que l'on peut le cache (backing) if (back[b].status > 0) { back_wait(sback, opt, cache, 0); } if (ptr >= 0) { back_fillmax(sback, opt, cache, ptr, numero_passe); } // on est obligé d'appeler le shell pour le refresh.. { // Transfer rate engine_stats(); // Refresh various stats HTS_STAT.stat_nsocket = back_nsoc(sback); HTS_STAT.stat_errors = fspc(opt, NULL, "error"); HTS_STAT.stat_warnings = fspc(opt, NULL, "warning"); HTS_STAT.stat_infos = fspc(opt, NULL, "info"); HTS_STAT.nbk = backlinks_done(sback, opt->liens, opt->lien_tot, ptr); HTS_STAT.nb = back_transferred(HTS_STAT.stat_bytes, sback); if (!RUN_CALLBACK7 (opt, loop, sback->lnk, sback->count, b, ptr, opt->lien_tot, (int) (time_local() - HTS_STAT.stat_timestart), &HTS_STAT)) { return -1; } else if (opt->state._hts_cancel || !back_checkmirror(opt)) { // cancel 2 ou 1 (cancel parsing) back_delete(opt, cache, sback, b); // cancel test break; } } } while( /* dns/connect/request */ (back[b].status >= 99 && back[b].status <= 101) || /* For redirects, wait for request to be terminated */ (HTTP_IS_REDIRECT(back[b].r.statuscode) && back[b].status > 0) || /* Same for errors */ (HTTP_IS_ERROR(back[b].r.statuscode) && back[b].status > 0) ); if (b >= 0) { back_set_unlocked(sback, b); // Unlocked entry } /* ready (chunked) or ready (regular download) or ready (completed) */ // Note: filename NOT in hashtable yet - liens_record will do it, with the correct ext! if (b >= 0) { lien_back delayed_back; //char BIGSTK delayed_ctype[128]; //delayed_ctype[0] = '\0'; //strncatbuff(delayed_ctype, back[b].r.contenttype, sizeof(delayed_ctype) - 1); // copier content-type back_copy_static(&back[b], &delayed_back); /* Error */ if (HTTP_IS_ERROR(back[b].r.statuscode)) { /* seen as in error */ in_error = back[b].r.statuscode; in_error_msg[0] = 0; strncat(in_error_msg, back[b].r.msg, sizeof(in_error_msg) - 1); in_error_size = back[b].r.totalsize; /* don't break, even with "don't take error pages" switch, because we need to process the slot anyway (and cache the error) */ } /* Moved! */ else if (HTTP_IS_REDIRECT(back[b].r.statuscode)) { char BIGSTK mov_url[HTS_URLMAXSIZE * 2]; mov_url[0] = '\0'; strcpybuff(mov_url, back[b].r.location); // copier URL /* Remove (temporarily created) file if it was created */ UNLINK(fconv(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), back[b].url_sav)); /* Remove slot! */ if (back[b].status == STATUS_READY) { back_maydelete(opt, cache, sback, b); } else { /* should not happend */ back_delete(opt, cache, sback, b); } b = -1; /* Handle redirect */ if (strnotempty(mov_url)) { // location existe! lien_adrfil moved; moved.adr[0] = moved.fil[0] = '\0'; // if (ident_url_relatif(mov_url, afs->af.adr, afs->af.fil, &moved) >= 0) { hts_log_print(opt, LOG_DEBUG, "Redirect while resolving type: %s%s -> %s%s", afs->af.adr, afs->af.fil, moved.adr, moved.fil); // si non bouclage sur soi même, ou si test avec GET non testé if (strcmp(moved.adr, afs->af.adr) != 0 || strcmp(moved.fil, afs->af.fil) != 0) { // recopier former->adr/fil? if (former != NULL) { if (strnotempty(former->adr) == 0) { // Pas déja noté strcpybuff(former->adr, afs->af.adr); strcpybuff(former->fil, afs->af.fil); } } // check explicit forbidden - don't follow 3xx in this case { int set_prio_to = 0; if (hts_acceptlink(opt, ptr, moved.adr, moved.fil, NULL, NULL, &set_prio_to, NULL) == 1) { /* forbidden */ /* Note: the cache 'cached_tests' system will remember this error, and we'll only issue ONE request */ *forbidden_url = 1; /* Forbidden! */ hts_log_print(opt, LOG_DEBUG, "link forbidden because of redirect beyond the mirror scope at %s%s -> %s%s", afs->af.adr, afs->af.fil, moved.adr, moved.fil); strcpybuff(afs->af.adr, moved.adr); strcpybuff(afs->af.fil, moved.fil); mov_url[0] = '\0'; break; } } // ftp: stop! if (strfield(mov_url, "ftp://")) { strcpybuff(afs->af.adr, moved.adr); strcpybuff(afs->af.fil, moved.fil); break; } /* ok, continue */ strcpybuff(afs->af.adr, moved.adr); strcpybuff(afs->af.fil, moved.fil); continue_loop = 1; /* Recompute filename for hash lookup */ afs->save[0] = '\0'; url_savename(afs, former, heap(ptr)->adr, heap(ptr)->fil, opt, sback, cache, hash, ptr, numero_passe, &delayed_back); } else { hts_log_print(opt, LOG_WARNING, "Unable to test %s%s (loop to same filename)", afs->af.adr, afs->af.fil); } // loop to same location } // ident_url_relatif() } // location } // redirect hts_log_print(opt, LOG_DEBUG, "Final type for %s%s: '%s'", afs->af.adr, afs->af.fil, delayed_back.r.contenttype); /* If we are done, do additional checks with final type and authorizations */ if (!continue_loop) { /* Recompute filename with MIME type */ afs->save[0] = '\0'; url_savename(afs, former, heap(ptr)->adr, heap(ptr)->fil, opt, sback, cache, hash, ptr, numero_passe, &delayed_back); /* Recompute authorization with MIME type */ { int new_forbidden_url = hts_acceptmime(opt, ptr, afs->af.adr, afs->af.fil, delayed_back.r.contenttype); if (new_forbidden_url != -1) { hts_log_print(opt, LOG_DEBUG, "result for wizard mime test: %d", *forbidden_url); if (new_forbidden_url == 1) { *forbidden_url = new_forbidden_url; hts_log_print(opt, LOG_DEBUG, "link forbidden because of MIME types restrictions: %s%s", afs->af.adr, afs->af.fil); break; // exit loop } } } } /* Still have a back reference */ if (b >= 0) { /* Finalize now as we have the type */ if (back[b].status == STATUS_READY) { if (!back[b].finalized) { hts_log_print(opt, LOG_TRACE, "finalizing as we have the type"); back_finalize(opt, cache, sback, b); } } /* Patch destination filename for direct-to-disk mode */ strcpybuff(back[b].url_sav, afs->save); } } // b >= 0 } else { printf("PANIC! : Crash adding error, unexpected error found.. [%d]\n", __LINE__); XH_uninit; // désallocation mémoire & buffers return -1; } } // while(IS_DELAYED_EXT(save)) if (in_error != 0) { /* 'no error page' selected or file discarded by size rules! */ if (!opt->errpage || (in_error == STATUSCODE_TOO_BIG)) { /* Note: the cache 'cached_tests' system will remember this error, and we'll only issue ONE request */ #if 0 /* No (3.43) - don't do that. We must not post-exclude an authorized link, because this will prevent the cache system from processing it, leading to refetch it endlessly. Just accept it, and handle the error as usual during parsing. */ *forbidden_url = 1; /* Forbidden! */ #endif if (in_error == STATUSCODE_TOO_BIG) { hts_log_print(opt, LOG_INFO, "link not taken because of its size (%d bytes) at %s%s", (int) in_error_size, afs->af.adr, afs->af.fil); } else { hts_log_print(opt, LOG_INFO, "link not taken because of error (%d '%s') at %s%s", in_error, in_error_msg, afs->af.adr, afs->af.fil); } } } // error if (*forbidden_url != 1 && IS_DELAYED_EXT(afs->save)) { *forbidden_url = 1; if (in_error) { hts_log_print(opt, LOG_WARNING, "link in error (%d '%s'), type unknown, aborting: %s%s", in_error, in_error_msg, afs->af.adr, afs->af.fil); } else { hts_log_print(opt, LOG_WARNING, "link is probably looping, type unknown, aborting: %s%s", afs->af.adr, afs->af.fil); } } } // delayed type check ? ENGINE_SAVE_CONTEXT_BASE(); return 0; } httrack-3.49.5/src/htscore.c0000644000175000017500000037563014360534067012625 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Main source */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* Internal engine bytecode */ #define HTS_INTERNAL_BYTECODE #include #include /* File defs */ #include "htscore.h" /* specific definitions */ #include "htsbase.h" #include "htsnet.h" #include "htsbauth.h" #include "htsmd5.h" #include "htsindex.h" /* external modules */ #include "htsmodules.h" // htswrap_add #include "htswrap.h" // parser #include "htsparse.h" /* Cache */ #include "htszlib.h" /* Charset handling */ #include "htscharset.h" /* Dynamic typed arrays */ #include "htsarrays.h" /* END specific definitions */ /* external modules */ extern int hts_parse_externals(htsmoduleStruct * str); extern void htspe_init(void); /* debug */ #if DEBUG_SHOWTYPES char REG[32768] = "\n"; #endif #if NSDEBUG int nsocDEBUG = 0; #endif // #define _CLRSCR printf("\33[m\33[2J"); #define _GOTOXY(X,Y) printf("\33[" X ";" Y "f"); #if DEBUG_CHECKINT #define _CHECKINT_FAIL(a) printf("\n%s\n",a); fflush(stdout); abort(); #define _CHECKINT(obj_ptr,message) \ if (obj_ptr) {\ if (( * ((char*) (obj_ptr)) != 0) || ( * ((char*) (((char*) (obj_ptr)) + sizeof(*(obj_ptr))-1)) != 0)) {\ char msg[1100];\ if (( * ((char*) (obj_ptr)) != 0) && ( * ((char*) (((char*) (obj_ptr)) + sizeof(*(obj_ptr))-1)) != 0))\ sprintf(msg,"* PANIC: Integrity error (structure crushed) in: %s",message);\ else if ( * ((char*) (obj_ptr)) != 0)\ sprintf(msg,"* PANIC: Integrity error (start of structure) in: %s",message);\ else\ sprintf(msg,"* PANIC: Integrity error (end of structure) in: %s",message);\ _CHECKINT_FAIL(msg);\ }\ } else {\ char msg[1100];\ sprintf(msg,"* PANIC: NULL pointer in: %s",message);\ _CHECKINT_FAIL(msg);\ } #endif #if DEBUG_HASH // longest hash chain? int longest_hash[3] = { 0, 0, 0 }, hashnumber = 0; #endif // Début de httpmirror, routines annexes // au cas où nous devons quitter rapidement xhttpmirror (plus de mémoire, etc) // note: partir de liens_max.. vers 0.. sinon erreur de violation de mémoire: les liens suivants // ne sont plus à nous.. agh! [dur celui-là] #define HTMLCHECK_UNINIT { \ hts_log_print(opt, LOG_INFO, "engine: end"); \ RUN_CALLBACK0(opt, end); \ } #define XH_extuninit do { \ HTMLCHECK_UNINIT \ hts_record_free(opt); \ if (filters && filters[0]) { \ freet(filters[0]); filters[0]=NULL; \ } \ if (filters) { \ freet(filters); filters=NULL; \ } \ back_delete_all(opt,&cache,sback); \ back_free(&sback); \ checkrobots_free(&robots);\ if (cache.use) { freet(cache.use); cache.use=NULL; } \ if (cache.dat) { fclose(cache.dat); cache.dat=NULL; } \ if (cache.ndx) { fclose(cache.ndx); cache.ndx=NULL; } \ if (cache.zipOutput) { \ zipClose(cache.zipOutput, "Created by HTTrack Website Copier/"HTTRACK_VERSION); \ cache.zipOutput = NULL; \ } \ if (cache.zipInput) { \ unzClose(cache.zipInput); \ cache.zipInput = NULL; \ } \ if (cache.olddat) { fclose(cache.olddat); cache.olddat=NULL; } \ if (cache.lst) { fclose(cache.lst); cache.lst=opt->state.strc.lst=NULL; } \ if (cache.txt) { fclose(cache.txt); cache.txt=NULL; } \ if (opt->log != NULL) fflush(opt->log); \ if (makestat_fp) { fclose(makestat_fp); makestat_fp=NULL; } \ if (maketrack_fp){ fclose(maketrack_fp); maketrack_fp=NULL; } \ if (opt->accept_cookie) cookie_save(opt->cookie,fconcat(OPT_GET_BUFF(opt),OPT_GET_BUFF_SIZE(opt),StringBuff(opt->path_log),"cookies.txt")); \ if (makeindex_fp) { fclose(makeindex_fp); makeindex_fp=NULL; } \ if (cache_hashtable) { coucal_delete(&cache_hashtable); } \ if (cache_tests) { coucal_delete(&cache_tests); } \ if (template_header) { freet(template_header); template_header=NULL; } \ if (template_body) { freet(template_body); template_body=NULL; } \ if (template_footer) { freet(template_footer); template_footer=NULL; } \ hash_free(&hash); \ clearCallbacks(&opt->state.callbacks); \ /*structcheck_init(-1);*/ \ } while(0) #define XH_uninit do { XH_extuninit; if (r.adr) { freet(r.adr); r.adr=NULL; } } while(0) struct lien_buffers { /* Main array of pointers. This is the real "lien_url **liens" pointer base. */ TypedArray(lien_url*) ptr; /* String pool, chunked. */ char *string_buffer; size_t string_buffer_size; size_t string_buffer_capa; TypedArray(char*) string_buffers; /* Structure list, chunked. */ lien_url *lien_buffer; size_t lien_buffer_size; size_t lien_buffer_capa; TypedArray(lien_url*) lien_buffers; }; // duplicate a string, or return NULL upon error (out-of-memory) static char* hts_record_link_strdup_(httrackp *opt, const char *s) { static const size_t block_capa = 32768; lien_buffers *const liensbuf = opt->liensbuf; const size_t len = strlen(s) + 1; /* including terminating \0 */ char *s_dup; assertf(liensbuf != NULL); assertf(len < block_capa); // not enough capacity ? then create a new chunk if (len + liensbuf->string_buffer_size > liensbuf->string_buffer_capa) { // backup current block pointer for later free if (liensbuf->string_buffer != NULL) { TypedArrayAdd(liensbuf->string_buffers, liensbuf->string_buffer); liensbuf->string_buffer = NULL; liensbuf->string_buffer_size = 0; } // Double capacity for each new chained block liensbuf->string_buffer_capa = liensbuf->string_buffer_capa < block_capa ? block_capa : liensbuf->string_buffer_capa * 2; liensbuf->string_buffer = malloct(liensbuf->string_buffer_capa); if (liensbuf->string_buffer == NULL) { hts_record_assert_memory_failed(liensbuf->string_buffer_capa); } liensbuf->string_buffer_size = 0; hts_log_print(opt, LOG_DEBUG, "reallocated %d new bytes of strings room", (int) liensbuf->string_buffer_capa); } assertf(len + liensbuf->string_buffer_size <= liensbuf->string_buffer_capa); s_dup = &liensbuf->string_buffer[liensbuf->string_buffer_size]; memcpy(s_dup, s, len); liensbuf->string_buffer_size += len; return s_dup; } static char* hts_record_link_strdup(httrackp *opt, const char *s) { assertf(opt != NULL); assertf(s != NULL); return hts_record_link_strdup_(opt, s); } size_t hts_record_link_latest(httrackp *opt) { lien_buffers *const liensbuf = opt->liensbuf; assertf(TypedArraySize(liensbuf->ptr) != 0); return TypedArraySize(liensbuf->ptr) - 1; } // returns a new zeroed lien_url entry, // or (size_t) -1 upon error (out-of-memory) // the returned index is the osset within opt->liens[] static size_t hts_record_link_alloc(httrackp *opt) { static const size_t block_capa = 256; lien_buffers *const liensbuf = opt->liensbuf; lien_url *link; assertf(opt != NULL); assertf(liensbuf != NULL); // Limit the number of links if (opt->maxlink > 0 && TypedArraySize(liensbuf->ptr) >= opt->maxlink) { return (size_t) -1; } // Create a new chunk of lien_url[] // There are references to item pointers, so we can not just realloc() if (liensbuf->lien_buffer_size == liensbuf->lien_buffer_capa) { size_t capa_bytes; if (liensbuf->lien_buffer != NULL) { TypedArrayAdd(liensbuf->lien_buffers, liensbuf->lien_buffer); liensbuf->lien_buffer_size = 0; } // Double capacity for each new chained block liensbuf->lien_buffer_capa = liensbuf->lien_buffer_capa < block_capa ? block_capa : liensbuf->lien_buffer_capa * 2; capa_bytes = liensbuf->lien_buffer_capa*sizeof(*liensbuf->lien_buffer); liensbuf->lien_buffer = (lien_url*) malloct(capa_bytes); if (liensbuf->lien_buffer == NULL) { hts_record_assert_memory_failed(capa_bytes); } liensbuf->lien_buffer_size = 0; hts_log_print(opt, LOG_DEBUG, "reallocated %d new link placeholders", (int) liensbuf->lien_buffer_capa); } // Take next lien_url item assertf(liensbuf->lien_buffer_size < liensbuf->lien_buffer_capa); link = &liensbuf->lien_buffer[liensbuf->lien_buffer_size++]; memset(link, 0, sizeof(*link)); // Add new lien_url pointer to the array of links TypedArrayAdd(liensbuf->ptr, link); // Ensure we have a guard NULL TypedArrayAdd(liensbuf->ptr, NULL); TypedArraySize(liensbuf->ptr)--; // Update pointer as it may have changed, // and update heap top index opt->liens = TypedArrayElts(liensbuf->ptr); assertf(TypedArraySize(liensbuf->ptr) != 0); assertf(TypedArraySize(liensbuf->ptr) < ( (unsigned int) -1 ) / 2); opt->lien_tot = (int) TypedArraySize(liensbuf->ptr); // return tail return hts_record_link_latest(opt); } void hts_record_init(httrackp *opt) { if (opt->liensbuf == NULL) { opt->liensbuf = calloct(sizeof(*opt->liensbuf), 1); if (opt->liensbuf == NULL) { hts_record_assert_memory_failed(sizeof(*opt->liensbuf)); } } } // wipe records void hts_record_free(httrackp *opt) { lien_buffers *const liensbuf = opt->liensbuf; if (liensbuf != NULL) { size_t i; TypedArrayFree(liensbuf->ptr); if (liensbuf->string_buffer != NULL) { freet(liensbuf->string_buffer); liensbuf->string_buffer = NULL; liensbuf->string_buffer_size = 0; liensbuf->string_buffer_capa = 0; } for(i = 0 ; i < TypedArraySize(liensbuf->string_buffers) ; i++) { freet(TypedArrayNth(liensbuf->string_buffers, i)); TypedArrayNth(liensbuf->string_buffers, i) = NULL; } TypedArrayFree(liensbuf->string_buffers); if (liensbuf->lien_buffer != NULL) { freet(liensbuf->lien_buffer); liensbuf->lien_buffer = NULL; } for(i = 0 ; i < TypedArraySize(liensbuf->lien_buffers) ; i++) { freet(TypedArrayNth(liensbuf->lien_buffers, i)); TypedArrayNth(liensbuf->lien_buffers, i) = NULL; } TypedArrayFree(liensbuf->lien_buffers); freet(opt->liensbuf); opt->liensbuf = NULL; } opt->liens = NULL; // no longer defined } // adds a new link and returns a non-zero value upon success static int hts_record_link_(httrackp * opt, const char *address, const char *file, const char *save, const char *ref_address, const char *ref_file, const char *codebase) { // create a new entry const size_t lien_tot = hts_record_link_alloc(opt); lien_url*const link = lien_tot != (size_t) -1 ? opt->liens[lien_tot] : NULL; if (link == NULL) { return 0; } // record string fields if ( (link->adr = hts_record_link_strdup(opt, address)) == NULL || (link->fil = hts_record_link_strdup(opt, file)) == NULL || (link->sav = hts_record_link_strdup(opt, save)) == NULL || (link->former_adr = hts_record_link_strdup(opt, ref_address)) == NULL || (link->former_fil = hts_record_link_strdup(opt, ref_file)) == NULL ) { return 0; } // record codebase for java classes if (codebase != NULL) { const size_t len = strlen(file); if (len > 6 && strncmp(&file[len - 6], ".class", 6) == 0) { if ((link->cod = hts_record_link_strdup(opt, codebase)) == NULL) { return 0; } } } // add entry in the hashtables hash_write(opt->hash, lien_tot); // success return 1; } int hts_record_link(httrackp * opt, const char *address, const char *file, const char *save, const char *ref_address, const char *ref_file, const char *codebase) { const int success = hts_record_link_(opt, address, file, save, ref_address, ref_file, codebase); if (!success) { hts_log_print(opt, LOG_PANIC, "Too many links (links=%ld, limit=%ld)", (long int) heap_top_index(), (long int) opt->maxlink); hts_log_print(opt, LOG_INFO, "To avoid that: use #L option for more links (example: -#L1000000, or -#L0 to disable)"); } return success; } void hts_invalidate_link(httrackp * opt, int lpos) { /* devalidate entry */ opt->liens[lpos]->pass2 = -1; } #define HT_INDEX_END do { \ if (!makeindex_done) { \ if (makeindex_fp) { \ char BIGSTK tempo[1024]; \ if (makeindex_links == 1) { \ char BIGSTK link_escaped[HTS_URLMAXSIZE*2]; \ escape_uri_utf(makeindex_firstlink, link_escaped, sizeof(link_escaped)); \ snprintf(tempo,sizeof(tempo),""CRLF, link_escaped); \ } else \ tempo[0]='\0'; \ hts_template_format(makeindex_fp,template_footer, \ "", \ tempo, /* EOF */ NULL \ ); \ fflush(makeindex_fp); \ fclose(makeindex_fp); /* à ne pas oublier sinon on passe une nuit blanche */ \ makeindex_fp=NULL; \ usercommand(opt,0,NULL,fconcat(OPT_GET_BUFF(opt),OPT_GET_BUFF_SIZE(opt),StringBuff(opt->path_html_utf8),"index.html"),"",""); \ } \ } \ makeindex_done=1; /* ok c'est fait */ \ } while(0) /* does it look like XML ? (SVG et al.) */ static int look_like_xml(const char *s) { return strncmp(s, "shell) { last_info_shell = HTS_STAT.stat_timestart; } if ((opt->makestat) || (opt->maketrack)) { makestat_time = HTS_STAT.stat_timestart; } // init external modules htspe_init(); // initialiser cookie if (opt->accept_cookie) { opt->cookie = &cookie; cookie.max_len = 30000; // max len strcpybuff(cookie.data, ""); // Charger cookies.txt par défaut ou cookies.txt du miroir cookie_load(opt->cookie, StringBuff(opt->path_log), "cookies.txt"); cookie_load(opt->cookie, "", "cookies.txt"); } else opt->cookie = NULL; // initialiser exit_xh opt->state.exit_xh = 0; // sortir prématurément (var globale) // initialiser usercommand usercommand(opt, opt->sys_com_exec, StringBuff(opt->sys_com), "", "", ""); // initialiser structcheck // structcheck_init(1); // initialiser verif_backblue verif_backblue(opt, NULL); verif_external(opt, 0, 0); verif_external(opt, 1, 0); // et templates html template_header = readfile_or(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_bin), "templates/index-header.html"), HTS_INDEX_HEADER); template_body = readfile_or(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_bin), "templates/index-body.html"), HTS_INDEX_BODY); template_footer = readfile_or(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_bin), "templates/index-footer.html"), HTS_INDEX_FOOTER); // initialiser mimedefs //get_userhttptype(opt,1,StringBuff(opt->mimedefs),NULL); // Initialiser indexation if (opt->kindex) index_init(StringBuff(opt->path_html)); // effacer bloc cache memset(&cache, 0, sizeof(cache_back)); cache.type = opt->cache; // cache? cache.errlog = cache.log = opt->log; // err log? cache.ptr_ant = cache.ptr_last = 0; // pointeur pour anticiper // initialiser hash cache cache_hashtable = coucal_new(0); cache_tests = coucal_new(0); if (cache_hashtable == NULL || cache_tests == NULL) { printf("PANIC! : Not enough memory [%d]\n", __LINE__); filters[0] = NULL; // uniquement a cause du warning de XH_extuninit XH_extuninit; return 0; } hts_set_hash_handler(cache_hashtable, opt); hts_set_hash_handler(cache_tests, opt); coucal_set_name(cache_hashtable, "cache_hashtable"); coucal_set_name(cache_tests, "cache_tests"); coucal_value_is_malloc(cache_tests, 1); /* malloc */ cache.hashtable = (void *) cache_hashtable; /* copy backcache hash */ cache.cached_tests = (void *) cache_tests; /* copy of cache_tests */ // robots.txt strcpybuff(robots.adr, "!"); // dummy robots.token[0] = '\0'; robots.next = NULL; // suivant opt->robotsptr = &robots; // effacer filters opt->maxfilter = maximum(opt->maxfilter, 128); if (filters_init(&filters, opt->maxfilter, 0) == 0) { printf("PANIC! : Not enough memory [%d]\n", __LINE__); XH_extuninit; return 0; } opt->filters.filters = &filters; // opt->filters.filptr = &filptr; //opt->filters.filter_max=&filter_max; // hash table opt->hash = &hash; // initialize link heap hts_record_init(opt); // initialiser ptr et lien_tot ptr = 0; // initialiser hachage hash_init(opt, &hash, opt->urlhack); // note: we need a cast because of the const hash.liens = (const lien_url *const*const*) &opt->liens; // copier adresse(s) dans liste des adresses { char *a = url1; int primary_len = 8192; if (StringNotEmpty(opt->filelist)) { primary_len += max(0, fsize(StringBuff(opt->filelist)) * 2); } primary_len += (int) strlen(url1) * 2; // création de la première page, qui contient les liens de base à scanner // c'est plus propre et plus logique que d'entrer à la main les liens dans la pile // on bénéficie ainsi des vérifications et des tests du robot pour les liens "primaires" primary = (char *) malloct(primary_len); if (primary) { primary[0] = '\0'; } else { printf("PANIC! : Not enough memory [%d]\n", __LINE__); XH_extuninit; return 0; } while(*a) { int i; int joker = 0; // vérifier qu'il n'y a pas de * dans l'url if (*a == '+') joker = 1; else if (*a == '-') joker = 1; if (joker) { // joker ou filters //char* p; char BIGSTK tempo[HTS_URLMAXSIZE * 2]; int type; int plus = 0; // noter joker (dans b) if (*a == '+') { // champ + type = 1; plus = 1; a++; } else if (*a == '-') { // champ forbidden[] type = 0; a++; } else { // champ + avec joker sans doute type = 1; } // recopier prochaine chaine (+ ou -) i = 0; while((*a != 0) && (!isspace((unsigned char) *a))) { tempo[i++] = *a; a++; } tempo[i++] = '\0'; while(isspace((unsigned char) *a)) { a++; } // sauter les + sans rien après.. if (strnotempty(tempo)) { if ((plus == 0) && (type == 1)) { // implicite: *www.edf.fr par exemple if (tempo[strlen(tempo) - 1] != '*') { strcatbuff(tempo, "*"); // ajouter un * } } if (type) strcpybuff(filters[filptr], "+"); else strcpybuff(filters[filptr], "-"); strcatbuff(filters[filptr], tempo); filptr++; /* sanity check */ if (filptr + 1 >= opt->maxfilter) { opt->maxfilter += HTS_FILTERSINC; if (filters_init(&filters, opt->maxfilter, HTS_FILTERSINC) == 0) { printf("PANIC! : Too many filters : >%d [%d]\n", filptr, __LINE__); hts_log_print(opt, LOG_PANIC, "Too many filters, giving up..(>%d)", filptr); hts_log_print(opt, LOG_NOTICE, "To avoid that: use #F option for more filters (example: -#F5000)"); XH_extuninit; return 0; } //opt->filters.filters=filters; } } } else { // adresse normale char BIGSTK url[HTS_URLMAXSIZE * 2]; // prochaine adresse i = 0; while((*a != 0) && (!isspace((unsigned char) *a))) { url[i++] = *a; a++; } while(isspace((unsigned char) *a)) { a++; } url[i++] = '\0'; //strcatbuff(primary,""); strcatbuff(primary, "\n"); } } // while /* load URL file list */ /* OPTIMIZED for fast load */ if (StringNotEmpty(opt->filelist)) { char *filelist_buff = NULL; const size_t filelist_sz = off_t_to_size_t(fsize(StringBuff(opt->filelist))); if (filelist_sz != (size_t) -1) { FILE *fp = fopen(StringBuff(opt->filelist), "rb"); if (fp) { filelist_buff = malloct(filelist_sz + 1); if (filelist_buff) { if (fread(filelist_buff, 1, filelist_sz, fp) != filelist_sz) { freet(filelist_buff); filelist_buff = NULL; } else { *(filelist_buff + filelist_sz) = '\0'; } } fclose(fp); } } if (filelist_buff) { int filelist_ptr = 0; int n = 0; char BIGSTK line[HTS_URLMAXSIZE * 2]; char *primary_ptr = primary + strlen(primary); while(filelist_ptr < filelist_sz) { int count = binput(filelist_buff + filelist_ptr, line, HTS_URLMAXSIZE); filelist_ptr += count; if (count && line[0]) { n++; if (strstr(line, ":/") == NULL) { strcpybuff(primary_ptr, "http://"); primary_ptr += strlen(primary_ptr); } strcpybuff(primary_ptr, line); primary_ptr += strlen(primary_ptr); strcpybuff(primary_ptr, "\n"); primary_ptr += 1; } } // fclose(fp); hts_log_print(opt, LOG_NOTICE, "%d links added from %s", n, StringBuff(opt->filelist)); // Free buffer freet(filelist_buff); } else { hts_log_print(opt, LOG_ERROR, "Could not include URL list: %s", StringBuff(opt->filelist)); } } // lien primaire if (!hts_record_link(opt, "primary", "/primary", fslash(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_html_utf8), "index.html")), "", "", NULL)) { XH_extuninit; // désallocation mémoire & buffers return 0; } heap_top()->testmode = 0; // pas mode test heap_top()->link_import = 0; // pas mode import heap_top()->depth = opt->depth + 1; // lien de priorité maximale heap_top()->pass2 = 0; // 1ère passe heap_top()->retry = opt->retry; // lien de priorité maximale heap_top()->premier = heap_top_index(); // premier lien, objet-père=objet heap_top()->precedent = heap_top_index(); // lien précédent // Initialiser cache { opt->state._hts_in_html_parsing = 4; if (!RUN_CALLBACK7(opt, loop, NULL, 0, 0, 0, opt->lien_tot, 0, NULL)) { opt->state.exit_xh = 1; // exit requested } cache_init(&cache, opt); opt->state._hts_in_html_parsing = 0; } } #if BDEBUG==3 { int i; for(i = 0; i < lien_tot; i++) { printf("%d>%s%s as %s\n", i, heap(i)->adr, heap(i)->fil, heap(i)->sav); } for(i = 0; i < filptr; i++) { printf("%d>filters=%s\n", i, filters[i]); } } #endif // backing //soc_max=opt->maxsoc; if (opt->maxsoc > 0) { #if BDEBUG==2 _CLRSCR; #endif // Nombre de fichiers HTML pouvant être présents en mémoire de manière simultannée // On prévoit large: les fichiers HTML ne prennent que peu de place en mémoire, et les // fichiers non html sont sauvés en direct sur disque. // --> 1024 entrées + 32 entrées par socket en supplément sback = back_new(opt, opt->maxsoc * 32 + 1024); if (sback == NULL) { hts_log_print(opt, LOG_PANIC, "Not enough memory, can not allocate %d bytes", (int) ((opt->maxsoc + 1) * sizeof(lien_back))); return 0; } } // statistiques if (opt->makestat) { makestat_fp = fopen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-stats.txt"), "wb"); if (makestat_fp != NULL) { fprintf(makestat_fp, "HTTrack statistics report, every minutes" LF LF); fflush(makestat_fp); } } // tracking -- débuggage if (opt->maketrack) { maketrack_fp = fopen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-track.txt"), "wb"); if (maketrack_fp != NULL) { fprintf(maketrack_fp, "HTTrack tracking report, every minutes" LF LF); fflush(maketrack_fp); } } // on n'a pas de liens!! (exemple: httrack www.* impossible sans départ..) if (opt->lien_tot <= 0) { hts_log_print(opt, LOG_ERROR, "You MUST specify at least one complete URL, and not only wildcards!"); } /* Send options to callback functions */ RUN_CALLBACK0(opt, chopt); // attendre une certaine heure.. if (opt->waittime > 0) { int rollover = 0; int ok = 0; { TStamp tl = 0; time_t tt; struct tm *A; tt = time(NULL); A = localtime(&tt); tl += A->tm_sec; tl += A->tm_min * 60; tl += A->tm_hour * 60 * 60; if (tl > opt->waittime) // attendre minuit rollover = 1; } // attendre.. opt->state._hts_in_html_parsing = 5; do { TStamp tl = 0; time_t tt; struct tm *A; tt = time(NULL); A = localtime(&tt); tl += A->tm_sec; tl += A->tm_min * 60; tl += A->tm_hour * 60 * 60; if (rollover) { if (tl <= opt->waittime) rollover = 0; // attendre heure } else { if (tl > opt->waittime) ok = 1; // ok! } { int r; if (rollover) r = RUN_CALLBACK7(opt, loop, sback->lnk, sback->count, 0, 0, opt->lien_tot, (int) (opt->waittime - tl + 24 * 3600), NULL); else r = RUN_CALLBACK7(opt, loop, sback->lnk, sback->count, 0, 0, opt->lien_tot, (int) (opt->waittime - tl), NULL); if (!r) { opt->state.exit_xh = 1; // exit requested ok = 1; } else Sleep(100); } } while(!ok); opt->state._hts_in_html_parsing = 0; // note: recopie de plus haut // noter heure actuelle de départ en secondes HTS_STAT.stat_timestart = time_local(); if (opt->shell) { last_info_shell = HTS_STAT.stat_timestart; } if ((opt->makestat) || (opt->maketrack)) { makestat_time = HTS_STAT.stat_timestart; } } /* Info for wrappers */ hts_log_print(opt, LOG_INFO, "engine: start"); if (!RUN_CALLBACK0(opt, start)) { XH_extuninit; return 1; } // ------------------------------------------------------------ // ------------------------------------------------------------ // Boucle générale de parcours des liens // ------------------------------------------------------------ do { int error = 0; // si error alors sauter int store_errpage = 0; // c'est une erreur mais on enregistre le html int is_binary = 0; // is a binary file int is_loaded_from_file = 0; // has been loaded from a file (implies is_write=1) char BIGSTK loc[HTS_URLMAXSIZE * 2]; // adresse de relocation // Ici on charge le fichier (html, gif..) en mémoire // Les HTMLs sont traités (si leur priorité est suffisante) // effacer r hts_init_htsblk(&r); //memset(&r, 0, sizeof(htsblk)); r.soc=INVALID_SOCKET; r.location = loc; // en cas d'erreur 3xx (moved) // recopier proxy if ((r.req.proxy.active = opt->proxy.active)) { if (StringBuff(opt->proxy.bindhost) != NULL) r.req.proxy.bindhost = StringBuff(opt->proxy.bindhost); if (StringBuff(opt->proxy.name) != NULL) r.req.proxy.name = StringBuff(opt->proxy.name); r.req.proxy.port = opt->proxy.port; } // et user-agent r.req.user_agent = StringBuff(opt->user_agent); r.req.referer = StringBuff(opt->referer); r.req.from = StringBuff(opt->from); r.req.lang_iso = StringBuff(opt->lang_iso); r.req.accept = StringBuff(opt->accept); r.req.headers = StringBuff(opt->headers); r.req.user_agent_send = opt->user_agent_send; if (!error) { // Skip empty/invalid/done in background if (heap(ptr)) { while(ptr < opt->lien_tot && (heap(ptr)) && ((((urladr() != NULL) ? (urladr()) : (" "))[0] == '!') || (((urlfil() != NULL) ? (urlfil()) : (" "))[0] == '\0') || ((heap(ptr)->pass2 == -1)) ) ) { // sauter si lien annulé (ou fil vide) if (heap(ptr) != NULL && heap(ptr)->pass2 == -1) { hts_log_print(opt, LOG_DEBUG, "link #%d is ready, skipping: %s%s..", ptr, ((urladr() != NULL) ? (urladr()) : (" ")), ((urlfil() != NULL) ? (urlfil()) : (" "))); } else { hts_log_print(opt, LOG_DEBUG, "link #%d seems ready, skipping: %s%s..", ptr, ((urladr() != NULL) ? (urladr()) : (" ")), ((urlfil() != NULL) ? (urlfil()) : (" "))); } // remove from stats if (heap(ptr)->pass2 == -1) { HTS_STAT.stat_background--; } ptr++; } // We're done! if (ptr == opt->lien_tot) { goto jump_if_done; } } if (heap(ptr) != NULL) { // on a qq chose à récupérer? hts_log_print(opt, LOG_DEBUG, "Wait get: %s%s", urladr(), urlfil()); #if DEBUG_ROBOTS if (strcmp(urlfil(), "/robots.txt") == 0) { printf("robots.txt detected\n"); } #endif // ------------------------------------------------------------ // DEBUT --RECUPERATION LIEN--- if (ptr == 0) { // premier lien à parcourir: lien primaire construit avant r.adr = primary; primary = NULL; r.statuscode = HTTP_OK; r.size = strlen(r.adr); r.soc = INVALID_SOCKET; strcpybuff(r.contenttype, "text/html"); /*} else if (opt->maxsoc<=0) { // fichiers 1 à 1 en attente (pas de backing) // charger le fichier en mémoire tout bêtement r=xhttpget(urladr(),urlfil()); // */ } else { // backing, multiples sockets /* ************************************** Get the next link, waiting for other files, handling external callbacks */ { char BIGSTK buff_err_msg[1024]; htsmoduleStruct BIGSTK str; htsmoduleStructExtended BIGSTK stre; buff_err_msg[0] = '\0'; memset(&str, 0, sizeof(str)); memset(&stre, 0, sizeof(stre)); /* */ str.err_msg = buff_err_msg; str.filename = savename(); str.mime = r.contenttype; str.url_host = urladr(); str.url_file = urlfil(); str.size = (const int) r.size; /* */ str.addLink = htsAddLink; /* */ str.opt = opt; str.sback = sback; str.cache = &cache; str.hashptr = hashptr; str.numero_passe = numero_passe; /* */ str.ptr_ = &ptr; /* */ str.page_charset_ = NULL; /* */ /* */ stre.r_ = &r; /* */ stre.error_ = &error; stre.exit_xh_ = &opt->state.exit_xh; stre.store_errpage_ = &store_errpage; /* */ stre.base = base; stre.codebase = codebase; /* */ stre.filters_ = &filters; stre.filptr_ = &filptr; stre.robots_ = &robots; stre.hash_ = &hash; /* */ stre.makeindex_done_ = &makeindex_done; stre.makeindex_fp_ = &makeindex_fp; stre.makeindex_links_ = &makeindex_links; stre.makeindex_firstlink_ = makeindex_firstlink; /* */ stre.template_header_ = template_header; stre.template_body_ = template_body; stre.template_footer_ = template_footer; /* */ stre.stat_fragment_ = &stat_fragment; stre.makestat_time = makestat_time; stre.makestat_fp = makestat_fp; stre.makestat_total_ = &makestat_total; stre.makestat_lnk_ = &makestat_lnk; stre.maketrack_fp = maketrack_fp; /* FUNCTION DEPENDANT */ stre.loc_ = loc; stre.last_info_shell_ = &last_info_shell; stre.info_shell_ = &info_shell; /* Parse */ switch (hts_mirror_wait_for_next_file(&str, &stre)) { case -1: XH_uninit; return -1; break; case 2: // Jump to 'continue' // This is one of the very very rare cases where goto // is acceptable // A supplemental flag and if( ) { } would be really messy goto jump_if_done; } } } // FIN --RECUPERATION LIEN--- // ------------------------------------------------------------ } else { // lien vide.. hts_log_print(opt, LOG_WARNING, "Warning, link #%d empty", ptr); error = 1; goto jump_if_done; } // test si url existe (non vide!) // ---tester taille a posteriori--- // tester r.adr if (!error) { // erreur, pas de fichier chargé: if ((!r.adr) && (r.is_write == 0) && (r.statuscode != 301) && (r.statuscode != 302) && (r.statuscode != 303) && (r.statuscode != 307) && (r.statuscode != 412) && (r.statuscode != 416) ) { // error=1; // peut être que le fichier était trop gros? if ((istoobig (opt, r.totalsize, opt->maxfile_html, opt->maxfile_nonhtml, r.contenttype)) || (istoobig (opt, r.totalsize, opt->maxfile_html, opt->maxfile_nonhtml, r.contenttype))) { error = 0; hts_log_print(opt, LOG_WARNING, "Big file cancelled according to user's preferences: %s%s", urladr(), urlfil()); } // // // error=1; // ne pas traiter la suite -- euhh si finalement.. } } // ---fin tester taille a posteriori--- // -------------------- // BOGUS MIME TYPE HACK // Check if we have a bogus MIME type // example: // Content-type="text/html" // and // Content-disposition="foo.jpg" // -------------------- if (!error) { if (r.statuscode == HTTP_OK) { // OK (ou 304 en backing) if (r.adr) { // Written file // Buggy SVG (Smiling Spectre) if (strcmp(r.contenttype, "image/svg+xml") == 0 && !look_like_xml(r.adr)) { // patch it strcpybuff(r.contenttype, "application/octet-stream"); is_binary = 1; } else if ((is_hypertext_mime(opt, r.contenttype, urlfil())) /* Is HTML or Js, .. */ /* NO - real media is real media, not HTML */ /*|| (may_be_hypertext_mime(r.contenttype, urlfil()) && (r.adr) ) */ /* Is real media, .. */ ) { if (strnotempty(r.cdispo)) { // Content-disposition set! if (ishtml(opt, savename()) == 0) { // Non HTML!! // patch it! strcpybuff(r.contenttype, "application/octet-stream"); } } } } } /* Load file if necessary and decode. */ #define LOAD_IN_MEMORY_IF_NECESSARY() do { \ if ( \ may_be_hypertext_mime(opt,r.contenttype, urlfil()) /* Is HTML or Js, .. */ \ && (heap(ptr)->depth>0) /* Depth > 0 (recurse depth) */ \ && (r.adr==NULL) /* HTML Data exists */ \ && (!store_errpage) /* Not an html error page */ \ && (savename()[0]!='\0') /* Output filename exists */ \ ) \ { \ is_loaded_from_file = 1; \ r.adr = readfile2(savename(), &r.size); \ if (r.adr != NULL) { \ hts_log_print(opt, LOG_INFO, "File successfully loaded for parsing: %s%s (%d bytes)",urladr(),urlfil(),(int)r.size); \ } else { \ hts_log_print(opt, LOG_ERROR, "File could not be loaded for parsing: %s%s",urladr(),urlfil()); \ } \ } \ } while(0) /* Load file and decode if necessary, before content-binary check. (3.43) */ LOAD_IN_MEMORY_IF_NECESSARY(); // ------------------------------------ // BOGUS MIME TYPE HACK II (the revenge) // Check if we have a bogus MIME type if (HTTP_IS_OK(r.statuscode) && (is_hypertext_mime(opt, r.contenttype, urlfil()) /* Is HTML or Js, .. */ ||may_be_hypertext_mime(opt, r.contenttype, urlfil())) /* Is real media, .. */ ) { /* Convert charset to UTF-8 - NOT! (what about links ? remote server side will have troubles with converted names) */ //if (r.adr != NULL && r.size != 0 && opt->convert_utf8) { // char *charset; // char *pos; // if (r.charset[0] != '\0') { // charset = strdup(r.charset); // } else { // charset = hts_getCharsetFromMeta(r.adr, r.size); // } // if (charset != NULL) { // char *const utf8 = hts_convertStringToUTF8(r.adr, r.size, charset); // /* Use new buffer */ // if (utf8 != NULL) { // freet(r.adr); // r.size = strlen(utf8); // r.adr = utf8; // /* New UTF-8 charset */ // r.charset[0] = '\0'; // strcpy(r.charset, "utf-8"); // } // /* Free charset */ // free(charset); // } //} /* Check bogus chars */ if ((r.adr) && (r.size)) { unsigned int map[256]; int i; unsigned int nspec = 0; map_characters((unsigned char *) r.adr, (unsigned int) r.size, &map[0]); for(i = 1; i < 32; i++) { // null chars ignored.. if (!is_realspace(i) && i != 27 /* Damn you ISO2022-xx! */ ) { nspec += map[i]; } } /* On-the-fly UCS2 to UTF-8 conversion (note: UCS2 should never be used on the net) */ if (map[0] > r.size / 10 && r.size % 2 == 0 && ((((unsigned char) r.adr[0]) == 0xff && ((unsigned char) r.adr[1]) == 0xfe) || (((unsigned char) r.adr[0]) == 0xfe && ((unsigned char) r.adr[1]) == 0xff) ) ) { #define CH_ADD(c) do { \ if (new_offs + 1 > new_capa) { \ new_capa *= 2; \ new_adr = (unsigned char*) realloct(new_adr, \ new_capa); \ assertf(new_adr != NULL); \ } \ new_adr[new_offs++] = (unsigned char) (c); \ } while(0) #define CH_ADD_RNG1(c, r, o) do { \ CH_ADD( (c) / (r) + (o) ); \ c = (c) % (r); \ } while(0) #define CH_ADD_RNG0(c, o) do { \ CH_ADD_RNG1(c, 1, o); \ } while(0) #define CH_ADD_RNG2(c, r, r2, o) do { \ CH_ADD_RNG1(c, (r) * (r2), o); \ } while(0) int new_capa = (int) (r.size / 2 + 1); int new_offs = 0; unsigned char *prev_adr = (unsigned char *) r.adr; unsigned char *new_adr = (unsigned char *) malloct(new_capa); int i; int swap = (((unsigned char) r.adr[0]) == 0xff); assertf(new_adr != NULL); /* See http://www.unicode.org/reports/tr28/tr28-3.html#conformance U+0000..U+007F 00..7F U+0080..U+07FF C2..DF 80..BF U+0800..U+0FFF E0 A0..BF 80..BF U+1000..U+CFFF E1..EC 80..BF 80..BF U+D000..U+D7FF ED 80..9F 80..BF U+D800..U+DFFF U+E000..U+FFFF EE..EF 80..BF 80..BF */ for(i = 0; i < r.size / 2; i++) { unsigned short int unic = 0; if (swap) unic = prev_adr[i * 2] + (prev_adr[i * 2 + 1] << 8); else unic = (prev_adr[i * 2] << 8) + prev_adr[i * 2 + 1]; if (unic <= 0x7F) { /* U+0000..U+007F 00..7F */ CH_ADD_RNG0(unic, 0x00); } else if (unic <= 0x07FF) { /* U+0080..U+07FF C2..DF 80..BF */ unic -= 0x0080; CH_ADD_RNG1(unic, 0xbf - 0x80 + 1, 0xc2); CH_ADD_RNG0(unic, 0x80); } else if (unic <= 0x0FFF) { /* U+0800..U+0FFF E0 A0..BF 80..BF */ unic -= 0x0800; CH_ADD_RNG2(unic, 0xbf - 0x80 + 1, 0xbf - 0xa0 + 1, 0xe0); CH_ADD_RNG1(unic, 0xbf - 0x80 + 1, 0xa0); CH_ADD_RNG0(unic, 0x80); } else if (unic <= 0xCFFF) { /* U+1000..U+CFFF E1..EC 80..BF 80..BF */ unic -= 0x1000; CH_ADD_RNG2(unic, 0xbf - 0x80 + 1, 0xbf - 0x80 + 1, 0xe1); CH_ADD_RNG1(unic, 0xbf - 0x80 + 1, 0x80); CH_ADD_RNG0(unic, 0x80); } else if (unic <= 0xD7FF) { /* U+D000..U+D7FF ED 80..9F 80..BF */ unic -= 0xD000; CH_ADD_RNG2(unic, 0xbf - 0x80 + 1, 0x9f - 0x80 + 1, 0xed); CH_ADD_RNG1(unic, 0xbf - 0x80 + 1, 0x80); CH_ADD_RNG0(unic, 0x80); } else if (unic <= 0xDFFF) { /* U+D800..U+DFFF */ CH_ADD('?'); /* ill-formed */ } else { /* if (unic <= 0xFFFF) */ /* U+E000..U+FFFF EE..EF 80..BF 80..BF */ unic -= 0xE000; CH_ADD_RNG2(unic, 0xbf - 0x80 + 1, 0xbf - 0x80 + 1, 0xee); CH_ADD_RNG1(unic, 0xbf - 0x80 + 1, 0x80); CH_ADD_RNG0(unic, 0x80); } } hts_log_print(opt, LOG_WARNING, "File %s%s converted from UCS2 to UTF-8 (old size: %d bytes, new size: %d bytes)", urladr(), urlfil(), (int) r.size, new_offs); freet(r.adr); r.adr = NULL; r.size = new_offs; CH_ADD(0); r.adr = (char *) new_adr; #undef CH_ADD #undef CH_ADD_RNG0 #undef CH_ADD_RNG1 #undef CH_ADD_RNG2 } else if ((nspec > r.size / 100) && (nspec > 10)) { // too many special characters is_binary = 1; strcpybuff(r.contenttype, "application/octet-stream"); hts_log_print(opt, LOG_WARNING, "File not parsed, looks like binary: %s%s", urladr(), urlfil()); } /* This hack allows you to avoid problems with parsing '\0' characters */ if (!is_binary) { for(i = 0; i < r.size; i++) { if (r.adr[i] == '\0') r.adr[i] = ' '; } } } } } // MOVED IN back_finalize() // // -------------------- // REAL MEDIA HACK // Check if we have to load locally the file // -------------------- //if (!error) { // if (r.statuscode == HTTP_OK) { // OK (ou 304 en backing) // if (r.adr==NULL) { // Written file // if (may_be_hypertext_mime(r.contenttype, urlfil())) { // to parse! // LLint sz; // sz=fsize_utf8(savename()); // if (sz>0) { // ok, exists! // if (sz < 8192) { // ok, small file --> to parse! // FILE* fp=FOPEN(savename(),"rb"); // if (fp) { // r.adr=malloct(sz + 1); // if (r.adr) { // if (fread(r.adr,1,sz,fp) == sz) { // r.size=sz; // r.adr[sz] = '\0'; // r.is_write = 0; // } else { // freet(r.adr); // r.size=0; // r.adr = NULL; // r.statuscode=STATUSCODE_INVALID; // strcpybuff(r.msg, ".RAM read error"); // } // fclose(fp); // fp=NULL; // // remove (temporary) file! // remove(savename()); // } // if (fp) // fclose(fp); // } // } // } // } // } // } //} // EN OF REAL MEDIA HACK // ---stockage en cache--- // stocker dans le cache? /* if (!error) { if (ptr>0) { if (heap(ptr)) { xxcache_mayadd(opt,&cache,&r,urladr(),urlfil(),savename()); } else error=1; } } */ // ---fin stockage en cache--- /* ************************************** Check "Moved permanently" and other similar errors, retrying URLs if necessary and handling redirect pages. */ if (!error) { char BIGSTK buff_err_msg[1024]; htsmoduleStruct BIGSTK str; htsmoduleStructExtended BIGSTK stre; buff_err_msg[0] = '\0'; memset(&str, 0, sizeof(str)); memset(&stre, 0, sizeof(stre)); /* */ str.err_msg = buff_err_msg; str.filename = savename(); str.mime = r.contenttype; str.url_host = urladr(); str.url_file = urlfil(); str.size = (int) r.size; /* */ str.addLink = htsAddLink; /* */ str.opt = opt; str.sback = sback; str.cache = &cache; str.hashptr = hashptr; str.numero_passe = numero_passe; /* */ str.ptr_ = &ptr; /* */ str.page_charset_ = NULL; /* */ /* */ stre.r_ = &r; /* */ stre.error_ = &error; stre.exit_xh_ = &opt->state.exit_xh; stre.store_errpage_ = &store_errpage; /* */ stre.base = base; stre.codebase = codebase; /* */ stre.filters_ = &filters; stre.filptr_ = &filptr; stre.robots_ = &robots; stre.hash_ = &hash; /* */ stre.makeindex_done_ = &makeindex_done; stre.makeindex_fp_ = &makeindex_fp; stre.makeindex_links_ = &makeindex_links; stre.makeindex_firstlink_ = makeindex_firstlink; /* */ stre.template_header_ = template_header; stre.template_body_ = template_body; stre.template_footer_ = template_footer; /* */ stre.stat_fragment_ = &stat_fragment; stre.makestat_time = makestat_time; stre.makestat_fp = makestat_fp; stre.makestat_total_ = &makestat_total; stre.makestat_lnk_ = &makestat_lnk; stre.maketrack_fp = maketrack_fp; /* Parse */ if (hts_mirror_check_moved(&str, &stre) != 0) { XH_uninit; return -1; } } } // if !error if (!error) { #if DEBUG_SHOWTYPES if (strstr(REG, r.contenttype) == NULL) { strcatbuff(REG, r.contenttype); strcatbuff(REG, "\n"); printf("%s\n", r.contenttype); io_flush; } #endif /* Load file and decode if necessary, after redirect check. */ LOAD_IN_MEMORY_IF_NECESSARY(); // ------------------------------------------------------ // ok, fichier chargé localement // ------------------------------------------------------ // Vérificateur d'intégrité #if DEBUG_CHECKINT { int i; for(i = 0; i < sback->count; i++) { char si[256]; sprintf(si, "Test global après back_wait, index %d", i); _CHECKINT(&back[i], si) } } #endif /* info: updated */ /* if (ptr>0) { // "mis à jour" if ((!r.notmodified) && (opt->is_update) && (!store_errpage)) { // page modifiée if (strnotempty(savename())) { HTS_STAT.stat_updated_files++; //if ((opt->debug>0) && (opt->log!=NULL)) { hts_log_print(opt, LOG_INFO, "File updated: %s%s",urladr(),urlfil()); } } else { if (!store_errpage) { hts_log_print(opt, LOG_INFO, "File recorded: %s%s",urladr(),urlfil()); } } } */ // ------------------------------------------------------ // traitement (parsing) // ------------------------------------------------------ // traiter if (!is_binary && ((is_hypertext_mime(opt, r.contenttype, urlfil())) /* Is HTML or Js, .. */ ||(may_be_hypertext_mime(opt, r.contenttype, urlfil()) && r.adr != NULL) /* Is real media, .. */ ) && (heap(ptr)->depth > 0) /* Depth > 0 (recurse depth) */ &&(r.adr != NULL) /* HTML Data exists */ &&(r.size > 0) /* And not empty */ &&(!store_errpage) /* Not an html error page */ &&(savename()[0] != '\0') /* Output filename exists */ ) { // ne traiter que le html si autorisé // -- -- -- -- // Parsing HTML if (!error) { char page_charset[32]; /* Remove file if being processed */ if (is_loaded_from_file) { (void) unlink(fconv(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), savename())); is_loaded_from_file = 0; } /* Detect charset to convert links into proper UTF8 filenames */ page_charset[0] = '\0'; if (opt->convert_utf8) { /* HTTP charset is prioritary over meta */ if (r.charset[0] != '\0') { if (strlen(r.charset) < sizeof(page_charset)) { strcpy(page_charset, r.charset); } } /* Attempt to find a meta charset */ else if (is_html_mime_type(r.contenttype)) { char *const charset = hts_getCharsetFromMeta(r.adr, r.size); if (charset != NULL && strlen(charset) < sizeof(page_charset)) { strcpy(page_charset, charset); } if (charset != NULL) free(charset); } /* Could not detect charset: could it be UTF-8 ? */ /* No, we can not do that: browsers do not do it (and it would break links). */ //if (page_charset[0] == '\0') { // if (is_unicode_utf8(r.adr, r.size)) { // strcpy(page_charset, "utf-8"); // } //} /* Could not detect charset */ if (page_charset[0] == '\0') { hts_log_print(opt, LOG_INFO, "Warning: could not detect encoding for: %s%s", urladr(), urlfil()); /* Fallback to ISO-8859-1 (~== identity) ; accents will look weird */ strcpy(page_charset, "iso-8859-1"); } } /* Info for wrappers */ hts_log_print(opt, LOG_INFO, "engine: check-html: %s%s", urladr(), urlfil()); { char BIGSTK buff_err_msg[1024]; htsmoduleStruct BIGSTK str; htsmoduleStructExtended BIGSTK stre; buff_err_msg[0] = '\0'; memset(&str, 0, sizeof(str)); memset(&stre, 0, sizeof(stre)); /* */ str.err_msg = buff_err_msg; str.filename = savename(); str.mime = r.contenttype; str.url_host = urladr(); str.url_file = urlfil(); str.size = (int) r.size; /* */ str.addLink = htsAddLink; /* */ str.opt = opt; str.sback = sback; str.cache = &cache; str.hashptr = hashptr; str.numero_passe = numero_passe; /* */ str.ptr_ = &ptr; /* */ str.page_charset_ = page_charset[0] != '\0' ? page_charset : NULL; /* */ /* */ stre.r_ = &r; /* */ stre.error_ = &error; stre.exit_xh_ = &opt->state.exit_xh; stre.store_errpage_ = &store_errpage; /* */ stre.base = base; stre.codebase = codebase; /* */ stre.filters_ = &filters; stre.filptr_ = &filptr; stre.robots_ = &robots; stre.hash_ = &hash; /* */ stre.makeindex_done_ = &makeindex_done; stre.makeindex_fp_ = &makeindex_fp; stre.makeindex_links_ = &makeindex_links; stre.makeindex_firstlink_ = makeindex_firstlink; /* */ stre.template_header_ = template_header; stre.template_body_ = template_body; stre.template_footer_ = template_footer; /* */ stre.stat_fragment_ = &stat_fragment; stre.makestat_time = makestat_time; stre.makestat_fp = makestat_fp; stre.makestat_total_ = &makestat_total; stre.makestat_lnk_ = &makestat_lnk; stre.maketrack_fp = maketrack_fp; /* Parse */ if (htsparse(&str, &stre) != 0) { XH_uninit; return -1; } // I'll have to segment this part // #include "htsparse.c" } } // Fin parsing HTML // -- -- -- -- } // si text/html // -- -- -- else { // sauver fichier quelconque // -- -- -- // sauver fichier /* En cas d'erreur, vérifier que fichier d'erreur existe */ if (strnotempty(savename()) == 0) { // chemin de sauvegarde existant if (strcmp(urlfil(), "/robots.txt") == 0) { // pas robots.txt if (store_errpage) { // c'est une page d'erreur int create_html_warning = 0; int create_gif_warning = 0; switch (ishtml(opt, urlfil())) { /* pas fichier html */ case 0: /* non html */ { char buff[256]; guess_httptype(opt, buff, urlfil()); if (strcmp(buff, "image/gif") == 0) create_gif_warning = 1; } break; case 1: /* html */ if (!r.adr) { } break; default: /* don't know.. */ break; } /* Créer message d'erreur ? */ if (create_html_warning) { char *adr = (char *) malloct(strlen(HTS_DATA_ERROR_HTML) + 1100); hts_log_print(opt, LOG_INFO, "Creating HTML warning file (%s)", r.msg); if (adr) { if (r.adr) { freet(r.adr); r.adr = NULL; } sprintf(adr, HTS_DATA_ERROR_HTML, r.msg); r.adr = adr; } } else if (create_gif_warning) { char *adr = (char *) malloct(HTS_DATA_UNKNOWN_GIF_LEN); hts_log_print(opt, LOG_INFO, "Creating GIF dummy file (%s)", r.msg); if (r.adr) { freet(r.adr); r.adr = NULL; } memcpy(adr, HTS_DATA_UNKNOWN_GIF, HTS_DATA_UNKNOWN_GIF_LEN); r.adr = adr; } } } } if (strnotempty(savename()) == 0) { // pas de chemin de sauvegarde if (strcmp(urlfil(), "/robots.txt") == 0) { // robots.txt if (r.adr) { int bptr = 0; char BIGSTK line[1024]; char BIGSTK buff[8192]; char BIGSTK infobuff[8192]; int record = 0; line[0] = '\0'; buff[0] = '\0'; infobuff[0] = '\0'; // #if DEBUG_ROBOTS printf("robots.txt dump:\n%s\n", r.adr); #endif do { char *comm; int llen; bptr += binput(r.adr + bptr, line, sizeof(line) - 2); /* strip comment */ comm = strchr(line, '#'); if (comm != NULL) { *comm = '\0'; } /* strip spaces */ llen = (int) strlen(line); while(llen > 0 && is_realspace(line[llen - 1])) { line[llen - 1] = '\0'; llen--; } if (strfield(line, "user-agent:")) { char *a; a = line + 11; while(is_realspace(*a)) a++; // sauter espace(s) if (*a == '*') { if (record != 2) record = 1; // c pour nous } else if (strfield(a, "httrack") || strfield(a, "winhttrack") || strfield(a, "webhttrack")) { buff[0] = '\0'; // re-enregistrer infobuff[0] = '\0'; record = 2; // locked #if DEBUG_ROBOTS printf("explicit disallow for httrack\n"); #endif } else record = 0; } else if (record) { if (strfield(line, "disallow:")) { char *a = line + 9; while(is_realspace(*a)) a++; // sauter espace(s) if (strnotempty(a)) { #ifdef IGNORE_RESTRICTIVE_ROBOTS if (strcmp(a, "/") != 0 || opt->robots >= 3) #endif { /* ignoring disallow: / */ if ((strlen(buff) + strlen(a) + 8) < sizeof(buff)) { strcatbuff(buff, a); strcatbuff(buff, "\n"); if ((strlen(infobuff) + strlen(a) + 8) < sizeof(infobuff)) { if (strnotempty(infobuff)) strcatbuff(infobuff, ", "); strcatbuff(infobuff, a); } } } #ifdef IGNORE_RESTRICTIVE_ROBOTS else { hts_log_print(opt, LOG_NOTICE, "Note: %s robots.txt rules are too restrictive, ignoring /", urladr()); } #endif } } } } while((bptr < r.size) && (strlen(buff) < (sizeof(buff) - 32))); if (strnotempty(buff)) { checkrobots_set(&robots, urladr(), buff); hts_log_print(opt, LOG_INFO, "Note: robots.txt forbidden links for %s are: %s", urladr(), infobuff); hts_log_print(opt, LOG_NOTICE, "Note: due to %s remote robots.txt rules, links beginning with these path will be forbidden: %s (see in the options to disable this)", urladr(), infobuff); } } } } else if (r.is_write) { // déja sauvé sur disque /* if (!ishttperror(r.statuscode)) HTS_STAT.stat_files++; HTS_STAT.stat_bytes+=r.size; */ //printf("ok......\n"); } else { // Si on doit sauver une page HTML sans la scanner, cela signifie que le niveau de // récursion nous en empêche // Dans ce cas on met un fichier indiquant ce fait // Si par la suite on doit retraiter ce fichier avec un niveau de récursion plus // fort, on supprimera le readme, et on scannera le fichier html! // note: sauté si store_errpage (càd si page d'erreur, non à scanner!) if ((is_hypertext_mime(opt, r.contenttype, urlfil())) && (!store_errpage) && (r.size > 0)) { // c'est du html!! char BIGSTK tempo[HTS_URLMAXSIZE * 2]; FILE *fp; tempo[0] = '\0'; strcpybuff(tempo, savename()); strcatbuff(tempo, ".readme"); #if HTS_DOSNAME // remplacer / par des slash arrière { int i = 0; while(tempo[i]) { if (tempo[i] == '/') tempo[i] = '\\'; i++; } } // a partir d'ici le slash devient antislash #endif if ((fp = FOPEN(tempo, "wb")) != NULL) { fprintf(fp, "Info-file generated by HTTrack Website Copier " HTTRACK_VERSION "%s" CRLF "" CRLF, hts_get_version_info(opt)); fprintf(fp, "The file %s has not been scanned by HTS" CRLF, savename()); fprintf(fp, "Some links contained in it may be unreachable locally." CRLF); fprintf(fp, "If you want to get these files, you have to set an upper recurse level, "); fprintf(fp, "and to rescan the URL." CRLF); fclose(fp); #ifndef _WIN32 chmod(tempo, HTS_ACCESS_FILE); #endif usercommand(opt, 0, NULL, fconv(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), tempo), "", ""); } hts_log_print(opt, LOG_WARNING, "Warning: store %s without scan: %s", r.contenttype, savename()); } else { if ((opt->getmode & 2) != 0) { // ok autorisé hts_log_print(opt, LOG_DEBUG, "Store %s: %s", r.contenttype, savename()); } else { // lien non autorisé! (ex: cgi-bin en html) hts_log_print(opt, LOG_DEBUG, "non-html file ignored after upload at %s : %s", urladr(), urlfil()); if (r.adr) { freet(r.adr); r.adr = NULL; } } } //printf("extern=%s\n",r.contenttype); // ATTENTION C'EST ICI QU'ON SAUVE LE FICHIER!! if (r.adr != NULL || r.size == 0) { file_notify(opt, urladr(), urlfil(), savename(), 1, 1, r.notmodified); if (filesave(opt, r.adr, (int) r.size, savename(), urladr(), urlfil()) != 0) { int fcheck; if ((fcheck = check_fatal_io_errno())) { hts_log_print(opt, LOG_ERROR, "Mirror aborted: disk full or filesystem problems"); opt->state.exit_xh = -1; /* fatal error */ } hts_log_print(opt, LOG_ERROR | LOG_ERRNO, "Unable to save file %s", savename()); } else { /* if (!ishttperror(r.statuscode)) HTS_STAT.stat_files++; HTS_STAT.stat_bytes+=r.size; */ } } } /* Parsing of other media types (java, ram..) */ /* if (strfield2(r.contenttype,"audio/x-pn-realaudio")) { hts_log_print(opt, LOG_DEBUG, "(Real Media): parsing %s",savename()); if (fexist(savename())) { // ok, existe bien! FILE* fp=FOPEN(savename(),"r+b"); if (fp) { if (!fseek(fp,0,SEEK_SET)) { char BIGSTK line[HTS_URLMAXSIZE*2]; linput(fp,line,HTS_URLMAXSIZE); if (strnotempty(line)) { hts_log_print(opt, LOG_DEBUG, "(Real Media): detected %s",line); } } fclose(fp); } } } else */ /* External modules */ if (opt->parsejava && (opt->parsejava & HTSPARSE_NO_CLASS) == 0 && fexist(savename())) { char BIGSTK buff_err_msg[1024]; htsmoduleStruct BIGSTK str; buff_err_msg[0] = '\0'; memset(&str, 0, sizeof(str)); /* */ str.err_msg = buff_err_msg; str.filename = savename(); str.mime = r.contenttype; str.url_host = urladr(); str.url_file = urlfil(); str.size = (int) r.size; /* */ str.addLink = htsAddLink; /* */ str.opt = opt; str.sback = sback; str.cache = &cache; str.hashptr = hashptr; str.numero_passe = numero_passe; str.ptr_ = &ptr; /* Parse if recognized */ switch (hts_parse_externals(&str)) { case 1: hts_log_print(opt, LOG_DEBUG, "(External module): parsed successfully %s", savename()); break; case 0: hts_log_print(opt, LOG_DEBUG, "(External module): couldn't parse successfully %s : %s", savename(), str.err_msg); break; } } } // text/html ou autre /* Post-processing */ if (fexist(savename())) { usercommand(opt, 0, NULL, savename(), urladr(), urlfil()); } } // if !error jump_if_done: // libérer les liens if (r.adr) { freet(r.adr); r.adr = NULL; } // libérer la mémoire! // prochain lien ptr++; // faut-il sauter le(s) lien(s) suivant(s)? (fichiers images à passer après les html) if (opt->getmode & 4) { // sauver les non html après // sauter les fichiers selon la passe if (!numero_passe) { while((ptr < opt->lien_tot) ? (heap(ptr)->pass2) : 0) ptr++; } else { while((ptr < opt->lien_tot) ? (!heap(ptr)->pass2) : 0) ptr++; } if (ptr >= opt->lien_tot) { // fin de boucle if (!numero_passe) { // première boucle hts_log_print(opt, LOG_DEBUG, "Now getting non-html files..."); numero_passe = 1; // seconde boucle ptr = 0; // prochain pass2 while((ptr < opt->lien_tot) ? (!heap(ptr)->pass2) : 0) ptr++; //printf("first link==%d\n"); } } } // copy abort state if necessary from outside //if (!exit_xh && opt->state.exit_xh) { // exit_xh=opt->state.exit_xh; //} // a-t-on dépassé le quota? if (!back_checkmirror(opt)) { ptr = opt->lien_tot; } else if (opt->state.exit_xh) { // sortir if (opt->state.exit_xh == 1) { hts_log_print(opt, LOG_ERROR, "Exit requested by shell or user"); } else { hts_log_print(opt, LOG_ERROR, "Exit requested by engine"); } ptr = opt->lien_tot; } } while(ptr < opt->lien_tot); // // // /* Ensure the index is being closed */ HT_INDEX_END; /* updating-a-remotely-deteted-website hack no much data transferred, no data saved we assume that something was bad (no connection) just backup old cache and restore everything */ if ((HTS_STAT.stat_files <= 0) && (HTS_STAT.HTS_TOTAL_RECV < 32768) /* should be fine */ ) { hts_log_print(opt, LOG_NOTICE, "No data seems to have been transferred during this session! : restoring previous one!"); XH_uninit; if ((fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.dat"))) && (fexist (fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.ndx")))) { remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.dat")); remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.ndx")); remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.lst")); remove(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.txt")); rename(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.dat"), fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.dat")); rename(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.ndx"), fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.ndx")); rename(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.lst"), fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.lst")); rename(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.txt"), fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.txt")); } opt->state.exit_xh = 2; /* interrupted (no connection detected) */ return 1; } // info text if (cache.txt) { fclose(cache.txt); cache.txt = NULL; } // purger! if (cache.lst) { fclose(cache.lst); cache.lst = opt->state.strc.lst = NULL; if (opt->delete_old) { FILE *old_lst, *new_lst; // opt->state._hts_in_html_parsing = 3; // old_lst = fopen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/old.lst"), "rb"); if (old_lst) { const size_t sz = off_t_to_size_t(fsize(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.lst"))); new_lst = fopen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_log), "hts-cache/new.lst"), "rb"); if (new_lst != NULL && sz != (size_t) -1) { char *adr = (char *) malloct(sz); if (adr) { if (fread(adr, 1, sz, new_lst) == sz) { char line[1100]; int purge = 0; while(!feof(old_lst)) { linput(old_lst, line, 1000); if (!strstr(adr, line)) { // fichier non trouvé dans le nouveau? char BIGSTK file[HTS_URLMAXSIZE * 2]; strcpybuff(file, StringBuff(opt->path_html)); strcatbuff(file, line + 1); file[strlen(file) - 1] = '\0'; if (fexist(file)) { // toujours sur disque: virer hts_log_print(opt, LOG_INFO, "Purging %s", file); remove(file); purge = 1; } } } { fseek(old_lst, 0, SEEK_SET); while(!feof(old_lst)) { linput(old_lst, line, 1000); while(strnotempty(line) && (line[strlen(line) - 1] != '/') && (line[strlen(line) - 1] != '\\')) { line[strlen(line) - 1] = '\0'; } if (strnotempty(line)) line[strlen(line) - 1] = '\0'; if (strnotempty(line)) if (!strstr(adr, line)) { // non trouvé? char BIGSTK file[HTS_URLMAXSIZE * 2]; strcpybuff(file, StringBuff(opt->path_html)); strcatbuff(file, line + 1); while((strnotempty(file)) && (rmdir(file) == 0)) { // ok, éliminé (existait) purge = 1; if (opt->log) { hts_log_print(opt, LOG_INFO, "Purging directory %s/", file); while(strnotempty(file) && (file[strlen(file) - 1] != '/') && (file[strlen(file) - 1] != '\\')) { file[strlen(file) - 1] = '\0'; } if (strnotempty(file)) file[strlen(file) - 1] = '\0'; } } } } } // if (!purge) { hts_log_print(opt, LOG_INFO, "No files purged"); } } freet(adr); } fclose(new_lst); } fclose(old_lst); } // opt->state._hts_in_html_parsing = 0; } } // fin purge! // Indexation if (opt->kindex) index_finish(StringBuff(opt->path_html), opt->kindex); // afficher résumé dans log if (opt->log != NULL) { char BIGSTK finalInfo[8192]; int error = fspc(opt, NULL, "error"); int warning = fspc(opt, NULL, "warning"); int info = fspc(opt, NULL, "info"); char BIGSTK htstime[256]; char BIGSTK infoupdated[256]; // int n=(int) (stat_loaded/(time_local()-HTS_STAT.stat_timestart)); LLint n = (LLint) (HTS_STAT.HTS_TOTAL_RECV / (max(1, time_local() - HTS_STAT.stat_timestart))); sec2str(htstime, time_local() - HTS_STAT.stat_timestart); //sprintf(finalInfo + strlen(finalInfo),LF"HTS-mirror complete in %s : %d links scanned, %d files written (%d bytes overall) [%d bytes received at %d bytes/sec]"LF,htstime,lien_tot-1,HTS_STAT.stat_files,stat_bytes,stat_loaded,n); infoupdated[0] = '\0'; if (opt->is_update) { if (HTS_STAT.stat_updated_files > 0) { sprintf(infoupdated, ", %d files updated", (int) HTS_STAT.stat_updated_files); } else { sprintf(infoupdated, ", no files updated"); } } finalInfo[0] = '\0'; sprintf(finalInfo + strlen(finalInfo), "HTTrack Website Copier/" HTTRACK_VERSION " mirror complete in %s : " "%d links scanned, %d files written (" LLintP " bytes overall)%s " "[" LLintP " bytes received at " LLintP " bytes/sec]", htstime, (int) opt->lien_tot - 1, (int) HTS_STAT.stat_files, (LLint) HTS_STAT.stat_bytes, infoupdated, (LLint) HTS_STAT.HTS_TOTAL_RECV, (LLint) n); if (HTS_STAT.total_packed > 0 && HTS_STAT.total_unpacked > 0) { int packed_ratio = (int) ((LLint) (HTS_STAT.total_packed * 100) / HTS_STAT.total_unpacked); sprintf(finalInfo + strlen(finalInfo), ", " LLintP " bytes transferred using HTTP compression in %d files, ratio %d%%", (LLint) HTS_STAT.total_unpacked, HTS_STAT.total_packedfiles, (int) packed_ratio); } if (!opt->nokeepalive && HTS_STAT.stat_sockid > 0 && HTS_STAT.stat_nrequests > HTS_STAT.stat_sockid) { int rq = (HTS_STAT.stat_nrequests * 10) / HTS_STAT.stat_sockid; sprintf(finalInfo + strlen(finalInfo), ", %d.%d requests per connection", rq / 10, rq % 10); } sprintf(finalInfo + strlen(finalInfo), LF); if (error) sprintf(finalInfo + strlen(finalInfo), "(%d errors, %d warnings, %d messages)" LF, error, warning, info); else sprintf(finalInfo + strlen(finalInfo), "(No errors, %d warnings, %d messages)" LF, warning, info); // Log fprintf(opt->log, LF "%s", finalInfo); // Close ZIP if (cache.zipOutput) { zipClose(cache.zipOutput, finalInfo); cache.zipOutput = NULL; } } // fin afficher résumé dans log // ending usercommand(opt, 0, NULL, NULL, NULL, NULL); // désallocation mémoire & buffers XH_uninit; return 1; // OK } // version 2 pour le reste // Estimate transfer rate // a little bit complex, but not too much /* .. : idle ^ : event ----|----|----|----|----|----|----|----|----> 1 2 3 4 5 6 7 8 9 time (seconds) ----|----|----|----|----|----|----|----|----> ^........^.........^.........^.........^.... timer 0 ----^.........^.........^.........^......... timer 1 0 1 0 1 0 1 0 timer N sets its statistics * * * * timer 0 resync timer 1 Therefore, each seconds, we resync the transfer rate with 2-seconds */ int engine_stats(void) { #if 0 static FILE *debug_fp = NULL; /* ok */ if (!debug_fp) debug_fp = fopen("esstat.txt", "wb"); #endif HTS_STAT.stat_nsocket = HTS_STAT.stat_errors = HTS_STAT.nbk = 0; HTS_STAT.nb = 0; if (HTS_STAT.HTS_TOTAL_RECV > 2048) { TStamp cdif = mtime_local(); int i; for(i = 0; i < 2; i++) { if ((cdif - HTS_STAT.istat_timestart[i]) >= 2000) { TStamp dif; #if 0 fprintf(debug_fp, "set timer %d\n", i); fflush(debug_fp); #endif dif = cdif - HTS_STAT.istat_timestart[i]; if ((TStamp) (dif / 1000) > 0) { LLint byt = (HTS_STAT.HTS_TOTAL_RECV - HTS_STAT.istat_bytes[i]); HTS_STAT.rate = (LLint) ((TStamp) ((TStamp) byt / (dif / 1000))); HTS_STAT.istat_idlasttimer = i; // this timer recently sets the stats // HTS_STAT.istat_bytes[i] = HTS_STAT.HTS_TOTAL_RECV; HTS_STAT.istat_timestart[i] = cdif; } return 1; /* refreshed */ } } // resynchronization between timer 0 (master) and 1 (slave) // timer #0 resync timer #1 when reaching 1 second limit if (HTS_STAT.istat_reference01 != HTS_STAT.istat_timestart[0]) { if ((cdif - HTS_STAT.istat_timestart[0]) >= 1000) { #if 0 fprintf(debug_fp, "resync timer 1\n"); fflush(debug_fp); #endif HTS_STAT.istat_bytes[1] = HTS_STAT.HTS_TOTAL_RECV; HTS_STAT.istat_timestart[1] = cdif; HTS_STAT.istat_reference01 = HTS_STAT.istat_timestart[0]; } } } return 0; } #define _FILTERS (*opt->filters.filters) #define _FILTERS_PTR (opt->filters.filptr) #define _ROBOTS ((robots_wizard*)opt->robotsptr) // bannir host (trop lent etc) void host_ban(httrackp * opt, int ptr, struct_back * sback, const char *host) { lien_back *const back = sback->lnk; const int back_max = sback->count; //int l; int i; if (host[0] == '!') return; // erreur.. déja cancellé.. bizarre.. devrait pas arriver /* sanity check */ if (*_FILTERS_PTR + 1 >= opt->maxfilter) { opt->maxfilter += HTS_FILTERSINC; if (filters_init(&_FILTERS, opt->maxfilter, HTS_FILTERSINC) == 0) { printf("PANIC! : Too many filters : >%d [%d]\n", *_FILTERS_PTR, __LINE__); hts_log_print(opt, LOG_PANIC, "Too many filters, giving up..(>%d)", *_FILTERS_PTR); hts_log_print(opt, LOG_INFO, "To avoid that: use #F option for more filters (example: -#F5000)"); assertf("too many filters - giving up" == NULL); } } // interdire host assertf((*_FILTERS_PTR) < opt->maxfilter); if (*_FILTERS_PTR < opt->maxfilter) { strcpybuff(_FILTERS[*_FILTERS_PTR], "-"); strcatbuff(_FILTERS[*_FILTERS_PTR], host); strcatbuff(_FILTERS[*_FILTERS_PTR], "/*"); // host/ * interdit (*_FILTERS_PTR)++; } // oups if (strlen(host) <= 1) { // euhh?? longueur <= 1 if (strcmp(host, "file://")) { //## if (host[0]!=lOCAL_CHAR) { // pas local hts_log_print(opt, LOG_PANIC, "PANIC! HostCancel detected memory leaks [char %d]", host[0]); return; // purée } } // couper connexion for(i = 0; i < back_max; i++) { if (back[i].status >= 0) // réception OU prêt if (strfield2(back[i].url_adr, host)) { #if HTS_DEBUG_CLOSESOCK DEBUG_W("host control: deletehttp\n"); #endif back[i].status = 0; // terminé back_set_finished(sback, i); if (back[i].r.soc != INVALID_SOCKET) deletehttp(&back[i].r); back[i].r.soc = INVALID_SOCKET; back[i].r.statuscode = STATUSCODE_TIMEOUT; // timeout (peu importe si c'est un traffic jam) strcpybuff(back[i].r.msg, "Link Cancelled by host control"); hts_log_print(opt, LOG_DEBUG, "Shutdown: %s%s", back[i].url_adr, back[i].url_fil); } } // effacer liens //l=strlen(host); for(i = 0; i < opt->lien_tot; i++) { //if (heap(i)->adr_len==l) { // même taille de chaîne // Calcul de taille sécurisée if (heap(i)) { if (heap(i)->adr) { int l = 0; while((heap(i)->adr[l]) && (l < 1020)) l++; if ((l > 0) && (l < 1020)) { // sécurité if (strfield2(jump_identification_const(heap(i)->adr), host)) { // host hts_log_print(opt, LOG_DEBUG, "Cancel: %s%s", heap(i)->adr, heap(i)->fil); hts_invalidate_link(opt, i); // invalidate hashtable entry // on efface pas le hash, because si on rencontre le lien, reverif sav.. } } else { if (opt->log != NULL) { char dmp[1040]; dmp[0] = '\0'; strncatbuff(dmp, heap(i)->adr, 1024); hts_log_print(opt, LOG_WARNING, "WARNING! HostCancel detected memory leaks [len %d at %d]", l, i); hts_log_print(opt, LOG_WARNING, "dump 1024 bytes (address %p): " LF "%s", heap(i)->adr, dmp); } } } else { hts_log_print(opt, LOG_WARNING, "WARNING! HostCancel detected memory leaks [adr at %d]", i); } } else { hts_log_print(opt, LOG_WARNING, "WARNING! HostCancel detected memory leaks [null at %d]", i); } //} } } int filters_init(char ***ptrfilters, int maxfilter, int filterinc) { char **filters = *ptrfilters; int filter_max = maximum(maxfilter, 128); if (filters == NULL) { filters = (char **) malloct(sizeof(char *) * (filter_max + 2)); memset(filters, 0, sizeof(char *) * (filter_max + 2)); // filters[0] == 0 } else { filters = (char **) realloct(filters, sizeof(char *) * (filter_max + 2)); } if (filters) { if (filters[0] == NULL) { filters[0] = (char *) malloct(sizeof(char) * (filter_max + 2) * (HTS_URLMAXSIZE * 2)); memset(filters[0], 0, sizeof(char) * (filter_max + 2) * (HTS_URLMAXSIZE * 2)); } else { filters[0] = (char *) realloct(filters[0], sizeof(char) * (filter_max + 2) * (HTS_URLMAXSIZE * 2)); } if (filters[0] == NULL) { freet(filters); filters = NULL; } } if (filters != NULL) { int i; int from; if (filterinc == 0) from = 0; else from = filter_max - filterinc; for(i = 0; i <= filter_max; i++) { // PLUS UN (sécurité) filters[i] = filters[0] + i * (HTS_URLMAXSIZE * 2); } for(i = from; i <= filter_max; i++) { // PLUS UN (sécurité) filters[i][0] = '\0'; // clear } } *ptrfilters = filters; return (filters != NULL) ? filter_max : 0; } static int mkdir_compat(const char *pathname) { #ifdef _WIN32 return mkdir(pathname); #else return mkdir(pathname, HTS_ACCESS_FOLDER); #endif } /* path must end with "/" or with the finename (/tmp/bar/ or /tmp/bar/foo.zip) */ /* Note: preserve errno */ HTSEXT_API int dir_exists(const char *path) { const int err = errno; STRUCT_STAT st; char BIGSTK file[HTS_URLMAXSIZE * 2]; int i = 0; if (strnotempty(path) == 0) { return 0; } if (strlen(path) > HTS_URLMAXSIZE) { return 0; } /* Get a copy */ strcpybuff(file, path); #ifdef _WIN32 /* To system name */ for(i = 0; file[i] != 0; i++) { if (file[i] == '/') { file[i] = PATH_SEPARATOR; } } #endif /* Get prefix (note: file can not be empty here) */ for(i = (int) strlen(file) - 1; i > 0 && file[i] != PATH_SEPARATOR; i--) ; for(; i > 0 && file[i] == PATH_SEPARATOR; i--) ; file[i + 1] = '\0'; /* Check the final dir */ if (STAT(file, &st) == 0 && S_ISDIR(st.st_mode)) { return 1; /* EXISTS */ } errno = err; return 0; /* DOES NOT EXIST */ } /* path must end with "/" or with the finename (/tmp/bar/ or /tmp/bar/foo.zip) */ /* Note: *not* UTF-8 */ HTSEXT_API int structcheck(const char *path) { struct stat st; char BIGSTK tmpbuf[HTS_URLMAXSIZE * 2]; char BIGSTK file[HTS_URLMAXSIZE * 2]; int i = 0; int npaths; if (strnotempty(path) == 0) return 0; if (strlen(path) > HTS_URLMAXSIZE) { errno = EINVAL; return -1; } /* Get a copy */ strcpybuff(file, path); #ifdef _WIN32 /* To system name */ for(i = 0; file[i] != 0; i++) { if (file[i] == '/') { file[i] = PATH_SEPARATOR; } } #endif /* Get prefix (note: file can not be empty here) */ for(i = (int) strlen(file) - 1; i > 0 && file[i] != PATH_SEPARATOR; i--) ; for(; i > 0 && file[i] == PATH_SEPARATOR; i--) ; file[i + 1] = '\0'; /* First check the final dir */ if (stat(file, &st) == 0 && S_ISDIR(st.st_mode)) { return 0; /* OK */ } /* Start from the beginning */ i = 0; /* Skip irrelevant part (the root slash, or the drive path) */ #ifdef _WIN32 if (file[0] != 0 && file[1] == ':') { /* f:\ */ i += 2; if (file[i] == PATH_SEPARATOR) { /* f:\ */ i++; } } else if (file[0] == PATH_SEPARATOR && file[1] == PATH_SEPARATOR) { /* \\mch */ int j; i += 2; // skip machine and first dir (share) or we'll have troubles (TomZ) for(j = 0; j < 2; j++) { // skip segment for(; file[i] != '\0' && file[i] != PATH_SEPARATOR; i++) ; // skip final separator if (file[i] == PATH_SEPARATOR) { /* f:\ */ i++; } } } #endif /* Check paths */ for(npaths = 1;; npaths++) { char end_char; /* Go to next path */ /* Skip separator(s) */ for(; file[i] == PATH_SEPARATOR; i++) ; /* Next separator */ for(; file[i] != 0 && file[i] != PATH_SEPARATOR; i++) ; /* Check */ end_char = file[i]; if (end_char != 0) { file[i] = '\0'; } if (stat(file, &st) == 0) { /* Something exists */ if (!S_ISDIR(st.st_mode)) { #if HTS_REMOVE_ANNOYING_INDEX if (S_ISREG(st.st_mode)) { /* Regular file in place ; move it and create directory */ sprintf(tmpbuf, "%s.txt", file); if (rename(file, tmpbuf) != 0) { /* Can't rename regular file */ return -1; } if (mkdir_compat(file) != 0) { /* Can't create directory */ return -1; } } #else #error Not implemented #endif } } else { /* Nothing exists ; create directory */ if (mkdir_compat(file) != 0) { /* Can't create directory */ return -1; } } if (end_char == 0) { /* End */ break; } else { file[i] = end_char; /* Restore / */ } } return 0; } /* path must end with "/" or with the finename (/tmp/bar/ or /tmp/bar/foo.zip) */ /* Note: UTF-8 */ HTSEXT_API int structcheck_utf8(const char *path) { STRUCT_STAT st; char BIGSTK tmpbuf[HTS_URLMAXSIZE * 2]; char BIGSTK file[HTS_URLMAXSIZE * 2]; int i = 0; int npaths; if (strnotempty(path) == 0) return 0; if (strlen(path) > HTS_URLMAXSIZE) { errno = EINVAL; return -1; } /* Get a copy */ strcpybuff(file, path); #ifdef _WIN32 /* To system name */ for(i = 0; file[i] != 0; i++) { if (file[i] == '/') { file[i] = PATH_SEPARATOR; } } #endif /* Get prefix (note: file can not be empty here) */ for(i = (int) strlen(file) - 1; i > 0 && file[i] != PATH_SEPARATOR; i--) ; for(; i > 0 && file[i] == PATH_SEPARATOR; i--) ; file[i + 1] = '\0'; /* First check the final dir */ if (STAT(file, &st) == 0 && S_ISDIR(st.st_mode)) { return 0; /* OK */ } /* Start from the beginning */ i = 0; /* Skip irrelevant part (the root slash, or the drive path) */ #ifdef _WIN32 if (file[0] != 0 && file[1] == ':') { /* f:\ */ i += 2; if (file[i] == PATH_SEPARATOR) { /* f:\ */ i++; } } else if (file[0] == PATH_SEPARATOR && file[1] == PATH_SEPARATOR) { /* \\mch */ int j; i += 2; // skip machine and first dir (share) or we'll have troubles (TomZ) for(j = 0; j < 2; j++) { // skip segment for(; file[i] != '\0' && file[i] != PATH_SEPARATOR; i++) ; // skip final separator if (file[i] == PATH_SEPARATOR) { /* f:\ */ i++; } } } #endif /* Check paths */ for(npaths = 1;; npaths++) { char end_char; /* Go to next path */ /* Skip separator(s) */ for(; file[i] == PATH_SEPARATOR; i++) ; /* Next separator */ for(; file[i] != 0 && file[i] != PATH_SEPARATOR; i++) ; /* Check */ end_char = file[i]; if (end_char != 0) { file[i] = '\0'; } if (STAT(file, &st) == 0) { /* Something exists */ if (!S_ISDIR(st.st_mode)) { #if HTS_REMOVE_ANNOYING_INDEX if (S_ISREG(st.st_mode)) { /* Regular file in place ; move it and create directory */ sprintf(tmpbuf, "%s.txt", file); if (RENAME(file, tmpbuf) != 0) { /* Can't rename regular file */ return -1; } if (MKDIR(file) != 0) { /* Can't create directory */ return -1; } } #else #error Not implemented #endif } } else { /* Nothing exists ; create directory */ if (MKDIR(file) != 0) { /* Can't create directory */ return -1; } } if (end_char == 0) { /* End */ break; } else { file[i] = end_char; /* Restore / */ } } return 0; } // sauver un fichier int filesave(httrackp * opt, const char *adr, int len, const char *s, const char *url_adr, const char *url_fil) { FILE *fp; // écrire le fichier if ((fp = filecreate(&opt->state.strc, s)) != NULL) { int nl = 0; if (len > 0) { nl = (int) fwrite(adr, 1, len, fp); } fclose(fp); if (nl != len) // erreur return -1; } else return -1; return 0; } /* We should stop */ int check_fatal_io_errno(void) { switch (errno) { #ifdef EMFILE case EMFILE: /* Too many open files */ #endif #ifdef ENOSPC case ENOSPC: /* No space left on device */ #endif #ifdef EROFS case EROFS: /* Read-only file system */ #endif return 1; break; } return 0; } // ouvrir un fichier (avec chemin Un*x) /* Note: utf-8 */ FILE *filecreate(filenote_strc * strc, const char *s) { char BIGSTK fname[HTS_URLMAXSIZE * 2]; FILE *fp; int last_errno = 0; fname[0] = '\0'; // noter lst if (strc != NULL) { filenote(strc, s, NULL); } strcpybuff(fname, s); #if HTS_DOSNAME // remplacer / par des slash arrière { int i = 0; while(fname[i]) { if (fname[i] == '/') fname[i] = '\\'; i++; } } // a partir d'ici le slash devient antislash #endif /* Try to open the file */ fp = FOPEN(fname, "wb"); /* Error ? Check the directory structure and retry. */ if (fp == NULL) { last_errno = errno; if (structcheck_utf8(s) != 0) { last_errno = errno; } else { last_errno = 0; } fp = FOPEN(fname, "wb"); } if (fp == NULL && last_errno != 0) { errno = last_errno; } #ifndef _WIN32 if (fp != NULL) chmod(fname, HTS_ACCESS_FILE); #endif return fp; } // ouvrir un fichier (avec chemin Un*x) FILE *fileappend(filenote_strc * strc, const char *s) { char BIGSTK fname[HTS_URLMAXSIZE * 2]; FILE *fp; fname[0] = '\0'; // noter lst filenote(strc, s, NULL); // if (*s=='/') strcpybuff(fname,s+1); else strcpybuff(fname,s); // pas de / (root!!) // ** SIIIIIII!!! à cause de -O strcpybuff(fname, s); #if HTS_DOSNAME // remplacer / par des slash arrière { int i = 0; while(fname[i]) { if (fname[i] == '/') fname[i] = '\\'; i++; } } // a partir d'ici le slash devient antislash #endif // ouvrir fp = FOPEN(fname, "ab"); #ifndef _WIN32 if (fp != NULL) chmod(fname, HTS_ACCESS_FILE); #endif return fp; } // create an empty file int filecreateempty(filenote_strc * strc, const char *filename) { FILE *fp; fp = filecreate(strc, filename); // filenote & co if (fp) { fclose(fp); return 1; } else return 0; } // noter fichier int filenote(filenote_strc * strc, const char *s, filecreate_params * params) { // gestion du fichier liste liste if (params) { //filecreate_params* p = (filecreate_params*) params; strcpybuff(strc->path, params->path); strc->lst = params->lst; return 0; } else if (strc->lst) { char BIGSTK savelst[HTS_URLMAXSIZE * 2]; char catbuff[CATBUFF_SIZE]; strcpybuff(savelst, fslash(catbuff, sizeof(catbuff), s)); // couper chemin? if (strnotempty(strc->path)) { if (strncmp(fslash(catbuff, sizeof(catbuff), strc->path), savelst, strlen(strc->path)) == 0) { // couper strcpybuff(savelst, s + strlen(strc->path)); } } fprintf(strc->lst, "[%s]" LF, savelst); fflush(strc->lst); } return 1; } /* Note: utf-8 */ void file_notify(httrackp * opt, const char *adr, const char *fil, const char *save, int create, int modify, int not_updated) { RUN_CALLBACK6(opt, filesave2, adr, fil, save, create, modify, not_updated); } // executer commande utilisateur static void postprocess_file(httrackp * opt, const char *save, const char *adr, const char *fil); void usercommand(httrackp * opt, int _exe, const char *_cmd, const char *file, const char *adr, const char *fil) { usercommand_strc *strc = &opt->state.usercmd; /* Callback */ if (_exe) { strcpybuff(strc->cmd, _cmd); if (strnotempty(strc->cmd)) strc->exe = _exe; else strc->exe = 0; } /* post-processing */ postprocess_file(opt, file, adr, fil); if (file != NULL && strnotempty(file)) { RUN_CALLBACK1(opt, filesave, file); } if (strc->exe) { if (file != NULL && strnotempty(file)) { if (strnotempty(strc->cmd)) { usercommand_exe(strc->cmd, file); } } } } void usercommand_exe(const char *cmd, const char *file) { char BIGSTK temp[8192]; size_t i; temp[0] = '\0'; // for(i = 0; cmd[i] != '\0'; i++) { if ((cmd[i] == '$') && (cmd[i + 1] == '0')) { strcatbuff(temp, file); i++; } else { char c[2]; c[0] = cmd[i]; c[1] = '\0'; strcatbuff(temp, c); } } if (system(temp) == -1) { assertf(!"can not spawn process"); } } static void postprocess_file(httrackp * opt, const char *save, const char *adr, const char *fil) { //int first = 0; /* MIME-html archive to build */ if (opt != NULL && opt->mimehtml) { if (adr != NULL && strcmp(adr, "primary") == 0) { adr = NULL; } if (save != NULL && opt != NULL && adr != NULL && adr[0] && strnotempty(save) && fexist(save)) { const char *rsc_save = save; const char *rsc_fil = strrchr(fil, '/'); int n; if (rsc_fil == NULL) rsc_fil = fil; if (strncmp (fslash(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), save), fslash(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_html_utf8)), (n = (int) strlen (StringBuff (opt-> path_html_utf8)))) == 0) { rsc_save += n; } if (!opt->state.mimehtml_created) { //first = 1; opt->state.mimefp = fopen(fconcat (OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_html), "index.mht"), "wb"); (void) unlink(fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_html), "index.eml")); #ifndef _WIN32 if (symlink("index.mht", fconcat(OPT_GET_BUFF(opt), OPT_GET_BUFF_SIZE(opt), StringBuff(opt->path_html), "index.eml")) != 0) { if (errno != EPERM) { hts_log_print(opt, LOG_WARNING | LOG_ERRNO, "could not create symbolic link from index.mht to index.eml"); } } #endif if (opt->state.mimefp != NULL) { char BIGSTK rndtmp[1024], currtime[256]; srand((unsigned int) time(NULL)); time_gmt_rfc822(currtime); sprintf(rndtmp, "%d_%d", (int) time(NULL), (int) rand()); StringRoom(opt->state.mimemid, 256); sprintf(StringBuffRW(opt->state.mimemid), "----=_MIMEPart_%s_=----", rndtmp); StringSetLength(opt->state.mimemid, -1); fprintf(opt->state.mimefp, "From: HTTrack Website Copier \r\n" "Subject: Local mirror\r\n" "Date: %s\r\n" "Message-ID: \r\n" "Content-Type: multipart/related;\r\n" "\tboundary=\"%s\";\r\n" "\ttype=\"text/html\"\r\n" "MIME-Version: 1.0\r\n" "\r\nThis message is a RFC MIME-compliant multipart message.\r\n" "\r\n", currtime, rndtmp, StringBuff(opt->state.mimemid)); opt->state.mimehtml_created = 1; } else { opt->state.mimehtml_created = -1; hts_log_print(opt, LOG_ERROR, "unable to create index.mht"); } } if (opt->state.mimehtml_created == 1 && opt->state.mimefp != NULL) { FILE *fp = FOPEN(save, "rb"); if (fp != NULL) { char buff[60 * 100 + 2]; char mimebuff[256]; char BIGSTK cid[HTS_URLMAXSIZE * 3]; size_t len; int isHtml = (ishtml(opt, save) == 1); mimebuff[0] = '\0'; /* CID */ make_content_id(adr, fil, cid, sizeof(cid)); guess_httptype(opt, mimebuff, save); fprintf(opt->state.mimefp, "--%s\r\n", StringBuff(opt->state.mimemid)); /*if (first) fprintf(opt->state.mimefp, "Content-disposition: inline\r\n"); else */ fprintf(opt->state.mimefp, "Content-disposition: attachment; filename=\"%s\"\r\n", rsc_save); fprintf(opt->state.mimefp, "Content-Type: %s\r\n" "Content-Transfer-Encoding: %s\r\n" /*"Content-Location: http://localhost/%s\r\n" */ "Content-ID: <%s>\r\n" "\r\n", mimebuff, isHtml ? "8bit" : "base64" /*, rsc_save */ , cid); while((len = fread(buff, 1, sizeof(buff) - 2, fp)) > 0) { buff[len] = '\0'; if (!isHtml) { char base64buff[60 * 100 * 2]; code64((unsigned char *) buff, (int) len, (unsigned char *) base64buff, 1); fprintf(opt->state.mimefp, "%s", base64buff); } else { fprintf(opt->state.mimefp, "%s", buff); } } fclose(fp); fprintf(opt->state.mimefp, "\r\n\r\n"); } } } else if (save == NULL) { if (opt->state.mimehtml_created == 1 && opt->state.mimefp != NULL) { fprintf(opt->state.mimefp, "--%s--\r\n", StringBuff(opt->state.mimemid)); fclose(opt->state.mimefp); opt->state.mimefp = NULL; } } } } // écrire n espaces dans fp int fspc(httrackp * opt, FILE * fp, const char *type) { fspc_strc *const strc = (opt != NULL) ? &opt->state.fspc : NULL; if (fp != NULL) { char s[256]; time_t tt; struct tm *A; tt = time(NULL); A = localtime(&tt); if (A == NULL) { int localtime_returned_null = 0; assertf(localtime_returned_null); } strftime(s, 250, "%H:%M:%S", A); if (strnotempty(type)) fprintf(fp, "%s\t%c%s: \t", s, hichar(*type), type + 1); else fprintf(fp, "%s\t \t", s); if (strc != NULL) { if (strcmp(type, "warning") == 0) strc->warning++; else if (strcmp(type, "error") == 0) strc->error++; else if (strcmp(type, "info") == 0) strc->info++; } } else if (strc == NULL) { return 0; } else if (!type) { strc->error = strc->warning = strc->info = 0; // reset } else if (strcmp(type, "warning") == 0) return strc->warning; else if (strcmp(type, "error") == 0) return strc->error; else if (strcmp(type, "info") == 0) return strc->info; return 0; } // vérifier taux de transfert #if 0 void check_rate(TStamp stat_timestart, int maxrate) { // vérifier taux de transfert (pas trop grand?) /* if (maxrate>0) { int r = (int) (HTS_STAT.HTS_TOTAL_RECV/(time_local()-stat_timestart)); // taux actuel de transfert HTS_STAT.HTS_TOTAL_RECV_STATE=0; if (r>maxrate) { // taux>taux autorisé int taux = (int) (((TStamp) (r - maxrate) * 100) / (TStamp) maxrate); if (taux<15) HTS_STAT.HTS_TOTAL_RECV_STATE=1; // ralentir un peu (<15% dépassement) else if (taux<50) HTS_STAT.HTS_TOTAL_RECV_STATE=2; // beaucoup (<50% dépassement) else HTS_STAT.HTS_TOTAL_RECV_STATE=3; // énormément (>50% dépassement) } } */ } #endif // --- // sous routines liées au moteur et au backing // supplemental links ready (done) after ptr or ready in background int backlinks_done(const struct_back * sback, lien_url ** liens, int lien_tot, int ptr) { int n = 0; #if 0 int i; //Links done and stored in cache for(i = ptr + 1; i < lien_tot; i++) { if (heap(i)) { if (heap(i)->pass2 == -1) { n++; } } } #else // finalized in background n += HTS_STAT.stat_background; #endif n += back_done_incache(sback); return n; } // remplir backing si moins de max_bytes en mémoire HTS_INLINE int back_fillmax(struct_back * sback, httrackp * opt, cache_back * cache, int ptr, int numero_passe) { if (!opt->state.stop) { if (back_incache(sback) < opt->maxcache) { // pas trop en mémoire? return back_fill(sback, opt, cache, ptr, numero_passe); } } return -1; /* plus de place */ } int back_pluggable_sockets_strict(struct_back * sback, httrackp * opt) { int n = opt->maxsoc - back_nsoc(sback); // connect limiter if (n > 0 && opt->maxconn > 0 && HTS_STAT.last_connect > 0) { TStamp opTime = HTS_STAT.last_request ? HTS_STAT.last_request : HTS_STAT.last_connect; TStamp cTime = mtime_local(); TStamp lap = (cTime - opTime); TStamp minLap = (TStamp) (1000.0 / opt->maxconn); if (lap < minLap) { n = 0; } else if (minLap != 0) { int nMax = (int) (lap / minLap); n = min(n, nMax); } } return n; } int back_pluggable_sockets(struct_back * sback, httrackp * opt) { int n; // ajouter autant de socket qu'on peut ajouter n = back_pluggable_sockets_strict(sback, opt); // vérifier qu'il restera assez de place pour les tests ensuite (en théorie, 1 entrée libre restante suffirait) n = min(n, back_available(sback) - 8); // no space left on backing stack - do not back anymore if (back_stack_available(sback) <= 2) n = 0; return n; } // remplir backing int back_fill(struct_back * sback, httrackp * opt, cache_back * cache, int ptr, int numero_passe) { int n = back_pluggable_sockets(sback, opt); if (opt->savename_delayed == 2 && !opt->delayed_cached) /* cancel (always delayed) */ return 0; if (n > 0) { int p; if (ptr < cache->ptr_last) { /* restart (2 scans: first html, then non html) */ cache->ptr_ant = 0; } p = ptr + 1; /* on a déja parcouru */ if (p < cache->ptr_ant) p = cache->ptr_ant; while(p < opt->lien_tot && n > 0 && back_checkmirror(opt)) { //while((p0) && (p < ptr+opt->maxcache_anticipate)) { int ok = 1; // on ne met pas le fichier en backing si il doit être traité après ou s'il a déja été traité if (heap(p)->pass2) { // 2è passe if (numero_passe != 1) ok = 0; } else { if (numero_passe != 0) ok = 0; } // Why in hell did I do that ? //if (ok && heap(p)->sav != NULL && heap(p)->sav[0] != '\0' // && hash_read(opt->hash,heap(p)->sav,NULL,HASH_STRUCT_FILENAME ) >= 0) // lookup in liens_record //{ // ok = 0; //} if (heap(p)->sav == NULL || heap(p)->sav[0] == '\0' || hash_read(opt->hash, heap(p)->sav, NULL, HASH_STRUCT_FILENAME ) < 0) { ok = 0; } // note: si un backing est fini, il reste en mémoire jusqu'à ce que // le ptr l'atteigne if (ok) { if (!back_exist (sback, opt, heap(p)->adr, heap(p)->fil, heap(p)->sav)) { if (back_add (sback, opt, cache, heap(p)->adr, heap(p)->fil, heap(p)->sav, heap(heap(p)->precedent)->adr, heap(heap(p)->precedent)->fil, heap(p)->testmode) == -1) { hts_log_print(opt, LOG_DEBUG, "error: unable to add more links through back_add for back_fill"); #if BDEBUG==1 printf("error while adding\n"); #endif n = 0; // sortir } else { n--; #if BDEBUG==1 printf("backing: %s%s\n", heap(p)->adr, heap(p)->fil); #endif } } } p++; } // while /* sauver position dernière anticipation */ cache->ptr_ant = p; cache->ptr_last = ptr; } return 0; } // --- // Poll stdin.. si besoin #if HTS_POLL // lecture stdin des caractères disponibles int read_stdin(char *s, int max) { int i = 0; while((check_stdin()) && (i < (max - 1))) s[i++] = fgetc(stdin); s[i] = '\0'; return i; } #ifdef _WIN32 int check_stdin(void) { return (_kbhit()); } #else int check_flot(T_SOC s) { fd_set fds; struct timeval tv; FD_ZERO(&fds); FD_SET((T_SOC) s, &fds); tv.tv_sec = 0; tv.tv_usec = 0; select(s + 1, &fds, NULL, NULL, &tv); return FD_ISSET(s, &fds); } int check_stdin(void) { fflush(stdout); fflush(stdin); if (check_flot(0)) return 1; return 0; } #endif #endif int check_sockerror(T_SOC s) { fd_set fds; struct timeval tv; FD_ZERO(&fds); FD_SET((T_SOC) s, &fds); tv.tv_sec = 0; tv.tv_usec = 0; select((int) s + 1, NULL, NULL, &fds, &tv); return FD_ISSET(s, &fds); } /* check incoming data */ int check_sockdata(T_SOC s) { fd_set fds; struct timeval tv; FD_ZERO(&fds); FD_SET((T_SOC) s, &fds); tv.tv_sec = 0; tv.tv_usec = 0; select((int) s + 1, &fds, NULL, NULL, &tv); return FD_ISSET(s, &fds); } // Attente de touche int ask_continue(httrackp * opt) { const char *s; s = RUN_CALLBACK1(opt, query2, opt->state.HTbuff); if (s) { if (strnotempty(s)) { if ((strfield2(s, "N")) || (strfield2(s, "NO")) || (strfield2(s, "NON"))) return 0; } return 1; } return 1; } // nombre de digits dans un nombre int nombre_digit(int n) { int i = 1; while(n >= 10) { n /= 10; i++; } return i; } // renvoi adresse de la fin du token dans p // renvoi NULL si la chaine est un token unique // (PATCHE également la chaine) // ex: "test" "test2" renvoi adresse sur espace // flag==1 si chaine comporte des echappements comme \" char *next_token(char *p, int flag) { int detect = 0; int quote = 0; p--; do { p++; if (flag && (*p == '\\')) { // sauter \x ou \" if (quote) { char c = '\0'; if (*(p + 1) == '\\') c = '\\'; else if (*(p + 1) == '"') c = '"'; if (c) { char BIGSTK tempo[8192]; tempo[0] = c; tempo[1] = '\0'; strcatbuff(tempo, p + 2); strcpybuff(p, tempo); } } } else if (*p == 34) { // guillemets (de fin) char BIGSTK tempo[8192]; tempo[0] = '\0'; strcatbuff(tempo, p + 1); strcpybuff(p, tempo); /* wipe "" */ p--; /* */ quote = !quote; } else if (*p == 32) { if (!quote) detect = 1; } else if (*p == '\0') { p = NULL; detect = 1; } } while(!detect); return p; } static int hts_cancel_file_push_(httrackp * opt, const char *url) { if (url != NULL && url[0] != '\0') { htsoptstatecancel **cancel; /* search for available place to store a new htsoptstatecancel* */ for(cancel = &opt->state.cancel; *cancel != NULL; cancel = &((*cancel)->next)) { if (strcmp((*cancel)->url, url) == 0) { return 1; /* already there */ } } *cancel = malloct(sizeof(htsoptstatecancel)); (*cancel)->next = NULL; (*cancel)->url = strdupt(url); return 0; } return 1; } /* cancel a file (locked) */ HTSEXT_API int hts_cancel_file_push(httrackp * opt, const char *url) { int ret; hts_mutexlock(&opt->state.lock); ret = hts_cancel_file_push_(opt, url); hts_mutexrelease(&opt->state.lock); return ret; } static char *hts_cancel_file_pop_(httrackp * opt) { if (opt->state.cancel != NULL) { htsoptstatecancel **cancel; htsoptstatecancel *ret; for(cancel = &opt->state.cancel; (*cancel)->next != NULL; cancel = &((*cancel)->next)) ; ret = *cancel; *cancel = NULL; return ret->url; } return NULL; /* no entry */ } char *hts_cancel_file_pop(httrackp * opt) { char *ret; hts_mutexlock(&opt->state.lock); ret = hts_cancel_file_pop_(opt); hts_mutexrelease(&opt->state.lock); return ret; } HTSEXT_API void hts_cancel_test(httrackp * opt) { if (opt->state._hts_in_html_parsing == 2) opt->state._hts_cancel = 2; } HTSEXT_API void hts_cancel_parsing(httrackp * opt) { if (opt->state._hts_in_html_parsing) opt->state._hts_cancel = 1; } // en train de parser un fichier html? réponse: % effectués // flag>0 : refresh demandé HTSEXT_API int hts_is_parsing(httrackp * opt, int flag) { if (opt->state._hts_in_html_parsing) { // parsing? if (flag >= 0) opt->state._hts_in_html_poll = 1; // faudrait un tit refresh return max(opt->state._hts_in_html_done, 1); // % effectués } else { return 0; // non } } HTSEXT_API int hts_is_testing(httrackp * opt) { // 0 non 1 test 2 purge if (opt->state._hts_in_html_parsing == 2) return 1; else if (opt->state._hts_in_html_parsing == 3) return 2; else if (opt->state._hts_in_html_parsing == 4) return 3; else if (opt->state._hts_in_html_parsing == 5) // scheduling return 4; else if (opt->state._hts_in_html_parsing == 6) // wait for slot return 5; return 0; } HTSEXT_API int hts_is_exiting(httrackp * opt) { return opt->state.exit_xh; } // message d'erreur? char *hts_errmsg(httrackp * opt) { return opt->state._hts_errmsg; } // mode pause transfer HTSEXT_API int hts_setpause(httrackp * opt, int p) { if (p >= 0) opt->state._hts_setpause = p; return opt->state._hts_setpause; } // ask for termination HTSEXT_API int hts_request_stop(httrackp * opt, int force) { if (opt != NULL) { hts_log_print(opt, LOG_ERROR, "Exit requested by shell or user"); hts_mutexlock(&opt->state.lock); opt->state.stop = 1; hts_mutexrelease(&opt->state.lock); } return 0; } HTSEXT_API int hts_has_stopped(httrackp * opt) { int ended; hts_mutexlock(&opt->state.lock); ended = opt->state.is_ended; hts_mutexrelease(&opt->state.lock); return ended; } // régler en cours de route les paramètres réglables.. // -1 : erreur //HTSEXT_API int hts_setopt(httrackp* set_opt) { // if (set_opt) { // httrackp* engine_opt=hts_declareoptbuffer(NULL); // if (engine_opt) { // //_hts_setopt=opt; // copy_htsopt(set_opt,engine_opt); // } // } // return 0; //} // ajout d'URL // -1 : erreur HTSEXT_API int hts_addurl(httrackp * opt, char **url) { if (url) opt->state._hts_addurl = url; return (opt->state._hts_addurl != NULL); } HTSEXT_API int hts_resetaddurl(httrackp * opt) { opt->state._hts_addurl = NULL; return (opt->state._hts_addurl != NULL); } // copier nouveaux paramètres si besoin HTSEXT_API int copy_htsopt(const httrackp * from, httrackp * to) { if (from->maxsite > -1) to->maxsite = from->maxsite; if (from->maxfile_nonhtml > -1) to->maxfile_nonhtml = from->maxfile_nonhtml; if (from->maxfile_html > -1) to->maxfile_html = from->maxfile_html; if (from->maxsoc > 0) to->maxsoc = from->maxsoc; if (from->nearlink > -1) to->nearlink = from->nearlink; if (from->timeout > -1) to->timeout = from->timeout; if (from->rateout > -1) to->rateout = from->rateout; if (from->maxtime > -1) to->maxtime = from->maxtime; if (from->maxrate > -1) to->maxrate = from->maxrate; if (from->maxconn > 0) to->maxconn = from->maxconn; if (StringNotEmpty(from->user_agent)) StringCopyS(to->user_agent, from->user_agent); if (from->retry > -1) to->retry = from->retry; if (from->hostcontrol > -1) to->hostcontrol = from->hostcontrol; if (from->errpage > -1) to->errpage = from->errpage; if (from->parseall > -1) to->parseall = from->parseall; // test all: bit 8 de travel if (from->travel > -1) { if (from->travel & 256) to->travel |= 256; else to->travel &= 255; } return 0; } // /* External modules callback */ int htsAddLink(htsmoduleStruct * str, char *link) { if (link != NULL && str != NULL && link[0] != '\0') { ENGINE_LOAD_CONTEXT_BASE(); /* */ lien_adrfilsave afs; char BIGSTK codebase[HTS_URLMAXSIZE * 2]; /* */ int pass_fix, prio_fix; /* */ int forbidden_url = 1; codebase[0] = '\0'; hts_log_print(opt, LOG_DEBUG, "(module): adding link : '%s'", link); // recopie de "creer le lien" // if (!RUN_CALLBACK1(opt, linkdetected, link)) { hts_log_print(opt, LOG_ERROR, "Link %s refused by external wrapper", link); return 0; } if (!RUN_CALLBACK2(opt, linkdetected2, link, NULL)) { hts_log_print(opt, LOG_ERROR, "Link %s refused by external wrapper(2)", link); return 0; } // adr = c'est la même // fil et save: save2 et fil2 prio_fix = maximum(heap(ptr)->depth - 1, 0); pass_fix = max(heap(ptr)->pass2, numero_passe); if (heap(ptr)->cod) strcpybuff(codebase, heap(ptr)->cod); // codebase valable pour tt les classes descendantes if (strnotempty(codebase) == 0) { // pas de codebase, construire char *a; if (str->relativeToHtmlLink == 0) strcpybuff(codebase, heap(ptr)->fil); else strcpybuff(codebase, heap(heap(ptr)->precedent)->fil); a = codebase + strlen(codebase) - 1; while((*a) && (*a != '/') && (a > codebase)) a--; if (*a == '/') *(a + 1) = '\0'; // couper } else { // couper http:// éventuel if (strfield(codebase, "http://")) { char BIGSTK tempo[HTS_URLMAXSIZE * 2]; char *a = codebase + 7; a = strchr(a, '/'); // après host if (a) { // ** msg erreur et vérifier? strcpybuff(tempo, a); strcpybuff(codebase, tempo); // couper host } else { hts_log_print(opt, LOG_ERROR, "Unexpected strstr error in base %s", codebase); } } } if (!((int) strlen(codebase) < HTS_URLMAXSIZE)) { // trop long hts_log_print(opt, LOG_ERROR, "Codebase too long, parsing skipped (%s)", codebase); } { char *lien = link; int dejafait = 0; if (strnotempty(lien) && strlen(lien) < HTS_URLMAXSIZE) { // calculer les chemins et noms de sauvegarde if (ident_url_relatif(lien, urladr(), codebase, &afs.af) >= 0) { // reformage selon chemin int r; int set_prio_to = 0; int just_test_it = 0; forbidden_url = hts_acceptlink(opt, ptr, afs.af.adr, afs.af.fil, NULL, NULL, &set_prio_to, &just_test_it); hts_log_print(opt, LOG_DEBUG, "result for wizard external module link: %d", forbidden_url); /* Link accepted */ if (!forbidden_url) { char BIGSTK tempo[HTS_URLMAXSIZE * 2]; int a, b; tempo[0] = '\0'; a = opt->savename_type; b = opt->savename_83; opt->savename_type = 0; opt->savename_83 = 0; // note: adr,fil peuvent être patchés r = url_savename(&afs, NULL, NULL, NULL, opt, sback, cache, hashptr, ptr, numero_passe, NULL); // resolve unresolved type if (r != -1 && forbidden_url == 0 && IS_DELAYED_EXT(afs.save) ) { // pas d'erreur, on continue lien_adrfil former; former.adr[0] = former.fil[0] = '\0'; r = hts_wait_delayed(str, &afs, NULL, NULL, &former, &forbidden_url); } // end resolve unresolved type opt->savename_type = a; opt->savename_83 = b; if (r != -1 && !forbidden_url) { if (savename()) { if (lienrelatif(tempo, afs.save, savename()) == 0) { hts_log_print(opt, LOG_DEBUG, "(module): relative link at %s build with %s and %s: %s", afs.af.adr, afs.save, savename(), tempo); if (str->localLink && str->localLinkSize > (int) strlen(tempo) + 1) { strcpybuff(str->localLink, tempo); } } } } } if (forbidden_url) { hts_log_print(opt, LOG_DEBUG, "(module): file not caught: %s", lien); if (str->localLink && str->localLinkSize > (int) (strlen(afs.af.adr) + strlen(afs.af.fil) + 8)) { str->localLink[0] = '\0'; if (!link_has_authority(afs.af.adr)) strcpybuff(str->localLink, "http://"); strcatbuff(str->localLink, afs.af.adr); strcatbuff(str->localLink, afs.af.fil); } r = -1; } // if (r != -1) { hts_log_print(opt, LOG_DEBUG, "(module): %s%s -> %s (base %s)", afs.af.adr, afs.af.fil, afs.save, codebase); // modifié par rapport à l'autre version (cf prio_fix notamment et save2) // vérifier que le lien n'a pas déja été noté // si c'est le cas, alors il faut s'assurer que la priorité associée // au fichier est la plus grande des deux priorités // // On part de la fin et on essaye de se presser (économise temps machine) { int i = hash_read(hashptr, afs.save, NULL, HASH_STRUCT_FILENAME ); // lecture type 0 (sav) if (i >= 0) { heap(i)->depth = maximum(heap(i)->depth, prio_fix); dejafait = 1; } } if (!dejafait) { // // >>>> CREER LE LIEN JAVA <<<< // enregistrer fichier (MACRO) if (!hts_record_link(opt, afs.af.adr, afs.af.fil, afs.save, "", "", "")) { // erreur, pas de place réservée opt->state.exit_xh = -1; /* fatal error -> exit */ return 0; } // mode test? heap_top()->testmode = 0; // pas mode test heap_top()->link_import = 0; // pas mode import // écrire autres paramètres de la structure-lien //if (meme_adresse) heap_top()->premier = heap(ptr)->premier; //else // sinon l'objet père est le précédent lui même // heap_top()->premier=ptr; heap_top()->precedent = ptr; // noter la priorité if (!set_prio_to) heap_top()->depth = prio_fix; else heap_top()->depth = max(0, min(heap(ptr)->depth - 1, set_prio_to - 1)); // PRIORITE NULLE (catch page) heap_top()->pass2 = max(pass_fix, numero_passe); heap_top()->retry = opt->retry; //strcpybuff(heap_top()->adr,adr); //strcpybuff(heap_top()->fil,fil); //strcpybuff(heap_top()->sav,save); hts_log_print(opt, LOG_DEBUG, "(module): OK, NOTE: %s%s -> %s", heap_top()->adr, heap_top()->fil, heap_top()->sav); } } } } } /* Apply changes */ ENGINE_SAVE_CONTEXT_BASE(); return (forbidden_url == 0); } return 0; } // message copyright interne void voidf(void) { static const char *a; a = "" CRLF "" CRLF; a = "+-----------------------------------------------+" CRLF; a = "|HyperTextTRACKer, Offline Browser Utility |" CRLF; a = "| HTTrack Website Copier |" CRLF; a = "|Code: Windows Interface Xavier Roche |" CRLF; a = "| HTS/HTTrack Xavier Roche |" CRLF; a = "| .class Parser Yann Philippot |" CRLF; a = "| |" CRLF; a = "|Tested on: Windows95,98,NT,2K |" CRLF; a = "| Linux PC |" CRLF; a = "| Sun-Solaris 5.6 |" CRLF; a = "| AIX 4 |" CRLF; a = "| |" CRLF; a = "|Copyright (C) Xavier Roche and other |" CRLF; a = "|contributors |" CRLF; a = "| |" CRLF; a = "|Use this program at your own risks! |" CRLF; a = "+-----------------------------------------------+" CRLF; a = "" CRLF; (void) a; } // HTTrack Website Copier Copyright (C) 1998-2017 Xavier Roche and other contributors // httrack-3.49.5/src/htsjava.h0000644000175000017500000000401014336470674012606 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Java classes parser .h */ /* Author: Yann Philippot */ /* ------------------------------------------------------------ */ #ifndef HTSJAVA_DEFH #define HTSJAVA_DEFH #ifndef HTS_DEF_FWSTRUCT_JAVA_HEADER #define HTS_DEF_FWSTRUCT_JAVA_HEADER typedef struct JAVA_HEADER JAVA_HEADER; #endif struct JAVA_HEADER { unsigned long int magic; unsigned short int minor; unsigned short int major; unsigned short int count; }; #ifndef HTS_DEF_FWSTRUCT_RESP_STRUCT #define HTS_DEF_FWSTRUCT_RESP_STRUCT typedef struct RESP_STRUCT RESP_STRUCT; #endif struct RESP_STRUCT { int file_position; // unsigned int index1; unsigned int type; char name[1024]; }; /* Library internal definictions */ #ifdef HTS_INTERNAL_BYTECODE EXTERNAL_FUNCTION int hts_plug_java(httrackp * opt, const char *argv); #endif #endif httrack-3.49.5/src/htsjava.c0000644000175000017500000003220314360553245012577 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Java classes parser */ /* Author: Yann Philippot */ /* ------------------------------------------------------------ */ /* Version: Oct/2000 */ /* Fixed: problems with class structure (10/2000) */ // htsjava.c - Parseur de classes java #ifdef HAVE_CONFIG_H #include "config.h" #endif #include #include #include #include #if ( defined(_WIN32) ||defined(HAVE_SYS_TYPES_H) ) #include #endif #ifdef HAVE_UNISTD_H #include #endif /* Standard httrack module includes */ #include "httrack-library.h" #include "htsopt.h" #include "htsdefines.h" /* Module structures */ #include "htsmodules.h" /* We link to libhttrack, we can use its functions */ #include "httrack-library.h" /* This file */ #include "htsjava.h" static int reverse_endian(void) { int endian = 1; return (*((char *) &endian) == 1); } /* big/little endian swap */ #define hts_swap16(A) ( (((A) & 0xFF)<<8) | (((A) & 0xFF00)>>8) ) #define hts_swap32(A) ( (( (hts_swap16(A)) & 0xFFFF)<<16) | (( (hts_swap16(A>>16)) & 0xFFFF)) ) /* Static definitions */ static RESP_STRUCT readtable(htsmoduleStruct * str, FILE * fp, RESP_STRUCT, int *); static unsigned short int readshort(FILE * fp); static int tris(httrackp * opt, char *); static char *printname(char[1024], char[1024]); // ** HTS_xx sinon pas pris par VC++ #define HTS_CLASS 7 #define HTS_FIELDREF 9 #define HTS_METHODREF 10 #define HTS_STRING 8 #define HTS_INTEGER 3 #define HTS_FLOAT 4 #define HTS_LONG 5 #define HTS_DOUBLE 6 #define HTS_INTERFACE 11 #define HTS_NAMEANDTYPE 12 #define HTS_ASCIZ 1 #define HTS_UNICODE 2 #define JAVADEBUG 0 static const char *libName = "htsjava"; #ifdef _WIN32 #define strcasecmp(a,b) stricmp(a,b) #define strncasecmp(a,b,n) strnicmp(a,b,n) #endif static int detect_mime(htsmoduleStruct * str) { const char *savename = str->filename; if (savename) { int len = (int) strlen(savename); if (len > 6 && strcasecmp(savename + len - 6, ".class") == 0) { return 1; } } return 0; } static int hts_detect_java(t_hts_callbackarg * carg, httrackp * opt, htsmoduleStruct * str) { /* Call parent functions if multiple callbacks are chained. */ if (CALLBACKARG_PREV_FUN(carg, detect) != NULL) { if (CALLBACKARG_PREV_FUN(carg, detect) (CALLBACKARG_PREV_CARG(carg), opt, str)) { return 1; /* Found before us, let them have the priority */ } } /* Check MIME */ if (detect_mime(str)) { str->wrapper_name = libName; /* Our ID */ return 1; /* Known format, we take it */ } return 0; /* Unknown format */ } static off_t fsize(const char *s) { STRUCT_STAT st; if (STAT(s, &st) == 0 && S_ISREG(st.st_mode)) { return st.st_size; } else { return -1; } } static int hts_parse_java(t_hts_callbackarg * carg, httrackp * opt, htsmoduleStruct * str) { /* The wrapper_name memebr has changed: not for us anymore */ if (str->wrapper_name == NULL || strcmp(str->wrapper_name, libName) != 0) { /* Call parent functions if multiple callbacks are chained. */ if (CALLBACKARG_PREV_FUN(carg, parse) != NULL) { return CALLBACKARG_PREV_FUN(carg, parse) (CALLBACKARG_PREV_CARG(carg), opt, str); } strcpy(str->err_msg, "unexpected error: bad wrapper_name and no previous wrapper"); return 0; /* Unexpected error */ } else { if (detect_mime(str)) { /* (Legacy code) */ char catbuff[CATBUFF_SIZE]; FILE *fpout; JAVA_HEADER header; RESP_STRUCT *tab; const char *file = str->filename; str->relativeToHtmlLink = 1; #if JAVADEBUG printf("fopen\n"); #endif if ((fpout = FOPEN(fconv(catbuff, sizeof(catbuff), file), "r+b")) == NULL) { //fprintf(stderr, "Cannot open input file.\n"); sprintf(str->err_msg, "Unable to open file %s", file); return 0; // une erreur.. } #if JAVADEBUG printf("fread\n"); #endif //if (fread(&header,1,sizeof(JAVA_HEADER),fpout) != sizeof(JAVA_HEADER)) { // pas complet.. if (fread(&header, 1, 10, fpout) != 10) { // pas complet.. fclose(fpout); sprintf(str->err_msg, "File header too small (file len = " LLintP ")", (LLint) fsize(file)); return 0; } #if JAVADEBUG printf("header\n"); #endif // tester en tête if (reverse_endian()) { header.magic = hts_swap32(header.magic); header.count = hts_swap16(header.count); } if (header.magic != 0xCAFEBABE) { sprintf(str->err_msg, "non java file"); if (fpout) { fclose(fpout); fpout = NULL; } return 0; } tab = (RESP_STRUCT *) calloc(header.count, sizeof(RESP_STRUCT)); if (!tab) { sprintf(str->err_msg, "Unable to alloc %d bytes", (int) sizeof(RESP_STRUCT)); if (fpout) { fclose(fpout); fpout = NULL; } return 0; // erreur.. } #if JAVADEBUG printf("calchead\n"); #endif { int i; for(i = 1; i < header.count; i++) { int err = 0; // ++ tab[i] = readtable(str, fpout, tab[i], &err); if (!err) { if ((tab[i].type == HTS_LONG) || (tab[i].type == HTS_DOUBLE)) i++; //2 element si double ou float } else { // ++ une erreur est survenue! if (strnotempty(str->err_msg) == 0) strcpy(str->err_msg, "Internal readtable error"); free(tab); if (fpout) { fclose(fpout); fpout = NULL; } return 0; } } } #if JAVADEBUG printf("addfiles\n"); #endif { //unsigned int acess; unsigned int Class; unsigned int SClass; int i; //acess = readshort(fpout); Class = readshort(fpout); SClass = readshort(fpout); for(i = 1; i < header.count; i++) { if (tab[i].type == HTS_CLASS) { if ((tab[i].index1 < header.count) && (tab[i].index1 >= 0)) { if ((tab[i].index1 != SClass) && (tab[i].index1 != Class) && (tab[tab[i].index1].name[0] != '[')) { if (!strstr(tab[tab[i].index1].name, "java/")) { char BIGSTK tempo[1024]; tempo[0] = '\0'; snprintf(tempo, sizeof(tempo), "%s.class", tab[tab[i].index1].name); #if JAVADEBUG printf("add %s\n", tempo); #endif if (tab[tab[i].index1].file_position >= 0) str->addLink(str, tempo); /* tab[tab[i].index1].file_position */ } } } else { i = header.count; // exit } } } } #if JAVADEBUG printf("end\n"); #endif free(tab); if (fpout) { fclose(fpout); fpout = NULL; } return 1; } else { strcpy(str->err_msg, "bad MIME type"); } } return 0; /* Error */ } /* module entry point */ EXTERNAL_FUNCTION int hts_plug(httrackp * opt, const char *argv); EXTERNAL_FUNCTION int hts_plug(httrackp * opt, const char *argv) { /* Plug callback functions */ CHAIN_FUNCTION(opt, detect, hts_detect_java, NULL); CHAIN_FUNCTION(opt, parse, hts_parse_java, NULL); return 1; /* success */ } // error: !=0 si erreur fatale static RESP_STRUCT readtable(htsmoduleStruct * str, FILE * fp, RESP_STRUCT trans, int *error) { char rname[1024]; unsigned short int length; int j; *error = 0; // pas d'erreur trans.file_position = -1; trans.type = (int) (unsigned char) fgetc(fp); switch (trans.type) { case HTS_CLASS: strcpy(trans.name, "Class"); trans.index1 = readshort(fp); break; case HTS_FIELDREF: strcpy(trans.name, "Field Reference"); trans.index1 = readshort(fp); readshort(fp); break; case HTS_METHODREF: strcpy(trans.name, "Method Reference"); trans.index1 = readshort(fp); readshort(fp); break; case HTS_INTERFACE: strcpy(trans.name, "Interface Method Reference"); trans.index1 = readshort(fp); readshort(fp); break; case HTS_NAMEANDTYPE: strcpy(trans.name, "Name and Type"); trans.index1 = readshort(fp); readshort(fp); break; case HTS_STRING: // CONSTANT_String strcpy(trans.name, "String"); trans.index1 = readshort(fp); break; case HTS_INTEGER: strcpy(trans.name, "Integer"); for(j = 0; j < 4; j++) fgetc(fp); break; case HTS_FLOAT: strcpy(trans.name, "Float"); for(j = 0; j < 4; j++) fgetc(fp); break; case HTS_LONG: strcpy(trans.name, "Long"); for(j = 0; j < 8; j++) fgetc(fp); break; case HTS_DOUBLE: strcpy(trans.name, "Double"); for(j = 0; j < 8; j++) fgetc(fp); break; case HTS_ASCIZ: case HTS_UNICODE: if (trans.type == HTS_ASCIZ) strcpy(trans.name, "HTS_ASCIZ"); else strcpy(trans.name, "HTS_UNICODE"); { char BIGSTK buffer[1024]; char *p; p = &buffer[0]; //fflush(fp); trans.file_position = ftell(fp); length = readshort(fp); if (length < HTS_URLMAXSIZE) { // while ((length > 0) && (length<500)) { while(length > 0) { *p++ = fgetc(fp); length--; } *p = '\0'; //#if JDEBUG // if(tris(buffer)==1) printf("%s\n ",buffer); // if(tris(buffer)==2) printf("%s\n ",printname(buffer)); //#endif if (tris(str->opt, buffer) == 1) str->addLink(str, buffer); /* trans.file_position */ else if (tris(str->opt, buffer) == 2) str->addLink(str, printname(rname, buffer)); strcpy(trans.name, buffer); } else { // gros pb while((length > 0) && (!feof(fp))) { fgetc(fp); length--; } if (!feof(fp)) { trans.type = -1; } else { sprintf(str->err_msg, "Internal structure error (ASCII)"); *error = 1; } return (trans); } } break; default: // printf("Type inconnue\n"); // on arrête tout sprintf(str->err_msg, "Internal structure unknown (type %d)", trans.type); *error = 1; return (trans); break; } return (trans); } static unsigned short int readshort(FILE * fp) { unsigned short int valint; if (fread(&valint, sizeof(valint), 1, fp) == 1) { if (reverse_endian()) return hts_swap16(valint); else return valint; } else { return 0; } } static int tris(httrackp * opt, char *buffer) { char catbuff[CATBUFF_SIZE]; // // Java if ((buffer[0] == '[') && buffer[1] == 'L' && (!strstr(buffer, "java/"))) return 2; if (strstr(buffer, ".gif") || strstr(buffer, ".jpg") || strstr(buffer, ".jpeg") || strstr(buffer, ".au")) return 1; // Ajouts R.X: test type // Autres fichiers { char type[256]; type[0] = '\0'; get_httptype(opt, type, buffer, 0); if (strnotempty(type)) // type reconnu! return 1; // ajout RX 05/2001 else if (is_dyntype(get_ext(catbuff, sizeof(catbuff), buffer))) // asp,cgi... return 1; } return 0; } static char *printname(char rname[1024], char name[1024]) { char *p; char *p1; size_t j; rname[0] = '\0'; // p = &name[0]; if (*p != '[') { return rname; // "" } p += 2; //rname=(char*)calloct(strlen(name)+8,sizeof(char)); p1 = rname; for(j = 0; name[j] != '\0'; j++, p++) { if (*p == '/') *p1 = '.'; if (*p == ';') { *p1 = '\0'; strcat(rname, ".class"); return rname; } else *p1 = *p; p1++; } p1 -= 3; *p1 = '\0'; return rname; } httrack-3.49.5/src/Makefile.in0000644000175000017500000032251214555203173013043 00000000000000# Makefile.in generated by automake 1.16.5 from Makefile.am. # @configure_input@ # Copyright (C) 1994-2021 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ VPATH = @srcdir@ am__is_gnu_make = { \ if test -z '$(MAKELEVEL)'; then \ false; \ elif test -n '$(MAKE_HOST)'; then \ true; \ elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ true; \ else \ false; \ fi; \ } am__make_running_with_option = \ case $${target_option-} in \ ?) ;; \ *) echo "am__make_running_with_option: internal error: invalid" \ "target option '$${target_option-}' specified" >&2; \ exit 1;; \ esac; \ has_opt=no; \ sane_makeflags=$$MAKEFLAGS; \ if $(am__is_gnu_make); then \ sane_makeflags=$$MFLAGS; \ else \ case $$MAKEFLAGS in \ *\\[\ \ ]*) \ bs=\\; \ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ esac; \ fi; \ skip_next=no; \ strip_trailopt () \ { \ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ }; \ for flg in $$sane_makeflags; do \ test $$skip_next = yes && { skip_next=no; continue; }; \ case $$flg in \ *=*|--*) continue;; \ -*I) strip_trailopt 'I'; skip_next=yes;; \ -*I?*) strip_trailopt 'I';; \ -*O) strip_trailopt 'O'; skip_next=yes;; \ -*O?*) strip_trailopt 'O';; \ -*l) strip_trailopt 'l'; skip_next=yes;; \ -*l?*) strip_trailopt 'l';; \ -[dEDm]) skip_next=yes;; \ -[JT]) skip_next=yes;; \ esac; \ case $$flg in \ *$$target_option*) has_opt=yes; break;; \ esac; \ done; \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkglibexecdir = $(libexecdir)/@PACKAGE@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ bin_PROGRAMS = proxytrack$(EXEEXT) httrack$(EXEEXT) htsserver$(EXEEXT) subdir = src ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/check_zlib.m4 \ $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/snprintf.m4 \ $(top_srcdir)/m4/visibility.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libdir)" \ "$(DESTDIR)$(whttrackrundir)" "$(DESTDIR)$(DevIncludesdir)" PROGRAMS = $(bin_PROGRAMS) am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ *) f=$$p;; \ esac; am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; am__install_max = 40 am__nobase_strip_setup = \ srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` am__nobase_strip = \ for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" am__nobase_list = $(am__nobase_strip_setup); \ for p in $$list; do echo "$$p $$p"; done | \ sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ if (++n[$$2] == $(am__install_max)) \ { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ END { for (dir in files) print dir, files[dir] }' am__base_list = \ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' am__uninstall_files_from_dir = { \ test -z "$$files" \ || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ $(am__cd) "$$dir" && rm -f $$files; }; \ } LTLIBRARIES = $(lib_LTLIBRARIES) am__DEPENDENCIES_1 = libhtsjava_la_DEPENDENCIES = $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) libhttrack.la am_libhtsjava_la_OBJECTS = htsjava.lo libhtsjava_la_OBJECTS = $(am_libhtsjava_la_OBJECTS) AM_V_lt = $(am__v_lt_@AM_V@) am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) am__v_lt_0 = --silent am__v_lt_1 = libhtsjava_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ $(libhtsjava_la_LDFLAGS) $(LDFLAGS) -o $@ libhttrack_la_DEPENDENCIES = $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) am__dirstamp = $(am__leading_dot)dirstamp am_libhttrack_la_OBJECTS = libhttrack_la-htscore.lo \ libhttrack_la-htsparse.lo libhttrack_la-htsback.lo \ libhttrack_la-htscache.lo libhttrack_la-htscatchurl.lo \ libhttrack_la-htsfilters.lo libhttrack_la-htsftp.lo \ libhttrack_la-htshash.lo coucal/libhttrack_la-coucal.lo \ libhttrack_la-htshelp.lo libhttrack_la-htslib.lo \ libhttrack_la-htscoremain.lo libhttrack_la-htsname.lo \ libhttrack_la-htsrobots.lo libhttrack_la-htstools.lo \ libhttrack_la-htswizard.lo libhttrack_la-htsalias.lo \ libhttrack_la-htsthread.lo libhttrack_la-htsindex.lo \ libhttrack_la-htsbauth.lo libhttrack_la-htsmd5.lo \ libhttrack_la-htszlib.lo libhttrack_la-htswrap.lo \ libhttrack_la-htsconcat.lo libhttrack_la-htsmodules.lo \ libhttrack_la-htscharset.lo libhttrack_la-punycode.lo \ libhttrack_la-htsencoding.lo libhttrack_la-md5.lo \ minizip/libhttrack_la-ioapi.lo \ minizip/libhttrack_la-mztools.lo \ minizip/libhttrack_la-unzip.lo minizip/libhttrack_la-zip.lo libhttrack_la_OBJECTS = $(am_libhttrack_la_OBJECTS) libhttrack_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=link $(CCLD) $(libhttrack_la_CFLAGS) \ $(CFLAGS) $(libhttrack_la_LDFLAGS) $(LDFLAGS) -o $@ am_htsserver_OBJECTS = htsserver-htsserver.$(OBJEXT) \ htsserver-htsweb.$(OBJEXT) htsserver_OBJECTS = $(am_htsserver_OBJECTS) htsserver_DEPENDENCIES = $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ libhttrack.la htsserver_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=link $(CCLD) $(htsserver_CFLAGS) \ $(CFLAGS) $(htsserver_LDFLAGS) $(LDFLAGS) -o $@ httrack_SOURCES = httrack.c httrack_OBJECTS = httrack-httrack.$(OBJEXT) httrack_DEPENDENCIES = $(am__DEPENDENCIES_1) libhttrack.la httrack_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=link $(CCLD) $(httrack_CFLAGS) \ $(CFLAGS) $(httrack_LDFLAGS) $(LDFLAGS) -o $@ am_proxytrack_OBJECTS = proxy/proxytrack-main.$(OBJEXT) \ proxy/proxytrack-proxytrack.$(OBJEXT) \ proxy/proxytrack-store.$(OBJEXT) \ coucal/proxytrack-coucal.$(OBJEXT) proxytrack-htsmd5.$(OBJEXT) \ proxytrack-md5.$(OBJEXT) minizip/proxytrack-ioapi.$(OBJEXT) \ minizip/proxytrack-mztools.$(OBJEXT) \ minizip/proxytrack-unzip.$(OBJEXT) \ minizip/proxytrack-zip.$(OBJEXT) proxytrack_OBJECTS = $(am_proxytrack_OBJECTS) proxytrack_DEPENDENCIES = $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) proxytrack_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=link $(CCLD) $(proxytrack_CFLAGS) \ $(CFLAGS) $(proxytrack_LDFLAGS) $(LDFLAGS) -o $@ SCRIPTS = $(whttrackrun_SCRIPTS) AM_V_P = $(am__v_P_@AM_V@) am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) am__v_P_0 = false am__v_P_1 = : AM_V_GEN = $(am__v_GEN_@AM_V@) am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) am__v_GEN_0 = @echo " GEN " $@; am__v_GEN_1 = AM_V_at = $(am__v_at_@AM_V@) am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) am__v_at_0 = @ am__v_at_1 = DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) depcomp = $(SHELL) $(top_srcdir)/depcomp am__maybe_remake_depfiles = depfiles am__depfiles_remade = ./$(DEPDIR)/htsjava.Plo \ ./$(DEPDIR)/htsserver-htsserver.Po \ ./$(DEPDIR)/htsserver-htsweb.Po ./$(DEPDIR)/httrack-httrack.Po \ ./$(DEPDIR)/libhttrack_la-htsalias.Plo \ ./$(DEPDIR)/libhttrack_la-htsback.Plo \ ./$(DEPDIR)/libhttrack_la-htsbauth.Plo \ ./$(DEPDIR)/libhttrack_la-htscache.Plo \ ./$(DEPDIR)/libhttrack_la-htscatchurl.Plo \ ./$(DEPDIR)/libhttrack_la-htscharset.Plo \ ./$(DEPDIR)/libhttrack_la-htsconcat.Plo \ ./$(DEPDIR)/libhttrack_la-htscore.Plo \ ./$(DEPDIR)/libhttrack_la-htscoremain.Plo \ ./$(DEPDIR)/libhttrack_la-htsencoding.Plo \ ./$(DEPDIR)/libhttrack_la-htsfilters.Plo \ ./$(DEPDIR)/libhttrack_la-htsftp.Plo \ ./$(DEPDIR)/libhttrack_la-htshash.Plo \ ./$(DEPDIR)/libhttrack_la-htshelp.Plo \ ./$(DEPDIR)/libhttrack_la-htsindex.Plo \ ./$(DEPDIR)/libhttrack_la-htslib.Plo \ ./$(DEPDIR)/libhttrack_la-htsmd5.Plo \ ./$(DEPDIR)/libhttrack_la-htsmodules.Plo \ ./$(DEPDIR)/libhttrack_la-htsname.Plo \ ./$(DEPDIR)/libhttrack_la-htsparse.Plo \ ./$(DEPDIR)/libhttrack_la-htsrobots.Plo \ ./$(DEPDIR)/libhttrack_la-htsthread.Plo \ ./$(DEPDIR)/libhttrack_la-htstools.Plo \ ./$(DEPDIR)/libhttrack_la-htswizard.Plo \ ./$(DEPDIR)/libhttrack_la-htswrap.Plo \ ./$(DEPDIR)/libhttrack_la-htszlib.Plo \ ./$(DEPDIR)/libhttrack_la-md5.Plo \ ./$(DEPDIR)/libhttrack_la-punycode.Plo \ ./$(DEPDIR)/proxytrack-htsmd5.Po ./$(DEPDIR)/proxytrack-md5.Po \ coucal/$(DEPDIR)/libhttrack_la-coucal.Plo \ coucal/$(DEPDIR)/proxytrack-coucal.Po \ minizip/$(DEPDIR)/libhttrack_la-ioapi.Plo \ minizip/$(DEPDIR)/libhttrack_la-mztools.Plo \ minizip/$(DEPDIR)/libhttrack_la-unzip.Plo \ minizip/$(DEPDIR)/libhttrack_la-zip.Plo \ minizip/$(DEPDIR)/proxytrack-ioapi.Po \ minizip/$(DEPDIR)/proxytrack-mztools.Po \ minizip/$(DEPDIR)/proxytrack-unzip.Po \ minizip/$(DEPDIR)/proxytrack-zip.Po \ proxy/$(DEPDIR)/proxytrack-main.Po \ proxy/$(DEPDIR)/proxytrack-proxytrack.Po \ proxy/$(DEPDIR)/proxytrack-store.Po am__mv = mv -f COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ $(AM_CFLAGS) $(CFLAGS) AM_V_CC = $(am__v_CC_@AM_V@) am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) am__v_CC_0 = @echo " CC " $@; am__v_CC_1 = CCLD = $(CC) LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ $(AM_LDFLAGS) $(LDFLAGS) -o $@ AM_V_CCLD = $(am__v_CCLD_@AM_V@) am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) am__v_CCLD_0 = @echo " CCLD " $@; am__v_CCLD_1 = SOURCES = $(libhtsjava_la_SOURCES) $(libhttrack_la_SOURCES) \ $(htsserver_SOURCES) httrack.c $(proxytrack_SOURCES) DIST_SOURCES = $(libhtsjava_la_SOURCES) $(libhttrack_la_SOURCES) \ $(htsserver_SOURCES) httrack.c $(proxytrack_SOURCES) am__can_run_installinfo = \ case $$AM_UPDATE_INFO_DIR in \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac DATA = $(DevIncludes_DATA) am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) # Read a list of newline-separated strings from the standard input, # and print each of them once, without duplicates. Input order is # *not* preserved. am__uniquify_input = $(AWK) '\ BEGIN { nonempty = 0; } \ { items[$$0] = 1; nonempty = 1; } \ END { if (nonempty) { for (i in items) print i; }; } \ ' # Make sure the list of sources is unique. This is necessary because, # e.g., the same source file might be shared among _SOURCES variables # for different programs/libraries. am__define_uniq_tagged_files = \ list='$(am__tagged_files)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | $(am__uniquify_input)` am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depcomp DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AM_CFLAGS = @AM_CFLAGS@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CFLAGS_PIE = @CFLAGS_PIE@ CFLAG_VISIBILITY = @CFLAG_VISIBILITY@ CPPFLAGS = @CPPFLAGS@ CSCOPE = @CSCOPE@ CTAGS = @CTAGS@ CYGPATH_W = @CYGPATH_W@ DEFAULT_CFLAGS = @DEFAULT_CFLAGS@ DEFAULT_LDFLAGS = @DEFAULT_LDFLAGS@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DLLTOOL = @DLLTOOL@ DL_LIBS = @DL_LIBS@ DSYMUTIL = @DSYMUTIL@ DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ ETAGS = @ETAGS@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ FILECMD = @FILECMD@ GREP = @GREP@ HAVE_VISIBILITY = @HAVE_VISIBILITY@ HTTPS_SUPPORT = @HTTPS_SUPPORT@ ICONV_LIBS = @ICONV_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LD = @LD@ LDFLAGS = @LDFLAGS@ LDFLAGS_PIE = @LDFLAGS_PIE@ LFS_FLAG = @LFS_FLAG@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ LIPO = @LIPO@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ LT_CV_OBJDIR = @LT_CV_OBJDIR@ LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ MAINT = @MAINT@ MAKEINFO = @MAKEINFO@ MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ NM = @NM@ NMEDIT = @NMEDIT@ OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ ONLINE_UNIT_TESTS = @ONLINE_UNIT_TESTS@ OPENSSL_LIBS = @OPENSSL_LIBS@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ RANLIB = @RANLIB@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ SHLIBPATH_VAR = @SHLIBPATH_VAR@ SOCKET_LIBS = @SOCKET_LIBS@ STRIP = @STRIP@ THREADS_CFLAGS = @THREADS_CFLAGS@ THREADS_LIBS = @THREADS_LIBS@ V6_FLAG = @V6_FLAG@ VERSION = @VERSION@ VERSION_INFO = @VERSION_INFO@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ builddir = @builddir@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ runstatedir = @runstatedir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ DevIncludesdir = $(includedir)/httrack DevIncludes_DATA = \ httrack-library.h \ htsglobal.h \ htsopt.h \ htswrap.h \ htsconfig.h \ ../config.h \ htsmodules.h \ htsbasenet.h \ htsnet.h \ htsbauth.h \ htsdefines.h \ htsstrings.h \ htsarrays.h \ htssafe.h AM_CPPFLAGS = \ @DEFAULT_CFLAGS@ \ @THREADS_CFLAGS@ \ @V6_FLAG@ \ @LFS_FLAG@ \ -DPREFIX=\""$(prefix)"\" \ -DSYSCONFDIR=\""$(sysconfdir)"\" \ -DDATADIR=\""$(datadir)"\" \ -DLIBDIR=\""$(libdir)"\" \ -I"$(abs_srcdir)" \ -I"$(abs_srcdir)/coucal" AM_LDFLAGS = \ @DEFAULT_LDFLAGS@ httrack_LDADD = $(THREADS_LIBS) libhttrack.la htsserver_LDADD = $(THREADS_LIBS) $(SOCKET_LIBS) libhttrack.la proxytrack_LDADD = $(THREADS_LIBS) $(SOCKET_LIBS) httrack_CFLAGS = $(AM_CFLAGS) $(CFLAGS_PIE) proxytrack_CFLAGS = $(AM_CFLAGS) $(CFLAGS_PIE) -DNO_MALLOCT -DZLIB_CONST -DHTS_INTHASH_USES_MD5 htsserver_CFLAGS = $(AM_CFLAGS) $(CFLAGS_PIE) -DZLIB_CONST -DHTS_INTHASH_USES_MD5 httrack_LDFLAGS = $(AM_LDFLAGS) $(LDFLAGS_PIE) proxytrack_LDFLAGS = $(AM_LDFLAGS) $(LDFLAGS_PIE) htsserver_LDFLAGS = $(AM_LDFLAGS) $(LDFLAGS_PIE) lib_LTLIBRARIES = libhttrack.la libhtsjava.la htsserver_SOURCES = htsserver.c htsserver.h htsweb.c htsweb.h proxytrack_SOURCES = proxy/main.c \ proxy/proxytrack.c proxy/store.c \ coucal/coucal.c htsmd5.c md5.c \ minizip/ioapi.c minizip/mztools.c minizip/unzip.c minizip/zip.c whttrackrundir = $(bindir) whttrackrun_SCRIPTS = webhttrack libhttrack_la_SOURCES = htscore.c htsparse.c htsback.c htscache.c \ htscatchurl.c htsfilters.c htsftp.c htshash.c coucal/coucal.c \ htshelp.c htslib.c htscoremain.c \ htsname.c htsrobots.c htstools.c htswizard.c \ htsalias.c htsthread.c htsindex.c htsbauth.c \ htsmd5.c htszlib.c htswrap.c htsconcat.c \ htsmodules.c htscharset.c punycode.c htsencoding.c \ md5.c \ minizip/ioapi.c minizip/mztools.c minizip/unzip.c minizip/zip.c \ hts-indextmpl.h htsalias.h htsback.h htsbase.h htssafe.h \ htsbasenet.h htsbauth.h htscache.h htscatchurl.h \ htsconfig.h htscore.h htsparse.h htscoremain.h htsdefines.h \ htsfilters.h htsftp.h htsglobal.h htshash.h coucal/coucal.h \ htshelp.h htsindex.h htslib.h htsmd5.h \ htsmodules.h htsname.h htsnet.h \ htsopt.h htsrobots.h htsthread.h \ htstools.h htswizard.h htswrap.h htszlib.h \ htsstrings.h htsarrays.h httrack-library.h \ htscharset.h punycode.h htsencoding.h \ htsentities.h htsentities.sh htsbasiccharsets.sh htscodepages.h \ md5.h coucal/murmurhash3.h \ minizip/crypt.h minizip/ioapi.h minizip/mztools.h minizip/unzip.h minizip/zip.h libhttrack_la_LIBADD = $(THREADS_LIBS) $(ZLIB_LIBS) $(OPENSSL_LIBS) $(DL_LIBS) $(SOCKET_LIBS) $(ICONV_LIBS) libhttrack_la_CFLAGS = $(AM_CFLAGS) -DLIBHTTRACK_EXPORTS -DZLIB_CONST libhttrack_la_LDFLAGS = $(AM_LDFLAGS) -version-info $(VERSION_INFO) libhtsjava_la_SOURCES = htsjava.c htsjava.h libhtsjava_la_LIBADD = $(THREADS_LIBS) $(DL_LIBS) libhttrack.la libhtsjava_la_LDFLAGS = $(AM_LDFLAGS) -version-info $(VERSION_INFO) EXTRA_DIST = httrack.h webhttrack \ coucal/murmurhash3.h.diff \ coucal/murmurhash3.h.orig \ minizip/iowin32.c \ minizip/iowin32.h \ minizip/ioapi.c.diff \ minizip/ioapi.h.diff \ minizip/zip.c.diff \ minizip/zip.h.diff \ minizip/mztools.c.diff \ minizip/ioapi.c.orig \ minizip/ioapi.h.orig \ minizip/mztools.c.orig \ minizip/zip.c.orig \ minizip/zip.h.orig \ minizip/MiniZip64_Changes.txt \ minizip/MiniZip64_info.txt \ proxy/AUTHORS \ proxy/COPYING \ proxy/changelog.txt \ proxy/proxystrings.h \ proxy/proxytrack.h \ proxy/store.h \ proxy/proxytrack.vcproj \ coucal/* \ *.dsw *.dsp *.vcproj all: all-am .SUFFIXES: .SUFFIXES: .c .lo .o .obj $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ && { if test -f $@; then exit 0; else break; fi; }; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu src/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --gnu src/Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(am__aclocal_m4_deps): install-binPROGRAMS: $(bin_PROGRAMS) @$(NORMAL_INSTALL) @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ if test -n "$$list"; then \ echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \ $(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \ fi; \ for p in $$list; do echo "$$p $$p"; done | \ sed 's/$(EXEEXT)$$//' | \ while read p p1; do if test -f $$p \ || test -f $$p1 \ ; then echo "$$p"; echo "$$p"; else :; fi; \ done | \ sed -e 'p;s,.*/,,;n;h' \ -e 's|.*|.|' \ -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ sed 'N;N;N;s,\n, ,g' | \ $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ if ($$2 == $$4) files[d] = files[d] " " $$1; \ else { print "f", $$3 "/" $$4, $$1; } } \ END { for (d in files) print "f", d, files[d] }' | \ while read type dir files; do \ if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ test -z "$$files" || { \ echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(bindir)$$dir'"; \ $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \ } \ ; done uninstall-binPROGRAMS: @$(NORMAL_UNINSTALL) @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ files=`for p in $$list; do echo "$$p"; done | \ sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ -e 's/$$/$(EXEEXT)/' \ `; \ test -n "$$list" || exit 0; \ echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \ cd "$(DESTDIR)$(bindir)" && rm -f $$files clean-binPROGRAMS: @list='$(bin_PROGRAMS)'; test -n "$$list" || exit 0; \ echo " rm -f" $$list; \ rm -f $$list || exit $$?; \ test -n "$(EXEEXT)" || exit 0; \ list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ echo " rm -f" $$list; \ rm -f $$list install-libLTLIBRARIES: $(lib_LTLIBRARIES) @$(NORMAL_INSTALL) @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ list2=; for p in $$list; do \ if test -f $$p; then \ list2="$$list2 $$p"; \ else :; fi; \ done; \ test -z "$$list2" || { \ echo " $(MKDIR_P) '$(DESTDIR)$(libdir)'"; \ $(MKDIR_P) "$(DESTDIR)$(libdir)" || exit 1; \ echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(libdir)'"; \ $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(libdir)"; \ } uninstall-libLTLIBRARIES: @$(NORMAL_UNINSTALL) @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ for p in $$list; do \ $(am__strip_dir) \ echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(libdir)/$$f'"; \ $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(libdir)/$$f"; \ done clean-libLTLIBRARIES: -test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES) @list='$(lib_LTLIBRARIES)'; \ locs=`for p in $$list; do echo $$p; done | \ sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ sort -u`; \ test -z "$$locs" || { \ echo rm -f $${locs}; \ rm -f $${locs}; \ } libhtsjava.la: $(libhtsjava_la_OBJECTS) $(libhtsjava_la_DEPENDENCIES) $(EXTRA_libhtsjava_la_DEPENDENCIES) $(AM_V_CCLD)$(libhtsjava_la_LINK) -rpath $(libdir) $(libhtsjava_la_OBJECTS) $(libhtsjava_la_LIBADD) $(LIBS) coucal/$(am__dirstamp): @$(MKDIR_P) coucal @: > coucal/$(am__dirstamp) coucal/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) coucal/$(DEPDIR) @: > coucal/$(DEPDIR)/$(am__dirstamp) coucal/libhttrack_la-coucal.lo: coucal/$(am__dirstamp) \ coucal/$(DEPDIR)/$(am__dirstamp) minizip/$(am__dirstamp): @$(MKDIR_P) minizip @: > minizip/$(am__dirstamp) minizip/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) minizip/$(DEPDIR) @: > minizip/$(DEPDIR)/$(am__dirstamp) minizip/libhttrack_la-ioapi.lo: minizip/$(am__dirstamp) \ minizip/$(DEPDIR)/$(am__dirstamp) minizip/libhttrack_la-mztools.lo: minizip/$(am__dirstamp) \ minizip/$(DEPDIR)/$(am__dirstamp) minizip/libhttrack_la-unzip.lo: minizip/$(am__dirstamp) \ minizip/$(DEPDIR)/$(am__dirstamp) minizip/libhttrack_la-zip.lo: minizip/$(am__dirstamp) \ minizip/$(DEPDIR)/$(am__dirstamp) libhttrack.la: $(libhttrack_la_OBJECTS) $(libhttrack_la_DEPENDENCIES) $(EXTRA_libhttrack_la_DEPENDENCIES) $(AM_V_CCLD)$(libhttrack_la_LINK) -rpath $(libdir) $(libhttrack_la_OBJECTS) $(libhttrack_la_LIBADD) $(LIBS) htsserver$(EXEEXT): $(htsserver_OBJECTS) $(htsserver_DEPENDENCIES) $(EXTRA_htsserver_DEPENDENCIES) @rm -f htsserver$(EXEEXT) $(AM_V_CCLD)$(htsserver_LINK) $(htsserver_OBJECTS) $(htsserver_LDADD) $(LIBS) httrack$(EXEEXT): $(httrack_OBJECTS) $(httrack_DEPENDENCIES) $(EXTRA_httrack_DEPENDENCIES) @rm -f httrack$(EXEEXT) $(AM_V_CCLD)$(httrack_LINK) $(httrack_OBJECTS) $(httrack_LDADD) $(LIBS) proxy/$(am__dirstamp): @$(MKDIR_P) proxy @: > proxy/$(am__dirstamp) proxy/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) proxy/$(DEPDIR) @: > proxy/$(DEPDIR)/$(am__dirstamp) proxy/proxytrack-main.$(OBJEXT): proxy/$(am__dirstamp) \ proxy/$(DEPDIR)/$(am__dirstamp) proxy/proxytrack-proxytrack.$(OBJEXT): proxy/$(am__dirstamp) \ proxy/$(DEPDIR)/$(am__dirstamp) proxy/proxytrack-store.$(OBJEXT): proxy/$(am__dirstamp) \ proxy/$(DEPDIR)/$(am__dirstamp) coucal/proxytrack-coucal.$(OBJEXT): coucal/$(am__dirstamp) \ coucal/$(DEPDIR)/$(am__dirstamp) minizip/proxytrack-ioapi.$(OBJEXT): minizip/$(am__dirstamp) \ minizip/$(DEPDIR)/$(am__dirstamp) minizip/proxytrack-mztools.$(OBJEXT): minizip/$(am__dirstamp) \ minizip/$(DEPDIR)/$(am__dirstamp) minizip/proxytrack-unzip.$(OBJEXT): minizip/$(am__dirstamp) \ minizip/$(DEPDIR)/$(am__dirstamp) minizip/proxytrack-zip.$(OBJEXT): minizip/$(am__dirstamp) \ minizip/$(DEPDIR)/$(am__dirstamp) proxytrack$(EXEEXT): $(proxytrack_OBJECTS) $(proxytrack_DEPENDENCIES) $(EXTRA_proxytrack_DEPENDENCIES) @rm -f proxytrack$(EXEEXT) $(AM_V_CCLD)$(proxytrack_LINK) $(proxytrack_OBJECTS) $(proxytrack_LDADD) $(LIBS) install-whttrackrunSCRIPTS: $(whttrackrun_SCRIPTS) @$(NORMAL_INSTALL) @list='$(whttrackrun_SCRIPTS)'; test -n "$(whttrackrundir)" || list=; \ if test -n "$$list"; then \ echo " $(MKDIR_P) '$(DESTDIR)$(whttrackrundir)'"; \ $(MKDIR_P) "$(DESTDIR)$(whttrackrundir)" || exit 1; \ fi; \ for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ if test -f "$$d$$p"; then echo "$$d$$p"; echo "$$p"; else :; fi; \ done | \ sed -e 'p;s,.*/,,;n' \ -e 'h;s|.*|.|' \ -e 'p;x;s,.*/,,;$(transform)' | sed 'N;N;N;s,\n, ,g' | \ $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1; } \ { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ if ($$2 == $$4) { files[d] = files[d] " " $$1; \ if (++n[d] == $(am__install_max)) { \ print "f", d, files[d]; n[d] = 0; files[d] = "" } } \ else { print "f", d "/" $$4, $$1 } } \ END { for (d in files) print "f", d, files[d] }' | \ while read type dir files; do \ if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ test -z "$$files" || { \ echo " $(INSTALL_SCRIPT) $$files '$(DESTDIR)$(whttrackrundir)$$dir'"; \ $(INSTALL_SCRIPT) $$files "$(DESTDIR)$(whttrackrundir)$$dir" || exit $$?; \ } \ ; done uninstall-whttrackrunSCRIPTS: @$(NORMAL_UNINSTALL) @list='$(whttrackrun_SCRIPTS)'; test -n "$(whttrackrundir)" || exit 0; \ files=`for p in $$list; do echo "$$p"; done | \ sed -e 's,.*/,,;$(transform)'`; \ dir='$(DESTDIR)$(whttrackrundir)'; $(am__uninstall_files_from_dir) mostlyclean-compile: -rm -f *.$(OBJEXT) -rm -f coucal/*.$(OBJEXT) -rm -f coucal/*.lo -rm -f minizip/*.$(OBJEXT) -rm -f minizip/*.lo -rm -f proxy/*.$(OBJEXT) distclean-compile: -rm -f *.tab.c @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/htsjava.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/htsserver-htsserver.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/htsserver-htsweb.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/httrack-httrack.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htsalias.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htsback.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htsbauth.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htscache.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htscatchurl.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htscharset.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htsconcat.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htscore.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htscoremain.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htsencoding.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htsfilters.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htsftp.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htshash.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htshelp.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htsindex.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htslib.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htsmd5.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htsmodules.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htsname.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htsparse.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htsrobots.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htsthread.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htstools.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htswizard.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htswrap.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-htszlib.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-md5.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhttrack_la-punycode.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/proxytrack-htsmd5.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/proxytrack-md5.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@coucal/$(DEPDIR)/libhttrack_la-coucal.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@coucal/$(DEPDIR)/proxytrack-coucal.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@minizip/$(DEPDIR)/libhttrack_la-ioapi.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@minizip/$(DEPDIR)/libhttrack_la-mztools.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@minizip/$(DEPDIR)/libhttrack_la-unzip.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@minizip/$(DEPDIR)/libhttrack_la-zip.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@minizip/$(DEPDIR)/proxytrack-ioapi.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@minizip/$(DEPDIR)/proxytrack-mztools.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@minizip/$(DEPDIR)/proxytrack-unzip.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@minizip/$(DEPDIR)/proxytrack-zip.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@proxy/$(DEPDIR)/proxytrack-main.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@proxy/$(DEPDIR)/proxytrack-proxytrack.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@proxy/$(DEPDIR)/proxytrack-store.Po@am__quote@ # am--include-marker $(am__depfiles_remade): @$(MKDIR_P) $(@D) @echo '# dummy' >$@-t && $(am__mv) $@-t $@ am--depfiles: $(am__depfiles_remade) .c.o: @am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.o$$||'`;\ @am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\ @am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< .c.obj: @am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.obj$$||'`;\ @am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ `$(CYGPATH_W) '$<'` &&\ @am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` .c.lo: @am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.lo$$||'`;\ @am__fastdepCC_TRUE@ $(LTCOMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\ @am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< libhttrack_la-htscore.lo: htscore.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htscore.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htscore.Tpo -c -o libhttrack_la-htscore.lo `test -f 'htscore.c' || echo '$(srcdir)/'`htscore.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htscore.Tpo $(DEPDIR)/libhttrack_la-htscore.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htscore.c' object='libhttrack_la-htscore.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htscore.lo `test -f 'htscore.c' || echo '$(srcdir)/'`htscore.c libhttrack_la-htsparse.lo: htsparse.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htsparse.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htsparse.Tpo -c -o libhttrack_la-htsparse.lo `test -f 'htsparse.c' || echo '$(srcdir)/'`htsparse.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htsparse.Tpo $(DEPDIR)/libhttrack_la-htsparse.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htsparse.c' object='libhttrack_la-htsparse.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htsparse.lo `test -f 'htsparse.c' || echo '$(srcdir)/'`htsparse.c libhttrack_la-htsback.lo: htsback.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htsback.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htsback.Tpo -c -o libhttrack_la-htsback.lo `test -f 'htsback.c' || echo '$(srcdir)/'`htsback.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htsback.Tpo $(DEPDIR)/libhttrack_la-htsback.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htsback.c' object='libhttrack_la-htsback.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htsback.lo `test -f 'htsback.c' || echo '$(srcdir)/'`htsback.c libhttrack_la-htscache.lo: htscache.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htscache.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htscache.Tpo -c -o libhttrack_la-htscache.lo `test -f 'htscache.c' || echo '$(srcdir)/'`htscache.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htscache.Tpo $(DEPDIR)/libhttrack_la-htscache.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htscache.c' object='libhttrack_la-htscache.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htscache.lo `test -f 'htscache.c' || echo '$(srcdir)/'`htscache.c libhttrack_la-htscatchurl.lo: htscatchurl.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htscatchurl.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htscatchurl.Tpo -c -o libhttrack_la-htscatchurl.lo `test -f 'htscatchurl.c' || echo '$(srcdir)/'`htscatchurl.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htscatchurl.Tpo $(DEPDIR)/libhttrack_la-htscatchurl.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htscatchurl.c' object='libhttrack_la-htscatchurl.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htscatchurl.lo `test -f 'htscatchurl.c' || echo '$(srcdir)/'`htscatchurl.c libhttrack_la-htsfilters.lo: htsfilters.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htsfilters.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htsfilters.Tpo -c -o libhttrack_la-htsfilters.lo `test -f 'htsfilters.c' || echo '$(srcdir)/'`htsfilters.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htsfilters.Tpo $(DEPDIR)/libhttrack_la-htsfilters.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htsfilters.c' object='libhttrack_la-htsfilters.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htsfilters.lo `test -f 'htsfilters.c' || echo '$(srcdir)/'`htsfilters.c libhttrack_la-htsftp.lo: htsftp.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htsftp.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htsftp.Tpo -c -o libhttrack_la-htsftp.lo `test -f 'htsftp.c' || echo '$(srcdir)/'`htsftp.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htsftp.Tpo $(DEPDIR)/libhttrack_la-htsftp.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htsftp.c' object='libhttrack_la-htsftp.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htsftp.lo `test -f 'htsftp.c' || echo '$(srcdir)/'`htsftp.c libhttrack_la-htshash.lo: htshash.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htshash.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htshash.Tpo -c -o libhttrack_la-htshash.lo `test -f 'htshash.c' || echo '$(srcdir)/'`htshash.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htshash.Tpo $(DEPDIR)/libhttrack_la-htshash.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htshash.c' object='libhttrack_la-htshash.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htshash.lo `test -f 'htshash.c' || echo '$(srcdir)/'`htshash.c coucal/libhttrack_la-coucal.lo: coucal/coucal.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT coucal/libhttrack_la-coucal.lo -MD -MP -MF coucal/$(DEPDIR)/libhttrack_la-coucal.Tpo -c -o coucal/libhttrack_la-coucal.lo `test -f 'coucal/coucal.c' || echo '$(srcdir)/'`coucal/coucal.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) coucal/$(DEPDIR)/libhttrack_la-coucal.Tpo coucal/$(DEPDIR)/libhttrack_la-coucal.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='coucal/coucal.c' object='coucal/libhttrack_la-coucal.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o coucal/libhttrack_la-coucal.lo `test -f 'coucal/coucal.c' || echo '$(srcdir)/'`coucal/coucal.c libhttrack_la-htshelp.lo: htshelp.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htshelp.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htshelp.Tpo -c -o libhttrack_la-htshelp.lo `test -f 'htshelp.c' || echo '$(srcdir)/'`htshelp.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htshelp.Tpo $(DEPDIR)/libhttrack_la-htshelp.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htshelp.c' object='libhttrack_la-htshelp.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htshelp.lo `test -f 'htshelp.c' || echo '$(srcdir)/'`htshelp.c libhttrack_la-htslib.lo: htslib.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htslib.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htslib.Tpo -c -o libhttrack_la-htslib.lo `test -f 'htslib.c' || echo '$(srcdir)/'`htslib.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htslib.Tpo $(DEPDIR)/libhttrack_la-htslib.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htslib.c' object='libhttrack_la-htslib.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htslib.lo `test -f 'htslib.c' || echo '$(srcdir)/'`htslib.c libhttrack_la-htscoremain.lo: htscoremain.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htscoremain.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htscoremain.Tpo -c -o libhttrack_la-htscoremain.lo `test -f 'htscoremain.c' || echo '$(srcdir)/'`htscoremain.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htscoremain.Tpo $(DEPDIR)/libhttrack_la-htscoremain.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htscoremain.c' object='libhttrack_la-htscoremain.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htscoremain.lo `test -f 'htscoremain.c' || echo '$(srcdir)/'`htscoremain.c libhttrack_la-htsname.lo: htsname.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htsname.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htsname.Tpo -c -o libhttrack_la-htsname.lo `test -f 'htsname.c' || echo '$(srcdir)/'`htsname.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htsname.Tpo $(DEPDIR)/libhttrack_la-htsname.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htsname.c' object='libhttrack_la-htsname.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htsname.lo `test -f 'htsname.c' || echo '$(srcdir)/'`htsname.c libhttrack_la-htsrobots.lo: htsrobots.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htsrobots.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htsrobots.Tpo -c -o libhttrack_la-htsrobots.lo `test -f 'htsrobots.c' || echo '$(srcdir)/'`htsrobots.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htsrobots.Tpo $(DEPDIR)/libhttrack_la-htsrobots.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htsrobots.c' object='libhttrack_la-htsrobots.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htsrobots.lo `test -f 'htsrobots.c' || echo '$(srcdir)/'`htsrobots.c libhttrack_la-htstools.lo: htstools.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htstools.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htstools.Tpo -c -o libhttrack_la-htstools.lo `test -f 'htstools.c' || echo '$(srcdir)/'`htstools.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htstools.Tpo $(DEPDIR)/libhttrack_la-htstools.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htstools.c' object='libhttrack_la-htstools.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htstools.lo `test -f 'htstools.c' || echo '$(srcdir)/'`htstools.c libhttrack_la-htswizard.lo: htswizard.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htswizard.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htswizard.Tpo -c -o libhttrack_la-htswizard.lo `test -f 'htswizard.c' || echo '$(srcdir)/'`htswizard.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htswizard.Tpo $(DEPDIR)/libhttrack_la-htswizard.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htswizard.c' object='libhttrack_la-htswizard.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htswizard.lo `test -f 'htswizard.c' || echo '$(srcdir)/'`htswizard.c libhttrack_la-htsalias.lo: htsalias.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htsalias.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htsalias.Tpo -c -o libhttrack_la-htsalias.lo `test -f 'htsalias.c' || echo '$(srcdir)/'`htsalias.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htsalias.Tpo $(DEPDIR)/libhttrack_la-htsalias.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htsalias.c' object='libhttrack_la-htsalias.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htsalias.lo `test -f 'htsalias.c' || echo '$(srcdir)/'`htsalias.c libhttrack_la-htsthread.lo: htsthread.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htsthread.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htsthread.Tpo -c -o libhttrack_la-htsthread.lo `test -f 'htsthread.c' || echo '$(srcdir)/'`htsthread.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htsthread.Tpo $(DEPDIR)/libhttrack_la-htsthread.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htsthread.c' object='libhttrack_la-htsthread.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htsthread.lo `test -f 'htsthread.c' || echo '$(srcdir)/'`htsthread.c libhttrack_la-htsindex.lo: htsindex.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htsindex.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htsindex.Tpo -c -o libhttrack_la-htsindex.lo `test -f 'htsindex.c' || echo '$(srcdir)/'`htsindex.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htsindex.Tpo $(DEPDIR)/libhttrack_la-htsindex.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htsindex.c' object='libhttrack_la-htsindex.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htsindex.lo `test -f 'htsindex.c' || echo '$(srcdir)/'`htsindex.c libhttrack_la-htsbauth.lo: htsbauth.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htsbauth.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htsbauth.Tpo -c -o libhttrack_la-htsbauth.lo `test -f 'htsbauth.c' || echo '$(srcdir)/'`htsbauth.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htsbauth.Tpo $(DEPDIR)/libhttrack_la-htsbauth.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htsbauth.c' object='libhttrack_la-htsbauth.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htsbauth.lo `test -f 'htsbauth.c' || echo '$(srcdir)/'`htsbauth.c libhttrack_la-htsmd5.lo: htsmd5.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htsmd5.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htsmd5.Tpo -c -o libhttrack_la-htsmd5.lo `test -f 'htsmd5.c' || echo '$(srcdir)/'`htsmd5.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htsmd5.Tpo $(DEPDIR)/libhttrack_la-htsmd5.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htsmd5.c' object='libhttrack_la-htsmd5.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htsmd5.lo `test -f 'htsmd5.c' || echo '$(srcdir)/'`htsmd5.c libhttrack_la-htszlib.lo: htszlib.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htszlib.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htszlib.Tpo -c -o libhttrack_la-htszlib.lo `test -f 'htszlib.c' || echo '$(srcdir)/'`htszlib.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htszlib.Tpo $(DEPDIR)/libhttrack_la-htszlib.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htszlib.c' object='libhttrack_la-htszlib.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htszlib.lo `test -f 'htszlib.c' || echo '$(srcdir)/'`htszlib.c libhttrack_la-htswrap.lo: htswrap.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htswrap.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htswrap.Tpo -c -o libhttrack_la-htswrap.lo `test -f 'htswrap.c' || echo '$(srcdir)/'`htswrap.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htswrap.Tpo $(DEPDIR)/libhttrack_la-htswrap.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htswrap.c' object='libhttrack_la-htswrap.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htswrap.lo `test -f 'htswrap.c' || echo '$(srcdir)/'`htswrap.c libhttrack_la-htsconcat.lo: htsconcat.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htsconcat.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htsconcat.Tpo -c -o libhttrack_la-htsconcat.lo `test -f 'htsconcat.c' || echo '$(srcdir)/'`htsconcat.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htsconcat.Tpo $(DEPDIR)/libhttrack_la-htsconcat.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htsconcat.c' object='libhttrack_la-htsconcat.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htsconcat.lo `test -f 'htsconcat.c' || echo '$(srcdir)/'`htsconcat.c libhttrack_la-htsmodules.lo: htsmodules.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htsmodules.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htsmodules.Tpo -c -o libhttrack_la-htsmodules.lo `test -f 'htsmodules.c' || echo '$(srcdir)/'`htsmodules.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htsmodules.Tpo $(DEPDIR)/libhttrack_la-htsmodules.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htsmodules.c' object='libhttrack_la-htsmodules.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htsmodules.lo `test -f 'htsmodules.c' || echo '$(srcdir)/'`htsmodules.c libhttrack_la-htscharset.lo: htscharset.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htscharset.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htscharset.Tpo -c -o libhttrack_la-htscharset.lo `test -f 'htscharset.c' || echo '$(srcdir)/'`htscharset.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htscharset.Tpo $(DEPDIR)/libhttrack_la-htscharset.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htscharset.c' object='libhttrack_la-htscharset.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htscharset.lo `test -f 'htscharset.c' || echo '$(srcdir)/'`htscharset.c libhttrack_la-punycode.lo: punycode.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-punycode.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-punycode.Tpo -c -o libhttrack_la-punycode.lo `test -f 'punycode.c' || echo '$(srcdir)/'`punycode.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-punycode.Tpo $(DEPDIR)/libhttrack_la-punycode.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='punycode.c' object='libhttrack_la-punycode.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-punycode.lo `test -f 'punycode.c' || echo '$(srcdir)/'`punycode.c libhttrack_la-htsencoding.lo: htsencoding.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-htsencoding.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-htsencoding.Tpo -c -o libhttrack_la-htsencoding.lo `test -f 'htsencoding.c' || echo '$(srcdir)/'`htsencoding.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-htsencoding.Tpo $(DEPDIR)/libhttrack_la-htsencoding.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htsencoding.c' object='libhttrack_la-htsencoding.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-htsencoding.lo `test -f 'htsencoding.c' || echo '$(srcdir)/'`htsencoding.c libhttrack_la-md5.lo: md5.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT libhttrack_la-md5.lo -MD -MP -MF $(DEPDIR)/libhttrack_la-md5.Tpo -c -o libhttrack_la-md5.lo `test -f 'md5.c' || echo '$(srcdir)/'`md5.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhttrack_la-md5.Tpo $(DEPDIR)/libhttrack_la-md5.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='md5.c' object='libhttrack_la-md5.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o libhttrack_la-md5.lo `test -f 'md5.c' || echo '$(srcdir)/'`md5.c minizip/libhttrack_la-ioapi.lo: minizip/ioapi.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT minizip/libhttrack_la-ioapi.lo -MD -MP -MF minizip/$(DEPDIR)/libhttrack_la-ioapi.Tpo -c -o minizip/libhttrack_la-ioapi.lo `test -f 'minizip/ioapi.c' || echo '$(srcdir)/'`minizip/ioapi.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) minizip/$(DEPDIR)/libhttrack_la-ioapi.Tpo minizip/$(DEPDIR)/libhttrack_la-ioapi.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='minizip/ioapi.c' object='minizip/libhttrack_la-ioapi.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o minizip/libhttrack_la-ioapi.lo `test -f 'minizip/ioapi.c' || echo '$(srcdir)/'`minizip/ioapi.c minizip/libhttrack_la-mztools.lo: minizip/mztools.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT minizip/libhttrack_la-mztools.lo -MD -MP -MF minizip/$(DEPDIR)/libhttrack_la-mztools.Tpo -c -o minizip/libhttrack_la-mztools.lo `test -f 'minizip/mztools.c' || echo '$(srcdir)/'`minizip/mztools.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) minizip/$(DEPDIR)/libhttrack_la-mztools.Tpo minizip/$(DEPDIR)/libhttrack_la-mztools.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='minizip/mztools.c' object='minizip/libhttrack_la-mztools.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o minizip/libhttrack_la-mztools.lo `test -f 'minizip/mztools.c' || echo '$(srcdir)/'`minizip/mztools.c minizip/libhttrack_la-unzip.lo: minizip/unzip.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT minizip/libhttrack_la-unzip.lo -MD -MP -MF minizip/$(DEPDIR)/libhttrack_la-unzip.Tpo -c -o minizip/libhttrack_la-unzip.lo `test -f 'minizip/unzip.c' || echo '$(srcdir)/'`minizip/unzip.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) minizip/$(DEPDIR)/libhttrack_la-unzip.Tpo minizip/$(DEPDIR)/libhttrack_la-unzip.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='minizip/unzip.c' object='minizip/libhttrack_la-unzip.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o minizip/libhttrack_la-unzip.lo `test -f 'minizip/unzip.c' || echo '$(srcdir)/'`minizip/unzip.c minizip/libhttrack_la-zip.lo: minizip/zip.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -MT minizip/libhttrack_la-zip.lo -MD -MP -MF minizip/$(DEPDIR)/libhttrack_la-zip.Tpo -c -o minizip/libhttrack_la-zip.lo `test -f 'minizip/zip.c' || echo '$(srcdir)/'`minizip/zip.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) minizip/$(DEPDIR)/libhttrack_la-zip.Tpo minizip/$(DEPDIR)/libhttrack_la-zip.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='minizip/zip.c' object='minizip/libhttrack_la-zip.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhttrack_la_CFLAGS) $(CFLAGS) -c -o minizip/libhttrack_la-zip.lo `test -f 'minizip/zip.c' || echo '$(srcdir)/'`minizip/zip.c htsserver-htsserver.o: htsserver.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(htsserver_CFLAGS) $(CFLAGS) -MT htsserver-htsserver.o -MD -MP -MF $(DEPDIR)/htsserver-htsserver.Tpo -c -o htsserver-htsserver.o `test -f 'htsserver.c' || echo '$(srcdir)/'`htsserver.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/htsserver-htsserver.Tpo $(DEPDIR)/htsserver-htsserver.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htsserver.c' object='htsserver-htsserver.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(htsserver_CFLAGS) $(CFLAGS) -c -o htsserver-htsserver.o `test -f 'htsserver.c' || echo '$(srcdir)/'`htsserver.c htsserver-htsserver.obj: htsserver.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(htsserver_CFLAGS) $(CFLAGS) -MT htsserver-htsserver.obj -MD -MP -MF $(DEPDIR)/htsserver-htsserver.Tpo -c -o htsserver-htsserver.obj `if test -f 'htsserver.c'; then $(CYGPATH_W) 'htsserver.c'; else $(CYGPATH_W) '$(srcdir)/htsserver.c'; fi` @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/htsserver-htsserver.Tpo $(DEPDIR)/htsserver-htsserver.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htsserver.c' object='htsserver-htsserver.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(htsserver_CFLAGS) $(CFLAGS) -c -o htsserver-htsserver.obj `if test -f 'htsserver.c'; then $(CYGPATH_W) 'htsserver.c'; else $(CYGPATH_W) '$(srcdir)/htsserver.c'; fi` htsserver-htsweb.o: htsweb.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(htsserver_CFLAGS) $(CFLAGS) -MT htsserver-htsweb.o -MD -MP -MF $(DEPDIR)/htsserver-htsweb.Tpo -c -o htsserver-htsweb.o `test -f 'htsweb.c' || echo '$(srcdir)/'`htsweb.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/htsserver-htsweb.Tpo $(DEPDIR)/htsserver-htsweb.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htsweb.c' object='htsserver-htsweb.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(htsserver_CFLAGS) $(CFLAGS) -c -o htsserver-htsweb.o `test -f 'htsweb.c' || echo '$(srcdir)/'`htsweb.c htsserver-htsweb.obj: htsweb.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(htsserver_CFLAGS) $(CFLAGS) -MT htsserver-htsweb.obj -MD -MP -MF $(DEPDIR)/htsserver-htsweb.Tpo -c -o htsserver-htsweb.obj `if test -f 'htsweb.c'; then $(CYGPATH_W) 'htsweb.c'; else $(CYGPATH_W) '$(srcdir)/htsweb.c'; fi` @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/htsserver-htsweb.Tpo $(DEPDIR)/htsserver-htsweb.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htsweb.c' object='htsserver-htsweb.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(htsserver_CFLAGS) $(CFLAGS) -c -o htsserver-htsweb.obj `if test -f 'htsweb.c'; then $(CYGPATH_W) 'htsweb.c'; else $(CYGPATH_W) '$(srcdir)/htsweb.c'; fi` httrack-httrack.o: httrack.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(httrack_CFLAGS) $(CFLAGS) -MT httrack-httrack.o -MD -MP -MF $(DEPDIR)/httrack-httrack.Tpo -c -o httrack-httrack.o `test -f 'httrack.c' || echo '$(srcdir)/'`httrack.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/httrack-httrack.Tpo $(DEPDIR)/httrack-httrack.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='httrack.c' object='httrack-httrack.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(httrack_CFLAGS) $(CFLAGS) -c -o httrack-httrack.o `test -f 'httrack.c' || echo '$(srcdir)/'`httrack.c httrack-httrack.obj: httrack.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(httrack_CFLAGS) $(CFLAGS) -MT httrack-httrack.obj -MD -MP -MF $(DEPDIR)/httrack-httrack.Tpo -c -o httrack-httrack.obj `if test -f 'httrack.c'; then $(CYGPATH_W) 'httrack.c'; else $(CYGPATH_W) '$(srcdir)/httrack.c'; fi` @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/httrack-httrack.Tpo $(DEPDIR)/httrack-httrack.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='httrack.c' object='httrack-httrack.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(httrack_CFLAGS) $(CFLAGS) -c -o httrack-httrack.obj `if test -f 'httrack.c'; then $(CYGPATH_W) 'httrack.c'; else $(CYGPATH_W) '$(srcdir)/httrack.c'; fi` proxy/proxytrack-main.o: proxy/main.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -MT proxy/proxytrack-main.o -MD -MP -MF proxy/$(DEPDIR)/proxytrack-main.Tpo -c -o proxy/proxytrack-main.o `test -f 'proxy/main.c' || echo '$(srcdir)/'`proxy/main.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) proxy/$(DEPDIR)/proxytrack-main.Tpo proxy/$(DEPDIR)/proxytrack-main.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='proxy/main.c' object='proxy/proxytrack-main.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -c -o proxy/proxytrack-main.o `test -f 'proxy/main.c' || echo '$(srcdir)/'`proxy/main.c proxy/proxytrack-main.obj: proxy/main.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -MT proxy/proxytrack-main.obj -MD -MP -MF proxy/$(DEPDIR)/proxytrack-main.Tpo -c -o proxy/proxytrack-main.obj `if test -f 'proxy/main.c'; then $(CYGPATH_W) 'proxy/main.c'; else $(CYGPATH_W) '$(srcdir)/proxy/main.c'; fi` @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) proxy/$(DEPDIR)/proxytrack-main.Tpo proxy/$(DEPDIR)/proxytrack-main.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='proxy/main.c' object='proxy/proxytrack-main.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -c -o proxy/proxytrack-main.obj `if test -f 'proxy/main.c'; then $(CYGPATH_W) 'proxy/main.c'; else $(CYGPATH_W) '$(srcdir)/proxy/main.c'; fi` proxy/proxytrack-proxytrack.o: proxy/proxytrack.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -MT proxy/proxytrack-proxytrack.o -MD -MP -MF proxy/$(DEPDIR)/proxytrack-proxytrack.Tpo -c -o proxy/proxytrack-proxytrack.o `test -f 'proxy/proxytrack.c' || echo '$(srcdir)/'`proxy/proxytrack.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) proxy/$(DEPDIR)/proxytrack-proxytrack.Tpo proxy/$(DEPDIR)/proxytrack-proxytrack.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='proxy/proxytrack.c' object='proxy/proxytrack-proxytrack.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -c -o proxy/proxytrack-proxytrack.o `test -f 'proxy/proxytrack.c' || echo '$(srcdir)/'`proxy/proxytrack.c proxy/proxytrack-proxytrack.obj: proxy/proxytrack.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -MT proxy/proxytrack-proxytrack.obj -MD -MP -MF proxy/$(DEPDIR)/proxytrack-proxytrack.Tpo -c -o proxy/proxytrack-proxytrack.obj `if test -f 'proxy/proxytrack.c'; then $(CYGPATH_W) 'proxy/proxytrack.c'; else $(CYGPATH_W) '$(srcdir)/proxy/proxytrack.c'; fi` @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) proxy/$(DEPDIR)/proxytrack-proxytrack.Tpo proxy/$(DEPDIR)/proxytrack-proxytrack.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='proxy/proxytrack.c' object='proxy/proxytrack-proxytrack.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -c -o proxy/proxytrack-proxytrack.obj `if test -f 'proxy/proxytrack.c'; then $(CYGPATH_W) 'proxy/proxytrack.c'; else $(CYGPATH_W) '$(srcdir)/proxy/proxytrack.c'; fi` proxy/proxytrack-store.o: proxy/store.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -MT proxy/proxytrack-store.o -MD -MP -MF proxy/$(DEPDIR)/proxytrack-store.Tpo -c -o proxy/proxytrack-store.o `test -f 'proxy/store.c' || echo '$(srcdir)/'`proxy/store.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) proxy/$(DEPDIR)/proxytrack-store.Tpo proxy/$(DEPDIR)/proxytrack-store.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='proxy/store.c' object='proxy/proxytrack-store.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -c -o proxy/proxytrack-store.o `test -f 'proxy/store.c' || echo '$(srcdir)/'`proxy/store.c proxy/proxytrack-store.obj: proxy/store.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -MT proxy/proxytrack-store.obj -MD -MP -MF proxy/$(DEPDIR)/proxytrack-store.Tpo -c -o proxy/proxytrack-store.obj `if test -f 'proxy/store.c'; then $(CYGPATH_W) 'proxy/store.c'; else $(CYGPATH_W) '$(srcdir)/proxy/store.c'; fi` @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) proxy/$(DEPDIR)/proxytrack-store.Tpo proxy/$(DEPDIR)/proxytrack-store.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='proxy/store.c' object='proxy/proxytrack-store.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -c -o proxy/proxytrack-store.obj `if test -f 'proxy/store.c'; then $(CYGPATH_W) 'proxy/store.c'; else $(CYGPATH_W) '$(srcdir)/proxy/store.c'; fi` coucal/proxytrack-coucal.o: coucal/coucal.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -MT coucal/proxytrack-coucal.o -MD -MP -MF coucal/$(DEPDIR)/proxytrack-coucal.Tpo -c -o coucal/proxytrack-coucal.o `test -f 'coucal/coucal.c' || echo '$(srcdir)/'`coucal/coucal.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) coucal/$(DEPDIR)/proxytrack-coucal.Tpo coucal/$(DEPDIR)/proxytrack-coucal.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='coucal/coucal.c' object='coucal/proxytrack-coucal.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -c -o coucal/proxytrack-coucal.o `test -f 'coucal/coucal.c' || echo '$(srcdir)/'`coucal/coucal.c coucal/proxytrack-coucal.obj: coucal/coucal.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -MT coucal/proxytrack-coucal.obj -MD -MP -MF coucal/$(DEPDIR)/proxytrack-coucal.Tpo -c -o coucal/proxytrack-coucal.obj `if test -f 'coucal/coucal.c'; then $(CYGPATH_W) 'coucal/coucal.c'; else $(CYGPATH_W) '$(srcdir)/coucal/coucal.c'; fi` @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) coucal/$(DEPDIR)/proxytrack-coucal.Tpo coucal/$(DEPDIR)/proxytrack-coucal.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='coucal/coucal.c' object='coucal/proxytrack-coucal.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -c -o coucal/proxytrack-coucal.obj `if test -f 'coucal/coucal.c'; then $(CYGPATH_W) 'coucal/coucal.c'; else $(CYGPATH_W) '$(srcdir)/coucal/coucal.c'; fi` proxytrack-htsmd5.o: htsmd5.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -MT proxytrack-htsmd5.o -MD -MP -MF $(DEPDIR)/proxytrack-htsmd5.Tpo -c -o proxytrack-htsmd5.o `test -f 'htsmd5.c' || echo '$(srcdir)/'`htsmd5.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/proxytrack-htsmd5.Tpo $(DEPDIR)/proxytrack-htsmd5.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htsmd5.c' object='proxytrack-htsmd5.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -c -o proxytrack-htsmd5.o `test -f 'htsmd5.c' || echo '$(srcdir)/'`htsmd5.c proxytrack-htsmd5.obj: htsmd5.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -MT proxytrack-htsmd5.obj -MD -MP -MF $(DEPDIR)/proxytrack-htsmd5.Tpo -c -o proxytrack-htsmd5.obj `if test -f 'htsmd5.c'; then $(CYGPATH_W) 'htsmd5.c'; else $(CYGPATH_W) '$(srcdir)/htsmd5.c'; fi` @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/proxytrack-htsmd5.Tpo $(DEPDIR)/proxytrack-htsmd5.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='htsmd5.c' object='proxytrack-htsmd5.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -c -o proxytrack-htsmd5.obj `if test -f 'htsmd5.c'; then $(CYGPATH_W) 'htsmd5.c'; else $(CYGPATH_W) '$(srcdir)/htsmd5.c'; fi` proxytrack-md5.o: md5.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -MT proxytrack-md5.o -MD -MP -MF $(DEPDIR)/proxytrack-md5.Tpo -c -o proxytrack-md5.o `test -f 'md5.c' || echo '$(srcdir)/'`md5.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/proxytrack-md5.Tpo $(DEPDIR)/proxytrack-md5.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='md5.c' object='proxytrack-md5.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -c -o proxytrack-md5.o `test -f 'md5.c' || echo '$(srcdir)/'`md5.c proxytrack-md5.obj: md5.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -MT proxytrack-md5.obj -MD -MP -MF $(DEPDIR)/proxytrack-md5.Tpo -c -o proxytrack-md5.obj `if test -f 'md5.c'; then $(CYGPATH_W) 'md5.c'; else $(CYGPATH_W) '$(srcdir)/md5.c'; fi` @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/proxytrack-md5.Tpo $(DEPDIR)/proxytrack-md5.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='md5.c' object='proxytrack-md5.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -c -o proxytrack-md5.obj `if test -f 'md5.c'; then $(CYGPATH_W) 'md5.c'; else $(CYGPATH_W) '$(srcdir)/md5.c'; fi` minizip/proxytrack-ioapi.o: minizip/ioapi.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -MT minizip/proxytrack-ioapi.o -MD -MP -MF minizip/$(DEPDIR)/proxytrack-ioapi.Tpo -c -o minizip/proxytrack-ioapi.o `test -f 'minizip/ioapi.c' || echo '$(srcdir)/'`minizip/ioapi.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) minizip/$(DEPDIR)/proxytrack-ioapi.Tpo minizip/$(DEPDIR)/proxytrack-ioapi.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='minizip/ioapi.c' object='minizip/proxytrack-ioapi.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -c -o minizip/proxytrack-ioapi.o `test -f 'minizip/ioapi.c' || echo '$(srcdir)/'`minizip/ioapi.c minizip/proxytrack-ioapi.obj: minizip/ioapi.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -MT minizip/proxytrack-ioapi.obj -MD -MP -MF minizip/$(DEPDIR)/proxytrack-ioapi.Tpo -c -o minizip/proxytrack-ioapi.obj `if test -f 'minizip/ioapi.c'; then $(CYGPATH_W) 'minizip/ioapi.c'; else $(CYGPATH_W) '$(srcdir)/minizip/ioapi.c'; fi` @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) minizip/$(DEPDIR)/proxytrack-ioapi.Tpo minizip/$(DEPDIR)/proxytrack-ioapi.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='minizip/ioapi.c' object='minizip/proxytrack-ioapi.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -c -o minizip/proxytrack-ioapi.obj `if test -f 'minizip/ioapi.c'; then $(CYGPATH_W) 'minizip/ioapi.c'; else $(CYGPATH_W) '$(srcdir)/minizip/ioapi.c'; fi` minizip/proxytrack-mztools.o: minizip/mztools.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -MT minizip/proxytrack-mztools.o -MD -MP -MF minizip/$(DEPDIR)/proxytrack-mztools.Tpo -c -o minizip/proxytrack-mztools.o `test -f 'minizip/mztools.c' || echo '$(srcdir)/'`minizip/mztools.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) minizip/$(DEPDIR)/proxytrack-mztools.Tpo minizip/$(DEPDIR)/proxytrack-mztools.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='minizip/mztools.c' object='minizip/proxytrack-mztools.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -c -o minizip/proxytrack-mztools.o `test -f 'minizip/mztools.c' || echo '$(srcdir)/'`minizip/mztools.c minizip/proxytrack-mztools.obj: minizip/mztools.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -MT minizip/proxytrack-mztools.obj -MD -MP -MF minizip/$(DEPDIR)/proxytrack-mztools.Tpo -c -o minizip/proxytrack-mztools.obj `if test -f 'minizip/mztools.c'; then $(CYGPATH_W) 'minizip/mztools.c'; else $(CYGPATH_W) '$(srcdir)/minizip/mztools.c'; fi` @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) minizip/$(DEPDIR)/proxytrack-mztools.Tpo minizip/$(DEPDIR)/proxytrack-mztools.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='minizip/mztools.c' object='minizip/proxytrack-mztools.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -c -o minizip/proxytrack-mztools.obj `if test -f 'minizip/mztools.c'; then $(CYGPATH_W) 'minizip/mztools.c'; else $(CYGPATH_W) '$(srcdir)/minizip/mztools.c'; fi` minizip/proxytrack-unzip.o: minizip/unzip.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -MT minizip/proxytrack-unzip.o -MD -MP -MF minizip/$(DEPDIR)/proxytrack-unzip.Tpo -c -o minizip/proxytrack-unzip.o `test -f 'minizip/unzip.c' || echo '$(srcdir)/'`minizip/unzip.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) minizip/$(DEPDIR)/proxytrack-unzip.Tpo minizip/$(DEPDIR)/proxytrack-unzip.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='minizip/unzip.c' object='minizip/proxytrack-unzip.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -c -o minizip/proxytrack-unzip.o `test -f 'minizip/unzip.c' || echo '$(srcdir)/'`minizip/unzip.c minizip/proxytrack-unzip.obj: minizip/unzip.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -MT minizip/proxytrack-unzip.obj -MD -MP -MF minizip/$(DEPDIR)/proxytrack-unzip.Tpo -c -o minizip/proxytrack-unzip.obj `if test -f 'minizip/unzip.c'; then $(CYGPATH_W) 'minizip/unzip.c'; else $(CYGPATH_W) '$(srcdir)/minizip/unzip.c'; fi` @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) minizip/$(DEPDIR)/proxytrack-unzip.Tpo minizip/$(DEPDIR)/proxytrack-unzip.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='minizip/unzip.c' object='minizip/proxytrack-unzip.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -c -o minizip/proxytrack-unzip.obj `if test -f 'minizip/unzip.c'; then $(CYGPATH_W) 'minizip/unzip.c'; else $(CYGPATH_W) '$(srcdir)/minizip/unzip.c'; fi` minizip/proxytrack-zip.o: minizip/zip.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -MT minizip/proxytrack-zip.o -MD -MP -MF minizip/$(DEPDIR)/proxytrack-zip.Tpo -c -o minizip/proxytrack-zip.o `test -f 'minizip/zip.c' || echo '$(srcdir)/'`minizip/zip.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) minizip/$(DEPDIR)/proxytrack-zip.Tpo minizip/$(DEPDIR)/proxytrack-zip.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='minizip/zip.c' object='minizip/proxytrack-zip.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -c -o minizip/proxytrack-zip.o `test -f 'minizip/zip.c' || echo '$(srcdir)/'`minizip/zip.c minizip/proxytrack-zip.obj: minizip/zip.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -MT minizip/proxytrack-zip.obj -MD -MP -MF minizip/$(DEPDIR)/proxytrack-zip.Tpo -c -o minizip/proxytrack-zip.obj `if test -f 'minizip/zip.c'; then $(CYGPATH_W) 'minizip/zip.c'; else $(CYGPATH_W) '$(srcdir)/minizip/zip.c'; fi` @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) minizip/$(DEPDIR)/proxytrack-zip.Tpo minizip/$(DEPDIR)/proxytrack-zip.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='minizip/zip.c' object='minizip/proxytrack-zip.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(proxytrack_CFLAGS) $(CFLAGS) -c -o minizip/proxytrack-zip.obj `if test -f 'minizip/zip.c'; then $(CYGPATH_W) 'minizip/zip.c'; else $(CYGPATH_W) '$(srcdir)/minizip/zip.c'; fi` mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs -rm -rf coucal/.libs coucal/_libs -rm -rf minizip/.libs minizip/_libs install-DevIncludesDATA: $(DevIncludes_DATA) @$(NORMAL_INSTALL) @list='$(DevIncludes_DATA)'; test -n "$(DevIncludesdir)" || list=; \ if test -n "$$list"; then \ echo " $(MKDIR_P) '$(DESTDIR)$(DevIncludesdir)'"; \ $(MKDIR_P) "$(DESTDIR)$(DevIncludesdir)" || exit 1; \ fi; \ for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; \ done | $(am__base_list) | \ while read files; do \ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(DevIncludesdir)'"; \ $(INSTALL_DATA) $$files "$(DESTDIR)$(DevIncludesdir)" || exit $$?; \ done uninstall-DevIncludesDATA: @$(NORMAL_UNINSTALL) @list='$(DevIncludes_DATA)'; test -n "$(DevIncludesdir)" || list=; \ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ dir='$(DESTDIR)$(DevIncludesdir)'; $(am__uninstall_files_from_dir) ID: $(am__tagged_files) $(am__define_uniq_tagged_files); mkid -fID $$unique tags: tags-am TAGS: tags tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ if test $$# -gt 0; then \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ "$$@" $$unique; \ else \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$unique; \ fi; \ fi ctags: ctags-am CTAGS: ctags ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" cscopelist: cscopelist-am cscopelist-am: $(am__tagged_files) list='$(am__tagged_files)'; \ case "$(srcdir)" in \ [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ *) sdir=$(subdir)/$(srcdir) ;; \ esac; \ for i in $$list; do \ if test -f "$$i"; then \ echo "$(subdir)/$$i"; \ else \ echo "$$sdir/$$i"; \ fi; \ done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags distdir: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) distdir-am distdir-am: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ dist_files=`for file in $$list; do echo $$file; done | \ sed -e "s|^$$srcdirstrip/||;t" \ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ case $$dist_files in \ */*) $(MKDIR_P) `echo "$$dist_files" | \ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ sort -u` ;; \ esac; \ for file in $$dist_files; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ if test -d $$d/$$file; then \ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ if test -d "$(distdir)/$$file"; then \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ else \ test -f "$(distdir)/$$file" \ || cp -p $$d/$$file "$(distdir)/$$file" \ || exit 1; \ fi; \ done check-am: all-am check: check-am all-am: Makefile $(PROGRAMS) $(LTLIBRARIES) $(SCRIPTS) $(DATA) install-binPROGRAMS: install-libLTLIBRARIES installdirs: for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libdir)" "$(DESTDIR)$(whttrackrundir)" "$(DESTDIR)$(DevIncludesdir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-am install-strip: if test -z '$(STRIP)'; then \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ install; \ else \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ fi mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) -rm -f coucal/$(DEPDIR)/$(am__dirstamp) -rm -f coucal/$(am__dirstamp) -rm -f minizip/$(DEPDIR)/$(am__dirstamp) -rm -f minizip/$(am__dirstamp) -rm -f proxy/$(DEPDIR)/$(am__dirstamp) -rm -f proxy/$(am__dirstamp) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-binPROGRAMS clean-generic clean-libLTLIBRARIES \ clean-libtool mostlyclean-am distclean: distclean-am -rm -f ./$(DEPDIR)/htsjava.Plo -rm -f ./$(DEPDIR)/htsserver-htsserver.Po -rm -f ./$(DEPDIR)/htsserver-htsweb.Po -rm -f ./$(DEPDIR)/httrack-httrack.Po -rm -f ./$(DEPDIR)/libhttrack_la-htsalias.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsback.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsbauth.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htscache.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htscatchurl.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htscharset.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsconcat.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htscore.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htscoremain.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsencoding.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsfilters.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsftp.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htshash.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htshelp.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsindex.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htslib.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsmd5.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsmodules.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsname.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsparse.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsrobots.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsthread.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htstools.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htswizard.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htswrap.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htszlib.Plo -rm -f ./$(DEPDIR)/libhttrack_la-md5.Plo -rm -f ./$(DEPDIR)/libhttrack_la-punycode.Plo -rm -f ./$(DEPDIR)/proxytrack-htsmd5.Po -rm -f ./$(DEPDIR)/proxytrack-md5.Po -rm -f coucal/$(DEPDIR)/libhttrack_la-coucal.Plo -rm -f coucal/$(DEPDIR)/proxytrack-coucal.Po -rm -f minizip/$(DEPDIR)/libhttrack_la-ioapi.Plo -rm -f minizip/$(DEPDIR)/libhttrack_la-mztools.Plo -rm -f minizip/$(DEPDIR)/libhttrack_la-unzip.Plo -rm -f minizip/$(DEPDIR)/libhttrack_la-zip.Plo -rm -f minizip/$(DEPDIR)/proxytrack-ioapi.Po -rm -f minizip/$(DEPDIR)/proxytrack-mztools.Po -rm -f minizip/$(DEPDIR)/proxytrack-unzip.Po -rm -f minizip/$(DEPDIR)/proxytrack-zip.Po -rm -f proxy/$(DEPDIR)/proxytrack-main.Po -rm -f proxy/$(DEPDIR)/proxytrack-proxytrack.Po -rm -f proxy/$(DEPDIR)/proxytrack-store.Po -rm -f Makefile distclean-am: clean-am distclean-compile distclean-generic \ distclean-tags dvi: dvi-am dvi-am: html: html-am html-am: info: info-am info-am: install-data-am: install-DevIncludesDATA install-whttrackrunSCRIPTS install-dvi: install-dvi-am install-dvi-am: install-exec-am: install-binPROGRAMS install-libLTLIBRARIES install-html: install-html-am install-html-am: install-info: install-info-am install-info-am: install-man: install-pdf: install-pdf-am install-pdf-am: install-ps: install-ps-am install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-am -rm -f ./$(DEPDIR)/htsjava.Plo -rm -f ./$(DEPDIR)/htsserver-htsserver.Po -rm -f ./$(DEPDIR)/htsserver-htsweb.Po -rm -f ./$(DEPDIR)/httrack-httrack.Po -rm -f ./$(DEPDIR)/libhttrack_la-htsalias.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsback.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsbauth.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htscache.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htscatchurl.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htscharset.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsconcat.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htscore.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htscoremain.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsencoding.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsfilters.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsftp.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htshash.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htshelp.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsindex.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htslib.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsmd5.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsmodules.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsname.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsparse.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsrobots.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htsthread.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htstools.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htswizard.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htswrap.Plo -rm -f ./$(DEPDIR)/libhttrack_la-htszlib.Plo -rm -f ./$(DEPDIR)/libhttrack_la-md5.Plo -rm -f ./$(DEPDIR)/libhttrack_la-punycode.Plo -rm -f ./$(DEPDIR)/proxytrack-htsmd5.Po -rm -f ./$(DEPDIR)/proxytrack-md5.Po -rm -f coucal/$(DEPDIR)/libhttrack_la-coucal.Plo -rm -f coucal/$(DEPDIR)/proxytrack-coucal.Po -rm -f minizip/$(DEPDIR)/libhttrack_la-ioapi.Plo -rm -f minizip/$(DEPDIR)/libhttrack_la-mztools.Plo -rm -f minizip/$(DEPDIR)/libhttrack_la-unzip.Plo -rm -f minizip/$(DEPDIR)/libhttrack_la-zip.Plo -rm -f minizip/$(DEPDIR)/proxytrack-ioapi.Po -rm -f minizip/$(DEPDIR)/proxytrack-mztools.Po -rm -f minizip/$(DEPDIR)/proxytrack-unzip.Po -rm -f minizip/$(DEPDIR)/proxytrack-zip.Po -rm -f proxy/$(DEPDIR)/proxytrack-main.Po -rm -f proxy/$(DEPDIR)/proxytrack-proxytrack.Po -rm -f proxy/$(DEPDIR)/proxytrack-store.Po -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am pdf-am: ps: ps-am ps-am: uninstall-am: uninstall-DevIncludesDATA uninstall-binPROGRAMS \ uninstall-libLTLIBRARIES uninstall-whttrackrunSCRIPTS .MAKE: install-am install-strip .PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-am clean \ clean-binPROGRAMS clean-generic clean-libLTLIBRARIES \ clean-libtool cscopelist-am ctags ctags-am distclean \ distclean-compile distclean-generic distclean-libtool \ distclean-tags distdir dvi dvi-am html html-am info info-am \ install install-DevIncludesDATA install-am install-binPROGRAMS \ install-data install-data-am install-dvi install-dvi-am \ install-exec install-exec-am install-html install-html-am \ install-info install-info-am install-libLTLIBRARIES \ install-man install-pdf install-pdf-am install-ps \ install-ps-am install-strip install-whttrackrunSCRIPTS \ installcheck installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-compile \ mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ tags tags-am uninstall uninstall-DevIncludesDATA uninstall-am \ uninstall-binPROGRAMS uninstall-libLTLIBRARIES \ uninstall-whttrackrunSCRIPTS .PRECIOUS: Makefile # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: httrack-3.49.5/src/Makefile.am0000644000175000017500000000707414555201650013033 00000000000000DevIncludesdir = $(includedir)/httrack DevIncludes_DATA = \ httrack-library.h \ htsglobal.h \ htsopt.h \ htswrap.h \ htsconfig.h \ ../config.h \ htsmodules.h \ htsbasenet.h \ htsnet.h \ htsbauth.h \ htsdefines.h \ htsstrings.h \ htsarrays.h \ htssafe.h AM_CPPFLAGS = \ @DEFAULT_CFLAGS@ \ @THREADS_CFLAGS@ \ @V6_FLAG@ \ @LFS_FLAG@ \ -DPREFIX=\""$(prefix)"\" \ -DSYSCONFDIR=\""$(sysconfdir)"\" \ -DDATADIR=\""$(datadir)"\" \ -DLIBDIR=\""$(libdir)"\" \ -I"$(abs_srcdir)" \ -I"$(abs_srcdir)/coucal" AM_LDFLAGS = \ @DEFAULT_LDFLAGS@ bin_PROGRAMS = proxytrack httrack htsserver httrack_LDADD = $(THREADS_LIBS) libhttrack.la htsserver_LDADD = $(THREADS_LIBS) $(SOCKET_LIBS) libhttrack.la proxytrack_LDADD = $(THREADS_LIBS) $(SOCKET_LIBS) httrack_CFLAGS = $(AM_CFLAGS) $(CFLAGS_PIE) proxytrack_CFLAGS = $(AM_CFLAGS) $(CFLAGS_PIE) -DNO_MALLOCT -DZLIB_CONST -DHTS_INTHASH_USES_MD5 htsserver_CFLAGS = $(AM_CFLAGS) $(CFLAGS_PIE) -DZLIB_CONST -DHTS_INTHASH_USES_MD5 httrack_LDFLAGS = $(AM_LDFLAGS) $(LDFLAGS_PIE) proxytrack_LDFLAGS = $(AM_LDFLAGS) $(LDFLAGS_PIE) htsserver_LDFLAGS = $(AM_LDFLAGS) $(LDFLAGS_PIE) lib_LTLIBRARIES = libhttrack.la libhtsjava.la htsserver_SOURCES = htsserver.c htsserver.h htsweb.c htsweb.h proxytrack_SOURCES = proxy/main.c \ proxy/proxytrack.c proxy/store.c \ coucal/coucal.c htsmd5.c md5.c \ minizip/ioapi.c minizip/mztools.c minizip/unzip.c minizip/zip.c whttrackrundir = $(bindir) whttrackrun_SCRIPTS = webhttrack libhttrack_la_SOURCES = htscore.c htsparse.c htsback.c htscache.c \ htscatchurl.c htsfilters.c htsftp.c htshash.c coucal/coucal.c \ htshelp.c htslib.c htscoremain.c \ htsname.c htsrobots.c htstools.c htswizard.c \ htsalias.c htsthread.c htsindex.c htsbauth.c \ htsmd5.c htszlib.c htswrap.c htsconcat.c \ htsmodules.c htscharset.c punycode.c htsencoding.c \ md5.c \ minizip/ioapi.c minizip/mztools.c minizip/unzip.c minizip/zip.c \ hts-indextmpl.h htsalias.h htsback.h htsbase.h htssafe.h \ htsbasenet.h htsbauth.h htscache.h htscatchurl.h \ htsconfig.h htscore.h htsparse.h htscoremain.h htsdefines.h \ htsfilters.h htsftp.h htsglobal.h htshash.h coucal/coucal.h \ htshelp.h htsindex.h htslib.h htsmd5.h \ htsmodules.h htsname.h htsnet.h \ htsopt.h htsrobots.h htsthread.h \ htstools.h htswizard.h htswrap.h htszlib.h \ htsstrings.h htsarrays.h httrack-library.h \ htscharset.h punycode.h htsencoding.h \ htsentities.h htsentities.sh htsbasiccharsets.sh htscodepages.h \ md5.h coucal/murmurhash3.h \ minizip/crypt.h minizip/ioapi.h minizip/mztools.h minizip/unzip.h minizip/zip.h libhttrack_la_LIBADD = $(THREADS_LIBS) $(ZLIB_LIBS) $(OPENSSL_LIBS) $(DL_LIBS) $(SOCKET_LIBS) $(ICONV_LIBS) libhttrack_la_CFLAGS = $(AM_CFLAGS) -DLIBHTTRACK_EXPORTS -DZLIB_CONST libhttrack_la_LDFLAGS = $(AM_LDFLAGS) -version-info $(VERSION_INFO) libhtsjava_la_SOURCES = htsjava.c htsjava.h libhtsjava_la_LIBADD = $(THREADS_LIBS) $(DL_LIBS) libhttrack.la libhtsjava_la_LDFLAGS = $(AM_LDFLAGS) -version-info $(VERSION_INFO) EXTRA_DIST = httrack.h webhttrack \ coucal/murmurhash3.h.diff \ coucal/murmurhash3.h.orig \ minizip/iowin32.c \ minizip/iowin32.h \ minizip/ioapi.c.diff \ minizip/ioapi.h.diff \ minizip/zip.c.diff \ minizip/zip.h.diff \ minizip/mztools.c.diff \ minizip/ioapi.c.orig \ minizip/ioapi.h.orig \ minizip/mztools.c.orig \ minizip/zip.c.orig \ minizip/zip.h.orig \ minizip/MiniZip64_Changes.txt \ minizip/MiniZip64_info.txt \ proxy/AUTHORS \ proxy/COPYING \ proxy/changelog.txt \ proxy/proxystrings.h \ proxy/proxytrack.h \ proxy/store.h \ proxy/proxytrack.vcproj \ coucal/* \ *.dsw *.dsp *.vcproj httrack-3.49.5/src/proxy/0000755000175000017500000000000014555203177012236 500000000000000httrack-3.49.5/src/proxy/proxytrack.vcproj0000644000175000017500000002651114336470674015623 00000000000000 httrack-3.49.5/src/proxy/store.h0000644000175000017500000001004614336470674013471 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Cache manager for ProxyTrack */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef WEBHTTRACK_PROXYTRACK_STORE #define WEBHTTRACK_PROXYTRACK_STORE /* Includes */ #ifndef _WIN32 #include #else #include "windows.h" #endif /* Proxy */ typedef struct _PT_Index _PT_Index; typedef struct _PT_Indexes _PT_Indexes; typedef struct _PT_Index *PT_Index; typedef struct _PT_Indexes *PT_Indexes; typedef struct _PT_Cache _PT_Cache; typedef struct _PT_Cache *PT_Cache; typedef struct _PT_CacheItem _PT_CacheItem; typedef struct _PT_CacheItem *PT_CacheItem; typedef struct _PT_Element { int indexId; // index identifier, if suitable (!= -1) // int statuscode; // status-code, -1=erreur, 200=OK,201=..etc (cf RFC1945) char *adr; // adresse du bloc de mémoire, NULL=vide char *headers; // adresse des en têtes si présents (RFC822 format) size_t size; // taille fichier char msg[1024]; // error message ("\0"=undefined) char contenttype[64]; // content-type ("text/html" par exemple) char charset[64]; // charset ("iso-8859-1" par exemple) char *location; // on copie dedans éventuellement la véritable 'location' char lastmodified[64]; // Last-Modified char etag[64]; // Etag char cdispo[256]; // Content-Disposition coupé } _PT_Element; typedef struct _PT_Element *PT_Element; typedef enum PT_Fetch_Flags { FETCH_HEADERS, // fetch headers FETCH_BODY // fetch body } PT_Fetch_Flags; /* Locking */ #ifdef _WIN32 typedef void *PT_Mutex; #else typedef pthread_mutex_t PT_Mutex; #endif void MutexInit(PT_Mutex * pMutex); void MutexLock(PT_Mutex * pMutex); void MutexUnlock(PT_Mutex * pMutex); void MutexFree(PT_Mutex * pMutex); /* Indexes */ PT_Indexes PT_New(void); void PT_Delete(PT_Indexes index); PT_Element PT_ReadIndex(PT_Indexes indexes, const char *url, int flags); int PT_LookupIndex(PT_Indexes indexes, const char *url); int PT_AddIndex(PT_Indexes index, const char *path); int PT_RemoveIndex(PT_Indexes index, int indexId); int PT_IndexMerge(PT_Indexes indexes, PT_Index * pindex); PT_Index PT_GetIndex(PT_Indexes indexes, int indexId); time_t PT_GetTimeIndex(PT_Indexes indexes); /* Indexes list */ PT_Element PT_Index_HTML_BuildRootInfo(PT_Indexes indexes); char **PT_Enumerate(PT_Indexes indexes, const char *url, int subtree); void PT_Enumerate_Delete(char ***plist); int PT_EnumCache(PT_Indexes indexes, int (*callback) (void *, const char *url, PT_Element), void *arg); int PT_SaveCache(PT_Indexes indexes, const char *filename); /* Index */ PT_Index PT_LoadCache(const char *filename); void PT_Index_Delete(PT_Index * pindex); PT_Element PT_ReadCache(PT_Index index, const char *url, int flags); int PT_LookupCache(PT_Index index, const char *url); time_t PT_Index_Timestamp(PT_Index index); /* Elements*/ PT_Element PT_ElementNew(void); void PT_Element_Delete(PT_Element * pentry); #endif httrack-3.49.5/src/proxy/proxytrack.h0000644000175000017500000002530314360534067014537 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: ProxyTrack, httrack cache-based proxy */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #ifndef WEBHTTRACK_PROXYTRACK #define WEBHTTRACK_PROXYTRACK /* Version */ #define PROXYTRACK_VERSION "0.5" /* Store manager */ #include "../minizip/mztools.h" #include "store.h" #include #ifdef _WIN32 #include #else #include #endif #include #ifndef _WIN32 #include #endif #include /* generic */ int proxytrack_main(char *proxyAddr, int proxyPort, char *icpAddr, int icpPort, PT_Indexes index); /* Spaces: CR,LF,TAB,FF */ #define is_space(c) ( ((c)==' ') || ((c)=='\"') || ((c)==10) || ((c)==13) || ((c)==9) || ((c)==12) || ((c)==11) || ((c)=='\'') ) #define is_realspace(c) ( ((c)==' ') || ((c)==10) || ((c)==13) || ((c)==9) || ((c)==12) || ((c)==11) ) #define is_taborspace(c) ( ((c)==' ') || ((c)==9) ) #define is_quote(c) ( ((c)=='\"') || ((c)=='\'') ) #define is_retorsep(c) ( ((c)==10) || ((c)==13) || ((c)==9) ) /* Static definitions */ HTS_UNUSED static void proxytrack_print_log(const char *severity, const char *format, ...) { if (severity != NULL) { const int error = errno; FILE *const fp = stderr; va_list args; fprintf(fp, " * %s: ", severity); va_start(args, format); (void) vfprintf(fp, format, args); va_end(args); fputs("\n", fp); fflush(fp); errno = error; } } #define CRITICAL "critical" #define WARNING "warning" #define LOG "log" #if defined(_DEBUG) || defined(DEBUG) #define DEBUG "debug" #else #define DEBUG NULL #endif /* Header for generated pages */ #define PROXYTRACK_COMMENT_HEADER \ "\r\n" \ "\r\n" /* See IE "feature" (MSKB Q294807) */ #define DISABLE_IE_FRIENDLY_HTTP_ERROR_MESSAGES \ "\r\n" \ "\r\n" \ "\r\n" \ "\r\n" \ "\r\n" \ "\r\n" \ "\r\n" \ "\r\n" \ "\r\n" \ "\r\n" \ "\r\n" \ "\r\n" HTS_UNUSED static const char *gethomedir(void) { const char *home = getenv("HOME"); if (home) return home; else return "."; } HTS_UNUSED static int linput(FILE * fp, char *s, int max) { int c; int j = 0; do { c = fgetc(fp); if (c != EOF) { switch (c) { case 13: break; // sauter CR case 10: c = -1; break; case 0: case 9: case 12: break; // sauter ces caractères default: s[j++] = (char) c; break; } } } while((c != -1) && (c != EOF) && (j < (max - 1))); s[j] = '\0'; return j; } HTS_UNUSED static int link_has_authority(const char *lien) { const char *a = lien; if (isalpha((const unsigned char) *a)) { // Skip scheme? while(isalpha((const unsigned char) *a)) a++; if (*a == ':') a++; else return 0; } if (strncmp(a, "//", 2) == 0) return 1; return 0; } HTS_UNUSED static const char *jump_protocol(const char *source) { int p; // scheme // "Comparisons of scheme names MUST be case-insensitive" (RFC2616) if ((p = strfield(source, "http:"))) source += p; else if ((p = strfield(source, "ftp:"))) source += p; else if ((p = strfield(source, "https:"))) source += p; else if ((p = strfield(source, "file:"))) source += p; // net_path if (strncmp(source, "//", 2) == 0) source += 2; return source; } HTS_UNUSED static const char *strrchr_limit(const char *s, char c, const char *limit) { if (limit == NULL) { char *p = strrchr(s, c); return p ? (p + 1) : NULL; } else { char *a = NULL, *p; for(;;) { p = strchr((a) ? a : s, c); if ((p >= limit) || (p == NULL)) return a; a = p + 1; } } } HTS_UNUSED static const char *jump_protocol_and_auth(const char *source) { const char *a, *trytofind; if (strcmp(source, "file://") == 0) return source; a = jump_protocol(source); trytofind = strrchr_limit(a, '@', strchr(a, '/')); return (trytofind != NULL) ? trytofind : a; } #ifndef min #define min(a,b) ((a)>(b)?(b):(a)) #endif #ifndef max #define max(a,b) ((a)>(b)?(a):(b)) #endif HTS_UNUSED static int linput_trim(FILE * fp, char *s, int max) { int rlen = 0; char *const ls = (char *) malloc(max + 1); s[0] = '\0'; if (ls) { char *a; // lire ligne rlen = linput(fp, ls, max); if (rlen) { // sauter espaces et tabs en fin while((rlen > 0) && is_realspace(ls[max(rlen - 1, 0)])) ls[--rlen] = '\0'; // sauter espaces en début a = ls; while((rlen > 0) && ((*a == ' ') || (*a == '\t'))) { a++; rlen--; } if (rlen > 0) { memcpy(s, a, rlen); // can copy \0 chars s[rlen] = '\0'; } } // free(ls); } return rlen; } #ifndef S_ISREG #define S_ISREG(m) ((m) & _S_IFREG) #endif HTS_UNUSED static int fexist(char *s) { struct stat st; memset(&st, 0, sizeof(st)); if (stat(s, &st) == 0) { if (S_ISREG(st.st_mode)) { return 1; } } return 0; } /* convertir une chaine en temps */ HTS_UNUSED static void set_lowcase(char *s) { int i; for(i = 0; i < (int) strlen(s); i++) if ((s[i] >= 'A') && (s[i] <= 'Z')) s[i] += ('a' - 'A'); } HTS_UNUSED static struct tm *convert_time_rfc822(struct tm *result, const char *s) { char months[] = "jan feb mar apr may jun jul aug sep oct nov dec"; char str[256]; char *a; /* */ int result_mm = -1; int result_dd = -1; int result_n1 = -1; int result_n2 = -1; int result_n3 = -1; int result_n4 = -1; /* */ if ((int) strlen(s) > 200) return NULL; strcpy(str, s); set_lowcase(str); /* éliminer :,- */ while((a = strchr(str, '-'))) *a = ' '; while((a = strchr(str, ':'))) *a = ' '; while((a = strchr(str, ','))) *a = ' '; /* tokeniser */ a = str; while(*a) { char *first, *last; char tok[256]; /* découper mot */ while(*a == ' ') a++; /* sauter espaces */ first = a; while((*a) && (*a != ' ')) a++; last = a; tok[0] = '\0'; if (first != last) { char *pos; strncat(tok, first, (int) (last - first)); /* analyser */ if ((pos = strstr(months, tok))) { /* month always in letters */ result_mm = ((int) (pos - months)) / 4; } else { int number; if (sscanf(tok, "%d", &number) == 1) { /* number token */ if (result_dd < 0) /* day always first number */ result_dd = number; else if (result_n1 < 0) result_n1 = number; else if (result_n2 < 0) result_n2 = number; else if (result_n3 < 0) result_n3 = number; else if (result_n4 < 0) result_n4 = number; } /* sinon, bruit de fond(+1GMT for exampel) */ } } } if ((result_n1 >= 0) && (result_mm >= 0) && (result_dd >= 0) && (result_n2 >= 0) && (result_n3 >= 0) && (result_n4 >= 0)) { if (result_n4 >= 1000) { /* Sun Nov 6 08:49:37 1994 */ result->tm_year = result_n4 - 1900; result->tm_hour = result_n1; result->tm_min = result_n2; result->tm_sec = max(result_n3, 0); } else { /* Sun, 06 Nov 1994 08:49:37 GMT or Sunday, 06-Nov-94 08:49:37 GMT */ result->tm_hour = result_n2; result->tm_min = result_n3; result->tm_sec = max(result_n4, 0); if (result_n1 <= 50) /* 00 means 2000 */ result->tm_year = result_n1 + 100; else if (result_n1 < 1000) /* 99 means 1999 */ result->tm_year = result_n1; else /* 2000 */ result->tm_year = result_n1 - 1900; } result->tm_isdst = 0; /* assume GMT */ result->tm_yday = -1; /* don't know */ result->tm_wday = -1; /* don't know */ result->tm_mon = result_mm; result->tm_mday = result_dd; return result; } return NULL; } HTS_UNUSED static struct tm PT_GetTime(time_t t) { struct tm tmbuf; #ifdef _WIN32 struct tm *tm = gmtime(&t); #else struct tm *tm = gmtime_r(&t, &tmbuf); #endif if (tm != NULL) return *tm; else { memset(&tmbuf, 0, sizeof(tmbuf)); return tmbuf; } } HTS_UNUSED static int set_filetime(const char *file, struct tm *tm_time) { struct utimbuf tim; tim.actime = tim.modtime = timegm(tm_time); return utime(file, &tim); } HTS_UNUSED static int set_filetime_time_t(const char *file, time_t t) { if (t != (time_t) 0 && t != (time_t) - 1) { struct tm tm = PT_GetTime(t); return set_filetime(file, &tm); } return -1; } HTS_UNUSED static int set_filetime_rfc822(const char *file, const char *date) { struct tm buffer; struct tm *tm_s = convert_time_rfc822(&buffer, date); if (tm_s) { return set_filetime(file, tm_s); } else return -1; } #endif httrack-3.49.5/src/proxy/proxystrings.h0000644000175000017500000000540314336470674015131 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: Strings */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ // Strings a bit safer than static buffers #ifndef HTS_PROXYSTRINGS_DEFSTATIC #define HTS_PROXYSTRINGS_DEFSTATIC #include "htsstrings.h" /* Tools */ HTS_UNUSED static int ehexh(char c) { if ((c >= '0') && (c <= '9')) return c - '0'; if ((c >= 'a') && (c <= 'f')) c -= ('a' - 'A'); if ((c >= 'A') && (c <= 'F')) return (c - 'A' + 10); return 0; } HTS_UNUSED static int ehex(const char *s) { return 16 * ehexh(*s) + ehexh(*(s + 1)); } HTS_UNUSED static void unescapehttp(const char *s, String * tempo) { int i; for(i = 0; s[i] != '\0'; i++) { if (s[i] == '%' && s[i + 1] == '%') { i++; StringAddchar(*tempo, '%'); } else if (s[i] == '%') { char hc; i++; hc = (char) ehex(s + i); StringAddchar(*tempo, (char) hc); i++; // sauter 2 caractères finalement } else if (s[i] == '+') { StringAddchar(*tempo, ' '); } else StringAddchar(*tempo, s[i]); } } HTS_UNUSED static void escapexml(const char *s, String * tempo) { int i; for(i = 0; s[i] != '\0'; i++) { if (s[i] == '&') StringCat(*tempo, "&"); else if (s[i] == '<') StringCat(*tempo, "<"); else if (s[i] == '>') StringCat(*tempo, ">"); else if (s[i] == '\"') StringCat(*tempo, """); else StringAddchar(*tempo, s[i]); } } HTS_UNUSED static char* file_convert(char *dest, size_t size, const char *src) { size_t i; for(i = 0 ; src[i] != '\0' && i + 1 < size ; i++) { #ifdef _WIN32 if (src[i] == '/') { dest[i] = '\\'; } else { #endif dest[i] = src[i]; #ifdef _WIN32 } #endif } dest[i] = '\0'; return dest; } #endif httrack-3.49.5/src/proxy/changelog.txt0000644000175000017500000000163414336470674014657 000000000000000.5 - May 8 2006 - added ARC (Internet Archive 1.0) file format - first index output routines (proxytrack --convert ..) 0.4 - Sept 18 2005 - implemented very limited WebDAV (RFC2518) primitives - index enumeration fixes - limited access to the proxy server through HTTP in non-proxy mode 0.3 - Sept 10 2005 - implemented ICPv2 server (tested with Squid Web Proxy Cache) implementing ICP_OP_QUERY and ICP_OP_SECHO - redirects for URLs with missing ending '/' - fixed htsnet.h macro errors (bogus port during address copy) - keep-alive fixes 0.2 - Sept 4 2005 - hack to fix the "external files stored as absolute references" bug - proper locking for indexes (unlocked zFile) - added previous httrack .dat/.ndx cache format - added catalog as index fallback - started to write ICPv2 server (RFC2186), but not yet ready 0.1 - Aug 27 2005 - initial release: HTTP (RFC2616) proxy and aggregation ready httrack-3.49.5/src/proxy/COPYING0000644000175000017500000010451314336470674013222 00000000000000 GNU GENERAL PUBLIC LICENSE Version 3, 29 June 2007 Copyright (C) 2007 Free Software Foundation, Inc. Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. Preamble The GNU General Public License is a free, copyleft license for software and other kinds of works. The licenses for most software and other practical works are designed to take away your freedom to share and change the works. By contrast, the GNU General Public License is intended to guarantee your freedom to share and change all versions of a program--to make sure it remains free software for all its users. We, the Free Software Foundation, use the GNU General Public License for most of our software; it applies also to any other work released this way by its authors. You can apply it to your programs, too. When we speak of free software, we are referring to freedom, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for them if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs, and that you know you can do these things. To protect your rights, we need to prevent others from denying you these rights or asking you to surrender the rights. Therefore, you have certain responsibilities if you distribute copies of the software, or if you modify it: responsibilities to respect the freedom of others. For example, if you distribute copies of such a program, whether gratis or for a fee, you must pass on to the recipients the same freedoms that you received. You must make sure that they, too, receive or can get the source code. And you must show them these terms so they know their rights. Developers that use the GNU GPL protect your rights with two steps: (1) assert copyright on the software, and (2) offer you this License giving you legal permission to copy, distribute and/or modify it. For the developers' and authors' protection, the GPL clearly explains that there is no warranty for this free software. For both users' and authors' sake, the GPL requires that modified versions be marked as changed, so that their problems will not be attributed erroneously to authors of previous versions. Some devices are designed to deny users access to install or run modified versions of the software inside them, although the manufacturer can do so. This is fundamentally incompatible with the aim of protecting users' freedom to change the software. The systematic pattern of such abuse occurs in the area of products for individuals to use, which is precisely where it is most unacceptable. Therefore, we have designed this version of the GPL to prohibit the practice for those products. If such problems arise substantially in other domains, we stand ready to extend this provision to those domains in future versions of the GPL, as needed to protect the freedom of users. Finally, every program is threatened constantly by software patents. States should not allow patents to restrict development and use of software on general-purpose computers, but in those that do, we wish to avoid the special danger that patents applied to a free program could make it effectively proprietary. To prevent this, the GPL assures that patents cannot be used to render the program non-free. The precise terms and conditions for copying, distribution and modification follow. TERMS AND CONDITIONS 0. Definitions. "This License" refers to version 3 of the GNU General Public License. "Copyright" also means copyright-like laws that apply to other kinds of works, such as semiconductor masks. "The Program" refers to any copyrightable work licensed under this License. Each licensee is addressed as "you". "Licensees" and "recipients" may be individuals or organizations. To "modify" a work means to copy from or adapt all or part of the work in a fashion requiring copyright permission, other than the making of an exact copy. The resulting work is called a "modified version" of the earlier work or a work "based on" the earlier work. A "covered work" means either the unmodified Program or a work based on the Program. To "propagate" a work means to do anything with it that, without permission, would make you directly or secondarily liable for infringement under applicable copyright law, except executing it on a computer or modifying a private copy. Propagation includes copying, distribution (with or without modification), making available to the public, and in some countries other activities as well. To "convey" a work means any kind of propagation that enables other parties to make or receive copies. Mere interaction with a user through a computer network, with no transfer of a copy, is not conveying. An interactive user interface displays "Appropriate Legal Notices" to the extent that it includes a convenient and prominently visible feature that (1) displays an appropriate copyright notice, and (2) tells the user that there is no warranty for the work (except to the extent that warranties are provided), that licensees may convey the work under this License, and how to view a copy of this License. If the interface presents a list of user commands or options, such as a menu, a prominent item in the list meets this criterion. 1. Source Code. The "source code" for a work means the preferred form of the work for making modifications to it. "Object code" means any non-source form of a work. A "Standard Interface" means an interface that either is an official standard defined by a recognized standards body, or, in the case of interfaces specified for a particular programming language, one that is widely used among developers working in that language. The "System Libraries" of an executable work include anything, other than the work as a whole, that (a) is included in the normal form of packaging a Major Component, but which is not part of that Major Component, and (b) serves only to enable use of the work with that Major Component, or to implement a Standard Interface for which an implementation is available to the public in source code form. A "Major Component", in this context, means a major essential component (kernel, window system, and so on) of the specific operating system (if any) on which the executable work runs, or a compiler used to produce the work, or an object code interpreter used to run it. The "Corresponding Source" for a work in object code form means all the source code needed to generate, install, and (for an executable work) run the object code and to modify the work, including scripts to control those activities. However, it does not include the work's System Libraries, or general-purpose tools or generally available free programs which are used unmodified in performing those activities but which are not part of the work. For example, Corresponding Source includes interface definition files associated with source files for the work, and the source code for shared libraries and dynamically linked subprograms that the work is specifically designed to require, such as by intimate data communication or control flow between those subprograms and other parts of the work. The Corresponding Source need not include anything that users can regenerate automatically from other parts of the Corresponding Source. The Corresponding Source for a work in source code form is that same work. 2. Basic Permissions. All rights granted under this License are granted for the term of copyright on the Program, and are irrevocable provided the stated conditions are met. This License explicitly affirms your unlimited permission to run the unmodified Program. The output from running a covered work is covered by this License only if the output, given its content, constitutes a covered work. This License acknowledges your rights of fair use or other equivalent, as provided by copyright law. You may make, run and propagate covered works that you do not convey, without conditions so long as your license otherwise remains in force. You may convey covered works to others for the sole purpose of having them make modifications exclusively for you, or provide you with facilities for running those works, provided that you comply with the terms of this License in conveying all material for which you do not control copyright. Those thus making or running the covered works for you must do so exclusively on your behalf, under your direction and control, on terms that prohibit them from making any copies of your copyrighted material outside their relationship with you. Conveying under any other circumstances is permitted solely under the conditions stated below. Sublicensing is not allowed; section 10 makes it unnecessary. 3. Protecting Users' Legal Rights From Anti-Circumvention Law. No covered work shall be deemed part of an effective technological measure under any applicable law fulfilling obligations under article 11 of the WIPO copyright treaty adopted on 20 December 1996, or similar laws prohibiting or restricting circumvention of such measures. When you convey a covered work, you waive any legal power to forbid circumvention of technological measures to the extent such circumvention is effected by exercising rights under this License with respect to the covered work, and you disclaim any intention to limit operation or modification of the work as a means of enforcing, against the work's users, your or third parties' legal rights to forbid circumvention of technological measures. 4. Conveying Verbatim Copies. You may convey verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice; keep intact all notices stating that this License and any non-permissive terms added in accord with section 7 apply to the code; keep intact all notices of the absence of any warranty; and give all recipients a copy of this License along with the Program. You may charge any price or no price for each copy that you convey, and you may offer support or warranty protection for a fee. 5. Conveying Modified Source Versions. You may convey a work based on the Program, or the modifications to produce it from the Program, in the form of source code under the terms of section 4, provided that you also meet all of these conditions: a) The work must carry prominent notices stating that you modified it, and giving a relevant date. b) The work must carry prominent notices stating that it is released under this License and any conditions added under section 7. This requirement modifies the requirement in section 4 to "keep intact all notices". c) You must license the entire work, as a whole, under this License to anyone who comes into possession of a copy. This License will therefore apply, along with any applicable section 7 additional terms, to the whole of the work, and all its parts, regardless of how they are packaged. This License gives no permission to license the work in any other way, but it does not invalidate such permission if you have separately received it. d) If the work has interactive user interfaces, each must display Appropriate Legal Notices; however, if the Program has interactive interfaces that do not display Appropriate Legal Notices, your work need not make them do so. A compilation of a covered work with other separate and independent works, which are not by their nature extensions of the covered work, and which are not combined with it such as to form a larger program, in or on a volume of a storage or distribution medium, is called an "aggregate" if the compilation and its resulting copyright are not used to limit the access or legal rights of the compilation's users beyond what the individual works permit. Inclusion of a covered work in an aggregate does not cause this License to apply to the other parts of the aggregate. 6. Conveying Non-Source Forms. You may convey a covered work in object code form under the terms of sections 4 and 5, provided that you also convey the machine-readable Corresponding Source under the terms of this License, in one of these ways: a) Convey the object code in, or embodied in, a physical product (including a physical distribution medium), accompanied by the Corresponding Source fixed on a durable physical medium customarily used for software interchange. b) Convey the object code in, or embodied in, a physical product (including a physical distribution medium), accompanied by a written offer, valid for at least three years and valid for as long as you offer spare parts or customer support for that product model, to give anyone who possesses the object code either (1) a copy of the Corresponding Source for all the software in the product that is covered by this License, on a durable physical medium customarily used for software interchange, for a price no more than your reasonable cost of physically performing this conveying of source, or (2) access to copy the Corresponding Source from a network server at no charge. c) Convey individual copies of the object code with a copy of the written offer to provide the Corresponding Source. This alternative is allowed only occasionally and noncommercially, and only if you received the object code with such an offer, in accord with subsection 6b. d) Convey the object code by offering access from a designated place (gratis or for a charge), and offer equivalent access to the Corresponding Source in the same way through the same place at no further charge. You need not require recipients to copy the Corresponding Source along with the object code. If the place to copy the object code is a network server, the Corresponding Source may be on a different server (operated by you or a third party) that supports equivalent copying facilities, provided you maintain clear directions next to the object code saying where to find the Corresponding Source. Regardless of what server hosts the Corresponding Source, you remain obligated to ensure that it is available for as long as needed to satisfy these requirements. e) Convey the object code using peer-to-peer transmission, provided you inform other peers where the object code and Corresponding Source of the work are being offered to the general public at no charge under subsection 6d. A separable portion of the object code, whose source code is excluded from the Corresponding Source as a System Library, need not be included in conveying the object code work. A "User Product" is either (1) a "consumer product", which means any tangible personal property which is normally used for personal, family, or household purposes, or (2) anything designed or sold for incorporation into a dwelling. In determining whether a product is a consumer product, doubtful cases shall be resolved in favor of coverage. For a particular product received by a particular user, "normally used" refers to a typical or common use of that class of product, regardless of the status of the particular user or of the way in which the particular user actually uses, or expects or is expected to use, the product. A product is a consumer product regardless of whether the product has substantial commercial, industrial or non-consumer uses, unless such uses represent the only significant mode of use of the product. "Installation Information" for a User Product means any methods, procedures, authorization keys, or other information required to install and execute modified versions of a covered work in that User Product from a modified version of its Corresponding Source. The information must suffice to ensure that the continued functioning of the modified object code is in no case prevented or interfered with solely because modification has been made. If you convey an object code work under this section in, or with, or specifically for use in, a User Product, and the conveying occurs as part of a transaction in which the right of possession and use of the User Product is transferred to the recipient in perpetuity or for a fixed term (regardless of how the transaction is characterized), the Corresponding Source conveyed under this section must be accompanied by the Installation Information. But this requirement does not apply if neither you nor any third party retains the ability to install modified object code on the User Product (for example, the work has been installed in ROM). The requirement to provide Installation Information does not include a requirement to continue to provide support service, warranty, or updates for a work that has been modified or installed by the recipient, or for the User Product in which it has been modified or installed. Access to a network may be denied when the modification itself materially and adversely affects the operation of the network or violates the rules and protocols for communication across the network. Corresponding Source conveyed, and Installation Information provided, in accord with this section must be in a format that is publicly documented (and with an implementation available to the public in source code form), and must require no special password or key for unpacking, reading or copying. 7. Additional Terms. "Additional permissions" are terms that supplement the terms of this License by making exceptions from one or more of its conditions. Additional permissions that are applicable to the entire Program shall be treated as though they were included in this License, to the extent that they are valid under applicable law. If additional permissions apply only to part of the Program, that part may be used separately under those permissions, but the entire Program remains governed by this License without regard to the additional permissions. When you convey a copy of a covered work, you may at your option remove any additional permissions from that copy, or from any part of it. (Additional permissions may be written to require their own removal in certain cases when you modify the work.) You may place additional permissions on material, added by you to a covered work, for which you have or can give appropriate copyright permission. Notwithstanding any other provision of this License, for material you add to a covered work, you may (if authorized by the copyright holders of that material) supplement the terms of this License with terms: a) Disclaiming warranty or limiting liability differently from the terms of sections 15 and 16 of this License; or b) Requiring preservation of specified reasonable legal notices or author attributions in that material or in the Appropriate Legal Notices displayed by works containing it; or c) Prohibiting misrepresentation of the origin of that material, or requiring that modified versions of such material be marked in reasonable ways as different from the original version; or d) Limiting the use for publicity purposes of names of licensors or authors of the material; or e) Declining to grant rights under trademark law for use of some trade names, trademarks, or service marks; or f) Requiring indemnification of licensors and authors of that material by anyone who conveys the material (or modified versions of it) with contractual assumptions of liability to the recipient, for any liability that these contractual assumptions directly impose on those licensors and authors. All other non-permissive additional terms are considered "further restrictions" within the meaning of section 10. If the Program as you received it, or any part of it, contains a notice stating that it is governed by this License along with a term that is a further restriction, you may remove that term. If a license document contains a further restriction but permits relicensing or conveying under this License, you may add to a covered work material governed by the terms of that license document, provided that the further restriction does not survive such relicensing or conveying. If you add terms to a covered work in accord with this section, you must place, in the relevant source files, a statement of the additional terms that apply to those files, or a notice indicating where to find the applicable terms. Additional terms, permissive or non-permissive, may be stated in the form of a separately written license, or stated as exceptions; the above requirements apply either way. 8. Termination. You may not propagate or modify a covered work except as expressly provided under this License. Any attempt otherwise to propagate or modify it is void, and will automatically terminate your rights under this License (including any patent licenses granted under the third paragraph of section 11). However, if you cease all violation of this License, then your license from a particular copyright holder is reinstated (a) provisionally, unless and until the copyright holder explicitly and finally terminates your license, and (b) permanently, if the copyright holder fails to notify you of the violation by some reasonable means prior to 60 days after the cessation. Moreover, your license from a particular copyright holder is reinstated permanently if the copyright holder notifies you of the violation by some reasonable means, this is the first time you have received notice of violation of this License (for any work) from that copyright holder, and you cure the violation prior to 30 days after your receipt of the notice. Termination of your rights under this section does not terminate the licenses of parties who have received copies or rights from you under this License. If your rights have been terminated and not permanently reinstated, you do not qualify to receive new licenses for the same material under section 10. 9. Acceptance Not Required for Having Copies. You are not required to accept this License in order to receive or run a copy of the Program. Ancillary propagation of a covered work occurring solely as a consequence of using peer-to-peer transmission to receive a copy likewise does not require acceptance. However, nothing other than this License grants you permission to propagate or modify any covered work. These actions infringe copyright if you do not accept this License. Therefore, by modifying or propagating a covered work, you indicate your acceptance of this License to do so. 10. Automatic Licensing of Downstream Recipients. Each time you convey a covered work, the recipient automatically receives a license from the original licensors, to run, modify and propagate that work, subject to this License. You are not responsible for enforcing compliance by third parties with this License. An "entity transaction" is a transaction transferring control of an organization, or substantially all assets of one, or subdividing an organization, or merging organizations. If propagation of a covered work results from an entity transaction, each party to that transaction who receives a copy of the work also receives whatever licenses to the work the party's predecessor in interest had or could give under the previous paragraph, plus a right to possession of the Corresponding Source of the work from the predecessor in interest, if the predecessor has it or can get it with reasonable efforts. You may not impose any further restrictions on the exercise of the rights granted or affirmed under this License. For example, you may not impose a license fee, royalty, or other charge for exercise of rights granted under this License, and you may not initiate litigation (including a cross-claim or counterclaim in a lawsuit) alleging that any patent claim is infringed by making, using, selling, offering for sale, or importing the Program or any portion of it. 11. Patents. A "contributor" is a copyright holder who authorizes use under this License of the Program or a work on which the Program is based. The work thus licensed is called the contributor's "contributor version". A contributor's "essential patent claims" are all patent claims owned or controlled by the contributor, whether already acquired or hereafter acquired, that would be infringed by some manner, permitted by this License, of making, using, or selling its contributor version, but do not include claims that would be infringed only as a consequence of further modification of the contributor version. For purposes of this definition, "control" includes the right to grant patent sublicenses in a manner consistent with the requirements of this License. Each contributor grants you a non-exclusive, worldwide, royalty-free patent license under the contributor's essential patent claims, to make, use, sell, offer for sale, import and otherwise run, modify and propagate the contents of its contributor version. In the following three paragraphs, a "patent license" is any express agreement or commitment, however denominated, not to enforce a patent (such as an express permission to practice a patent or covenant not to sue for patent infringement). To "grant" such a patent license to a party means to make such an agreement or commitment not to enforce a patent against the party. If you convey a covered work, knowingly relying on a patent license, and the Corresponding Source of the work is not available for anyone to copy, free of charge and under the terms of this License, through a publicly available network server or other readily accessible means, then you must either (1) cause the Corresponding Source to be so available, or (2) arrange to deprive yourself of the benefit of the patent license for this particular work, or (3) arrange, in a manner consistent with the requirements of this License, to extend the patent license to downstream recipients. "Knowingly relying" means you have actual knowledge that, but for the patent license, your conveying the covered work in a country, or your recipient's use of the covered work in a country, would infringe one or more identifiable patents in that country that you have reason to believe are valid. If, pursuant to or in connection with a single transaction or arrangement, you convey, or propagate by procuring conveyance of, a covered work, and grant a patent license to some of the parties receiving the covered work authorizing them to use, propagate, modify or convey a specific copy of the covered work, then the patent license you grant is automatically extended to all recipients of the covered work and works based on it. A patent license is "discriminatory" if it does not include within the scope of its coverage, prohibits the exercise of, or is conditioned on the non-exercise of one or more of the rights that are specifically granted under this License. You may not convey a covered work if you are a party to an arrangement with a third party that is in the business of distributing software, under which you make payment to the third party based on the extent of your activity of conveying the work, and under which the third party grants, to any of the parties who would receive the covered work from you, a discriminatory patent license (a) in connection with copies of the covered work conveyed by you (or copies made from those copies), or (b) primarily for and in connection with specific products or compilations that contain the covered work, unless you entered into that arrangement, or that patent license was granted, prior to 28 March 2007. Nothing in this License shall be construed as excluding or limiting any implied license or other defenses to infringement that may otherwise be available to you under applicable patent law. 12. No Surrender of Others' Freedom. If conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License. If you cannot convey a covered work so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not convey it at all. For example, if you agree to terms that obligate you to collect a royalty for further conveying from those to whom you convey the Program, the only way you could satisfy both those terms and this License would be to refrain entirely from conveying the Program. 13. Use with the GNU Affero General Public License. Notwithstanding any other provision of this License, you have permission to link or combine any covered work with a work licensed under version 3 of the GNU Affero General Public License into a single combined work, and to convey the resulting work. The terms of this License will continue to apply to the part which is the covered work, but the special requirements of the GNU Affero General Public License, section 13, concerning interaction through a network will apply to the combination as such. 14. Revised Versions of this License. The Free Software Foundation may publish revised and/or new versions of the GNU General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. Each version is given a distinguishing version number. If the Program specifies that a certain numbered version of the GNU General Public License "or any later version" applies to it, you have the option of following the terms and conditions either of that numbered version or of any later version published by the Free Software Foundation. If the Program does not specify a version number of the GNU General Public License, you may choose any version ever published by the Free Software Foundation. If the Program specifies that a proxy can decide which future versions of the GNU General Public License can be used, that proxy's public statement of acceptance of a version permanently authorizes you to choose that version for the Program. Later license versions may give you additional or different permissions. However, no additional obligations are imposed on any author or copyright holder as a result of your choosing to follow a later version. 15. Disclaimer of Warranty. THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. 16. Limitation of Liability. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. 17. Interpretation of Sections 15 and 16. If the disclaimer of warranty and limitation of liability provided above cannot be given local legal effect according to their terms, reviewing courts shall apply local law that most closely approximates an absolute waiver of all civil liability in connection with the Program, unless a warranty or assumption of liability accompanies a copy of the Program in return for a fee. END OF TERMS AND CONDITIONS How to Apply These Terms to Your New Programs If you develop a new program, and you want it to be of the greatest possible use to the public, the best way to achieve this is to make it free software which everyone can redistribute and change under these terms. To do so, attach the following notices to the program. It is safest to attach them to the start of each source file to most effectively state the exclusion of warranty; and each file should have at least the "copyright" line and a pointer to where the full notice is found. Copyright (C) This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Also add information on how to contact you by electronic and paper mail. If the program does terminal interaction, make it output a short notice like this when it starts in an interactive mode: Copyright (C) This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. This is free software, and you are welcome to redistribute it under certain conditions; type `show c' for details. The hypothetical commands `show w' and `show c' should show the appropriate parts of the General Public License. Of course, your program's commands might be different; for a GUI interface, you would use an "about box". You should also get your employer (if you work as a programmer) or school, if any, to sign a "copyright disclaimer" for the program, if necessary. For more information on this, and how to apply and follow the GNU GPL, see . The GNU General Public License does not permit incorporating your program into proprietary programs. If your program is a subroutine library, you may consider it more useful to permit linking proprietary applications with the library. If this is what you want to do, use the GNU Lesser General Public License instead of this License. But first, please read . httrack-3.49.5/src/proxy/AUTHORS0000644000175000017500000000004214336470674013227 00000000000000Xavier Roche httrack-3.49.5/src/proxy/store.c0000644000175000017500000022522714360534067013467 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Please visit our Website: http://www.httrack.com */ /* Parts (inside ARC format routines) by Lars Clausen (lc@statsbiblioteket.dk) */ /* ------------------------------------------------------------ */ /* File: Cache manager for ProxyTrack */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ #include #include #include #include /* Locking */ #ifdef _WIN32 #include /* _beginthread, _endthread */ #else #include #endif #define HTSSAFE_ABORT_FUNCTION(A,B,C) #include "htsglobal.h" #define HTS_INTERNAL_BYTECODE #include "coucal.h" #include "htsmd5.h" #undef HTS_INTERNAL_BYTECODE #include "../minizip/mztools.h" #include "../minizip/zip.h" #include "htscore.h" #include "htsback.h" #include "store.h" #include "proxystrings.h" #include "proxytrack.h" /* Unlocked functions */ static int PT_LookupCache__New_u(PT_Index index, const char *url); static PT_Element PT_ReadCache__New_u(PT_Index index, const char *url, int flags); static int PT_LookupCache__Old_u(PT_Index index, const char *url); static PT_Element PT_ReadCache__Old_u(PT_Index index, const char *url, int flags); static int PT_LookupCache__Arc_u(PT_Index index, const char *url); static PT_Element PT_ReadCache__Arc_u(PT_Index index, const char *url, int flags); /* Locking */ #ifdef _WIN32 void MutexInit(PT_Mutex * pMutex) { *pMutex = CreateMutex(NULL, FALSE, NULL); } void MutexLock(PT_Mutex * pMutex) { WaitForSingleObject(*pMutex, INFINITE); } void MutexUnlock(PT_Mutex * pMutex) { ReleaseMutex(*pMutex); } void MutexFree(PT_Mutex * pMutex) { CloseHandle(*pMutex); *pMutex = NULL; } #else void MutexInit(PT_Mutex * pMutex) { (void) pthread_mutex_init(pMutex, 0); } void MutexLock(PT_Mutex * pMutex) { pthread_mutex_lock(pMutex); } void MutexUnlock(PT_Mutex * pMutex) { pthread_mutex_unlock(pMutex); } void MutexFree(PT_Mutex * pMutex) { pthread_mutex_destroy(pMutex); } #endif /* Indexes */ typedef struct _PT_Index__New _PT_Index__New; typedef struct _PT_Index__Old _PT_Index__Old; typedef struct _PT_Index__Arc _PT_Index__Arc; typedef struct _PT_Index_Functions _PT_Index_Functions; typedef struct _PT_Index__New *PT_Index__New; typedef struct _PT_Index__Old *PT_Index__Old; typedef struct _PT_Index__Arc *PT_Index__Arc; typedef struct _PT_Index_Functions *PT_Index_Functions; enum { PT_CACHE_UNDEFINED = -1, PT_CACHE_MIN = 0, PT_CACHE__NEW = PT_CACHE_MIN, PT_CACHE__OLD, PT_CACHE__ARC, PT_CACHE_MAX = PT_CACHE__ARC }; static int PT_LoadCache__New(PT_Index index, const char *filename); static void PT_Index_Delete__New(PT_Index * pindex); static PT_Element PT_ReadCache__New(PT_Index index, const char *url, int flags); static int PT_LookupCache__New(PT_Index index, const char *url); static int PT_SaveCache__New(PT_Indexes indexes, const char *filename); /**/ static int PT_LoadCache__Old(PT_Index index, const char *filename); static void PT_Index_Delete__Old(PT_Index * pindex); static PT_Element PT_ReadCache__Old(PT_Index index, const char *url, int flags); static int PT_LookupCache__Old(PT_Index index, const char *url); /**/ static int PT_LoadCache__Arc(PT_Index index, const char *filename); static void PT_Index_Delete__Arc(PT_Index * pindex); static PT_Element PT_ReadCache__Arc(PT_Index index, const char *url, int flags); static int PT_LookupCache__Arc(PT_Index index, const char *url); static int PT_SaveCache__Arc(PT_Indexes indexes, const char *filename); struct _PT_Index_Functions { /* Mandatory services */ int (*PT_LoadCache) (PT_Index index, const char *filename); void (*PT_Index_Delete) (PT_Index * pindex); PT_Element(*PT_ReadCache) (PT_Index index, const char *url, int flags); int (*PT_LookupCache) (PT_Index index, const char *url); /* Optional services */ int (*PT_SaveCache) (PT_Indexes indexes, const char *filename); }; static _PT_Index_Functions _IndexFuncts[] = { {PT_LoadCache__New, PT_Index_Delete__New, PT_ReadCache__New, PT_LookupCache__New, PT_SaveCache__New}, {PT_LoadCache__Old, PT_Index_Delete__Old, PT_ReadCache__Old, PT_LookupCache__Old, NULL}, {PT_LoadCache__Arc, PT_Index_Delete__Arc, PT_ReadCache__Arc, PT_LookupCache__Arc, PT_SaveCache__Arc}, {NULL, NULL, NULL, NULL} }; #define PT_INDEX_COMMON_STRUCTURE \ time_t timestamp; \ coucal hash; \ char startUrl[1024] struct _PT_Index__New { PT_INDEX_COMMON_STRUCTURE; char path[1024]; /* either empty, or must include ending / */ int fixedPath; int safeCache; unzFile zFile; PT_Mutex zFileLock; }; struct _PT_Index__Old { PT_INDEX_COMMON_STRUCTURE; char filenameDat[1024]; char filenameNdx[1024]; FILE *dat, *ndx; PT_Mutex fileLock; int version; char lastmodified[1024]; char path[1024]; /* either empty, or must include ending / */ int fixedPath; int safeCache; }; struct _PT_Index__Arc { PT_INDEX_COMMON_STRUCTURE; FILE *file; PT_Mutex fileLock; int version; char lastmodified[1024]; char line[2048]; char filenameIndexBuff[2048]; }; struct _PT_Index { int type; union { _PT_Index__New formatNew; _PT_Index__Old formatOld; _PT_Index__Arc formatArc; struct { PT_INDEX_COMMON_STRUCTURE; } common; } slots; }; struct _PT_Indexes { coucal cil; struct _PT_Index **index; int index_size; }; struct _PT_CacheItem { time_t lastUsed; size_t size; void *data; }; struct _PT_Cache { coucal index; size_t maxSize; size_t totalSize; int count; }; PT_Indexes PT_New(void) { PT_Indexes index = (PT_Indexes) calloc(sizeof(_PT_Indexes), 1); index->cil = coucal_new(0); coucal_set_name(index->cil, "index->cil"); index->index_size = 0; index->index = NULL; return index; } void PT_Delete(PT_Indexes index) { if (index != NULL) { coucal_delete(&index->cil); free(index); } } int PT_RemoveIndex(PT_Indexes index, int indexId) { return 0; } static int binput(char *buff, char *s, int max) { int count = 0; int destCount = 0; // Note: \0 will return 1 while(destCount < max && buff[count] != '\0' && buff[count] != '\n') { if (buff[count] != '\r') { s[destCount++] = buff[count]; } count++; } s[destCount] = '\0'; // then return the supplemental jump offset return count + 1; } static time_t file_timestamp(const char *file) { struct stat buf; if (stat(file, &buf) == 0) { time_t tt = buf.st_mtime; if (tt != (time_t) 0 && tt != (time_t) - 1) { return tt; } } return (time_t) 0; } static int PT_Index_Check__(PT_Index index, const char *file, int line) { if (index == NULL) return 0; if (index->type >= PT_CACHE_MIN && index->type <= PT_CACHE_MAX) return 1; proxytrack_print_log(CRITICAL, "index corrupted in memory at %s:%d", file, line); return 0; } #define SAFE_INDEX(index) PT_Index_Check__(index, __FILE__, __LINE__) /* ------------------------------------------------------------ */ /* Generic cache dispatch */ /* ------------------------------------------------------------ */ void PT_Index_Delete(PT_Index * pindex) { if (pindex != NULL && (*pindex) != NULL) { PT_Index index = *pindex; if (SAFE_INDEX(index)) { _IndexFuncts[index->type].PT_Index_Delete(pindex); } free(index); *pindex = NULL; } } static void PT_Index_Delete__New(PT_Index * pindex) { if (pindex != NULL && (*pindex) != NULL) { PT_Index__New index = &(*pindex)->slots.formatNew; if (index->zFile != NULL) { unzClose(index->zFile); index->zFile = NULL; } if (index->hash != NULL) { coucal_delete(&index->hash); index->hash = NULL; } MutexFree(&index->zFileLock); } } static void PT_Index_Delete__Old(PT_Index * pindex) { if (pindex != NULL && (*pindex) != NULL) { PT_Index__Old index = &(*pindex)->slots.formatOld; if (index->dat != NULL) { fclose(index->dat); } if (index->ndx != NULL) { fclose(index->ndx); } if (index->hash != NULL) { coucal_delete(&index->hash); index->hash = NULL; } MutexFree(&index->fileLock); } } static void PT_Index_Delete__Arc(PT_Index * pindex) { if (pindex != NULL && (*pindex) != NULL) { PT_Index__Arc index = &(*pindex)->slots.formatArc; if (index->file != NULL) { fclose(index->file); } MutexFree(&index->fileLock); } } int PT_AddIndex(PT_Indexes indexes, const char *path) { PT_Index index = PT_LoadCache(path); if (index != NULL) { int ret = PT_IndexMerge(indexes, &index); if (index != NULL) { PT_Index_Delete(&index); } return ret; } return -1; } PT_Element PT_Index_HTML_BuildRootInfo(PT_Indexes indexes) { if (indexes != NULL) { PT_Element elt = PT_ElementNew(); int i; String html = STRING_EMPTY; StringClear(html); StringCat(html, "" PROXYTRACK_COMMENT_HEADER DISABLE_IE_FRIENDLY_HTTP_ERROR_MESSAGES "\r\n" "ProxyTrack " PROXYTRACK_VERSION " Catalog" "\r\n" "\r\n" "

Available sites in this cache:


" "
"); StringCat(html, "
    \r\n"); for(i = 0; i < indexes->index_size; i++) { if (indexes->index[i] != NULL && indexes->index[i]->slots.common.startUrl[0] != '\0') { const char *url = indexes->index[i]->slots.common.startUrl; StringCat(html, "
  • \r\n"); StringCat(html, ""); StringCat(html, url); StringCat(html, "\r\n"); StringCat(html, "
  • \r\n"); } } StringCat(html, "
\r\n"); StringCat(html, "\r\n"); elt->size = StringLength(html); elt->adr = StringAcquire(&html); elt->statuscode = HTTP_OK; strcpy(elt->charset, "iso-8859-1"); strcpy(elt->contenttype, "text/html"); strcpy(elt->msg, "OK"); StringFree(html); return elt; } return NULL; } static char *strchr_stop(char *str, char c, char stop) { for(; *str != 0 && *str != stop && *str != c; str++) ; if (*str == c) return str; return NULL; } char **PT_Enumerate(PT_Indexes indexes, const char *url, int subtree) { // should be cached! if (indexes != NULL && indexes->cil != NULL) { unsigned int urlSize; String list = STRING_EMPTY; String listindexes = STRING_EMPTY; String subitem = STRING_EMPTY; unsigned int listCount = 0; struct_coucal_enum en = coucal_enum_new(indexes->cil); coucal_item *chain; coucal hdupes = NULL; if (!subtree) { hdupes = coucal_new(0); coucal_set_name(hdupes, "hdupes"); } StringClear(list); StringClear(listindexes); StringClear(subitem); if (strncmp(url, "http://", 7) == 0) url += 7; urlSize = (unsigned int) strlen(url); while((chain = coucal_enum_next(&en))) { long int index = (long int) chain->value.intg; if (urlSize == 0 || strncmp(chain->name, url, urlSize) == 0) { if (index >= 0 && index < indexes->index_size) { char *item = (char*) chain->name + urlSize; if (*item == '/') item++; { char *pos = subtree ? 0 : strchr_stop(item, '/', '?'); unsigned int len = pos ? (unsigned int) (pos - item) : (unsigned int) strlen(item); if (len > 0 /* default document */ || *item == 0) { int isFolder = (item[len] == '/'); StringClear(subitem); if (len > 0) StringMemcat(subitem, item, len); if (len == 0 || !coucal_exists(hdupes, StringBuff(subitem))) { char *ptr = NULL; ptr += StringLength(list); if (len > 0) StringCat(list, StringBuff(subitem)); if (isFolder) StringCat(list, "/"); StringMemcat(list, "\0", 1); /* NULL terminated strings */ StringMemcat(listindexes, (char*) &ptr, sizeof(ptr)); listCount++; coucal_write(hdupes, StringBuff(subitem), 0); } } } } else { proxytrack_print_log(CRITICAL, "PT_Enumerate:Corrupted central index locator"); } } } StringFree(subitem); coucal_delete(&hdupes); if (listCount > 0) { unsigned int i; void *blk; char *nullPointer = NULL; char *startStrings; /* NULL terminated index */ StringMemcat(listindexes, (char*) &nullPointer, sizeof(nullPointer)); /* start of all strings (index) */ startStrings = nullPointer + StringLength(listindexes); /* copy list of URLs after indexes */ StringMemcat(listindexes, StringBuff(list), StringLength(list)); /* ---- no reallocation beyond this point (fixed addresses) ---- */ /* start of all strings (pointer) */ startStrings = (startStrings - nullPointer) + StringBuffRW(listindexes); /* transform indexes into references */ for(i = 0; i < listCount; i++) { char *ptr = NULL; unsigned int ndx; memcpy(&ptr, &StringBuff(listindexes)[i * sizeof(char *)], sizeof(char *)); ndx = (unsigned int) (ptr - nullPointer); ptr = startStrings + ndx; memcpy(&StringBuffRW(listindexes)[i * sizeof(char *)], &ptr, sizeof(char *)); } blk = StringAcquire(&listindexes); StringFree(list); StringFree(listindexes); return (char **) blk; } } return NULL; } void PT_Enumerate_Delete(char ***plist) { if (plist != NULL && *plist != NULL) { free(*plist); *plist = NULL; } } static int PT_GetType(const char *filename) { char *dot = strrchr(filename, '.'); if (dot != NULL) { if (strcasecmp(dot, ".zip") == 0) { return PT_CACHE__NEW; } else if (strcasecmp(dot, ".ndx") == 0 || strcasecmp(dot, ".dat") == 0) { return PT_CACHE__OLD; } else if (strcasecmp(dot, ".arc") == 0) { return PT_CACHE__ARC; } } return PT_CACHE_UNDEFINED; } PT_Index PT_LoadCache(const char *filename) { int type = PT_GetType(filename); if (type != PT_CACHE_UNDEFINED) { PT_Index index = calloc(sizeof(_PT_Index), 1); if (index != NULL) { index->type = type; index->slots.common.timestamp = (time_t) time(NULL); index->slots.common.startUrl[0] = '\0'; index->slots.common.hash = coucal_new(0); coucal_set_name(index->slots.common.hash, "index->slots.common.hash"); if (!_IndexFuncts[type].PT_LoadCache(index, filename)) { proxytrack_print_log(DEBUG, "reading httrack cache (format #%d) %s : error", type, filename); free(index); index = NULL; return NULL; } else { proxytrack_print_log(DEBUG, "reading httrack cache (format #%d) %s : success", type, filename); } /* default starting URL is the first hash entry */ if (index->slots.common.startUrl[0] == '\0') { struct_coucal_enum en = coucal_enum_new(index->slots.common.hash); coucal_item *chain; chain = coucal_enum_next(&en); if (chain != NULL && strstr(chain->name, "/robots.txt") != NULL) { chain = coucal_enum_next(&en); } if (chain != NULL) { if (!link_has_authority(chain->name)) strcat(index->slots.common.startUrl, "http://"); strcat(index->slots.common.startUrl, chain->name); } } } return index; } return NULL; } static long int filesize(const char *filename) { struct stat st; memset(&st, 0, sizeof(st)); if (stat(filename, &st) == 0) { return (long int) st.st_size; } return -1; } int PT_LookupCache(PT_Index index, const char *url) { if (index != NULL && SAFE_INDEX(index)) { return _IndexFuncts[index->type].PT_LookupCache(index, url); } return 0; } int PT_SaveCache(PT_Indexes indexes, const char *filename) { int type = PT_GetType(filename); if (type != PT_CACHE_UNDEFINED) { if (_IndexFuncts[type].PT_SaveCache != NULL) { int ret = _IndexFuncts[type].PT_SaveCache(indexes, filename); if (ret == 0) { (void) set_filetime_time_t(filename, PT_GetTimeIndex(indexes)); return 0; } } } return -1; } int PT_EnumCache(PT_Indexes indexes, int (*callback) (void *, const char *url, PT_Element), void *arg) { if (indexes != NULL && indexes->cil != NULL) { struct_coucal_enum en = coucal_enum_new(indexes->cil); coucal_item *chain; while((chain = coucal_enum_next(&en))) { const long int index_id = (long int) chain->value.intg; const char *const url = chain->name; if (index_id >= 0 && index_id <= indexes->index_size) { PT_Element item = PT_ReadCache(indexes->index[index_id], url, FETCH_HEADERS | FETCH_BODY); if (item != NULL) { int ret = callback(arg, url, item); PT_Element_Delete(&item); if (ret != 0) return ret; } } else { proxytrack_print_log(CRITICAL, "PT_ReadCache:Corrupted central index locator"); return -1; } } } return 0; } time_t PT_Index_Timestamp(PT_Index index) { return index->slots.common.timestamp; } static int PT_LookupCache__New(PT_Index index, const char *url) { int retCode; MutexLock(&index->slots.formatNew.zFileLock); { retCode = PT_LookupCache__New_u(index, url); } MutexUnlock(&index->slots.formatNew.zFileLock); return retCode; } static int PT_LookupCache__New_u(PT_Index index_, const char *url) { if (index_ != NULL) { PT_Index__New index = &index_->slots.formatNew; if (index->hash != NULL && index->zFile != NULL && url != NULL && *url != 0) { int hash_pos_return; if (strncmp(url, "http://", 7) == 0) url += 7; hash_pos_return = coucal_read(index->hash, url, NULL); if (hash_pos_return) return 1; } } return 0; } int PT_IndexMerge(PT_Indexes indexes, PT_Index * pindex) { if (pindex != NULL && *pindex != NULL && (*pindex)->slots.common.hash != NULL && indexes != NULL) { PT_Index index = *pindex; struct_coucal_enum en = coucal_enum_new(index->slots.common.hash); coucal_item *chain; int index_id = indexes->index_size++; int nMerged = 0; if ((indexes->index = realloc(indexes->index, sizeof(struct _PT_Index) * indexes->index_size)) != NULL) { indexes->index[index_id] = index; *pindex = NULL; while((chain = coucal_enum_next(&en)) != NULL) { const char *url = chain->name; if (url != NULL && url[0] != '\0') { intptr_t previous_index_id = 0; if (coucal_read(indexes->cil, url, &previous_index_id)) { if (previous_index_id >= 0 && previous_index_id < indexes->index_size) { if (indexes->index[previous_index_id]->slots.common.timestamp > index->slots.common.timestamp) // existing entry is newer break; } else { proxytrack_print_log(CRITICAL, "PT_IndexMerge:Corrupted central index locator"); } } coucal_write(indexes->cil, chain->name, index_id); nMerged++; } } } else { proxytrack_print_log(CRITICAL, "PT_IndexMerge:Memory exhausted"); } return nMerged; } return -1; } void PT_Element_Delete(PT_Element * pentry) { if (pentry != NULL) { PT_Element entry = *pentry; if (entry != NULL) { if (entry->adr != NULL) { free(entry->adr); entry->adr = NULL; } if (entry->headers != NULL) { free(entry->headers); entry->headers = NULL; } if (entry->location != NULL) { free(entry->location); entry->location = NULL; } free(entry); } *pentry = NULL; } } PT_Element PT_ReadIndex(PT_Indexes indexes, const char *url, int flags) { if (indexes != NULL) { intptr_t index_id; if (strncmp(url, "http://", 7) == 0) url += 7; if (coucal_read(indexes->cil, url, &index_id)) { if (index_id >= 0 && index_id <= indexes->index_size) { PT_Element item = PT_ReadCache(indexes->index[index_id], url, flags); if (item != NULL) { item->indexId = (int) index_id; return item; } } else { proxytrack_print_log(CRITICAL, "PT_ReadCache:Corrupted central index locator"); } } } return NULL; } int PT_LookupIndex(PT_Indexes indexes, const char *url) { if (indexes != NULL) { intptr_t index_id; if (strncmp(url, "http://", 7) == 0) url += 7; if (coucal_read(indexes->cil, url, &index_id)) { if (index_id >= 0 && index_id <= indexes->index_size) { return 1; } else { proxytrack_print_log(CRITICAL, "PT_ReadCache:Corrupted central index locator"); } } } return 0; } time_t PT_GetTimeIndex(PT_Indexes indexes) { if (indexes != NULL && indexes->index_size > 0) { int i; time_t maxt = indexes->index[0]->slots.common.timestamp; for(i = 1; i < indexes->index_size; i++) { const time_t currt = indexes->index[i]->slots.common.timestamp; if (currt > maxt) { maxt = currt; } } return maxt; } return (time_t) - 1; } PT_Index PT_GetIndex(PT_Indexes indexes, int indexId) { if (indexes != NULL && indexId >= 0 && indexId < indexes->index_size) { return indexes->index[indexId]; } return NULL; } PT_Element PT_ElementNew(void) { PT_Element r = NULL; if ((r = calloc(sizeof(_PT_Element), 1)) == NULL) return NULL; r->statuscode = STATUSCODE_INVALID; r->indexId = -1; return r; } PT_Element PT_ReadCache(PT_Index index, const char *url, int flags) { if (index != NULL && SAFE_INDEX(index)) { return _IndexFuncts[index->type].PT_ReadCache(index, url, flags); } return NULL; } static PT_Element PT_ReadCache__New(PT_Index index, const char *url, int flags) { PT_Element retCode; MutexLock(&index->slots.formatNew.zFileLock); { retCode = PT_ReadCache__New_u(index, url, flags); } MutexUnlock(&index->slots.formatNew.zFileLock); return retCode; } /* ------------------------------------------------------------ */ /* New HTTrack cache (new.zip) format */ /* ------------------------------------------------------------ */ #define ZIP_FIELD_STRING(headers, headersSize, field, value) do { \ if ( (value != NULL) && (value)[0] != '\0') { \ sprintf(headers + headersSize, "%s: %s\r\n", field, (value != NULL) ? (value) : ""); \ (headersSize) += (int) strlen(headers + headersSize); \ } \ } while(0) #define ZIP_FIELD_INT(headers, headersSize, field, value) do { \ if ( (value != 0) ) { \ sprintf(headers + headersSize, "%s: "LLintP"\r\n", field, (LLint)(value)); \ (headersSize) += (int) strlen(headers + headersSize); \ } \ } while(0) #define ZIP_FIELD_INT_FORCE(headers, headersSize, field, value) do { \ sprintf(headers + headersSize, "%s: "LLintP"\r\n", field, (LLint)(value)); \ (headersSize) += (int) strlen(headers + headersSize); \ } while(0) #define ZIP_READFIELD_STRING(line, value, refline, refvalue) do { \ if (line[0] != '\0' && strfield2(line, refline)) { \ strcpy(refvalue, value); \ line[0] = '\0'; \ } \ } while(0) #define ZIP_READFIELD_INT(line, value, refline, refvalue) do { \ if (line[0] != '\0' && strfield2(line, refline)) { \ int intval = 0; \ sscanf(value, "%d", &intval); \ (refvalue) = intval; \ line[0] = '\0'; \ } \ } while(0) int PT_LoadCache__New(PT_Index index_, const char *filename) { if (index_ != NULL && filename != NULL) { PT_Index__New index = &index_->slots.formatNew; unzFile zFile = index->zFile = unzOpen(filename); index->timestamp = file_timestamp(filename); MutexInit(&index->zFileLock); // Opened ? if (zFile != NULL) { const char *abpath; int slashes; coucal hashtable = index->hash; /* Compute base path for this index - the filename MUST be absolute! */ for(slashes = 2, abpath = filename + (int) strlen(filename) - 1; abpath > filename && ((*abpath != '/' && *abpath != '\\') || --slashes > 0); abpath--) ; index->path[0] = '\0'; if (slashes == 0 && *abpath != 0) { int i; strncat(index->path, filename, (int) (abpath - filename) + 1); for(i = 0; index->path[i] != 0; i++) { if (index->path[i] == '\\') { index->path[i] = '/'; } } } /* Ready directory entries */ if (unzGoToFirstFile(zFile) == Z_OK) { char comment[128]; char filename[HTS_URLMAXSIZE * 4]; int entries = 0; int firstSeen = 0; memset(comment, 0, sizeof(comment)); // for truncated reads do { int readSizeHeader = 0; filename[0] = '\0'; comment[0] = '\0'; if (unzOpenCurrentFile(zFile) == Z_OK) { if ((readSizeHeader = unzGetLocalExtrafield(zFile, comment, sizeof(comment) - 2)) > 0 && unzGetCurrentFileInfo(zFile, NULL, filename, sizeof(filename) - 2, NULL, 0, NULL, 0) == Z_OK) { long int pos = (long int) unzGetOffset(zFile); assertf(readSizeHeader < sizeof(comment)); comment[readSizeHeader] = '\0'; entries++; if (pos > 0) { int dataincache = 0; // data in cache ? char *filenameIndex = filename; if (strncmp(filenameIndex, "http://", 7) == 0) { filenameIndex += 7; } if (comment[0] != '\0') { int maxLine = 2; char *a = comment; while(*a && maxLine-- > 0) { // parse only few first lines char line[1024]; line[0] = '\0'; a += binput(a, line, sizeof(line) - 2); if (strncmp(line, "X-In-Cache:", 11) == 0) { if (strcmp(line, "X-In-Cache: 1") == 0) { dataincache = 1; } else { dataincache = 0; } break; } } } if (dataincache) coucal_add(hashtable, filenameIndex, pos); else coucal_add(hashtable, filenameIndex, -pos); /* First link as starting URL */ if (!firstSeen) { if (strstr(filenameIndex, "/robots.txt") == NULL) { firstSeen = 1; if (!link_has_authority(filenameIndex)) strcat(index->startUrl, "http://"); strcat(index->startUrl, filenameIndex); } } } else { fprintf(stderr, "Corrupted cache meta entry #%d" LF, (int) entries); } } else { fprintf(stderr, "Corrupted cache entry #%d" LF, (int) entries); } unzCloseCurrentFile(zFile); } else { fprintf(stderr, "Corrupted cache entry #%d" LF, (int) entries); } } while(unzGoToNextFile(zFile) == Z_OK); return 1; } else { coucal_delete(&index->hash); index = NULL; } } else { index = NULL; } } return 0; } static PT_Element PT_ReadCache__New_u(PT_Index index_, const char *url, int flags) { PT_Index__New index = (PT_Index__New) & index_->slots.formatNew; char location_default[HTS_URLMAXSIZE * 2]; char previous_save[HTS_URLMAXSIZE * 2]; char previous_save_[HTS_URLMAXSIZE * 2]; char catbuff[CATBUFF_SIZE]; intptr_t hash_pos; int hash_pos_return; PT_Element r = NULL; if (index == NULL || index->hash == NULL || index->zFile == NULL || url == NULL || *url == 0) return NULL; if ((r = PT_ElementNew()) == NULL) return NULL; location_default[0] = '\0'; previous_save[0] = previous_save_[0] = '\0'; memset(r, 0, sizeof(_PT_Element)); r->location = location_default; strcpy(r->location, ""); if (strncmp(url, "http://", 7) == 0) url += 7; hash_pos_return = coucal_read(index->hash, url, &hash_pos); if (hash_pos_return) { uLong posInZip; if (hash_pos > 0) { posInZip = (uLong) hash_pos; } else { posInZip = (uLong) - hash_pos; } if (unzSetOffset(index->zFile, posInZip) == Z_OK) { /* Read header (Max 8KiB) */ if (unzOpenCurrentFile(index->zFile) == Z_OK) { char headerBuff[8192 + 2]; int readSizeHeader; //int totalHeader = 0; int dataincache = 0; /* For BIG comments */ headerBuff[0] = headerBuff[sizeof(headerBuff) - 1] = headerBuff[sizeof(headerBuff) - 2] = headerBuff[sizeof(headerBuff) - 3] = '\0'; if ((readSizeHeader = unzGetLocalExtrafield(index->zFile, headerBuff, sizeof(headerBuff) - 2)) > 0) { int offset = 0; char line[HTS_URLMAXSIZE + 2]; int lineEof = 0; headerBuff[readSizeHeader] = '\0'; do { char *value; line[0] = '\0'; offset += binput(headerBuff + offset, line, sizeof(line) - 2); if (line[0] == '\0') { lineEof = 1; } value = strchr(line, ':'); if (value != NULL) { *value++ = '\0'; if (*value == ' ' || *value == '\t') value++; ZIP_READFIELD_INT(line, value, "X-In-Cache", dataincache); ZIP_READFIELD_INT(line, value, "X-Statuscode", r->statuscode); ZIP_READFIELD_STRING(line, value, "X-StatusMessage", r->msg); // msg ZIP_READFIELD_INT(line, value, "X-Size", r->size); // size ZIP_READFIELD_STRING(line, value, "Content-Type", r->contenttype); // contenttype ZIP_READFIELD_STRING(line, value, "X-Charset", r->charset); // contenttype ZIP_READFIELD_STRING(line, value, "Last-Modified", r->lastmodified); // last-modified ZIP_READFIELD_STRING(line, value, "Etag", r->etag); // Etag ZIP_READFIELD_STRING(line, value, "Location", r->location); // 'location' pour moved ZIP_READFIELD_STRING(line, value, "Content-Disposition", r->cdispo); // Content-disposition //ZIP_READFIELD_STRING(line, value, "X-Addr", ..); // Original address //ZIP_READFIELD_STRING(line, value, "X-Fil", ..); // Original URI filename ZIP_READFIELD_STRING(line, value, "X-Save", previous_save_); // Original save filename if (line[0] != '\0') { int len = r->headers ? ((int) strlen(r->headers)) : 0; int nlen = (int) (strlen(line) + 2 + strlen(value) + sizeof("\r\n") + 1); r->headers = realloc(r->headers, len + nlen); r->headers[len] = '\0'; strcat(r->headers, line); strcat(r->headers, ": "); strcat(r->headers, value); strcat(r->headers, "\r\n"); } } } while(offset < readSizeHeader && !lineEof); //totalHeader = offset; /* Previous entry */ if (previous_save_[0] != '\0') { int pathLen = (int) strlen(index->path); if (pathLen > 0 && strncmp(previous_save_, index->path, pathLen) == 0) { // old (<3.40) buggy format strcpy(previous_save, previous_save_); } // relative ? (hack) else if (index->safeCache || (previous_save_[0] != '/' // /home/foo/bar.gif && (!isalpha(previous_save_[0]) || previous_save_[1] != ':')) // c:/home/foo/bar.gif ) { index->safeCache = 1; sprintf(previous_save, "%s%s", index->path, previous_save_); } // bogus format (includes buggy absolute path) else { /* guess previous path */ if (index->fixedPath == 0) { const char *start = jump_protocol_and_auth(url); const char *end = start ? strchr(start, '/') : NULL; int len = (int) (end - start); if (start != NULL && end != NULL && len > 0 && len < 128) { char piece[128 + 2]; const char *where; piece[0] = '\0'; strncat(piece, start, len); if ((where = strstr(previous_save_, piece)) != NULL) { index->fixedPath = (int) (where - previous_save_); // offset to relative path } } } if (index->fixedPath > 0) { int saveLen = (int) strlen(previous_save_); if (index->fixedPath < saveLen) { sprintf(previous_save, "%s%s", index->path, previous_save_ + index->fixedPath); } else { snprintf(r->msg, sizeof(r->msg), "Bogus fixePath prefix for %s (prefixLen=%d)", previous_save_, (int) index->fixedPath); r->statuscode = STATUSCODE_INVALID; } } else { sprintf(previous_save, "%s%s", index->path, previous_save_); } } } /* Complete fields */ r->adr = NULL; if (r->statuscode != STATUSCODE_INVALID) { /* Can continue */ int ok = 0; // Court-circuit: // Peut-on stocker le fichier directement sur disque? if (ok) { if (r->msg[0] == '\0') { strcpy(r->msg, "Cache Read Error : Unexpected error"); } } else { // lire en mémoire if (!dataincache) { /* Read in memory from cache */ if (flags & FETCH_BODY) { if (strnotempty(previous_save)) { FILE *fp = fopen(file_convert(catbuff, sizeof(catbuff), previous_save), "rb"); if (fp != NULL) { r->adr = (char *) malloc(r->size + 4); if (r->adr != NULL) { if (r->size > 0 && fread(r->adr, 1, r->size, fp) != r->size) { int last_errno = errno; r->statuscode = STATUSCODE_INVALID; sprintf(r->msg, "Read error in cache disk data: %s", strerror(last_errno)); } } else { r->statuscode = STATUSCODE_INVALID; strcpy(r->msg, "Read error (memory exhausted) from cache"); } fclose(fp); } else { r->statuscode = STATUSCODE_INVALID; snprintf(r->msg, sizeof(r->msg), "Read error (can't open '%s') from cache", file_convert(catbuff, sizeof(catbuff), previous_save)); } } else { r->statuscode = STATUSCODE_INVALID; strcpy(r->msg, "Cached file name is invalid"); } } } else { // lire fichier (d'un coup) if (flags & FETCH_BODY) { r->adr = (char *) malloc(r->size + 1); if (r->adr != NULL) { if (unzReadCurrentFile(index->zFile, r->adr, (unsigned int) r->size) != r->size) { // erreur free(r->adr); r->adr = NULL; r->statuscode = STATUSCODE_INVALID; strcpy(r->msg, "Cache Read Error : Read Data"); } else *(r->adr + r->size) = '\0'; //printf(">%s status %d\n",back[p].r->contenttype,back[p].r->statuscode); } else { // erreur r->statuscode = STATUSCODE_INVALID; strcpy(r->msg, "Cache Memory Error"); } } } } } // si save==null, ne rien charger (juste en tête) } else { r->statuscode = STATUSCODE_INVALID; strcpy(r->msg, "Cache Read Error : Read Header Data"); } unzCloseCurrentFile(index->zFile); } else { r->statuscode = STATUSCODE_INVALID; strcpy(r->msg, "Cache Read Error : Open File"); } } else { r->statuscode = STATUSCODE_INVALID; strcpy(r->msg, "Cache Read Error : Bad Offset"); } } else { r->statuscode = STATUSCODE_INVALID; strcpy(r->msg, "File Cache Entry Not Found"); } if (r->location[0] != '\0') { r->location = strdup(r->location); } else { r->location = NULL; } return r; } static int PT_SaveCache__New_Fun(void *arg, const char *url, PT_Element element) { zipFile zFileOut = (zipFile) arg; char headers[8192]; int headersSize; zip_fileinfo fi; int zErr; const char *url_adr = ""; const char *url_fil = ""; headers[0] = '\0'; headersSize = 0; /* Fields */ headers[0] = '\0'; headersSize = 0; /* */ { const char *message; if (strlen(element->msg) < 32) { message = element->msg; } else { message = "(See X-StatusMessage)"; } /* 64 characters MAX for first line */ sprintf(headers + headersSize, "HTTP/1.%c %d %s\r\n", '1', element->statuscode, message); } headersSize += (int) strlen(headers + headersSize); /* Second line MUST ALWAYS be X-In-Cache */ ZIP_FIELD_INT_FORCE(headers, headersSize, "X-In-Cache", 1); ZIP_FIELD_INT(headers, headersSize, "X-StatusCode", element->statuscode); ZIP_FIELD_STRING(headers, headersSize, "X-StatusMessage", element->msg); ZIP_FIELD_INT(headers, headersSize, "X-Size", element->size); // size ZIP_FIELD_STRING(headers, headersSize, "Content-Type", element->contenttype); // contenttype ZIP_FIELD_STRING(headers, headersSize, "X-Charset", element->charset); // contenttype ZIP_FIELD_STRING(headers, headersSize, "Last-Modified", element->lastmodified); // last-modified ZIP_FIELD_STRING(headers, headersSize, "Etag", element->etag); // Etag ZIP_FIELD_STRING(headers, headersSize, "Location", element->location); // 'location' pour moved ZIP_FIELD_STRING(headers, headersSize, "Content-Disposition", element->cdispo); // Content-disposition ZIP_FIELD_STRING(headers, headersSize, "X-Addr", url_adr); // Original address ZIP_FIELD_STRING(headers, headersSize, "X-Fil", url_fil); // Original URI filename ZIP_FIELD_STRING(headers, headersSize, "X-Save", ""); // Original save filename /* Time */ memset(&fi, 0, sizeof(fi)); if (element->lastmodified[0] != '\0') { struct tm buffer; struct tm *tm_s = convert_time_rfc822(&buffer, element->lastmodified); if (tm_s) { fi.tmz_date.tm_sec = (uInt) tm_s->tm_sec; fi.tmz_date.tm_min = (uInt) tm_s->tm_min; fi.tmz_date.tm_hour = (uInt) tm_s->tm_hour; fi.tmz_date.tm_mday = (uInt) tm_s->tm_mday; fi.tmz_date.tm_mon = (uInt) tm_s->tm_mon; fi.tmz_date.tm_year = (uInt) tm_s->tm_year; } } /* Open file - NOTE: headers in "comment" */ if ((zErr = zipOpenNewFileInZip(zFileOut, url, &fi, /* Store headers in realtime in the local file directory as extra field In case of crash, we'll be able to recover the whole ZIP file by rescanning it */ headers, (uInt) strlen(headers), NULL, 0, NULL, /* comment */ Z_DEFLATED, Z_DEFAULT_COMPRESSION)) != Z_OK) { assertf(! "zip_zipOpenNewFileInZip_failed"); } /* Write data in cache */ if (element->size > 0 && element->adr != NULL) { if ((zErr = zipWriteInFileInZip(zFileOut, element->adr, (int) element->size)) != Z_OK) { assertf(! "zip_zipWriteInFileInZip_failed"); } } /* Close */ if ((zErr = zipCloseFileInZip(zFileOut)) != Z_OK) { assertf(! "zip_zipCloseFileInZip_failed"); } /* Flush */ if ((zErr = zipFlush(zFileOut)) != 0) { assertf(! "zip_zipFlush_failed"); } return 0; } static int PT_SaveCache__New(PT_Indexes indexes, const char *filename) { zipFile zFileOut = zipOpen(filename, 0); if (zFileOut != NULL) { int ret = PT_EnumCache(indexes, PT_SaveCache__New_Fun, (void *) zFileOut); zipClose(zFileOut, "Created by HTTrack Website Copier/ProxyTrack " PROXYTRACK_VERSION); zFileOut = NULL; if (ret != 0) (void) unlink(filename); return ret; } return -1; } /* ------------------------------------------------------------ */ /* Old HTTrack cache (dat/ndx) format */ /* ------------------------------------------------------------ */ static int cache_brstr(char *adr, char *s) { int i; int off; char buff[256 + 1]; off = binput(adr, buff, 256); adr += off; sscanf(buff, "%d", &i); if (i > 0) strncpy(s, adr, i); *(s + i) = '\0'; off += i; return off; } static void cache_rstr(FILE * fp, char *s) { INTsys i; char buff[256 + 4]; linput(fp, buff, 256); sscanf(buff, INTsysP, &i); if (i < 0 || i > 32768) /* error, something nasty happened */ i = 0; if (i > 0) { if ((int) fread(s, 1, i, fp) != i) { assertf(! "fread_cache_failed"); } } *(s + i) = '\0'; } static char *cache_rstr_addr(FILE * fp) { INTsys i; char *addr = NULL; char buff[256 + 4]; linput(fp, buff, 256); sscanf(buff, "%d", &i); if (i < 0 || i > 32768) /* error, something nasty happened */ i = 0; if (i > 0) { addr = malloc(i + 1); if (addr != NULL) { if ((int) fread(addr, 1, i, fp) != i) { assertf(! "fread_cache_failed"); } *(addr + i) = '\0'; } } return addr; } static void cache_rint(FILE * fp, int *i) { char s[256]; cache_rstr(fp, s); sscanf(s, "%d", i); } static void cache_rLLint(FILE * fp, unsigned long *i) { int l; char s[256]; cache_rstr(fp, s); sscanf(s, "%d", &l); *i = (unsigned long) l; } static int PT_LoadCache__Old(PT_Index index_, const char *filename) { if (index_ != NULL && filename != NULL) { char *pos = strrchr(filename, '.'); PT_Index__Old cache = &index_->slots.formatOld; long int ndxSize; cache->filenameDat[0] = '\0'; cache->filenameNdx[0] = '\0'; cache->path[0] = '\0'; { PT_Index__Old index = cache; const char *abpath; int slashes; /* -------------------- COPY OF THE __New() CODE -------------------- */ /* Compute base path for this index - the filename MUST be absolute! */ for(slashes = 2, abpath = filename + (int) strlen(filename) - 1; abpath > filename && ((*abpath != '/' && *abpath != '\\') || --slashes > 0); abpath--) ; index->path[0] = '\0'; if (slashes == 0 && *abpath != 0) { int i; strncat(index->path, filename, (int) (abpath - filename) + 1); for(i = 0; index->path[i] != 0; i++) { if (index->path[i] == '\\') { index->path[i] = '/'; } } } /* -------------------- END OF COPY OF THE __New() CODE -------------------- */ } /* Index/data filenames */ if (pos != NULL) { int nLen = (int) (pos - filename); strncat(cache->filenameDat, filename, nLen); strncat(cache->filenameNdx, filename, nLen); strcat(cache->filenameDat, ".dat"); strcat(cache->filenameNdx, ".ndx"); } ndxSize = filesize(cache->filenameNdx); cache->timestamp = file_timestamp(cache->filenameDat); cache->dat = fopen(cache->filenameDat, "rb"); cache->ndx = fopen(cache->filenameNdx, "rb"); if (cache->dat != NULL && cache->ndx != NULL && ndxSize > 0) { char *use = malloc(ndxSize + 1); if (fread(use, 1, ndxSize, cache->ndx) == ndxSize) { char firstline[256]; char *a = use; use[ndxSize] = '\0'; a += cache_brstr(a, firstline); if (strncmp(firstline, "CACHE-", 6) == 0) { // Nouvelle version du cache if (strncmp(firstline, "CACHE-1.", 8) == 0) { // Version 1.1x cache->version = (int) (firstline[8] - '0'); // cache 1.x if (cache->version <= 5) { a += cache_brstr(a, firstline); strcpy(cache->lastmodified, firstline); } else { // fprintf(opt->errlog,"Cache: version 1.%d not supported, ignoring current cache"LF,cache->version); fclose(cache->dat); cache->dat = NULL; free(use); use = NULL; } } else { // non supporté // fspc(opt->errlog,"error"); fprintf(opt->errlog,"Cache: %s not supported, ignoring current cache"LF,firstline); fclose(cache->dat); cache->dat = NULL; free(use); use = NULL; } /* */ } else { // Vieille version du cache /* */ // hts_log_print(opt, LOG_WARNING, "Cache: importing old cache format"); cache->version = 0; // cache 1.0 strcpy(cache->lastmodified, firstline); } /* Create hash table for the cache (MUCH FASTER!) */ if (use) { char line[HTS_URLMAXSIZE * 2]; char linepos[256]; int pos; int firstSeen = 0; while((a != NULL) && (a < (use + ndxSize))) { a = strchr(a + 1, '\n'); /* start of line */ if (a) { a++; /* read "host/file" */ a += binput(a, line, HTS_URLMAXSIZE); a += binput(a, line + strlen(line), HTS_URLMAXSIZE); /* read position */ a += binput(a, linepos, 200); sscanf(linepos, "%d", &pos); /* Add entry */ coucal_add(cache->hash, line, pos); /* First link as starting URL */ if (!firstSeen) { if (strstr(line, "/robots.txt") == NULL) { PT_Index__Old index = cache; firstSeen = 1; if (!link_has_authority(line)) strcat(index->startUrl, "http://"); strcat(index->startUrl, line); } } } } /* Not needed anymore! */ free(use); use = NULL; return 1; } } } } return 0; } static String DecodeUrl(const char *url) { int i; String s = STRING_EMPTY; StringClear(s); for(i = 0; url[i] != '\0'; i++) { if (url[i] == '+') { StringAddchar(s, ' '); } else if (url[i] == '%') { if (url[i + 1] == '%') { StringAddchar(s, '%'); i++; } else if (url[i + 1] != 0 && url[i + 2] != 0) { char tmp[3]; int codepoint = 0; tmp[0] = url[i + 1]; tmp[1] = url[i + 2]; tmp[2] = 0; if (sscanf(tmp, "%x", &codepoint) == 1) { StringAddchar(s, (char) codepoint); } i += 2; } } else { StringAddchar(s, url[i]); } } return s; } static PT_Element PT_ReadCache__Old(PT_Index index, const char *url, int flags) { PT_Element retCode; MutexLock(&index->slots.formatOld.fileLock); { retCode = PT_ReadCache__Old_u(index, url, flags); } MutexUnlock(&index->slots.formatOld.fileLock); return retCode; } static PT_Element PT_ReadCache__Old_u(PT_Index index_, const char *url, int flags) { PT_Index__Old cache = (PT_Index__Old) & index_->slots.formatOld; intptr_t hash_pos; int hash_pos_return; char location_default[HTS_URLMAXSIZE * 2]; char previous_save[HTS_URLMAXSIZE * 2]; char previous_save_[HTS_URLMAXSIZE * 2]; PT_Element r; int ok = 0; if (cache == NULL || cache->hash == NULL || url == NULL || *url == 0) return NULL; if ((r = PT_ElementNew()) == NULL) return NULL; location_default[0] = '\0'; previous_save[0] = previous_save_[0] = '\0'; memset(r, 0, sizeof(_PT_Element)); r->location = location_default; strcpy(r->location, ""); if (strncmp(url, "http://", 7) == 0) url += 7; hash_pos_return = coucal_read(cache->hash, url, &hash_pos); if (hash_pos_return) { int pos = (int) hash_pos; /* simply */ if (fseek(cache->dat, (pos > 0) ? pos : (-pos), SEEK_SET) == 0) { /* Importer cache1.0 */ if (cache->version == 0) { OLD_htsblk old_r; if (fread((char *) &old_r, 1, sizeof(old_r), cache->dat) == sizeof(old_r)) { // lire tout (y compris statuscode etc) int i; String urlDecoded; r->statuscode = old_r.statuscode; r->size = old_r.size; // taille fichier strcpy(r->msg, old_r.msg); strcpy(r->contenttype, old_r.contenttype); /* Guess the destination filename.. this sucks, because this method is not reliable. Yes, the old 1.0 cache format was *that* bogus. /rx */ #define FORBIDDEN_CHAR(c) (c == '~' \ || c == '\\' \ || c == ':' \ || c == '*' \ || c == '?' \ || c == '\"' \ || c == '<' \ || c == '>' \ || c == '|' \ || c == '@' \ || ((unsigned char) c ) <= 31 \ || ((unsigned char) c ) == 127 \ ) urlDecoded = DecodeUrl(jump_protocol_and_auth(url)); strcpy(previous_save_, StringBuff(urlDecoded)); StringFree(urlDecoded); for(i = 0; previous_save_[i] != '\0' && previous_save_[i] != '?'; i++) { if (FORBIDDEN_CHAR(previous_save_[i])) { previous_save_[i] = '_'; } } previous_save_[i] = '\0'; #undef FORBIDDEN_CHAR ok = 1; /* import ok */ } /* */ /* Cache 1.1 */ } else { char check[256]; unsigned long size_read; unsigned long int size_; check[0] = '\0'; // cache_rint(cache->dat, &r->statuscode); cache_rLLint(cache->dat, &size_); r->size = (size_t) size_; cache_rstr(cache->dat, r->msg); cache_rstr(cache->dat, r->contenttype); if (cache->version >= 3) cache_rstr(cache->dat, r->charset); cache_rstr(cache->dat, r->lastmodified); cache_rstr(cache->dat, r->etag); cache_rstr(cache->dat, r->location); if (cache->version >= 2) cache_rstr(cache->dat, r->cdispo); if (cache->version >= 4) { cache_rstr(cache->dat, previous_save_); // adr cache_rstr(cache->dat, previous_save_); // fil previous_save[0] = '\0'; cache_rstr(cache->dat, previous_save_); // save } if (cache->version >= 5) { r->headers = cache_rstr_addr(cache->dat); } // cache_rstr(cache->dat, check); if (strcmp(check, "HTS") == 0) { /* intégrité OK */ ok = 1; } cache_rLLint(cache->dat, &size_read); /* lire size pour être sûr de la taille déclarée (réécrire) */ if (size_read > 0) { /* si inscrite ici */ r->size = size_read; } else { /* pas de données directement dans le cache, fichier présent? */ r->size = 0; } } /* Check destination filename */ { PT_Index__Old index = cache; /* -------------------- COPY OF THE __New() CODE -------------------- */ if (previous_save_[0] != '\0') { int pathLen = (int) strlen(index->path); if (pathLen > 0 && strncmp(previous_save_, index->path, pathLen) == 0) { // old (<3.40) buggy format strcpy(previous_save, previous_save_); } // relative ? (hack) else if (index->safeCache || (previous_save_[0] != '/' // /home/foo/bar.gif && (!isalpha(previous_save_[0]) || previous_save_[1] != ':')) // c:/home/foo/bar.gif ) { index->safeCache = 1; sprintf(previous_save, "%s%s", index->path, previous_save_); } // bogus format (includes buggy absolute path) else { /* guess previous path */ if (index->fixedPath == 0) { const char *start = jump_protocol_and_auth(url); const char *end = start ? strchr(start, '/') : NULL; int len = (int) (end - start); if (start != NULL && end != NULL && len > 0 && len < 128) { char piece[128 + 2]; const char *where; piece[0] = '\0'; strncat(piece, start, len); if ((where = strstr(previous_save_, piece)) != NULL) { index->fixedPath = (int) (where - previous_save_); // offset to relative path } } } if (index->fixedPath > 0) { int saveLen = (int) strlen(previous_save_); if (index->fixedPath < saveLen) { sprintf(previous_save, "%s%s", index->path, previous_save_ + index->fixedPath); } else { snprintf(r->msg, sizeof(r->msg), "Bogus fixePath prefix for %s (prefixLen=%d)", previous_save_, (int) index->fixedPath); r->statuscode = STATUSCODE_INVALID; } } else { sprintf(previous_save, "%s%s", index->path, previous_save_); } } } /* -------------------- END OF COPY OF THE __New() CODE -------------------- */ } /* Read data */ if (ok) { r->adr = NULL; if ((r->statuscode >= 0) && (r->statuscode <= 999)) { r->adr = NULL; if (pos < 0) { if (flags & FETCH_BODY) { FILE *fp = fopen(previous_save, "rb"); if (fp != NULL) { r->adr = (char *) malloc(r->size + 1); if (r->adr != NULL) { if (r->size > 0 && fread(r->adr, 1, r->size, fp) != r->size) { r->statuscode = STATUSCODE_INVALID; strcpy(r->msg, "Read error in cache disk data"); } r->adr[r->size] = '\0'; } else { r->statuscode = STATUSCODE_INVALID; strcpy(r->msg, "Read error (memory exhausted) from cache"); } fclose(fp); } else { r->statuscode = STATUSCODE_INVALID; strcpy(r->msg, "Previous cache file not found (2)"); } } } else { // lire fichier (d'un coup) if (flags & FETCH_BODY) { r->adr = (char *) malloc(r->size + 1); if (r->adr != NULL) { if (fread(r->adr, 1, r->size, cache->dat) != r->size) { // erreur free(r->adr); r->adr = NULL; r->statuscode = STATUSCODE_INVALID; strcpy(r->msg, "Cache Read Error : Read Data"); } else r->adr[r->size] = '\0'; } else { // erreur r->statuscode = STATUSCODE_INVALID; strcpy(r->msg, "Cache Memory Error"); } } } } else { r->statuscode = STATUSCODE_INVALID; strcpy(r->msg, "Cache Read Error : Bad Data"); } } else { // erreur r->statuscode = STATUSCODE_INVALID; strcpy(r->msg, "Cache Read Error : Read Header"); } } else { r->statuscode = STATUSCODE_INVALID; strcpy(r->msg, "Cache Read Error : Seek Failed"); } } else { r->statuscode = STATUSCODE_INVALID; strcpy(r->msg, "File Cache Entry Not Found"); } if (r->location[0] != '\0') { r->location = strdup(r->location); } else { r->location = NULL; } return r; } static int PT_LookupCache__Old(PT_Index index, const char *url) { int retCode; MutexLock(&index->slots.formatOld.fileLock); { retCode = PT_LookupCache__Old_u(index, url); } MutexUnlock(&index->slots.formatOld.fileLock); return retCode; } static int PT_LookupCache__Old_u(PT_Index index_, const char *url) { if (index_ != NULL) { PT_Index__New cache = (PT_Index__New) & index_->slots.formatNew; if (cache == NULL || cache->hash == NULL || url == NULL || *url == 0) return 0; if (strncmp(url, "http://", 7) == 0) url += 7; if (coucal_read(cache->hash, url, NULL)) return 1; } return 0; } /* ------------------------------------------------------------ */ /* Internet Archive Arc 1.0 (arc) format */ /* Xavier Roche (roche@httrack.com) */ /* Lars Clausen (lc@statsbiblioteket.dk) */ /* ------------------------------------------------------------ */ #define ARC_SP ' ' static const char *getArcField(const char *line, int pos) { int i; for(i = 0; line[i] != '\0' && pos > 0; i++) { if (line[i] == ARC_SP) pos--; } if (pos == 0) return &line[i]; return NULL; } static char *copyArcField(const char *line, int npos, char *dest, int destMax) { const char *pos; if ((pos = getArcField(line, npos)) != NULL) { int i; for(i = 0; pos[i] != '\0' && pos[i] != ARC_SP && (--destMax) > 0; i++) { dest[i] = pos[i]; } dest[i] = 0; return dest; } dest[0] = 0; return NULL; } static int getArcLength(const char *line) { const char *pos; if ((pos = getArcField(line, 9)) != NULL || (pos = getArcField(line, 4)) != NULL || (pos = getArcField(line, 2)) != NULL) { int length; if (sscanf(pos, "%d", &length) == 1) { return length; } } return -1; } static int skipArcNl(FILE * file) { if (fgetc(file) == 0x0a) { return 0; } return -1; } static int skipArcData(FILE * file, const char *line) { int jump = getArcLength(line); if (jump != -1) { if (fseek(file, jump, SEEK_CUR) == 0 /* && skipArcNl(file) == 0 */ ) { return 0; } } return -1; } static int getDigit(const char digit) { return (int) (digit - '0'); } static int getDigit2(const char *const pos) { return getDigit(pos[0]) * 10 + getDigit(pos[1]); } static int getDigit4(const char *const pos) { return getDigit(pos[0]) * 1000 + getDigit(pos[1]) * 100 + getDigit(pos[2]) * 10 + getDigit(pos[3]); } static time_t getGMT(struct tm *tm) { /* hey, time_t is local! */ time_t t = mktime(tm); if (t != (time_t) - 1 && t != (time_t) 0) { /* BSD does not have static "timezone" declared */ #if (defined(BSD) || defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__FreeBSD_kernel__)) time_t now = time(NULL); time_t timezone = -localtime(&now)->tm_gmtoff; #endif return (time_t) (t - timezone); } return (time_t) - 1; } static time_t getArcTimestamp(const char *const line) { const char *pos; if ((pos = getArcField(line, 2)) != NULL) { int i; /* date == YYYYMMDDhhmmss (Greenwich Mean Time) */ /* example: 20050405154029 */ for(i = 0; pos[i] >= '0' && pos[i] <= '9'; i++) ; if (i == 14) { struct tm tm; memset(&tm, 0, sizeof(tm)); tm.tm_year = getDigit4(pos + 0) - 1900; /* current year minus 1900 */ tm.tm_mon = getDigit2(pos + 4) - 1; /* 0 – 11 */ tm.tm_mday = getDigit2(pos + 6); /* 1 – 31 */ tm.tm_hour = getDigit2(pos + 8); /* 0 – 23 */ tm.tm_min = getDigit2(pos + 10); /* 0 – 59 */ tm.tm_sec = getDigit2(pos + 12); /* 0 – 59 */ tm.tm_isdst = 0; return getGMT(&tm); } } return (time_t) - 1; } static int readArcURLRecord(PT_Index__Arc index) { index->line[0] = '\0'; if (linput(index->file, index->line, sizeof(index->line) - 1)) { return 0; } return -1; } #define str_begins(str, sstr) ( strncmp(str, sstr, sizeof(sstr) - 1) == 0 ) static int PT_CompatibleScheme(const char *url) { return (str_begins(url, "http:") || str_begins(url, "https:") || str_begins(url, "ftp:") || str_begins(url, "file:")); } int PT_LoadCache__Arc(PT_Index index_, const char *filename) { if (index_ != NULL && filename != NULL) { PT_Index__Arc index = &index_->slots.formatArc; index->timestamp = file_timestamp(filename); MutexInit(&index->fileLock); index->file = fopen(filename, "rb"); // Opened ? if (index->file != NULL) { coucal hashtable = index->hash; if (readArcURLRecord(index) == 0) { int entries = 0; /* Read first line */ if (strncmp(index->line, "filedesc://", sizeof("filedesc://") - 1) != 0) { fprintf(stderr, "Unexpected bad signature #%s" LF, index->line); fclose(index->file); index->file = NULL; return 0; } /* Timestamp */ index->timestamp = getArcTimestamp(index->line); /* Skip first entry */ if (skipArcData(index->file, index->line) != 0 || skipArcNl(index->file) != 0) { fprintf(stderr, "Unexpected bad data offset size first entry" LF); fclose(index->file); index->file = NULL; return 0; } /* Read all meta-entries (not data) */ while(!feof(index->file)) { unsigned long int fpos = ftell(index->file); if (skipArcNl(index->file) == 0 && readArcURLRecord(index) == 0) { int length = getArcLength(index->line); if (length >= 0) { const char *filenameIndex = copyArcField(index->line, 0, index->filenameIndexBuff, sizeof(index->filenameIndexBuff) - 1); /* can not be NULL */ if (strncmp(filenameIndex, "http://", 7) == 0) { filenameIndex += 7; } if (*filenameIndex != 0) { if (skipArcData(index->file, index->line) != 0) { fprintf(stderr, "Corrupted cache data entry #%d (truncated file?), aborting read" LF, (int) entries); } /*fprintf(stdout, "adding %s [%d]\n", filenameIndex, (int)fpos); */ if (PT_CompatibleScheme(index->filenameIndexBuff)) { coucal_add(hashtable, filenameIndex, fpos); /* position of meta-data */ entries++; } } else { fprintf(stderr, "Corrupted cache meta entry #%d" LF, (int) entries); } } else { fprintf(stderr, "Corrupted cache meta entry #%d, aborting read" LF, (int) entries); break; } } else { break; } } /* OK */ return 1; } else { fprintf(stderr, "Bad file (empty ?)" LF); } } else { fprintf(stderr, "Unable to open file" LF); index = NULL; } } else { fprintf(stderr, "Bad arguments" LF); } return 0; } #define HTTP_READFIELD_STRING(line, value, refline, refvalue) do { \ if (line[0] != '\0' && strfield2(line, refline)) { \ strcpy(refvalue, value); \ line[0] = '\0'; \ } \ } while(0) #define HTTP_READFIELD_INT(line, value, refline, refvalue) do { \ if (line[0] != '\0' && strfield2(line, refline)) { \ int intval = 0; \ sscanf(value, "%d", &intval); \ (refvalue) = intval; \ line[0] = '\0'; \ } \ } while(0) static PT_Element PT_ReadCache__Arc(PT_Index index, const char *url, int flags) { PT_Element retCode; MutexLock(&index->slots.formatArc.fileLock); { retCode = PT_ReadCache__Arc_u(index, url, flags); } MutexUnlock(&index->slots.formatArc.fileLock); return retCode; } static PT_Element PT_ReadCache__Arc_u(PT_Index index_, const char *url, int flags) { PT_Index__Arc index = (PT_Index__Arc) & index_->slots.formatArc; char location_default[HTS_URLMAXSIZE * 2]; intptr_t hash_pos; int hash_pos_return; PT_Element r = NULL; if (index == NULL || index->hash == NULL || url == NULL || *url == 0) return NULL; if ((r = PT_ElementNew()) == NULL) return NULL; location_default[0] = '\0'; memset(r, 0, sizeof(_PT_Element)); r->location = location_default; strcpy(r->location, ""); if (strncmp(url, "http://", 7) == 0) url += 7; hash_pos_return = coucal_read(index->hash, url, &hash_pos); if (hash_pos_return) { if (fseek(index->file, (long) hash_pos, SEEK_SET) == 0) { if (skipArcNl(index->file) == 0 && readArcURLRecord(index) == 0) { long int fposMeta = ftell(index->file); int dataLength = getArcLength(index->line); const char *pos; /* Read HTTP headers */ /* HTTP/1.1 404 Not Found */ if (linput(index->file, index->line, sizeof(index->line) - 1)) { if ((pos = getArcField(index->line, 1)) != NULL) { if (sscanf(pos, "%d", &r->statuscode) != 1) { r->statuscode = STATUSCODE_INVALID; } } if ((pos = getArcField(index->line, 2)) != NULL) { r->msg[0] = '\0'; strncat(r->msg, pos, sizeof(pos) - 1); } while(linput(index->file, index->line, sizeof(index->line) - 1) && index->line[0] != '\0') { char *const line = index->line; char *value = strchr(line, ':'); if (value != NULL) { *value = '\0'; for(value++; *value == ' ' || *value == '\t'; value++) ; HTTP_READFIELD_INT(line, value, "Content-Length", r->size); // size HTTP_READFIELD_STRING(line, value, "Content-Type", r->contenttype); // contenttype HTTP_READFIELD_STRING(line, value, "Last-Modified", r->lastmodified); // last-modified HTTP_READFIELD_STRING(line, value, "Etag", r->etag); // Etag HTTP_READFIELD_STRING(line, value, "Location", r->location); // 'location' pour moved HTTP_READFIELD_STRING(line, value, "Content-Disposition", r->cdispo); // Content-disposition if (line[0] != '\0') { int len = r->headers ? ((int) strlen(r->headers)) : 0; int nlen = (int) (strlen(line) + 2 + strlen(value) + sizeof("\r\n") + 1); r->headers = realloc(r->headers, len + nlen); r->headers[len] = '\0'; strcat(r->headers, line); strcat(r->headers, ": "); strcat(r->headers, value); strcat(r->headers, "\r\n"); } } } /* FIXME charset */ if (r->contenttype[0] != '\0') { char *pos = strchr(r->contenttype, ';'); if (pos != NULL) { /*char *chs = strchr(pos, "charset="); */ /*HTTP_READFIELD_STRING(line, value, "X-Charset", r->charset); */ *pos = 0; if ((pos = strchr(r->contenttype, ' ')) != NULL) { *pos = 0; } } } /* Read data */ if (r->statuscode != STATUSCODE_INVALID) { /* Can continue */ if (flags & FETCH_BODY) { long int fposCurrent = ftell(index->file); long int metaSize = fposCurrent - fposMeta; long int fetchSize = (long int) r->size; if (fetchSize <= 0) { fetchSize = dataLength - metaSize; } else if (fetchSize > dataLength - metaSize) { r->statuscode = STATUSCODE_INVALID; strcpy(r->msg, "Cache Read Error : Truncated Data"); } r->size = 0; if (r->statuscode != STATUSCODE_INVALID) { r->adr = (char *) malloc(fetchSize); if (r->adr != NULL) { if (fetchSize > 0 && (r->size = (int) fread(r->adr, 1, fetchSize, index->file)) != fetchSize) { int last_errno = errno; r->statuscode = STATUSCODE_INVALID; sprintf(r->msg, "Read error in cache disk data: %s", strerror(last_errno)); } } else { r->statuscode = STATUSCODE_INVALID; strcpy(r->msg, "Read error (memory exhausted) from cache"); } } } } } else { r->statuscode = STATUSCODE_INVALID; strcpy(r->msg, "Cache Read Error : Read Header Error"); } } else { r->statuscode = STATUSCODE_INVALID; strcpy(r->msg, "Cache Read Error : Read Header Error"); } } else { r->statuscode = STATUSCODE_INVALID; strcpy(r->msg, "Cache Read Error : Seek Error"); } } else { r->statuscode = STATUSCODE_INVALID; strcpy(r->msg, "File Cache Entry Not Found"); } if (r->location[0] != '\0') { r->location = strdup(r->location); } else { r->location = NULL; } return r; } static int PT_LookupCache__Arc(PT_Index index, const char *url) { int retCode; MutexLock(&index->slots.formatArc.fileLock); { retCode = PT_LookupCache__Arc_u(index, url); } MutexUnlock(&index->slots.formatArc.fileLock); return retCode; } static int PT_LookupCache__Arc_u(PT_Index index_, const char *url) { if (index_ != NULL) { PT_Index__New cache = (PT_Index__New) & index_->slots.formatNew; if (cache == NULL || cache->hash == NULL || url == NULL || *url == 0) return 0; if (strncmp(url, "http://", 7) == 0) url += 7; if (coucal_read(cache->hash, url, NULL)) return 1; } return 0; } typedef struct PT_SaveCache__Arc_t { PT_Indexes indexes; FILE *fp; time_t t; char filename[64]; struct tm buff; char headers[8192]; char md5[32 + 2]; } PT_SaveCache__Arc_t; static int PT_SaveCache__Arc_Fun(void *arg, const char *url, PT_Element element) { PT_SaveCache__Arc_t *st = (PT_SaveCache__Arc_t *) arg; FILE *const fp = st->fp; struct tm *tm = convert_time_rfc822(&st->buff, element->lastmodified); int size_headers; sprintf(st->headers, "HTTP/1.0 %d %s" "\r\n" "X-Server: ProxyTrack " PROXYTRACK_VERSION "\r\n" "Content-type: %s%s%s%s" "\r\n" "Last-modified: %s" "\r\n" "Content-length: %d" "\r\n", element->statuscode, element->msg, /**/ element->contenttype, (element->charset[0] ? "; charset=\"" : ""), (element->charset[0] ? element->charset : ""), (element->charset[0] ? "\"" : ""), /**/ element->lastmodified, (int) element->size); if (element->location != NULL && element->location[0] != '\0') { sprintf(st->headers + strlen(st->headers), "Location: %s" "\r\n", element->location); } if (element->headers != NULL) { if (strlen(element->headers) < sizeof(st->headers) - strlen(element->headers) - 1) { strcat(st->headers, element->headers); } } strcat(st->headers, "\r\n"); size_headers = (int) strlen(st->headers); /* doc == */ /* Format: URL IP date mime result checksum location offset filename length */ if (element->adr != NULL) { domd5mem(element->adr, element->size, st->md5, 1); } else { strcpy(st->md5, "-"); } fprintf(fp, /* nl */ "\n" /* URL-record */ "%s%s %s %04d%02d%02d%02d%02d%02d %s %d %s %s %ld %s %ld" /* nl */ "\n", /* args */ (link_has_authority(url) ? "" : "http://"), url, "0.0.0.0", tm->tm_year + 1900, tm->tm_mon + 1, tm->tm_mday, tm->tm_hour, tm->tm_min, tm->tm_sec, element->contenttype, element->statuscode, st->md5, (element->location ? element->location : "-"), (long int) ftell(fp), st->filename, (long int) (size_headers + element->size)); /* network_doc */ if (fwrite(st->headers, 1, size_headers, fp) != size_headers || (element->size > 0 && fwrite(element->adr, 1, element->size, fp) != element->size) ) { return 1; /* Error */ } return 0; } static int PT_SaveCache__Arc(PT_Indexes indexes, const char *filename) { FILE *fp = fopen(filename, "wb"); if (fp != NULL) { PT_SaveCache__Arc_t st; int ret; time_t t = PT_GetTimeIndex(indexes); struct tm tm = PT_GetTime(t); /* version-2-block == filedesc://text/plain200--0 2 URLIP-addressArchive-dateContent-typeResult-codeChecksumLocation OffsetFilenameArchive-length */ const char *prefix = "2 0 HTTrack Website Copier" "\n" "URL IP-address Archive-Date Content-Type Result-code Checksum Location Offset Filename Archive-length" "\n" "\n"; sprintf(st.filename, "httrack_%d.arc", (int) t); fprintf(fp, "filedesc://%s 0.0.0.0 %04d%02d%02d%02d%02d%02d text/plain 200 - - 0 %s %d" "\n" "%s", st.filename, tm.tm_year + 1900, tm.tm_mon + 1, tm.tm_mday, tm.tm_hour, tm.tm_min, tm.tm_sec, st.filename, (int) strlen(prefix), prefix); st.fp = fp; st.indexes = indexes; st.t = t; ret = PT_EnumCache(indexes, PT_SaveCache__Arc_Fun, (void *) &st); fclose(fp); if (ret != 0) (void) unlink(filename); return ret; } return -1; } httrack-3.49.5/src/proxy/proxytrack.c0000644000175000017500000014630314360553245014535 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: ProxyTrack, httrack cache-based proxy */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* /\/\/\/\/\/\/\/\/\/\/\/\/\ PENDING WORK /\/\/\/\/\/\/\/\/\/\/\/\/\ - Etag update handling - Other cache archive handling (.arc) - Live plug/unplug of archives - Listing \/\/\/\/\/\/\/\/\/\/\/\/\/ PENDING WORK \/\/\/\/\/\/\/\/\/\/\/\/\/ */ /* Architecture rough draft Xavier Roche 2005 Aim: Building a sub-proxy to be linked with other top level proxies (such as Squid) Basic design: Classical HTTP/1.0 proxy server, with ICP server support Internal data design: HTTrack cache indexing in fast hashtables, with 'pluggable' design (add/removal of caches on-the-fly) Index structure organization: ----------------------------- foo/hts-cache/new.zip -----> Index[0] \ bar/hts-cache/new.zip -----> Index[1] > Central Index Lookup (CIL) baz/hts-cache/new.zip -----> Index[2] / .. -----> .. Indexes are hashtables with URL (STRING) -> INTEGER lookup. URL -----> CIL Ask for index ID URL -----> Index[ID] Ask for index properties (ZIP cache index) Lookup of an entry: ------------------- ID = CIL[URL] If ID is valid Then return SUCCESS Else return FAILURE EndIf Fetching of an entry: --------------------- RESOURCE = null ID = CIL[URL] If ID is valid Then OFFSET = Index[ID][URL] If OFFSET is valid Then RESOURCE = Fetch(ID, OFFSET) EndIf EndIf Removal of index N: ------------------- For all entries in Index[N] URL(key) -----> Lookup all other caches Found: Replace in CIL Not Found: Delete entry in CIL Done Delete Index[N] Adding of index N: ------------------ Build Index[N] For all entries in Index[N] URL(key) -----> Lookup in CIL Found: Do nothing if corresponding Cache is newer than this one Not Found: Add/Replace entry in CIL Done Remark: If no cache newer than the added one is found, all entries can be added without any lookup (optim) */ /* HTTrack definitions */ #define HTSSAFE_ABORT_FUNCTION(A,B,C) #include "htsbase.h" #include "htsnet.h" #include "htslib.h" #include "htsglobal.h" #include #include #include #include #include #ifdef _WIN32 #else #include #endif /* END specific definitions */ /* String */ #include "proxystrings.h" /* Network base */ #include "htsbasenet.h" /* définitions globales */ #include "htsglobal.h" /* htsweb */ #include "coucal.h" /* ProxyTrack */ #include "proxytrack.h" /* Store manager */ #include "../minizip/mztools.h" #include "store.h" /* threads */ #ifdef _WIN32 #include /* _beginthread, _endthread */ #else #include #endif /* External references */ void abortLog__fnc(char *msg, char *file, int line); void abortLog__fnc(char *msg, char *file, int line) { FILE *fp = fopen("CRASH.TXT", "wb"); if (!fp) fp = fopen("/tmp/CRASH.TXT", "wb"); if (!fp) fp = fopen("C:\\CRASH.TXT", "wb"); if (!fp) fp = fopen("CRASH.TXT", "wb"); if (fp) { fprintf(fp, "HTTrack " HTTRACK_VERSIONID " closed at '%s', line %d\r\n", file, line); fprintf(fp, "Reason:\r\n%s\r\n", msg); fflush(fp); fclose(fp); } } #define webhttrack_lock(A) do{}while(0) /* Static definitions */ static int linputsoc(T_SOC soc, char *s, int max) { int c; int j = 0; do { unsigned char ch; if (recv(soc, &ch, 1, 0) == 1) { c = ch; } else { c = EOF; } if (c != EOF) { switch (c) { case 13: break; // sauter CR case 10: c = -1; break; case 9: case 12: break; // sauter ces caractères default: s[j++] = (char) c; break; } } } while((c != -1) && (c != EOF) && (j < (max - 1))); s[j] = '\0'; return j; } static int check_readinput_t(T_SOC soc, int timeout) { if (soc != INVALID_SOCKET) { fd_set fds; // poll structures struct timeval tv; // structure for select FD_ZERO(&fds); FD_SET(soc, &fds); tv.tv_sec = timeout; tv.tv_usec = 0; select((int) (soc + 1), &fds, NULL, NULL, &tv); if (FD_ISSET(soc, &fds)) return 1; else return 0; } else return 0; } static int linputsoc_t(T_SOC soc, char *s, int max, int timeout) { if (check_readinput_t(soc, timeout)) { return linputsoc(soc, s, max); } return -1; } static int gethost(const char *hostname, SOCaddr * server) { if (hostname != NULL && *hostname != '\0') { #if HTS_INET6==0 /* ipV4 resolver */ struct hostent *hp = gethostbyname(hostname); if (hp != NULL) { if (hp->h_length) { SOCaddr_copyaddr2(*server, hp->h_addr_list[0], hp->h_length); return 1; } } #else /* ipV6 resolver */ struct addrinfo *res = NULL; struct addrinfo hints; memset(&hints, 0, sizeof(hints)); #if 0 if (IPV6_resolver == 1) // V4 only (for bogus V6 entries) hints.ai_family = PF_INET; else if (IPV6_resolver == 2) // V6 only (for testing V6 only) hints.ai_family = PF_INET6; else #endif hints.ai_family = PF_UNSPEC; hints.ai_socktype = SOCK_STREAM; hints.ai_protocol = IPPROTO_TCP; if (getaddrinfo(hostname, NULL, &hints, &res) == 0) { if (res) { if ((res->ai_addr) && (res->ai_addrlen)) { SOCaddr_copyaddr2(*server, res->ai_addr, res->ai_addrlen); freeaddrinfo(res); return 1; } } } if (res) { freeaddrinfo(res); } #endif } return 0; } static String getip(SOCaddr * server) { String s = STRING_EMPTY; #if HTS_INET6==0 unsigned int sizeMax = sizeof("999.999.999.999:65535"); #else unsigned int sizeMax = sizeof("ffff:ffff:ffff:ffff:ffff:ffff:ffff:65535"); #endif char *dotted = malloc(sizeMax + 1); unsigned short port = ntohs(SOCaddr_sinport(*server)); if (dotted == NULL) { proxytrack_print_log(CRITICAL, "memory exhausted"); return s; } SOCaddr_inetntoa(dotted, sizeMax, *server); sprintf(dotted + strlen(dotted), ":%d", port); StringAttach(&s, &dotted); return s; } static T_SOC smallserver_init(const char *adr, int port, int family) { SOCaddr server; SOCaddr_initany(server); if (gethost(adr, &server)) { // host name T_SOC soc = INVALID_SOCKET; if ((soc = (T_SOC) socket(SOCaddr_sinfamily(server), family, 0)) != INVALID_SOCKET) { SOCaddr_initport(server, port); if (bind(soc, &SOCaddr_sockaddr(server), SOCaddr_size(server)) == 0) { if (family != SOCK_STREAM || listen(soc, 10) >= 0) { return soc; } else { #ifdef _WIN32 closesocket(soc); #else close(soc); #endif soc = INVALID_SOCKET; } } else { #ifdef _WIN32 closesocket(soc); #else close(soc); #endif soc = INVALID_SOCKET; } } } return INVALID_SOCKET; } static int proxytrack_start(PT_Indexes indexes, T_SOC soc, T_SOC socICP); int proxytrack_main(char *proxyAddr, int proxyPort, char *icpAddr, int icpPort, PT_Indexes index) { int returncode = 0; T_SOC soc = smallserver_init(proxyAddr, proxyPort, SOCK_STREAM); T_SOC socICP = smallserver_init(proxyAddr, icpPort, SOCK_DGRAM); if (soc != INVALID_SOCKET && socICP != INVALID_SOCKET) { //char url[HTS_URLMAXSIZE * 2]; //char method[32]; //char data[32768]; //url[0] = method[0] = data[0] = '\0'; // printf("HTTP Proxy installed on %s:%d/\n", proxyAddr, proxyPort); printf("ICP Proxy installed on %s:%d/\n", icpAddr, icpPort); #ifndef _WIN32 { pid_t pid = getpid(); printf("PID=%d\n", (int) pid); } #endif fflush(stdout); fflush(stderr); // if (!proxytrack_start(index, soc, socICP)) { int last_errno = errno; fprintf(stderr, "Unable to create the server: %s\n", strerror(last_errno)); #ifdef _WIN32 closesocket(soc); #else close(soc); #endif printf("Done\n"); returncode = 1; } else { returncode = 0; } } else { int last_errno = errno; fprintf(stderr, "Unable to initialize a temporary server : %s\n", strerror(last_errno)); returncode = 1; } printf("EXITED\n"); fflush(stdout); fflush(stderr); return returncode; } static const char *GetHttpMessage(int statuscode) { // Erreurs HTTP, selon RFC switch (statuscode) { case 100: return "Continue"; break; case 101: return "Switching Protocols"; break; case 200: return "OK"; break; case 201: return "Created"; break; case 202: return "Accepted"; break; case 203: return "Non-Authoritative Information"; break; case 204: return "No Content"; break; case 205: return "Reset Content"; break; case 206: return "Partial Content"; break; case 207: return "Multi-Status"; break; case 300: return "Multiple Choices"; break; case 301: return "Moved Permanently"; break; case 302: return "Moved Temporarily"; break; case 303: return "See Other"; break; case 304: return "Not Modified"; break; case 305: return "Use Proxy"; break; case 306: return "Undefined 306 error"; break; case 307: return "Temporary Redirect"; break; case 400: return "Bad Request"; break; case 401: return "Unauthorized"; break; case 402: return "Payment Required"; break; case 403: return "Forbidden"; break; case 404: return "Not Found"; break; case 405: return "Method Not Allowed"; break; case 406: return "Not Acceptable"; break; case 407: return "Proxy Authentication Required"; break; case 408: return "Request Time-out"; break; case 409: return "Conflict"; break; case 410: return "Gone"; break; case 411: return "Length Required"; break; case 412: return "Precondition Failed"; break; case 413: return "Request Entity Too Large"; break; case 414: return "Request-URI Too Large"; break; case 415: return "Unsupported Media Type"; break; case 416: return "Requested Range Not Satisfiable"; break; case 417: return "Expectation Failed"; break; case 500: return "Internal Server Error"; break; case 501: return "Not Implemented"; break; case 502: return "Bad Gateway"; break; case 503: return "Service Unavailable"; break; case 504: return "Gateway Time-out"; break; case 505: return "HTTP Version Not Supported"; break; default: return "Unknown HTTP Error"; break; } } #ifndef NO_WEBDAV static void proxytrack_add_DAV_Item(String * item, String * buff, const char *filename, size_t size, time_t timestamp, const char *mime, int isDir, int isRoot, int isDefault) { struct tm *timetm; if (timestamp == (time_t) 0 || timestamp == (time_t) - 1) { timestamp = time(NULL); } if ((timetm = gmtime(×tamp)) != NULL) { char tms[256 + 1]; const char *name; strftime(tms, 256, "%a, %d %b %Y %H:%M:%S GMT", timetm); /* Sun, 18 Sep 2005 11:45:45 GMT */ if (mime == NULL || *mime == 0) mime = "application/octet-stream"; StringLength(*buff) = 0; escapexml(filename, buff); name = strrchr(StringBuff(*buff), '/'); if (name != NULL) name++; if (name == NULL || *name == 0) { if (strcmp(mime, "text/html") == 0) name = "Default Document for the Folder.html"; else name = "Default Document for the Folder"; } StringRoom(*item, 1024); sprintf(StringBuffRW(*item), "\r\n" "/webdav%s%s\r\n" "\r\n" "\r\n" "%s\r\n" "%d\r\n" "%d\r\n" "%d\r\n" "%s\r\n" "%d-%02d-%02dT%02d:%02d:%02dZ\r\n" "%s\r\n" "\r\n" "\r\n" "%s\r\n" "%d\r\n" "%d\r\n" "\r\n" "HTTP/1.1 200 OK\r\n" "\r\n" "\r\n", /* */ (StringBuff(*buff)[0] == '/') ? "" : "/", StringBuff(*buff), name, isDir ? 1 : 0, isDir ? 1 : 0, isDir ? 1 : 0, isDir ? "" : "", timetm->tm_year + 1900, timetm->tm_mon + 1, timetm->tm_mday, timetm->tm_hour, timetm->tm_min, timetm->tm_sec, tms, isDir ? "httpd/unix-directory" : mime, (int) size, isRoot ? 1 : 0); StringLength(*item) = (int) strlen(StringBuff(*item)); } } /* Convert a RFC822 time to time_t */ static time_t get_time_rfc822(const char *s) { struct tm result; /* */ char months[] = "jan feb mar apr may jun jul aug sep oct nov dec"; char str[256]; char *a; int i; /* */ int result_mm = -1; int result_dd = -1; int result_n1 = -1; int result_n2 = -1; int result_n3 = -1; int result_n4 = -1; /* */ if ((int) strlen(s) > 200) return (time_t) 0; for(i = 0; s[i] != 0; i++) { if (s[i] >= 'A' && s[i] <= 'Z') str[i] = s[i] + ('a' - 'A'); else str[i] = s[i]; } str[i] = 0; /* éliminer :,- */ while((a = strchr(str, '-'))) *a = ' '; while((a = strchr(str, ':'))) *a = ' '; while((a = strchr(str, ','))) *a = ' '; /* tokeniser */ a = str; while(*a) { char *first, *last; char tok[256]; /* découper mot */ while(*a == ' ') a++; /* sauter espaces */ first = a; while((*a) && (*a != ' ')) a++; last = a; tok[0] = '\0'; if (first != last) { char *pos; strncat(tok, first, (int) (last - first)); /* analyser */ if ((pos = strstr(months, tok))) { /* month always in letters */ result_mm = ((int) (pos - months)) / 4; } else { int number; if (sscanf(tok, "%d", &number) == 1) { /* number token */ if (result_dd < 0) /* day always first number */ result_dd = number; else if (result_n1 < 0) result_n1 = number; else if (result_n2 < 0) result_n2 = number; else if (result_n3 < 0) result_n3 = number; else if (result_n4 < 0) result_n4 = number; } /* sinon, bruit de fond(+1GMT for exampel) */ } } } if ((result_n1 >= 0) && (result_mm >= 0) && (result_dd >= 0) && (result_n2 >= 0) && (result_n3 >= 0) && (result_n4 >= 0)) { if (result_n4 >= 1000) { /* Sun Nov 6 08:49:37 1994 */ result.tm_year = result_n4 - 1900; result.tm_hour = result_n1; result.tm_min = result_n2; result.tm_sec = max(result_n3, 0); } else { /* Sun, 06 Nov 1994 08:49:37 GMT or Sunday, 06-Nov-94 08:49:37 GMT */ result.tm_hour = result_n2; result.tm_min = result_n3; result.tm_sec = max(result_n4, 0); if (result_n1 <= 50) /* 00 means 2000 */ result.tm_year = result_n1 + 100; else if (result_n1 < 1000) /* 99 means 1999 */ result.tm_year = result_n1; else /* 2000 */ result.tm_year = result_n1 - 1900; } result.tm_isdst = 0; /* assume GMT */ result.tm_yday = -1; /* don't know */ result.tm_wday = -1; /* don't know */ result.tm_mon = result_mm; result.tm_mday = result_dd; return mktime(&result); } return (time_t) 0; } static PT_Element proxytrack_process_DAV_Request(PT_Indexes indexes, const char *urlFull, int depth) { const char *file = jump_protocol_and_auth(urlFull); if ((file = strchr(file, '/')) == NULL) return NULL; if (strncmp(file, "/webdav", 7) != 0) { PT_Element elt = PT_ElementNew(); elt->statuscode = 405; strcpy(elt->msg, "Method Not Allowed"); return elt; } /* Skip /webdav */ file += 7; /* */ { PT_Element elt = PT_ElementNew(); int i, isDir; String url = STRING_EMPTY; String response = STRING_EMPTY; String item = STRING_EMPTY; String itemUrl = STRING_EMPTY; String buff = STRING_EMPTY; StringClear(response); StringClear(item); StringClear(itemUrl); StringClear(buff); /* Canonize URL */ StringCopy(url, file + ((file[0] == '/') ? 1 : 0)); if (StringLength(url) > 0) { if (StringBuff(url)[StringLength(url) - 1] == '/') { StringBuffRW(url)[StringLength(url) - 1] = '\0'; StringLength(url)--; } } /* Form response */ StringRoom(response, 1024); sprintf(StringBuffRW(response), "\r\n" "\r\n"); StringLength(response) = (int) strlen(StringBuff(response)); /* */ /* Root */ StringLength(item) = 0; proxytrack_add_DAV_Item(&item, &buff, StringBuff(url), /*size */ 0, /*timestamp */ (time_t) 0, /*mime */ NULL, /*isDir */ 1, /*isRoot */ 1, /*isDefault */ 0); StringMemcat(response, StringBuff(item), StringLength(item)); /* Childrens (Depth > 0) */ if (depth > 0) { time_t timestampRep = (time_t) - 1; const char *prefix = StringBuff(url); unsigned int prefixLen = (unsigned int) strlen(prefix); char **list = PT_Enumerate(indexes, prefix, 0); if (list != NULL) { for(isDir = 1; isDir >= 0; isDir--) { for(i = 0; list[i] != NULL; i++) { const char *thisUrl = list[i]; const char *mimeType = "application/octet-stream"; unsigned int thisUrlLen = (unsigned int) strlen(thisUrl); int thisIsDir = (thisUrl[thisUrlLen - 1] == '/') ? 1 : 0; /* Item URL */ StringRoom(itemUrl, thisUrlLen + prefixLen + sizeof("/webdav/") + 1); StringClear(itemUrl); sprintf(StringBuffRW(itemUrl), "/%s/%s", prefix, thisUrl); if (!thisIsDir) StringLength(itemUrl) = (int) strlen(StringBuff(itemUrl)); else StringLength(itemUrl) = (int) strlen(StringBuff(itemUrl)) - 1; StringBuffRW(itemUrl)[StringLength(itemUrl)] = '\0'; if (thisIsDir == isDir) { size_t size = 0; time_t timestamp = (time_t) 0; PT_Element file = NULL; /* Item stats */ if (!isDir) { file = PT_ReadIndex(indexes, StringBuff(itemUrl) + 1, FETCH_HEADERS); if (file != NULL && file->statuscode == HTTP_OK) { size = file->size; if (file->lastmodified) { timestamp = get_time_rfc822(file->lastmodified); } if (timestamp == (time_t) 0) { if (timestampRep == (time_t) - 1) { timestampRep = 0; if (file->indexId != -1) { timestampRep = PT_Index_Timestamp(PT_GetIndex (indexes, file->indexId)); } } timestamp = timestampRep; } if (file->contenttype) { mimeType = file->contenttype; } } } /* Add item */ StringLength(item) = 0; proxytrack_add_DAV_Item(&item, &buff, StringBuff(itemUrl), size, timestamp, mimeType, isDir, /*isRoot */ 0, /*isDefault */ (thisUrlLen == 0)); StringMemcat(response, StringBuff(item), StringLength(item)); /* Wipe element */ if (file != NULL) PT_Element_Delete(&file); } } } PT_Enumerate_Delete(&list); } /* items != NULL */ } /* Depth > 0 */ /* End of responses */ StringCat(response, "\r\n"); StringFree(item); StringFree(itemUrl); StringFree(url); StringFree(buff); elt->size = StringLength(response); elt->adr = StringAcquire(&response); elt->statuscode = 207; /* Multi-Status */ strcpy(elt->charset, "utf-8"); strcpy(elt->contenttype, "text/xml"); strcpy(elt->msg, "Multi-Status"); StringFree(response); fprintf(stderr, "RESPONSE:\n%s\n", elt->adr); return elt; } return NULL; } #endif static PT_Element proxytrack_process_HTTP_List(PT_Indexes indexes, const char *url) { char **list = PT_Enumerate(indexes, url, 0); if (list != NULL) { PT_Element elt = PT_ElementNew(); int i, isDir; String html = STRING_EMPTY; StringClear(html); StringCat(html, "" PROXYTRACK_COMMENT_HEADER DISABLE_IE_FRIENDLY_HTTP_ERROR_MESSAGES "\r\n" "ProxyTrack " PROXYTRACK_VERSION " Catalog" "\r\n" "\r\n" "

Directory index:


" "
" "
" "[DIR] ..
"); for(isDir = 1; isDir >= 0; isDir--) { for(i = 0; list[i] != NULL; i++) { char *thisUrl = list[i]; unsigned int thisUrlLen = (unsigned int) strlen(thisUrl); int thisIsDir = (thisUrl[thisUrlLen - 1] == '/') ? 1 : 0; if (thisIsDir == isDir) { if (isDir) StringCat(html, "[DIR] "); else StringCat(html, "      "); StringCat(html, ""); StringCat(html, list[i]); StringCat(html, "
"); } } } StringCat(html, "" ""); PT_Enumerate_Delete(&list); elt->size = StringLength(html); elt->adr = StringAcquire(&html); elt->statuscode = HTTP_OK; strcpy(elt->charset, "iso-8859-1"); strcpy(elt->contenttype, "text/html"); strcpy(elt->msg, "OK"); StringFree(html); return elt; } return NULL; } static void proxytrack_process_HTTP(PT_Indexes indexes, T_SOC soc_c) { int timeout = 30; int buffer_size = 32768; char *buffer = (char *) malloc(buffer_size); int line1Size = 1024; char *line1 = (char *) malloc(line1Size); int lineSize = 8192; char *line = (char *) malloc(lineSize); int length = 0; int keepAlive = 1; String url = STRING_EMPTY; String urlRedirect = STRING_EMPTY; String headers = STRING_EMPTY; String output = STRING_EMPTY; String host = STRING_EMPTY; String localhost = STRING_EMPTY; #ifndef NO_WEBDAV String davHeaders = STRING_EMPTY; String davRequest = STRING_EMPTY; #endif StringRoom(localhost, 256); if (gethostname(StringBuffRW(localhost), (int) StringCapacity(localhost) - 1) == 0) { StringLength(localhost) = (int) strlen(StringBuff(localhost)); } else { StringCopy(localhost, "localhost"); } #ifdef _DEBUG Sleep(1000); #endif if (buffer == NULL || line == NULL || line1 == NULL) { proxytrack_print_log(CRITICAL, "proxytrack_process_HTTP:memory exhausted"); #ifdef _WIN32 closesocket(soc_c); #else close(soc_c); #endif return; } do { const char *msgError = NULL; int msgCode = 0; PT_Element element = NULL; char *command; char *proto; char *surl; //int directHit = 0; int headRequest = 0; int listRequest = 0; #ifndef NO_WEBDAV int davDepth = 0; #endif /* Clear context */ line[0] = line1[0] = '\0'; buffer[0] = '\0'; command = line1; StringClear(url); StringClear(urlRedirect); StringClear(headers); StringClear(output); StringClear(host); #ifndef NO_WEBDAV StringClear(davHeaders); StringClear(davRequest); #endif /* line1: "GET http://www.example.com/ HTTP/1.0" */ if (linputsoc_t(soc_c, line1, line1Size - 2, timeout) > 0 && (surl = strchr(line1, ' ')) && !(*surl = '\0') && ++surl && (proto = strchr(surl, ' ')) && !(*proto = '\0') && ++proto) { /* Flush headers */ while(linputsoc_t(soc_c, line, lineSize - 2, timeout) > 0 && line[0] != 0) { int p; if ((p = strfield(line, "Content-length:")) != 0) { if (sscanf(line + p, "%d", &length) != 1) { msgCode = 500; msgError = "Bad HTTP Content-Length Field"; keepAlive = 0; length = 0; } } else if (strcasecmp(line, "Connection: close") == 0) { keepAlive = 0; } else if (strcasecmp(line, "Connection: keep-alive") == 0) { keepAlive = 1; } else if ((p = strfield(line, "Host:"))) { char *chost = line + p; if (*chost == ' ') chost++; StringCopy(host, chost); } #ifndef NO_WEBDAV else if ((p = strfield(line, "Depth: "))) { char *depth = line + p; if (sscanf(depth, "%d", &davDepth) != 1) { davDepth = 0; } } #endif } /* Flush body */ #ifndef NO_WEBDAV if (length > 0) { if (length < 32768) { StringRoom(davRequest, length + 1); if (recv(soc_c, StringBuffRW(davRequest), length, 0) == length) { StringBuffRW(davRequest)[length] = 0; } else { msgCode = 500; msgError = "Posted Data Read Error"; keepAlive = 0; } } else { msgCode = 500; msgError = "Posted Data Too Large"; keepAlive = 0; } } #endif /* Switch protocol ID */ if (strcasecmp(command, "post") == 0) { #ifndef NO_WEBDAV msgCode = 404; #else msgCode = 501; keepAlive = 0; #endif msgError = "Proxy Error (POST Request Forbidden)"; } else if (strcasecmp(command, "get") == 0) { headRequest = 0; } else if (strcasecmp(command, "head") == 0) { headRequest = 1; } #ifndef NO_WEBDAV else if (strcasecmp(command, "options") == 0) { const char *options = "GET, HEAD, OPTIONS, POST, PROPFIND, TRACE" ", MKCOL, DELETE, PUT"; /* Not supported */ msgCode = HTTP_OK; StringRoom(headers, 8192); sprintf(StringBuffRW(headers), "HTTP/1.1 %d %s\r\n" "DAV: 1, 2\r\n" "MS-Author-Via: DAV\r\n" "Cache-Control: private\r\n" "Allow: %s\r\n", msgCode, GetHttpMessage(msgCode), options); StringLength(headers) = (int) strlen(StringBuff(headers)); } else if (strcasecmp(command, "propfind") == 0) { if (davDepth > 1) { msgCode = 403; msgError = "DAV Depth Limit Forbidden"; } else { fprintf(stderr, "DEBUG: DAV-DATA=<%s>\n", StringBuff(davRequest)); listRequest = 2; /* propfind */ } } else if (strcasecmp(command, "mkcol") == 0 || strcasecmp(command, "delete") == 0 || strcasecmp(command, "put") == 0 || strcasecmp(command, "proppatch") == 0 || strcasecmp(command, "lock") == 0 || strcasecmp(command, "unlock") == 0 || strcasecmp(command, "copy") == 0 || strcasecmp(command, "trace") == 0) { msgCode = 403; msgError = "Method Forbidden"; } #endif else { msgCode = 501; msgError = "Proxy Error (Unsupported or Unknown HTTP Command Request)"; keepAlive = 0; } if (strcasecmp(proto, "http/1.1") == 0) { keepAlive = 1; } else if (strcasecmp(proto, "http/1.0") == 0) { keepAlive = 0; } else { msgCode = 505; msgError = "Proxy Error (Unknown HTTP Version)"; keepAlive = 0; } /* Post-process request */ if (link_has_authority(surl)) { if (strncasecmp (surl, "http://proxytrack/", sizeof("http://proxytrack/") - 1) == 0) { //directHit = 1; /* Another direct hit hack */ } StringCopy(url, surl); } else { if (StringLength(host) > 0) { /* Direct hit */ if ( #ifndef NO_WEBDAV listRequest != 2 && #endif strncasecmp(StringBuff(host), StringBuff(localhost), StringLength(localhost)) == 0 && (StringBuff(host)[StringLength(localhost)] == '\0' || StringBuff(host)[StringLength(localhost)] == ':') && surl[0] == '/') { const char *toHit = surl + 1; if (strncmp(toHit, "webdav/", 7) == 0) { toHit += 7; } /* Direct hit */ //directHit = 1; StringCopy(url, ""); if (!link_has_authority(toHit)) StringCat(url, "http://"); StringCat(url, toHit); } else if (strncasecmp(surl, "/proxytrack/", sizeof("/proxytrack/") - 1) == 0) { const char *toHit = surl + sizeof("/proxytrack/") - 1; /* Direct hit */ //directHit = 1; StringCopy(url, ""); if (!link_has_authority(toHit)) StringCat(url, "http://"); StringCat(url, toHit); } else { /* Transparent proxy */ StringCopy(url, "http://"); StringCat(url, StringBuff(host)); StringCat(url, surl); } } else { msgCode = 500; msgError = "Transparent Proxy Error ('Host' HTTP Request Header Field Missing)"; keepAlive = 0; } } /* Response */ if (msgCode == 0) { if (listRequest == 1) { element = proxytrack_process_HTTP_List(indexes, StringBuff(url)); } #ifndef NO_WEBDAV else if (listRequest == 2) { if ((element = proxytrack_process_DAV_Request(indexes, StringBuff(url), davDepth)) != NULL) { msgCode = element->statuscode; StringRoom(davHeaders, 1024); sprintf(StringBuffRW(davHeaders), "DAV: 1, 2\r\n" "MS-Author-Via: DAV\r\n" "Cache-Control: private\r\n"); StringLength(davHeaders) = (int) strlen(StringBuff(davHeaders)); } } #endif else { element = PT_ReadIndex(indexes, StringBuff(url), FETCH_BODY); } if (element == NULL #ifndef NO_WEBDAV && listRequest == 2 #endif && StringLength(url) > 0 && StringBuff(url)[StringLength(url) - 1] == '/') { element = PT_Index_HTML_BuildRootInfo(indexes); if (element != NULL) { element->statuscode = 404; /* HTML page, but in error */ } } if (element != NULL) { msgCode = element->statuscode; StringRoom(headers, 8192); sprintf(StringBuffRW(headers), "HTTP/1.1 %d %s\r\n" #ifndef NO_WEBDAV "%s" #endif "Content-Type: %s%s%s%s\r\n" "%s%s%s" "%s%s%s" "%s%s%s", /* */ msgCode, element->msg, #ifndef NO_WEBDAV /* DAV */ StringBuff(davHeaders), #endif /* Content-type: foo; [ charset=bar ] */ element->contenttype, ((element->charset[0]) ? "; charset=\"" : ""), element->charset, ((element->charset[0]) ? "\"" : ""), /* location */ ((element->location != NULL && element->location[0]) ? "Location: " : ""), ((element->location != NULL && element->location[0]) ? element->location : ""), ((element->location != NULL && element->location[0]) ? "\r\n" : ""), /* last-modified */ ((element->lastmodified[0]) ? "Last-Modified: " : ""), ((element->lastmodified[0]) ? element->lastmodified : ""), ((element->lastmodified[0]) ? "\r\n" : ""), /* etag */ ((element->etag[0]) ? "ETag: " : ""), ((element->etag[0]) ? element->etag : ""), ((element->etag[0]) ? "\r\n" : "") ); StringLength(headers) = (int) strlen(StringBuff(headers)); } else { /* No query string, no ending / : check the the / page */ if (StringLength(url) > 0 && StringBuff(url)[StringLength(url) - 1] != '/' && strchr(StringBuff(url), '?') == NULL) { StringCopy(urlRedirect, StringBuff(url)); StringCat(urlRedirect, "/"); if (PT_LookupIndex(indexes, StringBuff(urlRedirect))) { msgCode = 301; /* Moved Permanently */ StringRoom(headers, 8192); sprintf(StringBuffRW(headers), "HTTP/1.1 %d %s\r\n" "Content-Type: text/html\r\n" "Location: %s\r\n", /* */ msgCode, GetHttpMessage(msgCode), StringBuff(urlRedirect) ); StringLength(headers) = (int) strlen(StringBuff(headers)); /* */ StringRoom(output, 1024 + sizeof(PROXYTRACK_COMMENT_HEADER) + sizeof(DISABLE_IE_FRIENDLY_HTTP_ERROR_MESSAGES)); sprintf(StringBuffRW(output), "" PROXYTRACK_COMMENT_HEADER DISABLE_IE_FRIENDLY_HTTP_ERROR_MESSAGES "" "ProxyTrack - Page has moved" "\r\n" "" "

The correct location is:


" "%s
" "
" "
\r\n" "Generated by ProxyTrack " PROXYTRACK_VERSION ", (C) Xavier Roche and other contributors" "\r\n" "" "", StringBuff(urlRedirect), StringBuff(urlRedirect)); StringLength(output) = (int) strlen(StringBuff(output)); } } if (msgCode == 0) { msgCode = 404; msgError = "Not Found in this cache"; } } } } else { msgCode = 500; msgError = "Server Error"; keepAlive = 0; } if (StringLength(headers) == 0) { if (msgCode == 0) { msgCode = 500; msgError = "Internal Proxy Error"; } else if (msgError == NULL) { msgError = GetHttpMessage(msgCode); } StringRoom(headers, 256); sprintf(StringBuffRW(headers), "HTTP/1.1 %d %s\r\n" "Content-type: text/html\r\n", msgCode, msgError); StringLength(headers) = (int) strlen(StringBuff(headers)); StringRoom(output, 1024 + sizeof(PROXYTRACK_COMMENT_HEADER) + sizeof(DISABLE_IE_FRIENDLY_HTTP_ERROR_MESSAGES)); sprintf(StringBuffRW(output), "" PROXYTRACK_COMMENT_HEADER DISABLE_IE_FRIENDLY_HTTP_ERROR_MESSAGES "" "ProxyTrack - HTTP Proxy Error %d" "\r\n" "" "

A proxy error has occurred while processing the request.


" "Error HTTP %d: %s
" "
" "
\r\n" "Generated by ProxyTrack " PROXYTRACK_VERSION ", (C) Xavier Roche and other contributors" "\r\n" "" "", msgCode, msgCode, msgError); StringLength(output) = (int) strlen(StringBuff(output)); } { char tmp[20 + 1]; /* 2^64 = 18446744073709551616 */ size_t dataSize = 0; if (!headRequest) { dataSize = StringLength(output); if (dataSize == 0 && element != NULL) { dataSize = element->size; } } sprintf(tmp, "%d", (int) dataSize); StringCat(headers, "Content-length: "); StringCat(headers, tmp); StringCat(headers, "\r\n"); } if (keepAlive) { StringCat(headers, "Connection: Keep-Alive\r\n" "Proxy-Connection: Keep-Alive\r\n"); } else { StringCat(headers, "Connection: Close\r\n" "Proxy-Connection: Close\r\n"); } if (msgCode != 500) StringCat(headers, "X-Cache: HIT from "); else StringCat(headers, "X-Cache: MISS from "); StringCat(headers, StringBuff(localhost)); StringCat(headers, "\r\n"); /* Logging */ { const char *contentType = "text/html"; size_t size = StringLength(output) ? StringLength(output) : (element ? element-> size : 0); /* */ String ip = STRING_EMPTY; SOCaddr serverClient; SOClen lenServerClient = SOCaddr_capacity(serverClient); memset(&serverClient, 0, sizeof(serverClient)); if (getsockname (soc_c, &SOCaddr_sockaddr(serverClient), &lenServerClient) == 0) { ip = getip(&serverClient); } else { StringCopy(ip, "unknown"); } if (element != NULL && element->contenttype[0] != '\0') { contentType = element->contenttype; } proxytrack_print_log(LOG, "HTTP %s %d %d %s %s %s", StringBuff(ip), msgCode, (int) size, command, StringBuff(url), contentType); StringFree(ip); } /* Send reply */ StringCat(headers, "Server: ProxyTrack " PROXYTRACK_VERSION " (HTTrack " HTTRACK_VERSIONID ")\r\n"); StringCat(headers, "\r\n"); /* Headers separator */ if (send(soc_c, StringBuff(headers), (int) StringLength(headers), 0) != StringLength(headers) || (!headRequest && StringLength(output) > 0 && send(soc_c, StringBuff(output), (int) StringLength(output), 0) != StringLength(output)) || (!headRequest && StringLength(output) == 0 && element != NULL && element->adr != NULL && send(soc_c, element->adr, (int) element->size, 0) != element->size) ) { keepAlive = 0; /* Error, abort connection */ } PT_Element_Delete(&element); /* Shutdown (FIN) and wait until confirmed */ if (!keepAlive) { char c; #ifdef _WIN32 shutdown(soc_c, SD_SEND); #else shutdown(soc_c, 1); #endif while(recv(soc_c, ((char *) &c), 1, 0) > 0) ; } } while(keepAlive); #ifdef _WIN32 closesocket(soc_c); #else close(soc_c); #endif StringFree(url); StringFree(urlRedirect); StringFree(headers); StringFree(output); StringFree(host); StringFree(localhost); #ifndef NO_WEBDAV StringFree(davHeaders); StringFree(davRequest); #endif if (buffer) free(buffer); if (line) free(line); if (line1) free(line1); } /* Generic threaded function start */ #ifdef _WIN32 static int startThread(void (*funct) (void *), void *param) { if (param != NULL) { if (_beginthread(funct, 0, param) == -1) { free(param); return 0; } return 1; } else { return 0; } } #else /* Generic threaded function start */ static int startThread(void* (*funct) (void *), void *param) { if (param != NULL) { pthread_t handle = 0; int retcode = pthread_create(&handle, NULL, funct, param); if (retcode != 0) { /* error */ free(param); return 0; } else { /* detach the thread from the main process so that is can be independent */ pthread_detach(handle); return 1; } } else { return 0; } } #endif /* Generic socket/index structure */ typedef struct proxytrack_process_th_p { T_SOC soc_c; PT_Indexes indexes; void (*process) (PT_Indexes indexes, T_SOC soc_c); } proxytrack_process_th_p; #ifdef _WIN32 typedef void proxytrack_process_th_return_t; #define PROXYTRACK_PROCESS_TH_RETURN return #else typedef void* proxytrack_process_th_return_t; #define PROXYTRACK_PROCESS_TH_RETURN return NULL #endif /* Generic socket/index function stub */ static proxytrack_process_th_return_t proxytrack_process_th(void *param_) { proxytrack_process_th_p *param = (proxytrack_process_th_p *) param_; T_SOC soc_c = param->soc_c; PT_Indexes indexes = param->indexes; void (*process) (PT_Indexes indexes, T_SOC soc_c) = param->process; free(param); process(indexes, soc_c); PROXYTRACK_PROCESS_TH_RETURN; } /* Process generic socket/index operation */ static int proxytrack_process_generic(void (*process) (PT_Indexes indexes, T_SOC soc_c), PT_Indexes indexes, T_SOC soc_c) { proxytrack_process_th_p *param = calloc(sizeof(proxytrack_process_th_p), 1); if (param != NULL) { param->soc_c = soc_c; param->indexes = indexes; param->process = process; return startThread(proxytrack_process_th, param); } else { proxytrack_print_log(CRITICAL, "proxytrack_process_generic:Memory exhausted"); return 0; } return 0; } /* Process HTTP proxy requests */ static int proxytrack_process_HTTP_threaded(PT_Indexes indexes, T_SOC soc) { return proxytrack_process_generic(proxytrack_process_HTTP, indexes, soc); } /* HTTP Server */ static int proxytrack_start_HTTP(PT_Indexes indexes, T_SOC soc) { while(soc != INVALID_SOCKET) { T_SOC soc_c; if ((soc_c = (T_SOC) accept(soc, NULL, NULL)) != INVALID_SOCKET) { if (!proxytrack_process_HTTP_threaded(indexes, soc_c)) { proxytrack_print_log(CRITICAL, "proxytrack_start_HTTP::Can not fork a thread"); } } } if (soc != INVALID_SOCKET) { #ifdef _WIN32 closesocket(soc); #else close(soc); #endif } return 1; } /* Network order is big endian */ #define READ_NET16(buffer) ( ( ((unsigned char*)buffer)[0] << 8 ) + ((unsigned char*)buffer)[1] ) #define READ_NET32(buffer) ( ( READ_NET16(buffer) << 16 ) + READ_NET16(((unsigned char*)buffer) + 2) ) #define WRITE_NET8(buffer, value) do { \ ((unsigned char*)buffer)[0] = (unsigned char)(value); \ } while(0) #define WRITE_NET16(buffer, value) do { \ ((unsigned char*)buffer)[0] = (((unsigned short)(value)) >> 8) & 0xff; \ ((unsigned char*)buffer)[1] = ((unsigned short)(value)) & 0xff; \ } while(0) #define WRITE_NET32(buffer, value) do { \ WRITE_NET16(buffer, ( ((unsigned int)(value)) >> 16 ) & 0xffff); \ WRITE_NET16(((unsigned char*)buffer) + 2, ( ((unsigned int)(value)) ) & 0xffff); \ } while(0) static int ICP_reply(struct sockaddr *clientAddr, int clientAddrLen, T_SOC soc, /* */ unsigned char Opcode, unsigned char Version, unsigned short Message_Length, unsigned int Request_Number, unsigned int Options, unsigned int Option_Data, unsigned int Sender_Host_Address, unsigned char *Message) { int ret = 0; unsigned long int BufferSize; unsigned char *buffer; if (Message_Length == 0 && Message != NULL) /* We have to get the message size */ Message_Length = (unsigned int) strlen((char*) Message) + 1; /* NULL terminated */ BufferSize = 20 + Message_Length; buffer = malloc(BufferSize); if (buffer != NULL) { WRITE_NET8(&buffer[0], Opcode); WRITE_NET8(&buffer[1], Version); WRITE_NET16(&buffer[2], Message_Length); WRITE_NET32(&buffer[4], Request_Number); WRITE_NET32(&buffer[8], Options); WRITE_NET32(&buffer[12], Option_Data); WRITE_NET32(&buffer[16], Sender_Host_Address); if (Message != NULL && Message_Length > 0) { memcpy(buffer + 20, Message, Message_Length); } if (sendto(soc, buffer, BufferSize, 0, clientAddr, clientAddrLen) == BufferSize) { ret = 1; } free(buffer); } return ret; } /* ICP Server */ static int proxytrack_start_ICP(PT_Indexes indexes, T_SOC soc) { /* "ICP messages MUST not exceed 16,384 octets in length." (RFC2186) */ int bufferSize = 16384; unsigned char *buffer = (unsigned char *) malloc(bufferSize + 1); if (buffer == NULL) { proxytrack_print_log(CRITICAL, "proxytrack_start_ICP:memory exhausted"); #ifdef _WIN32 closesocket(soc); #else close(soc); #endif return -1; } while(soc != INVALID_SOCKET) { SOCaddr clientAddr; SOClen clientAddrLen = SOCaddr_capacity(clientAddr); int n; memset(&clientAddr, 0, sizeof(clientAddr)); n = recvfrom(soc, (char *) buffer, bufferSize, 0, &SOCaddr_sockaddr(clientAddr), &clientAddrLen); if (n != -1) { const char *LogRequest = "ERROR"; const char *LogReply = "ERROR"; unsigned char *UrlRequest = NULL; if (n >= 20) { enum { ICP_OP_MIN = 0, ICP_OP_INVALID = 0, ICP_OP_QUERY = 1, ICP_OP_HIT = 2, ICP_OP_MISS = 3, ICP_OP_ERR = 4, ICP_OP_SECHO = 10, ICP_OP_DECHO = 11, ICP_OP_MISS_NOFETCH = 21, ICP_OP_DENIED = 22, ICP_OP_HIT_OBJ = 23, ICP_OP_MAX = ICP_OP_HIT_OBJ }; unsigned char Opcode = buffer[0]; unsigned char Version = buffer[1]; unsigned short Message_Length = READ_NET16(&buffer[2]); unsigned int Request_Number = READ_NET32(&buffer[4]); /* Session ID */ //unsigned int Options = READ_NET32(&buffer[8]); //unsigned int Option_Data = READ_NET32(&buffer[12]); /* ICP_FLAG_SRC_RTT */ //unsigned int Sender_Host_Address = READ_NET32(&buffer[16]); /* ignored */ unsigned char *Payload = &buffer[20]; buffer[bufferSize] = '\0'; /* Ensure payload is NULL terminated */ if (Message_Length <= bufferSize - 20) { if (Opcode >= ICP_OP_MIN && Opcode <= ICP_OP_MAX) { if (Version == 2) { switch (Opcode) { case ICP_OP_QUERY: { unsigned int UrlRequestSize; UrlRequest = &Payload[4]; UrlRequestSize = (unsigned int) strlen((char *) UrlRequest); LogRequest = "ICP_OP_QUERY"; if (indexes == NULL) { ICP_reply(&SOCaddr_sockaddr(clientAddr), clientAddrLen, soc, ICP_OP_DENIED, Version, 0, Request_Number, 0, 0, 0, UrlRequest); LogReply = "ICP_OP_DENIED"; } else if (PT_LookupIndex(indexes, (char*) UrlRequest)) { ICP_reply(&SOCaddr_sockaddr(clientAddr), clientAddrLen, soc, ICP_OP_HIT, Version, 0, Request_Number, 0, 0, 0, UrlRequest); LogReply = "ICP_OP_HIT"; } else { if (UrlRequestSize > 0 && UrlRequest[UrlRequestSize - 1] != '/' && strchr((char*) UrlRequest, '?') == NULL) { char *UrlRedirect = malloc(UrlRequestSize + 1 + 1); if (UrlRedirect != NULL) { sprintf(UrlRedirect, "%s/", UrlRequest); if (PT_LookupIndex(indexes, UrlRedirect)) { /* We'll generate a redirect */ ICP_reply(&SOCaddr_sockaddr(clientAddr), clientAddrLen, soc, ICP_OP_HIT, Version, 0, Request_Number, 0, 0, 0, UrlRequest); LogReply = "ICP_OP_HIT"; free(UrlRedirect); break; } free(UrlRedirect); } } /* We won't retrive the cache MISS online, no way! */ ICP_reply(&SOCaddr_sockaddr(clientAddr), clientAddrLen, soc, ICP_OP_MISS_NOFETCH, Version, 0, Request_Number, 0, 0, 0, UrlRequest); LogReply = "ICP_OP_MISS_NOFETCH"; } } break; case ICP_OP_SECHO: { UrlRequest = &Payload[4]; LogRequest = "ICP_OP_QUERY"; LogReply = "ICP_OP_QUERY"; ICP_reply(&SOCaddr_sockaddr(clientAddr), clientAddrLen, soc, ICP_OP_SECHO, Version, 0, Request_Number, 0, 0, 0, UrlRequest); } break; default: LogRequest = "NOTIMPLEMENTED"; LogReply = "ICP_OP_ERR"; ICP_reply(&SOCaddr_sockaddr(clientAddr), clientAddrLen, soc, ICP_OP_ERR, Version, 0, Request_Number, 0, 0, 0, NULL); break; } } else { ICP_reply(&SOCaddr_sockaddr(clientAddr), clientAddrLen, soc, ICP_OP_ERR, 2, 0, Request_Number, 0, 0, 0, NULL); } } /* Ignored (RFC2186) */ } else { ICP_reply(&SOCaddr_sockaddr(clientAddr), clientAddrLen, soc, ICP_OP_ERR, Version, 0, Request_Number, 0, 0, 0, NULL); } } /* Logging */ { String ip = STRING_EMPTY; SOCaddr serverClient; int lenServerClient = (int) sizeof(serverClient); SOCaddr_copyaddr(serverClient, lenServerClient, &clientAddr, clientAddrLen); if (lenServerClient > 0) { ip = getip(&clientAddr); } else { StringCopy(ip, "unknown"); } proxytrack_print_log(LOG, "ICP %s %s/%s %s", StringBuff(ip), LogRequest, LogReply, (UrlRequest ? (char*) UrlRequest : "-")); StringFree(ip); } } } if (soc != INVALID_SOCKET) { #ifdef _WIN32 closesocket(soc); #else close(soc); #endif } free(buffer); return 1; } static void proxytrack_start_ICP_th(PT_Indexes indexes, T_SOC soc) { (void) proxytrack_start_ICP(indexes, soc); } static int proxytrack_start(PT_Indexes indexes, T_SOC soc, T_SOC socICP) { int ret = 1; if (proxytrack_process_generic(proxytrack_start_ICP_th, indexes, socICP)) { if (!proxytrack_start_HTTP(indexes, soc)) { ret = 0; } } else { ret = 0; } return ret; } httrack-3.49.5/src/proxy/main.c0000644000175000017500000001360614336470674013261 00000000000000/* ------------------------------------------------------------ */ /* HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Please visit our Website: http://www.httrack.com */ /* ------------------------------------------------------------ */ /* File: ProxyTrack, httrack cache-based proxy */ /* Author: Xavier Roche */ /* ------------------------------------------------------------ */ /* Standard includes */ #include #include #include #include #include #define HTSSAFE_ABORT_FUNCTION(A,B,C) #include "htsbase.h" #include "htsnet.h" #include "htslib.h" #include "store.h" #include "proxytrack.h" #ifndef _WIN32 #include static void sig_brpipe(int code) { /* ignore */ } #endif static int scanHostPort(const char *str, char *host, int *port) { char *pos = strrchr(str, ':'); if (pos != NULL) { int n = (int) (pos - str); if (n < 256) { host[0] = '\0'; strncat(host, str, n); if (sscanf(pos + 1, "%d", port) == 1) { return 1; } } } return 0; } int main(int argc, char *argv[]) { int i; int ret = 0; int proxyPort = 0, icpPort = 0; char proxyAddr[256 + 1], icpAddr[256 + 1]; PT_Indexes index; #ifdef _WIN32 { WORD wVersionRequested; // requested version WinSock API WSADATA wsadata; // Windows Sockets API data int stat; wVersionRequested = 0x0101; stat = WSAStartup(wVersionRequested, &wsadata); if (stat != 0) { fprintf(stderr, "Winsock not found!\n"); return -1; } else if (LOBYTE(wsadata.wVersion) != 1 && HIBYTE(wsadata.wVersion) != 1) { fprintf(stderr, "WINSOCK.DLL does not support version 1.1\n"); WSACleanup(); return -1; } } #endif /* Args */ printf("ProxyTrack %s, build proxies upon HTTrack Website Copier Archives\n", PROXYTRACK_VERSION); printf("Copyright (C) 1998-2017 Xavier Roche and other contributors\n"); printf("\n"); printf("This program is free software: you can redistribute it and/or modify\n"); printf("it under the terms of the GNU General Public License as published by\n"); printf("the Free Software Foundation, either version 3 of the License, or\n"); printf("(at your option) any later version.\n"); printf("\n"); printf("*** This version is a development release ***\n"); printf("\n"); if (argc < 3 || (strcmp(argv[1], "--convert") != 0 && (!scanHostPort(argv[1], proxyAddr, &proxyPort) || !scanHostPort(argv[2], icpAddr, &icpPort) ) ) ) { fprintf(stderr, "proxy mode:\n"); fprintf(stderr, "usage: %s [ ( | | | --list ) ..]\n", argv[0]); fprintf(stderr, "\texample:%s proxy:8080 localhost:3130 /home/archives/www-archive-01.zip /home/old-archives/www-archive-02.ndx\n", argv[0]); fprintf(stderr, "convert mode:\n"); fprintf(stderr, "usage: %s --convert [ ( | | | --list ) ..]\n", argv[0]); fprintf(stderr, "\texample:%s proxy:8080 localhost:3130 /home/archives/www-archive-01.zip /home/old-archives/www-archive-02.ndx\n", argv[0]); return 1; } index = PT_New(); for(i = 3; i < argc; i++) { if (argv[i][0] == '-') { if (strcmp(argv[i], "--list") == 0) { if (i + 1 < argc) { char line[256 + 1]; FILE *fp = fopen(argv[++i], "rb"); if (fp == NULL) { fprintf(stderr, "error: could not process list %s\n", argv[i]); exit(1); } while(linput(fp, line, 256)) { int itemsAdded = PT_AddIndex(index, line); if (itemsAdded > 0) { fprintf(stderr, "processed: %s (%d items added)\n", line, itemsAdded); } else if (itemsAdded == 0) { fprintf(stderr, "processed: %s (no items added)\n", line); } else { fprintf(stderr, "error: could not process %s\n", line); } } fclose(fp); } } else { fprintf(stderr, "* bad arg %s\n", argv[i]); exit(1); } } else { int itemsAdded = PT_AddIndex(index, argv[i]); if (itemsAdded > 0) { fprintf(stderr, "processed: %s (%d items added)\n", argv[i], itemsAdded); } else if (itemsAdded == 0) { fprintf(stderr, "processed: %s (no items added)\n", argv[i]); } else { fprintf(stderr, "error: could not process %s\n", argv[i]); } } } /* sigpipe */ #ifndef _WIN32 signal(SIGPIPE, sig_brpipe); // broken pipe (write into non-opened socket) #endif /* Go */ if (strcmp(argv[1], "--convert") != 0) { ret = proxytrack_main(proxyAddr, proxyPort, icpAddr, icpPort, index); } else { if ((ret = PT_SaveCache(index, argv[2])) == 0) { fprintf(stderr, "processed: '%s'\n", argv[2]); } else { fprintf(stderr, "error: could not save '%s'\n", argv[2]); } } /* Wipe */ PT_Delete(index); #ifdef _WIN32 WSACleanup(); #endif return ret; } httrack-3.49.5/src/minizip/0000755000175000017500000000000014555203177012534 500000000000000httrack-3.49.5/src/minizip/MiniZip64_info.txt0000644000175000017500000000575014555200006015754 00000000000000MiniZip - Copyright (c) 1998-2010 - by Gilles Vollant - version 1.1 64 bits from Mathias Svensson Introduction --------------------- MiniZip 1.1 is built from MiniZip 1.0 by Gilles Vollant ( http://www.winimage.com/zLibDll/minizip.html ) When adding ZIP64 support into minizip it would result into risk of breaking compatibility with minizip 1.0. All possible work was done for compatibility. Background --------------------- When adding ZIP64 support Mathias Svensson found that Even Rouault have added ZIP64 support for unzip.c into minizip for a open source project called gdal ( http://www.gdal.org/ ) That was used as a starting point. And after that ZIP64 support was added to zip.c some refactoring and code cleanup was also done. Changed from MiniZip 1.0 to MiniZip 1.1 --------------------------------------- * Added ZIP64 support for unzip ( by Even Rouault ) * Added ZIP64 support for zip ( by Mathias Svensson ) * Reverted some changed that Even Rouault did. * Bunch of patches received from Gulles Vollant that he received for MiniZip from various users. * Added unzip patch for BZIP Compression method (patch create by Daniel Borca) * Added BZIP Compress method for zip * Did some refactoring and code cleanup Credits Gilles Vollant - Original MiniZip author Even Rouault - ZIP64 unzip Support Daniel Borca - BZip Compression method support in unzip Mathias Svensson - ZIP64 zip support Mathias Svensson - BZip Compression method support in zip Resources ZipLayout http://result42.com/projects/ZipFileLayout Command line tool for Windows that shows the layout and information of the headers in a zip archive. Used when debugging and validating the creation of zip files using MiniZip64 ZIP App Note http://www.pkware.com/documents/casestudies/APPNOTE.TXT Zip File specification Notes. * To be able to use BZip compression method in zip64.c or unzip64.c the BZIP2 lib is needed and HAVE_BZIP2 need to be defined. License ---------------------------------------------------------- Condition of use and distribution are the same than zlib : This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions: 1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required. 2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software. 3. This notice may not be removed or altered from any source distribution. ---------------------------------------------------------- httrack-3.49.5/src/minizip/MiniZip64_Changes.txt0000644000175000017500000000015414555201641016370 00000000000000 MiniZip 1.1 was derived from MiniZip at version 1.01f Change in 1.0 (Okt 2009) - **TODO - Add history** httrack-3.49.5/src/minizip/zip.h.orig0000644000175000017500000003623514555201641014371 00000000000000/* zip.h -- IO on .zip files using zlib Version 1.1, February 14h, 2010 part of the MiniZip project - ( http://www.winimage.com/zLibDll/minizip.html ) Copyright (C) 1998-2010 Gilles Vollant (minizip) ( http://www.winimage.com/zLibDll/minizip.html ) Modifications for Zip64 support Copyright (C) 2009-2010 Mathias Svensson ( http://result42.com ) For more info read MiniZip_info.txt --------------------------------------------------------------------------- Condition of use and distribution are the same than zlib : This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions: 1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required. 2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software. 3. This notice may not be removed or altered from any source distribution. --------------------------------------------------------------------------- Changes See header of zip.h */ #ifndef _zip12_H #define _zip12_H #ifdef __cplusplus extern "C" { #endif //#define HAVE_BZIP2 #ifndef _ZLIB_H #include "zlib.h" #endif #ifndef _ZLIBIOAPI_H #include "ioapi.h" #endif #ifdef HAVE_BZIP2 #include "bzlib.h" #endif #define Z_BZIP2ED 12 #if defined(STRICTZIP) || defined(STRICTZIPUNZIP) /* like the STRICT of WIN32, we define a pointer that cannot be converted from (void*) without cast */ typedef struct TagzipFile__ { int unused; } zipFile__; typedef zipFile__ *zipFile; #else typedef voidp zipFile; #endif #define ZIP_OK (0) #define ZIP_EOF (0) #define ZIP_ERRNO (Z_ERRNO) #define ZIP_PARAMERROR (-102) #define ZIP_BADZIPFILE (-103) #define ZIP_INTERNALERROR (-104) #ifndef DEF_MEM_LEVEL # if MAX_MEM_LEVEL >= 8 # define DEF_MEM_LEVEL 8 # else # define DEF_MEM_LEVEL MAX_MEM_LEVEL # endif #endif /* default memLevel */ /* tm_zip contain date/time info */ typedef struct tm_zip_s { int tm_sec; /* seconds after the minute - [0,59] */ int tm_min; /* minutes after the hour - [0,59] */ int tm_hour; /* hours since midnight - [0,23] */ int tm_mday; /* day of the month - [1,31] */ int tm_mon; /* months since January - [0,11] */ int tm_year; /* years - [1980..2044] */ } tm_zip; typedef struct { tm_zip tmz_date; /* date in understandable format */ uLong dosDate; /* if dos_date == 0, tmu_date is used */ /* uLong flag; */ /* general purpose bit flag 2 bytes */ uLong internal_fa; /* internal file attributes 2 bytes */ uLong external_fa; /* external file attributes 4 bytes */ } zip_fileinfo; typedef const char* zipcharpc; #define APPEND_STATUS_CREATE (0) #define APPEND_STATUS_CREATEAFTER (1) #define APPEND_STATUS_ADDINZIP (2) extern zipFile ZEXPORT zipOpen(const char *pathname, int append); extern zipFile ZEXPORT zipOpen64(const void *pathname, int append); /* Create a zipfile. pathname contain on Windows XP a filename like "c:\\zlib\\zlib113.zip" or on an Unix computer "zlib/zlib113.zip". if the file pathname exist and append==APPEND_STATUS_CREATEAFTER, the zip will be created at the end of the file. (useful if the file contain a self extractor code) if the file pathname exist and append==APPEND_STATUS_ADDINZIP, we will add files in existing zip (be sure you don't add file that doesn't exist) If the zipfile cannot be opened, the return value is NULL. Else, the return value is a zipFile Handle, usable with other function of this zip package. */ /* Note : there is no delete function into a zipfile. If you want delete file into a zipfile, you must open a zipfile, and create another Of course, you can use RAW reading and writing to copy the file you did not want delete */ extern zipFile ZEXPORT zipOpen2(const char *pathname, int append, zipcharpc* globalcomment, zlib_filefunc_def* pzlib_filefunc_def); extern zipFile ZEXPORT zipOpen2_64(const void *pathname, int append, zipcharpc* globalcomment, zlib_filefunc64_def* pzlib_filefunc_def); extern zipFile ZEXPORT zipOpen3(const void *pathname, int append, zipcharpc* globalcomment, zlib_filefunc64_32_def* pzlib_filefunc64_32_def); extern int ZEXPORT zipOpenNewFileInZip(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level); extern int ZEXPORT zipOpenNewFileInZip64(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int zip64); /* Open a file in the ZIP for writing. filename : the filename in zip (if NULL, '-' without quote will be used *zipfi contain supplemental information if extrafield_local!=NULL and size_extrafield_local>0, extrafield_local contains the extrafield data for the local header if extrafield_global!=NULL and size_extrafield_global>0, extrafield_global contains the extrafield data for the global header if comment != NULL, comment contain the comment string method contain the compression method (0 for store, Z_DEFLATED for deflate) level contain the level of compression (can be Z_DEFAULT_COMPRESSION) zip64 is set to 1 if a zip64 extended information block should be added to the local file header. this MUST be '1' if the uncompressed size is >= 0xffffffff. */ extern int ZEXPORT zipOpenNewFileInZip2(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int raw); extern int ZEXPORT zipOpenNewFileInZip2_64(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int raw, int zip64); /* Same than zipOpenNewFileInZip, except if raw=1, we write raw file */ extern int ZEXPORT zipOpenNewFileInZip3(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int raw, int windowBits, int memLevel, int strategy, const char* password, uLong crcForCrypting); extern int ZEXPORT zipOpenNewFileInZip3_64(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int raw, int windowBits, int memLevel, int strategy, const char* password, uLong crcForCrypting, int zip64); /* Same than zipOpenNewFileInZip2, except windowBits,memLevel,,strategy : see parameter strategy in deflateInit2 password : crypting password (NULL for no crypting) crcForCrypting : crc of file to compress (needed for crypting) */ extern int ZEXPORT zipOpenNewFileInZip4(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int raw, int windowBits, int memLevel, int strategy, const char* password, uLong crcForCrypting, uLong versionMadeBy, uLong flagBase); extern int ZEXPORT zipOpenNewFileInZip4_64(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int raw, int windowBits, int memLevel, int strategy, const char* password, uLong crcForCrypting, uLong versionMadeBy, uLong flagBase, int zip64); /* Same than zipOpenNewFileInZip4, except versionMadeBy : value for Version made by field flag : value for flag field (compression level info will be added) */ extern int ZEXPORT zipWriteInFileInZip(zipFile file, const void* buf, unsigned len); /* Write data in the zipfile */ extern int ZEXPORT zipCloseFileInZip(zipFile file); /* Close the current file in the zipfile */ extern int ZEXPORT zipCloseFileInZipRaw(zipFile file, uLong uncompressed_size, uLong crc32); extern int ZEXPORT zipCloseFileInZipRaw64(zipFile file, ZPOS64_T uncompressed_size, uLong crc32); /* Close the current file in the zipfile, for file opened with parameter raw=1 in zipOpenNewFileInZip2 uncompressed_size and crc32 are value for the uncompressed size */ extern int ZEXPORT zipClose(zipFile file, const char* global_comment); /* Close the zipfile */ extern int ZEXPORT zipRemoveExtraInfoBlock(char* pData, int* dataLen, short sHeader); /* zipRemoveExtraInfoBlock - Added by Mathias Svensson Remove extra information block from a extra information data for the local file header or central directory header It is needed to remove ZIP64 extra information blocks when before data is written if using RAW mode. 0x0001 is the signature header for the ZIP64 extra information blocks usage. Remove ZIP64 Extra information from a central director extra field data zipRemoveExtraInfoBlock(pCenDirExtraFieldData, &nCenDirExtraFieldDataLen, 0x0001); Remove ZIP64 Extra information from a Local File Header extra field data zipRemoveExtraInfoBlock(pLocalHeaderExtraFieldData, &nLocalHeaderExtraFieldDataLen, 0x0001); */ #ifdef __cplusplus } #endif #endif /* _zip64_H */ httrack-3.49.5/src/minizip/zip.c.orig0000644000175000017500000017761214555201641014371 00000000000000/* zip.c -- IO on .zip files using zlib Version 1.1, February 14h, 2010 part of the MiniZip project - ( http://www.winimage.com/zLibDll/minizip.html ) Copyright (C) 1998-2010 Gilles Vollant (minizip) ( http://www.winimage.com/zLibDll/minizip.html ) Modifications for Zip64 support Copyright (C) 2009-2010 Mathias Svensson ( http://result42.com ) For more info read MiniZip_info.txt Changes Oct-2009 - Mathias Svensson - Remove old C style function prototypes Oct-2009 - Mathias Svensson - Added Zip64 Support when creating new file archives Oct-2009 - Mathias Svensson - Did some code cleanup and refactoring to get better overview of some functions. Oct-2009 - Mathias Svensson - Added zipRemoveExtraInfoBlock to strip extra field data from its ZIP64 data It is used when recreating zip archive with RAW when deleting items from a zip. ZIP64 data is automatically added to items that needs it, and existing ZIP64 data need to be removed. Oct-2009 - Mathias Svensson - Added support for BZIP2 as compression mode (bzip2 lib is required) Jan-2010 - back to unzip and minizip 1.0 name scheme, with compatibility layer */ #include #include #include #include #include #include "zlib.h" #include "zip.h" #ifdef STDC # include #endif #ifdef NO_ERRNO_H extern int errno; #else # include #endif #ifndef local # define local static #endif /* compile with -Dlocal if your debugger can't find static symbols */ #ifndef VERSIONMADEBY # define VERSIONMADEBY (0x0) /* platform dependent */ #endif #ifndef Z_BUFSIZE #define Z_BUFSIZE (64*1024) //(16384) #endif #ifndef Z_MAXFILENAMEINZIP #define Z_MAXFILENAMEINZIP (256) #endif #ifndef ALLOC # define ALLOC(size) (malloc(size)) #endif /* #define SIZECENTRALDIRITEM (0x2e) #define SIZEZIPLOCALHEADER (0x1e) */ /* I've found an old Unix (a SunOS 4.1.3_U1) without all SEEK_* defined.... */ // NOT sure that this work on ALL platform #define MAKEULONG64(a, b) ((ZPOS64_T)(((unsigned long)(a)) | ((ZPOS64_T)((unsigned long)(b))) << 32)) #ifndef SEEK_CUR #define SEEK_CUR 1 #endif #ifndef SEEK_END #define SEEK_END 2 #endif #ifndef SEEK_SET #define SEEK_SET 0 #endif #ifndef DEF_MEM_LEVEL #if MAX_MEM_LEVEL >= 8 # define DEF_MEM_LEVEL 8 #else # define DEF_MEM_LEVEL MAX_MEM_LEVEL #endif #endif const char zip_copyright[] =" zip 1.01 Copyright 1998-2004 Gilles Vollant - http://www.winimage.com/zLibDll"; #define SIZEDATA_INDATABLOCK (4096-(4*4)) #define LOCALHEADERMAGIC (0x04034b50) #define CENTRALHEADERMAGIC (0x02014b50) #define ENDHEADERMAGIC (0x06054b50) #define ZIP64ENDHEADERMAGIC (0x6064b50) #define ZIP64ENDLOCHEADERMAGIC (0x7064b50) #define FLAG_LOCALHEADER_OFFSET (0x06) #define CRC_LOCALHEADER_OFFSET (0x0e) #define SIZECENTRALHEADER (0x2e) /* 46 */ typedef struct linkedlist_datablock_internal_s { struct linkedlist_datablock_internal_s* next_datablock; uLong avail_in_this_block; uLong filled_in_this_block; uLong unused; /* for future use and alignment */ unsigned char data[SIZEDATA_INDATABLOCK]; } linkedlist_datablock_internal; typedef struct linkedlist_data_s { linkedlist_datablock_internal* first_block; linkedlist_datablock_internal* last_block; } linkedlist_data; typedef struct { z_stream stream; /* zLib stream structure for inflate */ #ifdef HAVE_BZIP2 bz_stream bstream; /* bzLib stream structure for bziped */ #endif int stream_initialised; /* 1 is stream is initialised */ uInt pos_in_buffered_data; /* last written byte in buffered_data */ ZPOS64_T pos_local_header; /* offset of the local header of the file currently writing */ char* central_header; /* central header data for the current file */ uLong size_centralExtra; uLong size_centralheader; /* size of the central header for cur file */ uLong size_centralExtraFree; /* Extra bytes allocated to the centralheader but that are not used */ uLong flag; /* flag of the file currently writing */ int method; /* compression method of file currently wr.*/ int raw; /* 1 for directly writing raw data */ Byte buffered_data[Z_BUFSIZE];/* buffer contain compressed data to be writ*/ uLong dosDate; uLong crc32; int encrypt; int zip64; /* Add ZIP64 extended information in the extra field */ ZPOS64_T pos_zip64extrainfo; ZPOS64_T totalCompressedData; ZPOS64_T totalUncompressedData; #ifndef NOCRYPT unsigned long keys[3]; /* keys defining the pseudo-random sequence */ const z_crc_t* pcrc_32_tab; unsigned crypt_header_size; #endif } curfile64_info; typedef struct { zlib_filefunc64_32_def z_filefunc; voidpf filestream; /* io structure of the zipfile */ linkedlist_data central_dir;/* datablock with central dir in construction*/ int in_opened_file_inzip; /* 1 if a file in the zip is currently writ.*/ curfile64_info ci; /* info on the file currently writing */ ZPOS64_T begin_pos; /* position of the beginning of the zipfile */ ZPOS64_T add_position_when_writing_offset; ZPOS64_T number_entry; #ifndef NO_ADDFILEINEXISTINGZIP char *globalcomment; #endif } zip64_internal; #ifndef NOCRYPT #define INCLUDECRYPTINGCODE_IFCRYPTALLOWED #include "crypt.h" #endif local linkedlist_datablock_internal* allocate_new_datablock(void) { linkedlist_datablock_internal* ldi; ldi = (linkedlist_datablock_internal*) ALLOC(sizeof(linkedlist_datablock_internal)); if (ldi!=NULL) { ldi->next_datablock = NULL ; ldi->filled_in_this_block = 0 ; ldi->avail_in_this_block = SIZEDATA_INDATABLOCK ; } return ldi; } local void free_datablock(linkedlist_datablock_internal* ldi) { while (ldi!=NULL) { linkedlist_datablock_internal* ldinext = ldi->next_datablock; free(ldi); ldi = ldinext; } } local void init_linkedlist(linkedlist_data* ll) { ll->first_block = ll->last_block = NULL; } local void free_linkedlist(linkedlist_data* ll) { free_datablock(ll->first_block); ll->first_block = ll->last_block = NULL; } local int add_data_in_datablock(linkedlist_data* ll, const void* buf, uLong len) { linkedlist_datablock_internal* ldi; const unsigned char* from_copy; if (ll==NULL) return ZIP_INTERNALERROR; if (ll->last_block == NULL) { ll->first_block = ll->last_block = allocate_new_datablock(); if (ll->first_block == NULL) return ZIP_INTERNALERROR; } ldi = ll->last_block; from_copy = (const unsigned char*)buf; while (len>0) { uInt copy_this; uInt i; unsigned char* to_copy; if (ldi->avail_in_this_block==0) { ldi->next_datablock = allocate_new_datablock(); if (ldi->next_datablock == NULL) return ZIP_INTERNALERROR; ldi = ldi->next_datablock ; ll->last_block = ldi; } if (ldi->avail_in_this_block < len) copy_this = (uInt)ldi->avail_in_this_block; else copy_this = (uInt)len; to_copy = &(ldi->data[ldi->filled_in_this_block]); for (i=0;ifilled_in_this_block += copy_this; ldi->avail_in_this_block -= copy_this; from_copy += copy_this ; len -= copy_this; } return ZIP_OK; } /****************************************************************************/ #ifndef NO_ADDFILEINEXISTINGZIP /* =========================================================================== Inputs a long in LSB order to the given file nbByte == 1, 2 ,4 or 8 (byte, short or long, ZPOS64_T) */ local int zip64local_putValue(const zlib_filefunc64_32_def* pzlib_filefunc_def, voidpf filestream, ZPOS64_T x, int nbByte) { unsigned char buf[8]; int n; for (n = 0; n < nbByte; n++) { buf[n] = (unsigned char)(x & 0xff); x >>= 8; } if (x != 0) { /* data overflow - hack for ZIP64 (X Roche) */ for (n = 0; n < nbByte; n++) { buf[n] = 0xff; } } if (ZWRITE64(*pzlib_filefunc_def,filestream,buf,(uLong)nbByte)!=(uLong)nbByte) return ZIP_ERRNO; else return ZIP_OK; } local void zip64local_putValue_inmemory (void* dest, ZPOS64_T x, int nbByte) { unsigned char* buf=(unsigned char*)dest; int n; for (n = 0; n < nbByte; n++) { buf[n] = (unsigned char)(x & 0xff); x >>= 8; } if (x != 0) { /* data overflow - hack for ZIP64 */ for (n = 0; n < nbByte; n++) { buf[n] = 0xff; } } } /****************************************************************************/ local uLong zip64local_TmzDateToDosDate(const tm_zip* ptm) { uLong year = (uLong)ptm->tm_year; if (year>=1980) year-=1980; else if (year>=80) year-=80; return (uLong) (((uLong)(ptm->tm_mday) + (32 * (uLong)(ptm->tm_mon+1)) + (512 * year)) << 16) | (((uLong)ptm->tm_sec/2) + (32 * (uLong)ptm->tm_min) + (2048 * (uLong)ptm->tm_hour)); } /****************************************************************************/ local int zip64local_getByte(const zlib_filefunc64_32_def* pzlib_filefunc_def, voidpf filestream, int* pi) { unsigned char c; int err = (int)ZREAD64(*pzlib_filefunc_def,filestream,&c,1); if (err==1) { *pi = (int)c; return ZIP_OK; } else { if (ZERROR64(*pzlib_filefunc_def,filestream)) return ZIP_ERRNO; else return ZIP_EOF; } } /* =========================================================================== Reads a long in LSB order from the given gz_stream. Sets */ local int zip64local_getShort(const zlib_filefunc64_32_def* pzlib_filefunc_def, voidpf filestream, uLong* pX) { uLong x ; int i = 0; int err; err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x = (uLong)i; if (err==ZIP_OK) err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x += ((uLong)i)<<8; if (err==ZIP_OK) *pX = x; else *pX = 0; return err; } local int zip64local_getLong(const zlib_filefunc64_32_def* pzlib_filefunc_def, voidpf filestream, uLong* pX) { uLong x ; int i = 0; int err; err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x = (uLong)i; if (err==ZIP_OK) err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x += ((uLong)i)<<8; if (err==ZIP_OK) err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x += ((uLong)i)<<16; if (err==ZIP_OK) err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x += ((uLong)i)<<24; if (err==ZIP_OK) *pX = x; else *pX = 0; return err; } local int zip64local_getLong64(const zlib_filefunc64_32_def* pzlib_filefunc_def, voidpf filestream, ZPOS64_T *pX) { ZPOS64_T x; int i = 0; int err; err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x = (ZPOS64_T)i; if (err==ZIP_OK) err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x += ((ZPOS64_T)i)<<8; if (err==ZIP_OK) err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x += ((ZPOS64_T)i)<<16; if (err==ZIP_OK) err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x += ((ZPOS64_T)i)<<24; if (err==ZIP_OK) err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x += ((ZPOS64_T)i)<<32; if (err==ZIP_OK) err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x += ((ZPOS64_T)i)<<40; if (err==ZIP_OK) err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x += ((ZPOS64_T)i)<<48; if (err==ZIP_OK) err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x += ((ZPOS64_T)i)<<56; if (err==ZIP_OK) *pX = x; else *pX = 0; return err; } #ifndef BUFREADCOMMENT #define BUFREADCOMMENT (0x400) #endif /* Locate the Central directory of a zipfile (at the end, just before the global comment) */ local ZPOS64_T zip64local_SearchCentralDir(const zlib_filefunc64_32_def* pzlib_filefunc_def, voidpf filestream) { unsigned char* buf; ZPOS64_T uSizeFile; ZPOS64_T uBackRead; ZPOS64_T uMaxBack=0xffff; /* maximum size of global comment */ ZPOS64_T uPosFound=0; if (ZSEEK64(*pzlib_filefunc_def,filestream,0,ZLIB_FILEFUNC_SEEK_END) != 0) return 0; uSizeFile = ZTELL64(*pzlib_filefunc_def,filestream); if (uMaxBack>uSizeFile) uMaxBack = uSizeFile; buf = (unsigned char*)ALLOC(BUFREADCOMMENT+4); if (buf==NULL) return 0; uBackRead = 4; while (uBackReaduMaxBack) uBackRead = uMaxBack; else uBackRead+=BUFREADCOMMENT; uReadPos = uSizeFile-uBackRead ; uReadSize = ((BUFREADCOMMENT+4) < (uSizeFile-uReadPos)) ? (BUFREADCOMMENT+4) : (uLong)(uSizeFile-uReadPos); if (ZSEEK64(*pzlib_filefunc_def,filestream,uReadPos,ZLIB_FILEFUNC_SEEK_SET)!=0) break; if (ZREAD64(*pzlib_filefunc_def,filestream,buf,uReadSize)!=uReadSize) break; for (i=(int)uReadSize-3; (i--)>0;) if (((*(buf+i))==0x50) && ((*(buf+i+1))==0x4b) && ((*(buf+i+2))==0x05) && ((*(buf+i+3))==0x06)) { uPosFound = uReadPos+(unsigned)i; break; } if (uPosFound!=0) break; } free(buf); return uPosFound; } /* Locate the End of Zip64 Central directory locator and from there find the CD of a zipfile (at the end, just before the global comment) */ local ZPOS64_T zip64local_SearchCentralDir64(const zlib_filefunc64_32_def* pzlib_filefunc_def, voidpf filestream) { unsigned char* buf; ZPOS64_T uSizeFile; ZPOS64_T uBackRead; ZPOS64_T uMaxBack=0xffff; /* maximum size of global comment */ ZPOS64_T uPosFound=0; uLong uL; ZPOS64_T relativeOffset; if (ZSEEK64(*pzlib_filefunc_def,filestream,0,ZLIB_FILEFUNC_SEEK_END) != 0) return 0; uSizeFile = ZTELL64(*pzlib_filefunc_def,filestream); if (uMaxBack>uSizeFile) uMaxBack = uSizeFile; buf = (unsigned char*)ALLOC(BUFREADCOMMENT+4); if (buf==NULL) return 0; uBackRead = 4; while (uBackReaduMaxBack) uBackRead = uMaxBack; else uBackRead+=BUFREADCOMMENT; uReadPos = uSizeFile-uBackRead ; uReadSize = ((BUFREADCOMMENT+4) < (uSizeFile-uReadPos)) ? (BUFREADCOMMENT+4) : (uLong)(uSizeFile-uReadPos); if (ZSEEK64(*pzlib_filefunc_def,filestream,uReadPos,ZLIB_FILEFUNC_SEEK_SET)!=0) break; if (ZREAD64(*pzlib_filefunc_def,filestream,buf,uReadSize)!=uReadSize) break; for (i=(int)uReadSize-3; (i--)>0;) { // Signature "0x07064b50" Zip64 end of central directory locater if (((*(buf+i))==0x50) && ((*(buf+i+1))==0x4b) && ((*(buf+i+2))==0x06) && ((*(buf+i+3))==0x07)) { uPosFound = uReadPos+(unsigned)i; break; } } if (uPosFound!=0) break; } free(buf); if (uPosFound == 0) return 0; /* Zip64 end of central directory locator */ if (ZSEEK64(*pzlib_filefunc_def,filestream, uPosFound,ZLIB_FILEFUNC_SEEK_SET)!=0) return 0; /* the signature, already checked */ if (zip64local_getLong(pzlib_filefunc_def,filestream,&uL)!=ZIP_OK) return 0; /* number of the disk with the start of the zip64 end of central directory */ if (zip64local_getLong(pzlib_filefunc_def,filestream,&uL)!=ZIP_OK) return 0; if (uL != 0) return 0; /* relative offset of the zip64 end of central directory record */ if (zip64local_getLong64(pzlib_filefunc_def,filestream,&relativeOffset)!=ZIP_OK) return 0; /* total number of disks */ if (zip64local_getLong(pzlib_filefunc_def,filestream,&uL)!=ZIP_OK) return 0; if (uL != 1) return 0; /* Goto Zip64 end of central directory record */ if (ZSEEK64(*pzlib_filefunc_def,filestream, relativeOffset,ZLIB_FILEFUNC_SEEK_SET)!=0) return 0; /* the signature */ if (zip64local_getLong(pzlib_filefunc_def,filestream,&uL)!=ZIP_OK) return 0; if (uL != 0x06064b50) // signature of 'Zip64 end of central directory' return 0; return relativeOffset; } local int LoadCentralDirectoryRecord(zip64_internal* pziinit) { int err=ZIP_OK; ZPOS64_T byte_before_the_zipfile;/* byte before the zipfile, (>0 for sfx)*/ ZPOS64_T size_central_dir; /* size of the central directory */ ZPOS64_T offset_central_dir; /* offset of start of central directory */ ZPOS64_T central_pos; uLong uL; uLong number_disk; /* number of the current disk, used for spanning ZIP, unsupported, always 0*/ uLong number_disk_with_CD; /* number of the disk with central dir, used for spanning ZIP, unsupported, always 0*/ ZPOS64_T number_entry; ZPOS64_T number_entry_CD; /* total number of entries in the central dir (same than number_entry on nospan) */ uLong VersionMadeBy; uLong VersionNeeded; uLong size_comment; int hasZIP64Record = 0; // check first if we find a ZIP64 record central_pos = zip64local_SearchCentralDir64(&pziinit->z_filefunc,pziinit->filestream); if(central_pos > 0) { hasZIP64Record = 1; } else if(central_pos == 0) { central_pos = zip64local_SearchCentralDir(&pziinit->z_filefunc,pziinit->filestream); } /* disable to allow appending to empty ZIP archive if (central_pos==0) err=ZIP_ERRNO; */ if(hasZIP64Record) { ZPOS64_T sizeEndOfCentralDirectory; if (ZSEEK64(pziinit->z_filefunc, pziinit->filestream, central_pos, ZLIB_FILEFUNC_SEEK_SET) != 0) err=ZIP_ERRNO; /* the signature, already checked */ if (zip64local_getLong(&pziinit->z_filefunc, pziinit->filestream,&uL)!=ZIP_OK) err=ZIP_ERRNO; /* size of zip64 end of central directory record */ if (zip64local_getLong64(&pziinit->z_filefunc, pziinit->filestream, &sizeEndOfCentralDirectory)!=ZIP_OK) err=ZIP_ERRNO; /* version made by */ if (zip64local_getShort(&pziinit->z_filefunc, pziinit->filestream, &VersionMadeBy)!=ZIP_OK) err=ZIP_ERRNO; /* version needed to extract */ if (zip64local_getShort(&pziinit->z_filefunc, pziinit->filestream, &VersionNeeded)!=ZIP_OK) err=ZIP_ERRNO; /* number of this disk */ if (zip64local_getLong(&pziinit->z_filefunc, pziinit->filestream,&number_disk)!=ZIP_OK) err=ZIP_ERRNO; /* number of the disk with the start of the central directory */ if (zip64local_getLong(&pziinit->z_filefunc, pziinit->filestream,&number_disk_with_CD)!=ZIP_OK) err=ZIP_ERRNO; /* total number of entries in the central directory on this disk */ if (zip64local_getLong64(&pziinit->z_filefunc, pziinit->filestream, &number_entry)!=ZIP_OK) err=ZIP_ERRNO; /* total number of entries in the central directory */ if (zip64local_getLong64(&pziinit->z_filefunc, pziinit->filestream,&number_entry_CD)!=ZIP_OK) err=ZIP_ERRNO; if ((number_entry_CD!=number_entry) || (number_disk_with_CD!=0) || (number_disk!=0)) err=ZIP_BADZIPFILE; /* size of the central directory */ if (zip64local_getLong64(&pziinit->z_filefunc, pziinit->filestream,&size_central_dir)!=ZIP_OK) err=ZIP_ERRNO; /* offset of start of central directory with respect to the starting disk number */ if (zip64local_getLong64(&pziinit->z_filefunc, pziinit->filestream,&offset_central_dir)!=ZIP_OK) err=ZIP_ERRNO; // TODO.. // read the comment from the standard central header. size_comment = 0; } else { // Read End of central Directory info if (ZSEEK64(pziinit->z_filefunc, pziinit->filestream, central_pos,ZLIB_FILEFUNC_SEEK_SET)!=0) err=ZIP_ERRNO; /* the signature, already checked */ if (zip64local_getLong(&pziinit->z_filefunc, pziinit->filestream,&uL)!=ZIP_OK) err=ZIP_ERRNO; /* number of this disk */ if (zip64local_getShort(&pziinit->z_filefunc, pziinit->filestream,&number_disk)!=ZIP_OK) err=ZIP_ERRNO; /* number of the disk with the start of the central directory */ if (zip64local_getShort(&pziinit->z_filefunc, pziinit->filestream,&number_disk_with_CD)!=ZIP_OK) err=ZIP_ERRNO; /* total number of entries in the central dir on this disk */ number_entry = 0; if (zip64local_getShort(&pziinit->z_filefunc, pziinit->filestream, &uL)!=ZIP_OK) err=ZIP_ERRNO; else number_entry = uL; /* total number of entries in the central dir */ number_entry_CD = 0; if (zip64local_getShort(&pziinit->z_filefunc, pziinit->filestream, &uL)!=ZIP_OK) err=ZIP_ERRNO; else number_entry_CD = uL; if ((number_entry_CD!=number_entry) || (number_disk_with_CD!=0) || (number_disk!=0)) err=ZIP_BADZIPFILE; /* size of the central directory */ size_central_dir = 0; if (zip64local_getLong(&pziinit->z_filefunc, pziinit->filestream, &uL)!=ZIP_OK) err=ZIP_ERRNO; else size_central_dir = uL; /* offset of start of central directory with respect to the starting disk number */ offset_central_dir = 0; if (zip64local_getLong(&pziinit->z_filefunc, pziinit->filestream, &uL)!=ZIP_OK) err=ZIP_ERRNO; else offset_central_dir = uL; /* zipfile global comment length */ if (zip64local_getShort(&pziinit->z_filefunc, pziinit->filestream, &size_comment)!=ZIP_OK) err=ZIP_ERRNO; } if ((central_posz_filefunc, pziinit->filestream); return ZIP_ERRNO; } if (size_comment>0) { pziinit->globalcomment = (char*)ALLOC(size_comment+1); if (pziinit->globalcomment) { size_comment = ZREAD64(pziinit->z_filefunc, pziinit->filestream, pziinit->globalcomment,size_comment); pziinit->globalcomment[size_comment]=0; } } byte_before_the_zipfile = central_pos - (offset_central_dir+size_central_dir); pziinit->add_position_when_writing_offset = byte_before_the_zipfile; { ZPOS64_T size_central_dir_to_read = size_central_dir; size_t buf_size = SIZEDATA_INDATABLOCK; void* buf_read = (void*)ALLOC(buf_size); if (ZSEEK64(pziinit->z_filefunc, pziinit->filestream, offset_central_dir + byte_before_the_zipfile, ZLIB_FILEFUNC_SEEK_SET) != 0) err=ZIP_ERRNO; while ((size_central_dir_to_read>0) && (err==ZIP_OK)) { ZPOS64_T read_this = SIZEDATA_INDATABLOCK; if (read_this > size_central_dir_to_read) read_this = size_central_dir_to_read; if (ZREAD64(pziinit->z_filefunc, pziinit->filestream,buf_read,(uLong)read_this) != read_this) err=ZIP_ERRNO; if (err==ZIP_OK) err = add_data_in_datablock(&pziinit->central_dir,buf_read, (uLong)read_this); size_central_dir_to_read-=read_this; } free(buf_read); } pziinit->begin_pos = byte_before_the_zipfile; pziinit->number_entry = number_entry_CD; if (ZSEEK64(pziinit->z_filefunc, pziinit->filestream, offset_central_dir+byte_before_the_zipfile,ZLIB_FILEFUNC_SEEK_SET) != 0) err=ZIP_ERRNO; return err; } #endif /* !NO_ADDFILEINEXISTINGZIP*/ /************************************************************/ extern zipFile ZEXPORT zipOpen3(const void *pathname, int append, zipcharpc* globalcomment, zlib_filefunc64_32_def* pzlib_filefunc64_32_def) { zip64_internal ziinit; zip64_internal* zi; int err=ZIP_OK; ziinit.z_filefunc.zseek32_file = NULL; ziinit.z_filefunc.ztell32_file = NULL; if (pzlib_filefunc64_32_def==NULL) fill_fopen64_filefunc(&ziinit.z_filefunc.zfile_func64); else ziinit.z_filefunc = *pzlib_filefunc64_32_def; ziinit.filestream = ZOPEN64(ziinit.z_filefunc, pathname, (append == APPEND_STATUS_CREATE) ? (ZLIB_FILEFUNC_MODE_READ | ZLIB_FILEFUNC_MODE_WRITE | ZLIB_FILEFUNC_MODE_CREATE) : (ZLIB_FILEFUNC_MODE_READ | ZLIB_FILEFUNC_MODE_WRITE | ZLIB_FILEFUNC_MODE_EXISTING)); if (ziinit.filestream == NULL) return NULL; if (append == APPEND_STATUS_CREATEAFTER) ZSEEK64(ziinit.z_filefunc,ziinit.filestream,0,SEEK_END); ziinit.begin_pos = ZTELL64(ziinit.z_filefunc,ziinit.filestream); ziinit.in_opened_file_inzip = 0; ziinit.ci.stream_initialised = 0; ziinit.number_entry = 0; ziinit.add_position_when_writing_offset = 0; init_linkedlist(&(ziinit.central_dir)); zi = (zip64_internal*)ALLOC(sizeof(zip64_internal)); if (zi==NULL) { ZCLOSE64(ziinit.z_filefunc,ziinit.filestream); return NULL; } /* now we add file in a zipfile */ # ifndef NO_ADDFILEINEXISTINGZIP ziinit.globalcomment = NULL; if (append == APPEND_STATUS_ADDINZIP) { // Read and Cache Central Directory Records err = LoadCentralDirectoryRecord(&ziinit); } if (globalcomment) { *globalcomment = ziinit.globalcomment; } # endif /* !NO_ADDFILEINEXISTINGZIP*/ if (err != ZIP_OK) { # ifndef NO_ADDFILEINEXISTINGZIP free(ziinit.globalcomment); # endif /* !NO_ADDFILEINEXISTINGZIP*/ free(zi); return NULL; } else { *zi = ziinit; return (zipFile)zi; } } extern zipFile ZEXPORT zipOpen2(const char *pathname, int append, zipcharpc* globalcomment, zlib_filefunc_def* pzlib_filefunc32_def) { if (pzlib_filefunc32_def != NULL) { zlib_filefunc64_32_def zlib_filefunc64_32_def_fill; fill_zlib_filefunc64_32_def_from_filefunc32(&zlib_filefunc64_32_def_fill,pzlib_filefunc32_def); return zipOpen3(pathname, append, globalcomment, &zlib_filefunc64_32_def_fill); } else return zipOpen3(pathname, append, globalcomment, NULL); } extern zipFile ZEXPORT zipOpen2_64(const void *pathname, int append, zipcharpc* globalcomment, zlib_filefunc64_def* pzlib_filefunc_def) { if (pzlib_filefunc_def != NULL) { zlib_filefunc64_32_def zlib_filefunc64_32_def_fill; zlib_filefunc64_32_def_fill.zfile_func64 = *pzlib_filefunc_def; zlib_filefunc64_32_def_fill.ztell32_file = NULL; zlib_filefunc64_32_def_fill.zseek32_file = NULL; return zipOpen3(pathname, append, globalcomment, &zlib_filefunc64_32_def_fill); } else return zipOpen3(pathname, append, globalcomment, NULL); } extern zipFile ZEXPORT zipOpen(const char* pathname, int append) { return zipOpen3((const void*)pathname,append,NULL,NULL); } extern zipFile ZEXPORT zipOpen64(const void* pathname, int append) { return zipOpen3(pathname,append,NULL,NULL); } local int Write_LocalFileHeader(zip64_internal* zi, const char* filename, uInt size_extrafield_local, const void* extrafield_local) { /* write the local header */ int err; uInt size_filename = (uInt)strlen(filename); uInt size_extrafield = size_extrafield_local; err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)LOCALHEADERMAGIC, 4); if (err==ZIP_OK) { if(zi->ci.zip64) err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)45,2);/* version needed to extract */ else err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)20,2);/* version needed to extract */ } if (err==ZIP_OK) err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)zi->ci.flag,2); if (err==ZIP_OK) err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)zi->ci.method,2); if (err==ZIP_OK) err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)zi->ci.dosDate,4); // CRC / Compressed size / Uncompressed size will be filled in later and rewritten later if (err==ZIP_OK) err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)0,4); /* crc 32, unknown */ if (err==ZIP_OK) { if(zi->ci.zip64) err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)0xFFFFFFFF,4); /* compressed size, unknown */ else err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)0,4); /* compressed size, unknown */ } if (err==ZIP_OK) { if(zi->ci.zip64) err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)0xFFFFFFFF,4); /* uncompressed size, unknown */ else err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)0,4); /* uncompressed size, unknown */ } if (err==ZIP_OK) err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)size_filename,2); if(zi->ci.zip64) { size_extrafield += 20; } if (err==ZIP_OK) err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)size_extrafield,2); if ((err==ZIP_OK) && (size_filename > 0)) { if (ZWRITE64(zi->z_filefunc,zi->filestream,filename,size_filename)!=size_filename) err = ZIP_ERRNO; } if ((err==ZIP_OK) && (size_extrafield_local > 0)) { if (ZWRITE64(zi->z_filefunc, zi->filestream, extrafield_local, size_extrafield_local) != size_extrafield_local) err = ZIP_ERRNO; } if ((err==ZIP_OK) && (zi->ci.zip64)) { // write the Zip64 extended info short HeaderID = 1; short DataSize = 16; ZPOS64_T CompressedSize = 0; ZPOS64_T UncompressedSize = 0; // Remember position of Zip64 extended info for the local file header. (needed when we update size after done with file) zi->ci.pos_zip64extrainfo = ZTELL64(zi->z_filefunc,zi->filestream); err = zip64local_putValue(&zi->z_filefunc, zi->filestream, (ZPOS64_T)HeaderID,2); err = zip64local_putValue(&zi->z_filefunc, zi->filestream, (ZPOS64_T)DataSize,2); err = zip64local_putValue(&zi->z_filefunc, zi->filestream, (ZPOS64_T)UncompressedSize,8); err = zip64local_putValue(&zi->z_filefunc, zi->filestream, (ZPOS64_T)CompressedSize,8); } return err; } /* NOTE. When writing RAW the ZIP64 extended information in extrafield_local and extrafield_global needs to be stripped before calling this function it can be done with zipRemoveExtraInfoBlock It is not done here because then we need to realloc a new buffer since parameters are 'const' and I want to minimize unnecessary allocations. */ extern int ZEXPORT zipOpenNewFileInZip4_64(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int raw, int windowBits,int memLevel, int strategy, const char* password, uLong crcForCrypting, uLong versionMadeBy, uLong flagBase, int zip64) { zip64_internal* zi; uInt size_filename; uInt size_comment; uInt i; int err = ZIP_OK; # ifdef NOCRYPT (crcForCrypting); if (password != NULL) return ZIP_PARAMERROR; # endif if (file == NULL) return ZIP_PARAMERROR; #ifdef HAVE_BZIP2 if ((method!=0) && (method!=Z_DEFLATED) && (method!=Z_BZIP2ED)) return ZIP_PARAMERROR; #else if ((method!=0) && (method!=Z_DEFLATED)) return ZIP_PARAMERROR; #endif // The filename and comment length must fit in 16 bits. if ((filename!=NULL) && (strlen(filename)>0xffff)) return ZIP_PARAMERROR; if ((comment!=NULL) && (strlen(comment)>0xffff)) return ZIP_PARAMERROR; // The extra field length must fit in 16 bits. If the member also requires // a Zip64 extra block, that will also need to fit within that 16-bit // length, but that will be checked for later. if ((size_extrafield_local>0xffff) || (size_extrafield_global>0xffff)) return ZIP_PARAMERROR; zi = (zip64_internal*)file; if (zi->in_opened_file_inzip == 1) { err = zipCloseFileInZip (file); if (err != ZIP_OK) return err; } if (filename==NULL) filename="-"; if (comment==NULL) size_comment = 0; else size_comment = (uInt)strlen(comment); size_filename = (uInt)strlen(filename); if (zipfi == NULL) zi->ci.dosDate = 0; else { if (zipfi->dosDate != 0) zi->ci.dosDate = zipfi->dosDate; else zi->ci.dosDate = zip64local_TmzDateToDosDate(&zipfi->tmz_date); } zi->ci.flag = flagBase; if ((level==8) || (level==9)) zi->ci.flag |= 2; if (level==2) zi->ci.flag |= 4; if (level==1) zi->ci.flag |= 6; if (password != NULL) zi->ci.flag |= 1; zi->ci.crc32 = 0; zi->ci.method = method; zi->ci.encrypt = 0; zi->ci.stream_initialised = 0; zi->ci.pos_in_buffered_data = 0; zi->ci.raw = raw; zi->ci.pos_local_header = ZTELL64(zi->z_filefunc,zi->filestream); zi->ci.size_centralheader = SIZECENTRALHEADER + size_filename + size_extrafield_global + size_comment; zi->ci.size_centralExtraFree = 32; // Extra space we have reserved in case we need to add ZIP64 extra info data zi->ci.central_header = (char*)ALLOC((uInt)zi->ci.size_centralheader + zi->ci.size_centralExtraFree); zi->ci.size_centralExtra = size_extrafield_global; zip64local_putValue_inmemory(zi->ci.central_header,(uLong)CENTRALHEADERMAGIC,4); /* version info */ zip64local_putValue_inmemory(zi->ci.central_header+4,(uLong)versionMadeBy,2); zip64local_putValue_inmemory(zi->ci.central_header+6,(uLong)20,2); zip64local_putValue_inmemory(zi->ci.central_header+8,(uLong)zi->ci.flag,2); zip64local_putValue_inmemory(zi->ci.central_header+10,(uLong)zi->ci.method,2); zip64local_putValue_inmemory(zi->ci.central_header+12,(uLong)zi->ci.dosDate,4); zip64local_putValue_inmemory(zi->ci.central_header+16,(uLong)0,4); /*crc*/ zip64local_putValue_inmemory(zi->ci.central_header+20,(uLong)0,4); /*compr size*/ zip64local_putValue_inmemory(zi->ci.central_header+24,(uLong)0,4); /*uncompr size*/ zip64local_putValue_inmemory(zi->ci.central_header+28,(uLong)size_filename,2); zip64local_putValue_inmemory(zi->ci.central_header+30,(uLong)size_extrafield_global,2); zip64local_putValue_inmemory(zi->ci.central_header+32,(uLong)size_comment,2); zip64local_putValue_inmemory(zi->ci.central_header+34,(uLong)0,2); /*disk nm start*/ if (zipfi==NULL) zip64local_putValue_inmemory(zi->ci.central_header+36,(uLong)0,2); else zip64local_putValue_inmemory(zi->ci.central_header+36,(uLong)zipfi->internal_fa,2); if (zipfi==NULL) zip64local_putValue_inmemory(zi->ci.central_header+38,(uLong)0,4); else zip64local_putValue_inmemory(zi->ci.central_header+38,(uLong)zipfi->external_fa,4); if(zi->ci.pos_local_header >= 0xffffffff) zip64local_putValue_inmemory(zi->ci.central_header+42,(uLong)0xffffffff,4); else zip64local_putValue_inmemory(zi->ci.central_header+42,(uLong)zi->ci.pos_local_header - zi->add_position_when_writing_offset,4); for (i=0;ici.central_header+SIZECENTRALHEADER+i) = *(filename+i); for (i=0;ici.central_header+SIZECENTRALHEADER+size_filename+i) = *(((const char*)extrafield_global)+i); for (i=0;ici.central_header+SIZECENTRALHEADER+size_filename+ size_extrafield_global+i) = *(comment+i); if (zi->ci.central_header == NULL) return ZIP_INTERNALERROR; zi->ci.zip64 = zip64; zi->ci.totalCompressedData = 0; zi->ci.totalUncompressedData = 0; zi->ci.pos_zip64extrainfo = 0; err = Write_LocalFileHeader(zi, filename, size_extrafield_local, extrafield_local); #ifdef HAVE_BZIP2 zi->ci.bstream.avail_in = (uInt)0; zi->ci.bstream.avail_out = (uInt)Z_BUFSIZE; zi->ci.bstream.next_out = (char*)zi->ci.buffered_data; zi->ci.bstream.total_in_hi32 = 0; zi->ci.bstream.total_in_lo32 = 0; zi->ci.bstream.total_out_hi32 = 0; zi->ci.bstream.total_out_lo32 = 0; #endif zi->ci.stream.avail_in = (uInt)0; zi->ci.stream.avail_out = (uInt)Z_BUFSIZE; zi->ci.stream.next_out = zi->ci.buffered_data; zi->ci.stream.total_in = 0; zi->ci.stream.total_out = 0; zi->ci.stream.data_type = Z_BINARY; #ifdef HAVE_BZIP2 if ((err==ZIP_OK) && (zi->ci.method == Z_DEFLATED || zi->ci.method == Z_BZIP2ED) && (!zi->ci.raw)) #else if ((err==ZIP_OK) && (zi->ci.method == Z_DEFLATED) && (!zi->ci.raw)) #endif { if(zi->ci.method == Z_DEFLATED) { zi->ci.stream.zalloc = (alloc_func)0; zi->ci.stream.zfree = (free_func)0; zi->ci.stream.opaque = (voidpf)0; if (windowBits>0) windowBits = -windowBits; err = deflateInit2(&zi->ci.stream, level, Z_DEFLATED, windowBits, memLevel, strategy); if (err==Z_OK) zi->ci.stream_initialised = Z_DEFLATED; } else if(zi->ci.method == Z_BZIP2ED) { #ifdef HAVE_BZIP2 // Init BZip stuff here zi->ci.bstream.bzalloc = 0; zi->ci.bstream.bzfree = 0; zi->ci.bstream.opaque = (voidpf)0; err = BZ2_bzCompressInit(&zi->ci.bstream, level, 0,35); if(err == BZ_OK) zi->ci.stream_initialised = Z_BZIP2ED; #endif } } # ifndef NOCRYPT zi->ci.crypt_header_size = 0; if ((err==Z_OK) && (password != NULL)) { unsigned char bufHead[RAND_HEAD_LEN]; unsigned int sizeHead; zi->ci.encrypt = 1; zi->ci.pcrc_32_tab = get_crc_table(); /*init_keys(password,zi->ci.keys,zi->ci.pcrc_32_tab);*/ sizeHead=crypthead(password,bufHead,RAND_HEAD_LEN,zi->ci.keys,zi->ci.pcrc_32_tab,crcForCrypting); zi->ci.crypt_header_size = sizeHead; if (ZWRITE64(zi->z_filefunc,zi->filestream,bufHead,sizeHead) != sizeHead) err = ZIP_ERRNO; } # endif if (err==Z_OK) zi->in_opened_file_inzip = 1; return err; } extern int ZEXPORT zipOpenNewFileInZip4(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int raw, int windowBits,int memLevel, int strategy, const char* password, uLong crcForCrypting, uLong versionMadeBy, uLong flagBase) { return zipOpenNewFileInZip4_64(file, filename, zipfi, extrafield_local, size_extrafield_local, extrafield_global, size_extrafield_global, comment, method, level, raw, windowBits, memLevel, strategy, password, crcForCrypting, versionMadeBy, flagBase, 0); } extern int ZEXPORT zipOpenNewFileInZip3(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int raw, int windowBits,int memLevel, int strategy, const char* password, uLong crcForCrypting) { return zipOpenNewFileInZip4_64(file, filename, zipfi, extrafield_local, size_extrafield_local, extrafield_global, size_extrafield_global, comment, method, level, raw, windowBits, memLevel, strategy, password, crcForCrypting, VERSIONMADEBY, 0, 0); } extern int ZEXPORT zipOpenNewFileInZip3_64(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int raw, int windowBits,int memLevel, int strategy, const char* password, uLong crcForCrypting, int zip64) { return zipOpenNewFileInZip4_64(file, filename, zipfi, extrafield_local, size_extrafield_local, extrafield_global, size_extrafield_global, comment, method, level, raw, windowBits, memLevel, strategy, password, crcForCrypting, VERSIONMADEBY, 0, zip64); } extern int ZEXPORT zipOpenNewFileInZip2(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int raw) { return zipOpenNewFileInZip4_64(file, filename, zipfi, extrafield_local, size_extrafield_local, extrafield_global, size_extrafield_global, comment, method, level, raw, -MAX_WBITS, DEF_MEM_LEVEL, Z_DEFAULT_STRATEGY, NULL, 0, VERSIONMADEBY, 0, 0); } extern int ZEXPORT zipOpenNewFileInZip2_64(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int raw, int zip64) { return zipOpenNewFileInZip4_64(file, filename, zipfi, extrafield_local, size_extrafield_local, extrafield_global, size_extrafield_global, comment, method, level, raw, -MAX_WBITS, DEF_MEM_LEVEL, Z_DEFAULT_STRATEGY, NULL, 0, VERSIONMADEBY, 0, zip64); } extern int ZEXPORT zipOpenNewFileInZip64(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void*extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int zip64) { return zipOpenNewFileInZip4_64(file, filename, zipfi, extrafield_local, size_extrafield_local, extrafield_global, size_extrafield_global, comment, method, level, 0, -MAX_WBITS, DEF_MEM_LEVEL, Z_DEFAULT_STRATEGY, NULL, 0, VERSIONMADEBY, 0, zip64); } extern int ZEXPORT zipOpenNewFileInZip(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void*extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level) { return zipOpenNewFileInZip4_64(file, filename, zipfi, extrafield_local, size_extrafield_local, extrafield_global, size_extrafield_global, comment, method, level, 0, -MAX_WBITS, DEF_MEM_LEVEL, Z_DEFAULT_STRATEGY, NULL, 0, VERSIONMADEBY, 0, 0); } local int zip64FlushWriteBuffer(zip64_internal* zi) { int err=ZIP_OK; if (zi->ci.encrypt != 0) { #ifndef NOCRYPT uInt i; int t; for (i=0;ici.pos_in_buffered_data;i++) zi->ci.buffered_data[i] = zencode(zi->ci.keys, zi->ci.pcrc_32_tab, zi->ci.buffered_data[i],t); #endif } if (ZWRITE64(zi->z_filefunc,zi->filestream,zi->ci.buffered_data,zi->ci.pos_in_buffered_data) != zi->ci.pos_in_buffered_data) err = ZIP_ERRNO; zi->ci.totalCompressedData += zi->ci.pos_in_buffered_data; #ifdef HAVE_BZIP2 if(zi->ci.method == Z_BZIP2ED) { zi->ci.totalUncompressedData += zi->ci.bstream.total_in_lo32; zi->ci.bstream.total_in_lo32 = 0; zi->ci.bstream.total_in_hi32 = 0; } else #endif { zi->ci.totalUncompressedData += zi->ci.stream.total_in; zi->ci.stream.total_in = 0; } zi->ci.pos_in_buffered_data = 0; return err; } extern int ZEXPORT zipWriteInFileInZip(zipFile file, const void* buf, unsigned int len) { zip64_internal* zi; int err=ZIP_OK; if (file == NULL) return ZIP_PARAMERROR; zi = (zip64_internal*)file; if (zi->in_opened_file_inzip == 0) return ZIP_PARAMERROR; zi->ci.crc32 = crc32(zi->ci.crc32,buf,(uInt)len); #ifdef HAVE_BZIP2 if(zi->ci.method == Z_BZIP2ED && (!zi->ci.raw)) { zi->ci.bstream.next_in = (void*)buf; zi->ci.bstream.avail_in = len; err = BZ_RUN_OK; while ((err==BZ_RUN_OK) && (zi->ci.bstream.avail_in>0)) { if (zi->ci.bstream.avail_out == 0) { if (zip64FlushWriteBuffer(zi) == ZIP_ERRNO) err = ZIP_ERRNO; zi->ci.bstream.avail_out = (uInt)Z_BUFSIZE; zi->ci.bstream.next_out = (char*)zi->ci.buffered_data; } if(err != BZ_RUN_OK) break; if ((zi->ci.method == Z_BZIP2ED) && (!zi->ci.raw)) { uLong uTotalOutBefore_lo = zi->ci.bstream.total_out_lo32; // uLong uTotalOutBefore_hi = zi->ci.bstream.total_out_hi32; err=BZ2_bzCompress(&zi->ci.bstream, BZ_RUN); zi->ci.pos_in_buffered_data += (uInt)(zi->ci.bstream.total_out_lo32 - uTotalOutBefore_lo) ; } } if(err == BZ_RUN_OK) err = ZIP_OK; } else #endif { zi->ci.stream.next_in = (Bytef*)(uintptr_t)buf; zi->ci.stream.avail_in = len; while ((err==ZIP_OK) && (zi->ci.stream.avail_in>0)) { if (zi->ci.stream.avail_out == 0) { if (zip64FlushWriteBuffer(zi) == ZIP_ERRNO) err = ZIP_ERRNO; zi->ci.stream.avail_out = (uInt)Z_BUFSIZE; zi->ci.stream.next_out = zi->ci.buffered_data; } if(err != ZIP_OK) break; if ((zi->ci.method == Z_DEFLATED) && (!zi->ci.raw)) { uLong uTotalOutBefore = zi->ci.stream.total_out; err=deflate(&zi->ci.stream, Z_NO_FLUSH); zi->ci.pos_in_buffered_data += (uInt)(zi->ci.stream.total_out - uTotalOutBefore) ; } else { uInt copy_this,i; if (zi->ci.stream.avail_in < zi->ci.stream.avail_out) copy_this = zi->ci.stream.avail_in; else copy_this = zi->ci.stream.avail_out; for (i = 0; i < copy_this; i++) *(((char*)zi->ci.stream.next_out)+i) = *(((const char*)zi->ci.stream.next_in)+i); { zi->ci.stream.avail_in -= copy_this; zi->ci.stream.avail_out-= copy_this; zi->ci.stream.next_in+= copy_this; zi->ci.stream.next_out+= copy_this; zi->ci.stream.total_in+= copy_this; zi->ci.stream.total_out+= copy_this; zi->ci.pos_in_buffered_data += copy_this; } } }// while(...) } return err; } extern int ZEXPORT zipCloseFileInZipRaw(zipFile file, uLong uncompressed_size, uLong crc32) { return zipCloseFileInZipRaw64 (file, uncompressed_size, crc32); } extern int ZEXPORT zipCloseFileInZipRaw64(zipFile file, ZPOS64_T uncompressed_size, uLong crc32) { zip64_internal* zi; ZPOS64_T compressed_size; uLong invalidValue = 0xffffffff; unsigned datasize = 0; int err=ZIP_OK; if (file == NULL) return ZIP_PARAMERROR; zi = (zip64_internal*)file; if (zi->in_opened_file_inzip == 0) return ZIP_PARAMERROR; zi->ci.stream.avail_in = 0; if ((zi->ci.method == Z_DEFLATED) && (!zi->ci.raw)) { while (err==ZIP_OK) { uLong uTotalOutBefore; if (zi->ci.stream.avail_out == 0) { if (zip64FlushWriteBuffer(zi) == ZIP_ERRNO) err = ZIP_ERRNO; zi->ci.stream.avail_out = (uInt)Z_BUFSIZE; zi->ci.stream.next_out = zi->ci.buffered_data; } uTotalOutBefore = zi->ci.stream.total_out; err=deflate(&zi->ci.stream, Z_FINISH); zi->ci.pos_in_buffered_data += (uInt)(zi->ci.stream.total_out - uTotalOutBefore) ; } } else if ((zi->ci.method == Z_BZIP2ED) && (!zi->ci.raw)) { #ifdef HAVE_BZIP2 err = BZ_FINISH_OK; while (err==BZ_FINISH_OK) { uLong uTotalOutBefore; if (zi->ci.bstream.avail_out == 0) { if (zip64FlushWriteBuffer(zi) == ZIP_ERRNO) err = ZIP_ERRNO; zi->ci.bstream.avail_out = (uInt)Z_BUFSIZE; zi->ci.bstream.next_out = (char*)zi->ci.buffered_data; } uTotalOutBefore = zi->ci.bstream.total_out_lo32; err=BZ2_bzCompress(&zi->ci.bstream, BZ_FINISH); if(err == BZ_STREAM_END) err = Z_STREAM_END; zi->ci.pos_in_buffered_data += (uInt)(zi->ci.bstream.total_out_lo32 - uTotalOutBefore); } if(err == BZ_FINISH_OK) err = ZIP_OK; #endif } if (err==Z_STREAM_END) err=ZIP_OK; /* this is normal */ if ((zi->ci.pos_in_buffered_data>0) && (err==ZIP_OK)) { if (zip64FlushWriteBuffer(zi)==ZIP_ERRNO) err = ZIP_ERRNO; } if ((zi->ci.method == Z_DEFLATED) && (!zi->ci.raw)) { int tmp_err = deflateEnd(&zi->ci.stream); if (err == ZIP_OK) err = tmp_err; zi->ci.stream_initialised = 0; } #ifdef HAVE_BZIP2 else if((zi->ci.method == Z_BZIP2ED) && (!zi->ci.raw)) { int tmperr = BZ2_bzCompressEnd(&zi->ci.bstream); if (err==ZIP_OK) err = tmperr; zi->ci.stream_initialised = 0; } #endif if (!zi->ci.raw) { crc32 = (uLong)zi->ci.crc32; uncompressed_size = zi->ci.totalUncompressedData; } compressed_size = zi->ci.totalCompressedData; # ifndef NOCRYPT compressed_size += zi->ci.crypt_header_size; # endif // update Current Item crc and sizes, if(compressed_size >= 0xffffffff || uncompressed_size >= 0xffffffff || zi->ci.pos_local_header >= 0xffffffff) { /*version Made by*/ zip64local_putValue_inmemory(zi->ci.central_header+4,(uLong)45,2); /*version needed*/ zip64local_putValue_inmemory(zi->ci.central_header+6,(uLong)45,2); } zip64local_putValue_inmemory(zi->ci.central_header+16,crc32,4); /*crc*/ if(compressed_size >= 0xffffffff) zip64local_putValue_inmemory(zi->ci.central_header+20, invalidValue,4); /*compr size*/ else zip64local_putValue_inmemory(zi->ci.central_header+20, compressed_size,4); /*compr size*/ /// set internal file attributes field if (zi->ci.stream.data_type == Z_ASCII) zip64local_putValue_inmemory(zi->ci.central_header+36,(uLong)Z_ASCII,2); if(uncompressed_size >= 0xffffffff) zip64local_putValue_inmemory(zi->ci.central_header+24, invalidValue,4); /*uncompr size*/ else zip64local_putValue_inmemory(zi->ci.central_header+24, uncompressed_size,4); /*uncompr size*/ // Add ZIP64 extra info field for uncompressed size if(uncompressed_size >= 0xffffffff) datasize += 8; // Add ZIP64 extra info field for compressed size if(compressed_size >= 0xffffffff) datasize += 8; // Add ZIP64 extra info field for relative offset to local file header of current file if(zi->ci.pos_local_header >= 0xffffffff) datasize += 8; if(datasize > 0) { char* p = NULL; if((uLong)(datasize + 4) > zi->ci.size_centralExtraFree) { // we cannot write more data to the buffer that we have room for. return ZIP_BADZIPFILE; } p = zi->ci.central_header + zi->ci.size_centralheader; // Add Extra Information Header for 'ZIP64 information' zip64local_putValue_inmemory(p, 0x0001, 2); // HeaderID p += 2; zip64local_putValue_inmemory(p, datasize, 2); // DataSize p += 2; if(uncompressed_size >= 0xffffffff) { zip64local_putValue_inmemory(p, uncompressed_size, 8); p += 8; } if(compressed_size >= 0xffffffff) { zip64local_putValue_inmemory(p, compressed_size, 8); p += 8; } if(zi->ci.pos_local_header >= 0xffffffff) { zip64local_putValue_inmemory(p, zi->ci.pos_local_header, 8); p += 8; } // Update how much extra free space we got in the memory buffer // and increase the centralheader size so the new ZIP64 fields are included // ( 4 below is the size of HeaderID and DataSize field ) zi->ci.size_centralExtraFree -= datasize + 4; zi->ci.size_centralheader += datasize + 4; // Update the extra info size field zi->ci.size_centralExtra += datasize + 4; zip64local_putValue_inmemory(zi->ci.central_header+30,(uLong)zi->ci.size_centralExtra,2); } if (err==ZIP_OK) err = add_data_in_datablock(&zi->central_dir, zi->ci.central_header, (uLong)zi->ci.size_centralheader); free(zi->ci.central_header); if (err==ZIP_OK) { // Update the LocalFileHeader with the new values. ZPOS64_T cur_pos_inzip = ZTELL64(zi->z_filefunc,zi->filestream); if (ZSEEK64(zi->z_filefunc,zi->filestream, zi->ci.pos_local_header + 14,ZLIB_FILEFUNC_SEEK_SET)!=0) err = ZIP_ERRNO; if (err==ZIP_OK) err = zip64local_putValue(&zi->z_filefunc,zi->filestream,crc32,4); /* crc 32, unknown */ if(uncompressed_size >= 0xffffffff || compressed_size >= 0xffffffff ) { if(zi->ci.pos_zip64extrainfo > 0) { // Update the size in the ZIP64 extended field. if (ZSEEK64(zi->z_filefunc,zi->filestream, zi->ci.pos_zip64extrainfo + 4,ZLIB_FILEFUNC_SEEK_SET)!=0) err = ZIP_ERRNO; if (err==ZIP_OK) /* compressed size, unknown */ err = zip64local_putValue(&zi->z_filefunc, zi->filestream, uncompressed_size, 8); if (err==ZIP_OK) /* uncompressed size, unknown */ err = zip64local_putValue(&zi->z_filefunc, zi->filestream, compressed_size, 8); } else err = ZIP_BADZIPFILE; // Caller passed zip64 = 0, so no room for zip64 info -> fatal } else { if (err==ZIP_OK) /* compressed size, unknown */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,compressed_size,4); if (err==ZIP_OK) /* uncompressed size, unknown */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,uncompressed_size,4); } if (ZSEEK64(zi->z_filefunc,zi->filestream, cur_pos_inzip,ZLIB_FILEFUNC_SEEK_SET)!=0) err = ZIP_ERRNO; } zi->number_entry ++; zi->in_opened_file_inzip = 0; return err; } extern int ZEXPORT zipCloseFileInZip(zipFile file) { return zipCloseFileInZipRaw (file,0,0); } local int Write_Zip64EndOfCentralDirectoryLocator(zip64_internal* zi, ZPOS64_T zip64eocd_pos_inzip) { int err = ZIP_OK; ZPOS64_T pos = zip64eocd_pos_inzip - zi->add_position_when_writing_offset; err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)ZIP64ENDLOCHEADERMAGIC,4); /*num disks*/ if (err==ZIP_OK) /* number of the disk with the start of the central directory */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)0,4); /*relative offset*/ if (err==ZIP_OK) /* Relative offset to the Zip64EndOfCentralDirectory */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream, pos,8); /*total disks*/ /* Do not support spawning of disk so always say 1 here*/ if (err==ZIP_OK) /* number of the disk with the start of the central directory */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)1,4); return err; } local int Write_Zip64EndOfCentralDirectoryRecord(zip64_internal* zi, uLong size_centraldir, ZPOS64_T centraldir_pos_inzip) { int err = ZIP_OK; uLong Zip64DataSize = 44; err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)ZIP64ENDHEADERMAGIC,4); if (err==ZIP_OK) /* size of this 'zip64 end of central directory' */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(ZPOS64_T)Zip64DataSize,8); // why ZPOS64_T of this ? if (err==ZIP_OK) /* version made by */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)45,2); if (err==ZIP_OK) /* version needed */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)45,2); if (err==ZIP_OK) /* number of this disk */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)0,4); if (err==ZIP_OK) /* number of the disk with the start of the central directory */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)0,4); if (err==ZIP_OK) /* total number of entries in the central dir on this disk */ err = zip64local_putValue(&zi->z_filefunc, zi->filestream, zi->number_entry, 8); if (err==ZIP_OK) /* total number of entries in the central dir */ err = zip64local_putValue(&zi->z_filefunc, zi->filestream, zi->number_entry, 8); if (err==ZIP_OK) /* size of the central directory */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(ZPOS64_T)size_centraldir,8); if (err==ZIP_OK) /* offset of start of central directory with respect to the starting disk number */ { ZPOS64_T pos = centraldir_pos_inzip - zi->add_position_when_writing_offset; err = zip64local_putValue(&zi->z_filefunc,zi->filestream, (ZPOS64_T)pos,8); } return err; } local int Write_EndOfCentralDirectoryRecord(zip64_internal* zi, uLong size_centraldir, ZPOS64_T centraldir_pos_inzip) { int err = ZIP_OK; /*signature*/ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)ENDHEADERMAGIC,4); if (err==ZIP_OK) /* number of this disk */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)0,2); if (err==ZIP_OK) /* number of the disk with the start of the central directory */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)0,2); if (err==ZIP_OK) /* total number of entries in the central dir on this disk */ { { if(zi->number_entry >= 0xFFFF) err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)0xffff,2); // use value in ZIP64 record else err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)zi->number_entry,2); } } if (err==ZIP_OK) /* total number of entries in the central dir */ { if(zi->number_entry >= 0xFFFF) err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)0xffff,2); // use value in ZIP64 record else err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)zi->number_entry,2); } if (err==ZIP_OK) /* size of the central directory */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)size_centraldir,4); if (err==ZIP_OK) /* offset of start of central directory with respect to the starting disk number */ { ZPOS64_T pos = centraldir_pos_inzip - zi->add_position_when_writing_offset; if(pos >= 0xffffffff) { err = zip64local_putValue(&zi->z_filefunc,zi->filestream, (uLong)0xffffffff,4); } else err = zip64local_putValue(&zi->z_filefunc,zi->filestream, (uLong)(centraldir_pos_inzip - zi->add_position_when_writing_offset),4); } return err; } local int Write_GlobalComment(zip64_internal* zi, const char* global_comment) { int err = ZIP_OK; uInt size_global_comment = 0; if(global_comment != NULL) size_global_comment = (uInt)strlen(global_comment); err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)size_global_comment,2); if (err == ZIP_OK && size_global_comment > 0) { if (ZWRITE64(zi->z_filefunc,zi->filestream, global_comment, size_global_comment) != size_global_comment) err = ZIP_ERRNO; } return err; } extern int ZEXPORT zipClose(zipFile file, const char* global_comment) { zip64_internal* zi; int err = 0; uLong size_centraldir = 0; ZPOS64_T centraldir_pos_inzip; ZPOS64_T pos; if (file == NULL) return ZIP_PARAMERROR; zi = (zip64_internal*)file; if (zi->in_opened_file_inzip == 1) { err = zipCloseFileInZip (file); } #ifndef NO_ADDFILEINEXISTINGZIP if (global_comment==NULL) global_comment = zi->globalcomment; #endif centraldir_pos_inzip = ZTELL64(zi->z_filefunc,zi->filestream); if (err==ZIP_OK) { linkedlist_datablock_internal* ldi = zi->central_dir.first_block; while (ldi!=NULL) { if ((err==ZIP_OK) && (ldi->filled_in_this_block>0)) { if (ZWRITE64(zi->z_filefunc,zi->filestream, ldi->data, ldi->filled_in_this_block) != ldi->filled_in_this_block) err = ZIP_ERRNO; } size_centraldir += ldi->filled_in_this_block; ldi = ldi->next_datablock; } } free_linkedlist(&(zi->central_dir)); pos = centraldir_pos_inzip - zi->add_position_when_writing_offset; if(pos >= 0xffffffff || zi->number_entry >= 0xFFFF) { ZPOS64_T Zip64EOCDpos = ZTELL64(zi->z_filefunc,zi->filestream); Write_Zip64EndOfCentralDirectoryRecord(zi, size_centraldir, centraldir_pos_inzip); Write_Zip64EndOfCentralDirectoryLocator(zi, Zip64EOCDpos); } if (err==ZIP_OK) err = Write_EndOfCentralDirectoryRecord(zi, size_centraldir, centraldir_pos_inzip); if(err == ZIP_OK) err = Write_GlobalComment(zi, global_comment); if (ZCLOSE64(zi->z_filefunc,zi->filestream) != 0) if (err == ZIP_OK) err = ZIP_ERRNO; #ifndef NO_ADDFILEINEXISTINGZIP free(zi->globalcomment); #endif free(zi); return err; } extern int ZEXPORT zipRemoveExtraInfoBlock(char* pData, int* dataLen, short sHeader) { char* p = pData; int size = 0; char* pNewHeader; char* pTmp; short header; short dataSize; int retVal = ZIP_OK; if(pData == NULL || dataLen == NULL || *dataLen < 4) return ZIP_PARAMERROR; pNewHeader = (char*)ALLOC((unsigned)*dataLen); pTmp = pNewHeader; while(p < (pData + *dataLen)) { header = *(short*)p; dataSize = *(((short*)p)+1); if( header == sHeader ) // Header found. { p += dataSize + 4; // skip it. do not copy to temp buffer } else { // Extra Info block should not be removed, So copy it to the temp buffer. memcpy(pTmp, p, dataSize + 4); p += dataSize + 4; size += dataSize + 4; } } if(size < *dataLen) { // clean old extra info block. memset(pData,0, *dataLen); // copy the new extra info block over the old if(size > 0) memcpy(pData, pNewHeader, size); // set the new extra info size *dataLen = size; retVal = ZIP_OK; } else retVal = ZIP_ERRNO; free(pNewHeader); return retVal; } httrack-3.49.5/src/minizip/mztools.c.orig0000644000175000017500000001763314555200006015264 00000000000000/* Additional tools for Minizip Code: Xavier Roche '2004 License: Same as ZLIB (www.gzip.org) */ /* Code */ #include #include #include #include "zlib.h" #include "unzip.h" #define READ_8(adr) ((unsigned char)*(adr)) #define READ_16(adr) ( READ_8(adr) | (READ_8(adr+1) << 8) ) #define READ_32(adr) ( READ_16(adr) | (READ_16((adr)+2) << 16) ) #define WRITE_8(buff, n) do { \ *((unsigned char*)(buff)) = (unsigned char) ((n) & 0xff); \ } while(0) #define WRITE_16(buff, n) do { \ WRITE_8((unsigned char*)(buff), n); \ WRITE_8(((unsigned char*)(buff)) + 1, (n) >> 8); \ } while(0) #define WRITE_32(buff, n) do { \ WRITE_16((unsigned char*)(buff), (n) & 0xffff); \ WRITE_16((unsigned char*)(buff) + 2, (n) >> 16); \ } while(0) extern int ZEXPORT unzRepair(const char* file, const char* fileOut, const char* fileOutTmp, uLong* nRecovered, uLong* bytesRecovered) { int err = Z_OK; FILE* fpZip = fopen(file, "rb"); FILE* fpOut = fopen(fileOut, "wb"); FILE* fpOutCD = fopen(fileOutTmp, "wb"); if (fpZip != NULL && fpOut != NULL) { int entries = 0; uLong totalBytes = 0; char header[30]; char filename[1024]; char extra[1024]; int offset = 0; int offsetCD = 0; while ( fread(header, 1, 30, fpZip) == 30 ) { int currentOffset = offset; /* File entry */ if (READ_32(header) == 0x04034b50) { unsigned int version = READ_16(header + 4); unsigned int gpflag = READ_16(header + 6); unsigned int method = READ_16(header + 8); unsigned int filetime = READ_16(header + 10); unsigned int filedate = READ_16(header + 12); unsigned int crc = READ_32(header + 14); /* crc */ unsigned int cpsize = READ_32(header + 18); /* compressed size */ unsigned int uncpsize = READ_32(header + 22); /* uncompressed sz */ unsigned int fnsize = READ_16(header + 26); /* file name length */ unsigned int extsize = READ_16(header + 28); /* extra field length */ filename[0] = extra[0] = '\0'; /* Header */ if (fwrite(header, 1, 30, fpOut) == 30) { offset += 30; } else { err = Z_ERRNO; break; } /* Filename */ if (fnsize > 0) { if (fnsize < sizeof(filename)) { if (fread(filename, 1, fnsize, fpZip) == fnsize) { if (fwrite(filename, 1, fnsize, fpOut) == fnsize) { offset += fnsize; } else { err = Z_ERRNO; break; } } else { err = Z_ERRNO; break; } } else { err = Z_ERRNO; break; } } else { err = Z_STREAM_ERROR; break; } /* Extra field */ if (extsize > 0) { if (extsize < sizeof(extra)) { if (fread(extra, 1, extsize, fpZip) == extsize) { if (fwrite(extra, 1, extsize, fpOut) == extsize) { offset += extsize; } else { err = Z_ERRNO; break; } } else { err = Z_ERRNO; break; } } else { err = Z_ERRNO; break; } } /* Data */ { int dataSize = cpsize; if (dataSize == 0) { dataSize = uncpsize; } if (dataSize > 0) { char* data = malloc(dataSize); if (data != NULL) { if ((int)fread(data, 1, dataSize, fpZip) == dataSize) { if ((int)fwrite(data, 1, dataSize, fpOut) == dataSize) { offset += dataSize; totalBytes += dataSize; } else { err = Z_ERRNO; } } else { err = Z_ERRNO; } free(data); if (err != Z_OK) { break; } } else { err = Z_MEM_ERROR; break; } } } /* Central directory entry */ { char header[46]; char* comment = ""; int comsize = (int) strlen(comment); WRITE_32(header, 0x02014b50); WRITE_16(header + 4, version); WRITE_16(header + 6, version); WRITE_16(header + 8, gpflag); WRITE_16(header + 10, method); WRITE_16(header + 12, filetime); WRITE_16(header + 14, filedate); WRITE_32(header + 16, crc); WRITE_32(header + 20, cpsize); WRITE_32(header + 24, uncpsize); WRITE_16(header + 28, fnsize); WRITE_16(header + 30, extsize); WRITE_16(header + 32, comsize); WRITE_16(header + 34, 0); /* disk # */ WRITE_16(header + 36, 0); /* int attrb */ WRITE_32(header + 38, 0); /* ext attrb */ WRITE_32(header + 42, currentOffset); /* Header */ if (fwrite(header, 1, 46, fpOutCD) == 46) { offsetCD += 46; /* Filename */ if (fnsize > 0) { if (fwrite(filename, 1, fnsize, fpOutCD) == fnsize) { offsetCD += fnsize; } else { err = Z_ERRNO; break; } } else { err = Z_STREAM_ERROR; break; } /* Extra field */ if (extsize > 0) { if (fwrite(extra, 1, extsize, fpOutCD) == extsize) { offsetCD += extsize; } else { err = Z_ERRNO; break; } } /* Comment field */ if (comsize > 0) { if ((int)fwrite(comment, 1, comsize, fpOutCD) == comsize) { offsetCD += comsize; } else { err = Z_ERRNO; break; } } } else { err = Z_ERRNO; break; } } /* Success */ entries++; } else { break; } } /* Final central directory */ { int entriesZip = entries; char header[22]; char* comment = ""; // "ZIP File recovered by zlib/minizip/mztools"; int comsize = (int) strlen(comment); if (entriesZip > 0xffff) { entriesZip = 0xffff; } WRITE_32(header, 0x06054b50); WRITE_16(header + 4, 0); /* disk # */ WRITE_16(header + 6, 0); /* disk # */ WRITE_16(header + 8, entriesZip); /* hack */ WRITE_16(header + 10, entriesZip); /* hack */ WRITE_32(header + 12, offsetCD); /* size of CD */ WRITE_32(header + 16, offset); /* offset to CD */ WRITE_16(header + 20, comsize); /* comment */ /* Header */ if (fwrite(header, 1, 22, fpOutCD) == 22) { /* Comment field */ if (comsize > 0) { if ((int)fwrite(comment, 1, comsize, fpOutCD) != comsize) { err = Z_ERRNO; } } } else { err = Z_ERRNO; } } /* Final merge (file + central directory) */ fclose(fpOutCD); if (err == Z_OK) { fpOutCD = fopen(fileOutTmp, "rb"); if (fpOutCD != NULL) { int nRead; char buffer[8192]; while ( (nRead = (int)fread(buffer, 1, sizeof(buffer), fpOutCD)) > 0) { if ((int)fwrite(buffer, 1, nRead, fpOut) != nRead) { err = Z_ERRNO; break; } } fclose(fpOutCD); } } /* Close */ fclose(fpZip); fclose(fpOut); /* Wipe temporary file */ (void)remove(fileOutTmp); /* Number of recovered entries */ if (err == Z_OK) { if (nRecovered != NULL) { *nRecovered = entries; } if (bytesRecovered != NULL) { *bytesRecovered = totalBytes; } } } else { err = Z_STREAM_ERROR; } return err; } httrack-3.49.5/src/minizip/ioapi.h.orig0000644000175000017500000001567414555201641014674 00000000000000/* ioapi.h -- IO base function header for compress/uncompress .zip part of the MiniZip project - ( http://www.winimage.com/zLibDll/minizip.html ) Copyright (C) 1998-2010 Gilles Vollant (minizip) ( http://www.winimage.com/zLibDll/minizip.html ) Modifications for Zip64 support Copyright (C) 2009-2010 Mathias Svensson ( http://result42.com ) For more info read MiniZip_info.txt Changes Oct-2009 - Defined ZPOS64_T to fpos_t on windows and u_int64_t on linux. (might need to find a better why for this) Oct-2009 - Change to fseeko64, ftello64 and fopen64 so large files would work on linux. More if/def section may be needed to support other platforms Oct-2009 - Defined fxxxx64 calls to normal fopen/ftell/fseek so they would compile on windows. (but you should use iowin32.c for windows instead) */ #ifndef _ZLIBIOAPI64_H #define _ZLIBIOAPI64_H #if (!defined(_WIN32)) && (!defined(WIN32)) && (!defined(__APPLE__)) // Linux needs this to support file operation on files larger then 4+GB // But might need better if/def to select just the platforms that needs them. #ifndef __USE_FILE_OFFSET64 #define __USE_FILE_OFFSET64 #endif #ifndef __USE_LARGEFILE64 #define __USE_LARGEFILE64 #endif #ifndef _LARGEFILE64_SOURCE #define _LARGEFILE64_SOURCE #endif #ifndef _FILE_OFFSET_BIT #define _FILE_OFFSET_BIT 64 #endif #endif #include #include #include "zlib.h" #if defined(USE_FILE32API) #define fopen64 fopen #define ftello64 ftell #define fseeko64 fseek #else #if defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__HAIKU__) || defined(MINIZIP_FOPEN_NO_64) #define fopen64 fopen #define ftello64 ftello #define fseeko64 fseeko #endif #ifdef _MSC_VER #define fopen64 fopen #if (_MSC_VER >= 1400) && (!(defined(NO_MSCVER_FILE64_FUNC))) #define ftello64 _ftelli64 #define fseeko64 _fseeki64 #else // old MSC #define ftello64 ftell #define fseeko64 fseek #endif #endif #endif /* #ifndef ZPOS64_T #ifdef _WIN32 #define ZPOS64_T fpos_t #else #include #define ZPOS64_T uint64_t #endif #endif */ #ifdef HAVE_MINIZIP64_CONF_H #include "mz64conf.h" #endif /* a type chosen by DEFINE */ #ifdef HAVE_64BIT_INT_CUSTOM typedef 64BIT_INT_CUSTOM_TYPE ZPOS64_T; #else #ifdef HAS_STDINT_H #include "stdint.h" typedef uint64_t ZPOS64_T; #else #if defined(_MSC_VER) || defined(__BORLANDC__) typedef unsigned __int64 ZPOS64_T; #else typedef unsigned long long int ZPOS64_T; #endif #endif #endif /* Maximum unsigned 32-bit value used as placeholder for zip64 */ #ifndef MAXU32 #define MAXU32 (0xffffffff) #endif #ifdef __cplusplus extern "C" { #endif #define ZLIB_FILEFUNC_SEEK_CUR (1) #define ZLIB_FILEFUNC_SEEK_END (2) #define ZLIB_FILEFUNC_SEEK_SET (0) #define ZLIB_FILEFUNC_MODE_READ (1) #define ZLIB_FILEFUNC_MODE_WRITE (2) #define ZLIB_FILEFUNC_MODE_READWRITEFILTER (3) #define ZLIB_FILEFUNC_MODE_EXISTING (4) #define ZLIB_FILEFUNC_MODE_CREATE (8) #ifndef ZCALLBACK #if (defined(WIN32) || defined(_WIN32) || defined (WINDOWS) || defined (_WINDOWS)) && defined(CALLBACK) && defined (USEWINDOWS_CALLBACK) #define ZCALLBACK CALLBACK #else #define ZCALLBACK #endif #endif typedef voidpf (ZCALLBACK *open_file_func) (voidpf opaque, const char* filename, int mode); typedef uLong (ZCALLBACK *read_file_func) (voidpf opaque, voidpf stream, void* buf, uLong size); typedef uLong (ZCALLBACK *write_file_func) (voidpf opaque, voidpf stream, const void* buf, uLong size); typedef int (ZCALLBACK *close_file_func) (voidpf opaque, voidpf stream); typedef int (ZCALLBACK *testerror_file_func) (voidpf opaque, voidpf stream); typedef long (ZCALLBACK *tell_file_func) (voidpf opaque, voidpf stream); typedef long (ZCALLBACK *seek_file_func) (voidpf opaque, voidpf stream, uLong offset, int origin); /* here is the "old" 32 bits structure */ typedef struct zlib_filefunc_def_s { open_file_func zopen_file; read_file_func zread_file; write_file_func zwrite_file; tell_file_func ztell_file; seek_file_func zseek_file; close_file_func zclose_file; testerror_file_func zerror_file; voidpf opaque; } zlib_filefunc_def; typedef ZPOS64_T (ZCALLBACK *tell64_file_func) (voidpf opaque, voidpf stream); typedef long (ZCALLBACK *seek64_file_func) (voidpf opaque, voidpf stream, ZPOS64_T offset, int origin); typedef voidpf (ZCALLBACK *open64_file_func) (voidpf opaque, const void* filename, int mode); typedef struct zlib_filefunc64_def_s { open64_file_func zopen64_file; read_file_func zread_file; write_file_func zwrite_file; tell64_file_func ztell64_file; seek64_file_func zseek64_file; close_file_func zclose_file; testerror_file_func zerror_file; voidpf opaque; } zlib_filefunc64_def; void fill_fopen64_filefunc(zlib_filefunc64_def* pzlib_filefunc_def); void fill_fopen_filefunc(zlib_filefunc_def* pzlib_filefunc_def); /* now internal definition, only for zip.c and unzip.h */ typedef struct zlib_filefunc64_32_def_s { zlib_filefunc64_def zfile_func64; open_file_func zopen32_file; tell_file_func ztell32_file; seek_file_func zseek32_file; } zlib_filefunc64_32_def; #define ZREAD64(filefunc,filestream,buf,size) ((*((filefunc).zfile_func64.zread_file)) ((filefunc).zfile_func64.opaque,filestream,buf,size)) #define ZWRITE64(filefunc,filestream,buf,size) ((*((filefunc).zfile_func64.zwrite_file)) ((filefunc).zfile_func64.opaque,filestream,buf,size)) //#define ZTELL64(filefunc,filestream) ((*((filefunc).ztell64_file)) ((filefunc).opaque,filestream)) //#define ZSEEK64(filefunc,filestream,pos,mode) ((*((filefunc).zseek64_file)) ((filefunc).opaque,filestream,pos,mode)) #define ZCLOSE64(filefunc,filestream) ((*((filefunc).zfile_func64.zclose_file)) ((filefunc).zfile_func64.opaque,filestream)) #define ZERROR64(filefunc,filestream) ((*((filefunc).zfile_func64.zerror_file)) ((filefunc).zfile_func64.opaque,filestream)) voidpf call_zopen64(const zlib_filefunc64_32_def* pfilefunc,const void*filename,int mode); long call_zseek64(const zlib_filefunc64_32_def* pfilefunc,voidpf filestream, ZPOS64_T offset, int origin); ZPOS64_T call_ztell64(const zlib_filefunc64_32_def* pfilefunc,voidpf filestream); void fill_zlib_filefunc64_32_def_from_filefunc32(zlib_filefunc64_32_def* p_filefunc64_32,const zlib_filefunc_def* p_filefunc32); #define ZOPEN64(filefunc,filename,mode) (call_zopen64((&(filefunc)),(filename),(mode))) #define ZTELL64(filefunc,filestream) (call_ztell64((&(filefunc)),(filestream))) #define ZSEEK64(filefunc,filestream,pos,mode) (call_zseek64((&(filefunc)),(filestream),(pos),(mode))) #ifdef __cplusplus } #endif #endif httrack-3.49.5/src/minizip/ioapi.c.orig0000644000175000017500000001707414555200006014655 00000000000000/* ioapi.h -- IO base function header for compress/uncompress .zip part of the MiniZip project - ( http://www.winimage.com/zLibDll/minizip.html ) Copyright (C) 1998-2010 Gilles Vollant (minizip) ( http://www.winimage.com/zLibDll/minizip.html ) Modifications for Zip64 support Copyright (C) 2009-2010 Mathias Svensson ( http://result42.com ) For more info read MiniZip_info.txt */ #if defined(_WIN32) && (!(defined(_CRT_SECURE_NO_WARNINGS))) #define _CRT_SECURE_NO_WARNINGS #endif #if defined(__APPLE__) || defined(IOAPI_NO_64) || defined(__HAIKU__) || defined(MINIZIP_FOPEN_NO_64) // In darwin and perhaps other BSD variants off_t is a 64 bit value, hence no need for specific 64 bit functions #define FOPEN_FUNC(filename, mode) fopen(filename, mode) #define FTELLO_FUNC(stream) ftello(stream) #define FSEEKO_FUNC(stream, offset, origin) fseeko(stream, offset, origin) #else #define FOPEN_FUNC(filename, mode) fopen64(filename, mode) #define FTELLO_FUNC(stream) ftello64(stream) #define FSEEKO_FUNC(stream, offset, origin) fseeko64(stream, offset, origin) #endif #include "ioapi.h" voidpf call_zopen64 (const zlib_filefunc64_32_def* pfilefunc, const void*filename, int mode) { if (pfilefunc->zfile_func64.zopen64_file != NULL) return (*(pfilefunc->zfile_func64.zopen64_file)) (pfilefunc->zfile_func64.opaque,filename,mode); else { return (*(pfilefunc->zopen32_file))(pfilefunc->zfile_func64.opaque,(const char*)filename,mode); } } long call_zseek64 (const zlib_filefunc64_32_def* pfilefunc,voidpf filestream, ZPOS64_T offset, int origin) { if (pfilefunc->zfile_func64.zseek64_file != NULL) return (*(pfilefunc->zfile_func64.zseek64_file)) (pfilefunc->zfile_func64.opaque,filestream,offset,origin); else { uLong offsetTruncated = (uLong)offset; if (offsetTruncated != offset) return -1; else return (*(pfilefunc->zseek32_file))(pfilefunc->zfile_func64.opaque,filestream,offsetTruncated,origin); } } ZPOS64_T call_ztell64 (const zlib_filefunc64_32_def* pfilefunc, voidpf filestream) { if (pfilefunc->zfile_func64.zseek64_file != NULL) return (*(pfilefunc->zfile_func64.ztell64_file)) (pfilefunc->zfile_func64.opaque,filestream); else { uLong tell_uLong = (uLong)(*(pfilefunc->ztell32_file))(pfilefunc->zfile_func64.opaque,filestream); if ((tell_uLong) == MAXU32) return (ZPOS64_T)-1; else return tell_uLong; } } void fill_zlib_filefunc64_32_def_from_filefunc32(zlib_filefunc64_32_def* p_filefunc64_32, const zlib_filefunc_def* p_filefunc32) { p_filefunc64_32->zfile_func64.zopen64_file = NULL; p_filefunc64_32->zopen32_file = p_filefunc32->zopen_file; p_filefunc64_32->zfile_func64.zread_file = p_filefunc32->zread_file; p_filefunc64_32->zfile_func64.zwrite_file = p_filefunc32->zwrite_file; p_filefunc64_32->zfile_func64.ztell64_file = NULL; p_filefunc64_32->zfile_func64.zseek64_file = NULL; p_filefunc64_32->zfile_func64.zclose_file = p_filefunc32->zclose_file; p_filefunc64_32->zfile_func64.zerror_file = p_filefunc32->zerror_file; p_filefunc64_32->zfile_func64.opaque = p_filefunc32->opaque; p_filefunc64_32->zseek32_file = p_filefunc32->zseek_file; p_filefunc64_32->ztell32_file = p_filefunc32->ztell_file; } static voidpf ZCALLBACK fopen_file_func(voidpf opaque, const char* filename, int mode) { FILE* file = NULL; const char* mode_fopen = NULL; (void)opaque; if ((mode & ZLIB_FILEFUNC_MODE_READWRITEFILTER)==ZLIB_FILEFUNC_MODE_READ) mode_fopen = "rb"; else if (mode & ZLIB_FILEFUNC_MODE_EXISTING) mode_fopen = "r+b"; else if (mode & ZLIB_FILEFUNC_MODE_CREATE) mode_fopen = "wb"; if ((filename!=NULL) && (mode_fopen != NULL)) file = fopen(filename, mode_fopen); return file; } static voidpf ZCALLBACK fopen64_file_func(voidpf opaque, const void* filename, int mode) { FILE* file = NULL; const char* mode_fopen = NULL; (void)opaque; if ((mode & ZLIB_FILEFUNC_MODE_READWRITEFILTER)==ZLIB_FILEFUNC_MODE_READ) mode_fopen = "rb"; else if (mode & ZLIB_FILEFUNC_MODE_EXISTING) mode_fopen = "r+b"; else if (mode & ZLIB_FILEFUNC_MODE_CREATE) mode_fopen = "wb"; if ((filename!=NULL) && (mode_fopen != NULL)) file = FOPEN_FUNC((const char*)filename, mode_fopen); return file; } static uLong ZCALLBACK fread_file_func(voidpf opaque, voidpf stream, void* buf, uLong size) { uLong ret; (void)opaque; ret = (uLong)fread(buf, 1, (size_t)size, (FILE *)stream); return ret; } static uLong ZCALLBACK fwrite_file_func(voidpf opaque, voidpf stream, const void* buf, uLong size) { uLong ret; (void)opaque; ret = (uLong)fwrite(buf, 1, (size_t)size, (FILE *)stream); return ret; } static long ZCALLBACK ftell_file_func(voidpf opaque, voidpf stream) { long ret; (void)opaque; ret = ftell((FILE *)stream); return ret; } static ZPOS64_T ZCALLBACK ftell64_file_func(voidpf opaque, voidpf stream) { ZPOS64_T ret; (void)opaque; ret = (ZPOS64_T)FTELLO_FUNC((FILE *)stream); return ret; } static long ZCALLBACK fseek_file_func(voidpf opaque, voidpf stream, uLong offset, int origin) { int fseek_origin=0; long ret; (void)opaque; switch (origin) { case ZLIB_FILEFUNC_SEEK_CUR : fseek_origin = SEEK_CUR; break; case ZLIB_FILEFUNC_SEEK_END : fseek_origin = SEEK_END; break; case ZLIB_FILEFUNC_SEEK_SET : fseek_origin = SEEK_SET; break; default: return -1; } ret = 0; if (fseek((FILE *)stream, (long)offset, fseek_origin) != 0) ret = -1; return ret; } static long ZCALLBACK fseek64_file_func(voidpf opaque, voidpf stream, ZPOS64_T offset, int origin) { int fseek_origin=0; long ret; (void)opaque; switch (origin) { case ZLIB_FILEFUNC_SEEK_CUR : fseek_origin = SEEK_CUR; break; case ZLIB_FILEFUNC_SEEK_END : fseek_origin = SEEK_END; break; case ZLIB_FILEFUNC_SEEK_SET : fseek_origin = SEEK_SET; break; default: return -1; } ret = 0; if(FSEEKO_FUNC((FILE *)stream, (z_off64_t)offset, fseek_origin) != 0) ret = -1; return ret; } static int ZCALLBACK fclose_file_func(voidpf opaque, voidpf stream) { int ret; (void)opaque; ret = fclose((FILE *)stream); return ret; } static int ZCALLBACK ferror_file_func(voidpf opaque, voidpf stream) { int ret; (void)opaque; ret = ferror((FILE *)stream); return ret; } void fill_fopen_filefunc(zlib_filefunc_def* pzlib_filefunc_def) { pzlib_filefunc_def->zopen_file = fopen_file_func; pzlib_filefunc_def->zread_file = fread_file_func; pzlib_filefunc_def->zwrite_file = fwrite_file_func; pzlib_filefunc_def->ztell_file = ftell_file_func; pzlib_filefunc_def->zseek_file = fseek_file_func; pzlib_filefunc_def->zclose_file = fclose_file_func; pzlib_filefunc_def->zerror_file = ferror_file_func; pzlib_filefunc_def->opaque = NULL; } void fill_fopen64_filefunc(zlib_filefunc64_def* pzlib_filefunc_def) { pzlib_filefunc_def->zopen64_file = fopen64_file_func; pzlib_filefunc_def->zread_file = fread_file_func; pzlib_filefunc_def->zwrite_file = fwrite_file_func; pzlib_filefunc_def->ztell64_file = ftell64_file_func; pzlib_filefunc_def->zseek64_file = fseek64_file_func; pzlib_filefunc_def->zclose_file = fclose_file_func; pzlib_filefunc_def->zerror_file = ferror_file_func; pzlib_filefunc_def->opaque = NULL; } httrack-3.49.5/src/minizip/mztools.c.diff0000644000175000017500000000325014555201641015230 00000000000000--- mztools.c.orig 2024-01-27 14:07:18.636193212 +0100 +++ mztools.c 2024-01-27 14:09:55.356620093 +0100 @@ -10,6 +10,7 @@ #include #include "zlib.h" #include "unzip.h" +#include "mztools.h" #define READ_8(adr) ((unsigned char)*(adr)) #define READ_16(adr) ( READ_8(adr) | (READ_8(adr+1) << 8) ) @@ -141,8 +142,8 @@ /* Central directory entry */ { char header[46]; - char* comment = ""; - int comsize = (int) strlen(comment); + const char* comment = ""; + const size_t comsize = strlen(comment); WRITE_32(header, 0x02014b50); WRITE_16(header + 4, version); WRITE_16(header + 6, version); @@ -189,7 +190,7 @@ /* Comment field */ if (comsize > 0) { - if ((int)fwrite(comment, 1, comsize, fpOutCD) == comsize) { + if (fwrite(comment, 1, comsize, fpOutCD) == comsize) { offsetCD += comsize; } else { err = Z_ERRNO; @@ -216,8 +217,8 @@ { int entriesZip = entries; char header[22]; - char* comment = ""; // "ZIP File recovered by zlib/minizip/mztools"; - int comsize = (int) strlen(comment); + const char* comment = ""; // "ZIP File recovered by zlib/minizip/mztools"; + const size_t comsize = strlen(comment); if (entriesZip > 0xffff) { entriesZip = 0xffff; } @@ -235,7 +236,7 @@ /* Comment field */ if (comsize > 0) { - if ((int)fwrite(comment, 1, comsize, fpOutCD) != comsize) { + if (fwrite(comment, 1, comsize, fpOutCD) != comsize) { err = Z_ERRNO; } } httrack-3.49.5/src/minizip/zip.h.diff0000644000175000017500000000051614555201641014332 00000000000000--- zip.h.orig 2024-01-27 14:07:18.636193212 +0100 +++ zip.h 2024-01-27 14:10:04.104643731 +0100 @@ -313,6 +313,11 @@ Write data in the zipfile */ +extern int ZEXPORT zipFlush (zipFile file); +/* + Flush the zipfile output +*/ + extern int ZEXPORT zipCloseFileInZip(zipFile file); /* Close the current file in the zipfile httrack-3.49.5/src/minizip/zip.c.diff0000644000175000017500000000131414555201641014322 00000000000000--- zip.c.orig 2024-01-27 14:07:18.636193212 +0100 +++ zip.c 2024-01-27 14:09:59.736631926 +0100 @@ -1412,7 +1412,7 @@ else #endif { - zi->ci.stream.next_in = (Bytef*)(uintptr_t)buf; + zi->ci.stream.next_in = buf; zi->ci.stream.avail_in = len; while ((err==ZIP_OK) && (zi->ci.stream.avail_in>0)) @@ -1830,6 +1830,18 @@ return err; } +extern int ZEXPORT zipFlush (zipFile file) +{ + zip64_internal* zi; + + if (file == NULL) + return ZIP_PARAMERROR; + + zi = (zip64_internal*)file; + + return ZFLUSH64(zi->z_filefunc,zi->filestream); +} + extern int ZEXPORT zipClose(zipFile file, const char* global_comment) { zip64_internal* zi; int err = 0; httrack-3.49.5/src/minizip/ioapi.h.diff0000644000175000017500000000547714555201641014644 00000000000000--- ioapi.h.orig 2024-01-27 14:07:18.636193212 +0100 +++ ioapi.h 2024-01-27 14:09:46.028594897 +0100 @@ -21,6 +21,9 @@ #ifndef _ZLIBIOAPI64_H #define _ZLIBIOAPI64_H +#undef OF +#define OF(x) x + #if (!defined(_WIN32)) && (!defined(WIN32)) && (!defined(__APPLE__)) // Linux needs this to support file operation on files larger then 4+GB @@ -67,6 +70,24 @@ #endif #endif +/* As reported by sammyx, z_crc_t and z_const are not defined in pre-1.2.70 releases of zlib */ +/* See */ +#if ZLIB_VERNUM < 0x1270 + +#ifdef Z_U4 + typedef Z_U4 z_crc_t; +#else + typedef unsigned long z_crc_t; +#endif + +#if defined(ZLIB_CONST) && !defined(z_const) +# define z_const const +#else +# define z_const +#endif + +#endif + /* #ifndef ZPOS64_T #ifdef _WIN32 @@ -137,6 +158,7 @@ typedef voidpf (ZCALLBACK *open_file_func) (voidpf opaque, const char* filename, int mode); typedef uLong (ZCALLBACK *read_file_func) (voidpf opaque, voidpf stream, void* buf, uLong size); typedef uLong (ZCALLBACK *write_file_func) (voidpf opaque, voidpf stream, const void* buf, uLong size); +typedef int (ZCALLBACK *flush_file_func) (voidpf opaque, voidpf stream); typedef int (ZCALLBACK *close_file_func) (voidpf opaque, voidpf stream); typedef int (ZCALLBACK *testerror_file_func) (voidpf opaque, voidpf stream); @@ -150,6 +172,7 @@ open_file_func zopen_file; read_file_func zread_file; write_file_func zwrite_file; + flush_file_func zflush_file; tell_file_func ztell_file; seek_file_func zseek_file; close_file_func zclose_file; @@ -166,6 +189,7 @@ open64_file_func zopen64_file; read_file_func zread_file; write_file_func zwrite_file; + flush_file_func zflush_file; tell64_file_func ztell64_file; seek64_file_func zseek64_file; close_file_func zclose_file; @@ -188,6 +212,7 @@ #define ZREAD64(filefunc,filestream,buf,size) ((*((filefunc).zfile_func64.zread_file)) ((filefunc).zfile_func64.opaque,filestream,buf,size)) #define ZWRITE64(filefunc,filestream,buf,size) ((*((filefunc).zfile_func64.zwrite_file)) ((filefunc).zfile_func64.opaque,filestream,buf,size)) +#define ZFLUSH64(filefunc,filestream) ((*((filefunc).zfile_func64.zflush_file)) ((filefunc).zfile_func64.opaque,filestream)) //#define ZTELL64(filefunc,filestream) ((*((filefunc).ztell64_file)) ((filefunc).opaque,filestream)) //#define ZSEEK64(filefunc,filestream,pos,mode) ((*((filefunc).zseek64_file)) ((filefunc).opaque,filestream,pos,mode)) #define ZCLOSE64(filefunc,filestream) ((*((filefunc).zfile_func64.zclose_file)) ((filefunc).zfile_func64.opaque,filestream)) httrack-3.49.5/src/minizip/ioapi.c.diff0000644000175000017500000000421114555201641014620 00000000000000--- ioapi.c.orig 2024-01-27 14:07:18.636193212 +0100 +++ ioapi.c 2024-01-27 14:09:48.372601229 +0100 @@ -14,7 +14,7 @@ #define _CRT_SECURE_NO_WARNINGS #endif -#if defined(__APPLE__) || defined(IOAPI_NO_64) || defined(__HAIKU__) || defined(MINIZIP_FOPEN_NO_64) +#if defined(__APPLE__) || defined(__ANDROID__) || defined(IOAPI_NO_64) || defined(__HAIKU__) || defined(MINIZIP_FOPEN_NO_64) // In darwin and perhaps other BSD variants off_t is a 64 bit value, hence no need for specific 64 bit functions #define FOPEN_FUNC(filename, mode) fopen(filename, mode) #define FTELLO_FUNC(stream) ftello(stream) @@ -68,6 +68,7 @@ p_filefunc64_32->zopen32_file = p_filefunc32->zopen_file; p_filefunc64_32->zfile_func64.zread_file = p_filefunc32->zread_file; p_filefunc64_32->zfile_func64.zwrite_file = p_filefunc32->zwrite_file; + p_filefunc64_32->zfile_func64.zflush_file = p_filefunc32->zflush_file; p_filefunc64_32->zfile_func64.ztell64_file = NULL; p_filefunc64_32->zfile_func64.zseek64_file = NULL; p_filefunc64_32->zfile_func64.zclose_file = p_filefunc32->zclose_file; @@ -193,6 +194,12 @@ return ret; } +static int ZCALLBACK fflush_file_func (voidpf opaque, voidpf stream) +{ + int ret; + ret = fflush((FILE *)stream); + return ret; +} static int ZCALLBACK fclose_file_func(voidpf opaque, voidpf stream) { int ret; @@ -214,6 +221,7 @@ pzlib_filefunc_def->zwrite_file = fwrite_file_func; pzlib_filefunc_def->ztell_file = ftell_file_func; pzlib_filefunc_def->zseek_file = fseek_file_func; + pzlib_filefunc_def->zflush_file = fflush_file_func; pzlib_filefunc_def->zclose_file = fclose_file_func; pzlib_filefunc_def->zerror_file = ferror_file_func; pzlib_filefunc_def->opaque = NULL; @@ -225,6 +233,7 @@ pzlib_filefunc_def->zwrite_file = fwrite_file_func; pzlib_filefunc_def->ztell64_file = ftell64_file_func; pzlib_filefunc_def->zseek64_file = fseek64_file_func; + pzlib_filefunc_def->zflush_file = fflush_file_func; pzlib_filefunc_def->zclose_file = fclose_file_func; pzlib_filefunc_def->zerror_file = ferror_file_func; pzlib_filefunc_def->opaque = NULL; httrack-3.49.5/src/minizip/iowin32.h0000644000175000017500000000147714555200006014114 00000000000000/* iowin32.h -- IO base function header for compress/uncompress .zip Version 1.1, February 14h, 2010 part of the MiniZip project - ( http://www.winimage.com/zLibDll/minizip.html ) Copyright (C) 1998-2010 Gilles Vollant (minizip) ( http://www.winimage.com/zLibDll/minizip.html ) Modifications for Zip64 support Copyright (C) 2009-2010 Mathias Svensson ( http://result42.com ) For more info read MiniZip_info.txt */ #include #ifdef __cplusplus extern "C" { #endif void fill_win32_filefunc(zlib_filefunc_def* pzlib_filefunc_def); void fill_win32_filefunc64(zlib_filefunc64_def* pzlib_filefunc_def); void fill_win32_filefunc64A(zlib_filefunc64_def* pzlib_filefunc_def); void fill_win32_filefunc64W(zlib_filefunc64_def* pzlib_filefunc_def); #ifdef __cplusplus } #endif httrack-3.49.5/src/minizip/iowin32.c0000644000175000017500000003266514555200006014112 00000000000000/* iowin32.c -- IO base function header for compress/uncompress .zip Version 1.1, February 14h, 2010 part of the MiniZip project - ( http://www.winimage.com/zLibDll/minizip.html ) Copyright (C) 1998-2010 Gilles Vollant (minizip) ( http://www.winimage.com/zLibDll/minizip.html ) Modifications for Zip64 support Copyright (C) 2009-2010 Mathias Svensson ( http://result42.com ) For more info read MiniZip_info.txt */ #include #include "zlib.h" #include "ioapi.h" #include "iowin32.h" #ifndef INVALID_HANDLE_VALUE #define INVALID_HANDLE_VALUE (0xFFFFFFFF) #endif #ifndef INVALID_SET_FILE_POINTER #define INVALID_SET_FILE_POINTER ((DWORD)-1) #endif // see Include/shared/winapifamily.h in the Windows Kit #if defined(WINAPI_FAMILY_PARTITION) && (!(defined(IOWIN32_USING_WINRT_API))) #if !defined(WINAPI_FAMILY_ONE_PARTITION) #define WINAPI_FAMILY_ONE_PARTITION(PartitionSet, Partition) ((WINAPI_FAMILY & PartitionSet) == Partition) #endif #if WINAPI_FAMILY_ONE_PARTITION(WINAPI_FAMILY, WINAPI_PARTITION_APP) #define IOWIN32_USING_WINRT_API 1 #endif #endif typedef struct { HANDLE hf; int error; } WIN32FILE_IOWIN; static void win32_translate_open_mode(int mode, DWORD* lpdwDesiredAccess, DWORD* lpdwCreationDisposition, DWORD* lpdwShareMode, DWORD* lpdwFlagsAndAttributes) { *lpdwDesiredAccess = *lpdwShareMode = *lpdwFlagsAndAttributes = *lpdwCreationDisposition = 0; if ((mode & ZLIB_FILEFUNC_MODE_READWRITEFILTER)==ZLIB_FILEFUNC_MODE_READ) { *lpdwDesiredAccess = GENERIC_READ; *lpdwCreationDisposition = OPEN_EXISTING; *lpdwShareMode = FILE_SHARE_READ; } else if (mode & ZLIB_FILEFUNC_MODE_EXISTING) { *lpdwDesiredAccess = GENERIC_WRITE | GENERIC_READ; *lpdwCreationDisposition = OPEN_EXISTING; } else if (mode & ZLIB_FILEFUNC_MODE_CREATE) { *lpdwDesiredAccess = GENERIC_WRITE | GENERIC_READ; *lpdwCreationDisposition = CREATE_ALWAYS; } } static voidpf win32_build_iowin(HANDLE hFile) { voidpf ret=NULL; if ((hFile != NULL) && (hFile != INVALID_HANDLE_VALUE)) { WIN32FILE_IOWIN w32fiow; w32fiow.hf = hFile; w32fiow.error = 0; ret = malloc(sizeof(WIN32FILE_IOWIN)); if (ret==NULL) CloseHandle(hFile); else *((WIN32FILE_IOWIN*)ret) = w32fiow; } return ret; } voidpf ZCALLBACK win32_open64_file_func(voidpf opaque, const void* filename, int mode) { const char* mode_fopen = NULL; DWORD dwDesiredAccess,dwCreationDisposition,dwShareMode,dwFlagsAndAttributes ; HANDLE hFile = NULL; win32_translate_open_mode(mode,&dwDesiredAccess,&dwCreationDisposition,&dwShareMode,&dwFlagsAndAttributes); #ifdef IOWIN32_USING_WINRT_API #ifdef UNICODE if ((filename!=NULL) && (dwDesiredAccess != 0)) hFile = CreateFile2((LPCTSTR)filename, dwDesiredAccess, dwShareMode, dwCreationDisposition, NULL); #else if ((filename!=NULL) && (dwDesiredAccess != 0)) { WCHAR filenameW[FILENAME_MAX + 0x200 + 1]; MultiByteToWideChar(CP_ACP,0,(const char*)filename,-1,filenameW,FILENAME_MAX + 0x200); hFile = CreateFile2(filenameW, dwDesiredAccess, dwShareMode, dwCreationDisposition, NULL); } #endif #else if ((filename!=NULL) && (dwDesiredAccess != 0)) hFile = CreateFile((LPCTSTR)filename, dwDesiredAccess, dwShareMode, NULL, dwCreationDisposition, dwFlagsAndAttributes, NULL); #endif return win32_build_iowin(hFile); } voidpf ZCALLBACK win32_open64_file_funcA(voidpf opaque, const void* filename, int mode) { const char* mode_fopen = NULL; DWORD dwDesiredAccess,dwCreationDisposition,dwShareMode,dwFlagsAndAttributes ; HANDLE hFile = NULL; win32_translate_open_mode(mode,&dwDesiredAccess,&dwCreationDisposition,&dwShareMode,&dwFlagsAndAttributes); #ifdef IOWIN32_USING_WINRT_API if ((filename!=NULL) && (dwDesiredAccess != 0)) { WCHAR filenameW[FILENAME_MAX + 0x200 + 1]; MultiByteToWideChar(CP_ACP,0,(const char*)filename,-1,filenameW,FILENAME_MAX + 0x200); hFile = CreateFile2(filenameW, dwDesiredAccess, dwShareMode, dwCreationDisposition, NULL); } #else if ((filename!=NULL) && (dwDesiredAccess != 0)) hFile = CreateFileA((LPCSTR)filename, dwDesiredAccess, dwShareMode, NULL, dwCreationDisposition, dwFlagsAndAttributes, NULL); #endif return win32_build_iowin(hFile); } voidpf ZCALLBACK win32_open64_file_funcW(voidpf opaque, const void* filename, int mode) { const char* mode_fopen = NULL; DWORD dwDesiredAccess,dwCreationDisposition,dwShareMode,dwFlagsAndAttributes ; HANDLE hFile = NULL; win32_translate_open_mode(mode,&dwDesiredAccess,&dwCreationDisposition,&dwShareMode,&dwFlagsAndAttributes); #ifdef IOWIN32_USING_WINRT_API if ((filename!=NULL) && (dwDesiredAccess != 0)) hFile = CreateFile2((LPCWSTR)filename, dwDesiredAccess, dwShareMode, dwCreationDisposition,NULL); #else if ((filename!=NULL) && (dwDesiredAccess != 0)) hFile = CreateFileW((LPCWSTR)filename, dwDesiredAccess, dwShareMode, NULL, dwCreationDisposition, dwFlagsAndAttributes, NULL); #endif return win32_build_iowin(hFile); } voidpf ZCALLBACK win32_open_file_func(voidpf opaque, const char* filename, int mode) { const char* mode_fopen = NULL; DWORD dwDesiredAccess,dwCreationDisposition,dwShareMode,dwFlagsAndAttributes ; HANDLE hFile = NULL; win32_translate_open_mode(mode,&dwDesiredAccess,&dwCreationDisposition,&dwShareMode,&dwFlagsAndAttributes); #ifdef IOWIN32_USING_WINRT_API #ifdef UNICODE if ((filename!=NULL) && (dwDesiredAccess != 0)) hFile = CreateFile2((LPCTSTR)filename, dwDesiredAccess, dwShareMode, dwCreationDisposition, NULL); #else if ((filename!=NULL) && (dwDesiredAccess != 0)) { WCHAR filenameW[FILENAME_MAX + 0x200 + 1]; MultiByteToWideChar(CP_ACP,0,(const char*)filename,-1,filenameW,FILENAME_MAX + 0x200); hFile = CreateFile2(filenameW, dwDesiredAccess, dwShareMode, dwCreationDisposition, NULL); } #endif #else if ((filename!=NULL) && (dwDesiredAccess != 0)) hFile = CreateFile((LPCTSTR)filename, dwDesiredAccess, dwShareMode, NULL, dwCreationDisposition, dwFlagsAndAttributes, NULL); #endif return win32_build_iowin(hFile); } uLong ZCALLBACK win32_read_file_func(voidpf opaque, voidpf stream, void* buf,uLong size) { uLong ret=0; HANDLE hFile = NULL; if (stream!=NULL) hFile = ((WIN32FILE_IOWIN*)stream) -> hf; if (hFile != NULL) { if (!ReadFile(hFile, buf, size, &ret, NULL)) { DWORD dwErr = GetLastError(); if (dwErr == ERROR_HANDLE_EOF) dwErr = 0; ((WIN32FILE_IOWIN*)stream) -> error=(int)dwErr; } } return ret; } uLong ZCALLBACK win32_write_file_func(voidpf opaque, voidpf stream, const void* buf, uLong size) { uLong ret=0; HANDLE hFile = NULL; if (stream!=NULL) hFile = ((WIN32FILE_IOWIN*)stream) -> hf; if (hFile != NULL) { if (!WriteFile(hFile, buf, size, &ret, NULL)) { DWORD dwErr = GetLastError(); if (dwErr == ERROR_HANDLE_EOF) dwErr = 0; ((WIN32FILE_IOWIN*)stream) -> error=(int)dwErr; } } return ret; } static BOOL MySetFilePointerEx(HANDLE hFile, LARGE_INTEGER pos, LARGE_INTEGER *newPos, DWORD dwMoveMethod) { #ifdef IOWIN32_USING_WINRT_API return SetFilePointerEx(hFile, pos, newPos, dwMoveMethod); #else LONG lHigh = pos.HighPart; DWORD dwNewPos = SetFilePointer(hFile, pos.LowPart, &lHigh, dwMoveMethod); BOOL fOk = TRUE; if (dwNewPos == 0xFFFFFFFF) if (GetLastError() != NO_ERROR) fOk = FALSE; if ((newPos != NULL) && (fOk)) { newPos->LowPart = dwNewPos; newPos->HighPart = lHigh; } return fOk; #endif } long ZCALLBACK win32_tell_file_func(voidpf opaque, voidpf stream) { long ret=-1; HANDLE hFile = NULL; if (stream!=NULL) hFile = ((WIN32FILE_IOWIN*)stream) -> hf; if (hFile != NULL) { LARGE_INTEGER pos; pos.QuadPart = 0; if (!MySetFilePointerEx(hFile, pos, &pos, FILE_CURRENT)) { DWORD dwErr = GetLastError(); ((WIN32FILE_IOWIN*)stream) -> error=(int)dwErr; ret = -1; } else ret=(long)pos.LowPart; } return ret; } ZPOS64_T ZCALLBACK win32_tell64_file_func(voidpf opaque, voidpf stream) { ZPOS64_T ret= (ZPOS64_T)-1; HANDLE hFile = NULL; if (stream!=NULL) hFile = ((WIN32FILE_IOWIN*)stream)->hf; if (hFile) { LARGE_INTEGER pos; pos.QuadPart = 0; if (!MySetFilePointerEx(hFile, pos, &pos, FILE_CURRENT)) { DWORD dwErr = GetLastError(); ((WIN32FILE_IOWIN*)stream) -> error=(int)dwErr; ret = (ZPOS64_T)-1; } else ret=pos.QuadPart; } return ret; } long ZCALLBACK win32_seek_file_func(voidpf opaque, voidpf stream, uLong offset, int origin) { DWORD dwMoveMethod=0xFFFFFFFF; HANDLE hFile = NULL; long ret=-1; if (stream!=NULL) hFile = ((WIN32FILE_IOWIN*)stream) -> hf; switch (origin) { case ZLIB_FILEFUNC_SEEK_CUR : dwMoveMethod = FILE_CURRENT; break; case ZLIB_FILEFUNC_SEEK_END : dwMoveMethod = FILE_END; break; case ZLIB_FILEFUNC_SEEK_SET : dwMoveMethod = FILE_BEGIN; break; default: return -1; } if (hFile != NULL) { LARGE_INTEGER pos; pos.QuadPart = offset; if (!MySetFilePointerEx(hFile, pos, NULL, dwMoveMethod)) { DWORD dwErr = GetLastError(); ((WIN32FILE_IOWIN*)stream) -> error=(int)dwErr; ret = -1; } else ret=0; } return ret; } long ZCALLBACK win32_seek64_file_func(voidpf opaque, voidpf stream, ZPOS64_T offset, int origin) { DWORD dwMoveMethod=0xFFFFFFFF; HANDLE hFile = NULL; long ret=-1; if (stream!=NULL) hFile = ((WIN32FILE_IOWIN*)stream)->hf; switch (origin) { case ZLIB_FILEFUNC_SEEK_CUR : dwMoveMethod = FILE_CURRENT; break; case ZLIB_FILEFUNC_SEEK_END : dwMoveMethod = FILE_END; break; case ZLIB_FILEFUNC_SEEK_SET : dwMoveMethod = FILE_BEGIN; break; default: return -1; } if (hFile) { LARGE_INTEGER pos; pos.QuadPart = offset; if (!MySetFilePointerEx(hFile, pos, NULL, dwMoveMethod)) { DWORD dwErr = GetLastError(); ((WIN32FILE_IOWIN*)stream) -> error=(int)dwErr; ret = -1; } else ret=0; } return ret; } int ZCALLBACK win32_close_file_func(voidpf opaque, voidpf stream) { int ret=-1; if (stream!=NULL) { HANDLE hFile; hFile = ((WIN32FILE_IOWIN*)stream) -> hf; if (hFile != NULL) { CloseHandle(hFile); ret=0; } free(stream); } return ret; } int ZCALLBACK win32_error_file_func(voidpf opaque, voidpf stream) { int ret=-1; if (stream!=NULL) { ret = ((WIN32FILE_IOWIN*)stream) -> error; } return ret; } void fill_win32_filefunc(zlib_filefunc_def* pzlib_filefunc_def) { pzlib_filefunc_def->zopen_file = win32_open_file_func; pzlib_filefunc_def->zread_file = win32_read_file_func; pzlib_filefunc_def->zwrite_file = win32_write_file_func; pzlib_filefunc_def->ztell_file = win32_tell_file_func; pzlib_filefunc_def->zseek_file = win32_seek_file_func; pzlib_filefunc_def->zclose_file = win32_close_file_func; pzlib_filefunc_def->zerror_file = win32_error_file_func; pzlib_filefunc_def->opaque = NULL; } void fill_win32_filefunc64(zlib_filefunc64_def* pzlib_filefunc_def) { pzlib_filefunc_def->zopen64_file = win32_open64_file_func; pzlib_filefunc_def->zread_file = win32_read_file_func; pzlib_filefunc_def->zwrite_file = win32_write_file_func; pzlib_filefunc_def->ztell64_file = win32_tell64_file_func; pzlib_filefunc_def->zseek64_file = win32_seek64_file_func; pzlib_filefunc_def->zclose_file = win32_close_file_func; pzlib_filefunc_def->zerror_file = win32_error_file_func; pzlib_filefunc_def->opaque = NULL; } void fill_win32_filefunc64A(zlib_filefunc64_def* pzlib_filefunc_def) { pzlib_filefunc_def->zopen64_file = win32_open64_file_funcA; pzlib_filefunc_def->zread_file = win32_read_file_func; pzlib_filefunc_def->zwrite_file = win32_write_file_func; pzlib_filefunc_def->ztell64_file = win32_tell64_file_func; pzlib_filefunc_def->zseek64_file = win32_seek64_file_func; pzlib_filefunc_def->zclose_file = win32_close_file_func; pzlib_filefunc_def->zerror_file = win32_error_file_func; pzlib_filefunc_def->opaque = NULL; } void fill_win32_filefunc64W(zlib_filefunc64_def* pzlib_filefunc_def) { pzlib_filefunc_def->zopen64_file = win32_open64_file_funcW; pzlib_filefunc_def->zread_file = win32_read_file_func; pzlib_filefunc_def->zwrite_file = win32_write_file_func; pzlib_filefunc_def->ztell64_file = win32_tell64_file_func; pzlib_filefunc_def->zseek64_file = win32_seek64_file_func; pzlib_filefunc_def->zclose_file = win32_close_file_func; pzlib_filefunc_def->zerror_file = win32_error_file_func; pzlib_filefunc_def->opaque = NULL; } httrack-3.49.5/src/minizip/zip.h0000644000175000017500000003635314555201641013433 00000000000000/* zip.h -- IO on .zip files using zlib Version 1.1, February 14h, 2010 part of the MiniZip project - ( http://www.winimage.com/zLibDll/minizip.html ) Copyright (C) 1998-2010 Gilles Vollant (minizip) ( http://www.winimage.com/zLibDll/minizip.html ) Modifications for Zip64 support Copyright (C) 2009-2010 Mathias Svensson ( http://result42.com ) For more info read MiniZip_info.txt --------------------------------------------------------------------------- Condition of use and distribution are the same than zlib : This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions: 1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required. 2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software. 3. This notice may not be removed or altered from any source distribution. --------------------------------------------------------------------------- Changes See header of zip.h */ #ifndef _zip12_H #define _zip12_H #ifdef __cplusplus extern "C" { #endif //#define HAVE_BZIP2 #ifndef _ZLIB_H #include "zlib.h" #endif #ifndef _ZLIBIOAPI_H #include "ioapi.h" #endif #ifdef HAVE_BZIP2 #include "bzlib.h" #endif #define Z_BZIP2ED 12 #if defined(STRICTZIP) || defined(STRICTZIPUNZIP) /* like the STRICT of WIN32, we define a pointer that cannot be converted from (void*) without cast */ typedef struct TagzipFile__ { int unused; } zipFile__; typedef zipFile__ *zipFile; #else typedef voidp zipFile; #endif #define ZIP_OK (0) #define ZIP_EOF (0) #define ZIP_ERRNO (Z_ERRNO) #define ZIP_PARAMERROR (-102) #define ZIP_BADZIPFILE (-103) #define ZIP_INTERNALERROR (-104) #ifndef DEF_MEM_LEVEL # if MAX_MEM_LEVEL >= 8 # define DEF_MEM_LEVEL 8 # else # define DEF_MEM_LEVEL MAX_MEM_LEVEL # endif #endif /* default memLevel */ /* tm_zip contain date/time info */ typedef struct tm_zip_s { int tm_sec; /* seconds after the minute - [0,59] */ int tm_min; /* minutes after the hour - [0,59] */ int tm_hour; /* hours since midnight - [0,23] */ int tm_mday; /* day of the month - [1,31] */ int tm_mon; /* months since January - [0,11] */ int tm_year; /* years - [1980..2044] */ } tm_zip; typedef struct { tm_zip tmz_date; /* date in understandable format */ uLong dosDate; /* if dos_date == 0, tmu_date is used */ /* uLong flag; */ /* general purpose bit flag 2 bytes */ uLong internal_fa; /* internal file attributes 2 bytes */ uLong external_fa; /* external file attributes 4 bytes */ } zip_fileinfo; typedef const char* zipcharpc; #define APPEND_STATUS_CREATE (0) #define APPEND_STATUS_CREATEAFTER (1) #define APPEND_STATUS_ADDINZIP (2) extern zipFile ZEXPORT zipOpen(const char *pathname, int append); extern zipFile ZEXPORT zipOpen64(const void *pathname, int append); /* Create a zipfile. pathname contain on Windows XP a filename like "c:\\zlib\\zlib113.zip" or on an Unix computer "zlib/zlib113.zip". if the file pathname exist and append==APPEND_STATUS_CREATEAFTER, the zip will be created at the end of the file. (useful if the file contain a self extractor code) if the file pathname exist and append==APPEND_STATUS_ADDINZIP, we will add files in existing zip (be sure you don't add file that doesn't exist) If the zipfile cannot be opened, the return value is NULL. Else, the return value is a zipFile Handle, usable with other function of this zip package. */ /* Note : there is no delete function into a zipfile. If you want delete file into a zipfile, you must open a zipfile, and create another Of course, you can use RAW reading and writing to copy the file you did not want delete */ extern zipFile ZEXPORT zipOpen2(const char *pathname, int append, zipcharpc* globalcomment, zlib_filefunc_def* pzlib_filefunc_def); extern zipFile ZEXPORT zipOpen2_64(const void *pathname, int append, zipcharpc* globalcomment, zlib_filefunc64_def* pzlib_filefunc_def); extern zipFile ZEXPORT zipOpen3(const void *pathname, int append, zipcharpc* globalcomment, zlib_filefunc64_32_def* pzlib_filefunc64_32_def); extern int ZEXPORT zipOpenNewFileInZip(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level); extern int ZEXPORT zipOpenNewFileInZip64(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int zip64); /* Open a file in the ZIP for writing. filename : the filename in zip (if NULL, '-' without quote will be used *zipfi contain supplemental information if extrafield_local!=NULL and size_extrafield_local>0, extrafield_local contains the extrafield data for the local header if extrafield_global!=NULL and size_extrafield_global>0, extrafield_global contains the extrafield data for the global header if comment != NULL, comment contain the comment string method contain the compression method (0 for store, Z_DEFLATED for deflate) level contain the level of compression (can be Z_DEFAULT_COMPRESSION) zip64 is set to 1 if a zip64 extended information block should be added to the local file header. this MUST be '1' if the uncompressed size is >= 0xffffffff. */ extern int ZEXPORT zipOpenNewFileInZip2(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int raw); extern int ZEXPORT zipOpenNewFileInZip2_64(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int raw, int zip64); /* Same than zipOpenNewFileInZip, except if raw=1, we write raw file */ extern int ZEXPORT zipOpenNewFileInZip3(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int raw, int windowBits, int memLevel, int strategy, const char* password, uLong crcForCrypting); extern int ZEXPORT zipOpenNewFileInZip3_64(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int raw, int windowBits, int memLevel, int strategy, const char* password, uLong crcForCrypting, int zip64); /* Same than zipOpenNewFileInZip2, except windowBits,memLevel,,strategy : see parameter strategy in deflateInit2 password : crypting password (NULL for no crypting) crcForCrypting : crc of file to compress (needed for crypting) */ extern int ZEXPORT zipOpenNewFileInZip4(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int raw, int windowBits, int memLevel, int strategy, const char* password, uLong crcForCrypting, uLong versionMadeBy, uLong flagBase); extern int ZEXPORT zipOpenNewFileInZip4_64(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int raw, int windowBits, int memLevel, int strategy, const char* password, uLong crcForCrypting, uLong versionMadeBy, uLong flagBase, int zip64); /* Same than zipOpenNewFileInZip4, except versionMadeBy : value for Version made by field flag : value for flag field (compression level info will be added) */ extern int ZEXPORT zipWriteInFileInZip(zipFile file, const void* buf, unsigned len); /* Write data in the zipfile */ extern int ZEXPORT zipFlush (zipFile file); /* Flush the zipfile output */ extern int ZEXPORT zipCloseFileInZip(zipFile file); /* Close the current file in the zipfile */ extern int ZEXPORT zipCloseFileInZipRaw(zipFile file, uLong uncompressed_size, uLong crc32); extern int ZEXPORT zipCloseFileInZipRaw64(zipFile file, ZPOS64_T uncompressed_size, uLong crc32); /* Close the current file in the zipfile, for file opened with parameter raw=1 in zipOpenNewFileInZip2 uncompressed_size and crc32 are value for the uncompressed size */ extern int ZEXPORT zipClose(zipFile file, const char* global_comment); /* Close the zipfile */ extern int ZEXPORT zipRemoveExtraInfoBlock(char* pData, int* dataLen, short sHeader); /* zipRemoveExtraInfoBlock - Added by Mathias Svensson Remove extra information block from a extra information data for the local file header or central directory header It is needed to remove ZIP64 extra information blocks when before data is written if using RAW mode. 0x0001 is the signature header for the ZIP64 extra information blocks usage. Remove ZIP64 Extra information from a central director extra field data zipRemoveExtraInfoBlock(pCenDirExtraFieldData, &nCenDirExtraFieldDataLen, 0x0001); Remove ZIP64 Extra information from a Local File Header extra field data zipRemoveExtraInfoBlock(pLocalHeaderExtraFieldData, &nLocalHeaderExtraFieldDataLen, 0x0001); */ #ifdef __cplusplus } #endif #endif /* _zip64_H */ httrack-3.49.5/src/minizip/unzip.h0000644000175000017500000004010014555201641013757 00000000000000/* unzip.h -- IO for uncompress .zip files using zlib Version 1.1, February 14h, 2010 part of the MiniZip project - ( http://www.winimage.com/zLibDll/minizip.html ) Copyright (C) 1998-2010 Gilles Vollant (minizip) ( http://www.winimage.com/zLibDll/minizip.html ) Modifications of Unzip for Zip64 Copyright (C) 2007-2008 Even Rouault Modifications for Zip64 support on both zip and unzip Copyright (C) 2009-2010 Mathias Svensson ( http://result42.com ) For more info read MiniZip_info.txt --------------------------------------------------------------------------------- Condition of use and distribution are the same than zlib : This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions: 1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required. 2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software. 3. This notice may not be removed or altered from any source distribution. --------------------------------------------------------------------------------- Changes See header of unzip64.c */ #ifndef _unz64_H #define _unz64_H #ifdef __cplusplus extern "C" { #endif #ifndef _ZLIB_H #include "zlib.h" #endif #ifndef _ZLIBIOAPI_H #include "ioapi.h" #endif #ifdef HAVE_BZIP2 #include "bzlib.h" #endif #define Z_BZIP2ED 12 #if defined(STRICTUNZIP) || defined(STRICTZIPUNZIP) /* like the STRICT of WIN32, we define a pointer that cannot be converted from (void*) without cast */ typedef struct TagunzFile__ { int unused; } unzFile__; typedef unzFile__ *unzFile; #else typedef voidp unzFile; #endif #define UNZ_OK (0) #define UNZ_END_OF_LIST_OF_FILE (-100) #define UNZ_ERRNO (Z_ERRNO) #define UNZ_EOF (0) #define UNZ_PARAMERROR (-102) #define UNZ_BADZIPFILE (-103) #define UNZ_INTERNALERROR (-104) #define UNZ_CRCERROR (-105) /* tm_unz contain date/time info */ typedef struct tm_unz_s { int tm_sec; /* seconds after the minute - [0,59] */ int tm_min; /* minutes after the hour - [0,59] */ int tm_hour; /* hours since midnight - [0,23] */ int tm_mday; /* day of the month - [1,31] */ int tm_mon; /* months since January - [0,11] */ int tm_year; /* years - [1980..2044] */ } tm_unz; /* unz_global_info structure contain global data about the ZIPfile These data comes from the end of central dir */ typedef struct unz_global_info64_s { ZPOS64_T number_entry; /* total number of entries in the central dir on this disk */ uLong size_comment; /* size of the global comment of the zipfile */ } unz_global_info64; typedef struct unz_global_info_s { uLong number_entry; /* total number of entries in the central dir on this disk */ uLong size_comment; /* size of the global comment of the zipfile */ } unz_global_info; /* unz_file_info contain information about a file in the zipfile */ typedef struct unz_file_info64_s { uLong version; /* version made by 2 bytes */ uLong version_needed; /* version needed to extract 2 bytes */ uLong flag; /* general purpose bit flag 2 bytes */ uLong compression_method; /* compression method 2 bytes */ uLong dosDate; /* last mod file date in Dos fmt 4 bytes */ uLong crc; /* crc-32 4 bytes */ ZPOS64_T compressed_size; /* compressed size 8 bytes */ ZPOS64_T uncompressed_size; /* uncompressed size 8 bytes */ uLong size_filename; /* filename length 2 bytes */ uLong size_file_extra; /* extra field length 2 bytes */ uLong size_file_comment; /* file comment length 2 bytes */ uLong disk_num_start; /* disk number start 2 bytes */ uLong internal_fa; /* internal file attributes 2 bytes */ uLong external_fa; /* external file attributes 4 bytes */ tm_unz tmu_date; } unz_file_info64; typedef struct unz_file_info_s { uLong version; /* version made by 2 bytes */ uLong version_needed; /* version needed to extract 2 bytes */ uLong flag; /* general purpose bit flag 2 bytes */ uLong compression_method; /* compression method 2 bytes */ uLong dosDate; /* last mod file date in Dos fmt 4 bytes */ uLong crc; /* crc-32 4 bytes */ uLong compressed_size; /* compressed size 4 bytes */ uLong uncompressed_size; /* uncompressed size 4 bytes */ uLong size_filename; /* filename length 2 bytes */ uLong size_file_extra; /* extra field length 2 bytes */ uLong size_file_comment; /* file comment length 2 bytes */ uLong disk_num_start; /* disk number start 2 bytes */ uLong internal_fa; /* internal file attributes 2 bytes */ uLong external_fa; /* external file attributes 4 bytes */ tm_unz tmu_date; } unz_file_info; extern int ZEXPORT unzStringFileNameCompare(const char* fileName1, const char* fileName2, int iCaseSensitivity); /* Compare two filenames (fileName1,fileName2). If iCaseSensitivity = 1, comparison is case sensitive (like strcmp) If iCaseSensitivity = 2, comparison is not case sensitive (like strcmpi or strcasecmp) If iCaseSensitivity = 0, case sensitivity is default of your operating system (like 1 on Unix, 2 on Windows) */ extern unzFile ZEXPORT unzOpen(const char *path); extern unzFile ZEXPORT unzOpen64(const void *path); /* Open a Zip file. path contain the full pathname (by example, on a Windows XP computer "c:\\zlib\\zlib113.zip" or on an Unix computer "zlib/zlib113.zip". If the zipfile cannot be opened (file don't exist or in not valid), the return value is NULL. Else, the return value is a unzFile Handle, usable with other function of this unzip package. the "64" function take a const void* pointer, because the path is just the value passed to the open64_file_func callback. Under Windows, if UNICODE is defined, using fill_fopen64_filefunc, the path is a pointer to a wide unicode string (LPCTSTR is LPCWSTR), so const char* does not describe the reality */ extern unzFile ZEXPORT unzOpen2(const char *path, zlib_filefunc_def* pzlib_filefunc_def); /* Open a Zip file, like unzOpen, but provide a set of file low level API for read/write the zip file (see ioapi.h) */ extern unzFile ZEXPORT unzOpen2_64(const void *path, zlib_filefunc64_def* pzlib_filefunc_def); /* Open a Zip file, like unz64Open, but provide a set of file low level API for read/write the zip file (see ioapi.h) */ extern int ZEXPORT unzClose(unzFile file); /* Close a ZipFile opened with unzOpen. If there is files inside the .Zip opened with unzOpenCurrentFile (see later), these files MUST be closed with unzCloseCurrentFile before call unzClose. return UNZ_OK if there is no problem. */ extern int ZEXPORT unzGetGlobalInfo(unzFile file, unz_global_info *pglobal_info); extern int ZEXPORT unzGetGlobalInfo64(unzFile file, unz_global_info64 *pglobal_info); /* Write info about the ZipFile in the *pglobal_info structure. No preparation of the structure is needed return UNZ_OK if there is no problem. */ extern int ZEXPORT unzGetGlobalComment(unzFile file, char *szComment, uLong uSizeBuf); /* Get the global comment string of the ZipFile, in the szComment buffer. uSizeBuf is the size of the szComment buffer. return the number of byte copied or an error code <0 */ /***************************************************************************/ /* Unzip package allow you browse the directory of the zipfile */ extern int ZEXPORT unzGoToFirstFile(unzFile file); /* Set the current file of the zipfile to the first file. return UNZ_OK if there is no problem */ extern int ZEXPORT unzGoToNextFile(unzFile file); /* Set the current file of the zipfile to the next file. return UNZ_OK if there is no problem return UNZ_END_OF_LIST_OF_FILE if the actual file was the latest. */ extern int ZEXPORT unzLocateFile(unzFile file, const char *szFileName, int iCaseSensitivity); /* Try locate the file szFileName in the zipfile. For the iCaseSensitivity signification, see unzStringFileNameCompare return value : UNZ_OK if the file is found. It becomes the current file. UNZ_END_OF_LIST_OF_FILE if the file is not found */ /* ****************************************** */ /* Ryan supplied functions */ /* unz_file_info contain information about a file in the zipfile */ typedef struct unz_file_pos_s { uLong pos_in_zip_directory; /* offset in zip file directory */ uLong num_of_file; /* # of file */ } unz_file_pos; extern int ZEXPORT unzGetFilePos( unzFile file, unz_file_pos* file_pos); extern int ZEXPORT unzGoToFilePos( unzFile file, unz_file_pos* file_pos); typedef struct unz64_file_pos_s { ZPOS64_T pos_in_zip_directory; /* offset in zip file directory */ ZPOS64_T num_of_file; /* # of file */ } unz64_file_pos; extern int ZEXPORT unzGetFilePos64( unzFile file, unz64_file_pos* file_pos); extern int ZEXPORT unzGoToFilePos64( unzFile file, const unz64_file_pos* file_pos); /* ****************************************** */ extern int ZEXPORT unzGetCurrentFileInfo64(unzFile file, unz_file_info64 *pfile_info, char *szFileName, uLong fileNameBufferSize, void *extraField, uLong extraFieldBufferSize, char *szComment, uLong commentBufferSize); extern int ZEXPORT unzGetCurrentFileInfo(unzFile file, unz_file_info *pfile_info, char *szFileName, uLong fileNameBufferSize, void *extraField, uLong extraFieldBufferSize, char *szComment, uLong commentBufferSize); /* Get Info about the current file if pfile_info!=NULL, the *pfile_info structure will contain some info about the current file if szFileName!=NULL, the filename string will be copied in szFileName (fileNameBufferSize is the size of the buffer) if extraField!=NULL, the extra field information will be copied in extraField (extraFieldBufferSize is the size of the buffer). This is the Central-header version of the extra field if szComment!=NULL, the comment string of the file will be copied in szComment (commentBufferSize is the size of the buffer) */ /** Addition for GDAL : START */ extern ZPOS64_T ZEXPORT unzGetCurrentFileZStreamPos64(unzFile file); /** Addition for GDAL : END */ /***************************************************************************/ /* for reading the content of the current zipfile, you can open it, read data from it, and close it (you can close it before reading all the file) */ extern int ZEXPORT unzOpenCurrentFile(unzFile file); /* Open for reading data the current file in the zipfile. If there is no error, the return value is UNZ_OK. */ extern int ZEXPORT unzOpenCurrentFilePassword(unzFile file, const char* password); /* Open for reading data the current file in the zipfile. password is a crypting password If there is no error, the return value is UNZ_OK. */ extern int ZEXPORT unzOpenCurrentFile2(unzFile file, int* method, int* level, int raw); /* Same than unzOpenCurrentFile, but open for read raw the file (not uncompress) if raw==1 *method will receive method of compression, *level will receive level of compression note : you can set level parameter as NULL (if you did not want known level, but you CANNOT set method parameter as NULL */ extern int ZEXPORT unzOpenCurrentFile3(unzFile file, int* method, int* level, int raw, const char* password); /* Same than unzOpenCurrentFile, but open for read raw the file (not uncompress) if raw==1 *method will receive method of compression, *level will receive level of compression note : you can set level parameter as NULL (if you did not want known level, but you CANNOT set method parameter as NULL */ extern int ZEXPORT unzCloseCurrentFile(unzFile file); /* Close the file in zip opened with unzOpenCurrentFile Return UNZ_CRCERROR if all the file was read but the CRC is not good */ extern int ZEXPORT unzReadCurrentFile(unzFile file, voidp buf, unsigned len); /* Read bytes from the current file (opened by unzOpenCurrentFile) buf contain buffer where data must be copied len the size of buf. return the number of byte copied if some bytes are copied return 0 if the end of file was reached return <0 with error code if there is an error (UNZ_ERRNO for IO error, or zLib error for uncompress error) */ extern z_off_t ZEXPORT unztell(unzFile file); extern ZPOS64_T ZEXPORT unztell64(unzFile file); /* Give the current position in uncompressed data */ extern int ZEXPORT unzeof(unzFile file); /* return 1 if the end of file was reached, 0 elsewhere */ extern int ZEXPORT unzGetLocalExtrafield(unzFile file, voidp buf, unsigned len); /* Read extra field from the current file (opened by unzOpenCurrentFile) This is the local-header version of the extra field (sometimes, there is more info in the local-header version than in the central-header) if buf==NULL, it return the size of the local extra field if buf!=NULL, len is the size of the buffer, the extra header is copied in buf. the return value is the number of bytes copied in buf, or (if <0) the error code */ /***************************************************************************/ /* Get the current file offset */ extern ZPOS64_T ZEXPORT unzGetOffset64 (unzFile file); extern uLong ZEXPORT unzGetOffset (unzFile file); /* Set the current file offset */ extern int ZEXPORT unzSetOffset64 (unzFile file, ZPOS64_T pos); extern int ZEXPORT unzSetOffset (unzFile file, uLong pos); #ifdef __cplusplus } #endif #endif /* _unz64_H */ httrack-3.49.5/src/minizip/mztools.h0000644000175000017500000000130414555200006014316 00000000000000/* Additional tools for Minizip Code: Xavier Roche '2004 License: Same as ZLIB (www.gzip.org) */ #ifndef _zip_tools_H #define _zip_tools_H #ifdef __cplusplus extern "C" { #endif #ifndef _ZLIB_H #include "zlib.h" #endif #include "unzip.h" /* Repair a ZIP file (missing central directory) file: file to recover fileOut: output file after recovery fileOutTmp: temporary file name used for recovery */ extern int ZEXPORT unzRepair(const char* file, const char* fileOut, const char* fileOutTmp, uLong* nRecovered, uLong* bytesRecovered); #ifdef __cplusplus } #endif #endif httrack-3.49.5/src/minizip/ioapi.h0000644000175000017500000001727614555201641013735 00000000000000/* ioapi.h -- IO base function header for compress/uncompress .zip part of the MiniZip project - ( http://www.winimage.com/zLibDll/minizip.html ) Copyright (C) 1998-2010 Gilles Vollant (minizip) ( http://www.winimage.com/zLibDll/minizip.html ) Modifications for Zip64 support Copyright (C) 2009-2010 Mathias Svensson ( http://result42.com ) For more info read MiniZip_info.txt Changes Oct-2009 - Defined ZPOS64_T to fpos_t on windows and u_int64_t on linux. (might need to find a better why for this) Oct-2009 - Change to fseeko64, ftello64 and fopen64 so large files would work on linux. More if/def section may be needed to support other platforms Oct-2009 - Defined fxxxx64 calls to normal fopen/ftell/fseek so they would compile on windows. (but you should use iowin32.c for windows instead) */ #ifndef _ZLIBIOAPI64_H #define _ZLIBIOAPI64_H #undef OF #define OF(x) x #if (!defined(_WIN32)) && (!defined(WIN32)) && (!defined(__APPLE__)) // Linux needs this to support file operation on files larger then 4+GB // But might need better if/def to select just the platforms that needs them. #ifndef __USE_FILE_OFFSET64 #define __USE_FILE_OFFSET64 #endif #ifndef __USE_LARGEFILE64 #define __USE_LARGEFILE64 #endif #ifndef _LARGEFILE64_SOURCE #define _LARGEFILE64_SOURCE #endif #ifndef _FILE_OFFSET_BIT #define _FILE_OFFSET_BIT 64 #endif #endif #include #include #include "zlib.h" #if defined(USE_FILE32API) #define fopen64 fopen #define ftello64 ftell #define fseeko64 fseek #else #if defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__HAIKU__) || defined(MINIZIP_FOPEN_NO_64) #define fopen64 fopen #define ftello64 ftello #define fseeko64 fseeko #endif #ifdef _MSC_VER #define fopen64 fopen #if (_MSC_VER >= 1400) && (!(defined(NO_MSCVER_FILE64_FUNC))) #define ftello64 _ftelli64 #define fseeko64 _fseeki64 #else // old MSC #define ftello64 ftell #define fseeko64 fseek #endif #endif #endif /* As reported by sammyx, z_crc_t and z_const are not defined in pre-1.2.70 releases of zlib */ /* See */ #if ZLIB_VERNUM < 0x1270 #ifdef Z_U4 typedef Z_U4 z_crc_t; #else typedef unsigned long z_crc_t; #endif #if defined(ZLIB_CONST) && !defined(z_const) # define z_const const #else # define z_const #endif #endif /* #ifndef ZPOS64_T #ifdef _WIN32 #define ZPOS64_T fpos_t #else #include #define ZPOS64_T uint64_t #endif #endif */ #ifdef HAVE_MINIZIP64_CONF_H #include "mz64conf.h" #endif /* a type chosen by DEFINE */ #ifdef HAVE_64BIT_INT_CUSTOM typedef 64BIT_INT_CUSTOM_TYPE ZPOS64_T; #else #ifdef HAS_STDINT_H #include "stdint.h" typedef uint64_t ZPOS64_T; #else #if defined(_MSC_VER) || defined(__BORLANDC__) typedef unsigned __int64 ZPOS64_T; #else typedef unsigned long long int ZPOS64_T; #endif #endif #endif /* Maximum unsigned 32-bit value used as placeholder for zip64 */ #ifndef MAXU32 #define MAXU32 (0xffffffff) #endif #ifdef __cplusplus extern "C" { #endif #define ZLIB_FILEFUNC_SEEK_CUR (1) #define ZLIB_FILEFUNC_SEEK_END (2) #define ZLIB_FILEFUNC_SEEK_SET (0) #define ZLIB_FILEFUNC_MODE_READ (1) #define ZLIB_FILEFUNC_MODE_WRITE (2) #define ZLIB_FILEFUNC_MODE_READWRITEFILTER (3) #define ZLIB_FILEFUNC_MODE_EXISTING (4) #define ZLIB_FILEFUNC_MODE_CREATE (8) #ifndef ZCALLBACK #if (defined(WIN32) || defined(_WIN32) || defined (WINDOWS) || defined (_WINDOWS)) && defined(CALLBACK) && defined (USEWINDOWS_CALLBACK) #define ZCALLBACK CALLBACK #else #define ZCALLBACK #endif #endif typedef voidpf (ZCALLBACK *open_file_func) (voidpf opaque, const char* filename, int mode); typedef uLong (ZCALLBACK *read_file_func) (voidpf opaque, voidpf stream, void* buf, uLong size); typedef uLong (ZCALLBACK *write_file_func) (voidpf opaque, voidpf stream, const void* buf, uLong size); typedef int (ZCALLBACK *flush_file_func) (voidpf opaque, voidpf stream); typedef int (ZCALLBACK *close_file_func) (voidpf opaque, voidpf stream); typedef int (ZCALLBACK *testerror_file_func) (voidpf opaque, voidpf stream); typedef long (ZCALLBACK *tell_file_func) (voidpf opaque, voidpf stream); typedef long (ZCALLBACK *seek_file_func) (voidpf opaque, voidpf stream, uLong offset, int origin); /* here is the "old" 32 bits structure */ typedef struct zlib_filefunc_def_s { open_file_func zopen_file; read_file_func zread_file; write_file_func zwrite_file; flush_file_func zflush_file; tell_file_func ztell_file; seek_file_func zseek_file; close_file_func zclose_file; testerror_file_func zerror_file; voidpf opaque; } zlib_filefunc_def; typedef ZPOS64_T (ZCALLBACK *tell64_file_func) (voidpf opaque, voidpf stream); typedef long (ZCALLBACK *seek64_file_func) (voidpf opaque, voidpf stream, ZPOS64_T offset, int origin); typedef voidpf (ZCALLBACK *open64_file_func) (voidpf opaque, const void* filename, int mode); typedef struct zlib_filefunc64_def_s { open64_file_func zopen64_file; read_file_func zread_file; write_file_func zwrite_file; flush_file_func zflush_file; tell64_file_func ztell64_file; seek64_file_func zseek64_file; close_file_func zclose_file; testerror_file_func zerror_file; voidpf opaque; } zlib_filefunc64_def; void fill_fopen64_filefunc(zlib_filefunc64_def* pzlib_filefunc_def); void fill_fopen_filefunc(zlib_filefunc_def* pzlib_filefunc_def); /* now internal definition, only for zip.c and unzip.h */ typedef struct zlib_filefunc64_32_def_s { zlib_filefunc64_def zfile_func64; open_file_func zopen32_file; tell_file_func ztell32_file; seek_file_func zseek32_file; } zlib_filefunc64_32_def; #define ZREAD64(filefunc,filestream,buf,size) ((*((filefunc).zfile_func64.zread_file)) ((filefunc).zfile_func64.opaque,filestream,buf,size)) #define ZWRITE64(filefunc,filestream,buf,size) ((*((filefunc).zfile_func64.zwrite_file)) ((filefunc).zfile_func64.opaque,filestream,buf,size)) #define ZFLUSH64(filefunc,filestream) ((*((filefunc).zfile_func64.zflush_file)) ((filefunc).zfile_func64.opaque,filestream)) //#define ZTELL64(filefunc,filestream) ((*((filefunc).ztell64_file)) ((filefunc).opaque,filestream)) //#define ZSEEK64(filefunc,filestream,pos,mode) ((*((filefunc).zseek64_file)) ((filefunc).opaque,filestream,pos,mode)) #define ZCLOSE64(filefunc,filestream) ((*((filefunc).zfile_func64.zclose_file)) ((filefunc).zfile_func64.opaque,filestream)) #define ZERROR64(filefunc,filestream) ((*((filefunc).zfile_func64.zerror_file)) ((filefunc).zfile_func64.opaque,filestream)) voidpf call_zopen64(const zlib_filefunc64_32_def* pfilefunc,const void*filename,int mode); long call_zseek64(const zlib_filefunc64_32_def* pfilefunc,voidpf filestream, ZPOS64_T offset, int origin); ZPOS64_T call_ztell64(const zlib_filefunc64_32_def* pfilefunc,voidpf filestream); void fill_zlib_filefunc64_32_def_from_filefunc32(zlib_filefunc64_32_def* p_filefunc64_32,const zlib_filefunc_def* p_filefunc32); #define ZOPEN64(filefunc,filename,mode) (call_zopen64((&(filefunc)),(filename),(mode))) #define ZTELL64(filefunc,filestream) (call_ztell64((&(filefunc)),(filestream))) #define ZSEEK64(filefunc,filestream,pos,mode) (call_zseek64((&(filefunc)),(filestream),(pos),(mode))) #ifdef __cplusplus } #endif #endif httrack-3.49.5/src/minizip/crypt.h0000644000175000017500000001130114555200006013746 00000000000000/* crypt.h -- base code for crypt/uncrypt ZIPfile Version 1.01e, February 12th, 2005 Copyright (C) 1998-2005 Gilles Vollant This code is a modified version of crypting code in Infozip distribution The encryption/decryption parts of this source code (as opposed to the non-echoing password parts) were originally written in Europe. The whole source package can be freely distributed, including from the USA. (Prior to January 2000, re-export from the US was a violation of US law.) This encryption code is a direct transcription of the algorithm from Roger Schlafly, described by Phil Katz in the file appnote.txt. This file (appnote.txt) is distributed with the PKZIP program (even in the version without encryption capabilities). If you don't need crypting in your application, just define symbols NOCRYPT and NOUNCRYPT. This code support the "Traditional PKWARE Encryption". The new AES encryption added on Zip format by Winzip (see the page http://www.winzip.com/aes_info.htm ) and PKWare PKZip 5.x Strong Encryption is not supported. */ #define CRC32(c, b) ((*(pcrc_32_tab+(((int)(c) ^ (b)) & 0xff))) ^ ((c) >> 8)) /*********************************************************************** * Return the next byte in the pseudo-random sequence */ static int decrypt_byte(unsigned long* pkeys, const z_crc_t* pcrc_32_tab) { unsigned temp; /* POTENTIAL BUG: temp*(temp^1) may overflow in an * unpredictable manner on 16-bit systems; not a problem * with any known compiler so far, though */ (void)pcrc_32_tab; temp = ((unsigned)(*(pkeys+2)) & 0xffff) | 2; return (int)(((temp * (temp ^ 1)) >> 8) & 0xff); } /*********************************************************************** * Update the encryption keys with the next byte of plain text */ static int update_keys(unsigned long* pkeys, const z_crc_t* pcrc_32_tab, int c) { (*(pkeys+0)) = CRC32((*(pkeys+0)), c); (*(pkeys+1)) += (*(pkeys+0)) & 0xff; (*(pkeys+1)) = (*(pkeys+1)) * 134775813L + 1; { register int keyshift = (int)((*(pkeys+1)) >> 24); (*(pkeys+2)) = CRC32((*(pkeys+2)), keyshift); } return c; } /*********************************************************************** * Initialize the encryption keys and the random header according to * the given password. */ static void init_keys(const char* passwd, unsigned long* pkeys, const z_crc_t* pcrc_32_tab) { *(pkeys+0) = 305419896L; *(pkeys+1) = 591751049L; *(pkeys+2) = 878082192L; while (*passwd != '\0') { update_keys(pkeys,pcrc_32_tab,(int)*passwd); passwd++; } } #define zdecode(pkeys,pcrc_32_tab,c) \ (update_keys(pkeys,pcrc_32_tab,c ^= decrypt_byte(pkeys,pcrc_32_tab))) #define zencode(pkeys,pcrc_32_tab,c,t) \ (t=decrypt_byte(pkeys,pcrc_32_tab), update_keys(pkeys,pcrc_32_tab,c), (Byte)t^(c)) #ifdef INCLUDECRYPTINGCODE_IFCRYPTALLOWED #define RAND_HEAD_LEN 12 /* "last resort" source for second part of crypt seed pattern */ # ifndef ZCR_SEED2 # define ZCR_SEED2 3141592654UL /* use PI as default pattern */ # endif static unsigned crypthead(const char* passwd, /* password string */ unsigned char* buf, /* where to write header */ int bufSize, unsigned long* pkeys, const z_crc_t* pcrc_32_tab, unsigned long crcForCrypting) { unsigned n; /* index in random header */ int t; /* temporary */ int c; /* random byte */ unsigned char header[RAND_HEAD_LEN-2]; /* random header */ static unsigned calls = 0; /* ensure different random header each time */ if (bufSize> 7) & 0xff; header[n] = (unsigned char)zencode(pkeys, pcrc_32_tab, c, t); } /* Encrypt random header (last two bytes is high word of crc) */ init_keys(passwd, pkeys, pcrc_32_tab); for (n = 0; n < RAND_HEAD_LEN-2; n++) { buf[n] = (unsigned char)zencode(pkeys, pcrc_32_tab, header[n], t); } buf[n++] = (unsigned char)zencode(pkeys, pcrc_32_tab, (int)(crcForCrypting >> 16) & 0xff, t); buf[n++] = (unsigned char)zencode(pkeys, pcrc_32_tab, (int)(crcForCrypting >> 24) & 0xff, t); return n; } #endif httrack-3.49.5/src/minizip/zip.c0000644000175000017500000020011314555201641013411 00000000000000/* zip.c -- IO on .zip files using zlib Version 1.1, February 14h, 2010 part of the MiniZip project - ( http://www.winimage.com/zLibDll/minizip.html ) Copyright (C) 1998-2010 Gilles Vollant (minizip) ( http://www.winimage.com/zLibDll/minizip.html ) Modifications for Zip64 support Copyright (C) 2009-2010 Mathias Svensson ( http://result42.com ) For more info read MiniZip_info.txt Changes Oct-2009 - Mathias Svensson - Remove old C style function prototypes Oct-2009 - Mathias Svensson - Added Zip64 Support when creating new file archives Oct-2009 - Mathias Svensson - Did some code cleanup and refactoring to get better overview of some functions. Oct-2009 - Mathias Svensson - Added zipRemoveExtraInfoBlock to strip extra field data from its ZIP64 data It is used when recreating zip archive with RAW when deleting items from a zip. ZIP64 data is automatically added to items that needs it, and existing ZIP64 data need to be removed. Oct-2009 - Mathias Svensson - Added support for BZIP2 as compression mode (bzip2 lib is required) Jan-2010 - back to unzip and minizip 1.0 name scheme, with compatibility layer */ #include #include #include #include #include #include "zlib.h" #include "zip.h" #ifdef STDC # include #endif #ifdef NO_ERRNO_H extern int errno; #else # include #endif #ifndef local # define local static #endif /* compile with -Dlocal if your debugger can't find static symbols */ #ifndef VERSIONMADEBY # define VERSIONMADEBY (0x0) /* platform dependent */ #endif #ifndef Z_BUFSIZE #define Z_BUFSIZE (64*1024) //(16384) #endif #ifndef Z_MAXFILENAMEINZIP #define Z_MAXFILENAMEINZIP (256) #endif #ifndef ALLOC # define ALLOC(size) (malloc(size)) #endif /* #define SIZECENTRALDIRITEM (0x2e) #define SIZEZIPLOCALHEADER (0x1e) */ /* I've found an old Unix (a SunOS 4.1.3_U1) without all SEEK_* defined.... */ // NOT sure that this work on ALL platform #define MAKEULONG64(a, b) ((ZPOS64_T)(((unsigned long)(a)) | ((ZPOS64_T)((unsigned long)(b))) << 32)) #ifndef SEEK_CUR #define SEEK_CUR 1 #endif #ifndef SEEK_END #define SEEK_END 2 #endif #ifndef SEEK_SET #define SEEK_SET 0 #endif #ifndef DEF_MEM_LEVEL #if MAX_MEM_LEVEL >= 8 # define DEF_MEM_LEVEL 8 #else # define DEF_MEM_LEVEL MAX_MEM_LEVEL #endif #endif const char zip_copyright[] =" zip 1.01 Copyright 1998-2004 Gilles Vollant - http://www.winimage.com/zLibDll"; #define SIZEDATA_INDATABLOCK (4096-(4*4)) #define LOCALHEADERMAGIC (0x04034b50) #define CENTRALHEADERMAGIC (0x02014b50) #define ENDHEADERMAGIC (0x06054b50) #define ZIP64ENDHEADERMAGIC (0x6064b50) #define ZIP64ENDLOCHEADERMAGIC (0x7064b50) #define FLAG_LOCALHEADER_OFFSET (0x06) #define CRC_LOCALHEADER_OFFSET (0x0e) #define SIZECENTRALHEADER (0x2e) /* 46 */ typedef struct linkedlist_datablock_internal_s { struct linkedlist_datablock_internal_s* next_datablock; uLong avail_in_this_block; uLong filled_in_this_block; uLong unused; /* for future use and alignment */ unsigned char data[SIZEDATA_INDATABLOCK]; } linkedlist_datablock_internal; typedef struct linkedlist_data_s { linkedlist_datablock_internal* first_block; linkedlist_datablock_internal* last_block; } linkedlist_data; typedef struct { z_stream stream; /* zLib stream structure for inflate */ #ifdef HAVE_BZIP2 bz_stream bstream; /* bzLib stream structure for bziped */ #endif int stream_initialised; /* 1 is stream is initialised */ uInt pos_in_buffered_data; /* last written byte in buffered_data */ ZPOS64_T pos_local_header; /* offset of the local header of the file currently writing */ char* central_header; /* central header data for the current file */ uLong size_centralExtra; uLong size_centralheader; /* size of the central header for cur file */ uLong size_centralExtraFree; /* Extra bytes allocated to the centralheader but that are not used */ uLong flag; /* flag of the file currently writing */ int method; /* compression method of file currently wr.*/ int raw; /* 1 for directly writing raw data */ Byte buffered_data[Z_BUFSIZE];/* buffer contain compressed data to be writ*/ uLong dosDate; uLong crc32; int encrypt; int zip64; /* Add ZIP64 extended information in the extra field */ ZPOS64_T pos_zip64extrainfo; ZPOS64_T totalCompressedData; ZPOS64_T totalUncompressedData; #ifndef NOCRYPT unsigned long keys[3]; /* keys defining the pseudo-random sequence */ const z_crc_t* pcrc_32_tab; unsigned crypt_header_size; #endif } curfile64_info; typedef struct { zlib_filefunc64_32_def z_filefunc; voidpf filestream; /* io structure of the zipfile */ linkedlist_data central_dir;/* datablock with central dir in construction*/ int in_opened_file_inzip; /* 1 if a file in the zip is currently writ.*/ curfile64_info ci; /* info on the file currently writing */ ZPOS64_T begin_pos; /* position of the beginning of the zipfile */ ZPOS64_T add_position_when_writing_offset; ZPOS64_T number_entry; #ifndef NO_ADDFILEINEXISTINGZIP char *globalcomment; #endif } zip64_internal; #ifndef NOCRYPT #define INCLUDECRYPTINGCODE_IFCRYPTALLOWED #include "crypt.h" #endif local linkedlist_datablock_internal* allocate_new_datablock(void) { linkedlist_datablock_internal* ldi; ldi = (linkedlist_datablock_internal*) ALLOC(sizeof(linkedlist_datablock_internal)); if (ldi!=NULL) { ldi->next_datablock = NULL ; ldi->filled_in_this_block = 0 ; ldi->avail_in_this_block = SIZEDATA_INDATABLOCK ; } return ldi; } local void free_datablock(linkedlist_datablock_internal* ldi) { while (ldi!=NULL) { linkedlist_datablock_internal* ldinext = ldi->next_datablock; free(ldi); ldi = ldinext; } } local void init_linkedlist(linkedlist_data* ll) { ll->first_block = ll->last_block = NULL; } local void free_linkedlist(linkedlist_data* ll) { free_datablock(ll->first_block); ll->first_block = ll->last_block = NULL; } local int add_data_in_datablock(linkedlist_data* ll, const void* buf, uLong len) { linkedlist_datablock_internal* ldi; const unsigned char* from_copy; if (ll==NULL) return ZIP_INTERNALERROR; if (ll->last_block == NULL) { ll->first_block = ll->last_block = allocate_new_datablock(); if (ll->first_block == NULL) return ZIP_INTERNALERROR; } ldi = ll->last_block; from_copy = (const unsigned char*)buf; while (len>0) { uInt copy_this; uInt i; unsigned char* to_copy; if (ldi->avail_in_this_block==0) { ldi->next_datablock = allocate_new_datablock(); if (ldi->next_datablock == NULL) return ZIP_INTERNALERROR; ldi = ldi->next_datablock ; ll->last_block = ldi; } if (ldi->avail_in_this_block < len) copy_this = (uInt)ldi->avail_in_this_block; else copy_this = (uInt)len; to_copy = &(ldi->data[ldi->filled_in_this_block]); for (i=0;ifilled_in_this_block += copy_this; ldi->avail_in_this_block -= copy_this; from_copy += copy_this ; len -= copy_this; } return ZIP_OK; } /****************************************************************************/ #ifndef NO_ADDFILEINEXISTINGZIP /* =========================================================================== Inputs a long in LSB order to the given file nbByte == 1, 2 ,4 or 8 (byte, short or long, ZPOS64_T) */ local int zip64local_putValue(const zlib_filefunc64_32_def* pzlib_filefunc_def, voidpf filestream, ZPOS64_T x, int nbByte) { unsigned char buf[8]; int n; for (n = 0; n < nbByte; n++) { buf[n] = (unsigned char)(x & 0xff); x >>= 8; } if (x != 0) { /* data overflow - hack for ZIP64 (X Roche) */ for (n = 0; n < nbByte; n++) { buf[n] = 0xff; } } if (ZWRITE64(*pzlib_filefunc_def,filestream,buf,(uLong)nbByte)!=(uLong)nbByte) return ZIP_ERRNO; else return ZIP_OK; } local void zip64local_putValue_inmemory (void* dest, ZPOS64_T x, int nbByte) { unsigned char* buf=(unsigned char*)dest; int n; for (n = 0; n < nbByte; n++) { buf[n] = (unsigned char)(x & 0xff); x >>= 8; } if (x != 0) { /* data overflow - hack for ZIP64 */ for (n = 0; n < nbByte; n++) { buf[n] = 0xff; } } } /****************************************************************************/ local uLong zip64local_TmzDateToDosDate(const tm_zip* ptm) { uLong year = (uLong)ptm->tm_year; if (year>=1980) year-=1980; else if (year>=80) year-=80; return (uLong) (((uLong)(ptm->tm_mday) + (32 * (uLong)(ptm->tm_mon+1)) + (512 * year)) << 16) | (((uLong)ptm->tm_sec/2) + (32 * (uLong)ptm->tm_min) + (2048 * (uLong)ptm->tm_hour)); } /****************************************************************************/ local int zip64local_getByte(const zlib_filefunc64_32_def* pzlib_filefunc_def, voidpf filestream, int* pi) { unsigned char c; int err = (int)ZREAD64(*pzlib_filefunc_def,filestream,&c,1); if (err==1) { *pi = (int)c; return ZIP_OK; } else { if (ZERROR64(*pzlib_filefunc_def,filestream)) return ZIP_ERRNO; else return ZIP_EOF; } } /* =========================================================================== Reads a long in LSB order from the given gz_stream. Sets */ local int zip64local_getShort(const zlib_filefunc64_32_def* pzlib_filefunc_def, voidpf filestream, uLong* pX) { uLong x ; int i = 0; int err; err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x = (uLong)i; if (err==ZIP_OK) err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x += ((uLong)i)<<8; if (err==ZIP_OK) *pX = x; else *pX = 0; return err; } local int zip64local_getLong(const zlib_filefunc64_32_def* pzlib_filefunc_def, voidpf filestream, uLong* pX) { uLong x ; int i = 0; int err; err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x = (uLong)i; if (err==ZIP_OK) err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x += ((uLong)i)<<8; if (err==ZIP_OK) err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x += ((uLong)i)<<16; if (err==ZIP_OK) err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x += ((uLong)i)<<24; if (err==ZIP_OK) *pX = x; else *pX = 0; return err; } local int zip64local_getLong64(const zlib_filefunc64_32_def* pzlib_filefunc_def, voidpf filestream, ZPOS64_T *pX) { ZPOS64_T x; int i = 0; int err; err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x = (ZPOS64_T)i; if (err==ZIP_OK) err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x += ((ZPOS64_T)i)<<8; if (err==ZIP_OK) err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x += ((ZPOS64_T)i)<<16; if (err==ZIP_OK) err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x += ((ZPOS64_T)i)<<24; if (err==ZIP_OK) err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x += ((ZPOS64_T)i)<<32; if (err==ZIP_OK) err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x += ((ZPOS64_T)i)<<40; if (err==ZIP_OK) err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x += ((ZPOS64_T)i)<<48; if (err==ZIP_OK) err = zip64local_getByte(pzlib_filefunc_def,filestream,&i); x += ((ZPOS64_T)i)<<56; if (err==ZIP_OK) *pX = x; else *pX = 0; return err; } #ifndef BUFREADCOMMENT #define BUFREADCOMMENT (0x400) #endif /* Locate the Central directory of a zipfile (at the end, just before the global comment) */ local ZPOS64_T zip64local_SearchCentralDir(const zlib_filefunc64_32_def* pzlib_filefunc_def, voidpf filestream) { unsigned char* buf; ZPOS64_T uSizeFile; ZPOS64_T uBackRead; ZPOS64_T uMaxBack=0xffff; /* maximum size of global comment */ ZPOS64_T uPosFound=0; if (ZSEEK64(*pzlib_filefunc_def,filestream,0,ZLIB_FILEFUNC_SEEK_END) != 0) return 0; uSizeFile = ZTELL64(*pzlib_filefunc_def,filestream); if (uMaxBack>uSizeFile) uMaxBack = uSizeFile; buf = (unsigned char*)ALLOC(BUFREADCOMMENT+4); if (buf==NULL) return 0; uBackRead = 4; while (uBackReaduMaxBack) uBackRead = uMaxBack; else uBackRead+=BUFREADCOMMENT; uReadPos = uSizeFile-uBackRead ; uReadSize = ((BUFREADCOMMENT+4) < (uSizeFile-uReadPos)) ? (BUFREADCOMMENT+4) : (uLong)(uSizeFile-uReadPos); if (ZSEEK64(*pzlib_filefunc_def,filestream,uReadPos,ZLIB_FILEFUNC_SEEK_SET)!=0) break; if (ZREAD64(*pzlib_filefunc_def,filestream,buf,uReadSize)!=uReadSize) break; for (i=(int)uReadSize-3; (i--)>0;) if (((*(buf+i))==0x50) && ((*(buf+i+1))==0x4b) && ((*(buf+i+2))==0x05) && ((*(buf+i+3))==0x06)) { uPosFound = uReadPos+(unsigned)i; break; } if (uPosFound!=0) break; } free(buf); return uPosFound; } /* Locate the End of Zip64 Central directory locator and from there find the CD of a zipfile (at the end, just before the global comment) */ local ZPOS64_T zip64local_SearchCentralDir64(const zlib_filefunc64_32_def* pzlib_filefunc_def, voidpf filestream) { unsigned char* buf; ZPOS64_T uSizeFile; ZPOS64_T uBackRead; ZPOS64_T uMaxBack=0xffff; /* maximum size of global comment */ ZPOS64_T uPosFound=0; uLong uL; ZPOS64_T relativeOffset; if (ZSEEK64(*pzlib_filefunc_def,filestream,0,ZLIB_FILEFUNC_SEEK_END) != 0) return 0; uSizeFile = ZTELL64(*pzlib_filefunc_def,filestream); if (uMaxBack>uSizeFile) uMaxBack = uSizeFile; buf = (unsigned char*)ALLOC(BUFREADCOMMENT+4); if (buf==NULL) return 0; uBackRead = 4; while (uBackReaduMaxBack) uBackRead = uMaxBack; else uBackRead+=BUFREADCOMMENT; uReadPos = uSizeFile-uBackRead ; uReadSize = ((BUFREADCOMMENT+4) < (uSizeFile-uReadPos)) ? (BUFREADCOMMENT+4) : (uLong)(uSizeFile-uReadPos); if (ZSEEK64(*pzlib_filefunc_def,filestream,uReadPos,ZLIB_FILEFUNC_SEEK_SET)!=0) break; if (ZREAD64(*pzlib_filefunc_def,filestream,buf,uReadSize)!=uReadSize) break; for (i=(int)uReadSize-3; (i--)>0;) { // Signature "0x07064b50" Zip64 end of central directory locater if (((*(buf+i))==0x50) && ((*(buf+i+1))==0x4b) && ((*(buf+i+2))==0x06) && ((*(buf+i+3))==0x07)) { uPosFound = uReadPos+(unsigned)i; break; } } if (uPosFound!=0) break; } free(buf); if (uPosFound == 0) return 0; /* Zip64 end of central directory locator */ if (ZSEEK64(*pzlib_filefunc_def,filestream, uPosFound,ZLIB_FILEFUNC_SEEK_SET)!=0) return 0; /* the signature, already checked */ if (zip64local_getLong(pzlib_filefunc_def,filestream,&uL)!=ZIP_OK) return 0; /* number of the disk with the start of the zip64 end of central directory */ if (zip64local_getLong(pzlib_filefunc_def,filestream,&uL)!=ZIP_OK) return 0; if (uL != 0) return 0; /* relative offset of the zip64 end of central directory record */ if (zip64local_getLong64(pzlib_filefunc_def,filestream,&relativeOffset)!=ZIP_OK) return 0; /* total number of disks */ if (zip64local_getLong(pzlib_filefunc_def,filestream,&uL)!=ZIP_OK) return 0; if (uL != 1) return 0; /* Goto Zip64 end of central directory record */ if (ZSEEK64(*pzlib_filefunc_def,filestream, relativeOffset,ZLIB_FILEFUNC_SEEK_SET)!=0) return 0; /* the signature */ if (zip64local_getLong(pzlib_filefunc_def,filestream,&uL)!=ZIP_OK) return 0; if (uL != 0x06064b50) // signature of 'Zip64 end of central directory' return 0; return relativeOffset; } local int LoadCentralDirectoryRecord(zip64_internal* pziinit) { int err=ZIP_OK; ZPOS64_T byte_before_the_zipfile;/* byte before the zipfile, (>0 for sfx)*/ ZPOS64_T size_central_dir; /* size of the central directory */ ZPOS64_T offset_central_dir; /* offset of start of central directory */ ZPOS64_T central_pos; uLong uL; uLong number_disk; /* number of the current disk, used for spanning ZIP, unsupported, always 0*/ uLong number_disk_with_CD; /* number of the disk with central dir, used for spanning ZIP, unsupported, always 0*/ ZPOS64_T number_entry; ZPOS64_T number_entry_CD; /* total number of entries in the central dir (same than number_entry on nospan) */ uLong VersionMadeBy; uLong VersionNeeded; uLong size_comment; int hasZIP64Record = 0; // check first if we find a ZIP64 record central_pos = zip64local_SearchCentralDir64(&pziinit->z_filefunc,pziinit->filestream); if(central_pos > 0) { hasZIP64Record = 1; } else if(central_pos == 0) { central_pos = zip64local_SearchCentralDir(&pziinit->z_filefunc,pziinit->filestream); } /* disable to allow appending to empty ZIP archive if (central_pos==0) err=ZIP_ERRNO; */ if(hasZIP64Record) { ZPOS64_T sizeEndOfCentralDirectory; if (ZSEEK64(pziinit->z_filefunc, pziinit->filestream, central_pos, ZLIB_FILEFUNC_SEEK_SET) != 0) err=ZIP_ERRNO; /* the signature, already checked */ if (zip64local_getLong(&pziinit->z_filefunc, pziinit->filestream,&uL)!=ZIP_OK) err=ZIP_ERRNO; /* size of zip64 end of central directory record */ if (zip64local_getLong64(&pziinit->z_filefunc, pziinit->filestream, &sizeEndOfCentralDirectory)!=ZIP_OK) err=ZIP_ERRNO; /* version made by */ if (zip64local_getShort(&pziinit->z_filefunc, pziinit->filestream, &VersionMadeBy)!=ZIP_OK) err=ZIP_ERRNO; /* version needed to extract */ if (zip64local_getShort(&pziinit->z_filefunc, pziinit->filestream, &VersionNeeded)!=ZIP_OK) err=ZIP_ERRNO; /* number of this disk */ if (zip64local_getLong(&pziinit->z_filefunc, pziinit->filestream,&number_disk)!=ZIP_OK) err=ZIP_ERRNO; /* number of the disk with the start of the central directory */ if (zip64local_getLong(&pziinit->z_filefunc, pziinit->filestream,&number_disk_with_CD)!=ZIP_OK) err=ZIP_ERRNO; /* total number of entries in the central directory on this disk */ if (zip64local_getLong64(&pziinit->z_filefunc, pziinit->filestream, &number_entry)!=ZIP_OK) err=ZIP_ERRNO; /* total number of entries in the central directory */ if (zip64local_getLong64(&pziinit->z_filefunc, pziinit->filestream,&number_entry_CD)!=ZIP_OK) err=ZIP_ERRNO; if ((number_entry_CD!=number_entry) || (number_disk_with_CD!=0) || (number_disk!=0)) err=ZIP_BADZIPFILE; /* size of the central directory */ if (zip64local_getLong64(&pziinit->z_filefunc, pziinit->filestream,&size_central_dir)!=ZIP_OK) err=ZIP_ERRNO; /* offset of start of central directory with respect to the starting disk number */ if (zip64local_getLong64(&pziinit->z_filefunc, pziinit->filestream,&offset_central_dir)!=ZIP_OK) err=ZIP_ERRNO; // TODO.. // read the comment from the standard central header. size_comment = 0; } else { // Read End of central Directory info if (ZSEEK64(pziinit->z_filefunc, pziinit->filestream, central_pos,ZLIB_FILEFUNC_SEEK_SET)!=0) err=ZIP_ERRNO; /* the signature, already checked */ if (zip64local_getLong(&pziinit->z_filefunc, pziinit->filestream,&uL)!=ZIP_OK) err=ZIP_ERRNO; /* number of this disk */ if (zip64local_getShort(&pziinit->z_filefunc, pziinit->filestream,&number_disk)!=ZIP_OK) err=ZIP_ERRNO; /* number of the disk with the start of the central directory */ if (zip64local_getShort(&pziinit->z_filefunc, pziinit->filestream,&number_disk_with_CD)!=ZIP_OK) err=ZIP_ERRNO; /* total number of entries in the central dir on this disk */ number_entry = 0; if (zip64local_getShort(&pziinit->z_filefunc, pziinit->filestream, &uL)!=ZIP_OK) err=ZIP_ERRNO; else number_entry = uL; /* total number of entries in the central dir */ number_entry_CD = 0; if (zip64local_getShort(&pziinit->z_filefunc, pziinit->filestream, &uL)!=ZIP_OK) err=ZIP_ERRNO; else number_entry_CD = uL; if ((number_entry_CD!=number_entry) || (number_disk_with_CD!=0) || (number_disk!=0)) err=ZIP_BADZIPFILE; /* size of the central directory */ size_central_dir = 0; if (zip64local_getLong(&pziinit->z_filefunc, pziinit->filestream, &uL)!=ZIP_OK) err=ZIP_ERRNO; else size_central_dir = uL; /* offset of start of central directory with respect to the starting disk number */ offset_central_dir = 0; if (zip64local_getLong(&pziinit->z_filefunc, pziinit->filestream, &uL)!=ZIP_OK) err=ZIP_ERRNO; else offset_central_dir = uL; /* zipfile global comment length */ if (zip64local_getShort(&pziinit->z_filefunc, pziinit->filestream, &size_comment)!=ZIP_OK) err=ZIP_ERRNO; } if ((central_posz_filefunc, pziinit->filestream); return ZIP_ERRNO; } if (size_comment>0) { pziinit->globalcomment = (char*)ALLOC(size_comment+1); if (pziinit->globalcomment) { size_comment = ZREAD64(pziinit->z_filefunc, pziinit->filestream, pziinit->globalcomment,size_comment); pziinit->globalcomment[size_comment]=0; } } byte_before_the_zipfile = central_pos - (offset_central_dir+size_central_dir); pziinit->add_position_when_writing_offset = byte_before_the_zipfile; { ZPOS64_T size_central_dir_to_read = size_central_dir; size_t buf_size = SIZEDATA_INDATABLOCK; void* buf_read = (void*)ALLOC(buf_size); if (ZSEEK64(pziinit->z_filefunc, pziinit->filestream, offset_central_dir + byte_before_the_zipfile, ZLIB_FILEFUNC_SEEK_SET) != 0) err=ZIP_ERRNO; while ((size_central_dir_to_read>0) && (err==ZIP_OK)) { ZPOS64_T read_this = SIZEDATA_INDATABLOCK; if (read_this > size_central_dir_to_read) read_this = size_central_dir_to_read; if (ZREAD64(pziinit->z_filefunc, pziinit->filestream,buf_read,(uLong)read_this) != read_this) err=ZIP_ERRNO; if (err==ZIP_OK) err = add_data_in_datablock(&pziinit->central_dir,buf_read, (uLong)read_this); size_central_dir_to_read-=read_this; } free(buf_read); } pziinit->begin_pos = byte_before_the_zipfile; pziinit->number_entry = number_entry_CD; if (ZSEEK64(pziinit->z_filefunc, pziinit->filestream, offset_central_dir+byte_before_the_zipfile,ZLIB_FILEFUNC_SEEK_SET) != 0) err=ZIP_ERRNO; return err; } #endif /* !NO_ADDFILEINEXISTINGZIP*/ /************************************************************/ extern zipFile ZEXPORT zipOpen3(const void *pathname, int append, zipcharpc* globalcomment, zlib_filefunc64_32_def* pzlib_filefunc64_32_def) { zip64_internal ziinit; zip64_internal* zi; int err=ZIP_OK; ziinit.z_filefunc.zseek32_file = NULL; ziinit.z_filefunc.ztell32_file = NULL; if (pzlib_filefunc64_32_def==NULL) fill_fopen64_filefunc(&ziinit.z_filefunc.zfile_func64); else ziinit.z_filefunc = *pzlib_filefunc64_32_def; ziinit.filestream = ZOPEN64(ziinit.z_filefunc, pathname, (append == APPEND_STATUS_CREATE) ? (ZLIB_FILEFUNC_MODE_READ | ZLIB_FILEFUNC_MODE_WRITE | ZLIB_FILEFUNC_MODE_CREATE) : (ZLIB_FILEFUNC_MODE_READ | ZLIB_FILEFUNC_MODE_WRITE | ZLIB_FILEFUNC_MODE_EXISTING)); if (ziinit.filestream == NULL) return NULL; if (append == APPEND_STATUS_CREATEAFTER) ZSEEK64(ziinit.z_filefunc,ziinit.filestream,0,SEEK_END); ziinit.begin_pos = ZTELL64(ziinit.z_filefunc,ziinit.filestream); ziinit.in_opened_file_inzip = 0; ziinit.ci.stream_initialised = 0; ziinit.number_entry = 0; ziinit.add_position_when_writing_offset = 0; init_linkedlist(&(ziinit.central_dir)); zi = (zip64_internal*)ALLOC(sizeof(zip64_internal)); if (zi==NULL) { ZCLOSE64(ziinit.z_filefunc,ziinit.filestream); return NULL; } /* now we add file in a zipfile */ # ifndef NO_ADDFILEINEXISTINGZIP ziinit.globalcomment = NULL; if (append == APPEND_STATUS_ADDINZIP) { // Read and Cache Central Directory Records err = LoadCentralDirectoryRecord(&ziinit); } if (globalcomment) { *globalcomment = ziinit.globalcomment; } # endif /* !NO_ADDFILEINEXISTINGZIP*/ if (err != ZIP_OK) { # ifndef NO_ADDFILEINEXISTINGZIP free(ziinit.globalcomment); # endif /* !NO_ADDFILEINEXISTINGZIP*/ free(zi); return NULL; } else { *zi = ziinit; return (zipFile)zi; } } extern zipFile ZEXPORT zipOpen2(const char *pathname, int append, zipcharpc* globalcomment, zlib_filefunc_def* pzlib_filefunc32_def) { if (pzlib_filefunc32_def != NULL) { zlib_filefunc64_32_def zlib_filefunc64_32_def_fill; fill_zlib_filefunc64_32_def_from_filefunc32(&zlib_filefunc64_32_def_fill,pzlib_filefunc32_def); return zipOpen3(pathname, append, globalcomment, &zlib_filefunc64_32_def_fill); } else return zipOpen3(pathname, append, globalcomment, NULL); } extern zipFile ZEXPORT zipOpen2_64(const void *pathname, int append, zipcharpc* globalcomment, zlib_filefunc64_def* pzlib_filefunc_def) { if (pzlib_filefunc_def != NULL) { zlib_filefunc64_32_def zlib_filefunc64_32_def_fill; zlib_filefunc64_32_def_fill.zfile_func64 = *pzlib_filefunc_def; zlib_filefunc64_32_def_fill.ztell32_file = NULL; zlib_filefunc64_32_def_fill.zseek32_file = NULL; return zipOpen3(pathname, append, globalcomment, &zlib_filefunc64_32_def_fill); } else return zipOpen3(pathname, append, globalcomment, NULL); } extern zipFile ZEXPORT zipOpen(const char* pathname, int append) { return zipOpen3((const void*)pathname,append,NULL,NULL); } extern zipFile ZEXPORT zipOpen64(const void* pathname, int append) { return zipOpen3(pathname,append,NULL,NULL); } local int Write_LocalFileHeader(zip64_internal* zi, const char* filename, uInt size_extrafield_local, const void* extrafield_local) { /* write the local header */ int err; uInt size_filename = (uInt)strlen(filename); uInt size_extrafield = size_extrafield_local; err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)LOCALHEADERMAGIC, 4); if (err==ZIP_OK) { if(zi->ci.zip64) err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)45,2);/* version needed to extract */ else err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)20,2);/* version needed to extract */ } if (err==ZIP_OK) err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)zi->ci.flag,2); if (err==ZIP_OK) err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)zi->ci.method,2); if (err==ZIP_OK) err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)zi->ci.dosDate,4); // CRC / Compressed size / Uncompressed size will be filled in later and rewritten later if (err==ZIP_OK) err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)0,4); /* crc 32, unknown */ if (err==ZIP_OK) { if(zi->ci.zip64) err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)0xFFFFFFFF,4); /* compressed size, unknown */ else err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)0,4); /* compressed size, unknown */ } if (err==ZIP_OK) { if(zi->ci.zip64) err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)0xFFFFFFFF,4); /* uncompressed size, unknown */ else err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)0,4); /* uncompressed size, unknown */ } if (err==ZIP_OK) err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)size_filename,2); if(zi->ci.zip64) { size_extrafield += 20; } if (err==ZIP_OK) err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)size_extrafield,2); if ((err==ZIP_OK) && (size_filename > 0)) { if (ZWRITE64(zi->z_filefunc,zi->filestream,filename,size_filename)!=size_filename) err = ZIP_ERRNO; } if ((err==ZIP_OK) && (size_extrafield_local > 0)) { if (ZWRITE64(zi->z_filefunc, zi->filestream, extrafield_local, size_extrafield_local) != size_extrafield_local) err = ZIP_ERRNO; } if ((err==ZIP_OK) && (zi->ci.zip64)) { // write the Zip64 extended info short HeaderID = 1; short DataSize = 16; ZPOS64_T CompressedSize = 0; ZPOS64_T UncompressedSize = 0; // Remember position of Zip64 extended info for the local file header. (needed when we update size after done with file) zi->ci.pos_zip64extrainfo = ZTELL64(zi->z_filefunc,zi->filestream); err = zip64local_putValue(&zi->z_filefunc, zi->filestream, (ZPOS64_T)HeaderID,2); err = zip64local_putValue(&zi->z_filefunc, zi->filestream, (ZPOS64_T)DataSize,2); err = zip64local_putValue(&zi->z_filefunc, zi->filestream, (ZPOS64_T)UncompressedSize,8); err = zip64local_putValue(&zi->z_filefunc, zi->filestream, (ZPOS64_T)CompressedSize,8); } return err; } /* NOTE. When writing RAW the ZIP64 extended information in extrafield_local and extrafield_global needs to be stripped before calling this function it can be done with zipRemoveExtraInfoBlock It is not done here because then we need to realloc a new buffer since parameters are 'const' and I want to minimize unnecessary allocations. */ extern int ZEXPORT zipOpenNewFileInZip4_64(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int raw, int windowBits,int memLevel, int strategy, const char* password, uLong crcForCrypting, uLong versionMadeBy, uLong flagBase, int zip64) { zip64_internal* zi; uInt size_filename; uInt size_comment; uInt i; int err = ZIP_OK; # ifdef NOCRYPT (crcForCrypting); if (password != NULL) return ZIP_PARAMERROR; # endif if (file == NULL) return ZIP_PARAMERROR; #ifdef HAVE_BZIP2 if ((method!=0) && (method!=Z_DEFLATED) && (method!=Z_BZIP2ED)) return ZIP_PARAMERROR; #else if ((method!=0) && (method!=Z_DEFLATED)) return ZIP_PARAMERROR; #endif // The filename and comment length must fit in 16 bits. if ((filename!=NULL) && (strlen(filename)>0xffff)) return ZIP_PARAMERROR; if ((comment!=NULL) && (strlen(comment)>0xffff)) return ZIP_PARAMERROR; // The extra field length must fit in 16 bits. If the member also requires // a Zip64 extra block, that will also need to fit within that 16-bit // length, but that will be checked for later. if ((size_extrafield_local>0xffff) || (size_extrafield_global>0xffff)) return ZIP_PARAMERROR; zi = (zip64_internal*)file; if (zi->in_opened_file_inzip == 1) { err = zipCloseFileInZip (file); if (err != ZIP_OK) return err; } if (filename==NULL) filename="-"; if (comment==NULL) size_comment = 0; else size_comment = (uInt)strlen(comment); size_filename = (uInt)strlen(filename); if (zipfi == NULL) zi->ci.dosDate = 0; else { if (zipfi->dosDate != 0) zi->ci.dosDate = zipfi->dosDate; else zi->ci.dosDate = zip64local_TmzDateToDosDate(&zipfi->tmz_date); } zi->ci.flag = flagBase; if ((level==8) || (level==9)) zi->ci.flag |= 2; if (level==2) zi->ci.flag |= 4; if (level==1) zi->ci.flag |= 6; if (password != NULL) zi->ci.flag |= 1; zi->ci.crc32 = 0; zi->ci.method = method; zi->ci.encrypt = 0; zi->ci.stream_initialised = 0; zi->ci.pos_in_buffered_data = 0; zi->ci.raw = raw; zi->ci.pos_local_header = ZTELL64(zi->z_filefunc,zi->filestream); zi->ci.size_centralheader = SIZECENTRALHEADER + size_filename + size_extrafield_global + size_comment; zi->ci.size_centralExtraFree = 32; // Extra space we have reserved in case we need to add ZIP64 extra info data zi->ci.central_header = (char*)ALLOC((uInt)zi->ci.size_centralheader + zi->ci.size_centralExtraFree); zi->ci.size_centralExtra = size_extrafield_global; zip64local_putValue_inmemory(zi->ci.central_header,(uLong)CENTRALHEADERMAGIC,4); /* version info */ zip64local_putValue_inmemory(zi->ci.central_header+4,(uLong)versionMadeBy,2); zip64local_putValue_inmemory(zi->ci.central_header+6,(uLong)20,2); zip64local_putValue_inmemory(zi->ci.central_header+8,(uLong)zi->ci.flag,2); zip64local_putValue_inmemory(zi->ci.central_header+10,(uLong)zi->ci.method,2); zip64local_putValue_inmemory(zi->ci.central_header+12,(uLong)zi->ci.dosDate,4); zip64local_putValue_inmemory(zi->ci.central_header+16,(uLong)0,4); /*crc*/ zip64local_putValue_inmemory(zi->ci.central_header+20,(uLong)0,4); /*compr size*/ zip64local_putValue_inmemory(zi->ci.central_header+24,(uLong)0,4); /*uncompr size*/ zip64local_putValue_inmemory(zi->ci.central_header+28,(uLong)size_filename,2); zip64local_putValue_inmemory(zi->ci.central_header+30,(uLong)size_extrafield_global,2); zip64local_putValue_inmemory(zi->ci.central_header+32,(uLong)size_comment,2); zip64local_putValue_inmemory(zi->ci.central_header+34,(uLong)0,2); /*disk nm start*/ if (zipfi==NULL) zip64local_putValue_inmemory(zi->ci.central_header+36,(uLong)0,2); else zip64local_putValue_inmemory(zi->ci.central_header+36,(uLong)zipfi->internal_fa,2); if (zipfi==NULL) zip64local_putValue_inmemory(zi->ci.central_header+38,(uLong)0,4); else zip64local_putValue_inmemory(zi->ci.central_header+38,(uLong)zipfi->external_fa,4); if(zi->ci.pos_local_header >= 0xffffffff) zip64local_putValue_inmemory(zi->ci.central_header+42,(uLong)0xffffffff,4); else zip64local_putValue_inmemory(zi->ci.central_header+42,(uLong)zi->ci.pos_local_header - zi->add_position_when_writing_offset,4); for (i=0;ici.central_header+SIZECENTRALHEADER+i) = *(filename+i); for (i=0;ici.central_header+SIZECENTRALHEADER+size_filename+i) = *(((const char*)extrafield_global)+i); for (i=0;ici.central_header+SIZECENTRALHEADER+size_filename+ size_extrafield_global+i) = *(comment+i); if (zi->ci.central_header == NULL) return ZIP_INTERNALERROR; zi->ci.zip64 = zip64; zi->ci.totalCompressedData = 0; zi->ci.totalUncompressedData = 0; zi->ci.pos_zip64extrainfo = 0; err = Write_LocalFileHeader(zi, filename, size_extrafield_local, extrafield_local); #ifdef HAVE_BZIP2 zi->ci.bstream.avail_in = (uInt)0; zi->ci.bstream.avail_out = (uInt)Z_BUFSIZE; zi->ci.bstream.next_out = (char*)zi->ci.buffered_data; zi->ci.bstream.total_in_hi32 = 0; zi->ci.bstream.total_in_lo32 = 0; zi->ci.bstream.total_out_hi32 = 0; zi->ci.bstream.total_out_lo32 = 0; #endif zi->ci.stream.avail_in = (uInt)0; zi->ci.stream.avail_out = (uInt)Z_BUFSIZE; zi->ci.stream.next_out = zi->ci.buffered_data; zi->ci.stream.total_in = 0; zi->ci.stream.total_out = 0; zi->ci.stream.data_type = Z_BINARY; #ifdef HAVE_BZIP2 if ((err==ZIP_OK) && (zi->ci.method == Z_DEFLATED || zi->ci.method == Z_BZIP2ED) && (!zi->ci.raw)) #else if ((err==ZIP_OK) && (zi->ci.method == Z_DEFLATED) && (!zi->ci.raw)) #endif { if(zi->ci.method == Z_DEFLATED) { zi->ci.stream.zalloc = (alloc_func)0; zi->ci.stream.zfree = (free_func)0; zi->ci.stream.opaque = (voidpf)0; if (windowBits>0) windowBits = -windowBits; err = deflateInit2(&zi->ci.stream, level, Z_DEFLATED, windowBits, memLevel, strategy); if (err==Z_OK) zi->ci.stream_initialised = Z_DEFLATED; } else if(zi->ci.method == Z_BZIP2ED) { #ifdef HAVE_BZIP2 // Init BZip stuff here zi->ci.bstream.bzalloc = 0; zi->ci.bstream.bzfree = 0; zi->ci.bstream.opaque = (voidpf)0; err = BZ2_bzCompressInit(&zi->ci.bstream, level, 0,35); if(err == BZ_OK) zi->ci.stream_initialised = Z_BZIP2ED; #endif } } # ifndef NOCRYPT zi->ci.crypt_header_size = 0; if ((err==Z_OK) && (password != NULL)) { unsigned char bufHead[RAND_HEAD_LEN]; unsigned int sizeHead; zi->ci.encrypt = 1; zi->ci.pcrc_32_tab = get_crc_table(); /*init_keys(password,zi->ci.keys,zi->ci.pcrc_32_tab);*/ sizeHead=crypthead(password,bufHead,RAND_HEAD_LEN,zi->ci.keys,zi->ci.pcrc_32_tab,crcForCrypting); zi->ci.crypt_header_size = sizeHead; if (ZWRITE64(zi->z_filefunc,zi->filestream,bufHead,sizeHead) != sizeHead) err = ZIP_ERRNO; } # endif if (err==Z_OK) zi->in_opened_file_inzip = 1; return err; } extern int ZEXPORT zipOpenNewFileInZip4(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int raw, int windowBits,int memLevel, int strategy, const char* password, uLong crcForCrypting, uLong versionMadeBy, uLong flagBase) { return zipOpenNewFileInZip4_64(file, filename, zipfi, extrafield_local, size_extrafield_local, extrafield_global, size_extrafield_global, comment, method, level, raw, windowBits, memLevel, strategy, password, crcForCrypting, versionMadeBy, flagBase, 0); } extern int ZEXPORT zipOpenNewFileInZip3(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int raw, int windowBits,int memLevel, int strategy, const char* password, uLong crcForCrypting) { return zipOpenNewFileInZip4_64(file, filename, zipfi, extrafield_local, size_extrafield_local, extrafield_global, size_extrafield_global, comment, method, level, raw, windowBits, memLevel, strategy, password, crcForCrypting, VERSIONMADEBY, 0, 0); } extern int ZEXPORT zipOpenNewFileInZip3_64(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int raw, int windowBits,int memLevel, int strategy, const char* password, uLong crcForCrypting, int zip64) { return zipOpenNewFileInZip4_64(file, filename, zipfi, extrafield_local, size_extrafield_local, extrafield_global, size_extrafield_global, comment, method, level, raw, windowBits, memLevel, strategy, password, crcForCrypting, VERSIONMADEBY, 0, zip64); } extern int ZEXPORT zipOpenNewFileInZip2(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int raw) { return zipOpenNewFileInZip4_64(file, filename, zipfi, extrafield_local, size_extrafield_local, extrafield_global, size_extrafield_global, comment, method, level, raw, -MAX_WBITS, DEF_MEM_LEVEL, Z_DEFAULT_STRATEGY, NULL, 0, VERSIONMADEBY, 0, 0); } extern int ZEXPORT zipOpenNewFileInZip2_64(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void* extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int raw, int zip64) { return zipOpenNewFileInZip4_64(file, filename, zipfi, extrafield_local, size_extrafield_local, extrafield_global, size_extrafield_global, comment, method, level, raw, -MAX_WBITS, DEF_MEM_LEVEL, Z_DEFAULT_STRATEGY, NULL, 0, VERSIONMADEBY, 0, zip64); } extern int ZEXPORT zipOpenNewFileInZip64(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void*extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level, int zip64) { return zipOpenNewFileInZip4_64(file, filename, zipfi, extrafield_local, size_extrafield_local, extrafield_global, size_extrafield_global, comment, method, level, 0, -MAX_WBITS, DEF_MEM_LEVEL, Z_DEFAULT_STRATEGY, NULL, 0, VERSIONMADEBY, 0, zip64); } extern int ZEXPORT zipOpenNewFileInZip(zipFile file, const char* filename, const zip_fileinfo* zipfi, const void* extrafield_local, uInt size_extrafield_local, const void*extrafield_global, uInt size_extrafield_global, const char* comment, int method, int level) { return zipOpenNewFileInZip4_64(file, filename, zipfi, extrafield_local, size_extrafield_local, extrafield_global, size_extrafield_global, comment, method, level, 0, -MAX_WBITS, DEF_MEM_LEVEL, Z_DEFAULT_STRATEGY, NULL, 0, VERSIONMADEBY, 0, 0); } local int zip64FlushWriteBuffer(zip64_internal* zi) { int err=ZIP_OK; if (zi->ci.encrypt != 0) { #ifndef NOCRYPT uInt i; int t; for (i=0;ici.pos_in_buffered_data;i++) zi->ci.buffered_data[i] = zencode(zi->ci.keys, zi->ci.pcrc_32_tab, zi->ci.buffered_data[i],t); #endif } if (ZWRITE64(zi->z_filefunc,zi->filestream,zi->ci.buffered_data,zi->ci.pos_in_buffered_data) != zi->ci.pos_in_buffered_data) err = ZIP_ERRNO; zi->ci.totalCompressedData += zi->ci.pos_in_buffered_data; #ifdef HAVE_BZIP2 if(zi->ci.method == Z_BZIP2ED) { zi->ci.totalUncompressedData += zi->ci.bstream.total_in_lo32; zi->ci.bstream.total_in_lo32 = 0; zi->ci.bstream.total_in_hi32 = 0; } else #endif { zi->ci.totalUncompressedData += zi->ci.stream.total_in; zi->ci.stream.total_in = 0; } zi->ci.pos_in_buffered_data = 0; return err; } extern int ZEXPORT zipWriteInFileInZip(zipFile file, const void* buf, unsigned int len) { zip64_internal* zi; int err=ZIP_OK; if (file == NULL) return ZIP_PARAMERROR; zi = (zip64_internal*)file; if (zi->in_opened_file_inzip == 0) return ZIP_PARAMERROR; zi->ci.crc32 = crc32(zi->ci.crc32,buf,(uInt)len); #ifdef HAVE_BZIP2 if(zi->ci.method == Z_BZIP2ED && (!zi->ci.raw)) { zi->ci.bstream.next_in = (void*)buf; zi->ci.bstream.avail_in = len; err = BZ_RUN_OK; while ((err==BZ_RUN_OK) && (zi->ci.bstream.avail_in>0)) { if (zi->ci.bstream.avail_out == 0) { if (zip64FlushWriteBuffer(zi) == ZIP_ERRNO) err = ZIP_ERRNO; zi->ci.bstream.avail_out = (uInt)Z_BUFSIZE; zi->ci.bstream.next_out = (char*)zi->ci.buffered_data; } if(err != BZ_RUN_OK) break; if ((zi->ci.method == Z_BZIP2ED) && (!zi->ci.raw)) { uLong uTotalOutBefore_lo = zi->ci.bstream.total_out_lo32; // uLong uTotalOutBefore_hi = zi->ci.bstream.total_out_hi32; err=BZ2_bzCompress(&zi->ci.bstream, BZ_RUN); zi->ci.pos_in_buffered_data += (uInt)(zi->ci.bstream.total_out_lo32 - uTotalOutBefore_lo) ; } } if(err == BZ_RUN_OK) err = ZIP_OK; } else #endif { zi->ci.stream.next_in = buf; zi->ci.stream.avail_in = len; while ((err==ZIP_OK) && (zi->ci.stream.avail_in>0)) { if (zi->ci.stream.avail_out == 0) { if (zip64FlushWriteBuffer(zi) == ZIP_ERRNO) err = ZIP_ERRNO; zi->ci.stream.avail_out = (uInt)Z_BUFSIZE; zi->ci.stream.next_out = zi->ci.buffered_data; } if(err != ZIP_OK) break; if ((zi->ci.method == Z_DEFLATED) && (!zi->ci.raw)) { uLong uTotalOutBefore = zi->ci.stream.total_out; err=deflate(&zi->ci.stream, Z_NO_FLUSH); zi->ci.pos_in_buffered_data += (uInt)(zi->ci.stream.total_out - uTotalOutBefore) ; } else { uInt copy_this,i; if (zi->ci.stream.avail_in < zi->ci.stream.avail_out) copy_this = zi->ci.stream.avail_in; else copy_this = zi->ci.stream.avail_out; for (i = 0; i < copy_this; i++) *(((char*)zi->ci.stream.next_out)+i) = *(((const char*)zi->ci.stream.next_in)+i); { zi->ci.stream.avail_in -= copy_this; zi->ci.stream.avail_out-= copy_this; zi->ci.stream.next_in+= copy_this; zi->ci.stream.next_out+= copy_this; zi->ci.stream.total_in+= copy_this; zi->ci.stream.total_out+= copy_this; zi->ci.pos_in_buffered_data += copy_this; } } }// while(...) } return err; } extern int ZEXPORT zipCloseFileInZipRaw(zipFile file, uLong uncompressed_size, uLong crc32) { return zipCloseFileInZipRaw64 (file, uncompressed_size, crc32); } extern int ZEXPORT zipCloseFileInZipRaw64(zipFile file, ZPOS64_T uncompressed_size, uLong crc32) { zip64_internal* zi; ZPOS64_T compressed_size; uLong invalidValue = 0xffffffff; unsigned datasize = 0; int err=ZIP_OK; if (file == NULL) return ZIP_PARAMERROR; zi = (zip64_internal*)file; if (zi->in_opened_file_inzip == 0) return ZIP_PARAMERROR; zi->ci.stream.avail_in = 0; if ((zi->ci.method == Z_DEFLATED) && (!zi->ci.raw)) { while (err==ZIP_OK) { uLong uTotalOutBefore; if (zi->ci.stream.avail_out == 0) { if (zip64FlushWriteBuffer(zi) == ZIP_ERRNO) err = ZIP_ERRNO; zi->ci.stream.avail_out = (uInt)Z_BUFSIZE; zi->ci.stream.next_out = zi->ci.buffered_data; } uTotalOutBefore = zi->ci.stream.total_out; err=deflate(&zi->ci.stream, Z_FINISH); zi->ci.pos_in_buffered_data += (uInt)(zi->ci.stream.total_out - uTotalOutBefore) ; } } else if ((zi->ci.method == Z_BZIP2ED) && (!zi->ci.raw)) { #ifdef HAVE_BZIP2 err = BZ_FINISH_OK; while (err==BZ_FINISH_OK) { uLong uTotalOutBefore; if (zi->ci.bstream.avail_out == 0) { if (zip64FlushWriteBuffer(zi) == ZIP_ERRNO) err = ZIP_ERRNO; zi->ci.bstream.avail_out = (uInt)Z_BUFSIZE; zi->ci.bstream.next_out = (char*)zi->ci.buffered_data; } uTotalOutBefore = zi->ci.bstream.total_out_lo32; err=BZ2_bzCompress(&zi->ci.bstream, BZ_FINISH); if(err == BZ_STREAM_END) err = Z_STREAM_END; zi->ci.pos_in_buffered_data += (uInt)(zi->ci.bstream.total_out_lo32 - uTotalOutBefore); } if(err == BZ_FINISH_OK) err = ZIP_OK; #endif } if (err==Z_STREAM_END) err=ZIP_OK; /* this is normal */ if ((zi->ci.pos_in_buffered_data>0) && (err==ZIP_OK)) { if (zip64FlushWriteBuffer(zi)==ZIP_ERRNO) err = ZIP_ERRNO; } if ((zi->ci.method == Z_DEFLATED) && (!zi->ci.raw)) { int tmp_err = deflateEnd(&zi->ci.stream); if (err == ZIP_OK) err = tmp_err; zi->ci.stream_initialised = 0; } #ifdef HAVE_BZIP2 else if((zi->ci.method == Z_BZIP2ED) && (!zi->ci.raw)) { int tmperr = BZ2_bzCompressEnd(&zi->ci.bstream); if (err==ZIP_OK) err = tmperr; zi->ci.stream_initialised = 0; } #endif if (!zi->ci.raw) { crc32 = (uLong)zi->ci.crc32; uncompressed_size = zi->ci.totalUncompressedData; } compressed_size = zi->ci.totalCompressedData; # ifndef NOCRYPT compressed_size += zi->ci.crypt_header_size; # endif // update Current Item crc and sizes, if(compressed_size >= 0xffffffff || uncompressed_size >= 0xffffffff || zi->ci.pos_local_header >= 0xffffffff) { /*version Made by*/ zip64local_putValue_inmemory(zi->ci.central_header+4,(uLong)45,2); /*version needed*/ zip64local_putValue_inmemory(zi->ci.central_header+6,(uLong)45,2); } zip64local_putValue_inmemory(zi->ci.central_header+16,crc32,4); /*crc*/ if(compressed_size >= 0xffffffff) zip64local_putValue_inmemory(zi->ci.central_header+20, invalidValue,4); /*compr size*/ else zip64local_putValue_inmemory(zi->ci.central_header+20, compressed_size,4); /*compr size*/ /// set internal file attributes field if (zi->ci.stream.data_type == Z_ASCII) zip64local_putValue_inmemory(zi->ci.central_header+36,(uLong)Z_ASCII,2); if(uncompressed_size >= 0xffffffff) zip64local_putValue_inmemory(zi->ci.central_header+24, invalidValue,4); /*uncompr size*/ else zip64local_putValue_inmemory(zi->ci.central_header+24, uncompressed_size,4); /*uncompr size*/ // Add ZIP64 extra info field for uncompressed size if(uncompressed_size >= 0xffffffff) datasize += 8; // Add ZIP64 extra info field for compressed size if(compressed_size >= 0xffffffff) datasize += 8; // Add ZIP64 extra info field for relative offset to local file header of current file if(zi->ci.pos_local_header >= 0xffffffff) datasize += 8; if(datasize > 0) { char* p = NULL; if((uLong)(datasize + 4) > zi->ci.size_centralExtraFree) { // we cannot write more data to the buffer that we have room for. return ZIP_BADZIPFILE; } p = zi->ci.central_header + zi->ci.size_centralheader; // Add Extra Information Header for 'ZIP64 information' zip64local_putValue_inmemory(p, 0x0001, 2); // HeaderID p += 2; zip64local_putValue_inmemory(p, datasize, 2); // DataSize p += 2; if(uncompressed_size >= 0xffffffff) { zip64local_putValue_inmemory(p, uncompressed_size, 8); p += 8; } if(compressed_size >= 0xffffffff) { zip64local_putValue_inmemory(p, compressed_size, 8); p += 8; } if(zi->ci.pos_local_header >= 0xffffffff) { zip64local_putValue_inmemory(p, zi->ci.pos_local_header, 8); p += 8; } // Update how much extra free space we got in the memory buffer // and increase the centralheader size so the new ZIP64 fields are included // ( 4 below is the size of HeaderID and DataSize field ) zi->ci.size_centralExtraFree -= datasize + 4; zi->ci.size_centralheader += datasize + 4; // Update the extra info size field zi->ci.size_centralExtra += datasize + 4; zip64local_putValue_inmemory(zi->ci.central_header+30,(uLong)zi->ci.size_centralExtra,2); } if (err==ZIP_OK) err = add_data_in_datablock(&zi->central_dir, zi->ci.central_header, (uLong)zi->ci.size_centralheader); free(zi->ci.central_header); if (err==ZIP_OK) { // Update the LocalFileHeader with the new values. ZPOS64_T cur_pos_inzip = ZTELL64(zi->z_filefunc,zi->filestream); if (ZSEEK64(zi->z_filefunc,zi->filestream, zi->ci.pos_local_header + 14,ZLIB_FILEFUNC_SEEK_SET)!=0) err = ZIP_ERRNO; if (err==ZIP_OK) err = zip64local_putValue(&zi->z_filefunc,zi->filestream,crc32,4); /* crc 32, unknown */ if(uncompressed_size >= 0xffffffff || compressed_size >= 0xffffffff ) { if(zi->ci.pos_zip64extrainfo > 0) { // Update the size in the ZIP64 extended field. if (ZSEEK64(zi->z_filefunc,zi->filestream, zi->ci.pos_zip64extrainfo + 4,ZLIB_FILEFUNC_SEEK_SET)!=0) err = ZIP_ERRNO; if (err==ZIP_OK) /* compressed size, unknown */ err = zip64local_putValue(&zi->z_filefunc, zi->filestream, uncompressed_size, 8); if (err==ZIP_OK) /* uncompressed size, unknown */ err = zip64local_putValue(&zi->z_filefunc, zi->filestream, compressed_size, 8); } else err = ZIP_BADZIPFILE; // Caller passed zip64 = 0, so no room for zip64 info -> fatal } else { if (err==ZIP_OK) /* compressed size, unknown */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,compressed_size,4); if (err==ZIP_OK) /* uncompressed size, unknown */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,uncompressed_size,4); } if (ZSEEK64(zi->z_filefunc,zi->filestream, cur_pos_inzip,ZLIB_FILEFUNC_SEEK_SET)!=0) err = ZIP_ERRNO; } zi->number_entry ++; zi->in_opened_file_inzip = 0; return err; } extern int ZEXPORT zipCloseFileInZip(zipFile file) { return zipCloseFileInZipRaw (file,0,0); } local int Write_Zip64EndOfCentralDirectoryLocator(zip64_internal* zi, ZPOS64_T zip64eocd_pos_inzip) { int err = ZIP_OK; ZPOS64_T pos = zip64eocd_pos_inzip - zi->add_position_when_writing_offset; err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)ZIP64ENDLOCHEADERMAGIC,4); /*num disks*/ if (err==ZIP_OK) /* number of the disk with the start of the central directory */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)0,4); /*relative offset*/ if (err==ZIP_OK) /* Relative offset to the Zip64EndOfCentralDirectory */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream, pos,8); /*total disks*/ /* Do not support spawning of disk so always say 1 here*/ if (err==ZIP_OK) /* number of the disk with the start of the central directory */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)1,4); return err; } local int Write_Zip64EndOfCentralDirectoryRecord(zip64_internal* zi, uLong size_centraldir, ZPOS64_T centraldir_pos_inzip) { int err = ZIP_OK; uLong Zip64DataSize = 44; err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)ZIP64ENDHEADERMAGIC,4); if (err==ZIP_OK) /* size of this 'zip64 end of central directory' */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(ZPOS64_T)Zip64DataSize,8); // why ZPOS64_T of this ? if (err==ZIP_OK) /* version made by */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)45,2); if (err==ZIP_OK) /* version needed */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)45,2); if (err==ZIP_OK) /* number of this disk */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)0,4); if (err==ZIP_OK) /* number of the disk with the start of the central directory */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)0,4); if (err==ZIP_OK) /* total number of entries in the central dir on this disk */ err = zip64local_putValue(&zi->z_filefunc, zi->filestream, zi->number_entry, 8); if (err==ZIP_OK) /* total number of entries in the central dir */ err = zip64local_putValue(&zi->z_filefunc, zi->filestream, zi->number_entry, 8); if (err==ZIP_OK) /* size of the central directory */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(ZPOS64_T)size_centraldir,8); if (err==ZIP_OK) /* offset of start of central directory with respect to the starting disk number */ { ZPOS64_T pos = centraldir_pos_inzip - zi->add_position_when_writing_offset; err = zip64local_putValue(&zi->z_filefunc,zi->filestream, (ZPOS64_T)pos,8); } return err; } local int Write_EndOfCentralDirectoryRecord(zip64_internal* zi, uLong size_centraldir, ZPOS64_T centraldir_pos_inzip) { int err = ZIP_OK; /*signature*/ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)ENDHEADERMAGIC,4); if (err==ZIP_OK) /* number of this disk */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)0,2); if (err==ZIP_OK) /* number of the disk with the start of the central directory */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)0,2); if (err==ZIP_OK) /* total number of entries in the central dir on this disk */ { { if(zi->number_entry >= 0xFFFF) err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)0xffff,2); // use value in ZIP64 record else err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)zi->number_entry,2); } } if (err==ZIP_OK) /* total number of entries in the central dir */ { if(zi->number_entry >= 0xFFFF) err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)0xffff,2); // use value in ZIP64 record else err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)zi->number_entry,2); } if (err==ZIP_OK) /* size of the central directory */ err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)size_centraldir,4); if (err==ZIP_OK) /* offset of start of central directory with respect to the starting disk number */ { ZPOS64_T pos = centraldir_pos_inzip - zi->add_position_when_writing_offset; if(pos >= 0xffffffff) { err = zip64local_putValue(&zi->z_filefunc,zi->filestream, (uLong)0xffffffff,4); } else err = zip64local_putValue(&zi->z_filefunc,zi->filestream, (uLong)(centraldir_pos_inzip - zi->add_position_when_writing_offset),4); } return err; } local int Write_GlobalComment(zip64_internal* zi, const char* global_comment) { int err = ZIP_OK; uInt size_global_comment = 0; if(global_comment != NULL) size_global_comment = (uInt)strlen(global_comment); err = zip64local_putValue(&zi->z_filefunc,zi->filestream,(uLong)size_global_comment,2); if (err == ZIP_OK && size_global_comment > 0) { if (ZWRITE64(zi->z_filefunc,zi->filestream, global_comment, size_global_comment) != size_global_comment) err = ZIP_ERRNO; } return err; } extern int ZEXPORT zipFlush (zipFile file) { zip64_internal* zi; if (file == NULL) return ZIP_PARAMERROR; zi = (zip64_internal*)file; return ZFLUSH64(zi->z_filefunc,zi->filestream); } extern int ZEXPORT zipClose(zipFile file, const char* global_comment) { zip64_internal* zi; int err = 0; uLong size_centraldir = 0; ZPOS64_T centraldir_pos_inzip; ZPOS64_T pos; if (file == NULL) return ZIP_PARAMERROR; zi = (zip64_internal*)file; if (zi->in_opened_file_inzip == 1) { err = zipCloseFileInZip (file); } #ifndef NO_ADDFILEINEXISTINGZIP if (global_comment==NULL) global_comment = zi->globalcomment; #endif centraldir_pos_inzip = ZTELL64(zi->z_filefunc,zi->filestream); if (err==ZIP_OK) { linkedlist_datablock_internal* ldi = zi->central_dir.first_block; while (ldi!=NULL) { if ((err==ZIP_OK) && (ldi->filled_in_this_block>0)) { if (ZWRITE64(zi->z_filefunc,zi->filestream, ldi->data, ldi->filled_in_this_block) != ldi->filled_in_this_block) err = ZIP_ERRNO; } size_centraldir += ldi->filled_in_this_block; ldi = ldi->next_datablock; } } free_linkedlist(&(zi->central_dir)); pos = centraldir_pos_inzip - zi->add_position_when_writing_offset; if(pos >= 0xffffffff || zi->number_entry >= 0xFFFF) { ZPOS64_T Zip64EOCDpos = ZTELL64(zi->z_filefunc,zi->filestream); Write_Zip64EndOfCentralDirectoryRecord(zi, size_centraldir, centraldir_pos_inzip); Write_Zip64EndOfCentralDirectoryLocator(zi, Zip64EOCDpos); } if (err==ZIP_OK) err = Write_EndOfCentralDirectoryRecord(zi, size_centraldir, centraldir_pos_inzip); if(err == ZIP_OK) err = Write_GlobalComment(zi, global_comment); if (ZCLOSE64(zi->z_filefunc,zi->filestream) != 0) if (err == ZIP_OK) err = ZIP_ERRNO; #ifndef NO_ADDFILEINEXISTINGZIP free(zi->globalcomment); #endif free(zi); return err; } extern int ZEXPORT zipRemoveExtraInfoBlock(char* pData, int* dataLen, short sHeader) { char* p = pData; int size = 0; char* pNewHeader; char* pTmp; short header; short dataSize; int retVal = ZIP_OK; if(pData == NULL || dataLen == NULL || *dataLen < 4) return ZIP_PARAMERROR; pNewHeader = (char*)ALLOC((unsigned)*dataLen); pTmp = pNewHeader; while(p < (pData + *dataLen)) { header = *(short*)p; dataSize = *(((short*)p)+1); if( header == sHeader ) // Header found. { p += dataSize + 4; // skip it. do not copy to temp buffer } else { // Extra Info block should not be removed, So copy it to the temp buffer. memcpy(pTmp, p, dataSize + 4); p += dataSize + 4; size += dataSize + 4; } } if(size < *dataLen) { // clean old extra info block. memset(pData,0, *dataLen); // copy the new extra info block over the old if(size > 0) memcpy(pData, pNewHeader, size); // set the new extra info size *dataLen = size; retVal = ZIP_OK; } else retVal = ZIP_ERRNO; free(pNewHeader); return retVal; } httrack-3.49.5/src/minizip/unzip.c0000644000175000017500000020407014555201641013762 00000000000000/* unzip.c -- IO for uncompress .zip files using zlib Version 1.1, February 14h, 2010 part of the MiniZip project - ( http://www.winimage.com/zLibDll/minizip.html ) Copyright (C) 1998-2010 Gilles Vollant (minizip) ( http://www.winimage.com/zLibDll/minizip.html ) Modifications of Unzip for Zip64 Copyright (C) 2007-2008 Even Rouault Modifications for Zip64 support on both zip and unzip Copyright (C) 2009-2010 Mathias Svensson ( http://result42.com ) For more info read MiniZip_info.txt ------------------------------------------------------------------------------------ Decryption code comes from crypt.c by Info-ZIP but has been greatly reduced in terms of compatibility with older software. The following is from the original crypt.c. Code woven in by Terry Thorsen 1/2003. Copyright (c) 1990-2000 Info-ZIP. All rights reserved. See the accompanying file LICENSE, version 2000-Apr-09 or later (the contents of which are also included in zip.h) for terms of use. If, for some reason, all these files are missing, the Info-ZIP license also may be found at: ftp://ftp.info-zip.org/pub/infozip/license.html crypt.c (full version) by Info-ZIP. Last revised: [see crypt.h] The encryption/decryption parts of this source code (as opposed to the non-echoing password parts) were originally written in Europe. The whole source package can be freely distributed, including from the USA. (Prior to January 2000, re-export from the US was a violation of US law.) This encryption code is a direct transcription of the algorithm from Roger Schlafly, described by Phil Katz in the file appnote.txt. This file (appnote.txt) is distributed with the PKZIP program (even in the version without encryption capabilities). ------------------------------------------------------------------------------------ Changes in unzip.c 2007-2008 - Even Rouault - Addition of cpl_unzGetCurrentFileZStreamPos 2007-2008 - Even Rouault - Decoration of symbol names unz* -> cpl_unz* 2007-2008 - Even Rouault - Remove old C style function prototypes 2007-2008 - Even Rouault - Add unzip support for ZIP64 Copyright (C) 2007-2008 Even Rouault Oct-2009 - Mathias Svensson - Removed cpl_* from symbol names (Even Rouault added them but since this is now moved to a new project (minizip64) I renamed them again). Oct-2009 - Mathias Svensson - Fixed problem if uncompressed size was > 4G and compressed size was <4G should only read the compressed/uncompressed size from the Zip64 format if the size from normal header was 0xFFFFFFFF Oct-2009 - Mathias Svensson - Applied some bug fixes from patches received from Gilles Vollant Oct-2009 - Mathias Svensson - Applied support to unzip files with compression method BZIP2 (bzip2 lib is required) Patch created by Daniel Borca Jan-2010 - back to unzip and minizip 1.0 name scheme, with compatibility layer Copyright (C) 1998 - 2010 Gilles Vollant, Even Rouault, Mathias Svensson */ #include #include #include #ifndef NOUNCRYPT #define NOUNCRYPT #endif #include "zlib.h" #include "unzip.h" #ifdef STDC # include #endif #ifdef NO_ERRNO_H extern int errno; #else # include #endif #ifndef local # define local static #endif /* compile with -Dlocal if your debugger can't find static symbols */ #ifndef CASESENSITIVITYDEFAULT_NO # if !defined(unix) && !defined(CASESENSITIVITYDEFAULT_YES) # define CASESENSITIVITYDEFAULT_NO # endif #endif #ifndef UNZ_BUFSIZE #define UNZ_BUFSIZE (16384) #endif #ifndef UNZ_MAXFILENAMEINZIP #define UNZ_MAXFILENAMEINZIP (256) #endif #ifndef ALLOC # define ALLOC(size) (malloc(size)) #endif #define SIZECENTRALDIRITEM (0x2e) #define SIZEZIPLOCALHEADER (0x1e) const char unz_copyright[] = " unzip 1.01 Copyright 1998-2004 Gilles Vollant - http://www.winimage.com/zLibDll"; /* unz_file_info64_internal contain internal info about a file in zipfile*/ typedef struct unz_file_info64_internal_s { ZPOS64_T offset_curfile;/* relative offset of local header 8 bytes */ } unz_file_info64_internal; /* file_in_zip_read_info_s contain internal information about a file in zipfile, when reading and decompress it */ typedef struct { char *read_buffer; /* internal buffer for compressed data */ z_stream stream; /* zLib stream structure for inflate */ #ifdef HAVE_BZIP2 bz_stream bstream; /* bzLib stream structure for bziped */ #endif ZPOS64_T pos_in_zipfile; /* position in byte on the zipfile, for fseek*/ uLong stream_initialised; /* flag set if stream structure is initialised*/ ZPOS64_T offset_local_extrafield;/* offset of the local extra field */ uInt size_local_extrafield;/* size of the local extra field */ ZPOS64_T pos_local_extrafield; /* position in the local extra field in read*/ ZPOS64_T total_out_64; uLong crc32; /* crc32 of all data uncompressed */ uLong crc32_wait; /* crc32 we must obtain after decompress all */ ZPOS64_T rest_read_compressed; /* number of byte to be decompressed */ ZPOS64_T rest_read_uncompressed;/*number of byte to be obtained after decomp*/ zlib_filefunc64_32_def z_filefunc; voidpf filestream; /* io structure of the zipfile */ uLong compression_method; /* compression method (0==store) */ ZPOS64_T byte_before_the_zipfile;/* byte before the zipfile, (>0 for sfx)*/ int raw; } file_in_zip64_read_info_s; /* unz64_s contain internal information about the zipfile */ typedef struct { zlib_filefunc64_32_def z_filefunc; int is64bitOpenFunction; voidpf filestream; /* io structure of the zipfile */ unz_global_info64 gi; /* public global information */ ZPOS64_T byte_before_the_zipfile;/* byte before the zipfile, (>0 for sfx)*/ ZPOS64_T num_file; /* number of the current file in the zipfile*/ ZPOS64_T pos_in_central_dir; /* pos of the current file in the central dir*/ ZPOS64_T current_file_ok; /* flag about the usability of the current file*/ ZPOS64_T central_pos; /* position of the beginning of the central dir*/ ZPOS64_T size_central_dir; /* size of the central directory */ ZPOS64_T offset_central_dir; /* offset of start of central directory with respect to the starting disk number */ unz_file_info64 cur_file_info; /* public info about the current file in zip*/ unz_file_info64_internal cur_file_info_internal; /* private info about it*/ file_in_zip64_read_info_s* pfile_in_zip_read; /* structure about the current file if we are decompressing it */ int encrypted; int isZip64; # ifndef NOUNCRYPT unsigned long keys[3]; /* keys defining the pseudo-random sequence */ const z_crc_t* pcrc_32_tab; # endif } unz64_s; #ifndef NOUNCRYPT #include "crypt.h" #endif /* =========================================================================== Reads a long in LSB order from the given gz_stream. Sets */ local int unz64local_getShort(const zlib_filefunc64_32_def* pzlib_filefunc_def, voidpf filestream, uLong *pX) { unsigned char c[2]; int err = (int)ZREAD64(*pzlib_filefunc_def,filestream,c,2); if (err==2) { *pX = c[0] | ((uLong)c[1] << 8); return UNZ_OK; } else { *pX = 0; if (ZERROR64(*pzlib_filefunc_def,filestream)) return UNZ_ERRNO; else return UNZ_EOF; } } local int unz64local_getLong(const zlib_filefunc64_32_def* pzlib_filefunc_def, voidpf filestream, uLong *pX) { unsigned char c[4]; int err = (int)ZREAD64(*pzlib_filefunc_def,filestream,c,4); if (err==4) { *pX = c[0] | ((uLong)c[1] << 8) | ((uLong)c[2] << 16) | ((uLong)c[3] << 24); return UNZ_OK; } else { *pX = 0; if (ZERROR64(*pzlib_filefunc_def,filestream)) return UNZ_ERRNO; else return UNZ_EOF; } } local int unz64local_getLong64(const zlib_filefunc64_32_def* pzlib_filefunc_def, voidpf filestream, ZPOS64_T *pX) { unsigned char c[8]; int err = (int)ZREAD64(*pzlib_filefunc_def,filestream,c,8); if (err==8) { *pX = c[0] | ((ZPOS64_T)c[1] << 8) | ((ZPOS64_T)c[2] << 16) | ((ZPOS64_T)c[3] << 24) | ((ZPOS64_T)c[4] << 32) | ((ZPOS64_T)c[5] << 40) | ((ZPOS64_T)c[6] << 48) | ((ZPOS64_T)c[7] << 56); return UNZ_OK; } else { *pX = 0; if (ZERROR64(*pzlib_filefunc_def,filestream)) return UNZ_ERRNO; else return UNZ_EOF; } } /* My own strcmpi / strcasecmp */ local int strcmpcasenosensitive_internal(const char* fileName1, const char* fileName2) { for (;;) { char c1=*(fileName1++); char c2=*(fileName2++); if ((c1>='a') && (c1<='z')) c1 -= 0x20; if ((c2>='a') && (c2<='z')) c2 -= 0x20; if (c1=='\0') return ((c2=='\0') ? 0 : -1); if (c2=='\0') return 1; if (c1c2) return 1; } } #ifdef CASESENSITIVITYDEFAULT_NO #define CASESENSITIVITYDEFAULTVALUE 2 #else #define CASESENSITIVITYDEFAULTVALUE 1 #endif #ifndef STRCMPCASENOSENTIVEFUNCTION #define STRCMPCASENOSENTIVEFUNCTION strcmpcasenosensitive_internal #endif /* Compare two filenames (fileName1,fileName2). If iCaseSensitivity = 1, comparison is case sensitive (like strcmp) If iCaseSensitivity = 2, comparison is not case sensitive (like strcmpi or strcasecmp) If iCaseSensitivity = 0, case sensitivity is default of your operating system (like 1 on Unix, 2 on Windows) */ extern int ZEXPORT unzStringFileNameCompare (const char* fileName1, const char* fileName2, int iCaseSensitivity) { if (iCaseSensitivity==0) iCaseSensitivity=CASESENSITIVITYDEFAULTVALUE; if (iCaseSensitivity==1) return strcmp(fileName1,fileName2); return STRCMPCASENOSENTIVEFUNCTION(fileName1,fileName2); } #ifndef BUFREADCOMMENT #define BUFREADCOMMENT (0x400) #endif #ifndef CENTRALDIRINVALID #define CENTRALDIRINVALID ((ZPOS64_T)(-1)) #endif /* Locate the Central directory of a zipfile (at the end, just before the global comment) */ local ZPOS64_T unz64local_SearchCentralDir(const zlib_filefunc64_32_def* pzlib_filefunc_def, voidpf filestream) { unsigned char* buf; ZPOS64_T uSizeFile; ZPOS64_T uBackRead; ZPOS64_T uMaxBack=0xffff; /* maximum size of global comment */ ZPOS64_T uPosFound=CENTRALDIRINVALID; if (ZSEEK64(*pzlib_filefunc_def,filestream,0,ZLIB_FILEFUNC_SEEK_END) != 0) return CENTRALDIRINVALID; uSizeFile = ZTELL64(*pzlib_filefunc_def,filestream); if (uMaxBack>uSizeFile) uMaxBack = uSizeFile; buf = (unsigned char*)ALLOC(BUFREADCOMMENT+4); if (buf==NULL) return CENTRALDIRINVALID; uBackRead = 4; while (uBackReaduMaxBack) uBackRead = uMaxBack; else uBackRead+=BUFREADCOMMENT; uReadPos = uSizeFile-uBackRead ; uReadSize = ((BUFREADCOMMENT+4) < (uSizeFile-uReadPos)) ? (BUFREADCOMMENT+4) : (uLong)(uSizeFile-uReadPos); if (ZSEEK64(*pzlib_filefunc_def,filestream,uReadPos,ZLIB_FILEFUNC_SEEK_SET)!=0) break; if (ZREAD64(*pzlib_filefunc_def,filestream,buf,uReadSize)!=uReadSize) break; for (i=(int)uReadSize-3; (i--)>0;) if (((*(buf+i))==0x50) && ((*(buf+i+1))==0x4b) && ((*(buf+i+2))==0x05) && ((*(buf+i+3))==0x06)) { uPosFound = uReadPos+(unsigned)i; break; } if (uPosFound!=CENTRALDIRINVALID) break; } free(buf); return uPosFound; } /* Locate the Central directory 64 of a zipfile (at the end, just before the global comment) */ local ZPOS64_T unz64local_SearchCentralDir64(const zlib_filefunc64_32_def* pzlib_filefunc_def, voidpf filestream) { unsigned char* buf; ZPOS64_T uSizeFile; ZPOS64_T uBackRead; ZPOS64_T uMaxBack=0xffff; /* maximum size of global comment */ ZPOS64_T uPosFound=CENTRALDIRINVALID; uLong uL; ZPOS64_T relativeOffset; if (ZSEEK64(*pzlib_filefunc_def,filestream,0,ZLIB_FILEFUNC_SEEK_END) != 0) return CENTRALDIRINVALID; uSizeFile = ZTELL64(*pzlib_filefunc_def,filestream); if (uMaxBack>uSizeFile) uMaxBack = uSizeFile; buf = (unsigned char*)ALLOC(BUFREADCOMMENT+4); if (buf==NULL) return CENTRALDIRINVALID; uBackRead = 4; while (uBackReaduMaxBack) uBackRead = uMaxBack; else uBackRead+=BUFREADCOMMENT; uReadPos = uSizeFile-uBackRead ; uReadSize = ((BUFREADCOMMENT+4) < (uSizeFile-uReadPos)) ? (BUFREADCOMMENT+4) : (uLong)(uSizeFile-uReadPos); if (ZSEEK64(*pzlib_filefunc_def,filestream,uReadPos,ZLIB_FILEFUNC_SEEK_SET)!=0) break; if (ZREAD64(*pzlib_filefunc_def,filestream,buf,uReadSize)!=uReadSize) break; for (i=(int)uReadSize-3; (i--)>0;) if (((*(buf+i))==0x50) && ((*(buf+i+1))==0x4b) && ((*(buf+i+2))==0x06) && ((*(buf+i+3))==0x07)) { uPosFound = uReadPos+(unsigned)i; break; } if (uPosFound!=CENTRALDIRINVALID) break; } free(buf); if (uPosFound == CENTRALDIRINVALID) return CENTRALDIRINVALID; /* Zip64 end of central directory locator */ if (ZSEEK64(*pzlib_filefunc_def,filestream, uPosFound,ZLIB_FILEFUNC_SEEK_SET)!=0) return CENTRALDIRINVALID; /* the signature, already checked */ if (unz64local_getLong(pzlib_filefunc_def,filestream,&uL)!=UNZ_OK) return CENTRALDIRINVALID; /* number of the disk with the start of the zip64 end of central directory */ if (unz64local_getLong(pzlib_filefunc_def,filestream,&uL)!=UNZ_OK) return CENTRALDIRINVALID; if (uL != 0) return CENTRALDIRINVALID; /* relative offset of the zip64 end of central directory record */ if (unz64local_getLong64(pzlib_filefunc_def,filestream,&relativeOffset)!=UNZ_OK) return CENTRALDIRINVALID; /* total number of disks */ if (unz64local_getLong(pzlib_filefunc_def,filestream,&uL)!=UNZ_OK) return CENTRALDIRINVALID; if (uL != 1) return CENTRALDIRINVALID; /* Goto end of central directory record */ if (ZSEEK64(*pzlib_filefunc_def,filestream, relativeOffset,ZLIB_FILEFUNC_SEEK_SET)!=0) return CENTRALDIRINVALID; /* the signature */ if (unz64local_getLong(pzlib_filefunc_def,filestream,&uL)!=UNZ_OK) return CENTRALDIRINVALID; if (uL != 0x06064b50) return CENTRALDIRINVALID; return relativeOffset; } /* Open a Zip file. path contain the full pathname (by example, on a Windows NT computer "c:\\test\\zlib114.zip" or on an Unix computer "zlib/zlib114.zip". If the zipfile cannot be opened (file doesn't exist or in not valid), the return value is NULL. Else, the return value is a unzFile Handle, usable with other function of this unzip package. */ local unzFile unzOpenInternal(const void *path, zlib_filefunc64_32_def* pzlib_filefunc64_32_def, int is64bitOpenFunction) { unz64_s us; unz64_s *s; ZPOS64_T central_pos; uLong uL; uLong number_disk; /* number of the current disk, used for spanning ZIP, unsupported, always 0*/ uLong number_disk_with_CD; /* number the disk with central dir, used for spanning ZIP, unsupported, always 0*/ ZPOS64_T number_entry_CD; /* total number of entries in the central dir (same than number_entry on nospan) */ int err=UNZ_OK; if (unz_copyright[0]!=' ') return NULL; us.z_filefunc.zseek32_file = NULL; us.z_filefunc.ztell32_file = NULL; if (pzlib_filefunc64_32_def==NULL) fill_fopen64_filefunc(&us.z_filefunc.zfile_func64); else us.z_filefunc = *pzlib_filefunc64_32_def; us.is64bitOpenFunction = is64bitOpenFunction; us.filestream = ZOPEN64(us.z_filefunc, path, ZLIB_FILEFUNC_MODE_READ | ZLIB_FILEFUNC_MODE_EXISTING); if (us.filestream==NULL) return NULL; central_pos = unz64local_SearchCentralDir64(&us.z_filefunc,us.filestream); if (central_pos!=CENTRALDIRINVALID) { uLong uS; ZPOS64_T uL64; us.isZip64 = 1; if (ZSEEK64(us.z_filefunc, us.filestream, central_pos,ZLIB_FILEFUNC_SEEK_SET)!=0) err=UNZ_ERRNO; /* the signature, already checked */ if (unz64local_getLong(&us.z_filefunc, us.filestream,&uL)!=UNZ_OK) err=UNZ_ERRNO; /* size of zip64 end of central directory record */ if (unz64local_getLong64(&us.z_filefunc, us.filestream,&uL64)!=UNZ_OK) err=UNZ_ERRNO; /* version made by */ if (unz64local_getShort(&us.z_filefunc, us.filestream,&uS)!=UNZ_OK) err=UNZ_ERRNO; /* version needed to extract */ if (unz64local_getShort(&us.z_filefunc, us.filestream,&uS)!=UNZ_OK) err=UNZ_ERRNO; /* number of this disk */ if (unz64local_getLong(&us.z_filefunc, us.filestream,&number_disk)!=UNZ_OK) err=UNZ_ERRNO; /* number of the disk with the start of the central directory */ if (unz64local_getLong(&us.z_filefunc, us.filestream,&number_disk_with_CD)!=UNZ_OK) err=UNZ_ERRNO; /* total number of entries in the central directory on this disk */ if (unz64local_getLong64(&us.z_filefunc, us.filestream,&us.gi.number_entry)!=UNZ_OK) err=UNZ_ERRNO; /* total number of entries in the central directory */ if (unz64local_getLong64(&us.z_filefunc, us.filestream,&number_entry_CD)!=UNZ_OK) err=UNZ_ERRNO; if ((number_entry_CD!=us.gi.number_entry) || (number_disk_with_CD!=0) || (number_disk!=0)) err=UNZ_BADZIPFILE; /* size of the central directory */ if (unz64local_getLong64(&us.z_filefunc, us.filestream,&us.size_central_dir)!=UNZ_OK) err=UNZ_ERRNO; /* offset of start of central directory with respect to the starting disk number */ if (unz64local_getLong64(&us.z_filefunc, us.filestream,&us.offset_central_dir)!=UNZ_OK) err=UNZ_ERRNO; us.gi.size_comment = 0; } else { central_pos = unz64local_SearchCentralDir(&us.z_filefunc,us.filestream); if (central_pos==CENTRALDIRINVALID) err=UNZ_ERRNO; us.isZip64 = 0; if (ZSEEK64(us.z_filefunc, us.filestream, central_pos,ZLIB_FILEFUNC_SEEK_SET)!=0) err=UNZ_ERRNO; /* the signature, already checked */ if (unz64local_getLong(&us.z_filefunc, us.filestream,&uL)!=UNZ_OK) err=UNZ_ERRNO; /* number of this disk */ if (unz64local_getShort(&us.z_filefunc, us.filestream,&number_disk)!=UNZ_OK) err=UNZ_ERRNO; /* number of the disk with the start of the central directory */ if (unz64local_getShort(&us.z_filefunc, us.filestream,&number_disk_with_CD)!=UNZ_OK) err=UNZ_ERRNO; /* total number of entries in the central dir on this disk */ if (unz64local_getShort(&us.z_filefunc, us.filestream,&uL)!=UNZ_OK) err=UNZ_ERRNO; us.gi.number_entry = uL; /* total number of entries in the central dir */ if (unz64local_getShort(&us.z_filefunc, us.filestream,&uL)!=UNZ_OK) err=UNZ_ERRNO; number_entry_CD = uL; if ((number_entry_CD!=us.gi.number_entry) || (number_disk_with_CD!=0) || (number_disk!=0)) err=UNZ_BADZIPFILE; /* size of the central directory */ if (unz64local_getLong(&us.z_filefunc, us.filestream,&uL)!=UNZ_OK) err=UNZ_ERRNO; us.size_central_dir = uL; /* offset of start of central directory with respect to the starting disk number */ if (unz64local_getLong(&us.z_filefunc, us.filestream,&uL)!=UNZ_OK) err=UNZ_ERRNO; us.offset_central_dir = uL; /* zipfile comment length */ if (unz64local_getShort(&us.z_filefunc, us.filestream,&us.gi.size_comment)!=UNZ_OK) err=UNZ_ERRNO; } if ((central_pospfile_in_zip_read!=NULL) unzCloseCurrentFile(file); ZCLOSE64(s->z_filefunc, s->filestream); free(s); return UNZ_OK; } /* Write info about the ZipFile in the *pglobal_info structure. No preparation of the structure is needed return UNZ_OK if there is no problem. */ extern int ZEXPORT unzGetGlobalInfo64(unzFile file, unz_global_info64* pglobal_info) { unz64_s* s; if (file==NULL) return UNZ_PARAMERROR; s=(unz64_s*)file; *pglobal_info=s->gi; return UNZ_OK; } extern int ZEXPORT unzGetGlobalInfo(unzFile file, unz_global_info* pglobal_info32) { unz64_s* s; if (file==NULL) return UNZ_PARAMERROR; s=(unz64_s*)file; /* to do : check if number_entry is not truncated */ pglobal_info32->number_entry = (uLong)s->gi.number_entry; pglobal_info32->size_comment = s->gi.size_comment; return UNZ_OK; } /* Translate date/time from Dos format to tm_unz (readable more easily) */ local void unz64local_DosDateToTmuDate(ZPOS64_T ulDosDate, tm_unz* ptm) { ZPOS64_T uDate; uDate = (ZPOS64_T)(ulDosDate>>16); ptm->tm_mday = (int)(uDate&0x1f) ; ptm->tm_mon = (int)((((uDate)&0x1E0)/0x20)-1) ; ptm->tm_year = (int)(((uDate&0x0FE00)/0x0200)+1980) ; ptm->tm_hour = (int) ((ulDosDate &0xF800)/0x800); ptm->tm_min = (int) ((ulDosDate&0x7E0)/0x20) ; ptm->tm_sec = (int) (2*(ulDosDate&0x1f)) ; } /* Get Info about the current file in the zipfile, with internal only info */ local int unz64local_GetCurrentFileInfoInternal(unzFile file, unz_file_info64 *pfile_info, unz_file_info64_internal *pfile_info_internal, char *szFileName, uLong fileNameBufferSize, void *extraField, uLong extraFieldBufferSize, char *szComment, uLong commentBufferSize) { unz64_s* s; unz_file_info64 file_info; unz_file_info64_internal file_info_internal; int err=UNZ_OK; uLong uMagic; long lSeek=0; uLong uL; if (file==NULL) return UNZ_PARAMERROR; s=(unz64_s*)file; if (ZSEEK64(s->z_filefunc, s->filestream, s->pos_in_central_dir+s->byte_before_the_zipfile, ZLIB_FILEFUNC_SEEK_SET)!=0) err=UNZ_ERRNO; /* we check the magic */ if (err==UNZ_OK) { if (unz64local_getLong(&s->z_filefunc, s->filestream,&uMagic) != UNZ_OK) err=UNZ_ERRNO; else if (uMagic!=0x02014b50) err=UNZ_BADZIPFILE; } if (unz64local_getShort(&s->z_filefunc, s->filestream,&file_info.version) != UNZ_OK) err=UNZ_ERRNO; if (unz64local_getShort(&s->z_filefunc, s->filestream,&file_info.version_needed) != UNZ_OK) err=UNZ_ERRNO; if (unz64local_getShort(&s->z_filefunc, s->filestream,&file_info.flag) != UNZ_OK) err=UNZ_ERRNO; if (unz64local_getShort(&s->z_filefunc, s->filestream,&file_info.compression_method) != UNZ_OK) err=UNZ_ERRNO; if (unz64local_getLong(&s->z_filefunc, s->filestream,&file_info.dosDate) != UNZ_OK) err=UNZ_ERRNO; unz64local_DosDateToTmuDate(file_info.dosDate,&file_info.tmu_date); if (unz64local_getLong(&s->z_filefunc, s->filestream,&file_info.crc) != UNZ_OK) err=UNZ_ERRNO; if (unz64local_getLong(&s->z_filefunc, s->filestream,&uL) != UNZ_OK) err=UNZ_ERRNO; file_info.compressed_size = uL; if (unz64local_getLong(&s->z_filefunc, s->filestream,&uL) != UNZ_OK) err=UNZ_ERRNO; file_info.uncompressed_size = uL; if (unz64local_getShort(&s->z_filefunc, s->filestream,&file_info.size_filename) != UNZ_OK) err=UNZ_ERRNO; if (unz64local_getShort(&s->z_filefunc, s->filestream,&file_info.size_file_extra) != UNZ_OK) err=UNZ_ERRNO; if (unz64local_getShort(&s->z_filefunc, s->filestream,&file_info.size_file_comment) != UNZ_OK) err=UNZ_ERRNO; if (unz64local_getShort(&s->z_filefunc, s->filestream,&file_info.disk_num_start) != UNZ_OK) err=UNZ_ERRNO; if (unz64local_getShort(&s->z_filefunc, s->filestream,&file_info.internal_fa) != UNZ_OK) err=UNZ_ERRNO; if (unz64local_getLong(&s->z_filefunc, s->filestream,&file_info.external_fa) != UNZ_OK) err=UNZ_ERRNO; // relative offset of local header if (unz64local_getLong(&s->z_filefunc, s->filestream,&uL) != UNZ_OK) err=UNZ_ERRNO; file_info_internal.offset_curfile = uL; lSeek+=file_info.size_filename; if ((err==UNZ_OK) && (szFileName!=NULL)) { uLong uSizeRead ; if (file_info.size_filename0) && (fileNameBufferSize>0)) if (ZREAD64(s->z_filefunc, s->filestream,szFileName,uSizeRead)!=uSizeRead) err=UNZ_ERRNO; lSeek -= uSizeRead; } // Read extrafield if ((err==UNZ_OK) && (extraField!=NULL)) { ZPOS64_T uSizeRead ; if (file_info.size_file_extraz_filefunc, s->filestream,(ZPOS64_T)lSeek,ZLIB_FILEFUNC_SEEK_CUR)==0) lSeek=0; else err=UNZ_ERRNO; } if ((file_info.size_file_extra>0) && (extraFieldBufferSize>0)) if (ZREAD64(s->z_filefunc, s->filestream,extraField,(uLong)uSizeRead)!=uSizeRead) err=UNZ_ERRNO; lSeek += file_info.size_file_extra - (uLong)uSizeRead; } else lSeek += file_info.size_file_extra; if ((err==UNZ_OK) && (file_info.size_file_extra != 0)) { uLong acc = 0; // since lSeek now points to after the extra field we need to move back lSeek -= file_info.size_file_extra; if (lSeek!=0) { if (ZSEEK64(s->z_filefunc, s->filestream,(ZPOS64_T)lSeek,ZLIB_FILEFUNC_SEEK_CUR)==0) lSeek=0; else err=UNZ_ERRNO; } while(acc < file_info.size_file_extra) { uLong headerId; uLong dataSize; if (unz64local_getShort(&s->z_filefunc, s->filestream,&headerId) != UNZ_OK) err=UNZ_ERRNO; if (unz64local_getShort(&s->z_filefunc, s->filestream,&dataSize) != UNZ_OK) err=UNZ_ERRNO; /* ZIP64 extra fields */ if (headerId == 0x0001) { if(file_info.uncompressed_size == MAXU32) { if (unz64local_getLong64(&s->z_filefunc, s->filestream,&file_info.uncompressed_size) != UNZ_OK) err=UNZ_ERRNO; } if(file_info.compressed_size == MAXU32) { if (unz64local_getLong64(&s->z_filefunc, s->filestream,&file_info.compressed_size) != UNZ_OK) err=UNZ_ERRNO; } if(file_info_internal.offset_curfile == MAXU32) { /* Relative Header offset */ if (unz64local_getLong64(&s->z_filefunc, s->filestream,&file_info_internal.offset_curfile) != UNZ_OK) err=UNZ_ERRNO; } if(file_info.disk_num_start == 0xffff) { /* Disk Start Number */ if (unz64local_getLong(&s->z_filefunc, s->filestream,&file_info.disk_num_start) != UNZ_OK) err=UNZ_ERRNO; } } else { if (ZSEEK64(s->z_filefunc, s->filestream,dataSize,ZLIB_FILEFUNC_SEEK_CUR)!=0) err=UNZ_ERRNO; } acc += 2 + 2 + dataSize; } } if ((err==UNZ_OK) && (szComment!=NULL)) { uLong uSizeRead ; if (file_info.size_file_commentz_filefunc, s->filestream,(ZPOS64_T)lSeek,ZLIB_FILEFUNC_SEEK_CUR)==0) lSeek=0; else err=UNZ_ERRNO; } if ((file_info.size_file_comment>0) && (commentBufferSize>0)) if (ZREAD64(s->z_filefunc, s->filestream,szComment,uSizeRead)!=uSizeRead) err=UNZ_ERRNO; lSeek+=file_info.size_file_comment - uSizeRead; } else lSeek+=file_info.size_file_comment; if ((err==UNZ_OK) && (pfile_info!=NULL)) *pfile_info=file_info; if ((err==UNZ_OK) && (pfile_info_internal!=NULL)) *pfile_info_internal=file_info_internal; return err; } /* Write info about the ZipFile in the *pglobal_info structure. No preparation of the structure is needed return UNZ_OK if there is no problem. */ extern int ZEXPORT unzGetCurrentFileInfo64(unzFile file, unz_file_info64 * pfile_info, char * szFileName, uLong fileNameBufferSize, void *extraField, uLong extraFieldBufferSize, char* szComment, uLong commentBufferSize) { return unz64local_GetCurrentFileInfoInternal(file,pfile_info,NULL, szFileName,fileNameBufferSize, extraField,extraFieldBufferSize, szComment,commentBufferSize); } extern int ZEXPORT unzGetCurrentFileInfo(unzFile file, unz_file_info * pfile_info, char * szFileName, uLong fileNameBufferSize, void *extraField, uLong extraFieldBufferSize, char* szComment, uLong commentBufferSize) { int err; unz_file_info64 file_info64; err = unz64local_GetCurrentFileInfoInternal(file,&file_info64,NULL, szFileName,fileNameBufferSize, extraField,extraFieldBufferSize, szComment,commentBufferSize); if ((err==UNZ_OK) && (pfile_info != NULL)) { pfile_info->version = file_info64.version; pfile_info->version_needed = file_info64.version_needed; pfile_info->flag = file_info64.flag; pfile_info->compression_method = file_info64.compression_method; pfile_info->dosDate = file_info64.dosDate; pfile_info->crc = file_info64.crc; pfile_info->size_filename = file_info64.size_filename; pfile_info->size_file_extra = file_info64.size_file_extra; pfile_info->size_file_comment = file_info64.size_file_comment; pfile_info->disk_num_start = file_info64.disk_num_start; pfile_info->internal_fa = file_info64.internal_fa; pfile_info->external_fa = file_info64.external_fa; pfile_info->tmu_date = file_info64.tmu_date; pfile_info->compressed_size = (uLong)file_info64.compressed_size; pfile_info->uncompressed_size = (uLong)file_info64.uncompressed_size; } return err; } /* Set the current file of the zipfile to the first file. return UNZ_OK if there is no problem */ extern int ZEXPORT unzGoToFirstFile(unzFile file) { int err=UNZ_OK; unz64_s* s; if (file==NULL) return UNZ_PARAMERROR; s=(unz64_s*)file; s->pos_in_central_dir=s->offset_central_dir; s->num_file=0; err=unz64local_GetCurrentFileInfoInternal(file,&s->cur_file_info, &s->cur_file_info_internal, NULL,0,NULL,0,NULL,0); s->current_file_ok = (err == UNZ_OK); return err; } /* Set the current file of the zipfile to the next file. return UNZ_OK if there is no problem return UNZ_END_OF_LIST_OF_FILE if the actual file was the latest. */ extern int ZEXPORT unzGoToNextFile(unzFile file) { unz64_s* s; int err; if (file==NULL) return UNZ_PARAMERROR; s=(unz64_s*)file; if (!s->current_file_ok) return UNZ_END_OF_LIST_OF_FILE; if (s->gi.number_entry != 0xffff) /* 2^16 files overflow hack */ if (s->num_file+1==s->gi.number_entry) return UNZ_END_OF_LIST_OF_FILE; s->pos_in_central_dir += SIZECENTRALDIRITEM + s->cur_file_info.size_filename + s->cur_file_info.size_file_extra + s->cur_file_info.size_file_comment ; s->num_file++; err = unz64local_GetCurrentFileInfoInternal(file,&s->cur_file_info, &s->cur_file_info_internal, NULL,0,NULL,0,NULL,0); s->current_file_ok = (err == UNZ_OK); return err; } /* Try locate the file szFileName in the zipfile. For the iCaseSensitivity signification, see unzStringFileNameCompare return value : UNZ_OK if the file is found. It becomes the current file. UNZ_END_OF_LIST_OF_FILE if the file is not found */ extern int ZEXPORT unzLocateFile(unzFile file, const char *szFileName, int iCaseSensitivity) { unz64_s* s; int err; /* We remember the 'current' position in the file so that we can jump * back there if we fail. */ unz_file_info64 cur_file_infoSaved; unz_file_info64_internal cur_file_info_internalSaved; ZPOS64_T num_fileSaved; ZPOS64_T pos_in_central_dirSaved; if (file==NULL) return UNZ_PARAMERROR; if (strlen(szFileName)>=UNZ_MAXFILENAMEINZIP) return UNZ_PARAMERROR; s=(unz64_s*)file; if (!s->current_file_ok) return UNZ_END_OF_LIST_OF_FILE; /* Save the current state */ num_fileSaved = s->num_file; pos_in_central_dirSaved = s->pos_in_central_dir; cur_file_infoSaved = s->cur_file_info; cur_file_info_internalSaved = s->cur_file_info_internal; err = unzGoToFirstFile(file); while (err == UNZ_OK) { char szCurrentFileName[UNZ_MAXFILENAMEINZIP+1]; err = unzGetCurrentFileInfo64(file,NULL, szCurrentFileName,sizeof(szCurrentFileName)-1, NULL,0,NULL,0); if (err == UNZ_OK) { if (unzStringFileNameCompare(szCurrentFileName, szFileName,iCaseSensitivity)==0) return UNZ_OK; err = unzGoToNextFile(file); } } /* We failed, so restore the state of the 'current file' to where we * were. */ s->num_file = num_fileSaved ; s->pos_in_central_dir = pos_in_central_dirSaved ; s->cur_file_info = cur_file_infoSaved; s->cur_file_info_internal = cur_file_info_internalSaved; return err; } /* /////////////////////////////////////////// // Contributed by Ryan Haksi (mailto://cryogen@infoserve.net) // I need random access // // Further optimization could be realized by adding an ability // to cache the directory in memory. The goal being a single // comprehensive file read to put the file I need in a memory. */ /* typedef struct unz_file_pos_s { ZPOS64_T pos_in_zip_directory; // offset in file ZPOS64_T num_of_file; // # of file } unz_file_pos; */ extern int ZEXPORT unzGetFilePos64(unzFile file, unz64_file_pos* file_pos) { unz64_s* s; if (file==NULL || file_pos==NULL) return UNZ_PARAMERROR; s=(unz64_s*)file; if (!s->current_file_ok) return UNZ_END_OF_LIST_OF_FILE; file_pos->pos_in_zip_directory = s->pos_in_central_dir; file_pos->num_of_file = s->num_file; return UNZ_OK; } extern int ZEXPORT unzGetFilePos(unzFile file, unz_file_pos* file_pos) { unz64_file_pos file_pos64; int err = unzGetFilePos64(file,&file_pos64); if (err==UNZ_OK) { file_pos->pos_in_zip_directory = (uLong)file_pos64.pos_in_zip_directory; file_pos->num_of_file = (uLong)file_pos64.num_of_file; } return err; } extern int ZEXPORT unzGoToFilePos64(unzFile file, const unz64_file_pos* file_pos) { unz64_s* s; int err; if (file==NULL || file_pos==NULL) return UNZ_PARAMERROR; s=(unz64_s*)file; /* jump to the right spot */ s->pos_in_central_dir = file_pos->pos_in_zip_directory; s->num_file = file_pos->num_of_file; /* set the current file */ err = unz64local_GetCurrentFileInfoInternal(file,&s->cur_file_info, &s->cur_file_info_internal, NULL,0,NULL,0,NULL,0); /* return results */ s->current_file_ok = (err == UNZ_OK); return err; } extern int ZEXPORT unzGoToFilePos(unzFile file, unz_file_pos* file_pos) { unz64_file_pos file_pos64; if (file_pos == NULL) return UNZ_PARAMERROR; file_pos64.pos_in_zip_directory = file_pos->pos_in_zip_directory; file_pos64.num_of_file = file_pos->num_of_file; return unzGoToFilePos64(file,&file_pos64); } /* // Unzip Helper Functions - should be here? /////////////////////////////////////////// */ /* Read the local header of the current zipfile Check the coherency of the local header and info in the end of central directory about this file store in *piSizeVar the size of extra info in local header (filename and size of extra field data) */ local int unz64local_CheckCurrentFileCoherencyHeader(unz64_s* s, uInt* piSizeVar, ZPOS64_T * poffset_local_extrafield, uInt * psize_local_extrafield) { uLong uMagic,uData,uFlags; uLong size_filename; uLong size_extra_field; int err=UNZ_OK; *piSizeVar = 0; *poffset_local_extrafield = 0; *psize_local_extrafield = 0; if (ZSEEK64(s->z_filefunc, s->filestream,s->cur_file_info_internal.offset_curfile + s->byte_before_the_zipfile,ZLIB_FILEFUNC_SEEK_SET)!=0) return UNZ_ERRNO; if (err==UNZ_OK) { if (unz64local_getLong(&s->z_filefunc, s->filestream,&uMagic) != UNZ_OK) err=UNZ_ERRNO; else if (uMagic!=0x04034b50) err=UNZ_BADZIPFILE; } if (unz64local_getShort(&s->z_filefunc, s->filestream,&uData) != UNZ_OK) err=UNZ_ERRNO; /* else if ((err==UNZ_OK) && (uData!=s->cur_file_info.wVersion)) err=UNZ_BADZIPFILE; */ if (unz64local_getShort(&s->z_filefunc, s->filestream,&uFlags) != UNZ_OK) err=UNZ_ERRNO; if (unz64local_getShort(&s->z_filefunc, s->filestream,&uData) != UNZ_OK) err=UNZ_ERRNO; else if ((err==UNZ_OK) && (uData!=s->cur_file_info.compression_method)) err=UNZ_BADZIPFILE; if ((err==UNZ_OK) && (s->cur_file_info.compression_method!=0) && /* #ifdef HAVE_BZIP2 */ (s->cur_file_info.compression_method!=Z_BZIP2ED) && /* #endif */ (s->cur_file_info.compression_method!=Z_DEFLATED)) err=UNZ_BADZIPFILE; if (unz64local_getLong(&s->z_filefunc, s->filestream,&uData) != UNZ_OK) /* date/time */ err=UNZ_ERRNO; if (unz64local_getLong(&s->z_filefunc, s->filestream,&uData) != UNZ_OK) /* crc */ err=UNZ_ERRNO; else if ((err==UNZ_OK) && (uData!=s->cur_file_info.crc) && ((uFlags & 8)==0)) err=UNZ_BADZIPFILE; if (unz64local_getLong(&s->z_filefunc, s->filestream,&uData) != UNZ_OK) /* size compr */ err=UNZ_ERRNO; else if (uData != 0xFFFFFFFF && (err==UNZ_OK) && (uData!=s->cur_file_info.compressed_size) && ((uFlags & 8)==0)) err=UNZ_BADZIPFILE; if (unz64local_getLong(&s->z_filefunc, s->filestream,&uData) != UNZ_OK) /* size uncompr */ err=UNZ_ERRNO; else if (uData != 0xFFFFFFFF && (err==UNZ_OK) && (uData!=s->cur_file_info.uncompressed_size) && ((uFlags & 8)==0)) err=UNZ_BADZIPFILE; if (unz64local_getShort(&s->z_filefunc, s->filestream,&size_filename) != UNZ_OK) err=UNZ_ERRNO; else if ((err==UNZ_OK) && (size_filename!=s->cur_file_info.size_filename)) err=UNZ_BADZIPFILE; *piSizeVar += (uInt)size_filename; if (unz64local_getShort(&s->z_filefunc, s->filestream,&size_extra_field) != UNZ_OK) err=UNZ_ERRNO; *poffset_local_extrafield= s->cur_file_info_internal.offset_curfile + SIZEZIPLOCALHEADER + size_filename; *psize_local_extrafield = (uInt)size_extra_field; *piSizeVar += (uInt)size_extra_field; return err; } /* Open for reading data the current file in the zipfile. If there is no error and the file is opened, the return value is UNZ_OK. */ extern int ZEXPORT unzOpenCurrentFile3(unzFile file, int* method, int* level, int raw, const char* password) { int err=UNZ_OK; uInt iSizeVar; unz64_s* s; file_in_zip64_read_info_s* pfile_in_zip_read_info; ZPOS64_T offset_local_extrafield; /* offset of the local extra field */ uInt size_local_extrafield; /* size of the local extra field */ # ifndef NOUNCRYPT char source[12]; # else if (password != NULL) return UNZ_PARAMERROR; # endif if (file==NULL) return UNZ_PARAMERROR; s=(unz64_s*)file; if (!s->current_file_ok) return UNZ_PARAMERROR; if (s->pfile_in_zip_read != NULL) unzCloseCurrentFile(file); if (unz64local_CheckCurrentFileCoherencyHeader(s,&iSizeVar, &offset_local_extrafield,&size_local_extrafield)!=UNZ_OK) return UNZ_BADZIPFILE; pfile_in_zip_read_info = (file_in_zip64_read_info_s*)ALLOC(sizeof(file_in_zip64_read_info_s)); if (pfile_in_zip_read_info==NULL) return UNZ_INTERNALERROR; pfile_in_zip_read_info->read_buffer=(char*)ALLOC(UNZ_BUFSIZE); pfile_in_zip_read_info->offset_local_extrafield = offset_local_extrafield; pfile_in_zip_read_info->size_local_extrafield = size_local_extrafield; pfile_in_zip_read_info->pos_local_extrafield=0; pfile_in_zip_read_info->raw=raw; if (pfile_in_zip_read_info->read_buffer==NULL) { free(pfile_in_zip_read_info); return UNZ_INTERNALERROR; } pfile_in_zip_read_info->stream_initialised=0; if (method!=NULL) *method = (int)s->cur_file_info.compression_method; if (level!=NULL) { *level = 6; switch (s->cur_file_info.flag & 0x06) { case 6 : *level = 1; break; case 4 : *level = 2; break; case 2 : *level = 9; break; } } if ((s->cur_file_info.compression_method!=0) && /* #ifdef HAVE_BZIP2 */ (s->cur_file_info.compression_method!=Z_BZIP2ED) && /* #endif */ (s->cur_file_info.compression_method!=Z_DEFLATED)) err=UNZ_BADZIPFILE; pfile_in_zip_read_info->crc32_wait=s->cur_file_info.crc; pfile_in_zip_read_info->crc32=0; pfile_in_zip_read_info->total_out_64=0; pfile_in_zip_read_info->compression_method = s->cur_file_info.compression_method; pfile_in_zip_read_info->filestream=s->filestream; pfile_in_zip_read_info->z_filefunc=s->z_filefunc; pfile_in_zip_read_info->byte_before_the_zipfile=s->byte_before_the_zipfile; pfile_in_zip_read_info->stream.total_out = 0; if ((s->cur_file_info.compression_method==Z_BZIP2ED) && (!raw)) { #ifdef HAVE_BZIP2 pfile_in_zip_read_info->bstream.bzalloc = (void *(*) (void *, int, int))0; pfile_in_zip_read_info->bstream.bzfree = (free_func)0; pfile_in_zip_read_info->bstream.opaque = (voidpf)0; pfile_in_zip_read_info->bstream.state = (voidpf)0; pfile_in_zip_read_info->stream.zalloc = (alloc_func)0; pfile_in_zip_read_info->stream.zfree = (free_func)0; pfile_in_zip_read_info->stream.opaque = (voidpf)0; pfile_in_zip_read_info->stream.next_in = (voidpf)0; pfile_in_zip_read_info->stream.avail_in = 0; err=BZ2_bzDecompressInit(&pfile_in_zip_read_info->bstream, 0, 0); if (err == Z_OK) pfile_in_zip_read_info->stream_initialised=Z_BZIP2ED; else { free(pfile_in_zip_read_info->read_buffer); free(pfile_in_zip_read_info); return err; } #else pfile_in_zip_read_info->raw=1; #endif } else if ((s->cur_file_info.compression_method==Z_DEFLATED) && (!raw)) { pfile_in_zip_read_info->stream.zalloc = (alloc_func)0; pfile_in_zip_read_info->stream.zfree = (free_func)0; pfile_in_zip_read_info->stream.opaque = (voidpf)0; pfile_in_zip_read_info->stream.next_in = 0; pfile_in_zip_read_info->stream.avail_in = 0; err=inflateInit2(&pfile_in_zip_read_info->stream, -MAX_WBITS); if (err == Z_OK) pfile_in_zip_read_info->stream_initialised=Z_DEFLATED; else { free(pfile_in_zip_read_info->read_buffer); free(pfile_in_zip_read_info); return err; } /* windowBits is passed < 0 to tell that there is no zlib header. * Note that in this case inflate *requires* an extra "dummy" byte * after the compressed stream in order to complete decompression and * return Z_STREAM_END. * In unzip, i don't wait absolutely Z_STREAM_END because I known the * size of both compressed and uncompressed data */ } pfile_in_zip_read_info->rest_read_compressed = s->cur_file_info.compressed_size ; pfile_in_zip_read_info->rest_read_uncompressed = s->cur_file_info.uncompressed_size ; pfile_in_zip_read_info->pos_in_zipfile = s->cur_file_info_internal.offset_curfile + SIZEZIPLOCALHEADER + iSizeVar; pfile_in_zip_read_info->stream.avail_in = (uInt)0; s->pfile_in_zip_read = pfile_in_zip_read_info; s->encrypted = 0; # ifndef NOUNCRYPT if (password != NULL) { int i; s->pcrc_32_tab = get_crc_table(); init_keys(password,s->keys,s->pcrc_32_tab); if (ZSEEK64(s->z_filefunc, s->filestream, s->pfile_in_zip_read->pos_in_zipfile + s->pfile_in_zip_read->byte_before_the_zipfile, SEEK_SET)!=0) return UNZ_INTERNALERROR; if(ZREAD64(s->z_filefunc, s->filestream,source, 12)<12) return UNZ_INTERNALERROR; for (i = 0; i<12; i++) zdecode(s->keys,s->pcrc_32_tab,source[i]); s->pfile_in_zip_read->pos_in_zipfile+=12; s->encrypted=1; } # endif return UNZ_OK; } extern int ZEXPORT unzOpenCurrentFile(unzFile file) { return unzOpenCurrentFile3(file, NULL, NULL, 0, NULL); } extern int ZEXPORT unzOpenCurrentFilePassword(unzFile file, const char* password) { return unzOpenCurrentFile3(file, NULL, NULL, 0, password); } extern int ZEXPORT unzOpenCurrentFile2(unzFile file, int* method, int* level, int raw) { return unzOpenCurrentFile3(file, method, level, raw, NULL); } /** Addition for GDAL : START */ extern ZPOS64_T ZEXPORT unzGetCurrentFileZStreamPos64(unzFile file) { unz64_s* s; file_in_zip64_read_info_s* pfile_in_zip_read_info; s=(unz64_s*)file; if (file==NULL) return 0; //UNZ_PARAMERROR; pfile_in_zip_read_info=s->pfile_in_zip_read; if (pfile_in_zip_read_info==NULL) return 0; //UNZ_PARAMERROR; return pfile_in_zip_read_info->pos_in_zipfile + pfile_in_zip_read_info->byte_before_the_zipfile; } /** Addition for GDAL : END */ /* Read bytes from the current file. buf contain buffer where data must be copied len the size of buf. return the number of byte copied if some bytes are copied return 0 if the end of file was reached return <0 with error code if there is an error (UNZ_ERRNO for IO error, or zLib error for uncompress error) */ extern int ZEXPORT unzReadCurrentFile(unzFile file, voidp buf, unsigned len) { int err=UNZ_OK; uInt iRead = 0; unz64_s* s; file_in_zip64_read_info_s* pfile_in_zip_read_info; if (file==NULL) return UNZ_PARAMERROR; s=(unz64_s*)file; pfile_in_zip_read_info=s->pfile_in_zip_read; if (pfile_in_zip_read_info==NULL) return UNZ_PARAMERROR; if (pfile_in_zip_read_info->read_buffer == NULL) return UNZ_END_OF_LIST_OF_FILE; if (len==0) return 0; pfile_in_zip_read_info->stream.next_out = (Bytef*)buf; pfile_in_zip_read_info->stream.avail_out = (uInt)len; if ((len>pfile_in_zip_read_info->rest_read_uncompressed) && (!(pfile_in_zip_read_info->raw))) pfile_in_zip_read_info->stream.avail_out = (uInt)pfile_in_zip_read_info->rest_read_uncompressed; if ((len>pfile_in_zip_read_info->rest_read_compressed+ pfile_in_zip_read_info->stream.avail_in) && (pfile_in_zip_read_info->raw)) pfile_in_zip_read_info->stream.avail_out = (uInt)pfile_in_zip_read_info->rest_read_compressed+ pfile_in_zip_read_info->stream.avail_in; while (pfile_in_zip_read_info->stream.avail_out>0) { if ((pfile_in_zip_read_info->stream.avail_in==0) && (pfile_in_zip_read_info->rest_read_compressed>0)) { uInt uReadThis = UNZ_BUFSIZE; if (pfile_in_zip_read_info->rest_read_compressedrest_read_compressed; if (uReadThis == 0) return UNZ_EOF; if (ZSEEK64(pfile_in_zip_read_info->z_filefunc, pfile_in_zip_read_info->filestream, pfile_in_zip_read_info->pos_in_zipfile + pfile_in_zip_read_info->byte_before_the_zipfile, ZLIB_FILEFUNC_SEEK_SET)!=0) return UNZ_ERRNO; if (ZREAD64(pfile_in_zip_read_info->z_filefunc, pfile_in_zip_read_info->filestream, pfile_in_zip_read_info->read_buffer, uReadThis)!=uReadThis) return UNZ_ERRNO; # ifndef NOUNCRYPT if(s->encrypted) { uInt i; for(i=0;iread_buffer[i] = zdecode(s->keys,s->pcrc_32_tab, pfile_in_zip_read_info->read_buffer[i]); } # endif pfile_in_zip_read_info->pos_in_zipfile += uReadThis; pfile_in_zip_read_info->rest_read_compressed-=uReadThis; pfile_in_zip_read_info->stream.next_in = (Bytef*)pfile_in_zip_read_info->read_buffer; pfile_in_zip_read_info->stream.avail_in = (uInt)uReadThis; } if ((pfile_in_zip_read_info->compression_method==0) || (pfile_in_zip_read_info->raw)) { uInt uDoCopy,i ; if ((pfile_in_zip_read_info->stream.avail_in == 0) && (pfile_in_zip_read_info->rest_read_compressed == 0)) return (iRead==0) ? UNZ_EOF : (int)iRead; if (pfile_in_zip_read_info->stream.avail_out < pfile_in_zip_read_info->stream.avail_in) uDoCopy = pfile_in_zip_read_info->stream.avail_out ; else uDoCopy = pfile_in_zip_read_info->stream.avail_in ; for (i=0;istream.next_out+i) = *(pfile_in_zip_read_info->stream.next_in+i); pfile_in_zip_read_info->total_out_64 = pfile_in_zip_read_info->total_out_64 + uDoCopy; pfile_in_zip_read_info->crc32 = crc32(pfile_in_zip_read_info->crc32, pfile_in_zip_read_info->stream.next_out, uDoCopy); pfile_in_zip_read_info->rest_read_uncompressed-=uDoCopy; pfile_in_zip_read_info->stream.avail_in -= uDoCopy; pfile_in_zip_read_info->stream.avail_out -= uDoCopy; pfile_in_zip_read_info->stream.next_out += uDoCopy; pfile_in_zip_read_info->stream.next_in += uDoCopy; pfile_in_zip_read_info->stream.total_out += uDoCopy; iRead += uDoCopy; } else if (pfile_in_zip_read_info->compression_method==Z_BZIP2ED) { #ifdef HAVE_BZIP2 uLong uTotalOutBefore,uTotalOutAfter; const Bytef *bufBefore; uLong uOutThis; pfile_in_zip_read_info->bstream.next_in = (char*)pfile_in_zip_read_info->stream.next_in; pfile_in_zip_read_info->bstream.avail_in = pfile_in_zip_read_info->stream.avail_in; pfile_in_zip_read_info->bstream.total_in_lo32 = pfile_in_zip_read_info->stream.total_in; pfile_in_zip_read_info->bstream.total_in_hi32 = 0; pfile_in_zip_read_info->bstream.next_out = (char*)pfile_in_zip_read_info->stream.next_out; pfile_in_zip_read_info->bstream.avail_out = pfile_in_zip_read_info->stream.avail_out; pfile_in_zip_read_info->bstream.total_out_lo32 = pfile_in_zip_read_info->stream.total_out; pfile_in_zip_read_info->bstream.total_out_hi32 = 0; uTotalOutBefore = pfile_in_zip_read_info->bstream.total_out_lo32; bufBefore = (const Bytef *)pfile_in_zip_read_info->bstream.next_out; err=BZ2_bzDecompress(&pfile_in_zip_read_info->bstream); uTotalOutAfter = pfile_in_zip_read_info->bstream.total_out_lo32; uOutThis = uTotalOutAfter-uTotalOutBefore; pfile_in_zip_read_info->total_out_64 = pfile_in_zip_read_info->total_out_64 + uOutThis; pfile_in_zip_read_info->crc32 = crc32(pfile_in_zip_read_info->crc32,bufBefore, (uInt)(uOutThis)); pfile_in_zip_read_info->rest_read_uncompressed -= uOutThis; iRead += (uInt)(uTotalOutAfter - uTotalOutBefore); pfile_in_zip_read_info->stream.next_in = (Bytef*)pfile_in_zip_read_info->bstream.next_in; pfile_in_zip_read_info->stream.avail_in = pfile_in_zip_read_info->bstream.avail_in; pfile_in_zip_read_info->stream.total_in = pfile_in_zip_read_info->bstream.total_in_lo32; pfile_in_zip_read_info->stream.next_out = (Bytef*)pfile_in_zip_read_info->bstream.next_out; pfile_in_zip_read_info->stream.avail_out = pfile_in_zip_read_info->bstream.avail_out; pfile_in_zip_read_info->stream.total_out = pfile_in_zip_read_info->bstream.total_out_lo32; if (err==BZ_STREAM_END) return (iRead==0) ? UNZ_EOF : iRead; if (err!=BZ_OK) break; #endif } // end Z_BZIP2ED else { ZPOS64_T uTotalOutBefore,uTotalOutAfter; const Bytef *bufBefore; ZPOS64_T uOutThis; int flush=Z_SYNC_FLUSH; uTotalOutBefore = pfile_in_zip_read_info->stream.total_out; bufBefore = pfile_in_zip_read_info->stream.next_out; /* if ((pfile_in_zip_read_info->rest_read_uncompressed == pfile_in_zip_read_info->stream.avail_out) && (pfile_in_zip_read_info->rest_read_compressed == 0)) flush = Z_FINISH; */ err=inflate(&pfile_in_zip_read_info->stream,flush); if ((err>=0) && (pfile_in_zip_read_info->stream.msg!=NULL)) err = Z_DATA_ERROR; uTotalOutAfter = pfile_in_zip_read_info->stream.total_out; /* Detect overflow, because z_stream.total_out is uLong (32 bits) */ if (uTotalOutAftertotal_out_64 = pfile_in_zip_read_info->total_out_64 + uOutThis; pfile_in_zip_read_info->crc32 = crc32(pfile_in_zip_read_info->crc32,bufBefore, (uInt)(uOutThis)); pfile_in_zip_read_info->rest_read_uncompressed -= uOutThis; iRead += (uInt)(uTotalOutAfter - uTotalOutBefore); if (err==Z_STREAM_END) return (iRead==0) ? UNZ_EOF : (int)iRead; if (err!=Z_OK) break; } } if (err==Z_OK) return (int)iRead; return err; } /* Give the current position in uncompressed data */ extern z_off_t ZEXPORT unztell(unzFile file) { unz64_s* s; file_in_zip64_read_info_s* pfile_in_zip_read_info; if (file==NULL) return UNZ_PARAMERROR; s=(unz64_s*)file; pfile_in_zip_read_info=s->pfile_in_zip_read; if (pfile_in_zip_read_info==NULL) return UNZ_PARAMERROR; return (z_off_t)pfile_in_zip_read_info->stream.total_out; } extern ZPOS64_T ZEXPORT unztell64(unzFile file) { unz64_s* s; file_in_zip64_read_info_s* pfile_in_zip_read_info; if (file==NULL) return (ZPOS64_T)-1; s=(unz64_s*)file; pfile_in_zip_read_info=s->pfile_in_zip_read; if (pfile_in_zip_read_info==NULL) return (ZPOS64_T)-1; return pfile_in_zip_read_info->total_out_64; } /* return 1 if the end of file was reached, 0 elsewhere */ extern int ZEXPORT unzeof(unzFile file) { unz64_s* s; file_in_zip64_read_info_s* pfile_in_zip_read_info; if (file==NULL) return UNZ_PARAMERROR; s=(unz64_s*)file; pfile_in_zip_read_info=s->pfile_in_zip_read; if (pfile_in_zip_read_info==NULL) return UNZ_PARAMERROR; if (pfile_in_zip_read_info->rest_read_uncompressed == 0) return 1; else return 0; } /* Read extra field from the current file (opened by unzOpenCurrentFile) This is the local-header version of the extra field (sometimes, there is more info in the local-header version than in the central-header) if buf==NULL, it return the size of the local extra field that can be read if buf!=NULL, len is the size of the buffer, the extra header is copied in buf. the return value is the number of bytes copied in buf, or (if <0) the error code */ extern int ZEXPORT unzGetLocalExtrafield(unzFile file, voidp buf, unsigned len) { unz64_s* s; file_in_zip64_read_info_s* pfile_in_zip_read_info; uInt read_now; ZPOS64_T size_to_read; if (file==NULL) return UNZ_PARAMERROR; s=(unz64_s*)file; pfile_in_zip_read_info=s->pfile_in_zip_read; if (pfile_in_zip_read_info==NULL) return UNZ_PARAMERROR; size_to_read = (pfile_in_zip_read_info->size_local_extrafield - pfile_in_zip_read_info->pos_local_extrafield); if (buf==NULL) return (int)size_to_read; if (len>size_to_read) read_now = (uInt)size_to_read; else read_now = (uInt)len ; if (read_now==0) return 0; if (ZSEEK64(pfile_in_zip_read_info->z_filefunc, pfile_in_zip_read_info->filestream, pfile_in_zip_read_info->offset_local_extrafield + pfile_in_zip_read_info->pos_local_extrafield, ZLIB_FILEFUNC_SEEK_SET)!=0) return UNZ_ERRNO; if (ZREAD64(pfile_in_zip_read_info->z_filefunc, pfile_in_zip_read_info->filestream, buf,read_now)!=read_now) return UNZ_ERRNO; return (int)read_now; } /* Close the file in zip opened with unzOpenCurrentFile Return UNZ_CRCERROR if all the file was read but the CRC is not good */ extern int ZEXPORT unzCloseCurrentFile(unzFile file) { int err=UNZ_OK; unz64_s* s; file_in_zip64_read_info_s* pfile_in_zip_read_info; if (file==NULL) return UNZ_PARAMERROR; s=(unz64_s*)file; pfile_in_zip_read_info=s->pfile_in_zip_read; if (pfile_in_zip_read_info==NULL) return UNZ_PARAMERROR; if ((pfile_in_zip_read_info->rest_read_uncompressed == 0) && (!pfile_in_zip_read_info->raw)) { if (pfile_in_zip_read_info->crc32 != pfile_in_zip_read_info->crc32_wait) err=UNZ_CRCERROR; } free(pfile_in_zip_read_info->read_buffer); pfile_in_zip_read_info->read_buffer = NULL; if (pfile_in_zip_read_info->stream_initialised == Z_DEFLATED) inflateEnd(&pfile_in_zip_read_info->stream); #ifdef HAVE_BZIP2 else if (pfile_in_zip_read_info->stream_initialised == Z_BZIP2ED) BZ2_bzDecompressEnd(&pfile_in_zip_read_info->bstream); #endif pfile_in_zip_read_info->stream_initialised = 0; free(pfile_in_zip_read_info); s->pfile_in_zip_read=NULL; return err; } /* Get the global comment string of the ZipFile, in the szComment buffer. uSizeBuf is the size of the szComment buffer. return the number of byte copied or an error code <0 */ extern int ZEXPORT unzGetGlobalComment(unzFile file, char * szComment, uLong uSizeBuf) { unz64_s* s; uLong uReadThis ; if (file==NULL) return (int)UNZ_PARAMERROR; s=(unz64_s*)file; uReadThis = uSizeBuf; if (uReadThis>s->gi.size_comment) uReadThis = s->gi.size_comment; if (ZSEEK64(s->z_filefunc,s->filestream,s->central_pos+22,ZLIB_FILEFUNC_SEEK_SET)!=0) return UNZ_ERRNO; if (uReadThis>0) { *szComment='\0'; if (ZREAD64(s->z_filefunc,s->filestream,szComment,uReadThis)!=uReadThis) return UNZ_ERRNO; } if ((szComment != NULL) && (uSizeBuf > s->gi.size_comment)) *(szComment+s->gi.size_comment)='\0'; return (int)uReadThis; } /* Additions by RX '2004 */ extern ZPOS64_T ZEXPORT unzGetOffset64(unzFile file) { unz64_s* s; if (file==NULL) return 0; //UNZ_PARAMERROR; s=(unz64_s*)file; if (!s->current_file_ok) return 0; if (s->gi.number_entry != 0 && s->gi.number_entry != 0xffff) if (s->num_file==s->gi.number_entry) return 0; return s->pos_in_central_dir; } extern uLong ZEXPORT unzGetOffset(unzFile file) { ZPOS64_T offset64; if (file==NULL) return 0; //UNZ_PARAMERROR; offset64 = unzGetOffset64(file); return (uLong)offset64; } extern int ZEXPORT unzSetOffset64(unzFile file, ZPOS64_T pos) { unz64_s* s; int err; if (file==NULL) return UNZ_PARAMERROR; s=(unz64_s*)file; s->pos_in_central_dir = pos; s->num_file = s->gi.number_entry; /* hack */ err = unz64local_GetCurrentFileInfoInternal(file,&s->cur_file_info, &s->cur_file_info_internal, NULL,0,NULL,0,NULL,0); s->current_file_ok = (err == UNZ_OK); return err; } extern int ZEXPORT unzSetOffset (unzFile file, uLong pos) { return unzSetOffset64(file,pos); } httrack-3.49.5/src/minizip/mztools.c0000644000175000017500000001767014555200243014331 00000000000000/* Additional tools for Minizip Code: Xavier Roche '2004 License: Same as ZLIB (www.gzip.org) */ /* Code */ #include #include #include #include "zlib.h" #include "unzip.h" #include "mztools.h" #define READ_8(adr) ((unsigned char)*(adr)) #define READ_16(adr) ( READ_8(adr) | (READ_8(adr+1) << 8) ) #define READ_32(adr) ( READ_16(adr) | (READ_16((adr)+2) << 16) ) #define WRITE_8(buff, n) do { \ *((unsigned char*)(buff)) = (unsigned char) ((n) & 0xff); \ } while(0) #define WRITE_16(buff, n) do { \ WRITE_8((unsigned char*)(buff), n); \ WRITE_8(((unsigned char*)(buff)) + 1, (n) >> 8); \ } while(0) #define WRITE_32(buff, n) do { \ WRITE_16((unsigned char*)(buff), (n) & 0xffff); \ WRITE_16((unsigned char*)(buff) + 2, (n) >> 16); \ } while(0) extern int ZEXPORT unzRepair(const char* file, const char* fileOut, const char* fileOutTmp, uLong* nRecovered, uLong* bytesRecovered) { int err = Z_OK; FILE* fpZip = fopen(file, "rb"); FILE* fpOut = fopen(fileOut, "wb"); FILE* fpOutCD = fopen(fileOutTmp, "wb"); if (fpZip != NULL && fpOut != NULL) { int entries = 0; uLong totalBytes = 0; char header[30]; char filename[1024]; char extra[1024]; int offset = 0; int offsetCD = 0; while ( fread(header, 1, 30, fpZip) == 30 ) { int currentOffset = offset; /* File entry */ if (READ_32(header) == 0x04034b50) { unsigned int version = READ_16(header + 4); unsigned int gpflag = READ_16(header + 6); unsigned int method = READ_16(header + 8); unsigned int filetime = READ_16(header + 10); unsigned int filedate = READ_16(header + 12); unsigned int crc = READ_32(header + 14); /* crc */ unsigned int cpsize = READ_32(header + 18); /* compressed size */ unsigned int uncpsize = READ_32(header + 22); /* uncompressed sz */ unsigned int fnsize = READ_16(header + 26); /* file name length */ unsigned int extsize = READ_16(header + 28); /* extra field length */ filename[0] = extra[0] = '\0'; /* Header */ if (fwrite(header, 1, 30, fpOut) == 30) { offset += 30; } else { err = Z_ERRNO; break; } /* Filename */ if (fnsize > 0) { if (fnsize < sizeof(filename)) { if (fread(filename, 1, fnsize, fpZip) == fnsize) { if (fwrite(filename, 1, fnsize, fpOut) == fnsize) { offset += fnsize; } else { err = Z_ERRNO; break; } } else { err = Z_ERRNO; break; } } else { err = Z_ERRNO; break; } } else { err = Z_STREAM_ERROR; break; } /* Extra field */ if (extsize > 0) { if (extsize < sizeof(extra)) { if (fread(extra, 1, extsize, fpZip) == extsize) { if (fwrite(extra, 1, extsize, fpOut) == extsize) { offset += extsize; } else { err = Z_ERRNO; break; } } else { err = Z_ERRNO; break; } } else { err = Z_ERRNO; break; } } /* Data */ { int dataSize = cpsize; if (dataSize == 0) { dataSize = uncpsize; } if (dataSize > 0) { char* data = malloc(dataSize); if (data != NULL) { if ((int)fread(data, 1, dataSize, fpZip) == dataSize) { if ((int)fwrite(data, 1, dataSize, fpOut) == dataSize) { offset += dataSize; totalBytes += dataSize; } else { err = Z_ERRNO; } } else { err = Z_ERRNO; } free(data); if (err != Z_OK) { break; } } else { err = Z_MEM_ERROR; break; } } } /* Central directory entry */ { char header[46]; const char* comment = ""; const size_t comsize = strlen(comment); WRITE_32(header, 0x02014b50); WRITE_16(header + 4, version); WRITE_16(header + 6, version); WRITE_16(header + 8, gpflag); WRITE_16(header + 10, method); WRITE_16(header + 12, filetime); WRITE_16(header + 14, filedate); WRITE_32(header + 16, crc); WRITE_32(header + 20, cpsize); WRITE_32(header + 24, uncpsize); WRITE_16(header + 28, fnsize); WRITE_16(header + 30, extsize); WRITE_16(header + 32, comsize); WRITE_16(header + 34, 0); /* disk # */ WRITE_16(header + 36, 0); /* int attrb */ WRITE_32(header + 38, 0); /* ext attrb */ WRITE_32(header + 42, currentOffset); /* Header */ if (fwrite(header, 1, 46, fpOutCD) == 46) { offsetCD += 46; /* Filename */ if (fnsize > 0) { if (fwrite(filename, 1, fnsize, fpOutCD) == fnsize) { offsetCD += fnsize; } else { err = Z_ERRNO; break; } } else { err = Z_STREAM_ERROR; break; } /* Extra field */ if (extsize > 0) { if (fwrite(extra, 1, extsize, fpOutCD) == extsize) { offsetCD += extsize; } else { err = Z_ERRNO; break; } } /* Comment field */ if (comsize > 0) { if (fwrite(comment, 1, comsize, fpOutCD) == comsize) { offsetCD += comsize; } else { err = Z_ERRNO; break; } } } else { err = Z_ERRNO; break; } } /* Success */ entries++; } else { break; } } /* Final central directory */ { int entriesZip = entries; char header[22]; const char* comment = ""; // "ZIP File recovered by zlib/minizip/mztools"; const size_t comsize = strlen(comment); if (entriesZip > 0xffff) { entriesZip = 0xffff; } WRITE_32(header, 0x06054b50); WRITE_16(header + 4, 0); /* disk # */ WRITE_16(header + 6, 0); /* disk # */ WRITE_16(header + 8, entriesZip); /* hack */ WRITE_16(header + 10, entriesZip); /* hack */ WRITE_32(header + 12, offsetCD); /* size of CD */ WRITE_32(header + 16, offset); /* offset to CD */ WRITE_16(header + 20, comsize); /* comment */ /* Header */ if (fwrite(header, 1, 22, fpOutCD) == 22) { /* Comment field */ if (comsize > 0) { if (fwrite(comment, 1, comsize, fpOutCD) != comsize) { err = Z_ERRNO; } } } else { err = Z_ERRNO; } } /* Final merge (file + central directory) */ fclose(fpOutCD); if (err == Z_OK) { fpOutCD = fopen(fileOutTmp, "rb"); if (fpOutCD != NULL) { int nRead; char buffer[8192]; while ( (nRead = (int)fread(buffer, 1, sizeof(buffer), fpOutCD)) > 0) { if ((int)fwrite(buffer, 1, nRead, fpOut) != nRead) { err = Z_ERRNO; break; } } fclose(fpOutCD); } } /* Close */ fclose(fpZip); fclose(fpOut); /* Wipe temporary file */ (void)remove(fileOutTmp); /* Number of recovered entries */ if (err == Z_OK) { if (nRecovered != NULL) { *nRecovered = entries; } if (bytesRecovered != NULL) { *bytesRecovered = totalBytes; } } } else { err = Z_STREAM_ERROR; } return err; } httrack-3.49.5/src/minizip/ioapi.c0000644000175000017500000001762714555200234013725 00000000000000/* ioapi.h -- IO base function header for compress/uncompress .zip part of the MiniZip project - ( http://www.winimage.com/zLibDll/minizip.html ) Copyright (C) 1998-2010 Gilles Vollant (minizip) ( http://www.winimage.com/zLibDll/minizip.html ) Modifications for Zip64 support Copyright (C) 2009-2010 Mathias Svensson ( http://result42.com ) For more info read MiniZip_info.txt */ #if defined(_WIN32) && (!(defined(_CRT_SECURE_NO_WARNINGS))) #define _CRT_SECURE_NO_WARNINGS #endif #if defined(__APPLE__) || defined(__ANDROID__) || defined(IOAPI_NO_64) || defined(__HAIKU__) || defined(MINIZIP_FOPEN_NO_64) // In darwin and perhaps other BSD variants off_t is a 64 bit value, hence no need for specific 64 bit functions #define FOPEN_FUNC(filename, mode) fopen(filename, mode) #define FTELLO_FUNC(stream) ftello(stream) #define FSEEKO_FUNC(stream, offset, origin) fseeko(stream, offset, origin) #else #define FOPEN_FUNC(filename, mode) fopen64(filename, mode) #define FTELLO_FUNC(stream) ftello64(stream) #define FSEEKO_FUNC(stream, offset, origin) fseeko64(stream, offset, origin) #endif #include "ioapi.h" voidpf call_zopen64 (const zlib_filefunc64_32_def* pfilefunc, const void*filename, int mode) { if (pfilefunc->zfile_func64.zopen64_file != NULL) return (*(pfilefunc->zfile_func64.zopen64_file)) (pfilefunc->zfile_func64.opaque,filename,mode); else { return (*(pfilefunc->zopen32_file))(pfilefunc->zfile_func64.opaque,(const char*)filename,mode); } } long call_zseek64 (const zlib_filefunc64_32_def* pfilefunc,voidpf filestream, ZPOS64_T offset, int origin) { if (pfilefunc->zfile_func64.zseek64_file != NULL) return (*(pfilefunc->zfile_func64.zseek64_file)) (pfilefunc->zfile_func64.opaque,filestream,offset,origin); else { uLong offsetTruncated = (uLong)offset; if (offsetTruncated != offset) return -1; else return (*(pfilefunc->zseek32_file))(pfilefunc->zfile_func64.opaque,filestream,offsetTruncated,origin); } } ZPOS64_T call_ztell64 (const zlib_filefunc64_32_def* pfilefunc, voidpf filestream) { if (pfilefunc->zfile_func64.zseek64_file != NULL) return (*(pfilefunc->zfile_func64.ztell64_file)) (pfilefunc->zfile_func64.opaque,filestream); else { uLong tell_uLong = (uLong)(*(pfilefunc->ztell32_file))(pfilefunc->zfile_func64.opaque,filestream); if ((tell_uLong) == MAXU32) return (ZPOS64_T)-1; else return tell_uLong; } } void fill_zlib_filefunc64_32_def_from_filefunc32(zlib_filefunc64_32_def* p_filefunc64_32, const zlib_filefunc_def* p_filefunc32) { p_filefunc64_32->zfile_func64.zopen64_file = NULL; p_filefunc64_32->zopen32_file = p_filefunc32->zopen_file; p_filefunc64_32->zfile_func64.zread_file = p_filefunc32->zread_file; p_filefunc64_32->zfile_func64.zwrite_file = p_filefunc32->zwrite_file; p_filefunc64_32->zfile_func64.zflush_file = p_filefunc32->zflush_file; p_filefunc64_32->zfile_func64.ztell64_file = NULL; p_filefunc64_32->zfile_func64.zseek64_file = NULL; p_filefunc64_32->zfile_func64.zclose_file = p_filefunc32->zclose_file; p_filefunc64_32->zfile_func64.zerror_file = p_filefunc32->zerror_file; p_filefunc64_32->zfile_func64.opaque = p_filefunc32->opaque; p_filefunc64_32->zseek32_file = p_filefunc32->zseek_file; p_filefunc64_32->ztell32_file = p_filefunc32->ztell_file; } static voidpf ZCALLBACK fopen_file_func(voidpf opaque, const char* filename, int mode) { FILE* file = NULL; const char* mode_fopen = NULL; (void)opaque; if ((mode & ZLIB_FILEFUNC_MODE_READWRITEFILTER)==ZLIB_FILEFUNC_MODE_READ) mode_fopen = "rb"; else if (mode & ZLIB_FILEFUNC_MODE_EXISTING) mode_fopen = "r+b"; else if (mode & ZLIB_FILEFUNC_MODE_CREATE) mode_fopen = "wb"; if ((filename!=NULL) && (mode_fopen != NULL)) file = fopen(filename, mode_fopen); return file; } static voidpf ZCALLBACK fopen64_file_func(voidpf opaque, const void* filename, int mode) { FILE* file = NULL; const char* mode_fopen = NULL; (void)opaque; if ((mode & ZLIB_FILEFUNC_MODE_READWRITEFILTER)==ZLIB_FILEFUNC_MODE_READ) mode_fopen = "rb"; else if (mode & ZLIB_FILEFUNC_MODE_EXISTING) mode_fopen = "r+b"; else if (mode & ZLIB_FILEFUNC_MODE_CREATE) mode_fopen = "wb"; if ((filename!=NULL) && (mode_fopen != NULL)) file = FOPEN_FUNC((const char*)filename, mode_fopen); return file; } static uLong ZCALLBACK fread_file_func(voidpf opaque, voidpf stream, void* buf, uLong size) { uLong ret; (void)opaque; ret = (uLong)fread(buf, 1, (size_t)size, (FILE *)stream); return ret; } static uLong ZCALLBACK fwrite_file_func(voidpf opaque, voidpf stream, const void* buf, uLong size) { uLong ret; (void)opaque; ret = (uLong)fwrite(buf, 1, (size_t)size, (FILE *)stream); return ret; } static long ZCALLBACK ftell_file_func(voidpf opaque, voidpf stream) { long ret; (void)opaque; ret = ftell((FILE *)stream); return ret; } static ZPOS64_T ZCALLBACK ftell64_file_func(voidpf opaque, voidpf stream) { ZPOS64_T ret; (void)opaque; ret = (ZPOS64_T)FTELLO_FUNC((FILE *)stream); return ret; } static long ZCALLBACK fseek_file_func(voidpf opaque, voidpf stream, uLong offset, int origin) { int fseek_origin=0; long ret; (void)opaque; switch (origin) { case ZLIB_FILEFUNC_SEEK_CUR : fseek_origin = SEEK_CUR; break; case ZLIB_FILEFUNC_SEEK_END : fseek_origin = SEEK_END; break; case ZLIB_FILEFUNC_SEEK_SET : fseek_origin = SEEK_SET; break; default: return -1; } ret = 0; if (fseek((FILE *)stream, (long)offset, fseek_origin) != 0) ret = -1; return ret; } static long ZCALLBACK fseek64_file_func(voidpf opaque, voidpf stream, ZPOS64_T offset, int origin) { int fseek_origin=0; long ret; (void)opaque; switch (origin) { case ZLIB_FILEFUNC_SEEK_CUR : fseek_origin = SEEK_CUR; break; case ZLIB_FILEFUNC_SEEK_END : fseek_origin = SEEK_END; break; case ZLIB_FILEFUNC_SEEK_SET : fseek_origin = SEEK_SET; break; default: return -1; } ret = 0; if(FSEEKO_FUNC((FILE *)stream, (z_off64_t)offset, fseek_origin) != 0) ret = -1; return ret; } static int ZCALLBACK fflush_file_func (voidpf opaque, voidpf stream) { int ret; ret = fflush((FILE *)stream); return ret; } static int ZCALLBACK fclose_file_func(voidpf opaque, voidpf stream) { int ret; (void)opaque; ret = fclose((FILE *)stream); return ret; } static int ZCALLBACK ferror_file_func(voidpf opaque, voidpf stream) { int ret; (void)opaque; ret = ferror((FILE *)stream); return ret; } void fill_fopen_filefunc(zlib_filefunc_def* pzlib_filefunc_def) { pzlib_filefunc_def->zopen_file = fopen_file_func; pzlib_filefunc_def->zread_file = fread_file_func; pzlib_filefunc_def->zwrite_file = fwrite_file_func; pzlib_filefunc_def->ztell_file = ftell_file_func; pzlib_filefunc_def->zseek_file = fseek_file_func; pzlib_filefunc_def->zflush_file = fflush_file_func; pzlib_filefunc_def->zclose_file = fclose_file_func; pzlib_filefunc_def->zerror_file = ferror_file_func; pzlib_filefunc_def->opaque = NULL; } void fill_fopen64_filefunc(zlib_filefunc64_def* pzlib_filefunc_def) { pzlib_filefunc_def->zopen64_file = fopen64_file_func; pzlib_filefunc_def->zread_file = fread_file_func; pzlib_filefunc_def->zwrite_file = fwrite_file_func; pzlib_filefunc_def->ztell64_file = ftell64_file_func; pzlib_filefunc_def->zseek64_file = fseek64_file_func; pzlib_filefunc_def->zflush_file = fflush_file_func; pzlib_filefunc_def->zclose_file = fclose_file_func; pzlib_filefunc_def->zerror_file = ferror_file_func; pzlib_filefunc_def->opaque = NULL; } httrack-3.49.5/src/coucal/0000755000175000017500000000000014555203177012323 500000000000000httrack-3.49.5/src/coucal/tests.c0000644000175000017500000001660214336470675013564 00000000000000/* ------------------------------------------------------------ */ /* Coucal, Cuckoo hashing-based hashtable with stash area. Copyright (C) 2013-2014 Xavier Roche and other contributors All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. 3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #include #include #include #include #include #include #include "coucal.h" static size_t fsize(const char *s) { struct stat st; if (stat(s, &st) == 0 && S_ISREG(st.st_mode)) { return st.st_size; } else { return (size_t) -1; } } static int coucal_test(const char *snum) { unsigned long count = 0; const char *const names[] = { "", "add", "delete", "dry-add", "dry-del", "test-exists", "test-not-exist" }; const struct { enum { DO_END, DO_ADD, DO_DEL, DO_DRY_ADD, DO_DRY_DEL, TEST_ADD, TEST_DEL } type; size_t modulus; size_t offset; } bench[] = { { DO_ADD, 4, 0 }, /* add 4/0 */ { TEST_ADD, 4, 0 }, /* check 4/0 */ { TEST_DEL, 4, 1 }, /* check 4/1 */ { TEST_DEL, 4, 2 }, /* check 4/2 */ { TEST_DEL, 4, 3 }, /* check 4/3 */ { DO_DRY_DEL, 4, 1 }, /* del 4/1 */ { DO_DRY_DEL, 4, 2 }, /* del 4/2 */ { DO_DRY_DEL, 4, 3 }, /* del 4/3 */ { DO_ADD, 4, 1 }, /* add 4/1 */ { DO_DRY_ADD, 4, 1 }, /* add 4/1 */ { TEST_ADD, 4, 0 }, /* check 4/0 */ { TEST_ADD, 4, 1 }, /* check 4/1 */ { TEST_DEL, 4, 2 }, /* check 4/2 */ { TEST_DEL, 4, 3 }, /* check 4/3 */ { DO_ADD, 4, 2 }, /* add 4/2 */ { DO_DRY_DEL, 4, 3 }, /* del 4/3 */ { DO_ADD, 4, 3 }, /* add 4/3 */ { DO_DEL, 4, 3 }, /* del 4/3 */ { TEST_ADD, 4, 0 }, /* check 4/0 */ { TEST_ADD, 4, 1 }, /* check 4/1 */ { TEST_ADD, 4, 2 }, /* check 4/2 */ { TEST_DEL, 4, 3 }, /* check 4/3 */ { DO_DEL, 4, 0 }, /* del 4/0 */ { DO_DEL, 4, 1 }, /* del 4/1 */ { DO_DEL, 4, 2 }, /* del 4/2 */ /* empty here */ { TEST_DEL, 1, 0 }, /* check */ { DO_ADD, 4, 0 }, /* add 4/0 */ { DO_ADD, 4, 1 }, /* add 4/1 */ { DO_ADD, 4, 2 }, /* add 4/2 */ { DO_DEL, 42, 0 }, /* add 42/0 */ { TEST_DEL, 42, 0 }, /* check 42/0 */ { TEST_ADD, 42, 2 }, /* check 42/2 */ { DO_END } }; char *buff = NULL; const char **strings = NULL; /* produce random patterns, or read from a file */ if (sscanf(snum, "%lu", &count) != 1) { const size_t size = fsize(snum); FILE *fp = fopen(snum, "rb"); if (fp != NULL) { buff = malloc(size); if (buff != NULL && fread(buff, 1, size, fp) == size) { size_t capa = 0; size_t i, last; for(i = 0, last = 0, count = 0 ; i < size ; i++) { if (buff[i] == 10 || buff[i] == 0) { buff[i] = '\0'; if (capa == count) { if (capa == 0) { capa = 16; } else { capa <<= 1; } strings = (const char **) realloc((void*) strings, capa*sizeof(char*)); } strings[count++] = &buff[last]; last = i + 1; } } } fclose(fp); } } /* successfully read */ if (count > 0) { coucal hashtable = coucal_new(0); size_t loop; for(loop = 0 ; bench[loop].type != DO_END ; loop++) { size_t i; for(i = bench[loop].offset ; i < (size_t) count ; i += bench[loop].modulus) { int result; char buffer[256]; const char *name; const long expected = (long) i * 1664525 + 1013904223; if (strings == NULL) { snprintf(buffer, sizeof(buffer), "http://www.example.com/website/sample/for/hashtable/" "%ld/index.html?foo=%ld&bar", (long) i, (long) (expected)); name = buffer; } else { name = strings[i]; } if (bench[loop].type == DO_ADD || bench[loop].type == DO_DRY_ADD) { size_t k; result = coucal_write(hashtable, name, (uintptr_t) expected); for(k = 0 ; k < /* stash_size*2 */ 32 ; k++) { (void) coucal_write(hashtable, name, (uintptr_t) expected); } /* revert logic */ if (bench[loop].type == DO_DRY_ADD) { result = result ? 0 : 1; } } else if (bench[loop].type == DO_DEL || bench[loop].type == DO_DRY_DEL) { size_t k; result = coucal_remove(hashtable, name); for(k = 0 ; k < /* stash_size*2 */ 32 ; k++) { (void) coucal_remove(hashtable, name); } /* revert logic */ if (bench[loop].type == DO_DRY_DEL) { result = result ? 0 : 1; } } else if (bench[loop].type == TEST_ADD || bench[loop].type == TEST_DEL) { intptr_t value = -1; result = coucal_readptr(hashtable, name, &value); if (bench[loop].type == TEST_ADD && result && value != expected) { fprintf(stderr, "value failed for %s (expected %ld, got %ld)\n", name, (long) expected, (long) value); return EXIT_FAILURE; } /* revert logic */ if (bench[loop].type == TEST_DEL) { result = result ? 0 : 1; } } if (!result) { fprintf(stderr, "failed %s{%d/+%d} test on loop %ld" " at offset %ld for %s\n", names[bench[loop].type], (int) bench[loop].modulus, (int) bench[loop].offset, (long) loop, (long) i, name); return EXIT_FAILURE; } } } coucal_delete(&hashtable); fprintf(stderr, "all hashtable tests were successful!\n"); return EXIT_SUCCESS; } else { fprintf(stderr, "Malformed number\n"); return EXIT_FAILURE; } } int main(int argc, char **argv) { if (argc == 2) { return coucal_test(argv[1]); } else { fprintf(stderr, "usage: %s [number-of-tests | keys-filename]\n", argv[0]); return EXIT_FAILURE; } } httrack-3.49.5/src/coucal/sample.c0000644000175000017500000000552614336470675013706 00000000000000/* ------------------------------------------------------------ */ /* Coucal, Cuckoo hashing-based hashtable with stash area. Copyright (C) 2013-2014 Xavier Roche and other contributors All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. 3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ /* * Sample: String => String hashtable. */ #include #include #include #include "coucal.h" int main(int argc, char **argv) { int i; coucal hashtable; struct_coucal_enum enumerator; coucal_item *item; if (argc == 1 || ( argc % 2 ) != 1 ) { printf("usage: %s [key value] ..\n", argv[0]); exit(EXIT_FAILURE); } /* Create a new hashtable with default settings */ hashtable = coucal_new(0); assert(hashtable != NULL); /* Fill hashtable */ for(i = 1 ; i < argc ; i += 2) { coucal_write_pvoid(hashtable, argv[i], argv[i + 1]); } printf("stored %zu keys\n", coucal_nitems(hashtable)); /* Check we have the items */ printf("Checking keys:\n"); for(i = 1 ; i < argc ; i += 2) { void *value = NULL; if (!coucal_read_pvoid(hashtable, argv[i], &value)) { assert(! "hashtable internal error!"); } printf("%s=%s\n", argv[i], (const char*) value); } /* Enumerate */ enumerator = coucal_enum_new(hashtable); printf("Enumerating keys:\n"); while((item = coucal_enum_next(&enumerator)) != NULL) { printf("%s=%s\n", (const char*) item->name, (const char*) item->value.ptr); } /* Delete hashtable */ coucal_delete(&hashtable); return EXIT_SUCCESS; } httrack-3.49.5/src/coucal/README.md0000644000175000017500000000410614360555203013515 00000000000000coucal ====== **Coucal**, a Cuckoo-hashing-based hashtable with stash area C library. ![Greater Coucal Centropus sinensis](https://upload.wikimedia.org/wikipedia/commons/thumb/8/8d/Greater_Coucal_%28Centropus_sinensis%29_in_Hyderabad_W_IMG_8962.jpg/250px-Greater_Coucal_%28Centropus_sinensis%29_in_Hyderabad_W_IMG_8962.jpg "Centropus sinensis") > [Wikipedia] A coucal is one of about 30 species of birds in the cuckoo family. All of them belong in the subfamily Centropodinae and the genus Centropus. Unlike many Old World cuckoos, coucals are not brood parasites. This is an implementation of the cuckoo hashing algorithm ([paper](https://web.archive.org/web/20180219194838/www.it-c.dk/people/pagh/papers/cuckoo-jour.pdf) by Rasmus Pagh and Flemming Friche Rodler) with a stash area ([paper](https://web.archive.org/web/20160325171418/research.microsoft.com/pubs/73856/stash-full.9-30.pdf) by Adam Kirsch, Michael Mitzenmacher and Udi Wieder), using by default the [`MurmurHash`](https://en.wikipedia.org/wiki/MurmurHash) hash function (by Austin Appleby). This allows an efficient generic hashtable implementation, with the following features: * guaranteed constant time (Θ(1)) lookup * guaranteed constant time (Θ(1)) delete or replace * average constant time (O(1)) insert * one large memory chunk for table (and one for the key pool) * simple enumeration This library has been thoroughly tested, and is currently used by the [HTTrack](https://www.httrack.com/) project in production. ## License Copyright © 2013-2014 Xavier Roche (https://www.httrack.com/). All rights reserved. This library is licensed under the [BSD 3-Clause License](https://opensource.org/licenses/BSD-3-Clause) See the [LICENSE](LICENSE) file. ## Example ```c coucal hashtable = coucal_new(0); coucal_write_pvoid(hashtable, "foo", "bar"); printf("value==%s\n", (char*) coucal_get_pvoid(hashtable, "foo")); struct_coucal_enum enumerator = coucal_enum_new(hashtable); coucal_item *item; while((item = coucal_enum_next(&enumerator)) != NULL) { printf("%s=%s\n", (const char*) item->name, (const char*) item->value.ptr); } ``` httrack-3.49.5/src/coucal/Makefile0000644000175000017500000000215414336470675013713 00000000000000############################################################################### # # "Cuckoo Hashtables" # ############################################################################### CFILES = coucal.c all: gcc tests sample runtests clean: rm -f *.o *.obj *.so* *.dll *.exe *.pdb *.exp *.lib sample tests tar: rm -f coucal.tgz tar cvfz coucal.tgz coucal.txt coucal.c coucal.h Makefile LICENSE README.md gcc: gcc -c -fPIC -O3 -g3 -pthread \ -W -Wall -Wextra -Werror -Wno-unused-function \ -D_REENTRANT -D_GNU_SOURCE \ -DHTS_INTHASH_USES_MURMUR \ $(CFILES) gcc -shared -fPIC -O3 -Wl,-O1 -Wl,--no-undefined \ -rdynamic -shared -Wl,-soname=libcoucal.so \ coucal.o -o libcoucal.so \ -ldl -lpthread tests: gcc -c -fPIC -O3 -g3 \ -W -Wall -Wextra -Werror -Wno-unused-function \ -D_REENTRANT \ tests.c -o tests.o gcc -fPIC -O3 -Wl,-O1 \ -lcoucal -L. \ tests.o -o tests sample: gcc -c -fPIC -O3 -g3 \ -W -Wall -Wextra -Werror -Wno-unused-function \ -D_REENTRANT \ sample.c -o sample.o gcc -fPIC -O3 -Wl,-O1 \ -lcoucal -L. \ sample.o -o sample runtests: LD_LIBRARY_PATH=. ./tests 100000 httrack-3.49.5/src/coucal/LICENSE0000644000175000017500000000274614360555203013253 00000000000000Copyright (c) 2013, Xavier Roche (https://www.httrack.com/) All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. 3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. httrack-3.49.5/src/coucal/murmurhash3.h.orig0000644000175000017500000000644614336470675015651 00000000000000//----------------------------------------------------------------------------- // MurmurHash3 was written by Austin Appleby, and is placed in the public // domain. The author hereby disclaims copyright to this source code. // Note - The x86 and x64 versions do _not_ produce the same results, as the // algorithms are optimized for their respective platforms. You can still // compile and run any of them on any platform, but your performance with the // non-native version will be less than optimal. #include static uint32_t rotl32 ( uint32_t x, int8_t r ) { return (x << r) | (x >> (32 - r)); } #define ROTL32(x,y) rotl32(x,y) static uint32_t getblock32 ( const uint32_t * p, int i ) { return p[i]; } static uint32_t fmix32 ( uint32_t h ) { h ^= h >> 16; h *= 0x85ebca6b; h ^= h >> 13; h *= 0xc2b2ae35; h ^= h >> 16; return h; } #define BIG_CONSTANT(x) (x##LLU) static void MurmurHash3_x86_128 ( const void * key, const int len, uint32_t seed, void * out ) { const uint8_t * data = (const uint8_t*)key; const int nblocks = len / 16; uint32_t h1 = seed; uint32_t h2 = seed; uint32_t h3 = seed; uint32_t h4 = seed; const uint32_t c1 = 0x239b961b; const uint32_t c2 = 0xab0e9789; const uint32_t c3 = 0x38b34ae5; const uint32_t c4 = 0xa1e38b93; const uint32_t * blocks = (const uint32_t *)(data + nblocks*16); int i; for(i = -nblocks; i; i++) { uint32_t k1 = getblock32(blocks,i*4+0); uint32_t k2 = getblock32(blocks,i*4+1); uint32_t k3 = getblock32(blocks,i*4+2); uint32_t k4 = getblock32(blocks,i*4+3); k1 *= c1; k1 = ROTL32(k1,15); k1 *= c2; h1 ^= k1; h1 = ROTL32(h1,19); h1 += h2; h1 = h1*5+0x561ccd1b; k2 *= c2; k2 = ROTL32(k2,16); k2 *= c3; h2 ^= k2; h2 = ROTL32(h2,17); h2 += h3; h2 = h2*5+0x0bcaa747; k3 *= c3; k3 = ROTL32(k3,17); k3 *= c4; h3 ^= k3; h3 = ROTL32(h3,15); h3 += h4; h3 = h3*5+0x96cd1c35; k4 *= c4; k4 = ROTL32(k4,18); k4 *= c1; h4 ^= k4; h4 = ROTL32(h4,13); h4 += h1; h4 = h4*5+0x32ac3b17; } { const uint8_t * tail = (const uint8_t*)(data + nblocks*16); uint32_t k1 = 0; uint32_t k2 = 0; uint32_t k3 = 0; uint32_t k4 = 0; switch(len & 15) { case 15: k4 ^= tail[14] << 16; case 14: k4 ^= tail[13] << 8; case 13: k4 ^= tail[12] << 0; k4 *= c4; k4 = ROTL32(k4,18); k4 *= c1; h4 ^= k4; case 12: k3 ^= tail[11] << 24; case 11: k3 ^= tail[10] << 16; case 10: k3 ^= tail[ 9] << 8; case 9: k3 ^= tail[ 8] << 0; k3 *= c3; k3 = ROTL32(k3,17); k3 *= c4; h3 ^= k3; case 8: k2 ^= tail[ 7] << 24; case 7: k2 ^= tail[ 6] << 16; case 6: k2 ^= tail[ 5] << 8; case 5: k2 ^= tail[ 4] << 0; k2 *= c2; k2 = ROTL32(k2,16); k2 *= c3; h2 ^= k2; case 4: k1 ^= tail[ 3] << 24; case 3: k1 ^= tail[ 2] << 16; case 2: k1 ^= tail[ 1] << 8; case 1: k1 ^= tail[ 0] << 0; k1 *= c1; k1 = ROTL32(k1,15); k1 *= c2; h1 ^= k1; }; h1 ^= len; h2 ^= len; h3 ^= len; h4 ^= len; h1 += h2; h1 += h3; h1 += h4; h2 += h1; h3 += h1; h4 += h1; h1 = fmix32(h1); h2 = fmix32(h2); h3 = fmix32(h3); h4 = fmix32(h4); h1 += h2; h1 += h3; h1 += h4; h2 += h1; h3 += h1; h4 += h1; ((uint32_t*)out)[0] = h1; ((uint32_t*)out)[1] = h2; ((uint32_t*)out)[2] = h3; ((uint32_t*)out)[3] = h4; } } httrack-3.49.5/src/coucal/murmurhash3.h.diff0000644000175000017500000000140114336470675015603 00000000000000--- murmurhash3.h.orig 2014-06-14 14:29:11.562576736 +0200 +++ murmurhash3.h 2014-06-14 14:39:43.989624584 +0200 @@ -7,7 +7,19 @@ // compile and run any of them on any platform, but your performance with the // non-native version will be less than optimal. +#ifdef _WIN32 +#include +typedef __int8 int8_t; +typedef unsigned __int8 uint8_t; +typedef unsigned __int16 uint16_t; +typedef unsigned __int32 uint32_t; +typedef unsigned __int64 uint64_t; +#elif (defined(SOLARIS) || defined(sun) || defined(HAVE_INTTYPES_H) \ + || defined(BSD) || defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__FreeBSD_kernel__)) +#include +#else #include +#endif static uint32_t rotl32 ( uint32_t x, int8_t r ) { httrack-3.49.5/src/coucal/murmurhash3.h0000644000175000017500000000731314336470675014704 00000000000000//----------------------------------------------------------------------------- // MurmurHash3 was written by Austin Appleby, and is placed in the public // domain. The author hereby disclaims copyright to this source code. // Note - The x86 and x64 versions do _not_ produce the same results, as the // algorithms are optimized for their respective platforms. You can still // compile and run any of them on any platform, but your performance with the // non-native version will be less than optimal. #ifdef _WIN32 #include typedef __int8 int8_t; typedef unsigned __int8 uint8_t; typedef unsigned __int16 uint16_t; typedef unsigned __int32 uint32_t; typedef unsigned __int64 uint64_t; #elif (defined(SOLARIS) || defined(sun) || defined(HAVE_INTTYPES_H) \ || defined(BSD) || defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__FreeBSD_kernel__)) #include #else #include #endif static uint32_t rotl32 ( uint32_t x, int8_t r ) { return (x << r) | (x >> (32 - r)); } #define ROTL32(x,y) rotl32(x,y) static uint32_t getblock32 ( const uint32_t * p, int i ) { return p[i]; } static uint32_t fmix32 ( uint32_t h ) { h ^= h >> 16; h *= 0x85ebca6b; h ^= h >> 13; h *= 0xc2b2ae35; h ^= h >> 16; return h; } #define BIG_CONSTANT(x) (x##LLU) static void MurmurHash3_x86_128 ( const void * key, const int len, uint32_t seed, void * out ) { const uint8_t * data = (const uint8_t*)key; const int nblocks = len / 16; uint32_t h1 = seed; uint32_t h2 = seed; uint32_t h3 = seed; uint32_t h4 = seed; const uint32_t c1 = 0x239b961b; const uint32_t c2 = 0xab0e9789; const uint32_t c3 = 0x38b34ae5; const uint32_t c4 = 0xa1e38b93; const uint32_t * blocks = (const uint32_t *)(data + nblocks*16); int i; for(i = -nblocks; i; i++) { uint32_t k1 = getblock32(blocks,i*4+0); uint32_t k2 = getblock32(blocks,i*4+1); uint32_t k3 = getblock32(blocks,i*4+2); uint32_t k4 = getblock32(blocks,i*4+3); k1 *= c1; k1 = ROTL32(k1,15); k1 *= c2; h1 ^= k1; h1 = ROTL32(h1,19); h1 += h2; h1 = h1*5+0x561ccd1b; k2 *= c2; k2 = ROTL32(k2,16); k2 *= c3; h2 ^= k2; h2 = ROTL32(h2,17); h2 += h3; h2 = h2*5+0x0bcaa747; k3 *= c3; k3 = ROTL32(k3,17); k3 *= c4; h3 ^= k3; h3 = ROTL32(h3,15); h3 += h4; h3 = h3*5+0x96cd1c35; k4 *= c4; k4 = ROTL32(k4,18); k4 *= c1; h4 ^= k4; h4 = ROTL32(h4,13); h4 += h1; h4 = h4*5+0x32ac3b17; } { const uint8_t * tail = (const uint8_t*)(data + nblocks*16); uint32_t k1 = 0; uint32_t k2 = 0; uint32_t k3 = 0; uint32_t k4 = 0; switch(len & 15) { case 15: k4 ^= tail[14] << 16; case 14: k4 ^= tail[13] << 8; case 13: k4 ^= tail[12] << 0; k4 *= c4; k4 = ROTL32(k4,18); k4 *= c1; h4 ^= k4; case 12: k3 ^= tail[11] << 24; case 11: k3 ^= tail[10] << 16; case 10: k3 ^= tail[ 9] << 8; case 9: k3 ^= tail[ 8] << 0; k3 *= c3; k3 = ROTL32(k3,17); k3 *= c4; h3 ^= k3; case 8: k2 ^= tail[ 7] << 24; case 7: k2 ^= tail[ 6] << 16; case 6: k2 ^= tail[ 5] << 8; case 5: k2 ^= tail[ 4] << 0; k2 *= c2; k2 = ROTL32(k2,16); k2 *= c3; h2 ^= k2; case 4: k1 ^= tail[ 3] << 24; case 3: k1 ^= tail[ 2] << 16; case 2: k1 ^= tail[ 1] << 8; case 1: k1 ^= tail[ 0] << 0; k1 *= c1; k1 = ROTL32(k1,15); k1 *= c2; h1 ^= k1; }; h1 ^= len; h2 ^= len; h3 ^= len; h4 ^= len; h1 += h2; h1 += h3; h1 += h4; h2 += h1; h3 += h1; h4 += h1; h1 = fmix32(h1); h2 = fmix32(h2); h3 = fmix32(h3); h4 = fmix32(h4); h1 += h2; h1 += h3; h1 += h4; h2 += h1; h3 += h1; h4 += h1; ((uint32_t*)out)[0] = h1; ((uint32_t*)out)[1] = h2; ((uint32_t*)out)[2] = h3; ((uint32_t*)out)[3] = h4; } } httrack-3.49.5/src/coucal/coucal.h0000644000175000017500000004442614360555203013666 00000000000000/* ------------------------------------------------------------ */ /* Coucal, Cuckoo hashing-based hashtable with stash area. Copyright (C) 2013-2014 Xavier Roche (https://www.httrack.com/) All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. 3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ /** * Coucal, a Cuckoo-hashing-based hashtable with stash area C library. * * This hashtable library provides key/value hashtable, with by default a * string key, and integer/pointer value (with an associated optional * allocator). Both key and value can be of any type, using custom settings. * By default, the string key is dup'ed using a string pool, and the opaque * value is stored as-is (either the pointer, or an uintptr_t integer value). * It features O(1) average insertion, and guaranteed O(1) lookup, replace, * and delete operations. * * Implementation notes: * Implementation is auto-rehashable, and uses cuckoo hashing of size 2**n * with a Murmur or MD5 hash function, with one additional auxiliary hash * function. * It also uses a small stash area to handle rare cases of collisions. * Enumeration of all key/values is possible, deletion is also possible, but * currently without any auto-shrinking (ie. table will never shrink). * Overall, two main blocks are allocated: one for the items, and one for * the keys (pool). * If the string pool is being used (to store dup'ed keys), deleting is only * O(1) average, because the pool needs to be compacted time to time. * Currently the default maximum number of elements in the hashtable is * 2**31 - 1 (that is, 2,147,483,648 elements), but this default can be changed * by setting COUCAL_HASH_SIZE to a higher value (64 is the only higher value * currently supported), and rebuilding the library. * * References: * * Cuckoo Hashing, by Rasmus Pagh and Flemming Friche Rodler * https://web.archive.org/web/20180219194838/www.it-c.dk/people/pagh/papers/cuckoo-jour.pdf * * Cuckoo Stash, by Adam Kirsch, Michael Mitzenmacher and Udi Wieder * https://web.archive.org/web/20160325171418/research.microsoft.com/pubs/73856/stash-full.9-30.pdf * * MurmurHash3, by Austin Appleby * https://en.wikipedia.org/wiki/MurmurHash * * MD5 https://en.wikipedia.org/wiki/MD5 * FNV http://www.isthe.com/chongo/tech/comp/fnv/ **/ #ifndef COUCAL_DEFH #define COUCAL_DEFH /* Includes */ #ifdef _WIN32 #include typedef unsigned __int32 uint32_t; typedef unsigned __int64 uint64_t; #elif (defined(SOLARIS) || defined(sun) || defined(HAVE_INTTYPES_H) \ || defined(BSD) || defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__FreeBSD_kernel__)) #include #else #include #endif #include /* External definitions */ #ifndef COUCAL_EXTERN #ifdef _WIN32 #ifdef COUCAL_BUILDING #define COUCAL_EXTERN __declspec(dllimport) #else #define COUCAL_EXTERN __declspec(dllexport) #endif #elif ( ( defined(__GNUC__) && ( __GNUC__ >= 4 ) ) \ || ( defined(HAVE_VISIBILITY) && HAVE_VISIBILITY ) ) #define COUCAL_EXTERN extern __attribute__ ((visibility("default"))) #else #define COUCAL_EXTERN extern #endif #endif /** Key opaque type. May be a regular 'const char*'. **/ typedef void* coucal_key; /** Key constant (can not be modified) opaque type. **/ typedef const void* coucal_key_const; /** Opaque user-defined pointer. **/ typedef void* coucal_opaque; /** Value (union of any value). **/ typedef union coucal_value { /** Integer value. **/ intptr_t intg; /** Unsigned integer value. **/ uintptr_t uintg; /** Pointer value. **/ void *ptr; } coucal_value; /** Value constant. **/ typedef const coucal_value coucal_value_const; /** NULL Value. **/ #define INTHASH_VALUE_NULL { 0 } #ifndef HTS_DEF_FWSTRUCT_coucal_item #define HTS_DEF_FWSTRUCT_coucal_item typedef struct coucal_item coucal_item; #endif /** Coucal primary hash size. Default is 32-bit. **/ #ifndef COUCAL_HASH_SIZE #define COUCAL_HASH_SIZE 32 #endif /** Hash integer type. **/ #if (COUCAL_HASH_SIZE == 32) /** 32-bit hash key. **/ typedef uint32_t coucal_hashkey; #elif (COUCAL_HASH_SIZE == 64) /** 64-bit hash key. **/ typedef uint64_t coucal_hashkey; #else #error "Unsupported COUCAL_HASH_SIZE" #endif /** Pair of hashes **/ typedef struct coucal_hashkeys { coucal_hashkey hash1; coucal_hashkey hash2; } coucal_hashkeys; /** NULL pair of hashes. **/ #define INTHASH_KEYS_NULL { 0, 0 } /** Item holding a value. **/ struct coucal_item { /** Key. **/ coucal_key name; /** Value. **/ coucal_value value; /** Hashes of the key. **/ coucal_hashkeys hashes; }; /** Log level. **/ typedef enum coucal_loglevel { coucal_log_critical, coucal_log_warning, coucal_log_info, coucal_log_debug, coucal_log_trace } coucal_loglevel; /** free handler. Only used when values are markes as xxc **/ typedef void (*t_coucal_key_freehandler)(coucal_opaque arg, coucal_key key); /** Value free handler. Only used when values are markes as xxc **/ typedef void (*t_coucal_value_freehandler)(coucal_opaque arg, coucal_value value); /** Key dup handler. **/ typedef coucal_key (*t_coucal_duphandler)(coucal_opaque arg, coucal_key_const name); /** Key hash computation handler. **/ typedef coucal_hashkeys (*t_coucal_hasheshandler)(coucal_opaque arg, coucal_key_const name); /** Hashtable logging handler. **/ typedef void (*t_coucal_loghandler)(coucal_opaque arg, coucal_loglevel level, const char* format, va_list args); /** Hashtable fatal assertion failure. **/ typedef void (*t_coucal_asserthandler)(coucal_opaque arg, const char* exp, const char* file, int line); /** Key printer (debug) **/ typedef const char* (*t_coucal_printkeyhandler)(coucal_opaque arg, coucal_key_const name); /** Value printer (debug) **/ typedef const char* (*t_coucal_printvaluehandler)(coucal_opaque arg, coucal_value_const value); /** * Value comparison handler (returns non-zero value if strings are equal). **/ typedef int (*t_coucal_cmphandler)(coucal_opaque arg, coucal_key_const a, coucal_key_const b); /** Hashtable (opaque structure). **/ #ifndef HTS_DEF_FWSTRUCT_struct_coucal #define HTS_DEF_FWSTRUCT_struct_coucal typedef struct struct_coucal struct_coucal, *coucal; #endif /** Hashtable enumeration (opaque structure). **/ #ifndef HTS_DEF_FWSTRUCT_struct_coucal_enum #define HTS_DEF_FWSTRUCT_struct_coucal_enum typedef struct struct_coucal_enum struct_coucal_enum; #endif /** Enumeration. **/ struct struct_coucal_enum { coucal table; size_t index; }; #ifdef __cplusplus extern "C" { #endif /** * Create a new hashtable, with initial bucket size of 'size'. * If size is 0, use the default minimal bucket size. * Return a non-NULL pointer upon success. * * By default, keys are supposed to be '\0'-terminated strings, which are * duplicated by the library (the passed pointer does not need to be * persistent), and values are opaque pointers (or integers) which are copied * "as is", without further processing. Use coucal_value_set_key_handler() * and coucal_value_set_value_handler() to alter this default behavior. **/ COUCAL_EXTERN coucal coucal_new(size_t size); /** * Was the hashtable successfully created ? * Return non-zero value if the hashtable is valid. **/ COUCAL_EXTERN int coucal_created(coucal hashtable); /** * Delete a hashtable, freeing all entries. **/ COUCAL_EXTERN void coucal_delete(coucal * hashtable); /** * Return the number of items in the hashtable. **/ COUCAL_EXTERN size_t coucal_nitems(coucal hashtable); /** * Return the memory size taken by the hashtable. * (This does not take account of the possible memory taken by values) **/ COUCAL_EXTERN size_t coucal_memory_size(coucal hashtable); /** * Return the library hash size compiled. * The returned value MUST match COUCAL_HASH_SIZE. **/ COUCAL_EXTERN size_t coucal_hash_size(void); /** * If 'flag' is non-zero, calls coucal_value_set_value_handler() with * default system free() handler function, otherwise, free the value handlers. **/ COUCAL_EXTERN void coucal_value_is_malloc(coucal hashtable, int flag); /** * Set handlers for values. * free: this handler will be called when a value is to be removed from * the hashtable. if NULL, values won't be free'd. * arg: opaque custom argument to be used by functions. * Handler(s) MUST NOT be changed once elements have been added. **/ COUCAL_EXTERN void coucal_value_set_value_handler(coucal hashtable, t_coucal_value_freehandler free, coucal_opaque arg); /** * Set handlers for keys. * dup: handler called to duplicate a key. if NULL, the internal pool is used. * free: handler called to free a key. if NULL, the internal pool is used. * hash: hashing handler, called to hash a key. if NULL, the default hash * function is used. * equals: comparison handler, returning non-zero value when two keys are * identical. if NULL, the default comparison function is used. * arg: opaque custom argument to be used by functions. * Handler(s) MUST NOT be changed once elements have been added. **/ COUCAL_EXTERN void coucal_value_set_key_handler(coucal hashtable, t_coucal_duphandler dup, t_coucal_key_freehandler free, t_coucal_hasheshandler hash, t_coucal_cmphandler equals, coucal_opaque arg); /** * Set assertion failure handler. * log: handler called upon serious programming error * fatal: handler called upon serious programming error **/ COUCAL_EXTERN void coucal_set_assert_handler(coucal hashtable, t_coucal_loghandler log, t_coucal_asserthandler fatal, coucal_opaque arg); /** * Set pretty print loggers (debug). Both handlers must return a string * pointer which shall be valid until the next call. Both key and value * pointers shall be valid at the same time. * name: handler called to print the string representation of the name * value: handler called to print the string representation of the value **/ COUCAL_EXTERN void coucal_set_print_handler(coucal hashtable, t_coucal_printkeyhandler key, t_coucal_printvaluehandler value, coucal_opaque arg); /** * Set the hashtable name, for degugging purpose. * name: the hashtable name (ASCII or UTF-8) */ COUCAL_EXTERN void coucal_set_name(coucal hashtable, coucal_key_const name); /** * Get the hashtable name, for degugging purpose. * Return NULL if no name was defined. **/ COUCAL_EXTERN const char* coucal_get_name(coucal hashtable); /** * Read an integer entry from the hashtable. * Return non-zero value upon success and sets intvalue. **/ COUCAL_EXTERN int coucal_read(coucal hashtable, coucal_key_const name, intptr_t * intvalue); /** * Same as coucal_read(), but return 0 is the value was zero. **/ COUCAL_EXTERN int coucal_readptr(coucal hashtable, coucal_key_const name, intptr_t * intvalue); /** * Read an integer entry from the hashtable. * Return 0 if the entry could not be found. **/ COUCAL_EXTERN intptr_t coucal_get_intptr(coucal hashtable, coucal_key_const name); /** * Return non-zero value if the given entry exists. **/ COUCAL_EXTERN int coucal_exists(coucal hashtable, coucal_key_const name); /** * Read an entry from the hashtable. * Return non-zero value upon success and sets value. **/ COUCAL_EXTERN int coucal_read_value(coucal hashtable, coucal_key_const name, coucal_value *value); /** * Write an entry to the hashtable. * Return non-zero value if the entry was added, zero if it was replaced. **/ COUCAL_EXTERN int coucal_write_value(coucal hashtable, coucal_key_const name, coucal_value_const value); /** * Read a pointer entry from the hashtable. * Return non-zero value upon success and sets value. **/ COUCAL_EXTERN int coucal_read_pvoid(coucal hashtable, coucal_key_const name, void **value); /** * Read a pointer entry from the hashtable and returns its value. * Return NULL if the entry could not be found. **/ COUCAL_EXTERN void* coucal_get_pvoid(coucal hashtable, coucal_key_const name); /** * Write a pointer entry to the hashtable. * Return non-zero value if the entry was added, zero if it was replaced. **/ COUCAL_EXTERN int coucal_write_pvoid(coucal hashtable, coucal_key_const name, void *value); /** * Alias to coucal_write_pvoid() **/ COUCAL_EXTERN void coucal_add_pvoid(coucal hashtable, coucal_key_const name, void *value); /** * Write an integer entry to the hashtable. * Return non-zero value if the entry was added, zero if it was replaced. **/ COUCAL_EXTERN int coucal_write(coucal hashtable, coucal_key_const name, intptr_t value); /** * Alias to coucal_write() **/ COUCAL_EXTERN void coucal_add(coucal hashtable, coucal_key_const name, intptr_t value); /** * Increment an entry value in the hashtable * (or create a new entry with value 1 if it does not yet exist) * Return non-zero value if the entry was added, zero if it was changed. **/ COUCAL_EXTERN int coucal_inc(coucal hashtable, coucal_key_const name); /** * Decrement an entry value in the hashtable * (or create a new entry with value -1 if it does not yet exist) * Return non-zero value if the entry was added, zero if it was changed. **/ COUCAL_EXTERN int coucal_dec(coucal hashtable, coucal_key_const name); /** * Fetch an entry value from the hashtable. * Returns NULL if the entry could not be found. * The returned pointer is only valid until next call to this library, and can * be used for read or write operations. **/ COUCAL_EXTERN coucal_value* coucal_fetch_value(coucal hashtable, coucal_key_const name); /** * Fetch an entry value from the hashtable, given a name, and its hashes. * Returns NULL if the entry could not be found. * The returned pointer is only valid until next call to this library, and can * be used for read or write operations. * The hashes MUST have been computed using coucal_calc_hashes(), or by * copying an existing hash during an enumeration. * The use of a non-matching hash is safe, but will return NULL. **/ COUCAL_EXTERN coucal_value* coucal_fetch_value_hashes(coucal hashtable, coucal_key_const name, const coucal_hashkeys *hashes); /** * Remove an entry from the hashtable * Return non-zero value if the entry was removed, zero otherwise. **/ COUCAL_EXTERN int coucal_remove(coucal hashtable, coucal_key_const name); /** * Return a new enumerator. * Note: deleting entries is safe while enumerating, but adding entries * lead to undefined enumeration behavior (yet safe). **/ COUCAL_EXTERN struct_coucal_enum coucal_enum_new(coucal hashtable); /** * Enumerate the next entry. **/ COUCAL_EXTERN coucal_item *coucal_enum_next(struct_coucal_enum * e); /** * Compute a hash of a key for the hashtable 'hashtable'. * The returned hash is suitable for use with coucal_fetch_value_hashes() * Note: the default implementation uses coucal_hash_string() **/ COUCAL_EXTERN coucal_hashkeys coucal_calc_hashes(coucal hashtable, coucal_key_const value); /** * Compute a hash, given a string. This is the default function used for * hashing keys, which are by default strings. This function uses * coucal_hash_data() as backend. **/ COUCAL_EXTERN coucal_hashkeys coucal_hash_string(const char *value); /** * Compute a hash, given an opaque buffer. **/ COUCAL_EXTERN coucal_hashkeys coucal_hash_data(const void *data, size_t size); /** * Set default global assertion failure handler. * The handler will be used if no specific handler was defined in the * hashtable itself. * log: handler called upon serious error log (opaque argument * is the hashtable itself) * fatal: handler called upon serious programming error (opaque argument * is the hashtable itself) **/ COUCAL_EXTERN void coucal_set_global_assert_handler(t_coucal_loghandler log, t_coucal_asserthandler fatal); #ifdef __cplusplus } #endif #endif httrack-3.49.5/src/coucal/coucal.c0000644000175000017500000014763614360555203013670 00000000000000/* ------------------------------------------------------------ */ /* Coucal, Cuckoo hashing-based hashtable with stash area. Copyright (C) 2013-2014 Xavier Roche (https://www.httrack.com/) All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. 3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #include #include #include #include #include #include "coucal.h" /* We use murmur hashing by default, even if md5 can be a good candidate, for its quality regarding diffusion and collisions. MD5 is slower than other hashing functions, but is known to be an excellent hashing function. FNV-1 is generally good enough for this purpose, too, but the performance gain is not sufficient to use it by default. On several benchmarks, both MD5 and FNV were quite good (0.45 cuckoo moved on average for each new item inserted in the hashtable), but FNV-1 was more prone to mutual collisions (creating cycles requiring stash handling), and was causing the stash area to be more filled than the MD5 variant. Simpler hashing functions, such as rolling hashes (LCG) were also tested, but with collision rate and diffusion were terrible. [ On a 10M key tests, both variants acheived 0.45 cuckoo/add ration, but the FNV-1 variant collided 11 times with a maximum stash area filled with 4 entries ; whereas the MD5 variant did only collide once ] */ #if (!defined(HTS_INTHASH_USES_MD5) \ && !defined(HTS_INTHASH_USES_OPENSSL_MD5) \ && !defined(HTS_INTHASH_USES_MURMUR) \ && !defined(HTS_INTHASH_USES_FNV1) \ ) /* Temporry: fixing Invalid address alignment issues */ #if (defined(HAVE_ALIGNED_ACCESS_REQUIRED) \ || defined(__sparc__) \ || defined(mips) || defined(__mips__) || defined(MIPS) || defined(_MIPS_) \ || defined(arm) || defined(__arm__) || defined(ARM) || defined(_ARM_) \ ) #ifndef LIBHTTRACK_EXPORTS #define HTS_INTHASH_USES_OPENSSL_MD5 1 #else #define HTS_INTHASH_USES_MD5 1 #endif #else #define HTS_INTHASH_USES_MURMUR 1 #endif #endif /* Dispatch includes */ #if (defined(HTS_INTHASH_USES_MURMUR)) #include "murmurhash3.h" #elif (defined(HTS_INTHASH_USES_MD5)) #include "md5.h" #define HashMD5Init(CTX, FLAG) MD5Init(CTX, FLAG) #define HashMD5Update(CTX, DATA, SIZE) MD5Update(CTX, DATA, SIZE) #define HashMD5Final(DIGEST, CTX) MD5Final(DIGEST, CTX) #define HashMD5Context MD5CTX #elif (defined(HTS_INTHASH_USES_OPENSSL_MD5)) #include #define HashMD5Init(CTX, FLAG) MD5_Init(CTX) #define HashMD5Update(CTX, DATA, SIZE) MD5_Update(CTX, DATA, SIZE) #define HashMD5Final(DIGEST, CTX) MD5_Final(DIGEST, CTX) #define HashMD5Context MD5_CTX #else #error "No hash method defined" #endif /** Size of auxiliary stash. **/ #define STASH_SIZE 16 /** Minimum value for lg_size. **/ #define MIN_LG_SIZE 4 /** Minimum value for pool.capacity. **/ #define MIN_POOL_CAPACITY 256 /* 64-bit constant */ #if (defined(WIN32)) #define UINT_64_CONST(X) ((uint64_t) (X)) #define UINT_64_FORMAT "I64d" #elif (defined(_LP64) || defined(__x86_64__) \ || defined(__powerpc64__) || defined(__64BIT__)) #define UINT_64_CONST(X) ((uint64_t) X##UL) #define UINT_64_FORMAT "ld" #else #define UINT_64_CONST(X) ((uint64_t) X##ULL) #define UINT_64_FORMAT "lld" #endif /** Hashtable. **/ struct struct_coucal { /** Hashtable items. **/ coucal_item *items; /** Log-2 of the hashtable size. **/ size_t lg_size; /** Number of used items (<= POW2(lg_size)). **/ size_t used; /** Stash area for collisions. **/ struct { /** Stash items. **/ coucal_item items[STASH_SIZE]; /** Stash size (<= STASH_SIZE). **/ size_t size; } stash; /** String pool. **/ struct { /** String buffer. **/ char *buffer; /** Buffer used size (high watermark). **/ size_t size; /** Buffer capacity. **/ size_t capacity; /** Used chars (== size if compacted). **/ size_t used; } pool; /** Statistics **/ struct { /** Highest stash.size seen. **/ size_t max_stash_size; /** Number of writes. **/ size_t write_count; /** Number of writes causing an add. **/ size_t add_count; /** Number of cuckoo moved during adds. **/ size_t cuckoo_moved; /** Number of items added to stash. **/ size_t stash_added; /** Number of hashtable rehash/expand operations. **/ size_t rehash_count; /** Number of pool compact operations. **/ size_t pool_compact_count; /** Number of pool realloc operations. **/ size_t pool_realloc_count; } stats; /** Settings. **/ struct { /** How to handle values (might be NULL). **/ struct { /** free() **/ t_coucal_value_freehandler free; /** opaque argument **/ coucal_opaque arg; } value; /** How to handle names (might be NULL). **/ struct { /** strdup() **/ t_coucal_duphandler dup; /** free() **/ t_coucal_key_freehandler free; /** hash **/ t_coucal_hasheshandler hash; /** comparison **/ t_coucal_cmphandler equals; /** opaque argument **/ coucal_opaque arg; } key; /** How to handle fatal assertions (might be NULL). **/ struct { /** logging **/ t_coucal_loghandler log; /** abort() **/ t_coucal_asserthandler fatal; /** opaque argument **/ coucal_opaque arg; /** hashtable name for logging **/ coucal_key_const name; } error; /** How to handle pretty-print (debug) (might be NULL). **/ struct { /** key print() **/ t_coucal_printkeyhandler key; /** value print() **/ t_coucal_printvaluehandler value; /** opaque argument **/ coucal_opaque arg; } print; } custom; }; /* Assertion check. */ #define coucal_assert(HASHTABLE, EXP) \ (void)( (EXP) || (coucal_assert_failed(HASHTABLE, #EXP, __FILE__, __LINE__), 0) ) /* Compiler-specific. */ #ifdef __GNUC__ #define INTHASH_PRINTF_FUN(fmt, arg) __attribute__ ((format (printf, fmt, arg))) #define INTHASH_INLINE __inline__ #elif (defined(_MSC_VER)) #define INTHASH_PRINTF_FUN(FMT, ARGS) #define INTHASH_INLINE __inline #else #define INTHASH_PRINTF_FUN(FMT, ARGS) #define INTHASH_INLINE #endif /* Logging level. */ static void coucal_log(const coucal hashtable, coucal_loglevel level, const char *format, va_list args); #define DECLARE_LOG_FUNCTION(NAME, LEVEL) \ static void NAME(const coucal hashtable, const char *format, ...) \ INTHASH_PRINTF_FUN(2, 3); \ static void NAME(const coucal hashtable, const char *format, ...) { \ va_list args; \ va_start(args, format); \ coucal_log(hashtable, LEVEL, format, args); \ va_end(args); \ } #if 0 /* Verbose. */ DECLARE_LOG_FUNCTION(coucal_crit, coucal_log_critical) DECLARE_LOG_FUNCTION(coucal_warning, coucal_log_warning) DECLARE_LOG_FUNCTION(coucal_info, coucal_log_info) DECLARE_LOG_FUNCTION(coucal_debug, coucal_log_debug) DECLARE_LOG_FUNCTION(coucal_trace, coucal_log_trace) #elif 0 /* Info. */ DECLARE_LOG_FUNCTION(coucal_crit, coucal_log_critical) DECLARE_LOG_FUNCTION(coucal_warning, coucal_log_warning) DECLARE_LOG_FUNCTION(coucal_info, coucal_log_info) #define coucal_debug coucal_log #define coucal_trace coucal_nolog #else /* No logging except stats and critical. */ DECLARE_LOG_FUNCTION(coucal_crit, coucal_log_critical) DECLARE_LOG_FUNCTION(coucal_warning, coucal_log_warning) DECLARE_LOG_FUNCTION(coucal_info, coucal_log_info) #define coucal_debug coucal_nolog #define coucal_trace coucal_nolog #endif /* 2**X */ #define POW2(X) ( (size_t) 1 << (X) ) /* the empty string for the string pool */ static char the_empty_string[1] = { 0 }; /* global assertion handler */ static t_coucal_asserthandler global_assert_handler = NULL; /* global assertion handler */ static t_coucal_loghandler global_log_handler = NULL; /* default assertion handler, if neither hashtable one nor global one were defined */ static void coucal_fail(const char* exp, const char* file, int line) { fprintf(stderr, "assertion '%s' failed at %s:%d\n", exp, file, line); abort(); } /* assert failed handler. */ static void coucal_assert_failed(const coucal hashtable, const char* exp, const char* file, int line) { const char *const name = coucal_get_name(hashtable); coucal_crit(hashtable, "hashtable %s: %s failed at %s:%d", name != NULL ? name : "", exp, file, line); if (hashtable != NULL && hashtable->custom.error.fatal != NULL) { hashtable->custom.error.fatal(hashtable->custom.error.arg, exp, file, line); } else if (global_assert_handler != NULL) { global_assert_handler(hashtable, exp, file, line); } else { coucal_fail(exp, file, line); } abort(); } /* Logging */ static void coucal_log(const coucal hashtable, coucal_loglevel level, const char *format, va_list args) { coucal_assert(hashtable, format != NULL); if (hashtable != NULL && hashtable->custom.error.log != NULL) { hashtable->custom.error.log(hashtable->custom.error.arg, level, format, args); } else if (global_log_handler != NULL) { global_log_handler(hashtable, level, format, args); } else { fprintf(stderr, "[%p] ", (void*) hashtable); (void) vfprintf(stderr, format, args); putc('\n', stderr); } } /* No logging (should be dropped by the compiler) */ static INTHASH_INLINE void coucal_nolog(const coucal hashtable, const char *format, ...) INTHASH_PRINTF_FUN(2, 3); static INTHASH_INLINE void coucal_nolog(const coucal hashtable, const char *format, ...) { (void) hashtable; (void) format; } const char* coucal_get_name(coucal hashtable) { return hashtable->custom.error.name; } static void coucal_log_stats(coucal hashtable) { const char *const name = coucal_get_name(hashtable); coucal_info(hashtable, "hashtable %s%s%ssummary: " "size=%"UINT_64_FORMAT" (lg2=%"UINT_64_FORMAT") " "used=%"UINT_64_FORMAT" " "stash-size=%"UINT_64_FORMAT" " "pool-size=%"UINT_64_FORMAT" " "pool-capacity=%"UINT_64_FORMAT" " "pool-used=%"UINT_64_FORMAT" " "writes=%"UINT_64_FORMAT" " "(new=%"UINT_64_FORMAT") " "moved=%"UINT_64_FORMAT " " "stashed=%"UINT_64_FORMAT" " "max-stash-size=%"UINT_64_FORMAT" " "avg-moved=%g " "rehash=%"UINT_64_FORMAT" " "pool-compact=%"UINT_64_FORMAT" " "pool-realloc=%"UINT_64_FORMAT" " "memory=%"UINT_64_FORMAT, name != NULL ? "\"" : "", name != NULL ? name : "", name != NULL ? "\" " : "", (uint64_t) POW2(hashtable->lg_size), (uint64_t) hashtable->lg_size, (uint64_t) hashtable->used, (uint64_t) hashtable->stash.size, (uint64_t) hashtable->pool.size, (uint64_t) hashtable->pool.capacity, (uint64_t) hashtable->pool.used, (uint64_t) hashtable->stats.write_count, (uint64_t) hashtable->stats.add_count, (uint64_t) hashtable->stats.cuckoo_moved, (uint64_t) hashtable->stats.stash_added, (uint64_t) hashtable->stats.max_stash_size, (double) hashtable->stats.cuckoo_moved / (double) hashtable->stats.add_count, (uint64_t) hashtable->stats.rehash_count, (uint64_t) hashtable->stats.pool_compact_count, (uint64_t) hashtable->stats.pool_realloc_count, (uint64_t) coucal_memory_size(hashtable) ); } /* default hash function when key is a regular C-string */ coucal_hashkeys coucal_hash_data(const void *data_, size_t size) { const unsigned char *const data = (const unsigned char *) data_; #if (defined(HTS_INTHASH_USES_MD5) || defined(HTS_INTHASH_USES_OPENSSL_MD5)) /* compute a regular MD5 and extract two 32-bit integers */ HashMD5Context ctx; union { unsigned char md5digest[16]; #if (COUCAL_HASH_SIZE == 32) coucal_hashkeys mhashes[2]; #endif coucal_hashkeys hashes; } u; /* compute MD5 */ HashMD5Init(&ctx, 0); HashMD5Update(&ctx, data, (unsigned int) size); HashMD5Final(u.md5digest, &ctx); #if (COUCAL_HASH_SIZE == 32) /* mix mix mix */ u.mhashes[0].hash1 ^= u.mhashes[1].hash1; u.mhashes[0].hash2 ^= u.mhashes[1].hash2; #endif /* do not keep identical hashes */ if (u.hashes.hash1 == u.hashes.hash2) { u.hashes.hash2 = ~u.hashes.hash2; } return u.hashes; #elif (defined(HTS_INTHASH_USES_MURMUR)) union { uint32_t result[4]; coucal_hashkeys hashes; } u; MurmurHash3_x86_128(data, (const int) size, 42, &u.result); #if (COUCAL_HASH_SIZE == 32) /* mix mix mix */ u.result[0] ^= u.result[2]; u.result[1] ^= u.result[3]; #endif /* do not keep identical hashes */ if (u.hashes.hash1 == u.hashes.hash2) { u.hashes.hash2 = ~u.hashes.hash2; } return u.hashes; #elif (defined(HTS_INTHASH_USES_FNV1)) /* compute two Fowler-Noll-Vo hashes (64-bit FNV-1 variant) ; each 64-bit hash being XOR-folded into a single 32-bit hash. */ size_t i; coucal_hashkeys hashes; uint64_t h1, h2; /* FNV-1, 64-bit. */ #define FNV1_PRIME UINT_64_CONST(1099511628211) #define FNV1_OFFSET_BASIS UINT_64_CONST(14695981039346656037) /* compute the hashes ; second variant is using xored data */ h1 = FNV1_OFFSET_BASIS; h2 = ~FNV1_OFFSET_BASIS; for(i = 0 ; i < size ; i++) { const unsigned char c1 = data[i]; const unsigned char c2 = ~c1; h1 = ( h1 * FNV1_PRIME ) ^ c1; h2 = ( h2 * FNV1_PRIME ) ^ c2; } #if (COUCAL_HASH_SIZE == 32) /* XOR-folding to improve diffusion (Wikipedia) */ hashes.hash1 = ( (uint32_t) h1 ^ (uint32_t) ( h1 >> 32 ) ); hashes.hash2 = ( (uint32_t) h2 ^ (uint32_t) ( h2 >> 32 ) ); #elif (COUCAL_HASH_SIZE == 64) /* Direct hashes */ hashes.hash1 = h1; hashes.hash2 = h2; #else #error "Unsupported COUCAL_HASH_SIZE" #endif #undef FNV1_PRIME #undef FNV1_OFFSET_BASIS /* do not keep identical hashes */ if (hashes.hash1 == hashes.hash2) { hashes.hash2 = ~hashes.hash2; } return hashes; #else #error "Undefined hashing method" #endif } INTHASH_INLINE coucal_hashkeys coucal_hash_string(const char *name) { return coucal_hash_data(name, strlen(name)); } INTHASH_INLINE coucal_hashkeys coucal_calc_hashes(coucal hashtable, coucal_key_const value) { return hashtable->custom.key.hash == NULL ? coucal_hash_string(value) : hashtable->custom.key.hash(hashtable->custom.key.arg, value); } /* position 'pos' is free ? */ static INTHASH_INLINE int coucal_is_free(const coucal hashtable, size_t pos) { return hashtable->items[pos].name == NULL; } /* compare two keys ; by default using strcmp() */ static INTHASH_INLINE int coucal_equals(coucal hashtable, coucal_key_const a, coucal_key_const b) { return hashtable->custom.key.equals == NULL ? strcmp((const char*) a, (const char*) b) == 0 : hashtable->custom.key.equals(hashtable->custom.key.arg, a, b); } static INTHASH_INLINE int coucal_matches_(coucal hashtable, const coucal_item *const item, coucal_key_const name, const coucal_hashkeys *hashes) { return item->name != NULL && item->hashes.hash1 == hashes->hash1 && item->hashes.hash2 == hashes->hash2 && coucal_equals(hashtable, item->name, name); } static INTHASH_INLINE int coucal_matches(coucal hashtable, size_t pos, coucal_key_const name, const coucal_hashkeys *hashes) { const coucal_item *const item = &hashtable->items[pos]; return coucal_matches_(hashtable, item, name, hashes); } /* compact string pool ; does not necessarily change the capacity */ static void coucal_compact_pool(coucal hashtable, size_t capacity) { const size_t hash_size = POW2(hashtable->lg_size); size_t i; char*const old_pool = hashtable->pool.buffer; const size_t old_size = hashtable->pool.size; size_t count = 0; /* we manage the string pool */ coucal_assert(hashtable, hashtable->custom.key.dup == NULL); /* statistics */ hashtable->stats.pool_compact_count++; /* change capacity now */ if (hashtable->pool.capacity != capacity) { hashtable->pool.capacity = capacity; } /* realloc */ hashtable->pool.buffer = malloc(hashtable->pool.capacity); hashtable->pool.size = 0; hashtable->pool.used = 0; if (hashtable->pool.buffer == NULL) { coucal_debug(hashtable, "** hashtable string pool compaction error: could not allocate " "%"UINT_64_FORMAT" bytes", (uint64_t) hashtable->pool.capacity); coucal_assert(hashtable, ! "hashtable string pool compaction error"); } /* relocate a string on a different pool */ #define RELOCATE_STRING(S) do { \ if (S != NULL && S != the_empty_string) { \ const char *const src = (S); \ char *const dest = \ &hashtable->pool.buffer[hashtable->pool.size]; \ const size_t capacity = hashtable->pool.capacity; \ char *const max_dest = \ &hashtable->pool.buffer[capacity]; \ /* copy string */ \ coucal_assert(hashtable, dest < max_dest); \ dest[0] = src[0]; \ { \ size_t i; \ for(i = 1 ; src[i - 1] != '\0' ; i++) { \ coucal_assert(hashtable, &dest[i] < max_dest); \ dest[i] = src[i]; \ } \ /* update pool size */ \ hashtable->pool.size += i; \ coucal_assert(hashtable, \ hashtable->pool.size <= capacity); \ } \ /* update source */ \ S = dest; \ count++; \ } \ } while(0) /* relocate */ for(i = 0 ; i < hash_size ; i++) { RELOCATE_STRING(hashtable->items[i].name); } for(i = 0 ; i < hashtable->stash.size ; i++) { RELOCATE_STRING(hashtable->stash.items[i].name); } #undef RELOCATE_STRING /* compacted (used chars == current size) */ hashtable->pool.used = hashtable->pool.size; /* wipe previous pool */ free(old_pool); coucal_debug(hashtable, "compacted string pool for %"UINT_64_FORMAT" strings: " "%"UINT_64_FORMAT" bytes => %"UINT_64_FORMAT" bytes", (uint64_t) count, (uint64_t) old_size, (uint64_t) hashtable->pool.size); } /* realloc (expand) string pool ; does not change the compacity */ static void coucal_realloc_pool(coucal hashtable, size_t capacity) { const size_t hash_size = POW2(hashtable->lg_size); char *const oldbase = hashtable->pool.buffer; size_t count = 0; /* we manage the string pool */ coucal_assert(hashtable, hashtable->custom.key.dup == NULL); /* compact instead ? */ if (hashtable->pool.used < ( hashtable->pool.size*3 ) / 4) { coucal_compact_pool(hashtable, capacity); return ; } /* statistics */ hashtable->stats.pool_realloc_count++; /* change capacity now */ hashtable->pool.capacity = capacity; /* realloc */ hashtable->pool.buffer = realloc(hashtable->pool.buffer, hashtable->pool.capacity); if (hashtable->pool.buffer == NULL) { coucal_crit(hashtable, "** hashtable string pool allocation error: could not allocate " "%"UINT_64_FORMAT" bytes", (uint64_t) hashtable->pool.capacity); coucal_assert(hashtable, ! "hashtable string pool allocation error"); } /* recompute string address */ #define RECOMPUTE_STRING(S) do { \ if (S != NULL && S != the_empty_string) { \ const size_t offset = (const char*) (S) - oldbase; \ coucal_assert(hashtable, offset < hashtable->pool.capacity); \ S = &hashtable->pool.buffer[offset]; \ count++; \ } \ } while(0) /* recompute string addresses */ if (hashtable->pool.buffer != oldbase) { size_t i; for(i = 0 ; i < hash_size ; i++) { RECOMPUTE_STRING(hashtable->items[i].name); } for(i = 0 ; i < hashtable->stash.size ; i++) { RECOMPUTE_STRING(hashtable->stash.items[i].name); } } #undef RECOMPUTE_STRING coucal_debug(hashtable, "reallocated string pool for " "%"UINT_64_FORMAT" strings: %"UINT_64_FORMAT" bytes", (uint64_t) count, (uint64_t) hashtable->pool.capacity); } static coucal_key coucal_dup_name_internal(coucal hashtable, coucal_key_const name_) { const char *const name = (const char*) name_; const size_t len = strlen(name) + 1; char *s; /* the pool does not allow empty strings for safety purpose ; handhe that (keys are being emptied when free'd to detect duplicate free) */ if (len == 1) { coucal_assert(hashtable, the_empty_string[0] == '\0'); return the_empty_string; } /* expand pool capacity */ coucal_assert(hashtable, hashtable->pool.size <= hashtable->pool.capacity); if (hashtable->pool.capacity - hashtable->pool.size < len) { size_t capacity; for(capacity = MIN_POOL_CAPACITY ; capacity < hashtable->pool.size + len ; capacity <<= 1) ; coucal_assert(hashtable, hashtable->pool.size < capacity); coucal_realloc_pool(hashtable, capacity); } /* copy */ coucal_assert(hashtable, len + hashtable->pool.size <= hashtable->pool.capacity); s = &hashtable->pool.buffer[hashtable->pool.size]; memcpy(s, name, len); hashtable->pool.size += len; hashtable->pool.used += len; return s; } /* duplicate a key. default is to use the internal pool. */ static INTHASH_INLINE coucal_key coucal_dup_name(coucal hashtable, coucal_key_const name) { return hashtable->custom.key.dup == NULL ? coucal_dup_name_internal(hashtable, name) : hashtable->custom.key.dup(hashtable->custom.key.arg, name); } /* internal pool free handler. note: pointer must have been kicked from the pool first */ static void coucal_free_key_internal(coucal hashtable, coucal_key name_) { char *const name = (char*) name_; const size_t len = strlen(name) + 1; /* see coucal_dup_name_internal() handling */ if (len == 1 && name == the_empty_string) { coucal_assert(hashtable, the_empty_string[0] == '\0'); return ; } coucal_assert(hashtable, *name != '\0' || !"duplicate or bad string pool release"); hashtable->pool.used -= len; *name = '\0'; /* the string is now invalidated */ /* compact the pool is too many holes */ if (hashtable->pool.used != 0 && hashtable->pool.used < hashtable->pool.size / 2) { size_t capacity = hashtable->pool.capacity; /* compact and shrink */ if (hashtable->pool.used < capacity / 4) { capacity /= 2; } coucal_assert(hashtable, hashtable->pool.used < capacity); coucal_compact_pool(hashtable, capacity); } } /* free a key. default is to use the internal pool. note: pointer must have been kicked from the pool first */ static void coucal_free_key(coucal hashtable, coucal_key name) { if (hashtable->custom.key.free == NULL) { coucal_free_key_internal(hashtable, name); } else { hashtable->custom.key.free(hashtable->custom.key.arg, name); } } static INTHASH_INLINE size_t coucal_hash_to_pos_(size_t lg_size, coucal_hashkey hash) { const coucal_hashkey mask = POW2(lg_size) - 1; return hash & mask; } static INTHASH_INLINE size_t coucal_hash_to_pos(const coucal hashtable, coucal_hashkey hash) { return coucal_hash_to_pos_(hashtable->lg_size, hash); } int coucal_read_pvoid(coucal hashtable, coucal_key_const name, void **pvalue) { coucal_value value = INTHASH_VALUE_NULL; const int ret = coucal_read_value(hashtable, name, (pvalue != NULL) ? &value : NULL); if (pvalue != NULL) *pvalue = value.ptr; return ret; } void* coucal_get_pvoid(coucal hashtable, coucal_key_const name) { void *value; if (!coucal_read_pvoid(hashtable, name, &value)) { return NULL; } return value; } int coucal_write_pvoid(coucal hashtable, coucal_key_const name, void *pvalue) { coucal_value value = INTHASH_VALUE_NULL; value.ptr = pvalue; return coucal_write_value(hashtable, name, value); } void coucal_add_pvoid(coucal hashtable, coucal_key_const name, void *pvalue) { coucal_value value = INTHASH_VALUE_NULL; value.ptr = pvalue; coucal_write_value(hashtable, name, value); } int coucal_write(coucal hashtable, coucal_key_const name, intptr_t intvalue) { coucal_value value = INTHASH_VALUE_NULL; value.intg = intvalue; return coucal_write_value(hashtable, name, value); } static void coucal_default_free_handler(coucal_opaque arg, coucal_value value) { (void) arg; if (value.ptr != NULL) free(value.ptr); } static INTHASH_INLINE void coucal_del_value_(coucal hashtable, coucal_value *pvalue) { if (pvalue->ptr != NULL) { if (hashtable->custom.value.free != NULL) hashtable->custom.value.free(hashtable->custom.value.arg, *pvalue); pvalue->ptr = NULL; } } static INTHASH_INLINE void coucal_del_value(coucal hashtable, size_t pos) { coucal_del_value_(hashtable, &hashtable->items[pos].value); } static void coucal_del_name(coucal hashtable, coucal_item *item) { const coucal_hashkeys nullHash = INTHASH_KEYS_NULL; char *const name = (char*) item->name; item->name = NULL; /* there must be no reference remaining */ item->hashes = nullHash; /* free after detach (we may compact the pool) */ coucal_free_key(hashtable, name); } static void coucal_del_item(coucal hashtable, coucal_item *pitem) { coucal_del_value_(hashtable, &pitem->value); coucal_del_name(hashtable, pitem); } static int coucal_add_item_(coucal hashtable, coucal_item item); /* Write (add or replace) a value in the hashtable. */ static int coucal_write_value_(coucal hashtable, coucal_key_const name, coucal_value value) { coucal_item item; size_t pos; const coucal_hashkeys hashes = coucal_calc_hashes(hashtable, name); /* Statistics */ hashtable->stats.write_count++; /* replace at position 1 ? */ pos = coucal_hash_to_pos(hashtable, hashes.hash1); if (coucal_matches(hashtable, pos, name, &hashes)) { coucal_del_value(hashtable, pos); hashtable->items[pos].value = value; return 0; /* replaced */ } /* replace at position 2 ? */ pos = coucal_hash_to_pos(hashtable, hashes.hash2); if (coucal_matches(hashtable, pos, name, &hashes)) { coucal_del_value(hashtable, pos); hashtable->items[pos].value = value; return 0; /* replaced */ } /* replace in the stash ? */ if (hashtable->stash.size != 0) { size_t i; for(i = 0 ; i < hashtable->stash.size ; i++) { if (coucal_matches_(hashtable, &hashtable->stash.items[i], name, &hashes)) { coucal_del_value_(hashtable, &hashtable->stash.items[i].value); hashtable->stash.items[i].value = value; return 0; /* replaced */ } } } /* Statistics */ hashtable->stats.add_count++; /* otherwise we need to create a new item */ item.name = coucal_dup_name(hashtable, name); item.value = value; item.hashes = hashes; return coucal_add_item_(hashtable, item); } /* Return the string representation of a key */ static const char* coucal_print_key(coucal hashtable, coucal_key_const name) { return hashtable->custom.print.key != NULL ? hashtable->custom.print.key(hashtable->custom.print.arg, name) : (const char*) name; } /* Add a new item in the hashtable. The item SHALL NOT be already present. */ static int coucal_add_item_(coucal hashtable, coucal_item item) { coucal_hashkey cuckoo_hash, initial_cuckoo_hash; size_t loops; size_t pos; /* place at free position 1 ? */ pos = coucal_hash_to_pos(hashtable, item.hashes.hash1); if (coucal_is_free(hashtable, pos)) { hashtable->items[pos] = item; return 1; /* added */ } else { /* place at free position 2 ? */ pos = coucal_hash_to_pos(hashtable, item.hashes.hash2); if (coucal_is_free(hashtable, pos)) { hashtable->items[pos] = item; return 1; /* added */ } /* prepare cuckoo ; let's take position 1 */ else { cuckoo_hash = initial_cuckoo_hash = item.hashes.hash1; coucal_trace(hashtable, "debug:collision with '%s' at %"UINT_64_FORMAT" (%x)", coucal_print_key(hashtable, item.name), (uint64_t) pos, cuckoo_hash); } } /* put 'item' in place with hash 'cuckoo_hash' */ for(loops = POW2(hashtable->lg_size) ; loops != 0 ; --loops) { const size_t pos = coucal_hash_to_pos(hashtable, cuckoo_hash); coucal_trace(hashtable, "\tdebug:placing cuckoo '%s' at %"UINT_64_FORMAT" (%x)", coucal_print_key(hashtable, item.name), (uint64_t) pos, cuckoo_hash); /* place at alternate free position ? */ if (coucal_is_free(hashtable, pos)) { coucal_trace(hashtable, "debug:free position"); hashtable->items[pos] = item; return 1; /* added */ } /* then cuckoo's place it is */ else { /* replace */ const coucal_item backup_item = hashtable->items[pos]; hashtable->items[pos] = item; /* statistics */ hashtable->stats.cuckoo_moved++; /* take care of new lost item */ item = backup_item; /* we just kicked this item from its position 1 */ if (pos == coucal_hash_to_pos(hashtable, item.hashes.hash1)) { /* then place it on position 2 on next run */ coucal_trace(hashtable, "\tdebug:position 1"); cuckoo_hash = item.hashes.hash2; } /* we just kicked this item from its position 2 */ else if (pos == coucal_hash_to_pos(hashtable, item.hashes.hash2)) { /* then place it on position 1 on next run */ coucal_trace(hashtable, "\tdebug:position 2"); cuckoo_hash = item.hashes.hash1; } else { coucal_assert(hashtable, ! "hashtable internal error: unexpected position"); } /* we are looping (back to same hash) */ /* TODO FIXME: we should actually check the positions */ if (cuckoo_hash == initial_cuckoo_hash) { /* emergency stash */ break; } } } /* emergency stashing for the rare cases of collisions */ if (hashtable->stash.size < STASH_SIZE) { hashtable->stash.items[hashtable->stash.size] = item; hashtable->stash.size++; /* for statistics */ hashtable->stats.stash_added++; if (hashtable->stash.size > hashtable->stats.max_stash_size) { hashtable->stats.max_stash_size = hashtable->stash.size; } coucal_debug(hashtable, "used stash because of collision (%d entries)", (int) hashtable->stash.size); return 1; /* added */ } else { /* debugging */ if (hashtable->custom.print.key != NULL && hashtable->custom.print.value != NULL) { size_t i; for(i = 0 ; i < hashtable->stash.size ; i++) { coucal_item *const item = &hashtable->stash.items[i]; const size_t pos1 = coucal_hash_to_pos(hashtable, item->hashes.hash1); const size_t pos2 = coucal_hash_to_pos(hashtable, item->hashes.hash2); coucal_crit(hashtable, "stash[%u]: key='%s' value='%s' pos1=%d pos2=%d hash1=%04x hash2=%04x", (int) i, hashtable->custom.print.key(hashtable->custom.print.arg, item->name), hashtable->custom.print.value(hashtable->custom.print.arg, item->value), (int) pos1, (int) pos2, item->hashes.hash1, item->hashes.hash2); if (!coucal_is_free(hashtable, pos1)) { coucal_item *const item = &hashtable->items[pos1]; const size_t pos1 = coucal_hash_to_pos(hashtable, item->hashes.hash1); const size_t pos2 = coucal_hash_to_pos(hashtable, item->hashes.hash2); coucal_crit(hashtable, "\t.. collisionning with key='%s' value='%s' pos1=%d pos2=%d hash1=%04x hash2=%04x", hashtable->custom.print.key(hashtable->custom.print.arg, item->name), hashtable->custom.print.value(hashtable->custom.print.arg, item->value), (int) pos1, (int) pos2, item->hashes.hash1, item->hashes.hash2); } else { coucal_crit(hashtable, "\t.. collisionning with a free slot (%d)!", (int) pos1); } if (!coucal_is_free(hashtable, pos2)) { coucal_item *const item = &hashtable->items[pos2]; const size_t pos1 = coucal_hash_to_pos(hashtable, item->hashes.hash1); const size_t pos2 = coucal_hash_to_pos(hashtable, item->hashes.hash2); coucal_crit(hashtable, "\t.. collisionning with key='%s' value='%s' pos1=%d pos2=%d hash1=%04x hash2=%04x", hashtable->custom.print.key(hashtable->custom.print.arg, item->name), hashtable->custom.print.value(hashtable->custom.print.arg, item->value), (int) pos1, (int) pos2, item->hashes.hash1, item->hashes.hash2); } else { coucal_crit(hashtable, "\t.. collisionning with a free slot (%d)!", (int) pos2); } } } /* we are doomed. hopefully the probability is lower than being killed by a wandering radioactive monkey */ coucal_log_stats(hashtable); coucal_assert(hashtable, ! "hashtable internal error: cuckoo/stash collision"); /* not reachable code */ return -1; } } static INTHASH_INLINE int coucal_is_acceptable_pow2(size_t lg_size) { return lg_size <= COUCAL_HASH_SIZE && lg_size < sizeof(size_t)*8; } int coucal_write_value(coucal hashtable, coucal_key_const name, coucal_value_const value) { /* replace of add item */ const int ret = coucal_write_value_(hashtable, name, value); /* added ? */ if (ret) { /* size of half of the table */ const size_t half_size = POW2(hashtable->lg_size - 1); /* size of half of the stash */ const size_t half_stash_size = STASH_SIZE / 2; /* item was added: increase count */ hashtable->used++; /* table is more than half-full, or stash is more than half-full */ if (hashtable->used >= half_size || hashtable->stash.size >= half_stash_size) { size_t i; /* size before */ const size_t prev_power = hashtable->lg_size; const size_t prev_size = half_size * 2; const size_t prev_alloc_size = prev_size*sizeof(coucal_item); /* size after doubling it */ const size_t alloc_size = prev_alloc_size * 2; /* log stash issues */ if (hashtable->stash.size >= half_stash_size && half_size > POW2(16) && hashtable->used < half_size / 4) { coucal_warning(hashtable, "stash size still full despite %"UINT_64_FORMAT " elements used out of %"UINT_64_FORMAT, (uint64_t) hashtable->used, (uint64_t) half_size*2); } /* statistics */ hashtable->stats.rehash_count++; /* realloc */ hashtable->lg_size++; coucal_assert(hashtable, coucal_is_acceptable_pow2(hashtable->lg_size)); hashtable->items = (coucal_item *) realloc(hashtable->items, alloc_size); if (hashtable->items == NULL) { coucal_crit(hashtable, "** hashtable allocation error: " "could not allocate %"UINT_64_FORMAT" bytes", (uint64_t) alloc_size); coucal_assert(hashtable, ! "hashtable allocation error"); } /* clear upper half */ memset(&hashtable->items[prev_size], 0, prev_alloc_size); /* relocate lower half items when needed */ for(i = 0 ; i < prev_size ; i++) { if (!coucal_is_free(hashtable, i)) { const coucal_hashkeys *const hashes = &hashtable->items[i].hashes; /* currently at old position 1 */ if (coucal_hash_to_pos_(prev_power, hashes->hash1) == i) { const size_t pos = coucal_hash_to_pos(hashtable, hashes->hash1); /* no more the expected position */ if (pos != i) { coucal_assert(hashtable, pos >= prev_size); hashtable->items[pos] = hashtable->items[i]; memset(&hashtable->items[i], 0, sizeof(hashtable->items[i])); } } else if (coucal_hash_to_pos_(prev_power, hashes->hash2) == i) { const size_t pos = coucal_hash_to_pos(hashtable, hashes->hash2); /* no more the expected position */ if (pos != i) { coucal_assert(hashtable, pos >= prev_size); hashtable->items[pos] = hashtable->items[i]; memset(&hashtable->items[i], 0, sizeof(hashtable->items[i])); } } else { coucal_assert(hashtable, ! "hashtable unexpected internal error (bad position)"); } } } coucal_debug(hashtable, "expanded hashtable to %"UINT_64_FORMAT" elements", (uint64_t) POW2(hashtable->lg_size)); /* attempt to merge the stash if present */ if (hashtable->stash.size != 0) { const size_t old_size = hashtable->stash.size; size_t i; /* backup stash and reset it */ coucal_item stash[STASH_SIZE]; memcpy(&stash, hashtable->stash.items, sizeof(hashtable->stash.items)); hashtable->stash.size = 0; /* insert all items */ for(i = 0 ; i < old_size ; i++) { const int ret = coucal_add_item_(hashtable, stash[i]); if (ret == 0) { coucal_assert(hashtable, ! "hashtable duplicate key when merging the stash"); } } /* logging */ coucal_assert(hashtable, hashtable->stash.size <= old_size); if (hashtable->stash.size < old_size) { coucal_debug(hashtable, "reduced stash size from %"UINT_64_FORMAT" " "to %"UINT_64_FORMAT, (uint64_t) old_size, (uint64_t) hashtable->stash.size); } else { coucal_trace(hashtable, "stash has still %"UINT_64_FORMAT" elements", (uint64_t) hashtable->stash.size); } } } } return ret; } void coucal_add(coucal hashtable, coucal_key_const name, intptr_t intvalue) { coucal_value value = INTHASH_VALUE_NULL; memset(&value, 0, sizeof(value)); value.intg = intvalue; coucal_write_value(hashtable, name, value); } int coucal_read(coucal hashtable, coucal_key_const name, intptr_t * intvalue) { coucal_value value = INTHASH_VALUE_NULL; int ret = coucal_read_value(hashtable, name, (intvalue != NULL) ? &value : NULL); if (intvalue != NULL) *intvalue = value.intg; return ret; } coucal_value* coucal_fetch_value_hashes(coucal hashtable, coucal_key_const name, const coucal_hashkeys *hashes) { size_t pos; /* found at position 1 ? */ pos = coucal_hash_to_pos(hashtable, hashes->hash1); if (coucal_matches(hashtable, pos, name, hashes)) { return &hashtable->items[pos].value; } /* found at position 2 ? */ pos = coucal_hash_to_pos(hashtable, hashes->hash2); if (coucal_matches(hashtable, pos, name, hashes)) { return &hashtable->items[pos].value; } /* find in stash ? */ if (hashtable->stash.size != 0) { size_t i; for(i = 0 ; i < hashtable->stash.size ; i++) { if (coucal_matches_(hashtable, &hashtable->stash.items[i], name, hashes)) { return &hashtable->stash.items[i].value; } } } /* not found */ return NULL; } INTHASH_INLINE coucal_value* coucal_fetch_value(coucal hashtable, coucal_key_const name) { const coucal_hashkeys hashes = coucal_calc_hashes(hashtable, name); return coucal_fetch_value_hashes(hashtable, name, &hashes); } int coucal_read_value(coucal hashtable, coucal_key_const name, coucal_value * pvalue) { coucal_value* const value = coucal_fetch_value(hashtable, name); if (value != NULL) { if (pvalue != NULL) { *pvalue = *value; } return 1; } return 0; } static size_t coucal_inc_(coucal hashtable, coucal_key_const name, size_t inc) { coucal_value* const value = coucal_fetch_value(hashtable, name); if (value != NULL) { value->uintg += inc; return value->uintg; } else { /* create a new value */ const int ret = coucal_write(hashtable, name, inc); coucal_assert(hashtable, ret); return inc; } } int coucal_inc(coucal hashtable, coucal_key_const name) { return (int) coucal_inc_(hashtable, name, 1); } int coucal_dec(coucal hashtable, coucal_key_const name) { return (int) coucal_inc_(hashtable, name, (size_t) -1); } int coucal_exists(coucal hashtable, coucal_key_const name) { return coucal_read_value(hashtable, name, NULL); } static int coucal_remove_(coucal hashtable, coucal_key_const name, const coucal_hashkeys *hashes, size_t *removed) { size_t pos; /* found at position 1 ? */ pos = coucal_hash_to_pos(hashtable, hashes->hash1); if (coucal_matches(hashtable, pos, name, hashes)) { coucal_del_item(hashtable, &hashtable->items[pos]); *removed = pos; return 1; } /* found at position 2 ? */ pos = coucal_hash_to_pos(hashtable, hashes->hash2); if (coucal_matches(hashtable, pos, name, hashes)) { coucal_del_item(hashtable, &hashtable->items[pos]); *removed = pos; return 1; } /* find in stash ? */ if (hashtable->stash.size != 0) { size_t i; for(i = 0 ; i < hashtable->stash.size ; i++) { if (coucal_matches_(hashtable, &hashtable->stash.items[i], name, hashes)) { coucal_del_item(hashtable, &hashtable->stash.items[i]); for( ; i + 1 < hashtable->stash.size ; i++) { hashtable->stash.items[i] = hashtable->stash.items[i + 1]; } hashtable->stash.size--; *removed = (size_t) -1; coucal_debug(hashtable, "debug:deleted item in stash (%d entries)", (int) hashtable->stash.size); return 1; } } } /* not found */ return 0; } int coucal_remove(coucal hashtable, coucal_key_const name) { const coucal_hashkeys hashes = coucal_calc_hashes(hashtable, name); size_t removed; const int ret = coucal_remove_(hashtable, name, &hashes, &removed); if (ret) { /* item was removed: decrease count */ coucal_assert(hashtable, hashtable->used != 0); hashtable->used--; /* can we place stash entry back to the table ? */ if (hashtable->stash.size != 0 && removed != (size_t) -1) { size_t i; for(i = 0 ; i < hashtable->stash.size ; i++) { const size_t pos1 = coucal_hash_to_pos(hashtable, hashtable->stash.items[i].hashes.hash1); const size_t pos2 = coucal_hash_to_pos(hashtable, hashtable->stash.items[i].hashes.hash2); if (pos1 == removed || pos2 == removed) { if (pos1 == removed) { hashtable->items[pos1] = hashtable->stash.items[i]; } else if (pos2 == removed) { hashtable->items[pos2] = hashtable->stash.items[i]; } for( ; i + 1 < hashtable->stash.size ; i++) { hashtable->stash.items[i] = hashtable->stash.items[i + 1]; } hashtable->stash.size--; coucal_debug(hashtable, "debug:moved item from stash (%d entries)", (int) hashtable->stash.size); break; } } } } return ret; } int coucal_readptr(coucal hashtable, coucal_key_const name, intptr_t * value) { int ret; *value = 0; ret = coucal_read(hashtable, name, value); if (*value == 0) ret = 0; return ret; } intptr_t coucal_get_intptr(coucal hashtable, coucal_key_const name) { intptr_t value; if (!coucal_read(hashtable, name, &value)) { return 0; } return value; } static INTHASH_INLINE size_t coucal_get_pow2(size_t initial_size) { size_t size; for(size = MIN_LG_SIZE ; size <= COUCAL_HASH_SIZE && POW2(size) < initial_size ; size++) ; return size; } coucal coucal_new(size_t initial_size) { const size_t lg_size = coucal_get_pow2(initial_size); const int lg_valid = coucal_is_acceptable_pow2(lg_size); coucal hashtable = lg_valid ? (coucal) calloc(1, sizeof(struct_coucal)) : NULL; coucal_item *const items = (coucal_item *) calloc(POW2(lg_size), sizeof(coucal_item)); if (lg_valid && items != NULL && hashtable != NULL) { hashtable->lg_size = lg_size; hashtable->items = items; hashtable->used = 0; hashtable->stash.size = 0; hashtable->pool.buffer = NULL; hashtable->pool.size = 0; hashtable->pool.capacity = 0; hashtable->pool.used = 0; hashtable->stats.max_stash_size = 0; hashtable->stats.write_count = 0; hashtable->stats.add_count = 0; hashtable->stats.cuckoo_moved = 0; hashtable->stats.stash_added= 0; hashtable->stats.pool_compact_count = 0; hashtable->stats.pool_realloc_count = 0; hashtable->stats.rehash_count = 0; hashtable->custom.value.free = NULL; hashtable->custom.value.arg = NULL; hashtable->custom.key.dup = NULL; hashtable->custom.key.free = NULL; hashtable->custom.key.hash = NULL; hashtable->custom.key.equals = NULL; hashtable->custom.key.arg = NULL; hashtable->custom.error.log = NULL; hashtable->custom.error.fatal = NULL; hashtable->custom.error.name = NULL; hashtable->custom.error.arg = NULL; hashtable->custom.print.key = NULL; hashtable->custom.print.value = NULL; hashtable->custom.print.arg = NULL; return hashtable; } if (items != NULL) { free(items); } if (hashtable != NULL) { free(hashtable); } return NULL; } int coucal_created(coucal hashtable) { return hashtable != NULL && hashtable->items != NULL; } void coucal_value_is_malloc(coucal hashtable, int flag) { if (flag) { if (hashtable->custom.value.free == NULL) { hashtable->custom.value.free = coucal_default_free_handler; hashtable->custom.value.arg = NULL; } } else { hashtable->custom.value.free = NULL; hashtable->custom.value.arg = NULL; } } void coucal_set_name(coucal hashtable, coucal_key_const name) { hashtable->custom.error.name = name; } void coucal_value_set_value_handler(coucal hashtable, t_coucal_value_freehandler free, coucal_opaque arg) { hashtable->custom.value.free = free; hashtable->custom.value.arg = arg; } void coucal_value_set_key_handler(coucal hashtable, t_coucal_duphandler dup, t_coucal_key_freehandler free, t_coucal_hasheshandler hash, t_coucal_cmphandler equals, coucal_opaque arg) { /* dup and free must be consistent */ coucal_assert(hashtable, ( dup == NULL ) == ( free == NULL ) ); hashtable->custom.key.dup = dup; hashtable->custom.key.free = free; hashtable->custom.key.hash = hash; hashtable->custom.key.equals = equals; hashtable->custom.key.arg = arg; } void coucal_set_assert_handler(coucal hashtable, t_coucal_loghandler log, t_coucal_asserthandler fatal, coucal_opaque arg) { hashtable->custom.error.log = log; hashtable->custom.error.fatal = fatal; hashtable->custom.error.arg = arg; } void coucal_set_print_handler(coucal hashtable, t_coucal_printkeyhandler key, t_coucal_printvaluehandler value, coucal_opaque arg) { hashtable->custom.print.key = key; hashtable->custom.print.value = value; hashtable->custom.print.arg = arg; } size_t coucal_nitems(coucal hashtable) { if (hashtable != NULL) return hashtable->used; return 0; } size_t coucal_memory_size(coucal hashtable) { const size_t size_struct = sizeof(struct_coucal); const size_t hash_size = POW2(hashtable->lg_size)*sizeof(coucal_item); const size_t pool_size = hashtable->pool.capacity*sizeof(char); return size_struct + hash_size + pool_size; } size_t coucal_hash_size(void) { return COUCAL_HASH_SIZE; } void coucal_delete(coucal *phashtable) { if (phashtable != NULL) { coucal hashtable = *phashtable; if (hashtable != NULL) { coucal_log_stats(hashtable); if (hashtable->items != NULL) { /* we need to delete values */ const size_t hash_size = POW2(hashtable->lg_size); size_t i; /* wipe hashtable values (not names) */ for(i = 0 ; i < hash_size ; i++) { if (!coucal_is_free(hashtable, i)) { coucal_del_value(hashtable, i); } } /* wipe auxiliary stash values (not names) if any */ for(i = 0 ; i < hashtable->stash.size ; i++) { coucal_del_value_(hashtable, &hashtable->stash.items[i].value); } } /* wipe top-level */ hashtable->lg_size = 0; hashtable->used = 0; free(hashtable->pool.buffer); hashtable->pool.buffer = NULL; free(hashtable->items); hashtable->items = NULL; free(hashtable); *phashtable = NULL; } } } /* Enumerator */ struct_coucal_enum coucal_enum_new(coucal hashtable) { struct_coucal_enum e; e.index = 0; e.table = hashtable; return e; } coucal_item *coucal_enum_next(struct_coucal_enum * e) { const size_t hash_size = POW2(e->table->lg_size); for( ; e->index < hash_size && coucal_is_free(e->table, e->index) ; e->index++) ; /* enumerate all table */ if (e->index < hash_size) { coucal_item *const next = &e->table->items[e->index]; e->index++; return next; } /* enumerate stash if present */ else if (e->index < hash_size + e->table->stash.size) { const size_t index = e->index - hash_size; coucal_item *const next = &e->table->stash.items[index]; e->index++; return next; } /* eof */ else { return NULL; } } void coucal_set_global_assert_handler(t_coucal_loghandler log, t_coucal_asserthandler fatal) { global_log_handler = log; global_assert_handler = fatal; } httrack-3.49.5/README.md0000644000175000017500000000213314336470674011471 00000000000000# HTTrack Website Copier - Development Repository ## About _Copy websites to your computer (Offline browser)_ *HTTrack* is an _offline browser_ utility, allowing you to download a World Wide website from the Internet to a local directory, building recursively all directories, getting html, images, and other files from the server to your computer. *HTTrack* arranges the original site's relative link-structure. Simply open a page of the "mirrored" website in your browser, and you can browse the site from link to link, as if you were viewing it online. HTTrack can also update an existing mirrored site, and resume interrupted downloads. HTTrack is fully configurable, and has an integrated help system. *WinHTTrack* is the Windows 2000/XP/Vista/Seven release of HTTrack, and *WebHTTrack* the Linux/Unix/BSD release. ## Website *Main Website:* http://www.httrack.com/ ## Compile trunk release ```sh git clone https://github.com/xroche/httrack.git --recurse cd httrack ./configure --prefix=$HOME/usr && make -j8 && make install ``` httrack-3.49.5/lang.def0000755000175000017500000005444714360553245011626 00000000000000English LANGUAGE_1 Francais LANGUAGE_2 Castellano LANGUAGE_3 Deutsch LANGUAGE_4 Nederlands LANGUAGE_5 Polski LANGUAGE_6 Portugues LANGUAGE_7 Russian LANGUAGE_8 Italiano LANGUAGE_9 Turkish LANGUAGE_10 Magyar LANGUAGE_11 Portugues-Brasil LANGUAGE_12 Chinese-Simplified LANGUAGE_13 Chinese-BIG5 LANGUAGE_14 Dansk LANGUAGE_15 Eesti LANGUAGE_16 Svenska LANGUAGE_17 Macedonian LANGUAGE_18 Japanese LANGUAGE_19 Slovak LANGUAGE_20 Cesky LANGUAGE_21 Ukrainian LANGUAGE_22 Norsk LANGUAGE_23 Slovenian LANGUAGE_24 Romanian LANGUAGE_25 Greek LANGUAGE_26 Bulgarian LANGUAGE_27 Finnish LANGUAGE_28 Croatian LANGUAGE_29 Uzbek LANGUAGE_30 LANGUAGE_NAME LANGUAGE_NAME LANGUAGE_FILE LANGUAGE_FILE LANGUAGE_ISO LANGUAGE_ISO LANGUAGE_AUTHOR LANGUAGE_AUTHOR LANGUAGE_CHARSET LANGUAGE_CHARSET LANGUAGE_WINDOWSID LANGUAGE_WINDOWSID LANG_OK OK LANG_CANCEL Cancel LANG_QUIT Exit LANG_CLOSE Close LANG_TIPCANCEL Cancel changes LANG_TIPOK Click to confirm LANG_TIPHELP Click to get help! LANG_TIPPREV Click to return to previous screen LANG_TIPNEXT Click to go to next screen LANG_HIDEPWD Hide password LANG_SAVEPROJECT Save project LANG_CLOSEPRJ Close current project? LANG_DELETECONF Delete this project? LANG_DELETEEMPTYCONF Delete empty project %s? LANG_ACTIONNYP Action not yet implemented LANG_ERRORDEL Error deleting this project LANG_B1 Select a rule for the filter LANG_B2 Enter keywords for the filter LANG_B3 Cancel LANG_B4 Add this rule LANG_A2 Please enter one or several keyword(s) for the rule LANG_B5 Add Scan Rule LANG_B6 Criterion LANG_B7 String LANG_B8 Add LANG_B9 Scan Rules LANG_B10 Use wildcards to exclude or include URLs or links.\nYou can put several scan strings on the same line.\nUse spaces as separators.\n\nExample: +*.zip -www.*.com -www.*.edu/cgi-bin/*.cgi LANG_B11 Exclude links LANG_B12 Include link(s) LANG_B13 Tip: To have ALL GIF files included, use something like +www.someweb.com/*.gif. \n(+*.gif / -*.gif will include/exclude ALL GIFs from ALL sites) LANG_B14 Save prefs LANG_B20 Matching links will be excluded: LANG_B21 Matching links will be included: LANG_B22 Example: LANG_B23 gif\r\nWill match all GIF files LANG_B24 blue\r\nWill find all files with a matching 'blue' sub-string such as 'bluesky-small.jpeg' LANG_B25 bigfile.mov\r\nWill match the file 'bigfile.mov', but not 'bigfile2.mov' LANG_B26 cgi\r\nWill find links with folder name matching sub-string 'cgi' such as /cgi-bin/somecgi.cgi LANG_B27 cgi-bin\r\nWill find links with folder name matching whole 'cgi-bin' string (but not cgi-bin-2, for example) LANG_B28 someweb.com\r\nWill find links with matching sub-string such as www.someweb.com, private.someweb.com etc. LANG_B29 someweb\r\nWill find links with matching folder sub-string such as www.someweb.com, www.someweb.edu, private.someweb.otherweb.com etc. LANG_B30 www.someweb.com\r\nWill find links matching whole 'www.someweb.com' sub-string (but not links such as private.someweb.com/..) LANG_B31 someweb\r\nWill find any links with matching sub-string such as www.someweb.com/.., www.test.abc/fromsomeweb/index.html, www.test.abc/test/someweb.html etc. LANG_B32 www.test.com/test/someweb.html\r\nWill only find the 'www.test.com/test/someweb.html' file. Note that you have to type the complete path (URL + site path) LANG_B33 All links will match LANG_C1 Add exclusion filter LANG_C2 Add inclusion filter LANG_C3 Existing filters LANG_C4 Cancel changes LANG_C5 Save current preferences as default values LANG_C6 Click to confirm LANG_D1 No log files in %s! LANG_D2 No 'index.html' file in %s! LANG_D3 Click to quit WinHTTrack Website Copier LANG_D4 View log files LANG_D5 Browse HTML start page LANG_D6 End of mirror LANG_D7 View log files LANG_D8 Browse Mirrored Website LANG_D9 New project... LANG_E1 View error and warning reports LANG_E2 View report LANG_E3 Close the log file window LANG_E4 Info type: LANG_E5 Errors LANG_E6 Infos LANG_E7 Find LANG_E8 Find a word LANG_E10 Info log file LANG_E11 Warning/Errors log file LANG_F1 Unable to initialize the OLE system LANG_F2 WinHTTrack could not find any interrupted download file cache in the specified folder! LANG_F3 Could not connect to provider LANG_F4 receive LANG_F5 request LANG_F6 connect LANG_F7 search LANG_F8 ready LANG_F9 error LANG_F10 Receiving files.. LANG_F11 Parsing HTML file.. LANG_F11b Purging files.. LANG_F11c Loading cache in progress.. LANG_F12 Parsing HTML file (testing links).. LANG_F13 Pause - Toggle [Mirror]/[Pause download] to resume operation LANG_F13b Finishing pending transfers - Select [Cancel] to stop now! LANG_F14 scanning LANG_F15 Waiting for scheduled time.. LANG_F15b Transferring data.. LANG_F16 Connecting to provider LANG_F17 [%d seconds] to go before start of operation LANG_F18 Site mirroring in progress [%s, %s bytes] LANG_F18b Site mirroring finished! LANG_F19 A problem occurred during the mirroring operation\n LANG_F20 \nDuring:\n LANG_F21 \nSee the log file if necessary.\n\nClick FINISH to quit WinHTTrack Website Copier.\n\nThanks for using WinHTTrack! LANG_F22 Mirroring operation complete.\nClick Exit to quit WinHTTrack.\nSee log file(s) if necessary to ensure that everything is OK.\n\nThanks for using WinHTTrack! LANG_F22b * * MIRROR ABORTED! * *\r\nThe current temporary cache is required for any update operation and only contains data downloaded during the present aborted session.\r\nThe former cache might contain more complete information; if you do not want to lose that information, you have to restore it and delete the current cache.\r\n[Note: This can easily be done here by erasing the hts-cache/new.* files]\r\n\r\nDo you think the former cache might contain more complete information, and do you want to restore it? LANG_F22c * * MIRROR ERROR! * *\r\nHTTrack has detected that the current mirror is empty. If it was an update, the previous mirror has been restored.\r\nReason: the first page(s) either could not be found, or a connection problem occurred.\r\n=> Ensure that the website still exists, and/or check your proxy settings! <= LANG_F23 \n\nTip: Click [View log file] to see warning or error messages LANG_F24 Error deleting a hts-cache/new.* file, please do it manually LANG_G1 Do you really want to quit WinHTTrack Website Copier? LANG_G2 - Mirroring Mode -\n\nEnter address(es) in URL box LANG_G3 - Interactive Wizard Mode (questions) -\n\nEnter address(es) in URL box LANG_G4 - File Download Mode -\n\nEnter file address(es) in URL box LANG_G5 - Link Testing Mode -\n\nEnter Web address(es) with links to test in URL box LANG_G6 - Update Mode -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button LANG_G6b - Resume Mode (Interrupted Operation) -\n\nVerify address(es) in URL box, check parameters if necessary then click on 'NEXT' button LANG_G7 Log files Path LANG_G8 Path LANG_G1B - Links List Mode -\n\nUse URL box to enter address(es) of page(s) containing links to mirror LANG_G1C New project / Import? LANG_G9 Choose criterion LANG_G10 Maximum link scanning depth LANG_G11 Enter address(es) here LANG_G13 Define additional filtering rules LANG_G14 Proxy Name (if needed) LANG_G15 Proxy Port LANG_G15b Define proxy settings LANG_G15c Use standard HTTP proxy as FTP proxy LANG_G16 Path LANG_G17 Select Path LANG_G18 Path LANG_G19 Select Path LANG_G20 Quit WinHTTrack Website Copier LANG_G21 About WinHTTrack LANG_G22 Save current preferences as default values LANG_G23 Click to continue LANG_G24 Click to define options LANG_G24b Click to add a URL LANG_G24c Load URL(s) from text file LANG_G25 WinHTTrack preferences (*.opt)|*.opt|| LANG_G25b Address List text file (*.txt)|*.txt|| LANG_G26 File not found! LANG_G26b Do you really want to change the project name/path? LANG_G27 Load user-default options? LANG_G28 Save user-default options? LANG_G29 Reset all default options? LANG_G30 Welcome to WinHTTrack! LANG_G31 Action: LANG_G32 Max Depth LANG_G32b Maximum external depth: LANG_G33 Filters (refuse/accept links) : LANG_G34 Paths LANG_G37 Save prefs LANG_G39 Define.. LANG_G40 Set options.. LANG_G41 Preferences and mirror options: LANG_G42 Project name LANG_G43 Add a URL... LANG_G44 Web Addresses: (URL) LANG_H1 Stop WinHTTrack? LANG_H2 No log files in %s! LANG_H3 Pause Download? LANG_H4 Stop the mirroring operation LANG_H5 Minimize to System Tray LANG_H6 Click to skip a link or stop parsing LANG_H7 Click to skip a link LANG_H8 Bytes saved LANG_H9 Links scanned LANG_H10 Time: LANG_H11 Connections: LANG_H12 Running: LANG_H13 Hide LANG_H14 Transfer rate LANG_H15 SKIP LANG_H16 Information LANG_H17 Files written: LANG_H18 Files updated: LANG_H19 Errors: LANG_H20 In progress: LANG_I1 Follow external links LANG_I2 Test all links in pages LANG_I2b Try to ferret out all links LANG_I2c Download HTML files first (faster) LANG_I3 Choose local site structure LANG_I4 Set user-defined structure on disk LANG_I5 Use a cache for updates and retries LANG_I5b Do not update zero size or user-erased files LANG_I6 Create a Start Page LANG_I6b Create a word database of all html pages LANG_I6c Build a complete RFC822 mail (MHT/EML) archive of the mirror LANG_I7 Create error logging and report files LANG_I8 Generate DOS 8-3 filenames ONLY LANG_I8b Generate ISO9660 filenames ONLY for CDROM medias LANG_I9 Do not create HTML error pages LANG_I10 Select file types to be saved to disk LANG_I11 Select parsing direction LANG_I11b Select global parsing direction LANG_I11c Setup URL rewriting rules for internal links (downloaded ones) and external links (not downloaded ones) LANG_I12 Max simultaneous connections LANG_I13 File timeout LANG_I14 Cancel all links from host if timeout occurs LANG_I15 Minimum admissible transfer rate LANG_I16 Cancel all links from host if too slow LANG_I17 Maximum number of retries on non-fatal errors LANG_I18 Maximum size for any single HTML file LANG_I19 Maximum size for any single non-HTML file LANG_I20 Maximum amount of bytes to retrieve from the Web LANG_I20b Make a pause after downloading this amount of bytes LANG_I21 Maximum duration time for the mirroring operation LANG_I22 Maximum transfer rate LANG_I22b Maximum connections/seconds (avoid server overload) LANG_I22c Maximum number of links that can be tested (not saved!) LANG_I23 Browser identity LANG_I23b Comment to be placed in each HTML file LANG_I23c Languages accepted by the browser LANG_I23d Additional HTTP headers to be sent in each requests LANG_I23e HTTP referer to be sent for initial URLs LANG_I24 Back to starting page LANG_I25 Save current preferences as default values LANG_I26 Click to continue LANG_I27 Click to cancel changes LANG_I28 Follow local robots rules on sites LANG_I29 Links to non-localised external pages will produce error pages LANG_I1a Do not erase obsolete files after update LANG_I1b Accept cookies? LANG_I1c Check document type when unknown? LANG_I1d Parse java applets to retrieve included files that must be downloaded? LANG_I1e Store all files in cache instead of HTML only LANG_I1f Log file type (if generated) LANG_I1g Maximum mirroring depth from root address LANG_I1g2 Maximum mirroring depth for external/forbidden addresses (0, that is, none, is the default) LANG_I1h Create a debugging file LANG_I1i Use non-standard requests to get round some server bugs LANG_I1j Use old HTTP/1.0 requests (limits engine power!) LANG_I1k Attempt to limit retransfers through several tricks (file size test..) LANG_I1k2 Attempt to limit the number of links by skipping similar URLs (www.foo.com==foo.com, http=https ..) LANG_I30 Write external links without login/password LANG_I30b Write internal links without query string LANG_I31 Get non-HTML files related to a link, eg external .ZIP or pictures LANG_I32 Test all links (even forbidden ones) LANG_I32b Try to catch all URLs (even in unknown tags/code) LANG_I32c Get HTML files first! LANG_I33 Structure type (how links are saved) LANG_I34 Use a cache for updates LANG_I34b Do not re-download locally erased files LANG_I35 Make an index LANG_I35b Make a word database LANG_I35c Build a mail archive LANG_I36 Log files LANG_I37 DOS names (8+3) LANG_I37b ISO9660 names (CDROM) LANG_I38 No error pages LANG_I39 Primary Scan Rule LANG_I40 Travel mode LANG_I40b Global travel mode LANG_I40c These options should be modified only exceptionally LANG_I40d Activate Debugging Mode (winhttrack.log) LANG_I40e Rewrite links: internal / external LANG_I41 Flow control LANG_I42 Limits LANG_I43 Identity LANG_I43b HTML footer LANG_I43c Languages LANG_I43d Additional HTTP Headers LANG_I43e Default referer URL LANG_I44 N# connections LANG_I45 Abandon host if error LANG_I46 Minimum transfer rate (B/s) LANG_I47 Abandon host if too slow LANG_I47b Configure LANG_I47c Use proxy for ftp transfers LANG_I47d TimeOut(s) LANG_I47e Persistent connections (Keep-Alive) LANG_I47f Reduce connection time and type lookup time using persistent connections LANG_I48 Retries LANG_I49 Size limit LANG_I50 Max size of any HTML file (B) LANG_I50b Max size of any non-HTML file LANG_I51 Max site size LANG_I52 Max time LANG_I53 Save prefs LANG_I54 Max transfer rate LANG_I55 Follow robots.txt LANG_I56 No external pages LANG_I57 Do not purge old files LANG_I58 Accept cookies LANG_I59 Check document type LANG_I60 Parse java files LANG_I61 Store ALL files in cache LANG_I62 Tolerant requests (for servers) LANG_I62b Update hack (limit re-transfers) LANG_I62b2 URL hacks (join similar URLs) LANG_I63 Force old HTTP/1.0 requests (no 1.1) LANG_I64 Max connections / seconds LANG_I64b Maximum number of links LANG_I65 Pause after downloading.. LANG_I66 Hide passwords LANG_I67 Hide query strings LANG_IOPT1 Links LANG_IOPT2 Build LANG_IOPT3 Experts Only LANG_IOPT4 Flow Control LANG_IOPT5 Limits LANG_IOPT6 Browser ID LANG_IOPT7 Scan Rules LANG_IOPT8 Spider LANG_IOPT9 Log, Index, Cache LANG_IOPT10 Proxy LANG_IOPT11 MIME Types LANG_J1 Do you really want to quit WinHTTrack Website Copier? LANG_J2 Do not connect to a provider (already connected) LANG_J2b Do not use remote access connection LANG_J3 Schedule the mirroring operation LANG_J4 Quit WinHTTrack Website Copier LANG_J5 Back to starting page LANG_J6 Click to start! LANG_J7 No saved password for this connection! LANG_J8 Can not get remote connection settings LANG_J8b Select a connection provider LANG_J9 Start LANG_J10 Please adjust connection parameters if necessary,\nthen press FINISH to launch the mirroring operation. LANG_J10b Save settings only, do not launch download now. LANG_J11 On hold LANG_J12 Transfer scheduled for: (hh/mm/ss) LANG_J13 Start LANG_J14 Connect to provider (RAS) LANG_J15 Connect to this provider LANG_J16 Disconnect when finished LANG_J17 Disconnect modem on completion LANG_K1 \r\n(Please notify us of any bug or problem)\r\n\r\nDevelopment:\r\nInterface (Windows): Xavier Roche\r\nSpider: Xavier Roche\r\nJavaParserClasses: Yann Philippot\r\n\r\n(C)1998-2003 Xavier Roche and other contributors\r\nMANY THANKS for translation tips to:\r\nRobert Lagadec (rlagadec@yahoo.fr) LANG_K2 About WinHTTrack Website Copier LANG_K3 Please visit our Web page LANG_L1 Wizard query LANG_L2 Your answer: LANG_M1 Link detected.. LANG_M2 Choose a rule LANG_M3 Ignore this link LANG_M4 Ignore directory LANG_M5 Ignore domain LANG_M6 Catch this page only LANG_M7 Mirror site LANG_M8 Mirror domain LANG_M9 Ignore all LANG_N1 Wizard query LANG_N2 NO LANG_O1 File LANG_O2 Options LANG_O3 Log LANG_O4 Window LANG_O5 Help LANG_O10 Pause transfer LANG_O11 Exit LANG_O12 Modify options LANG_O13 View log LANG_O14 View error log LANG_O14b View file transfers LANG_O15 Hide LANG_O16 About WinHTTrack Website Copier LANG_O17 Check program updates... LANG_O18 &Toolbar LANG_O19 &Status Bar LANG_O20 S&plit LANG_P1 File LANG_P2 Preferences LANG_P3 Mirror LANG_P4 Log LANG_P5 Window LANG_P6 Help LANG_P10 Exit LANG_P11 Load default options LANG_P12 Save default options LANG_P12b Reset to default options LANG_P13 Load options... LANG_P14 Save options as... LANG_P15 Language preference... LANG_P16 Contents... LANG_P17 About WinHTTrack... LANG_P18 New project\tCtrl+N LANG_P19 &Open...\tCtrl+O LANG_P20 &Save\tCtrl+S LANG_P21 Save &As... LANG_P22 &Delete... LANG_P23 &Browse sites... LANG_Q1 User-defined structure LANG_Q2 %n\tName of file without file type (ex: image)\r\n%N\tName of file including file type (ex: image.gif)\r\n%t\tFile type only (ex: gif)\r\n%p\tPath [without ending /] (ex: /someimages)\r\n%h\tHost name (ex: www.someweb.com)\r\n%M\tMD5 URL (128 bits, 32 ascii bytes)\r\n%Q\tMD5 query string (128 bits, 32 ascii bytes)\r\n%q\tMD5 small query string (16 bits, 4 ascii bytes)\r\n\r\n%s?\tShort name (ex: %sN) LANG_Q3 Example:\t%h%p/%n%q.%t\n->\t\tc:\\mirror\\www.someweb.com\\someimages\\image.gif LANG_R1 Proxy settings LANG_R2 Proxy address: LANG_R3 Proxy port: LANG_R4 Authentication (only if needed) LANG_R5 Login LANG_R6 Password LANG_R10 Enter proxy address here LANG_R11 Enter proxy port here LANG_R12 Enter proxy login LANG_R13 Enter proxy password LANG_S1 Enter project name here LANG_S2 Enter saving path here LANG_S3 Select existing project to update LANG_S4 Click here to select path LANG_S5 Select or create a new category name, to sort your mirrors in categories LANG_S10 HTTrack Project Wizard... LANG_S11 New project name: LANG_S11b Existing project name: LANG_S11c Project name: LANG_S12 Base path: LANG_S13 Project category: LANG_S20 C:\\My Web Sites LANG_S30 Type a new project name, \r\nor select existing project to update/resume LANG_S31 New project LANG_T1 Insert URL LANG_T2 URL: LANG_T4 Authentication (only if needed) LANG_T5 Login LANG_T6 Password LANG_T7 Forms or complex links: LANG_T8 Capture URL... LANG_T10 Enter URL address(es) here LANG_T12 Enter site login LANG_T13 Enter site password LANG_T14 Use this capture tool for links that can only be accessed through forms or javascript code LANG_U1 Choose language according to preference LANG_V1 Catch URL! LANG_V2 Please set temporary browser proxy settings to the following values (Copy/Paste Proxy Address and Port).\nThen click on the Form SUBMIT button in your browser page, or click on the specific link you want to capture. LANG_V3 This will send the desired link from your browser to WinHTTrack. LANG_V4 ABORT LANG_V10 Copy/Paste the temporary proxy parameters here LANG_V11 Cancel LANG_DIAL1 Unable to find Help files! LANG_DIAL2 Unable to save parameters! LANG_DIAL3 Please drag only one folder at a time LANG_DIAL4 Please drag only folders, not files LANG_DIAL5 Please drag folders only LANG_DIAL6 Select user-defined structure? LANG_DIAL7 Please ensure that the user-defined-string is correct,\notherwise filenames will be bogus! LANG_DIAL8 Do you really want to use a user-defined structure? LANG_DIAL9 Too manu URLs, cannot handle so many links!! LANG_DIAL10 Not enough memory, fatal internal error.. LANG_DIAL11 Unknown operation! LANG_DIAL12 Add this URL?\r\n LANG_DIAL13 Warning: main process is still not responding, cannot add URL(s).. LANG_W1 Type/MIME associations LANG_W2 File types: LANG_W3 MIME identity: LANG_W4 Select or modify your file type(s) here LANG_W5 Select or modify your MIME type(s) here LANG_W6 Go up LANG_W7 Go down LANG_X1 File download information LANG_X2 Freeze Window LANG_X3 More information: LANG_Y1 Welcome to WinHTTrack Website Copier!\n\nPlease click on the NEXT button to\n\n- start a new project\n- or resume a partial download LISTDEF_1 File names with extension:\nFile names containing:\nThis file name:\nFolder names containing:\nThis folder name:\nLinks on this domain:\nLinks on domains containing:\nLinks from this host:\nLinks containing:\nThis link:\nALL LINKS LISTDEF_2 Show all\nHide debug\nHide infos\nHide debug and infos LISTDEF_3 Site-structure (default)\nHtml in web/, images/other files in web/images/\nHtml in web/html, images/other in web/images\nHtml in web/, images/other in web/\nHtml in web/, images/other in web/xxx, where xxx is the file extension\nHtml in web/html, images/other in web/xxx\nSite-structure, without www.domain.xxx/\nHtml in site_name/, images/other files in site_name/images/\nHtml in site_name/html, images/other in site_name/images\nHtml in site_name/, images/other in site_name/\nHtml in site_name/, images/other in site_name/xxx\nHtml in site_name/html, images/other in site_name/xxx\nAll files in web/, with random names (gadget !)\nAll files in site_name/, with random names (gadget !)\nUser-defined structure.. LISTDEF_4 Just scan\nStore html files\nStore non html files\nStore all files (default)\nStore html files first LISTDEF_5 Stay in the same directory\nCan go down (default)\nCan go up\nCan both go up & down LISTDEF_6 Stay on the same address (default)\nStay on the same domain\nStay on the same top level domain\nGo everywhere on the web LISTDEF_7 Never\nIf unknown (except /)\nIf unknown LISTDEF_8 no robots.txt rules\nrobots.txt except wizard\nfollow robots.txt rules LISTDEF_9 normal\nextended\ndebug LISTDEF_10 Download web site(s)\nDownload web site(s) + questions\nGet individual files\nDownload all sites in pages (multiple mirror)\nTest links in pages (bookmark test)\n* Continue interrupted download\n* Update existing download LISTDEF_11 Relative URI / Absolute URL (default)\nAbsolute URL / Absolute URL\nAbsolute URI / Absolute URL\nOriginal URL / Original URL LANG_OSFWB Open Source offline browser LANG_METADESC Website Copier/Offline Browser. Copy remote websites to your computer. Free. LANG_METAKEYW httrack, winhttrack, webhttrack, offline browser LANG_URLLIST URL list (.txt) LANG_PREVIOUS Previous LANG_NEXT Next LANG_URLS URLs LANG_WARNING Warning LANG_NOJS Your browser does not currently support javascript. For better results, please use a javascript-aware browser. LANG_THANKYOU Thank you LANG_CANCLSWND You can now close this window LANG_SERVEND Server terminated LANG_FATALERR A fatal error has occurred during this mirror httrack-3.49.5/httrack-doc.html0000644000175000017500000000027614336470674013311 00000000000000 Documentation Documentation httrack-3.49.5/history.txt0000644000175000017500000011635614555202533012457 00000000000000 HTTrack Website Copier release history: -------------------------------------- This file lists all changes and fixes that have been made for HTTrack 3.49-5 + Fixed: MiniZip CVE-2023-45853 + Lintian fixes, multiple build fixes 3.49-4 + New: Push default bandwidth to 100kiB/s, max to 10MiB/s + Fixed: Multiple packaging and build fixes, added security flags 3.49-3 + Fixed: Corrections and updates of the Brazilian Portuguese translations (Paulo Neto) + Fixed: Fixed for Android + Fixed: Add mimetypes for documents (Pablo Castellano) + Fixed: Add firefox-developer-edition (sickcodes) + New: Support data-src and data-srcset for img (Brian 'Redbeard' Harrington) + Fixed: When using the '%N' structure naming key, separate the filename and extension with a dot (Steve Mokris) + Fixed: Multiple build updates 3.49-2 + Fixed: Buffer overflow in output option commandline argument (VL-ID 2068) (Hosein Askari) + Fixed: Minor fixes 3.48-23 + Fixed: on Linux, FTBFS with openssl 1.1.0 3.48-22 + Fixed: on Windows, fixed possible DLL local injection (Tunisian Cyber) + Fixed: various typos 3.48-21 + Fixed: Google RPMs use /usr/bin/google-chrome as program location (Cickumqt) + Fixed: Fixed htsserver not dying (immediately) on quit + New: Updated WIN32 OpenSSL to 1.0.1j (Evgeniy) + Fixed: webhttrack incompatibility with Chrome + Fixed: assertion failure at htslib.c:3458 (strlen(copyBuff) == qLen) seen on Linux + Fixed: infamous crashes inside the DNS cache due to a corruption within the option structure (E.Kalinowski/karbofos) + New: added minimalistic crash reporting on Windows and Linux + Fixed: URL list not working anymore (tom swift) + Fixed: FTBFS on ARM + Fixed: buggy FFFD (replacement character) in place of leading non-ascii character such as Chinese ones (aballboy) + Fixed: FTBFS when compiling with zlib versions < 1.2.70 (sammyx) + Fixed: buggy SVG (Smiling Spectre) + Fixed: do not uncompress .tgz advertised as "streamed" (Smiling Spectre) + Fixed: NULL pointer dereferencing in back_unserialize (htsback.c:976) + Fixed: library development files + Fixed: --advanced-maxlinks broken (Localhost) + Fixed: -devel package should now be standalone + Fixed: assertion failure at htscore.c:244 (len + liensbuf->string_buffer_size < liensbuf->string_buffer_capa) + Fixed: injection-proof templates + Fixed: htshash.c:330 assertion failure ("error invalidating hash entry") (Sergey) + Fixed: Windows 2000 regression (fantozzi.usenet) + Fixed: code cleanup (aliasing issues, const correctness, safe strings) + New: handle --advanced-maxlinks=0 to disable maximum link limits + New: updated ZIP routines (zlib 1.2.8) + Fixed: broken 32-bit version + Fixed: assertion "segOutputSize < segSize assertion fails at htscharset.c:993" + Fixed: new zlib version fixing CVE-2004-0797 and CVE-2005-2096 + Fixed: more reliable crash reporting + Fixed: fixed infamous "hashtable internal error: cuckoo/stash collision" errors + Fixed: safety cleanup in many strings operations + Fixed: buggy option pannels + New: Enforce check against CVE-2014-0160 + New: improved hashtables to speedup large mirrors + New: added unit tests + New: Added %a option, allowing to define the "Accept:" header line. + New: Added %X option, to define additional request header lines. + New: Added option '-%t', preserving the original file type (which may produce non-browseable file locally) + Fixed: remove scope id (% character) in dotted address resolution (especially for catchurl proxy) + Fixed: build fixes, including for Android, non-SSL releases + Fixed: buggy keep-alive handling, leading to waste connections + Fixed: removed chroot and setuid features (this is definitely not our business) + Fixed: removed MMS (Microsoft Media Server) ripping code (mmsrip) (dead protocol, unmaintained code, licensing issues) + Fixed: type mishandling when processing a redirect (such as a .PDF redirecting to another .PDF, with a text/html type tagged in the redirect message) + Fixed: infinite loop when attempting to download a file:/// directory on Unix (gp)
+ Fixed: removed background DNS resolution, prone to bugs + Fixed: do not choke on Windows 2000 because of missing SetDllDirectory() (Andy Hewitt) + Fixed: %h custom build structure parameter not taken in account (William Clark) 3.47-27 + New: support for IDNA / RFC 3492 (punycode) handling + New: openssl is no longer dynamically probed at stratup, but dynamically linked + Fixed: random closing of files/sockets, leading to "zip_zipWriteInFileInZip_failed" assertion, "bogus state" messages, or random garbage in downloaded files + Fixed: libssl.dylib is now in the search list for libssl on OSX (Nils Breunese) + Fixed: bogus charset because the meta http-equiv tag is placed too far in the html page + Fixed: incorrect \\machine\dir structure build on Windows (TomZ) + Fixed: do not force a file to have an extension unless it has a known type (such as html), or a possibly known type (if delayed checks are disabled) + Fixed: HTML 5 addition regarding "poster" attribute for the "video" tag (Jason Ronallo) + Fixed: memory leaks in proxytrack.c (Eric Searcy) + Fixed: correctly set the Z flag in hts-cache/new.txt file (Peter) + Fixed: parallel patch, typo regarding ICONV_LIBS (Sebastian Pipping) + Fixed: memory leak in hashtable, that may lead to excessive memory consumption + Fixed: on Windows, fixed possible DLL local injection (CVE-2010-5252) + Fixed: UTF-8 conversion bug on Linux that may lead to buggy filenames + Fixed: zero-length files not being properly handled (not saved on disk, not updated) (lugusto) + Fixed: serious bug that may lead to download several times the same file, and "Unexpected 412/416 error" errors + Fixed: images in CSS were sometimes not correctly detected (Martin) + Fixed: links within javascript events were sometimes not correctly detected (wquatan) + Fixed: webhttrack caused bus error on certain systems, such as Mac OSX, due to the stack size (Patrick Gundlach) + Fixed: bogus charset for requests when filenames have non-ascii characters (Steven Hsiao) + Fixed: bogus charset on disk when filenames have non-ascii characters (Steven Hsiao) + Fixed: fixed 260-characters path limit for Windows (lugusto) + Fixed: non-ascii characters encoding issue inside query string (lugusto) + Fixed: HTML entities not properly decoded inside URI and query string + Fixed: URL-encoding issue within URI + Fixed: --timeout alias did not work + Fixed: more windows-specific fixes regarding 260-character path limit + Fixed: escaping issue in top index + Fixed: Linux build cleanup (gentoo patches merge, lintian fixes et al.) + Fixed: Fixed div-by-zero when specifying more than 1000 connections per seconds (probably not very common) + Fixed: Mishandling of '+' in URLs introduced in 3.47-15 (sarclaudio) + Fixed: "Wildcard domains in cookies do not match" (alexei dot co at gmail dot com ) + Fixed: buggy referer while parsing: the referer of all links in the page is the current page being parsed, NOT the parent page. (alexei dot com at gmail dot com) + Fixed: Russian translation fixes by Oleg Komarov (komoleg at mail dot ru) + New: Added .torrent => application/x-bittorrent built-in MIME type (alexei dot co at gmail dot com) + Fixed: unable to download an URL whose filename embeds special characters such as # (lugusto) + New: Croatian translation by Dominko Aždajić (domazd at mail dot ru) + Fixed: url-escaping regression introduced in the previous subrelease + Fixed: content-disposition NOT taken in account (Stephan Matthiesen) + Fixed: buggy DNS cache leading to random crashes + Fixed: fixed logging not displaying robots.txt rules limits by default + Fixed: license year and GPL link, libtool fixes (cicku) + Fixed: Keywords field in desktop files (Sebastian Pipping) 3.46-1 * New: Unicode filenames handling * Fixed: fixed bug in handling of update/continue with erased files or renamed files, leading to "Unexpected 412/416 error (Requested Range Not Satisfiable)" and/or "Previous cache file not found" (-1)" errors * Fixed: escape characters >= 128 when sending GET/HEAD requests to avoid server errors * Fixed: do not use "delayed" extensions when the mirror is aborting * Fixed: generate error pages when needed (Brent Palmer) * Fixed: parsing issue with js files due to "script" tags (Vasiliy) * Fixed: anonymous FTP without password (Luiz) * Fixed: Makefile issues regarding parrallel build and examples (Sebastian Pipping) * Fixed: removed deprecated and annoying "Accept-Charset" header in requests (Piotr Engelking) (closes:#674053) 3.45-4 * New: source license is now GPLv3 * New: added a "K5" feature to handle transparent proxies (Brent Palmer) * New: option -y to control ^Z behavior (Julian H. Stacey) * Fixed: replace // by / when saving rather than _/ (Brent Palmer) * Fixed: do not interpret ^C before mirror is finished, or after * Fixed: webhttrack: do not use md5sum to produce a temporary filename, but mktemp (Ryan Schmidt) * Fixed: document %k for custom structure (full query string) 3.45-3 * Fixed: spurious "Previous file not found (erased by user ?)" messages leading to retransfer existing files in cache (Alain Desilets) * Fixed: --max-time now stops the mirror smoothly (Alain Desilets) 3.45-2 * Fixed: number of simultaneous connections was often only one * Fixed: "Unexpected 412/416 error" leading to have broken files on disk 3.45-1 * Fixed: interrupting an update/continue mirror session should not delete anymore previously downloaded content (William Roeder, Alain Desilets and many others) * Fixed: --continue/--update bug leading to download again already cached data in some cases (especially redirect/error pages) 3.44-5 * Fixed: crash when using -d with non-fully-qualified hostname (Alain Desilets) * Fixed: typo in logs (Pascal Boulerie) 3.44-4 * Fixed: random crash when interrupting the mirror (spotted by -fstack-protector) in htscoremain.c (closes:#657878) 3.44-3 + Fixed: Linux build (closes:#657334) 3.44-2 + Fixed: malformed format htslib.c (Moritz Muehlenhoff) + Fixed: default footer print format + New: clever "^C" handling + New: added --do-not-generate-errors option + New: increased maximum cookie name 3.44-1 + Fixed: Randomly corrupted files during updates due to "engine: warning: entry cleaned up, but no trace on heap"/"Unexpected 412/416 error" errors (Petr Gajdusek ; closes:#614966) 3.43-12 + Fixed: buffer overflow while repairing httrack cache if a damaged cache is found from a previous mirror (closes:#607704) 3.43-11 + Fixed: webhttrack fixes for icecat (closes:#605140) 3.43-10 + Fixed: capture URL not working properly when IPv6 is installed (John Bostelman) 3.43-9 + Fixed: application/xhtml+xml not seen as "html" (Peter Fritzsche) + Fixed: various linux fixes for desktop files (closes:#563691) 3.43-8 + Fixed: URL encoding bugs with filenames containing '%' characters (sandboxie32) + Fixed: MacPorts Darwin/Mac fixes to webhttrack (Ross Williams) + Fixed: Flash link extraction has been improved (Vincent/suei8423) 3.43-7 + Fixed: "Open error when decompressing" errors due to temporary file generation problems (Scott Mueller) 3.43-6 + Shell: WIN32 setup cosmetic fixes: do not probe the proxy on non-local network, do not force *.whtt registration 3.43-5 + Fixed: code tag handling bug in certain cases leading to produce invalid links (Tom-tmh13 and William Roeder) 3.43-4 + Fixed: horrible SSL slowdowns due to bogus select() calls (Patrick Pfeifer) + Fixed: Konqueror fixes 3.43-3 + Updated: Portugues-Brasil language file 3.43-2 + Fixed: wizard question buggy, and commandline version did not print it (Maz) + Fixed: do not rename xml subtypes (such as xsd schemas) (Eric Avrillon) 3.43 + Fixed: Fixed too aggressive javascript url= parsing (Chris) + Fixed: fixed --urllist option "sticking" the list content to the list of URL (Andreas Maier) + Fixed: "Previous cache file not found" not redownloading file when deleted before an update (William Roeder) + Fixed: *.rpm.src files renamed to *.src.src with bogus servers (Hippy Dave) + Fixed: "pause" is pausing much faster (William Roeder) + Fixed: binary real media files and related files are no longer being parsed as html (William Roeder) + Fixed: "File not parsed, looks like binary" check no longer corrupt the checked binary file + Fixed: multiple download of error pages (several identical '"Not Found" (404) at link [identical link]') leading to a slowdown in certain cases (William Roeder) + Fixed: sometimes, a double request was issued to update a broken file + Fixed: display bug "link is probably looping, type unknown, aborting .." + Fixed: missing library references at build time and other build related issues (Debarshi Ray) + Fixed: on windows, switched from wsock32.dll to ws2_32.dll + Fixed: minor argument size validation error for "-O" option (Joan CALVET) 3.42-3 + Fixed: Bad URL length validation in the commandline (CVE-2008-3429) (Joan CALVET) 3.42-2 + Fixed: Random crashes at the end of the mirror due to a dangling file pointer (Carlos, angus at quovadis.com.ar) 3.42 + Fixed: size limits are stopping the mirror gently, finishing pending transfers (David Stevenson) 3.41-3 + Fixed: text/plain advertised files renamed into .txt + Fixed: broken configure.in 3.41-2 + Fixed: major WIN32 inlined function bug caused the cache not to be used at all, causing update not to work 3.41 + New: changed API/ABI to thread-safe ones (libhttrack1 2), big cleanup in all .h definitions + Fixed: Major memory usage bug when downloading large sites + Fixed: do not rename files if the original MIME type was compatible + Fixed: several source fixes for freeBSD (especially time problems) + New: option %w to disable specific modules (java, flash..) + Fixed: 'no space left in stack for back_add' error + Fixed: fixed redirected images with "html" type + Fixed: 'Crash adding error, unexpected error found.. [4268]' error 3.40-2 + Fixed: bogus '.del' filenames with ISO-9660 option + Fixed: now merges the header charset even with an empty footer string + New: --port option for webhttrack 3.40 + New: mms:// streaming capture (thanks to Nicolas Benoit!) + New: proxyTrack project released + New: new experimental parser that no longer needs link testing ('testing link type..') + New: Redirect handled transparently with delayed type check and broken links made external when the "no error page" option is enabled + New: improved background download to handle large sites + New: '--assume foo/bar.cgi=text/html' is now possible + New: MIME type scan rules (such as -mime:video/* +mime:video/mpeg) + New: size scan rules now allows to rewrite uncaught links as external links + Fixed: crash fixed when ftime()/localtime()==NULL + Fixed: iso-9660 option now using '_' for collision character + Fixed: collision problems with CaSe SeNsItIvItY + Fixed: a href='..' fixed! + Fixed: redirects are now handled by the new experimental parser + Fixed: "./" links generated with fixed outbound links (../../) + Fixed: 'base href' bogus in many cases + Fixed: enforce security limits to avoid bandwidth abuses + Fixed: bogus external (swf) parser, fixed remaining .delayed files + New: new check-mime and save-file2 callbacks + New: "always delayed type check" enabled + Fixed: totally bogus finalizer causing compressed files not to be uncompressed, and many files to be truncated + Shell: new Finnish interface added! + Fixed: "..html" bogus type + Fixed: remaining bogus .delayed entries + Fixed: flush before user-defined command + Fixed: fixed user-defined command call and background cleaner + Fixed: fixed 'Crash adding error, unexpected error found.. [4250]' error + Fixed: fixed cache absolute file reference (the reference is now relative) preventing the cache form being moved to another place + Fixed: webhttrack 'Browse Sites' path bug + Fixed: old httrack cache format fixes (import of older versions did not work anymore) + Fixed: port fixes in htsnet.h + Fixed: -N option with advanced extraction (bogus "not found" member) + Fixed: javascript: location=URL was not recognized + Fixed: no more character escaping when not needed (such as UTF-8 codes) + Fixed: possibly temporary files left on disk with bogus servers giving compressed content on HEAD reuests + Fixed: URL hack caused unexpected filename collisions (index.html vs INDEX.HTML) + Fixed: "do not erase already downloaded file" option now correctly works (it leaves files linked in the mirror) + Fixed: UCS2 encoded pages are now converted properly into UTF-8 + New: "near" option now also catch embedded (images, css, ..) files + Fixed: bogus chunked multimedia link text files (such as x-ms-asf files) + Fixed: compilation problems on Un*x version 3.33 + Fixed: Bogus redirects with same location in https + Fixed: Bogus file naming with URL hack + Fixed: Extremly slow redirections and empty files + Fixed: Bogus names with directories ending with a "." + New: Number of connection per second can now be.. decimal, to delay even more + New: Enforce stronger ISO9660 compliance + Shell: "URL Hack" in interface + Shell: "Save settings" now rebuild categories + Shell: "Shutdown PC after mirror" option + Shell: Sound at the beginning/end or the mirror (configurable through system sound properties) + Shell: Fixed drag & drop, .url import + Shell: Fixed "wizard" mode (crash) + Fixed: Crash at the end due to unterminated pending threads + Fixed: \ is not anymore transformed into / after the query (?) delimiter + New: Two new callbacks for pre/post-processing html data + New: link-detected2 callback (additional tag name parameter) + Fixed: Broken ISO9660 + Fixed: Crash on file:// links + Fixed: Unescaped ampersands (&) in URLs + Fixed: Transfer hangs introduced in 3.33-beta-2 + Fixed: Display bug "Waiting for scheduled time.." + Fixed: Bug "Waiting for scheduled time.." (NOT a display bug, actually) + Fixed: CaSe SenSiTiViTy bugs with mutliple links reffering to the same URL but using different case styles + Fixed: Failed to build from sources (FTBFS) on amd64 archs because of cast problems (Andreas Jochens) + Fixed: & were converted into   (Leto Kauler) + Shell: Fixed crash with long URL lists (Libor Striz) + Fixed: connection/seconds limiter replugged + Fixed: "no files updated" display bug + Fixed: bogus links encoded with UTF (Lukasz Wozniak) + New: --assume can be used to force a specific script type (Brian Schröder) 3.32 + Fixed: css and js files were not parsed! + Fixed: again broken file:// (infinite loops with local crawls) + Fixed: Bandwidth limiter more gentle with low transfer rate + Fixed: external wrappers were not called during updates/continue + New: additional callback examples + Fixed: overflow in unzip.c fixed + New: tests are now cached for better performances! + New: %r (protocol) option for user-defined structure + Fixed: Broken engine on 64-bit archs 3.31 + New: Experimental categories implemented + New: New cache format (ZIP file) + New: .m3u files now crawled + New: .aam files now crawled + Fixed: Broken ftp + Fixed: Broken file:// + Fixed: Broken cookies management and loading + Fixed: HTTrackInterface.c:251 crash + Fixed: "N connections" means "N connections" even in scan phase + Fixed: javascript:location bug + Fixed: libtool versioning problem fixed + Fixed: More javascript bugs with \' and \" + Fixed: .HTM files not renamed into .html anymore + Fixed: OSX fixes in the Makefile script + New: Default "referer" and "from" fields + New: Full HTTP headers are now stored in cache + Fixed: ftp transfer not logged/properly finalized + Fixed: Missing symbolic link in webhttrack install + Fixed: path and language not saved in webhttrack + Shell: Avoid invalid project names + Fixed: Javascript bug with src= + Fixed: Keep-alive consistency problems on Linux/Unix with bogus servers (SIGPIPE) + Fixed: Parsing bug inside javascript (bogus parsing with empty quotes in function: foo('')) + Fixed: static compiling on Linux/Unix + Fixed: bloated .h headers (internal function definitions) + Fixed: Bogus query strings with embedded ../ and/or ./ + New: Added "change-options" call in the crawl beginning + New: Query arguments now sorted for normalized URL checks (when "url hack" option is activated) + Fixed: Previous dependency to zlib.dll to zlib1.dll + Fixed: Broken static files were not correctly updated with the new cache format + Shell: Launch button in Internet Explorer + Fixed: Crash when dealing with multiple '?' in query string with 3.31-alpha 3.30 + New: Webhttrack, a linux/unix/bsd Web GUI for httrack + New: "URL hack" feature + New: HTTP-headers charset is now propagated in the html file + New: loadable external engine callbacks + New: Experimental ".mht" archives format + Fixed: Query ?? bug + Fixed: Bogus base href without http:// + Fixed: Several javascript bugs + Fixed: UCS2 pages badly detected + Fixed: Build structure change does not redownload files + Fixed: "?foo" URL bug (link with only a query string) fixed + Fixed: ' or " inside non-quoted URLs + Fixed: keep-alive problems with bogus servers + Fixed: Broken .ra files + Fixed: More javascript bugs + Fixed: ftp transfers not properly monitored in the shell + Fixed: various fixes in webhttrack + Fixed: Blank final page in webhttrack + Fixed: Javascript comments (//) are skipped + Fixed: Temporary fix for "archive" bug with multiple java archives + Fixed: Inlined js or css files have their path relative to the parent + Fixed: Unescaped quotes ("") when continuing/updating in commandline mode + Fixed: Null-character in html page bug + Fixed: External depth slightly less bogus + Fixed: Filters based on size bogus ("less than 1KiB" is now functionning) + Fixed: Strange behaviour with filters (last filter "crushed") + Fixed: Bogus downloads when using ftp (unable to save file) + Fixed: Freeze with keep-alive on certain sites due to bad chunk encoding handling + Fixed: Problems with javascript included paths + Fixed: The mirror now aborts when the filesystem is full + Fixed: "No external pages" option fixed + Fixed: Javascript and \" in document.write bug fixed + Fixed: Two memory leaks in temporary file generation, and in link build fixed + Fixed: Bogus compression with non-gzip format + Fixed: Larger range of charsets accepted + Fixed: Bogus robots.txt when using comments (#) + Fixed: Missing MIME types for files such as .ico + Shell: Fixed continuous proxy search + Shell: Fixed missing HelpHtml/ link + Fixed: Overflow in htsback.c:2779 + Fixed: Bogus style and script expressions due to too aggressive parsing + Fixed: Javascript parsing bugs with \" and \' + Fixed: Javascript link detection bugs when comments were inserted between arguments + Fixed: Bug when valid empty gzip content was received + New: More aggressive "maximum mirroring time" and "maximum amount of bytes transfered" options + New: Windows file://server/path syntax handled + Fixed: mht archive fixes + Fixed: Serious bugs with filters given in commandline erased by the engine + Fixed: Bogus parsing of javascript: generated inside document.write() inside javascript code removed 3.23 + New: Keep-alive + New: URLs size limit is now 1024 bytes + New: Bogus UCS2 html files hack + Fixed: base href bugs + Fixed: windows "dos devices" bug fixed + Fixed: dirty parsing now avoids "," + Fixed: "get non-html files near a link" option sometimes caused huge mirrors + Fixed: Bugs if zlib library is not found + Fixed: Bug with "near" and "no external pages" + Fixed: "Link empty" crash + Fixed: Several javascript bugs + Fixed: Keep-alive problems ("unknown response structure") + Fixed: Major keep-alive bug (connection not closed) + Fixed: 8-3 options not working, ISO9660 option improved + Fixed: Bogus links with embedded CR, TAB.. + Fixed: small ../ external link bug fixed 3.22-3 + Fixed: Slow engine due to (too strict) memory checks + Fixed: Overflow in htscore.c:2353 + Fixed: Bogus chunked files with content-length fixed + Fixed: Folders renamed into ".txt" on Un*x platforms bug fixed! + New: Scan rule list (-%S) added + New: Cache debugging tool (-#C) added 3.21-8 + New: Basic Macromedia Flash support (links extraction) + New: Modular design for https, flash parser and zlib + New: Standard autoconf/configure design on Un*x platforms + New: Modular design also on Windows platforms (dll/lib) + Fixed: Text files without extension not renamed "html" anymore + Fixed: Bug with "?foo" urls + Fixed: No chmod 755 on home anymore + Fixed: Stability problems due to bad file structure checks + Fixed: Overflow in GUI/commandline when displaying statistics + Fixed: Directory creation error 3.20-2 + New: HTTPS support (SSL) + New: ipv6 support + New: 'longdesc' added + New: new file 'new.txt' generated for transfer status reports + New: ISO9660 compatibility option + New: empty mirror/update detection improved + New: Update hack now recognizes "imported" files + New: Option to disable ipv4/ipv6 + New: Filters now recognize patterns like -https://* + Fixed: The engine should be now fully reentrant + Fixed: Fixes for alpha and other 64-bit systems + Fixed: Files downloaded twice if not found in cache + Fixed: ftp problems with 2xx responses + Fixed: ftp problems with multiple lines responses + Fixed: ftp %20 not escaped anymore + Fixed: ftp RETR with quotes problems + Fixed: now tolerent to empty header responses + Fixed: hts-log closed + Fixed: Compressed pages during updates + Fixed: Crash when receiving empty compressed pages + Fixed: Random crashes in 'spider' mode + Fixed: bcopy/bzero not used anymore.. + Fixed: various code cleanups + Fixed: Better UTF8 detection + Fixed: External links now work with https and ftp + Fixed: Top index.html corrupted or missing + Fixed: URL list crashes + Fixed: Random crashes with large sites due to bogus naming handler + Fixed: Freezes on some robots.txt files + Fixed: Compressed files not stored + Fixed: SVG fixes + Fixed: Raw HTML responses + Fixed: 406 error workaround + Fixed: Crashes due to binary files with bogus HTML type (not parsed anymore) + Fixed: External https and ftp links broken, relative https links broken + Fixed: Automatic resizing of filter stack + Fixed: Various ampersand (&) elements added + Fixed: https with proxy temporary workaround (direct connection) + Fixed: "base href" with absolute uris + Fixed: stack frame too large on some systems + Fixed: random bad requests due to bogus authentication + Shell: Several fixes, including registration type problems + Shell: "template files not found" fixed 3.16-2 + Fixed: Zlib v1.4 + Fixed: Gzipped files now downloaded without problems (HTTP compression bug) + Fixed: Ending spaces in URLs now handled correctly + Fixed: META-HTTP bug + Shell: Type registration done only once 3.15 + Fixed: Bogus HTTP-referer with protected sites + Fixed: Fatal IO/socket error with large sites (handles not closed) + Fixed: K4 option now works + Fixed: --continue+URL(s) now clears previous URLs + Fixed: Parsing bug with 'www.foo.com?query' + Shell: 'Soft cancel' documented + Shell: 'Kx' options added 3.10 + Fixed: Broken pipes on Linux version + Fixed: Commandline version bug with gzipped files + Fixed: Crash when reaching compressed error pages + Fixed: Bogus html-escaped characters in query strings + Fixed: Files skipped (bogus anticipating system) + Fixed: Crash when showing stats (div by zero) + Fixed: Problems with URLs/redirects containing spaces or quotes + Fixed: Slash added when ~ detected + Fixed: Ugly VT terminal + New: Faster and cleaner mirror interrupt 3.09 + Fixed: Several problems with javascript parsing + Fixed: Elements after onXXX not parsed + New: Source update wrapper + New: Style url() and @import parsed + Shell: Word database and maximum number of links + Shell: Option changes taken in account immediately + Shell: Cleaner installer (registry keys) 3.08 + New: HTTP compression is now supported + New: Faster response analysis + Fixed: External page in html if cgi + Fixed: Mix between CR and CR/LF for comments + Fixed: Top index corrupted + Shell: Better refresh during parsing + Shell: DLL error 3.07 + Fixed: Random crashes with HTTP redirects + New: New rate limiter (should be sharper) + New: Code cleaned up, new htscore.c/httrack.c files 3.06 + Fixed: Redirect to https/mailto now supported + New: Top index/top dir for Un*x version + New: Sources more modular (.so) + New: Quicktime targetX= tags + New: HTTP 100 partially supported 3.05 + Fixed: Non-scannable tag parameters ("id","name",..) + Fixed: Java classes not found when using "." as separator + Fixed: Java classes not found when missing .class 3.04 + Fixed: URLs with starting spaces + Fixed: bogus URLs when using "base href" + Shell: --assume and -%e options included + New: Documentation updated a little 3.03 + New: Parser optimizations, 10 times faster now! + New: New --assume option to speed up cgi tests + New: Option to avoid Username/password storage for external pages + New: Query string kept for local URIs + Fixed: RFC2396 compliant URLs accepted (//foo and http:foo) + Fixed: foo@foo.com not considered as URL anymore + Fixed: Space encoded into %20 in URIs + Fixed: "Unable to save file" bug + Fixed: Corrupted top index.html + Fixed: Cookies disabled with --get + Fixed: Cache bug for error pages 3.02 + Fixed: Pages without title recorded in top index + Fixed: Error with Content-type+Content-disposition + Fixed: backblue.gif/external.html files not purged anymore + Fixed: Encoding problems with files containing %2F or other characters + Fixed: Write error reported for HTML files + New: hts-stop.lock file to pause the engine + New: New install system using InnoSetup 3.01 + New: HTTP real media files captured + Fixed: Bogus statitics + Fixed: Minor fixes 3.00 + New: New interface, with MANY improvements! + New: Better parsing (enhanced javascript parsing, sharper HTML parsing) + New: Faster and more efficient background download system + New: ETag properly handled + New: Optional URL list + New: Optionnal config file + New: New structure options + New: New filters options (size filters) + New: Better password site handling + New: Traffic control to avoid server overload + New: Setuid and Chroot for Unix release + New: limited 64-bit handling + New: .js files are now parsed + New: Single hts-log.txt file, error level + New: New top index.html design + New: "Update hack" option to prevent unnecessary updates + New: Default language sent for mirrors + New: Searchable index + Fixed: Bogus ftp routines (Linux version) + Fixed: Bug that caused to mirror a complete site from a subdir + Fixed: Bug that caused restart to be very slow + Fixed: Bug that caused loops on several query-string pages (?foo=/) + Fixed: Corrupted cache bug + Fixed: Random broken links (pages not downloaded) + Fixed: Shared links problems + Fixed: Bogus URLs with commas (,) + Fixed: Bogus / and \ mixed + Fixed: Bogus addresses with multiple @ + Fixed: Bogus links with %2E and %2F + Fixed: Bogus empty links + Fixed: "Unexpected backing error" bug fixed + Fixed: Files with incorrect size no more accepted + Fixed: Top index.html created even for untitled pages + Fixed: Bogus N100 option (unable to save file) + Fixed: Deadlock when using many hosts in URLs + Fixed: Password stored internally to avoid access errors + Fixed: Fixed /nul DOS limit + Fixed: Bogus -* filter (nothing mirrored) + Fixed: .shtml now renamed into .html + Fixed: Content-disposition without "" + Fixed: External html page for /foo links + Fixed: Username/password % compliant + Fixed: Javascript parser sometimes failed with " and ' mixed + Fixed: Some Range: bugs when regeting complete files + Fixed: Range: problems with html files + Fixed: HTTP/1.1 407 and 416 messages now handled + Fixed: Bogus timestamp + Fixed: Null chars in HTML bug + Fixed: Error pages cache bug + Fixed: Connect error/site moved do not delete everything anymore! + Fixed: Bogus garbage ../ in relative URL + Shell: New transfer rate estimation + Shell: Fixed crash when using verbose wizard + Shell: dynamic lang.h for easier translation updates + Shell: Fixed some options not passed to the engine + Fixed: A lots of minor fixes! 2.2 Note: 3.00 alpha major bug fixes are included in the 2.2 2.02 + New: Cache system improved, compatible with all platforms + New: Update process improved (accurate date) + New: Remote timestamp for files + New: ETag (HTTP/1.1) supported + Shell: Portugese interface available + Fixed: Bug with links containing commas + Fixed: 'file://' bug with proxy + New: Engine a little bit faster + Shell: Some bugs fixed in the interface 2.01 + New: ftp through proxy finally supported! + New: Sources cleaned up + New: Again some new marvelous options + New: Speed improved (links caught during parsing, faster "fast update") + New: Tool to catch "submit" URL (forms or complex javascript links) + Shell: German interface available + Shell: Dutch interface available + Shell: Polish interface available + Fixed: Level 1 bug fixed + Fixed: Still some parsing/structure problems + Fixed: Referer now sent to server + Fixed: Cookies did not work properly + Fixed: Problems with redirect pages + New: Better javascript parsing + Fixed: Problems with URL-parameters (foo.cgi?param=2&choice=1) + Fixed: Problems with ftp + New: ftp transfers are now in passive mode (firewall compliant) 2.00 -- The First Free Software Release of HTTrack! + New: HTTrack sources (command line), now free software, are given + Shell: Interface rewritten! + New: Documentation rewritten + Shell: Drag&Drop abilities + Shell: More URL informations + Shell: Fixed: Remote access problems + Fixed: Loop problems on some sites causing crashes + Fixed: URL encoding problems + Fixed: Some file access problems for ../ + Fixed: Some fixes for updating a mirror + Shell: Crazy progress bar fixed + Fixed: Form action are rewritten so that cgi on form can work from an offline mirror + Fixed: Crashes after continuing an "hand-interrupted" mirror + Fixed: Bogus files with some servers (chunk bug) 1.30 + Shell: Interface improved + New: robots.txt are followed by default + New: Parsing speed improved on big (>10,000 links) sites with an hash table + New: Mirror Link mode (mirror all links in a page) + New: Cookies are now understood + New: No external pages option (replace external html/gif by default files) + New: Command line version improved, background on Unix releases + Fixed: Problems with javascript parsing + Fixed: Username/password not set to lowercase anymore + Fixed: Problems with base href + New: Links in level 1 html files now patched + New: Expurge now deletes unused folders + New: Option -V executes shell command for every new file + Shell: Primary filter now works 1.24 + Fixed: Ftp protocol bogus (with login/pass) + Fixed: Cache problems (corrupted files) + New: Expurge old files for updates + New: "Updated" messages for mirror updates + Shell: Autodial/hangup option to RAS + Fixed: index.html were not created sometimes + Shell: Fixed: Random crashes with the interface + Shell: Fixed: Filters profile not saved + Fixed: Various (and numerous) fixes 1.23 + Shell: Interface improved + Shell: Multiple setups + Shell: Redefine options + Shell: Continue interrupted mirror improved 1.22 + Fixed: Parsing up/down did not work well + Fixed: Several files not catched, bugs fixes + Fixed: Problems with classes (1.21) + New: Transfer rate can be limited (-A option) + Shell: Smooth refresh + New: ftp basic protocol a little bit improved 1.21 + Fixed: Several java classes were not parsed + Fixed: Some folders without ending / ignored + Fixed: Crashes due to content-type too long 1.20 + Shell: documentation! + Fixed: Some problems with 'host cancel' system after timeouts (crashes) + New: Get only end of files if possible (file partially get) + New: New cache system (only HTML stored) + New: User-defined structure possible + New: Also available: french interface + Fixed: Random crashes (div by 0/illegal instruction) with null size files + New: Limited ftp protocol (files only), e.g. +ftp://* now works + Fixed: Some connect problems with several servers or proxies + New: New option, save html error report by default + Shell: Browse and see log files at the end of a mirror + New: Proxy authentication (ex: guest:star@myproxy.com:8080) + Shell: Interface improved (especially during mirror) + Fixed: Ambiguous files are renamed (asp,cgi->html/gif..) + Shell: New test link mode option + New: Site authentication (ex: guest:star@www.myweb.com/index.html) + Fixed: Minor bugs fixed + Shell: See log files during a mirror + Fixed: Some problems using CGI (different names now) + Fixed: Go down/up/both options and filters + Fixed: "Store html first" did not work + New: -F option ("Browser ID") disguise HTTrack into a browser + New: New filter system + Shell: New "Save as default" options + Fixed: "Build options" did NOT work properly! (files overwritten or missing) + Fixed: User agent ID fixed + Shell: Skip options + Shell: Better interface control during mirrors + Shell: InstallShield and Help files + Fixed: Some external links were not filtered sometimes + Fixed: Mirror crash at the end 1.16b + Shell: Really *stupid* bug fixed causing WinHTTrack to be slooow + Fixed: Crash if the first page has no title fixed + Fixed: Bogus options like "Just scan" saved empty files + Fixed: Forbid all links (*) with manual accept did not work + Shell: Filters interface improved 1.16: + New : Java Classes and subclasses are now retrieved! + New: Better JavaScripts parsing + New: Option: Abandon slowest hosts if timeout/transfer too slow + Shell: Interface improved 1.15b + Fixed: Some bugs fixed 1.15: + Shell: Interface improved + New: Robot improved (some files through javascript are now detected!) + New: Improved wild cards (for example, +www.*.com/*.zip) + New: 'config' file to configurate proxy, path.. only once 1.11 + New: Wait for specific time (begin transfer at specific hour) + New: Time limit option (stops transfer after x seconds) + Shell: Interface improved for an easy use 1.10e + Fixed: Maps were not correctly managed (stupid bug) 1.10d: + Fixed: Bogus index.html fixed 1.10c + Shell: "Time out" field needed "transfer rate" field 1.10b + Fixed: Better memory management 1.10 + New: "Transfer rate out" option added (abandon slowests sites) + New: "Deaf" hosts do not freeze HTTrack any more + Fixed: Again problems with code/codebase tags + New: Broken links detection improved 1.04 + Fixed:Some links were not correctly read (pages with "codebase" tags) + Shell: Interface improved 1.03 (No changes for the command-line robot) + Shell: Big bug fixed! (VERY slow transfer rates..) 1.02 + Fixed: Some java files were not correctly transfered + New: Speed has been improved + Fixed: Log file more accurate + Shell: Interface has been improved 1.01 + Fixed: Structure check error in some cases 1.00 -- The 1.00, Yeah! + New: base and codebase are now scanned 0.998 beta-2 + Fixed: Multiple name bug (files having the same name in the same directory) with -O option fixed 0.997 beta-2 + Fixed: Filenames with '%' were not correctly named + Fixed: Bug detected in 0.996: several files are not written on disk!! 0.996 beta-2 + New: -O option (path for mirror and log) + New: Unmodified file time/date are not changed during an update 0.99 beta-2 + New: User-agent field + New: Shortcuts (--spider etc.) + New: Links not retrieved are now rebuilt absolutly + New: The 'g' option (juste get files in current directory) has been added + New: Primary links analyste has been improved + Fixed: "304" bug fixed 0.25 beta-2 + Fixed: Freeze during several mirrors fixed! + New: More 'N' options (filenames type) 0.24 beta-2 + Fixed: Restart/Update with cache did not work (really not..) + Fixed: Wild cards now work properly (e.g. +www.abc.com* do works) + New: The 'n' option (get non-html files near a link) has been added! 0.23 beta-2 + Fixed: The 'M' option (site size) did not work + Fixed: Files larger than 65Kb were not correctly written older beta + Many, many bugs fixed httrack-3.49.5/greetings.txt0000644000175000017500000000676214336470674012756 00000000000000Informations on this project: This project has been developed by: Xavier Roche (xroche at httrack.com) project leader core engine, Windows/Linux GUI Yann Philippot (yphilippot at lemel.fr) for the java binary .class parser With the help of: Leto Kauler (molotov at tasmail.com) for the site/logos design http://kauler.com/ Christian Marillat (marillat.christian at wanadoo.fr) for autoconf compliance and .deb package Fred Cohen (fc at all.net) for HTTrack user's guide http://all.net/ And the help of the following third party developers: Nicolas Benoit (nbenoit at tuxfamily.org), SDP Multimedia and Major MMS for the mms plugin core routines (MMSRIP) http://nbenoit.tuxfamily.org/ Jean-loup Gailly from gzip.org for the help provided with Zlib http://www.zlib.net/ Eric A. Young (eay at cryptsoft.com) for SSL cryptographic material (OpenSSL) http://www.openssl.org/ Jordan Russell for the Windows setup tool (Inno Setup) http://www.jrsoftware.org/isinfo.php Translations written by: David Lawrie (dalawrie at lineone.net) Robert Lagadec (rlagadec at yahoo.fr) for checking both English & French translations Juan Pablo Barrio Lera (University of León) for Spanish translations Rainer Klueting (rk-htt at centermail.net) Bastian Gorke (bastiang at yahoo.com) Rudi Ferrari (Wyando at netcologne.de) Marcus Gaza (MarcusGaza at t-online.de) for German translations Rudi Ferrari (Wyando at netcologne.de) for Dutch translations Lukasz Jokiel (Opole University of Technology, Lukasz.Jokiel at po.opole.pl) for Polish translations Rui Fernandes (CANTIC, ruiefe at mail.malhatlantica.pt) Pedro T. Pinheiro (Universidade Nova de Lisboa-FCT, ptiago at mail.iupi.pt) for Portuguese translations Andrei Iliev (iliev at vitaplus.ru) for Russian translations Witold Krakowski (wtkrak at netscape.net ) for Italian translations Jozsef Tamas Herczeg (hdodi at freemail.hu) for Hungarian translation Paulo Neto (pauloneto at layoutdobrasil.com) for Brazilian translation Brook Qin (brookqwr at sina.com) for simplified Chinese translation David Hing Cheong Hung (DAVEHUNG at mtr.com.hk) Addy Lin (addy1975 at pchome.com.tw) for traditional Chinese translation Jesper Bramm (bramm at get2net.dk) for Danish translation Tõnu Virma for Estonian translation Staffan Ström (staffan at fam-strom.org) for Swedish translation Arman (Armish) Aksoy (armish at linux-sevenler.de) Mehmet Akif Köeoðlu (mak at ttnet.net.tr) for Turkish translation Aleksandar Savic (aleks at macedonia.eu.org) for Macedonian translation Takayoshi Nakasikiryo for Japanese translation Martin Sereday (sereday at slovanet.sk) for Slovak translation Antonín Matìjèík (matejcik at volny.cz) for Czech translation Andrij Shevchuk (http://programy.com.ua) for Ukrainian translation Tobias "Spug" Langhoff (spug_enigma at hotmail.com) for Norwegian translation Jadran Rudeciur (jrudec at email.si) for Slovenian translation Alin Gheorghe Miron (miron.alin at personal.ro) for Romanian translation Michael Papadakis (mikepap at freemail.gr) for Greek translation Ilia Lindov (ilia at infomat-bg.com) for Bulgarian translation Mika Kähkönen (mika.kahkonen at mbnet.fi) for Finnish translation Thanks to: Patrick Ducrot & Daniel Carré (ENSI of Caen) for their initial support http://www.ducrot.org/ http://www.greyc.ensicaen.fr/~dcarre/ Ensi of Caen for their initial support http://www.ensicaen.fr/ La sonothèque du Terrier for the sound fx :) ..and all users who are using and supporting HTTrack! httrack-3.49.5/license.txt0000644000175000017500000000315314336470674012400 00000000000000HTTrack Website Copier License Agreement: HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . In addition, as a special exception, Xavier Roche gives permission to link the code of this program with the openSSL library (or with modified versions of openSSL that use the same license as openSSL), and distribute linked combinations including the two. You must obey the GNU General Public License in all respects for all of the code used other than openSSL. If you modify this file, you may extend this exception to your version of the file, but you are not obligated to do so. If you do not wish to do so, delete this exception statement from your version. Important notes: We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private informations on persons. This would disgrace our work, and spoil the many hours we spent on it. Contacting us / support: Please refer to the README file httrack-3.49.5/gpl-fr.txt0000644000175000017500000013442014336470674012147 00000000000000 LICENCE PUBLIQUE GÉNÉRALE GNU Version 3, du 29 juin 2007. Copyright (C) 2007 Free Software Foundation, Inc. Chacun est autorisé à copier et distribuer des copies conformes de ce document de licence, mais toute modification en est proscrite. Traduction française par Philippe Verdy , le 30 juin 2007. _______________________________________________________________________ Avertissement important au sujet de cette traduction française. _______________________________________________________________________ Ceci est une traduction en français de la licence “GNU General Public License” (GPL). Cette traduction est fournie ici dans l’espoir qu’elle facilitera sa compréhension, mais elle ne constitue pas une traduction officielle ou approuvée d’un point de vue juridique. La Free Software Foundation (FSF) ne publie pas cette traduction et ne l’a pas approuvée en tant que substitut valide au plan légal pour la licence authentique “GNU General Public Licence”. Cette traduction n’a pas encore été passée en revue attentivement par un juriste et donc le traducteur ne peut garantir avec certitude qu’elle représente avec exactitude la signification légale des termes de la licence authentique “GNU General Public License” publiée en anglais. Cette traduction n’établit donc légalement aucun des termes et conditions d’utilisation d’un logiciel sous licence GNU GPL — seul le texte original en anglais le fait. Si vous souhaitez être sûr que les activités que vous projetez seront autorisées par la GNU General Public License, veuillez vous référer à sa seule version anglaise authentique. La FSF vous recommande fermement de ne pas utiliser cette traduction en tant que termes officiels pour vos propres programmes ; veuillez plutôt utiliser la version anglaise authentique telle que publiée par la FSF. Si vous choisissez d’acheminer cette traduction en même temps qu’un Programme sous licence GNU GPL, cela ne vous dispense pas de l’obligation d’acheminer en même temps une copie de la licence authentique en anglais, et de conserver dans la traduction cet avertissement important en français et son équivalent en anglais ci-dessous. _______________________________________________________________________ Important Warning About This French Translation. _______________________________________________________________________ This is a translation of the GNU General Public License (GPL) into French. This translation is distributed in the hope that it will facilitate understanding, but it is not an official or legally approved translation. The Free Software Foundation (FSF) is not the publisher of this translation and has not approved it as a legal substitute for the authentic GNU General Public License. The translation has not been reviewed carefully by lawyers, and therefore the translator cannot be sure that it exactly represents the legal meaning of the authentic GNU General Public License published in English. This translation does not legally state the terms and conditions of use of any Program licenced under GNU GPL — only the original English text of the GNU LGPL does that. If you wish to be sure whether your planned activities are permitted by the GNU General Public License, please refer to its sole authentic English version. The FSF strongly urges you not to use this translation as the official distribution terms for your programs; instead, please use the authentic English version published by the FSF. If you choose to convey this translation along with a Program covered by the GPL Licence, this does not remove your obligation to convey at the same time a copy of the authentic GNU GPL License in English, and you must keep in this translation this important warning in English and its equivalent in French above. _______________________________________________________________________ Préambule La Licence Publique Générale GNU (“GNU General Public License”) est une licence libre, en “copyleft”, destinée aux œuvres logicielles et d’autres types de travaux. Les licences de la plupart des œuvres logicielles et autres travaux de pratique sont conçues pour ôter votre liberté de partager et modifier ces travaux. En contraste, la Licence Publique Générale GNU a pour but de garantir votre liberté de partager et changer toutes les versions d’un programme — afin d’assurer qu’il restera libre pour tous les utilisateurs. Nous, la Free Software Foundation, utilisons la Licence Publique Générale GNU pour la plupart de nos logiciels ; cela s’applique aussi à tout autre travail édité de cette façon par ses auteurs. Vous pouvez, vous aussi, l’appliquer à vos propres programmes. Quand nous parlons de logiciel libre (“free”), nous nous référons à la liberté (“freedom”), pas au prix. Nos Licences Publiques Générales sont conçues pour assurer que vous ayez la liberté de distribuer des copies de logiciel libre (et le facturer si vous le souhaitez), que vous receviez le code source ou pouviez l’obtenir si vous le voulez, que vous pouviez modifier le logiciel ou en utiliser toute partie dans de nouveaux logiciels libres, et que vous sachiez que vous avez le droit de faire tout ceci. Pour protéger vos droits, nous avons besoin d’empêcher que d’autres vous restreignent ces droits ou vous demande de leur abandonner ces droits. En conséquence, vous avez certaines responsabilités si vous distribuez des copies d’un tel programme ou si vous le modifiez : les responsabilités de respecter la liberté des autres. Par exemple, si vous distribuez des copies d’un tel programme, que ce soit gratuit ou contre un paiement, vous devez accorder aux Destinataires les mêmes libertés que vous avez reçues. Vous devez aussi vous assurer qu’eux aussi reçoivent ou peuvent recevoir son code source. Et vous devez leur montrer les termes de cette licence afin qu’ils connaissent leurs droits. Les développeurs qui utilisent la GPL GNU protègent vos droits en deux étapes : (1) ils affirment leur droits d’auteur (“copyright”) sur le logiciel, et (2) vous accordent cette Licence qui vous donne la permission légale de le copier, le distribuer et/ou le modifier. Pour la protection des développeurs et auteurs, la GPL stipule clairement qu’il n’y a pas de garantie pour ce logiciel libre. Aux fins à la fois des utilisateurs et auteurs, la GPL requière que les versions modifiées soient marquées comme changées, afin que leurs problèmes ne soient pas attribués de façon erronée aux auteurs des versions précédentes. Certains dispositifs sont conçus pour empêcher l’accès des utilisateurs à l’installation ou l’exécution de versions modifiées du logiciel à l’intérieur de ces dispositifs, alors que les fabricants le peuvent. Ceci est fondamentalement incompatible avec le but de protéger la liberté des utilisateurs de modifier le logiciel. L’aspect systématique de tels abus se produit dans le secteur des produits destinés aux utilisateurs individuels, ce qui est précidément ce qui est le plus inacceptable. Aussi, nous avons conçu cette version de la GPL pour prohiber cette pratique pour ces produits. Si de tels problèmes surviennent dans d’autres domaines, nous nous tenons prêt à étendre cette restriction à ces domaines dans de futures versions de la GPL, autant qu’il sera nécessaire pour protéger la liberté des utilisateurs. Finalement, chaque programme est constamment menacé par les brevets logiciels. Les États ne devraient pas autoriser de tels brevets à restreindre le développement et l’utilisation de logiciels libres sur des ordinateurs d’usage général ; mais dans ceux qui le font, nous voulons spécialement éviter le danger que les brevets appliqués à un programme libre puisse le rendre effectivement propriétaire. Pour empêcher ceci, la GPL assure que les brevets ne peuvent être utilisés pour rendre le programme non-libre. Les termes précis et conditions concernant la copie, la distribution et la modification suivent. TERMES ET CONDITIONS Article 0. Définitions. « Cette Licence » se réfère à la version 3 de la “GNU General Public License” (le texte original en anglais). « Droit d’Auteur » signifie aussi les droits du “copyright” ou voisins qui s’appliquent à d’autres types de travaux, tels que ceux sur les masques de semi-conducteurs. « Le Programme » se réfère à tout travail qui peut être sujet au Droit d’Auteur (“copyright”) et dont les droits d’utilisation sont concédés en vertu de cette Licence. Chacun des Licenciés, à qui cette Licence est concédée, est désigné par « vous. » Les « Licenciés » et les « Destinataires » peuvent être des personnes physiques ou morales (individus ou organisations). « Modifier » un travail signifie en obtenir une copie et adapter tout ou partie du travail d’une façon nécessitant une autorisation d’un titulaire de Droit d’Auteur, autre que celle permettant d’en produire une copie conforme. Le travail résultant est appelé une « version modifiée » du précédent travail, ou un travail « basé sur » le précédent travail. Un « Travail Couvert » signifie soit le Programme non modifié soit un travail basé sur le Programme. « Propager » un travail signifie faire quoi que ce soit avec lui qui, sans permission, vous rendrait directement ou indirectement responsable d’un délit de contrefaçon suivant les lois relatives au Droit d’Auteur, à l’exception de son exécution sur un ordinateur ou de la modification d’une copie privée. La propagation inclue la copie, la distribution (avec ou sans modification), la mise à disposition envers le public, et aussi d'autres activités dans certains pays. « Acheminer » un travail signifie tout moyen de propagation de celui-ci qui permet à d’autres parties de réaliser ou recevoir des copies. La simple interaction d’un utilisateur à travers un réseau informatique, sans transfert effectif d’une copie, ne constitue pas un acheminement. Une interface utilisateur interactive affiche des « Notices Légales Appropriées » quand elle comprend un dispositif convenable, bien visible et évident qui (1) affiche une notice appropriée sur les droits d’auteur et (2) informe l’utilisateur qu’il n’y a pas de garantie pour le travail (sauf si des garanties ont été fournies hors du cadre de cette Licence), que les licenciés peuvent acheminer le travail sous cette Licence, et comment voir une copie de cette Licence. Si l’interface présente une liste de commandes utilisateur ou d’options, tel qu’un menu, un élément évident dans la liste présentée remplit ce critère. Article 1. Code source. Le « code source » d’un travail signifie la forme préférée du travail permettant ou facilitant les modifications de celui-ci. Le « code objet » d’un travail signifie toute forme du travail qui n’en est pas le code source. Une « Interface Standard » signifie une interface qui est soit celle d’une norme officielle définie par un organisme de normalisation reconnu ou, dans le cas des interfaces spécifiées pour un langage de programmation particulier, une interface largement utilisée parmi les développeurs travaillant dans ce langage. Les « Bibliothèques Système » d’un travail exécutable incluent tout ce qui, en dehors du travail dans son ensemble, (a) est inclus dans la forme usuelle de paquetage d’un Composant Majeur mais ne fait pas partie de ce Composant Majeur et (b) sert seulement à permettre l’utilisation du travail avec ce Composant Majeur ou à implémenter une Interface Standard pour laquelle une implémentation est disponible au public sous forme de code source ; un « Composant Majeur » signifie, dans ce contexte, un composant majeur essentiel (noyau, système de fenêtrage, etc.) du système d’exploitation (le cas échéant) d’un système sur lequel le travail exécutable fonctionne, ou bien un compilateur utilisé pour produire le code objet du travail, ou un interprète de code objet utilisé pour exécuter celui-ci. Le « Source Correspondant » d’un travail sous forme de code objet signifie l’ensemble des codes sources nécessaires pour générer, installer et (dans le cas d’un travail exécutable) exécuter le code objet et modifier le travail, y compris les scripts pour contrôler ces activités. Cependant, cela n’inclue pas les Bibliothèques Système du travail, ni les outils d’usage général ou les programmes libres généralement disponibles qui peuvent être utilisés sans modification pour achever ces activités mais ne sont pas partie de ce travail. Par exemple le Source Correspondant inclut les fichiers de définition d’interfaces associés aux fichiers sources du travail, et le code source des bibliothèques partagées et des sous-routines liées dynamiquement, pour lesquelles le travail est spécifiquement conçu pour les requérir via, par exemple, des communications de données ou contrôles de flux internes entre ces sous-programmes et d’autres parties du travail. Le Source Correspondant n’a pas besoin d’inclure tout ce que les utilisateurs peuvent regénérer automatiquement à partir d’autres parties du Source Correspondant. Le Source Correspondant pour un travail sous forme de code source est ce même travail. Article 2. Permissions de base. Tous les droits accordés suivant cette Licence le sont jusqu’au terme des Droits d’Auteur (“copyright”) sur le Programme, et sont irrévocables pourvu que les conditions établies soient remplies. Cette Licence affirme explicitement votre permission illimitée d’exécuter le Programme non modifié. La sortie produite par l’exécution d’un Travail Couvert n’est couverte par cette Licence que si cette sortie, étant donné leur contenu, constitue un Travail Couvert. Cette Licence reconnait vos propres droits d’usage raisonnable (“fair use” en législation des États-Unis d’Amérique) ou autres équivalents, tels qu’ils sont pourvus par la loi applicable sur le Droit d’Auteur (“copyright”). Vous pouvez créer, exécuter et propager sans condition des Travaux Couverts que vous n’acheminez pas, aussi longtemps que votre licence demeure en vigueur. Vous pouvez acheminer des Travaux Couverts à d’autres personnes dans le seul but de leur faire réaliser des modifications à votre usage exclusif, ou pour qu’ils vous fournissent des facilités vous permettant d’exécuter ces travaux, pourvu que vous vous conformiez aux termes de cette Licence lors de l’acheminement de tout matériel dont vous ne contrôlez pas le Droit d’Auteur (“copyright”). Ceux qui, dès lors, réalisent ou exécutent pour vous les Travaux Couverts ne doivent alors le faire qu’exclusivement pour votre propre compte, sous votre direction et votre contrôle, suivant des termes qui leur interdisent de réaliser, en dehors de leurs relations avec vous, toute copie de votre matériel soumis au Droit d’Auteur. L’acheminement dans toutes les autres circonstances n’est permis que selon les conditions établies ci-dessous. La concession de sous-licences n’est pas autorisé ; l’article 10 rend cet usage non nécessaire. Article 3. Protection des droits légaux des utilisateurs envers les lois anti-contournement. Aucun Travail Couvert ne doit être vu comme faisant partie d’une mesure technologique effective selon toute loi applicable remplissant les obligations prévues à l’article 11 du traité international sur le droit d’auteur adopté à l’OMPI le 20 décembre 1996, ou toutes lois similaires qui prohibent ou restreignent le contournement de telles mesures. Si vous acheminez un Travail Couvert, vous renoncez à tout pouvoir légal d’interdire le contournement des mesures technologiques dans tous les cas où un tel contournement serait effectué en exerçant les droits prévus dans cette Licence pour ce Travail Couvert, et vous déclarez rejeter toute intention de limiter l’opération ou la modification du Travail, en tant que moyens de renforcer, à l’encontre des utilisateurs de ce Travail, vos droits légaux ou ceux de tierces parties d’interdire le contournement des mesures technologiques. Article 4. Acheminement des copies conformes. Vous pouvez acheminer des copies conformes du code source du Programme tel que vous l’avez reçu, sur n’importe quel support, pourvu que vous publiiez scrupuleusement et de façon appropriée sur chaque copie une notice de Droit d’Auteur appropriée ; gardez intactes toutes les notices établissant que cette Licence et tous les termes additionnels non permissifs ajoutés en accord avec l’article 7 s’appliquent à ce code ; et donnez à chacun des Destinataires une copie de cette Licence en même temps que le Programme. Vous pouvez facturer à un prix quelconque, y compris gratuit, chacune des copies que vous acheminez, et vous pouvez offrir une protection additionnelle de support ou de garantie en échange d’un paiement. Article 5. Acheminement des versions sources modifiées. Vous pouvez acheminer un travail basé sur le Programme, ou bien les modifications pour le produire à partir du Programme, sous la forme de code source suivant les termes de l’article 4, pourvu que vous satisfassiez aussi à chacune des conditions requises suivantes : a) Le travail doit comporter des notices évidentes établissant que vous l’avez modifié et donnant la date correspondante. b) Le travail doit comporter des notices évidentes établissant qu’il est édité selon cette Licence et les conditions ajoutées d’après l’article 7. Cette obligation vient modifier l’obligation de l’article 4 de « garder intactes toutes les notices. » c) Vous devez licencier le travail entier, comme un tout, suivant cette Licence à quiconque entre en possession d’une copie. Cette Licence s’appliquera en conséquence, avec les termes additionnels applicables prévus par l’article 7, à la totalité du travail et chacune de ses parties, indépendamment de la façon dont ils sont empaquetés. Cette licence ne donne aucune permission de licencier le travail d’une autre façon, mais elle n’invalide pas une telle permission si vous l’avez reçue séparément. d) Si le travail a des interfaces utilisateurs interactives, chacune doit afficher les Notices Légales Appropriées ; cependant si le Programme a des interfaces qui n’affichent pas les Notices Légales Appropriées, votre travail n’a pas à les modifier pour qu’elles les affichent. Une compilation d’un Travail Couvert avec d’autres travaux séparés et indépendants, qui ne sont pas par leur nature des extensions du Travail Couvert, et qui ne sont pas combinés avec lui de façon à former un programme plus large, dans ou sur un volume de stockage ou un support de distribution, est appelé un « aggrégat » si la compilation et son Droit d’Auteur résultant ne sont pas utilisés pour limiter l’accès ou les droits légaux des utilisateurs de la compilation en deça de ce que permettent les travaux individuels. L’inclusion d’un Travail Couvert dans un aggrégat ne cause pas l’application de cette Licence aux autres parties de l’aggrégat. Article 6. Acheminement des formes non sources. Vous pouvez acheminer sous forme de code objet un Travail Couvert suivant les termes des articles 4 et 5, pourvu que vous acheminiez également suivant les termes de cette Licence le Source Correspondant lisible par une machine, d’une des façons suivantes : a) Acheminer le code objet sur, ou inclus dans, un produit physique (y compris un support de distribution physique), accompagné par le Source Correspondant fixé sur un support physique durable habituellement utilisé pour les échanges de logiciels. b) Acheminer le code objet sur, ou inclus dans, un produit physique (y compris un support de distribution physique), accompagné d’une offre écrite, valide pour au moins trois années et valide pour aussi longtemps que vous fournissez des pièces de rechange ou un support client pour ce modèle de produit, afin de donner à quiconque possède le code objet soit (1) une copie du Source Correspondant à tout logiciel dans ce produit qui est couvert par cette Licence, sur un support physique durable habituellement utilisé pour les échanges de logiciels, pour un prix non supérieur au coût raisonnable de la réalisation physique de l’acheminement de la source, ou soit (2) un accès permettant de copier le Source Correspondant depuis un serveur réseau sans frais. c) Acheminer des copies individuelles du code objet avec une copie de l’offre écrite de fournir le Source Correspondant. Cette alternative est permise seulement occasionellement et non commercialement, et seulement si vous avez reçu le code objet avec une telle offre, en accord avec l’article 6 alinéa b. d) Acheminer le code objet en offrant un accès depuis un emplacement désigné (gratuit ou contre facturation) et offrir un accès équivalent au Source Correspondant de la même façon via le même emplacement et sans facturation supplémentaire. Vous n’avez pas besoin d’obliger les Destinataires à copier le Source Correspondant en même temps que le code objet. Si l’emplacement pour copier le code objet est un serveur réseau, le Source Correspondant peut être sur un serveur différent (opéré par vous ou par un tiers) qui supporte des facilités équivalentes de copie, pourvu que vous mainteniez des directions claires à proximité du code objet indiquant où trouver le Source Correspondant. Indépendamment de quel serveur héberge le Source Correspondant, vous restez obligé de vous assurer qu’il reste disponible aussi longtemps que nécessaire pour satisfaire à ces obligations. e) Acheminer le code objet en utilisant une transmission d’égal-à-égal, pourvu que vous informiez les autres participants sur où le code objet et le Source Correspondant du travail sont offerts sans frais au public général suivant l’article 6 alinéa d. Une portion séparable du code objet, dont le code source est exclu du Source Correspondant en tant que Bibliothèque Système, n’a pas besoin d’être inclu dans l’acheminement du travail sous forme de code objet. Un « Produit Utilisateur » est soit (1) un « Produit de Consommation, » ce qui signifie toute propriété personnelle tangible normalement utilisée à des fins personnelles, familiales ou relatives au foyer, soit (2) toute chose conçue ou vendue pour l’incorporation dans un lieu d’habitation. Pour déterminer si un produit constitue un Produit de Consommation, les cas ambigus sont résolus en fonction de la couverture. Pour un produit particulier reçu par un utilisateur particulier, l’expression « normalement utilisée » ci-avant se réfère à une utilisation typique ou l’usage commun de produits de même catégorie, indépendamment du statut de cet utilisateur particulier ou de la façon spécifique dont cet utilisateur particulier utilise effectivement ou s’attend lui-même ou est attendu à utiliser ce produit. Un produit est un Produit de Consommation indépendamment du fait que ce produit a ou n’a pas d’utilisations substantielles commerciales, industrielles ou hors Consommation, à moins que de telles utilisations représentent le seul mode significatif d’utilisation du produit. Les « Informations d’Installation » d’un Produit Utilisateur signifient toutes les méthodes, procédures, clés d’autorisation ou autres informations requises pour installer et exécuter des versions modifiées d’un Travail Couvert dans ce Produit Utilisateur à partir d’une version modifiée de son Source Correspondant. Les informations qui suffisent à assurer la continuité de fonctionnement du code objet modifié ne doivent en aucun cas être empêchées ou interférées du seul fait qu’une modification a été effectuée. Si vous acheminez le code objet d’un Travail Couvert dans, ou avec, ou spécifiquement pour l’utilisation dans, un Produit Utilisateur et l’acheminement se produit en tant qu’élément d’une transaction dans laquelle le droit de possession et d’utilisation du Produit Utilisateur est transféré au Destinataire définitivement ou pour un terme fixé (indépendamment de la façon dont la transaction est caractérisée), le Source Correspondant acheminé selon cet article-ci doit être accompagné des Informations d’Installation. Mais cette obligation ne s’applique pas si ni vous ni aucune tierce partie ne détient la possibilité d’intaller un code objet modifié sur le Produit Utilisateur (par exemple, le travail a été installé en mémoire morte). L’obligation de fournir les Informations d’Installation n’inclue pas celle de continuer à fournir un service de support, une garantie ou des mises à jour pour un travail qui a été modifié ou installé par le Destinataire, ou pour le Produit Utilisateur dans lequel il a été modifié ou installé. L’accès à un réseau peut être rejeté quand la modification elle-même affecte matériellement et défavorablement les opérations du réseau ou viole les règles et protocoles de communication au travers du réseau. Le Source Correspondant acheminé et les Informations d’Installation fournies, en accord avec cet article, doivent être dans un format publiquement documenté (et dont une implémentation est disponible auprès du public sous forme de code source) et ne doit nécessiter aucune clé ou mot de passe spécial pour le dépaquetage, la lecture ou la copie. Article 7. Termes additionnels. Les « permissions additionelles » désignent les termes qui supplémentent ceux de cette Licence en émettant des exceptions à l’une ou plusieurs de ses conditions. Les permissions additionnelles qui sont applicables au Programme entier doivent être traitées comme si elles étaient incluent dans cette Licence, dans les limites de leur validité suivant la loi applicable. Si des permissions additionnelles s’appliquent seulement à une partie du Programme, cette partie peut être utilisée séparément suivant ces permissions, mais le Programme tout entier reste gouverné par cette Licence sans regard aux permissions additionelles. Quand vous acheminez une copie d’un Travail Couvert, vous pouvez à votre convenance ôter toute permission additionelle de cette copie, ou de n’importe quelle partie de celui-ci. (Des permissions additionnelles peuvent être rédigées de façon à requérir leur propre suppression dans certains cas où vous modifiez le travail.) Vous pouvez placer les permissions additionnelles sur le matériel acheminé, ajoutées par vous à un Travail Couvert pour lequel vous avez ou pouvez donner les permissions de Droit d’Auteur (“copyright”) appropriées. Nonobstant toute autre clause de cette Licence, pour tout constituant que vous ajoutez à un Travail Couvert, vous pouvez (si autorisé par les titulaires de Droit d’Auteur pour ce constituant) supplémenter les termes de cette Licence avec des termes : a) qui rejettent la garantie ou limitent la responsabilité de façon différente des termes des articles 15 et 16 de cette Licence ; ou b) qui requièrent la préservation de notices légales raisonnables spécifiées ou les attributions d’auteur dans ce constituant ou dans les Notices Légales Appropriées affichées par les travaux qui le contiennent ; ou c) qui prohibent la représentation incorrecte de l’origine de ce constituant, ou qui requièrent que les versions modifiées d’un tel constituant soit marquées par des moyens raisonnables comme différentes de la version originale ; ou d) qui limitent l’usage à but publicitaire des noms des concédants de licence et des auteurs du constituant ; ou e) qui refusent à accorder des droits selon la législation relative aux marques commerciales, pour l’utilisation dans des noms commerciaux, marques commerciales ou marques de services ; ou f) qui requièrent l’indemnisation des concédants de licences et auteurs du constituant par quiconque achemine ce constituant (ou des versions modifiées de celui-ci) en assumant contractuellement la responsabilité envers le Destinataire, pour toute responsabilité que ces engagements contractuels imposent directement à ces octroyants de licences et auteurs. Tous les autres termes additionnels non permissifs sont considérés comme des « restrictions avancées » dans le sens de l’article 10. Si le Programme tel que vous l’avez reçu, ou toute partie de celui-ci, contient une notice établissant qu’il est gouverné par cette Licence en même temps qu’un terme qui est une restriction avancée, vous pouvez ôter ce terme. Si un document de licence contient une restriction avancée mais permet la reconcession de licence ou l’acheminement suivant cette Licence, vous pouvez ajouter un Travail Couvert constituant gouverné par les termes de ce document de licence, pourvu que la restriction avancée ne survit pas à un telle cession de licence ou acheminement. Si vous ajoutez des termes à un Travail Couvert en accord avec cet article, vous devez placer, dans les fichiers sources appropriés, une déclaration des termes additionnels qui s’appliquent à ces fichiers, ou une notice indiquant où trouver les termes applicables. Les termes additionnels, qu’ils soient permissifs ou non permissifs, peuvent être établis sous la forme d’une licence écrite séparément, ou établis comme des exceptions ; les obligations ci-dessus s’appliquent dans chacun de ces cas. Article 8. Terminaison. Vous ne pouvez ni propager ni modifier un Travail Couvert autrement que suivant les termes de cette Licence. Toute autre tentative de le propager ou le modifier est nulle et terminera automatiquement vos droits selon cette Licence (y compris toute licence de brevet accordée selon le troisième paragraphe de l’article 11). Cependant, si vous cessez toute violation de cette Licence, alors votre licence depuis un titulaire de Droit d’Auteur (“copyright”) est réinstaurée (a) à titre provisoire à moins que et jusqu’à ce que le titulaire de Droit d’Auteur termine finalement et explicitement votre licence, et (b) de façon permanente si le titulaire de Droit d’Auteur ne parvient pas à vous notifier de la violation par quelque moyen raisonnable dans les soixante (60) jours après la cessation. De plus, votre licence depuis un titulaire particulier de Droit d’Auteur est réinstaurée de façon permanente si ce titulaire vous notifie de la violation par quelque moyen raisonnable, c’est la première fois que vous avez reçu une notification deviolation de cette Licence (pour un travail quelconque) depuis ce titulaire de Droit d’Auteur, et vous résolvez la violation dans les trente (30) jours qui suivent votre réception de la notification. La terminaison de vos droits suivant cette section ne terminera pas les licences des parties qui ont reçu des copies ou droits de votre part suivant cette Licence. Si vos droits ont été terminés et non réinstaurés de façon permanente, vous n’êtes plus qualifié à recevoir de nouvelles licences pour les mêmes constituants selon l’article 10. Article 9. Acceptation non requise pour obtenir des copies. Vous n’êtes pas obligé d’accepter cette licence afin de recevoir ou exécuter une copie du Programme. La propagation asservie d’un Travail Couvert qui se produit simplement en conséquence d’une transmission d’égal-à-égal pour recevoir une copie ne nécessite pas l’acceptation. Cependant, rien d’autre que cette Licence ne vous accorde la permission de propager ou modifier un quelconque Travail Couvert. Ces actions enfreignent le Droit d’Auteur si vous n’acceptez pas cette Licence. Par conséquent, en modifiant ou propageant un Travail Couvert, vous indiquez votre acceptation de cette Licence pour agir ainsi. Article 10. Cession automatique de Licence aux Destinataires et intermédiaires. Chaque fois que vous acheminez un Travail Couvert, le Destinataire reçoit automatiquement une licence depuis les concédants originaux, pour exécuter, modifier et propager ce travail, suivant les termes de cette Licence. Vous n’êtes pas responsable du renforcement de la conformation des tierces parties avec cette Licence. Une « transaction d’entité » désigne une transaction qui transfère le contrôle d’une organisation, ou de substantiellement tous ses actifs, ou la subdivision d’une organisation, ou la fusion de plusieurs organisations. Si la propagation d’un Travail Couvert résulte d’une transaction d’entité, chaque partie à cette transaction qui reçoit une copie du travail reçoit aussi les licences pour le travail que le prédécesseur intéressé à cette partie avait ou pourrait donner selon le paragraphe précédent, plus un droit de possession du Source Correspondant de ce travail depuis le prédécesseur intéressé si ce prédécesseur en dispose ou peut l’obtenir par des efforts raisonnables. Vous ne pouvez imposer aucune restriction avancée dans l’exercice des droits accordés ou affirmés selon cette Licence. Par exemple, vous ne pouvez imposer aucun paiement pour la licence, aucune royaltie, ni aucune autre charge pour l’exercice des droits accordés selon cette Licence ; et vous ne pouvez amorcer aucun litige judiciaire (y compris une réclamation croisée ou contre-réclamation dans un procès) sur l’allégation qu’une revendication de brevet est enfreinte par la réalisation, l’utilisation, la vente, l’offre de vente, ou l’importation du Programme ou d’une quelconque portion de celui-ci. Article 11. Brevets. Un « contributeur » est un titulaire de Droit d’Auteur (“copyright”) qui autorise l’utilisation selon cette Licence du Programme ou du travail sur lequel le Programme est basé. Le travail ainsi soumis à licence est appelé la « version contributive » de ce contributeur. Les « revendications de brevet essentielles » sont toutes les revendications de brevets détenues ou contrôlées par le contributeur, qu’elles soient déjà acquises par lui ou acquises subséquemment, qui pourraient être enfreintes de quelque manière, permises par cette Licence, sur la réalisation, l’utilisation ou la vente de la version contributive de celui-ci. Aux fins de cette définition, le « contrôle » inclue le droit de concéder des sous-licences de brevets d’une manière consistante, nécessaire et suffisante, avec les obligations de cette Licence. Chaque contributeur vous accorde une licence de brevet non exclusive, mondiale et libre de toute royaltie, selon les revendications de brevet essentielles, pour réaliser, utiliser, vendre, offrir à la vente, importer et autrement exécuter, modifier et propager les contenus de sa version contributive. Dans les trois paragraphes suivants, une « licence de brevet » désigne tous les accords ou engagements exprimés, quel que soit le nom que vous lui donnez, de ne pas mettre en vigueur un brevet (telle qu’une permission explicite pour mettre en pratique un brevet, ou un accord pour ne pas poursuivre un Destinataire pour cause de violation de brevet). « Accorder » une telle licence de brevet à une partie signifie conclure un tel accord ou engagement à ne pas faire appliquer le brevet à cette partie. Si vous acheminez un Travail Couvert, dépendant en connaissance d’une licence de brevet, et si le Source Correspondant du travail n’est pas disponible à quiconque copie, sans frais et suivant les termes de cette Licence, à travers un serveur réseau publiquement acessible ou tout autre moyen immédiatement accessible, alors vous devez soit (1) rendre la Source Correspondante ainsi disponible, soit (2) vous engager à vous priver pour vous-même du bénéfice de la licence de brevet pour ce travail particulier, soit (3) vous engager, d’une façon consistante avec les obligations de cette Licence, à étendre la licence de brevet aux Destinataires de ce travail. « Dépendant en connaissance » signifie que vous avez effectivement connaissance que, selon la licence de brevet, votre acheminement du Travail Couvert dans un pays, ou l’utilisation du Travail Couvert par votre Destinataire dans un pays, infreindrait un ou plusieurs brevets identifiables dans ce pays où vous avez des raisons de penser qu’ils sont valides. Si, conformément à ou en liaison avec une même transaction ou un même arrangement, vous acheminez, ou propagez en procurant un acheminement de, un Travail Couvert et accordez une licence de brevet à l’une des parties recevant le Travail Couvert pour lui permettre d’utiliser, propager, modifier ou acheminer une copie spécifique du Travail Couvert, alors votre accord est automatiquement étendu à tous les Destinataires du Travail Couvert et des travaux basés sur celui-ci. Une licence de brevet est « discriminatoire » si, dans le champ de sa couverture, elle n’inclut pas un ou plusieurs des droits qui sont spécifiquement accordés selon cette Licence, ou en prohibe l’exercice, ou est conditionnée par le non-exercice d’un ou plusieurs de ces droits. Vous ne pouvez pas acheminer un Travail Couvert si vous êtes partie à un arrangement selon lequel une partie tierce exerçant son activité dans la distribution de logiciels et à laquelle vous effectuez un paiement fondé sur l’étendue de votre activité d’acheminement du travail, et selon lequel la partie tierce accorde, à une quelconque partie qui recevrait depuis vous le Travail Couvert, une licence de brevet discriminatoire (a) en relation avec les copies du Travail Couvert acheminées par vous (ou les copies réalisées à partir de ces copies), ou (b) avant tout destinée et en relation avec des produits spécifiques ou compilations contenant le Travail Couvert, à moins que vous ayez conclu cet arrangement ou que la licence de brevet ait été accordée avant le 28 mars 2007. Rien dans cette Licence ne devrait être interprété comme devant exclure ou limiter toute licence implicite ou d’autres moyens de défense à une infraction qui vous seraient autrement disponible selon la loi applicable relative aux brevets. Article 12. Non abandon de la liberté des autres. Si des conditions vous sont imposées (que ce soit par décision judiciaire, par un accord ou autrement) qui contredisent les conditions de cette Licence, elles ne vous excusent pas des conditions de cette Licence. Si vous ne pouvez pas acheminer un Travail Couvert de façon à satisfaire simulténément vos obligations suivant cette Licence et toutes autres obligations pertinentes, alors en conséquence vous ne pouvez pas du tout l’acheminer. Par exemple, si vous avez un accord sur des termes qui vous obligent à collecter pour le réacheminement des royalties depuis ceux à qui vous acheminez le Programme, la seule façon qui puisse vous permettre de satisfaire à la fois à ces termes et ceux de cette Licence sera de vous abstenir entièrement d’acheminer le Programme. Article 13. Utilisation avec la Licence Générale Publique Affero GNU. Nonobstant toute autre clause de cette Licence, vous avez la permission de lier ou combiner tout Travail Couvert avec un travail placé sous la version 3 de la Licence Générale Publique GNU Affero (“GNU Affero General Public License”) en un seul travail combiné, et d’acheminer le travail résultant. Les termes de cette Licence continueront à s’appliquer à la partie formant un Travail Couvert, mais les obligations spéciales de la Licence Générale Publique GNU Affero, article 13, concernant l’interaction à travers un réseau s’appliqueront à la combinaison en tant que telle. Article 14. Versions révisées de cette License. La Free Software Foundation peut publier des versions révisées et/ou nouvelles de la Licence Publique Générale GNU (“GNU General Public License”) de temps en temps. De telles version nouvelles resteront similaires dans l’esprit avec la présente version, mais peuvent différer dans le détail afin de traiter de nouveaux problèmes ou préoccupations. Chaque version reçoit un numéro de version distinctif. Si le Programme indique qu’une version spécifique de la Licence Publique Générale GNU « ou toute version ultérieure » (“or any later version”) s’applique à celui-ci, vous avez le choix de suivre soit les termes et conditions de cette version numérotée, soit ceux de n’importe quelle version publiée ultérieurement par la Free Software Foundation. Si le Programme n’indique pas une version spécifique de la Licence Publique Générale GNU, vous pouvez choisir l’une quelconque des versions qui ont été publiées par la Free Software Foundation. Si le Programme spécifie qu’un intermédiaire peut décider quelles versions futures de la Licence Générale Publique GNU peut être utilisée, la déclaration publique d’acceptation d’une version par cet intermédiaire vous autorise à choisir cette version pour le Programme. Des versions ultérieures de la licence peuvent vous donner des permissions additionelles ou différentes. Cependant aucune obligation additionelle n’est imposée à l’un des auteurs ou titulaires de Droit d’Auteur du fait de votre choix de suivre une version ultérieure. Article 15. Déclaration d’absence de garantie. IL N’Y A AUCUNE GARANTIE POUR LE PROGRAMME, DANS LES LIMITES PERMISES PAR LA LOI APPLICABLE. À MOINS QUE CELA NE SOIT ÉTABLI DIFFÉREMMENT PAR ÉCRIT, LES PROPRIÉTAIRES DE DROITS ET/OU LES AUTRES PARTIES FOURNISSENT LE PROGRAMME « EN L’ÉTAT » SANS GARANTIE D’AUCUNE SORTE, QU’ELLE SOIT EXPRIMÉE OU IMPLICITE, CECI COMPRENANT, SANS SE LIMITER À CELLES-CI, LES GARANTIES IMPLICITES DE COMMERCIALISABILITÉ ET D’ADÉQUATION À UN OBJECTIF PARTICULIER. VOUS ASSUMEZ LE RISQUE ENTIER CONCERNANT LA QUALITÉ ET LES PERFORMANCES DU PROGRAMME. DANS L’ÉVENTUALITÉ OÙ LE PROGRAMME S’AVÉRERAIT DÉFECTUEUX, VOUS ASSUMEZ LES COÛTS DE TOUS LES SERVICES, RÉPARATIONS OU CORRECTIONS NÉCESSAIRES. Article 16. Limitation de responsabilité. EN AUCUNE AUTRE CIRCONSTANCE QUE CELLES REQUISES PAR LA LOI APPLICABLE OU ACCORDÉES PAR ÉCRIT, UN TITULAIRE DE DROITS SUR LE PROGRAMME, OU TOUT AUTRE PARTIE QUI MODIFIE OU ACHEMINE LE PROGRAMME COMME PERMIS CI-DESSUS, NE PEUT ÊTRE TENU POUR RESPONSABLE ENVERS VOUS POUR LES DOMMAGES, INCLUANT TOUT DOMMAGE GÉNÉRAL, SPÉCIAL, ACCIDENTEL OU INDUIT SURVENANT PAR SUITE DE L’UTILISATION OU DE L’INCAPACITÉ D’UTILISER LE PROGRAMME (Y COMPRIS, SANS SE LIMITER À CELLES-CI, LA PERTE DE DONNÉES OU L’INEXACTITUDE DES DONNÉES RETOURNÉES OU LES PERTES SUBIES PAR VOUS OU DES PARTIES TIERCES OU L’INCAPACITÉ DU PROGRAMME À FONCTIONNER AVEC TOUT AUTRE PROGRAMME), MÊME SI UN TEL TITULAIRE OU TOUTE AUTRE PARTIE A ÉTÉ AVISÉ DE LA POSSIBILITÉ DE TELS DOMMAGES. Article 17. Interprétation des sections 15 et 16. Si la déclaration d’absence de garantie et la limitation de responsabilité fournies ci-dessus ne peuvent prendre effet localement selon leurs termes, les cours de justice qui les examinent doivent appliquer la législation locale qui approche au plus près possible une levée absolue de toute responsabilité civile liée au Programme, à moins qu’une garantie ou assumation de responsabilité accompagne une copie du Programme en échange d’un paiement. FIN DES TERMES ET CONDITIONS. _______________________________________________________________________ Comment appliquer ces termes à vos nouveaux programmes Si vous développez un nouveau programme et voulez qu’il soit le plus possible utilisable par le public, la meilleure façon d’y parvenir et d’en faire un logiciel libre que chacun peut redistribuer et changer suivant ces termes-ci. Pour appliquer ces termes, attachez les notices suivantes au programme. Il est plus sûr de les attacher au début de chacun des fichiers sources afin de transporter de façon la plus effective possible l’exclusion de garantie ; et chaque fichier devrait comporter au moins la ligne de réservation de droit (“copyright”) et une indication permettant de savoir où la notice complète peut être trouvée : Copyright (C) — Tous droits réservés. Ce programme est un logiciel libre ; vous pouvez le redistribuer ou le modifier suivant les termes de la “GNU General Public License” telle que publiée par la Free Software Foundation : soit la version 3 de cette licence, soit (à votre gré) toute version ultérieure. Ce programme est distribué dans l’espoir qu’il vous sera utile, mais SANS AUCUNE GARANTIE : sans même la garantie implicite de COMMERCIALISABILITÉ ni d’ADÉQUATION À UN OBJECTIF PARTICULIER. Consultez la Licence Générale Publique GNU pour plus de détails. Vous devriez avoir reçu une copie de la Licence Générale Publique GNU avec ce programme ; si ce n’est pas le cas, consultez : . Ajoutez également les informations permettant de vous contacter par courrier électronique ou postal. Si le programme produit une interaction sur un terminal, faites lui afficher une courte notice comme celle-ci lors de son démarrage en mode interactif : Copyright (C) Ce programme vient SANS ABSOLUMENT AUCUNE GARANTIE ; taper “affiche g” pour les détails. Ceci est un logiciel libre et vous êtes invité à le redistribuer suivant certaines conditions ; taper “affiche c” pour les détails. Les commandes hypothétiques “affiche g” and “affiche c” devrait afficher les parties appropriées de la Licence Générale Publique. Bien sûr, les commandes de votre programme peuvent être différentes ; pour une interface graphique, vous pourriez utiliser une « boîte À propos. » Vous devriez également obtenir de votre employeur (si vous travaillez en tant que programmeur) ou de votre école un « renoncement aux droits de propriété » pour ce programme, si nécessaire. Pour plus d’informations à ce sujet, et comment appliquer la GPL GNU, consultez . La Licence Générale Publique GNU ne permet pas d’incorporer votre programme dans des programmes propriétaires. Si votre programme est une bibliothèque de sous-routines, vous pourriez considérer qu’il serait plus utile de permettre de lier des applications propriétaires avec la bibliothèque. Si c’est ce que vous voulez faire, utilisez la Licence Générale Publique Limitée GNU au lieu de cette Licence ; mais d’abord, veuillez lire . _______________________________________________________________________ httrack-3.49.5/INSTALL.Linux0000644000175000017500000000052614336470674012345 00000000000000HTTrack Website Copier - Install notes -------------------------------------- On most systems (including GNU/Linux), installing can be easily achieved using the following command: ./configure && make && make install -or- (if not compiling as root) ./configure --prefix=$HOME && make && make install See also the INSTALL generic help file. httrack-3.49.5/missing0000755000175000017500000001533614555203165011612 00000000000000#! /bin/sh # Common wrapper for a few potentially missing GNU programs. scriptversion=2018-03-07.03; # UTC # Copyright (C) 1996-2021 Free Software Foundation, Inc. # Originally written by Fran,cois Pinard , 1996. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2, or (at your option) # any later version. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # You should have received a copy of the GNU General Public License # along with this program. If not, see . # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. if test $# -eq 0; then echo 1>&2 "Try '$0 --help' for more information" exit 1 fi case $1 in --is-lightweight) # Used by our autoconf macros to check whether the available missing # script is modern enough. exit 0 ;; --run) # Back-compat with the calling convention used by older automake. shift ;; -h|--h|--he|--hel|--help) echo "\ $0 [OPTION]... PROGRAM [ARGUMENT]... Run 'PROGRAM [ARGUMENT]...', returning a proper advice when this fails due to PROGRAM being missing or too old. Options: -h, --help display this help and exit -v, --version output version information and exit Supported PROGRAM values: aclocal autoconf autoheader autom4te automake makeinfo bison yacc flex lex help2man Version suffixes to PROGRAM as well as the prefixes 'gnu-', 'gnu', and 'g' are ignored when checking the name. Send bug reports to ." exit $? ;; -v|--v|--ve|--ver|--vers|--versi|--versio|--version) echo "missing $scriptversion (GNU Automake)" exit $? ;; -*) echo 1>&2 "$0: unknown '$1' option" echo 1>&2 "Try '$0 --help' for more information" exit 1 ;; esac # Run the given program, remember its exit status. "$@"; st=$? # If it succeeded, we are done. test $st -eq 0 && exit 0 # Also exit now if we it failed (or wasn't found), and '--version' was # passed; such an option is passed most likely to detect whether the # program is present and works. case $2 in --version|--help) exit $st;; esac # Exit code 63 means version mismatch. This often happens when the user # tries to use an ancient version of a tool on a file that requires a # minimum version. if test $st -eq 63; then msg="probably too old" elif test $st -eq 127; then # Program was missing. msg="missing on your system" else # Program was found and executed, but failed. Give up. exit $st fi perl_URL=https://www.perl.org/ flex_URL=https://github.com/westes/flex gnu_software_URL=https://www.gnu.org/software program_details () { case $1 in aclocal|automake) echo "The '$1' program is part of the GNU Automake package:" echo "<$gnu_software_URL/automake>" echo "It also requires GNU Autoconf, GNU m4 and Perl in order to run:" echo "<$gnu_software_URL/autoconf>" echo "<$gnu_software_URL/m4/>" echo "<$perl_URL>" ;; autoconf|autom4te|autoheader) echo "The '$1' program is part of the GNU Autoconf package:" echo "<$gnu_software_URL/autoconf/>" echo "It also requires GNU m4 and Perl in order to run:" echo "<$gnu_software_URL/m4/>" echo "<$perl_URL>" ;; esac } give_advice () { # Normalize program name to check for. normalized_program=`echo "$1" | sed ' s/^gnu-//; t s/^gnu//; t s/^g//; t'` printf '%s\n' "'$1' is $msg." configure_deps="'configure.ac' or m4 files included by 'configure.ac'" case $normalized_program in autoconf*) echo "You should only need it if you modified 'configure.ac'," echo "or m4 files included by it." program_details 'autoconf' ;; autoheader*) echo "You should only need it if you modified 'acconfig.h' or" echo "$configure_deps." program_details 'autoheader' ;; automake*) echo "You should only need it if you modified 'Makefile.am' or" echo "$configure_deps." program_details 'automake' ;; aclocal*) echo "You should only need it if you modified 'acinclude.m4' or" echo "$configure_deps." program_details 'aclocal' ;; autom4te*) echo "You might have modified some maintainer files that require" echo "the 'autom4te' program to be rebuilt." program_details 'autom4te' ;; bison*|yacc*) echo "You should only need it if you modified a '.y' file." echo "You may want to install the GNU Bison package:" echo "<$gnu_software_URL/bison/>" ;; lex*|flex*) echo "You should only need it if you modified a '.l' file." echo "You may want to install the Fast Lexical Analyzer package:" echo "<$flex_URL>" ;; help2man*) echo "You should only need it if you modified a dependency" \ "of a man page." echo "You may want to install the GNU Help2man package:" echo "<$gnu_software_URL/help2man/>" ;; makeinfo*) echo "You should only need it if you modified a '.texi' file, or" echo "any other file indirectly affecting the aspect of the manual." echo "You might want to install the Texinfo package:" echo "<$gnu_software_URL/texinfo/>" echo "The spurious makeinfo call might also be the consequence of" echo "using a buggy 'make' (AIX, DU, IRIX), in which case you might" echo "want to install GNU make:" echo "<$gnu_software_URL/make/>" ;; *) echo "You might have modified some files without having the proper" echo "tools for further handling them. Check the 'README' file, it" echo "often tells you about the needed prerequisites for installing" echo "this package. You may also peek at any GNU archive site, in" echo "case some other package contains this missing '$1' program." ;; esac } give_advice "$1" | sed -e '1s/^/WARNING: /' \ -e '2,$s/^/ /' >&2 # Propagate the correct exit status (expected to be 127 for a program # not found, 63 for a program that failed due to version mismatch). exit $st # Local variables: # eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" # time-stamp-end: "; # UTC" # End: httrack-3.49.5/ltmain.sh0000755000175000017500000121320114555203162012023 00000000000000#! /usr/bin/env sh ## DO NOT EDIT - This file generated from ./build-aux/ltmain.in ## by inline-source v2019-02-19.15 # libtool (GNU libtool) 2.4.7 # Provide generalized library-building support services. # Written by Gordon Matzigkeit , 1996 # Copyright (C) 1996-2019, 2021-2022 Free Software Foundation, Inc. # This is free software; see the source for copying conditions. There is NO # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. # GNU Libtool is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # As a special exception to the GNU General Public License, # if you distribute this file as part of a program or library that # is built using GNU Libtool, you may include this file under the # same distribution terms that you use for the rest of that program. # # GNU Libtool is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see . PROGRAM=libtool PACKAGE=libtool VERSION="2.4.7 Debian-2.4.7-5" package_revision=2.4.7 ## ------ ## ## Usage. ## ## ------ ## # Run './libtool --help' for help with using this script from the # command line. ## ------------------------------- ## ## User overridable command paths. ## ## ------------------------------- ## # After configure completes, it has a better idea of some of the # shell tools we need than the defaults used by the functions shared # with bootstrap, so set those here where they can still be over- # ridden by the user, but otherwise take precedence. : ${AUTOCONF="autoconf"} : ${AUTOMAKE="automake"} ## -------------------------- ## ## Source external libraries. ## ## -------------------------- ## # Much of our low-level functionality needs to be sourced from external # libraries, which are installed to $pkgauxdir. # Set a version string for this script. scriptversion=2019-02-19.15; # UTC # General shell script boiler plate, and helper functions. # Written by Gary V. Vaughan, 2004 # This is free software. There is NO warranty; not even for # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. # # Copyright (C) 2004-2019, 2021 Bootstrap Authors # # This file is dual licensed under the terms of the MIT license # , and GPL version 2 or later # . You must apply one of # these licenses when using or redistributing this software or any of # the files within it. See the URLs above, or the file `LICENSE` # included in the Bootstrap distribution for the full license texts. # Please report bugs or propose patches to: # ## ------ ## ## Usage. ## ## ------ ## # Evaluate this file near the top of your script to gain access to # the functions and variables defined here: # # . `echo "$0" | ${SED-sed} 's|[^/]*$||'`/build-aux/funclib.sh # # If you need to override any of the default environment variable # settings, do that before evaluating this file. ## -------------------- ## ## Shell normalisation. ## ## -------------------- ## # Some shells need a little help to be as Bourne compatible as possible. # Before doing anything else, make sure all that help has been provided! DUALCASE=1; export DUALCASE # for MKS sh if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in *posix*) set -o posix ;; esac fi # NLS nuisances: We save the old values in case they are required later. _G_user_locale= _G_safe_locale= for _G_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES do eval "if test set = \"\${$_G_var+set}\"; then save_$_G_var=\$$_G_var $_G_var=C export $_G_var _G_user_locale=\"$_G_var=\\\$save_\$_G_var; \$_G_user_locale\" _G_safe_locale=\"$_G_var=C; \$_G_safe_locale\" fi" done # These NLS vars are set unconditionally (bootstrap issue #24). Unset those # in case the environment reset is needed later and the $save_* variant is not # defined (see the code above). LC_ALL=C LANGUAGE=C export LANGUAGE LC_ALL # Make sure IFS has a sensible default sp=' ' nl=' ' IFS="$sp $nl" # There are apparently some retarded systems that use ';' as a PATH separator! if test "${PATH_SEPARATOR+set}" != set; then PATH_SEPARATOR=: (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || PATH_SEPARATOR=';' } fi # func_unset VAR # -------------- # Portably unset VAR. # In some shells, an 'unset VAR' statement leaves a non-zero return # status if VAR is already unset, which might be problematic if the # statement is used at the end of a function (thus poisoning its return # value) or when 'set -e' is active (causing even a spurious abort of # the script in this case). func_unset () { { eval $1=; (eval unset $1) >/dev/null 2>&1 && eval unset $1 || : ; } } # Make sure CDPATH doesn't cause `cd` commands to output the target dir. func_unset CDPATH # Make sure ${,E,F}GREP behave sanely. func_unset GREP_OPTIONS ## ------------------------- ## ## Locate command utilities. ## ## ------------------------- ## # func_executable_p FILE # ---------------------- # Check that FILE is an executable regular file. func_executable_p () { test -f "$1" && test -x "$1" } # func_path_progs PROGS_LIST CHECK_FUNC [PATH] # -------------------------------------------- # Search for either a program that responds to --version with output # containing "GNU", or else returned by CHECK_FUNC otherwise, by # trying all the directories in PATH with each of the elements of # PROGS_LIST. # # CHECK_FUNC should accept the path to a candidate program, and # set $func_check_prog_result if it truncates its output less than # $_G_path_prog_max characters. func_path_progs () { _G_progs_list=$1 _G_check_func=$2 _G_PATH=${3-"$PATH"} _G_path_prog_max=0 _G_path_prog_found=false _G_save_IFS=$IFS; IFS=${PATH_SEPARATOR-:} for _G_dir in $_G_PATH; do IFS=$_G_save_IFS test -z "$_G_dir" && _G_dir=. for _G_prog_name in $_G_progs_list; do for _exeext in '' .EXE; do _G_path_prog=$_G_dir/$_G_prog_name$_exeext func_executable_p "$_G_path_prog" || continue case `"$_G_path_prog" --version 2>&1` in *GNU*) func_path_progs_result=$_G_path_prog _G_path_prog_found=: ;; *) $_G_check_func $_G_path_prog func_path_progs_result=$func_check_prog_result ;; esac $_G_path_prog_found && break 3 done done done IFS=$_G_save_IFS test -z "$func_path_progs_result" && { echo "no acceptable sed could be found in \$PATH" >&2 exit 1 } } # We want to be able to use the functions in this file before configure # has figured out where the best binaries are kept, which means we have # to search for them ourselves - except when the results are already set # where we skip the searches. # Unless the user overrides by setting SED, search the path for either GNU # sed, or the sed that truncates its output the least. test -z "$SED" && { _G_sed_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ for _G_i in 1 2 3 4 5 6 7; do _G_sed_script=$_G_sed_script$nl$_G_sed_script done echo "$_G_sed_script" 2>/dev/null | sed 99q >conftest.sed _G_sed_script= func_check_prog_sed () { _G_path_prog=$1 _G_count=0 printf 0123456789 >conftest.in while : do cat conftest.in conftest.in >conftest.tmp mv conftest.tmp conftest.in cp conftest.in conftest.nl echo '' >> conftest.nl "$_G_path_prog" -f conftest.sed conftest.out 2>/dev/null || break diff conftest.out conftest.nl >/dev/null 2>&1 || break _G_count=`expr $_G_count + 1` if test "$_G_count" -gt "$_G_path_prog_max"; then # Best one so far, save it but keep looking for a better one func_check_prog_result=$_G_path_prog _G_path_prog_max=$_G_count fi # 10*(2^10) chars as input seems more than enough test 10 -lt "$_G_count" && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out } func_path_progs "sed gsed" func_check_prog_sed "$PATH:/usr/xpg4/bin" rm -f conftest.sed SED=$func_path_progs_result } # Unless the user overrides by setting GREP, search the path for either GNU # grep, or the grep that truncates its output the least. test -z "$GREP" && { func_check_prog_grep () { _G_path_prog=$1 _G_count=0 _G_path_prog_max=0 printf 0123456789 >conftest.in while : do cat conftest.in conftest.in >conftest.tmp mv conftest.tmp conftest.in cp conftest.in conftest.nl echo 'GREP' >> conftest.nl "$_G_path_prog" -e 'GREP$' -e '-(cannot match)-' conftest.out 2>/dev/null || break diff conftest.out conftest.nl >/dev/null 2>&1 || break _G_count=`expr $_G_count + 1` if test "$_G_count" -gt "$_G_path_prog_max"; then # Best one so far, save it but keep looking for a better one func_check_prog_result=$_G_path_prog _G_path_prog_max=$_G_count fi # 10*(2^10) chars as input seems more than enough test 10 -lt "$_G_count" && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out } func_path_progs "grep ggrep" func_check_prog_grep "$PATH:/usr/xpg4/bin" GREP=$func_path_progs_result } ## ------------------------------- ## ## User overridable command paths. ## ## ------------------------------- ## # All uppercase variable names are used for environment variables. These # variables can be overridden by the user before calling a script that # uses them if a suitable command of that name is not already available # in the command search PATH. : ${CP="cp -f"} : ${ECHO="printf %s\n"} : ${EGREP="$GREP -E"} : ${FGREP="$GREP -F"} : ${LN_S="ln -s"} : ${MAKE="make"} : ${MKDIR="mkdir"} : ${MV="mv -f"} : ${RM="rm -f"} : ${SHELL="${CONFIG_SHELL-/bin/sh}"} ## -------------------- ## ## Useful sed snippets. ## ## -------------------- ## sed_dirname='s|/[^/]*$||' sed_basename='s|^.*/||' # Sed substitution that helps us do robust quoting. It backslashifies # metacharacters that are still active within double-quoted strings. sed_quote_subst='s|\([`"$\\]\)|\\\1|g' # Same as above, but do not quote variable references. sed_double_quote_subst='s/\(["`\\]\)/\\\1/g' # Sed substitution that turns a string into a regex matching for the # string literally. sed_make_literal_regex='s|[].[^$\\*\/]|\\&|g' # Sed substitution that converts a w32 file name or path # that contains forward slashes, into one that contains # (escaped) backslashes. A very naive implementation. sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g' # Re-'\' parameter expansions in output of sed_double_quote_subst that # were '\'-ed in input to the same. If an odd number of '\' preceded a # '$' in input to sed_double_quote_subst, that '$' was protected from # expansion. Since each input '\' is now two '\'s, look for any number # of runs of four '\'s followed by two '\'s and then a '$'. '\' that '$'. _G_bs='\\' _G_bs2='\\\\' _G_bs4='\\\\\\\\' _G_dollar='\$' sed_double_backslash="\ s/$_G_bs4/&\\ /g s/^$_G_bs2$_G_dollar/$_G_bs&/ s/\\([^$_G_bs]\\)$_G_bs2$_G_dollar/\\1$_G_bs2$_G_bs$_G_dollar/g s/\n//g" # require_check_ifs_backslash # --------------------------- # Check if we can use backslash as IFS='\' separator, and set # $check_ifs_backshlash_broken to ':' or 'false'. require_check_ifs_backslash=func_require_check_ifs_backslash func_require_check_ifs_backslash () { _G_save_IFS=$IFS IFS='\' _G_check_ifs_backshlash='a\\b' for _G_i in $_G_check_ifs_backshlash do case $_G_i in a) check_ifs_backshlash_broken=false ;; '') break ;; *) check_ifs_backshlash_broken=: break ;; esac done IFS=$_G_save_IFS require_check_ifs_backslash=: } ## ----------------- ## ## Global variables. ## ## ----------------- ## # Except for the global variables explicitly listed below, the following # functions in the '^func_' namespace, and the '^require_' namespace # variables initialised in the 'Resource management' section, sourcing # this file will not pollute your global namespace with anything # else. There's no portable way to scope variables in Bourne shell # though, so actually running these functions will sometimes place # results into a variable named after the function, and often use # temporary variables in the '^_G_' namespace. If you are careful to # avoid using those namespaces casually in your sourcing script, things # should continue to work as you expect. And, of course, you can freely # overwrite any of the functions or variables defined here before # calling anything to customize them. EXIT_SUCCESS=0 EXIT_FAILURE=1 EXIT_MISMATCH=63 # $? = 63 is used to indicate version mismatch to missing. EXIT_SKIP=77 # $? = 77 is used to indicate a skipped test to automake. # Allow overriding, eg assuming that you follow the convention of # putting '$debug_cmd' at the start of all your functions, you can get # bash to show function call trace with: # # debug_cmd='echo "${FUNCNAME[0]} $*" >&2' bash your-script-name debug_cmd=${debug_cmd-":"} exit_cmd=: # By convention, finish your script with: # # exit $exit_status # # so that you can set exit_status to non-zero if you want to indicate # something went wrong during execution without actually bailing out at # the point of failure. exit_status=$EXIT_SUCCESS # Work around backward compatibility issue on IRIX 6.5. On IRIX 6.4+, sh # is ksh but when the shell is invoked as "sh" and the current value of # the _XPG environment variable is not equal to 1 (one), the special # positional parameter $0, within a function call, is the name of the # function. progpath=$0 # The name of this program. progname=`$ECHO "$progpath" |$SED "$sed_basename"` # Make sure we have an absolute progpath for reexecution: case $progpath in [\\/]*|[A-Za-z]:\\*) ;; *[\\/]*) progdir=`$ECHO "$progpath" |$SED "$sed_dirname"` progdir=`cd "$progdir" && pwd` progpath=$progdir/$progname ;; *) _G_IFS=$IFS IFS=${PATH_SEPARATOR-:} for progdir in $PATH; do IFS=$_G_IFS test -x "$progdir/$progname" && break done IFS=$_G_IFS test -n "$progdir" || progdir=`pwd` progpath=$progdir/$progname ;; esac ## ----------------- ## ## Standard options. ## ## ----------------- ## # The following options affect the operation of the functions defined # below, and should be set appropriately depending on run-time para- # meters passed on the command line. opt_dry_run=false opt_quiet=false opt_verbose=false # Categories 'all' and 'none' are always available. Append any others # you will pass as the first argument to func_warning from your own # code. warning_categories= # By default, display warnings according to 'opt_warning_types'. Set # 'warning_func' to ':' to elide all warnings, or func_fatal_error to # treat the next displayed warning as a fatal error. warning_func=func_warn_and_continue # Set to 'all' to display all warnings, 'none' to suppress all # warnings, or a space delimited list of some subset of # 'warning_categories' to display only the listed warnings. opt_warning_types=all ## -------------------- ## ## Resource management. ## ## -------------------- ## # This section contains definitions for functions that each ensure a # particular resource (a file, or a non-empty configuration variable for # example) is available, and if appropriate to extract default values # from pertinent package files. Call them using their associated # 'require_*' variable to ensure that they are executed, at most, once. # # It's entirely deliberate that calling these functions can set # variables that don't obey the namespace limitations obeyed by the rest # of this file, in order that that they be as useful as possible to # callers. # require_term_colors # ------------------- # Allow display of bold text on terminals that support it. require_term_colors=func_require_term_colors func_require_term_colors () { $debug_cmd test -t 1 && { # COLORTERM and USE_ANSI_COLORS environment variables take # precedence, because most terminfo databases neglect to describe # whether color sequences are supported. test -n "${COLORTERM+set}" && : ${USE_ANSI_COLORS="1"} if test 1 = "$USE_ANSI_COLORS"; then # Standard ANSI escape sequences tc_reset='' tc_bold=''; tc_standout='' tc_red=''; tc_green='' tc_blue=''; tc_cyan='' else # Otherwise trust the terminfo database after all. test -n "`tput sgr0 2>/dev/null`" && { tc_reset=`tput sgr0` test -n "`tput bold 2>/dev/null`" && tc_bold=`tput bold` tc_standout=$tc_bold test -n "`tput smso 2>/dev/null`" && tc_standout=`tput smso` test -n "`tput setaf 1 2>/dev/null`" && tc_red=`tput setaf 1` test -n "`tput setaf 2 2>/dev/null`" && tc_green=`tput setaf 2` test -n "`tput setaf 4 2>/dev/null`" && tc_blue=`tput setaf 4` test -n "`tput setaf 5 2>/dev/null`" && tc_cyan=`tput setaf 5` } fi } require_term_colors=: } ## ----------------- ## ## Function library. ## ## ----------------- ## # This section contains a variety of useful functions to call in your # scripts. Take note of the portable wrappers for features provided by # some modern shells, which will fall back to slower equivalents on # less featureful shells. # func_append VAR VALUE # --------------------- # Append VALUE onto the existing contents of VAR. # We should try to minimise forks, especially on Windows where they are # unreasonably slow, so skip the feature probes when bash or zsh are # being used: if test set = "${BASH_VERSION+set}${ZSH_VERSION+set}"; then : ${_G_HAVE_ARITH_OP="yes"} : ${_G_HAVE_XSI_OPS="yes"} # The += operator was introduced in bash 3.1 case $BASH_VERSION in [12].* | 3.0 | 3.0*) ;; *) : ${_G_HAVE_PLUSEQ_OP="yes"} ;; esac fi # _G_HAVE_PLUSEQ_OP # Can be empty, in which case the shell is probed, "yes" if += is # useable or anything else if it does not work. test -z "$_G_HAVE_PLUSEQ_OP" \ && (eval 'x=a; x+=" b"; test "a b" = "$x"') 2>/dev/null \ && _G_HAVE_PLUSEQ_OP=yes if test yes = "$_G_HAVE_PLUSEQ_OP" then # This is an XSI compatible shell, allowing a faster implementation... eval 'func_append () { $debug_cmd eval "$1+=\$2" }' else # ...otherwise fall back to using expr, which is often a shell builtin. func_append () { $debug_cmd eval "$1=\$$1\$2" } fi # func_append_quoted VAR VALUE # ---------------------------- # Quote VALUE and append to the end of shell variable VAR, separated # by a space. if test yes = "$_G_HAVE_PLUSEQ_OP"; then eval 'func_append_quoted () { $debug_cmd func_quote_arg pretty "$2" eval "$1+=\\ \$func_quote_arg_result" }' else func_append_quoted () { $debug_cmd func_quote_arg pretty "$2" eval "$1=\$$1\\ \$func_quote_arg_result" } fi # func_append_uniq VAR VALUE # -------------------------- # Append unique VALUE onto the existing contents of VAR, assuming # entries are delimited by the first character of VALUE. For example: # # func_append_uniq options " --another-option option-argument" # # will only append to $options if " --another-option option-argument " # is not already present somewhere in $options already (note spaces at # each end implied by leading space in second argument). func_append_uniq () { $debug_cmd eval _G_current_value='`$ECHO $'$1'`' _G_delim=`expr "$2" : '\(.\)'` case $_G_delim$_G_current_value$_G_delim in *"$2$_G_delim"*) ;; *) func_append "$@" ;; esac } # func_arith TERM... # ------------------ # Set func_arith_result to the result of evaluating TERMs. test -z "$_G_HAVE_ARITH_OP" \ && (eval 'test 2 = $(( 1 + 1 ))') 2>/dev/null \ && _G_HAVE_ARITH_OP=yes if test yes = "$_G_HAVE_ARITH_OP"; then eval 'func_arith () { $debug_cmd func_arith_result=$(( $* )) }' else func_arith () { $debug_cmd func_arith_result=`expr "$@"` } fi # func_basename FILE # ------------------ # Set func_basename_result to FILE with everything up to and including # the last / stripped. if test yes = "$_G_HAVE_XSI_OPS"; then # If this shell supports suffix pattern removal, then use it to avoid # forking. Hide the definitions single quotes in case the shell chokes # on unsupported syntax... _b='func_basename_result=${1##*/}' _d='case $1 in */*) func_dirname_result=${1%/*}$2 ;; * ) func_dirname_result=$3 ;; esac' else # ...otherwise fall back to using sed. _b='func_basename_result=`$ECHO "$1" |$SED "$sed_basename"`' _d='func_dirname_result=`$ECHO "$1" |$SED "$sed_dirname"` if test "X$func_dirname_result" = "X$1"; then func_dirname_result=$3 else func_append func_dirname_result "$2" fi' fi eval 'func_basename () { $debug_cmd '"$_b"' }' # func_dirname FILE APPEND NONDIR_REPLACEMENT # ------------------------------------------- # Compute the dirname of FILE. If nonempty, add APPEND to the result, # otherwise set result to NONDIR_REPLACEMENT. eval 'func_dirname () { $debug_cmd '"$_d"' }' # func_dirname_and_basename FILE APPEND NONDIR_REPLACEMENT # -------------------------------------------------------- # Perform func_basename and func_dirname in a single function # call: # dirname: Compute the dirname of FILE. If nonempty, # add APPEND to the result, otherwise set result # to NONDIR_REPLACEMENT. # value returned in "$func_dirname_result" # basename: Compute filename of FILE. # value retuned in "$func_basename_result" # For efficiency, we do not delegate to the functions above but instead # duplicate the functionality here. eval 'func_dirname_and_basename () { $debug_cmd '"$_b"' '"$_d"' }' # func_echo ARG... # ---------------- # Echo program name prefixed message. func_echo () { $debug_cmd _G_message=$* func_echo_IFS=$IFS IFS=$nl for _G_line in $_G_message; do IFS=$func_echo_IFS $ECHO "$progname: $_G_line" done IFS=$func_echo_IFS } # func_echo_all ARG... # -------------------- # Invoke $ECHO with all args, space-separated. func_echo_all () { $ECHO "$*" } # func_echo_infix_1 INFIX ARG... # ------------------------------ # Echo program name, followed by INFIX on the first line, with any # additional lines not showing INFIX. func_echo_infix_1 () { $debug_cmd $require_term_colors _G_infix=$1; shift _G_indent=$_G_infix _G_prefix="$progname: $_G_infix: " _G_message=$* # Strip color escape sequences before counting printable length for _G_tc in "$tc_reset" "$tc_bold" "$tc_standout" "$tc_red" "$tc_green" "$tc_blue" "$tc_cyan" do test -n "$_G_tc" && { _G_esc_tc=`$ECHO "$_G_tc" | $SED "$sed_make_literal_regex"` _G_indent=`$ECHO "$_G_indent" | $SED "s|$_G_esc_tc||g"` } done _G_indent="$progname: "`echo "$_G_indent" | $SED 's|.| |g'`" " ## exclude from sc_prohibit_nested_quotes func_echo_infix_1_IFS=$IFS IFS=$nl for _G_line in $_G_message; do IFS=$func_echo_infix_1_IFS $ECHO "$_G_prefix$tc_bold$_G_line$tc_reset" >&2 _G_prefix=$_G_indent done IFS=$func_echo_infix_1_IFS } # func_error ARG... # ----------------- # Echo program name prefixed message to standard error. func_error () { $debug_cmd $require_term_colors func_echo_infix_1 " $tc_standout${tc_red}error$tc_reset" "$*" >&2 } # func_fatal_error ARG... # ----------------------- # Echo program name prefixed message to standard error, and exit. func_fatal_error () { $debug_cmd func_error "$*" exit $EXIT_FAILURE } # func_grep EXPRESSION FILENAME # ----------------------------- # Check whether EXPRESSION matches any line of FILENAME, without output. func_grep () { $debug_cmd $GREP "$1" "$2" >/dev/null 2>&1 } # func_len STRING # --------------- # Set func_len_result to the length of STRING. STRING may not # start with a hyphen. test -z "$_G_HAVE_XSI_OPS" \ && (eval 'x=a/b/c; test 5aa/bb/cc = "${#x}${x%%/*}${x%/*}${x#*/}${x##*/}"') 2>/dev/null \ && _G_HAVE_XSI_OPS=yes if test yes = "$_G_HAVE_XSI_OPS"; then eval 'func_len () { $debug_cmd func_len_result=${#1} }' else func_len () { $debug_cmd func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len` } fi # func_mkdir_p DIRECTORY-PATH # --------------------------- # Make sure the entire path to DIRECTORY-PATH is available. func_mkdir_p () { $debug_cmd _G_directory_path=$1 _G_dir_list= if test -n "$_G_directory_path" && test : != "$opt_dry_run"; then # Protect directory names starting with '-' case $_G_directory_path in -*) _G_directory_path=./$_G_directory_path ;; esac # While some portion of DIR does not yet exist... while test ! -d "$_G_directory_path"; do # ...make a list in topmost first order. Use a colon delimited # list incase some portion of path contains whitespace. _G_dir_list=$_G_directory_path:$_G_dir_list # If the last portion added has no slash in it, the list is done case $_G_directory_path in */*) ;; *) break ;; esac # ...otherwise throw away the child directory and loop _G_directory_path=`$ECHO "$_G_directory_path" | $SED -e "$sed_dirname"` done _G_dir_list=`$ECHO "$_G_dir_list" | $SED 's|:*$||'` func_mkdir_p_IFS=$IFS; IFS=: for _G_dir in $_G_dir_list; do IFS=$func_mkdir_p_IFS # mkdir can fail with a 'File exist' error if two processes # try to create one of the directories concurrently. Don't # stop in that case! $MKDIR "$_G_dir" 2>/dev/null || : done IFS=$func_mkdir_p_IFS # Bail out if we (or some other process) failed to create a directory. test -d "$_G_directory_path" || \ func_fatal_error "Failed to create '$1'" fi } # func_mktempdir [BASENAME] # ------------------------- # Make a temporary directory that won't clash with other running # libtool processes, and avoids race conditions if possible. If # given, BASENAME is the basename for that directory. func_mktempdir () { $debug_cmd _G_template=${TMPDIR-/tmp}/${1-$progname} if test : = "$opt_dry_run"; then # Return a directory name, but don't create it in dry-run mode _G_tmpdir=$_G_template-$$ else # If mktemp works, use that first and foremost _G_tmpdir=`mktemp -d "$_G_template-XXXXXXXX" 2>/dev/null` if test ! -d "$_G_tmpdir"; then # Failing that, at least try and use $RANDOM to avoid a race _G_tmpdir=$_G_template-${RANDOM-0}$$ func_mktempdir_umask=`umask` umask 0077 $MKDIR "$_G_tmpdir" umask $func_mktempdir_umask fi # If we're not in dry-run mode, bomb out on failure test -d "$_G_tmpdir" || \ func_fatal_error "cannot create temporary directory '$_G_tmpdir'" fi $ECHO "$_G_tmpdir" } # func_normal_abspath PATH # ------------------------ # Remove doubled-up and trailing slashes, "." path components, # and cancel out any ".." path components in PATH after making # it an absolute path. func_normal_abspath () { $debug_cmd # These SED scripts presuppose an absolute path with a trailing slash. _G_pathcar='s|^/\([^/]*\).*$|\1|' _G_pathcdr='s|^/[^/]*||' _G_removedotparts=':dotsl s|/\./|/|g t dotsl s|/\.$|/|' _G_collapseslashes='s|/\{1,\}|/|g' _G_finalslash='s|/*$|/|' # Start from root dir and reassemble the path. func_normal_abspath_result= func_normal_abspath_tpath=$1 func_normal_abspath_altnamespace= case $func_normal_abspath_tpath in "") # Empty path, that just means $cwd. func_stripname '' '/' "`pwd`" func_normal_abspath_result=$func_stripname_result return ;; # The next three entries are used to spot a run of precisely # two leading slashes without using negated character classes; # we take advantage of case's first-match behaviour. ///*) # Unusual form of absolute path, do nothing. ;; //*) # Not necessarily an ordinary path; POSIX reserves leading '//' # and for example Cygwin uses it to access remote file shares # over CIFS/SMB, so we conserve a leading double slash if found. func_normal_abspath_altnamespace=/ ;; /*) # Absolute path, do nothing. ;; *) # Relative path, prepend $cwd. func_normal_abspath_tpath=`pwd`/$func_normal_abspath_tpath ;; esac # Cancel out all the simple stuff to save iterations. We also want # the path to end with a slash for ease of parsing, so make sure # there is one (and only one) here. func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \ -e "$_G_removedotparts" -e "$_G_collapseslashes" -e "$_G_finalslash"` while :; do # Processed it all yet? if test / = "$func_normal_abspath_tpath"; then # If we ascended to the root using ".." the result may be empty now. if test -z "$func_normal_abspath_result"; then func_normal_abspath_result=/ fi break fi func_normal_abspath_tcomponent=`$ECHO "$func_normal_abspath_tpath" | $SED \ -e "$_G_pathcar"` func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \ -e "$_G_pathcdr"` # Figure out what to do with it case $func_normal_abspath_tcomponent in "") # Trailing empty path component, ignore it. ;; ..) # Parent dir; strip last assembled component from result. func_dirname "$func_normal_abspath_result" func_normal_abspath_result=$func_dirname_result ;; *) # Actual path component, append it. func_append func_normal_abspath_result "/$func_normal_abspath_tcomponent" ;; esac done # Restore leading double-slash if one was found on entry. func_normal_abspath_result=$func_normal_abspath_altnamespace$func_normal_abspath_result } # func_notquiet ARG... # -------------------- # Echo program name prefixed message only when not in quiet mode. func_notquiet () { $debug_cmd $opt_quiet || func_echo ${1+"$@"} # A bug in bash halts the script if the last line of a function # fails when set -e is in force, so we need another command to # work around that: : } # func_relative_path SRCDIR DSTDIR # -------------------------------- # Set func_relative_path_result to the relative path from SRCDIR to DSTDIR. func_relative_path () { $debug_cmd func_relative_path_result= func_normal_abspath "$1" func_relative_path_tlibdir=$func_normal_abspath_result func_normal_abspath "$2" func_relative_path_tbindir=$func_normal_abspath_result # Ascend the tree starting from libdir while :; do # check if we have found a prefix of bindir case $func_relative_path_tbindir in $func_relative_path_tlibdir) # found an exact match func_relative_path_tcancelled= break ;; $func_relative_path_tlibdir*) # found a matching prefix func_stripname "$func_relative_path_tlibdir" '' "$func_relative_path_tbindir" func_relative_path_tcancelled=$func_stripname_result if test -z "$func_relative_path_result"; then func_relative_path_result=. fi break ;; *) func_dirname $func_relative_path_tlibdir func_relative_path_tlibdir=$func_dirname_result if test -z "$func_relative_path_tlibdir"; then # Have to descend all the way to the root! func_relative_path_result=../$func_relative_path_result func_relative_path_tcancelled=$func_relative_path_tbindir break fi func_relative_path_result=../$func_relative_path_result ;; esac done # Now calculate path; take care to avoid doubling-up slashes. func_stripname '' '/' "$func_relative_path_result" func_relative_path_result=$func_stripname_result func_stripname '/' '/' "$func_relative_path_tcancelled" if test -n "$func_stripname_result"; then func_append func_relative_path_result "/$func_stripname_result" fi # Normalisation. If bindir is libdir, return '.' else relative path. if test -n "$func_relative_path_result"; then func_stripname './' '' "$func_relative_path_result" func_relative_path_result=$func_stripname_result fi test -n "$func_relative_path_result" || func_relative_path_result=. : } # func_quote_portable EVAL ARG # ---------------------------- # Internal function to portably implement func_quote_arg. Note that we still # keep attention to performance here so we as much as possible try to avoid # calling sed binary (so far O(N) complexity as long as func_append is O(1)). func_quote_portable () { $debug_cmd $require_check_ifs_backslash func_quote_portable_result=$2 # one-time-loop (easy break) while true do if $1; then func_quote_portable_result=`$ECHO "$2" | $SED \ -e "$sed_double_quote_subst" -e "$sed_double_backslash"` break fi # Quote for eval. case $func_quote_portable_result in *[\\\`\"\$]*) # Fallback to sed for $func_check_bs_ifs_broken=:, or when the string # contains the shell wildcard characters. case $check_ifs_backshlash_broken$func_quote_portable_result in :*|*[\[\*\?]*) func_quote_portable_result=`$ECHO "$func_quote_portable_result" \ | $SED "$sed_quote_subst"` break ;; esac func_quote_portable_old_IFS=$IFS for _G_char in '\' '`' '"' '$' do # STATE($1) PREV($2) SEPARATOR($3) set start "" "" func_quote_portable_result=dummy"$_G_char$func_quote_portable_result$_G_char"dummy IFS=$_G_char for _G_part in $func_quote_portable_result do case $1 in quote) func_append func_quote_portable_result "$3$2" set quote "$_G_part" "\\$_G_char" ;; start) set first "" "" func_quote_portable_result= ;; first) set quote "$_G_part" "" ;; esac done done IFS=$func_quote_portable_old_IFS ;; *) ;; esac break done func_quote_portable_unquoted_result=$func_quote_portable_result case $func_quote_portable_result in # double-quote args containing shell metacharacters to delay # word splitting, command substitution and variable expansion # for a subsequent eval. # many bourne shells cannot handle close brackets correctly # in scan sets, so we specify it separately. *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") func_quote_portable_result=\"$func_quote_portable_result\" ;; esac } # func_quotefast_eval ARG # ----------------------- # Quote one ARG (internal). This is equivalent to 'func_quote_arg eval ARG', # but optimized for speed. Result is stored in $func_quotefast_eval. if test xyes = `(x=; printf -v x %q yes; echo x"$x") 2>/dev/null`; then printf -v _GL_test_printf_tilde %q '~' if test '\~' = "$_GL_test_printf_tilde"; then func_quotefast_eval () { printf -v func_quotefast_eval_result %q "$1" } else # Broken older Bash implementations. Make those faster too if possible. func_quotefast_eval () { case $1 in '~'*) func_quote_portable false "$1" func_quotefast_eval_result=$func_quote_portable_result ;; *) printf -v func_quotefast_eval_result %q "$1" ;; esac } fi else func_quotefast_eval () { func_quote_portable false "$1" func_quotefast_eval_result=$func_quote_portable_result } fi # func_quote_arg MODEs ARG # ------------------------ # Quote one ARG to be evaled later. MODEs argument may contain zero or more # specifiers listed below separated by ',' character. This function returns two # values: # i) func_quote_arg_result # double-quoted (when needed), suitable for a subsequent eval # ii) func_quote_arg_unquoted_result # has all characters that are still active within double # quotes backslashified. Available only if 'unquoted' is specified. # # Available modes: # ---------------- # 'eval' (default) # - escape shell special characters # 'expand' # - the same as 'eval'; but do not quote variable references # 'pretty' # - request aesthetic output, i.e. '"a b"' instead of 'a\ b'. This might # be used later in func_quote to get output like: 'echo "a b"' instead # of 'echo a\ b'. This is slower than default on some shells. # 'unquoted' # - produce also $func_quote_arg_unquoted_result which does not contain # wrapping double-quotes. # # Examples for 'func_quote_arg pretty,unquoted string': # # string | *_result | *_unquoted_result # ------------+-----------------------+------------------- # " | \" | \" # a b | "a b" | a b # "a b" | "\"a b\"" | \"a b\" # * | "*" | * # z="${x-$y}" | "z=\"\${x-\$y}\"" | z=\"\${x-\$y}\" # # Examples for 'func_quote_arg pretty,unquoted,expand string': # # string | *_result | *_unquoted_result # --------------+---------------------+-------------------- # z="${x-$y}" | "z=\"${x-$y}\"" | z=\"${x-$y}\" func_quote_arg () { _G_quote_expand=false case ,$1, in *,expand,*) _G_quote_expand=: ;; esac case ,$1, in *,pretty,*|*,expand,*|*,unquoted,*) func_quote_portable $_G_quote_expand "$2" func_quote_arg_result=$func_quote_portable_result func_quote_arg_unquoted_result=$func_quote_portable_unquoted_result ;; *) # Faster quote-for-eval for some shells. func_quotefast_eval "$2" func_quote_arg_result=$func_quotefast_eval_result ;; esac } # func_quote MODEs ARGs... # ------------------------ # Quote all ARGs to be evaled later and join them into single command. See # func_quote_arg's description for more info. func_quote () { $debug_cmd _G_func_quote_mode=$1 ; shift func_quote_result= while test 0 -lt $#; do func_quote_arg "$_G_func_quote_mode" "$1" if test -n "$func_quote_result"; then func_append func_quote_result " $func_quote_arg_result" else func_append func_quote_result "$func_quote_arg_result" fi shift done } # func_stripname PREFIX SUFFIX NAME # --------------------------------- # strip PREFIX and SUFFIX from NAME, and store in func_stripname_result. # PREFIX and SUFFIX must not contain globbing or regex special # characters, hashes, percent signs, but SUFFIX may contain a leading # dot (in which case that matches only a dot). if test yes = "$_G_HAVE_XSI_OPS"; then eval 'func_stripname () { $debug_cmd # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are # positional parameters, so assign one to ordinary variable first. func_stripname_result=$3 func_stripname_result=${func_stripname_result#"$1"} func_stripname_result=${func_stripname_result%"$2"} }' else func_stripname () { $debug_cmd case $2 in .*) func_stripname_result=`$ECHO "$3" | $SED -e "s%^$1%%" -e "s%\\\\$2\$%%"`;; *) func_stripname_result=`$ECHO "$3" | $SED -e "s%^$1%%" -e "s%$2\$%%"`;; esac } fi # func_show_eval CMD [FAIL_EXP] # ----------------------------- # Unless opt_quiet is true, then output CMD. Then, if opt_dryrun is # not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP # is given, then evaluate it. func_show_eval () { $debug_cmd _G_cmd=$1 _G_fail_exp=${2-':'} func_quote_arg pretty,expand "$_G_cmd" eval "func_notquiet $func_quote_arg_result" $opt_dry_run || { eval "$_G_cmd" _G_status=$? if test 0 -ne "$_G_status"; then eval "(exit $_G_status); $_G_fail_exp" fi } } # func_show_eval_locale CMD [FAIL_EXP] # ------------------------------------ # Unless opt_quiet is true, then output CMD. Then, if opt_dryrun is # not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP # is given, then evaluate it. Use the saved locale for evaluation. func_show_eval_locale () { $debug_cmd _G_cmd=$1 _G_fail_exp=${2-':'} $opt_quiet || { func_quote_arg expand,pretty "$_G_cmd" eval "func_echo $func_quote_arg_result" } $opt_dry_run || { eval "$_G_user_locale $_G_cmd" _G_status=$? eval "$_G_safe_locale" if test 0 -ne "$_G_status"; then eval "(exit $_G_status); $_G_fail_exp" fi } } # func_tr_sh # ---------- # Turn $1 into a string suitable for a shell variable name. # Result is stored in $func_tr_sh_result. All characters # not in the set a-zA-Z0-9_ are replaced with '_'. Further, # if $1 begins with a digit, a '_' is prepended as well. func_tr_sh () { $debug_cmd case $1 in [0-9]* | *[!a-zA-Z0-9_]*) func_tr_sh_result=`$ECHO "$1" | $SED -e 's/^\([0-9]\)/_\1/' -e 's/[^a-zA-Z0-9_]/_/g'` ;; * ) func_tr_sh_result=$1 ;; esac } # func_verbose ARG... # ------------------- # Echo program name prefixed message in verbose mode only. func_verbose () { $debug_cmd $opt_verbose && func_echo "$*" : } # func_warn_and_continue ARG... # ----------------------------- # Echo program name prefixed warning message to standard error. func_warn_and_continue () { $debug_cmd $require_term_colors func_echo_infix_1 "${tc_red}warning$tc_reset" "$*" >&2 } # func_warning CATEGORY ARG... # ---------------------------- # Echo program name prefixed warning message to standard error. Warning # messages can be filtered according to CATEGORY, where this function # elides messages where CATEGORY is not listed in the global variable # 'opt_warning_types'. func_warning () { $debug_cmd # CATEGORY must be in the warning_categories list! case " $warning_categories " in *" $1 "*) ;; *) func_internal_error "invalid warning category '$1'" ;; esac _G_category=$1 shift case " $opt_warning_types " in *" $_G_category "*) $warning_func ${1+"$@"} ;; esac } # func_sort_ver VER1 VER2 # ----------------------- # 'sort -V' is not generally available. # Note this deviates from the version comparison in automake # in that it treats 1.5 < 1.5.0, and treats 1.4.4a < 1.4-p3a # but this should suffice as we won't be specifying old # version formats or redundant trailing .0 in bootstrap.conf. # If we did want full compatibility then we should probably # use m4_version_compare from autoconf. func_sort_ver () { $debug_cmd printf '%s\n%s\n' "$1" "$2" \ | sort -t. -k 1,1n -k 2,2n -k 3,3n -k 4,4n -k 5,5n -k 6,6n -k 7,7n -k 8,8n -k 9,9n } # func_lt_ver PREV CURR # --------------------- # Return true if PREV and CURR are in the correct order according to # func_sort_ver, otherwise false. Use it like this: # # func_lt_ver "$prev_ver" "$proposed_ver" || func_fatal_error "..." func_lt_ver () { $debug_cmd test "x$1" = x`func_sort_ver "$1" "$2" | $SED 1q` } # Local variables: # mode: shell-script # sh-indentation: 2 # eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-pattern: "10/scriptversion=%:y-%02m-%02d.%02H; # UTC" # time-stamp-time-zone: "UTC" # End: #! /bin/sh # A portable, pluggable option parser for Bourne shell. # Written by Gary V. Vaughan, 2010 # This is free software. There is NO warranty; not even for # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. # # Copyright (C) 2010-2019, 2021 Bootstrap Authors # # This file is dual licensed under the terms of the MIT license # , and GPL version 2 or later # . You must apply one of # these licenses when using or redistributing this software or any of # the files within it. See the URLs above, or the file `LICENSE` # included in the Bootstrap distribution for the full license texts. # Please report bugs or propose patches to: # # Set a version string for this script. scriptversion=2019-02-19.15; # UTC ## ------ ## ## Usage. ## ## ------ ## # This file is a library for parsing options in your shell scripts along # with assorted other useful supporting features that you can make use # of too. # # For the simplest scripts you might need only: # # #!/bin/sh # . relative/path/to/funclib.sh # . relative/path/to/options-parser # scriptversion=1.0 # func_options ${1+"$@"} # eval set dummy "$func_options_result"; shift # ...rest of your script... # # In order for the '--version' option to work, you will need to have a # suitably formatted comment like the one at the top of this file # starting with '# Written by ' and ending with '# Copyright'. # # For '-h' and '--help' to work, you will also need a one line # description of your script's purpose in a comment directly above the # '# Written by ' line, like the one at the top of this file. # # The default options also support '--debug', which will turn on shell # execution tracing (see the comment above debug_cmd below for another # use), and '--verbose' and the func_verbose function to allow your script # to display verbose messages only when your user has specified # '--verbose'. # # After sourcing this file, you can plug in processing for additional # options by amending the variables from the 'Configuration' section # below, and following the instructions in the 'Option parsing' # section further down. ## -------------- ## ## Configuration. ## ## -------------- ## # You should override these variables in your script after sourcing this # file so that they reflect the customisations you have added to the # option parser. # The usage line for option parsing errors and the start of '-h' and # '--help' output messages. You can embed shell variables for delayed # expansion at the time the message is displayed, but you will need to # quote other shell meta-characters carefully to prevent them being # expanded when the contents are evaled. usage='$progpath [OPTION]...' # Short help message in response to '-h' and '--help'. Add to this or # override it after sourcing this library to reflect the full set of # options your script accepts. usage_message="\ --debug enable verbose shell tracing -W, --warnings=CATEGORY report the warnings falling in CATEGORY [all] -v, --verbose verbosely report processing --version print version information and exit -h, --help print short or long help message and exit " # Additional text appended to 'usage_message' in response to '--help'. long_help_message=" Warning categories include: 'all' show all warnings 'none' turn off all the warnings 'error' warnings are treated as fatal errors" # Help message printed before fatal option parsing errors. fatal_help="Try '\$progname --help' for more information." ## ------------------------- ## ## Hook function management. ## ## ------------------------- ## # This section contains functions for adding, removing, and running hooks # in the main code. A hook is just a list of function names that can be # run in order later on. # func_hookable FUNC_NAME # ----------------------- # Declare that FUNC_NAME will run hooks added with # 'func_add_hook FUNC_NAME ...'. func_hookable () { $debug_cmd func_append hookable_fns " $1" } # func_add_hook FUNC_NAME HOOK_FUNC # --------------------------------- # Request that FUNC_NAME call HOOK_FUNC before it returns. FUNC_NAME must # first have been declared "hookable" by a call to 'func_hookable'. func_add_hook () { $debug_cmd case " $hookable_fns " in *" $1 "*) ;; *) func_fatal_error "'$1' does not accept hook functions." ;; esac eval func_append ${1}_hooks '" $2"' } # func_remove_hook FUNC_NAME HOOK_FUNC # ------------------------------------ # Remove HOOK_FUNC from the list of hook functions to be called by # FUNC_NAME. func_remove_hook () { $debug_cmd eval ${1}_hooks='`$ECHO "\$'$1'_hooks" |$SED "s| '$2'||"`' } # func_propagate_result FUNC_NAME_A FUNC_NAME_B # --------------------------------------------- # If the *_result variable of FUNC_NAME_A _is set_, assign its value to # *_result variable of FUNC_NAME_B. func_propagate_result () { $debug_cmd func_propagate_result_result=: if eval "test \"\${${1}_result+set}\" = set" then eval "${2}_result=\$${1}_result" else func_propagate_result_result=false fi } # func_run_hooks FUNC_NAME [ARG]... # --------------------------------- # Run all hook functions registered to FUNC_NAME. # It's assumed that the list of hook functions contains nothing more # than a whitespace-delimited list of legal shell function names, and # no effort is wasted trying to catch shell meta-characters or preserve # whitespace. func_run_hooks () { $debug_cmd _G_rc_run_hooks=false case " $hookable_fns " in *" $1 "*) ;; *) func_fatal_error "'$1' does not support hook functions." ;; esac eval _G_hook_fns=\$$1_hooks; shift for _G_hook in $_G_hook_fns; do func_unset "${_G_hook}_result" eval $_G_hook '${1+"$@"}' func_propagate_result $_G_hook func_run_hooks if $func_propagate_result_result; then eval set dummy "$func_run_hooks_result"; shift fi done } ## --------------- ## ## Option parsing. ## ## --------------- ## # In order to add your own option parsing hooks, you must accept the # full positional parameter list from your hook function. You may remove # or edit any options that you action, and then pass back the remaining # unprocessed options in '_result', escaped # suitably for 'eval'. # # The '_result' variable is automatically unset # before your hook gets called; for best performance, only set the # *_result variable when necessary (i.e. don't call the 'func_quote' # function unnecessarily because it can be an expensive operation on some # machines). # # Like this: # # my_options_prep () # { # $debug_cmd # # # Extend the existing usage message. # usage_message=$usage_message' # -s, --silent don'\''t print informational messages # ' # # No change in '$@' (ignored completely by this hook). Leave # # my_options_prep_result variable intact. # } # func_add_hook func_options_prep my_options_prep # # # my_silent_option () # { # $debug_cmd # # args_changed=false # # # Note that, for efficiency, we parse as many options as we can # # recognise in a loop before passing the remainder back to the # # caller on the first unrecognised argument we encounter. # while test $# -gt 0; do # opt=$1; shift # case $opt in # --silent|-s) opt_silent=: # args_changed=: # ;; # # Separate non-argument short options: # -s*) func_split_short_opt "$_G_opt" # set dummy "$func_split_short_opt_name" \ # "-$func_split_short_opt_arg" ${1+"$@"} # shift # args_changed=: # ;; # *) # Make sure the first unrecognised option "$_G_opt" # # is added back to "$@" in case we need it later, # # if $args_changed was set to 'true'. # set dummy "$_G_opt" ${1+"$@"}; shift; break ;; # esac # done # # # Only call 'func_quote' here if we processed at least one argument. # if $args_changed; then # func_quote eval ${1+"$@"} # my_silent_option_result=$func_quote_result # fi # } # func_add_hook func_parse_options my_silent_option # # # my_option_validation () # { # $debug_cmd # # $opt_silent && $opt_verbose && func_fatal_help "\ # '--silent' and '--verbose' options are mutually exclusive." # } # func_add_hook func_validate_options my_option_validation # # You'll also need to manually amend $usage_message to reflect the extra # options you parse. It's preferable to append if you can, so that # multiple option parsing hooks can be added safely. # func_options_finish [ARG]... # ---------------------------- # Finishing the option parse loop (call 'func_options' hooks ATM). func_options_finish () { $debug_cmd func_run_hooks func_options ${1+"$@"} func_propagate_result func_run_hooks func_options_finish } # func_options [ARG]... # --------------------- # All the functions called inside func_options are hookable. See the # individual implementations for details. func_hookable func_options func_options () { $debug_cmd _G_options_quoted=false for my_func in options_prep parse_options validate_options options_finish do func_unset func_${my_func}_result func_unset func_run_hooks_result eval func_$my_func '${1+"$@"}' func_propagate_result func_$my_func func_options if $func_propagate_result_result; then eval set dummy "$func_options_result"; shift _G_options_quoted=: fi done $_G_options_quoted || { # As we (func_options) are top-level options-parser function and # nobody quoted "$@" for us yet, we need to do it explicitly for # caller. func_quote eval ${1+"$@"} func_options_result=$func_quote_result } } # func_options_prep [ARG]... # -------------------------- # All initialisations required before starting the option parse loop. # Note that when calling hook functions, we pass through the list of # positional parameters. If a hook function modifies that list, and # needs to propagate that back to rest of this script, then the complete # modified list must be put in 'func_run_hooks_result' before returning. func_hookable func_options_prep func_options_prep () { $debug_cmd # Option defaults: opt_verbose=false opt_warning_types= func_run_hooks func_options_prep ${1+"$@"} func_propagate_result func_run_hooks func_options_prep } # func_parse_options [ARG]... # --------------------------- # The main option parsing loop. func_hookable func_parse_options func_parse_options () { $debug_cmd _G_parse_options_requote=false # this just eases exit handling while test $# -gt 0; do # Defer to hook functions for initial option parsing, so they # get priority in the event of reusing an option name. func_run_hooks func_parse_options ${1+"$@"} func_propagate_result func_run_hooks func_parse_options if $func_propagate_result_result; then eval set dummy "$func_parse_options_result"; shift # Even though we may have changed "$@", we passed the "$@" array # down into the hook and it quoted it for us (because we are in # this if-branch). No need to quote it again. _G_parse_options_requote=false fi # Break out of the loop if we already parsed every option. test $# -gt 0 || break # We expect that one of the options parsed in this function matches # and thus we remove _G_opt from "$@" and need to re-quote. _G_match_parse_options=: _G_opt=$1 shift case $_G_opt in --debug|-x) debug_cmd='set -x' func_echo "enabling shell trace mode" >&2 $debug_cmd ;; --no-warnings|--no-warning|--no-warn) set dummy --warnings none ${1+"$@"} shift ;; --warnings|--warning|-W) if test $# = 0 && func_missing_arg $_G_opt; then _G_parse_options_requote=: break fi case " $warning_categories $1" in *" $1 "*) # trailing space prevents matching last $1 above func_append_uniq opt_warning_types " $1" ;; *all) opt_warning_types=$warning_categories ;; *none) opt_warning_types=none warning_func=: ;; *error) opt_warning_types=$warning_categories warning_func=func_fatal_error ;; *) func_fatal_error \ "unsupported warning category: '$1'" ;; esac shift ;; --verbose|-v) opt_verbose=: ;; --version) func_version ;; -\?|-h) func_usage ;; --help) func_help ;; # Separate optargs to long options (plugins may need this): --*=*) func_split_equals "$_G_opt" set dummy "$func_split_equals_lhs" \ "$func_split_equals_rhs" ${1+"$@"} shift ;; # Separate optargs to short options: -W*) func_split_short_opt "$_G_opt" set dummy "$func_split_short_opt_name" \ "$func_split_short_opt_arg" ${1+"$@"} shift ;; # Separate non-argument short options: -\?*|-h*|-v*|-x*) func_split_short_opt "$_G_opt" set dummy "$func_split_short_opt_name" \ "-$func_split_short_opt_arg" ${1+"$@"} shift ;; --) _G_parse_options_requote=: ; break ;; -*) func_fatal_help "unrecognised option: '$_G_opt'" ;; *) set dummy "$_G_opt" ${1+"$@"}; shift _G_match_parse_options=false break ;; esac if $_G_match_parse_options; then _G_parse_options_requote=: fi done if $_G_parse_options_requote; then # save modified positional parameters for caller func_quote eval ${1+"$@"} func_parse_options_result=$func_quote_result fi } # func_validate_options [ARG]... # ------------------------------ # Perform any sanity checks on option settings and/or unconsumed # arguments. func_hookable func_validate_options func_validate_options () { $debug_cmd # Display all warnings if -W was not given. test -n "$opt_warning_types" || opt_warning_types=" $warning_categories" func_run_hooks func_validate_options ${1+"$@"} func_propagate_result func_run_hooks func_validate_options # Bail if the options were screwed! $exit_cmd $EXIT_FAILURE } ## ----------------- ## ## Helper functions. ## ## ----------------- ## # This section contains the helper functions used by the rest of the # hookable option parser framework in ascii-betical order. # func_fatal_help ARG... # ---------------------- # Echo program name prefixed message to standard error, followed by # a help hint, and exit. func_fatal_help () { $debug_cmd eval \$ECHO \""Usage: $usage"\" eval \$ECHO \""$fatal_help"\" func_error ${1+"$@"} exit $EXIT_FAILURE } # func_help # --------- # Echo long help message to standard output and exit. func_help () { $debug_cmd func_usage_message $ECHO "$long_help_message" exit 0 } # func_missing_arg ARGNAME # ------------------------ # Echo program name prefixed message to standard error and set global # exit_cmd. func_missing_arg () { $debug_cmd func_error "Missing argument for '$1'." exit_cmd=exit } # func_split_equals STRING # ------------------------ # Set func_split_equals_lhs and func_split_equals_rhs shell variables # after splitting STRING at the '=' sign. test -z "$_G_HAVE_XSI_OPS" \ && (eval 'x=a/b/c; test 5aa/bb/cc = "${#x}${x%%/*}${x%/*}${x#*/}${x##*/}"') 2>/dev/null \ && _G_HAVE_XSI_OPS=yes if test yes = "$_G_HAVE_XSI_OPS" then # This is an XSI compatible shell, allowing a faster implementation... eval 'func_split_equals () { $debug_cmd func_split_equals_lhs=${1%%=*} func_split_equals_rhs=${1#*=} if test "x$func_split_equals_lhs" = "x$1"; then func_split_equals_rhs= fi }' else # ...otherwise fall back to using expr, which is often a shell builtin. func_split_equals () { $debug_cmd func_split_equals_lhs=`expr "x$1" : 'x\([^=]*\)'` func_split_equals_rhs= test "x$func_split_equals_lhs=" = "x$1" \ || func_split_equals_rhs=`expr "x$1" : 'x[^=]*=\(.*\)$'` } fi #func_split_equals # func_split_short_opt SHORTOPT # ----------------------------- # Set func_split_short_opt_name and func_split_short_opt_arg shell # variables after splitting SHORTOPT after the 2nd character. if test yes = "$_G_HAVE_XSI_OPS" then # This is an XSI compatible shell, allowing a faster implementation... eval 'func_split_short_opt () { $debug_cmd func_split_short_opt_arg=${1#??} func_split_short_opt_name=${1%"$func_split_short_opt_arg"} }' else # ...otherwise fall back to using expr, which is often a shell builtin. func_split_short_opt () { $debug_cmd func_split_short_opt_name=`expr "x$1" : 'x\(-.\)'` func_split_short_opt_arg=`expr "x$1" : 'x-.\(.*\)$'` } fi #func_split_short_opt # func_usage # ---------- # Echo short help message to standard output and exit. func_usage () { $debug_cmd func_usage_message $ECHO "Run '$progname --help |${PAGER-more}' for full usage" exit 0 } # func_usage_message # ------------------ # Echo short help message to standard output. func_usage_message () { $debug_cmd eval \$ECHO \""Usage: $usage"\" echo $SED -n 's|^# || /^Written by/{ x;p;x } h /^Written by/q' < "$progpath" echo eval \$ECHO \""$usage_message"\" } # func_version # ------------ # Echo version message to standard output and exit. # The version message is extracted from the calling file's header # comments, with leading '# ' stripped: # 1. First display the progname and version # 2. Followed by the header comment line matching /^# Written by / # 3. Then a blank line followed by the first following line matching # /^# Copyright / # 4. Immediately followed by any lines between the previous matches, # except lines preceding the intervening completely blank line. # For example, see the header comments of this file. func_version () { $debug_cmd printf '%s\n' "$progname $scriptversion" $SED -n ' /^# Written by /!b s|^# ||; p; n :fwd2blnk /./ { n b fwd2blnk } p; n :holdwrnt s|^# || s|^# *$|| /^Copyright /!{ /./H n b holdwrnt } s|\((C)\)[ 0-9,-]*[ ,-]\([1-9][0-9]* \)|\1 \2| G s|\(\n\)\n*|\1|g p; q' < "$progpath" exit $? } # Local variables: # mode: shell-script # sh-indentation: 2 # eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-pattern: "30/scriptversion=%:y-%02m-%02d.%02H; # UTC" # time-stamp-time-zone: "UTC" # End: # Set a version string. scriptversion='(GNU libtool) 2.4.7' # func_echo ARG... # ---------------- # Libtool also displays the current mode in messages, so override # funclib.sh func_echo with this custom definition. func_echo () { $debug_cmd _G_message=$* func_echo_IFS=$IFS IFS=$nl for _G_line in $_G_message; do IFS=$func_echo_IFS $ECHO "$progname${opt_mode+: $opt_mode}: $_G_line" done IFS=$func_echo_IFS } # func_warning ARG... # ------------------- # Libtool warnings are not categorized, so override funclib.sh # func_warning with this simpler definition. func_warning () { $debug_cmd $warning_func ${1+"$@"} } ## ---------------- ## ## Options parsing. ## ## ---------------- ## # Hook in the functions to make sure our own options are parsed during # the option parsing loop. usage='$progpath [OPTION]... [MODE-ARG]...' # Short help message in response to '-h'. usage_message="Options: --config show all configuration variables --debug enable verbose shell tracing -n, --dry-run display commands without modifying any files --features display basic configuration information and exit --mode=MODE use operation mode MODE --no-warnings equivalent to '-Wnone' --preserve-dup-deps don't remove duplicate dependency libraries --quiet, --silent don't print informational messages --tag=TAG use configuration variables from tag TAG -v, --verbose print more informational messages than default --version print version information -W, --warnings=CATEGORY report the warnings falling in CATEGORY [all] -h, --help, --help-all print short, long, or detailed help message " # Additional text appended to 'usage_message' in response to '--help'. func_help () { $debug_cmd func_usage_message $ECHO "$long_help_message MODE must be one of the following: clean remove files from the build directory compile compile a source file into a libtool object execute automatically set library path, then run a program finish complete the installation of libtool libraries install install libraries or executables link create a library or an executable uninstall remove libraries from an installed directory MODE-ARGS vary depending on the MODE. When passed as first option, '--mode=MODE' may be abbreviated as 'MODE' or a unique abbreviation of that. Try '$progname --help --mode=MODE' for a more detailed description of MODE. When reporting a bug, please describe a test case to reproduce it and include the following information: host-triplet: $host shell: $SHELL compiler: $LTCC compiler flags: $LTCFLAGS linker: $LD (gnu? $with_gnu_ld) version: $progname $scriptversion Debian-2.4.7-5 automake: `($AUTOMAKE --version) 2>/dev/null |$SED 1q` autoconf: `($AUTOCONF --version) 2>/dev/null |$SED 1q` Report bugs to . GNU libtool home page: . General help using GNU software: ." exit 0 } # func_lo2o OBJECT-NAME # --------------------- # Transform OBJECT-NAME from a '.lo' suffix to the platform specific # object suffix. lo2o=s/\\.lo\$/.$objext/ o2lo=s/\\.$objext\$/.lo/ if test yes = "$_G_HAVE_XSI_OPS"; then eval 'func_lo2o () { case $1 in *.lo) func_lo2o_result=${1%.lo}.$objext ;; * ) func_lo2o_result=$1 ;; esac }' # func_xform LIBOBJ-OR-SOURCE # --------------------------- # Transform LIBOBJ-OR-SOURCE from a '.o' or '.c' (or otherwise) # suffix to a '.lo' libtool-object suffix. eval 'func_xform () { func_xform_result=${1%.*}.lo }' else # ...otherwise fall back to using sed. func_lo2o () { func_lo2o_result=`$ECHO "$1" | $SED "$lo2o"` } func_xform () { func_xform_result=`$ECHO "$1" | $SED 's|\.[^.]*$|.lo|'` } fi # func_fatal_configuration ARG... # ------------------------------- # Echo program name prefixed message to standard error, followed by # a configuration failure hint, and exit. func_fatal_configuration () { func_fatal_error ${1+"$@"} \ "See the $PACKAGE documentation for more information." \ "Fatal configuration error." } # func_config # ----------- # Display the configuration for all the tags in this script. func_config () { re_begincf='^# ### BEGIN LIBTOOL' re_endcf='^# ### END LIBTOOL' # Default configuration. $SED "1,/$re_begincf CONFIG/d;/$re_endcf CONFIG/,\$d" < "$progpath" # Now print the configurations for the tags. for tagname in $taglist; do $SED -n "/$re_begincf TAG CONFIG: $tagname\$/,/$re_endcf TAG CONFIG: $tagname\$/p" < "$progpath" done exit $? } # func_features # ------------- # Display the features supported by this script. func_features () { echo "host: $host" if test yes = "$build_libtool_libs"; then echo "enable shared libraries" else echo "disable shared libraries" fi if test yes = "$build_old_libs"; then echo "enable static libraries" else echo "disable static libraries" fi exit $? } # func_enable_tag TAGNAME # ----------------------- # Verify that TAGNAME is valid, and either flag an error and exit, or # enable the TAGNAME tag. We also add TAGNAME to the global $taglist # variable here. func_enable_tag () { # Global variable: tagname=$1 re_begincf="^# ### BEGIN LIBTOOL TAG CONFIG: $tagname\$" re_endcf="^# ### END LIBTOOL TAG CONFIG: $tagname\$" sed_extractcf=/$re_begincf/,/$re_endcf/p # Validate tagname. case $tagname in *[!-_A-Za-z0-9,/]*) func_fatal_error "invalid tag name: $tagname" ;; esac # Don't test for the "default" C tag, as we know it's # there but not specially marked. case $tagname in CC) ;; *) if $GREP "$re_begincf" "$progpath" >/dev/null 2>&1; then taglist="$taglist $tagname" # Evaluate the configuration. Be careful to quote the path # and the sed script, to avoid splitting on whitespace, but # also don't use non-portable quotes within backquotes within # quotes we have to do it in 2 steps: extractedcf=`$SED -n -e "$sed_extractcf" < "$progpath"` eval "$extractedcf" else func_error "ignoring unknown tag $tagname" fi ;; esac } # func_check_version_match # ------------------------ # Ensure that we are using m4 macros, and libtool script from the same # release of libtool. func_check_version_match () { if test "$package_revision" != "$macro_revision"; then if test "$VERSION" != "$macro_version"; then if test -z "$macro_version"; then cat >&2 <<_LT_EOF $progname: Version mismatch error. This is $PACKAGE $VERSION, but the $progname: definition of this LT_INIT comes from an older release. $progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION $progname: and run autoconf again. _LT_EOF else cat >&2 <<_LT_EOF $progname: Version mismatch error. This is $PACKAGE $VERSION, but the $progname: definition of this LT_INIT comes from $PACKAGE $macro_version. $progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION $progname: and run autoconf again. _LT_EOF fi else cat >&2 <<_LT_EOF $progname: Version mismatch error. This is $PACKAGE $VERSION, revision $package_revision, $progname: but the definition of this LT_INIT comes from revision $macro_revision. $progname: You should recreate aclocal.m4 with macros from revision $package_revision $progname: of $PACKAGE $VERSION and run autoconf again. _LT_EOF fi exit $EXIT_MISMATCH fi } # libtool_options_prep [ARG]... # ----------------------------- # Preparation for options parsed by libtool. libtool_options_prep () { $debug_mode # Option defaults: opt_config=false opt_dlopen= opt_dry_run=false opt_help=false opt_mode= opt_preserve_dup_deps=false opt_quiet=false nonopt= preserve_args= _G_rc_lt_options_prep=: _G_rc_lt_options_prep=: # Shorthand for --mode=foo, only valid as the first argument case $1 in clean|clea|cle|cl) shift; set dummy --mode clean ${1+"$@"}; shift ;; compile|compil|compi|comp|com|co|c) shift; set dummy --mode compile ${1+"$@"}; shift ;; execute|execut|execu|exec|exe|ex|e) shift; set dummy --mode execute ${1+"$@"}; shift ;; finish|finis|fini|fin|fi|f) shift; set dummy --mode finish ${1+"$@"}; shift ;; install|instal|insta|inst|ins|in|i) shift; set dummy --mode install ${1+"$@"}; shift ;; link|lin|li|l) shift; set dummy --mode link ${1+"$@"}; shift ;; uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u) shift; set dummy --mode uninstall ${1+"$@"}; shift ;; *) _G_rc_lt_options_prep=false ;; esac if $_G_rc_lt_options_prep; then # Pass back the list of options. func_quote eval ${1+"$@"} libtool_options_prep_result=$func_quote_result fi } func_add_hook func_options_prep libtool_options_prep # libtool_parse_options [ARG]... # --------------------------------- # Provide handling for libtool specific options. libtool_parse_options () { $debug_cmd _G_rc_lt_parse_options=false # Perform our own loop to consume as many options as possible in # each iteration. while test $# -gt 0; do _G_match_lt_parse_options=: _G_opt=$1 shift case $_G_opt in --dry-run|--dryrun|-n) opt_dry_run=: ;; --config) func_config ;; --dlopen|-dlopen) opt_dlopen="${opt_dlopen+$opt_dlopen }$1" shift ;; --preserve-dup-deps) opt_preserve_dup_deps=: ;; --features) func_features ;; --finish) set dummy --mode finish ${1+"$@"}; shift ;; --help) opt_help=: ;; --help-all) opt_help=': help-all' ;; --mode) test $# = 0 && func_missing_arg $_G_opt && break opt_mode=$1 case $1 in # Valid mode arguments: clean|compile|execute|finish|install|link|relink|uninstall) ;; # Catch anything else as an error *) func_error "invalid argument for $_G_opt" exit_cmd=exit break ;; esac shift ;; --no-silent|--no-quiet) opt_quiet=false func_append preserve_args " $_G_opt" ;; --no-warnings|--no-warning|--no-warn) opt_warning=false func_append preserve_args " $_G_opt" ;; --no-verbose) opt_verbose=false func_append preserve_args " $_G_opt" ;; --silent|--quiet) opt_quiet=: opt_verbose=false func_append preserve_args " $_G_opt" ;; --tag) test $# = 0 && func_missing_arg $_G_opt && break opt_tag=$1 func_append preserve_args " $_G_opt $1" func_enable_tag "$1" shift ;; --verbose|-v) opt_quiet=false opt_verbose=: func_append preserve_args " $_G_opt" ;; # An option not handled by this hook function: *) set dummy "$_G_opt" ${1+"$@"} ; shift _G_match_lt_parse_options=false break ;; esac $_G_match_lt_parse_options && _G_rc_lt_parse_options=: done if $_G_rc_lt_parse_options; then # save modified positional parameters for caller func_quote eval ${1+"$@"} libtool_parse_options_result=$func_quote_result fi } func_add_hook func_parse_options libtool_parse_options # libtool_validate_options [ARG]... # --------------------------------- # Perform any sanity checks on option settings and/or unconsumed # arguments. libtool_validate_options () { # save first non-option argument if test 0 -lt $#; then nonopt=$1 shift fi # preserve --debug test : = "$debug_cmd" || func_append preserve_args " --debug" case $host in # Solaris2 added to fix http://debbugs.gnu.org/cgi/bugreport.cgi?bug=16452 # see also: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59788 *cygwin* | *mingw* | *pw32* | *cegcc* | *solaris2* | *os2*) # don't eliminate duplications in $postdeps and $predeps opt_duplicate_compiler_generated_deps=: ;; *) opt_duplicate_compiler_generated_deps=$opt_preserve_dup_deps ;; esac $opt_help || { # Sanity checks first: func_check_version_match test yes != "$build_libtool_libs" \ && test yes != "$build_old_libs" \ && func_fatal_configuration "not configured to build any kind of library" # Darwin sucks eval std_shrext=\"$shrext_cmds\" # Only execute mode is allowed to have -dlopen flags. if test -n "$opt_dlopen" && test execute != "$opt_mode"; then func_error "unrecognized option '-dlopen'" $ECHO "$help" 1>&2 exit $EXIT_FAILURE fi # Change the help message to a mode-specific one. generic_help=$help help="Try '$progname --help --mode=$opt_mode' for more information." } # Pass back the unparsed argument list func_quote eval ${1+"$@"} libtool_validate_options_result=$func_quote_result } func_add_hook func_validate_options libtool_validate_options # Process options as early as possible so that --help and --version # can return quickly. func_options ${1+"$@"} eval set dummy "$func_options_result"; shift ## ----------- ## ## Main. ## ## ----------- ## magic='%%%MAGIC variable%%%' magic_exe='%%%MAGIC EXE variable%%%' # Global variables. extracted_archives= extracted_serial=0 # If this variable is set in any of the actions, the command in it # will be execed at the end. This prevents here-documents from being # left over by shells. exec_cmd= # A function that is used when there is no print builtin or printf. func_fallback_echo () { eval 'cat <<_LTECHO_EOF $1 _LTECHO_EOF' } # func_generated_by_libtool # True iff stdin has been generated by Libtool. This function is only # a basic sanity check; it will hardly flush out determined imposters. func_generated_by_libtool_p () { $GREP "^# Generated by .*$PACKAGE" > /dev/null 2>&1 } # func_lalib_p file # True iff FILE is a libtool '.la' library or '.lo' object file. # This function is only a basic sanity check; it will hardly flush out # determined imposters. func_lalib_p () { test -f "$1" && $SED -e 4q "$1" 2>/dev/null | func_generated_by_libtool_p } # func_lalib_unsafe_p file # True iff FILE is a libtool '.la' library or '.lo' object file. # This function implements the same check as func_lalib_p without # resorting to external programs. To this end, it redirects stdin and # closes it afterwards, without saving the original file descriptor. # As a safety measure, use it only where a negative result would be # fatal anyway. Works if 'file' does not exist. func_lalib_unsafe_p () { lalib_p=no if test -f "$1" && test -r "$1" && exec 5<&0 <"$1"; then for lalib_p_l in 1 2 3 4 do read lalib_p_line case $lalib_p_line in \#\ Generated\ by\ *$PACKAGE* ) lalib_p=yes; break;; esac done exec 0<&5 5<&- fi test yes = "$lalib_p" } # func_ltwrapper_script_p file # True iff FILE is a libtool wrapper script # This function is only a basic sanity check; it will hardly flush out # determined imposters. func_ltwrapper_script_p () { test -f "$1" && $lt_truncate_bin < "$1" 2>/dev/null | func_generated_by_libtool_p } # func_ltwrapper_executable_p file # True iff FILE is a libtool wrapper executable # This function is only a basic sanity check; it will hardly flush out # determined imposters. func_ltwrapper_executable_p () { func_ltwrapper_exec_suffix= case $1 in *.exe) ;; *) func_ltwrapper_exec_suffix=.exe ;; esac $GREP "$magic_exe" "$1$func_ltwrapper_exec_suffix" >/dev/null 2>&1 } # func_ltwrapper_scriptname file # Assumes file is an ltwrapper_executable # uses $file to determine the appropriate filename for a # temporary ltwrapper_script. func_ltwrapper_scriptname () { func_dirname_and_basename "$1" "" "." func_stripname '' '.exe' "$func_basename_result" func_ltwrapper_scriptname_result=$func_dirname_result/$objdir/${func_stripname_result}_ltshwrapper } # func_ltwrapper_p file # True iff FILE is a libtool wrapper script or wrapper executable # This function is only a basic sanity check; it will hardly flush out # determined imposters. func_ltwrapper_p () { func_ltwrapper_script_p "$1" || func_ltwrapper_executable_p "$1" } # func_execute_cmds commands fail_cmd # Execute tilde-delimited COMMANDS. # If FAIL_CMD is given, eval that upon failure. # FAIL_CMD may read-access the current command in variable CMD! func_execute_cmds () { $debug_cmd save_ifs=$IFS; IFS='~' for cmd in $1; do IFS=$sp$nl eval cmd=\"$cmd\" IFS=$save_ifs func_show_eval "$cmd" "${2-:}" done IFS=$save_ifs } # func_source file # Source FILE, adding directory component if necessary. # Note that it is not necessary on cygwin/mingw to append a dot to # FILE even if both FILE and FILE.exe exist: automatic-append-.exe # behavior happens only for exec(3), not for open(2)! Also, sourcing # 'FILE.' does not work on cygwin managed mounts. func_source () { $debug_cmd case $1 in */* | *\\*) . "$1" ;; *) . "./$1" ;; esac } # func_resolve_sysroot PATH # Replace a leading = in PATH with a sysroot. Store the result into # func_resolve_sysroot_result func_resolve_sysroot () { func_resolve_sysroot_result=$1 case $func_resolve_sysroot_result in =*) func_stripname '=' '' "$func_resolve_sysroot_result" func_resolve_sysroot_result=$lt_sysroot$func_stripname_result ;; esac } # func_replace_sysroot PATH # If PATH begins with the sysroot, replace it with = and # store the result into func_replace_sysroot_result. func_replace_sysroot () { case $lt_sysroot:$1 in ?*:"$lt_sysroot"*) func_stripname "$lt_sysroot" '' "$1" func_replace_sysroot_result='='$func_stripname_result ;; *) # Including no sysroot. func_replace_sysroot_result=$1 ;; esac } # func_infer_tag arg # Infer tagged configuration to use if any are available and # if one wasn't chosen via the "--tag" command line option. # Only attempt this if the compiler in the base compile # command doesn't match the default compiler. # arg is usually of the form 'gcc ...' func_infer_tag () { $debug_cmd if test -n "$available_tags" && test -z "$tagname"; then CC_quoted= for arg in $CC; do func_append_quoted CC_quoted "$arg" done CC_expanded=`func_echo_all $CC` CC_quoted_expanded=`func_echo_all $CC_quoted` case $@ in # Blanks in the command may have been stripped by the calling shell, # but not from the CC environment variable when configure was run. " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \ " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) ;; # Blanks at the start of $base_compile will cause this to fail # if we don't check for them as well. *) for z in $available_tags; do if $GREP "^# ### BEGIN LIBTOOL TAG CONFIG: $z$" < "$progpath" > /dev/null; then # Evaluate the configuration. eval "`$SED -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$z'$/,/^# ### END LIBTOOL TAG CONFIG: '$z'$/p' < $progpath`" CC_quoted= for arg in $CC; do # Double-quote args containing other shell metacharacters. func_append_quoted CC_quoted "$arg" done CC_expanded=`func_echo_all $CC` CC_quoted_expanded=`func_echo_all $CC_quoted` case "$@ " in " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \ " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) # The compiler in the base compile command matches # the one in the tagged configuration. # Assume this is the tagged configuration we want. tagname=$z break ;; esac fi done # If $tagname still isn't set, then no tagged configuration # was found and let the user know that the "--tag" command # line option must be used. if test -z "$tagname"; then func_echo "unable to infer tagged configuration" func_fatal_error "specify a tag with '--tag'" # else # func_verbose "using $tagname tagged configuration" fi ;; esac fi } # func_write_libtool_object output_name pic_name nonpic_name # Create a libtool object file (analogous to a ".la" file), # but don't create it if we're doing a dry run. func_write_libtool_object () { write_libobj=$1 if test yes = "$build_libtool_libs"; then write_lobj=\'$2\' else write_lobj=none fi if test yes = "$build_old_libs"; then write_oldobj=\'$3\' else write_oldobj=none fi $opt_dry_run || { cat >${write_libobj}T </dev/null` if test "$?" -eq 0 && test -n "$func_convert_core_file_wine_to_w32_tmp"; then func_convert_core_file_wine_to_w32_result=`$ECHO "$func_convert_core_file_wine_to_w32_tmp" | $SED -e "$sed_naive_backslashify"` else func_convert_core_file_wine_to_w32_result= fi fi } # end: func_convert_core_file_wine_to_w32 # func_convert_core_path_wine_to_w32 ARG # Helper function used by path conversion functions when $build is *nix, and # $host is mingw, cygwin, or some other w32 environment. Relies on a correctly # configured wine environment available, with the winepath program in $build's # $PATH. Assumes ARG has no leading or trailing path separator characters. # # ARG is path to be converted from $build format to win32. # Result is available in $func_convert_core_path_wine_to_w32_result. # Unconvertible file (directory) names in ARG are skipped; if no directory names # are convertible, then the result may be empty. func_convert_core_path_wine_to_w32 () { $debug_cmd # unfortunately, winepath doesn't convert paths, only file names func_convert_core_path_wine_to_w32_result= if test -n "$1"; then oldIFS=$IFS IFS=: for func_convert_core_path_wine_to_w32_f in $1; do IFS=$oldIFS func_convert_core_file_wine_to_w32 "$func_convert_core_path_wine_to_w32_f" if test -n "$func_convert_core_file_wine_to_w32_result"; then if test -z "$func_convert_core_path_wine_to_w32_result"; then func_convert_core_path_wine_to_w32_result=$func_convert_core_file_wine_to_w32_result else func_append func_convert_core_path_wine_to_w32_result ";$func_convert_core_file_wine_to_w32_result" fi fi done IFS=$oldIFS fi } # end: func_convert_core_path_wine_to_w32 # func_cygpath ARGS... # Wrapper around calling the cygpath program via LT_CYGPATH. This is used when # when (1) $build is *nix and Cygwin is hosted via a wine environment; or (2) # $build is MSYS and $host is Cygwin, or (3) $build is Cygwin. In case (1) or # (2), returns the Cygwin file name or path in func_cygpath_result (input # file name or path is assumed to be in w32 format, as previously converted # from $build's *nix or MSYS format). In case (3), returns the w32 file name # or path in func_cygpath_result (input file name or path is assumed to be in # Cygwin format). Returns an empty string on error. # # ARGS are passed to cygpath, with the last one being the file name or path to # be converted. # # Specify the absolute *nix (or w32) name to cygpath in the LT_CYGPATH # environment variable; do not put it in $PATH. func_cygpath () { $debug_cmd if test -n "$LT_CYGPATH" && test -f "$LT_CYGPATH"; then func_cygpath_result=`$LT_CYGPATH "$@" 2>/dev/null` if test "$?" -ne 0; then # on failure, ensure result is empty func_cygpath_result= fi else func_cygpath_result= func_error "LT_CYGPATH is empty or specifies non-existent file: '$LT_CYGPATH'" fi } #end: func_cygpath # func_convert_core_msys_to_w32 ARG # Convert file name or path ARG from MSYS format to w32 format. Return # result in func_convert_core_msys_to_w32_result. func_convert_core_msys_to_w32 () { $debug_cmd # awkward: cmd appends spaces to result func_convert_core_msys_to_w32_result=`( cmd //c echo "$1" ) 2>/dev/null | $SED -e 's/[ ]*$//' -e "$sed_naive_backslashify"` } #end: func_convert_core_msys_to_w32 # func_convert_file_check ARG1 ARG2 # Verify that ARG1 (a file name in $build format) was converted to $host # format in ARG2. Otherwise, emit an error message, but continue (resetting # func_to_host_file_result to ARG1). func_convert_file_check () { $debug_cmd if test -z "$2" && test -n "$1"; then func_error "Could not determine host file name corresponding to" func_error " '$1'" func_error "Continuing, but uninstalled executables may not work." # Fallback: func_to_host_file_result=$1 fi } # end func_convert_file_check # func_convert_path_check FROM_PATHSEP TO_PATHSEP FROM_PATH TO_PATH # Verify that FROM_PATH (a path in $build format) was converted to $host # format in TO_PATH. Otherwise, emit an error message, but continue, resetting # func_to_host_file_result to a simplistic fallback value (see below). func_convert_path_check () { $debug_cmd if test -z "$4" && test -n "$3"; then func_error "Could not determine the host path corresponding to" func_error " '$3'" func_error "Continuing, but uninstalled executables may not work." # Fallback. This is a deliberately simplistic "conversion" and # should not be "improved". See libtool.info. if test "x$1" != "x$2"; then lt_replace_pathsep_chars="s|$1|$2|g" func_to_host_path_result=`echo "$3" | $SED -e "$lt_replace_pathsep_chars"` else func_to_host_path_result=$3 fi fi } # end func_convert_path_check # func_convert_path_front_back_pathsep FRONTPAT BACKPAT REPL ORIG # Modifies func_to_host_path_result by prepending REPL if ORIG matches FRONTPAT # and appending REPL if ORIG matches BACKPAT. func_convert_path_front_back_pathsep () { $debug_cmd case $4 in $1 ) func_to_host_path_result=$3$func_to_host_path_result ;; esac case $4 in $2 ) func_append func_to_host_path_result "$3" ;; esac } # end func_convert_path_front_back_pathsep ################################################## # $build to $host FILE NAME CONVERSION FUNCTIONS # ################################################## # invoked via '$to_host_file_cmd ARG' # # In each case, ARG is the path to be converted from $build to $host format. # Result will be available in $func_to_host_file_result. # func_to_host_file ARG # Converts the file name ARG from $build format to $host format. Return result # in func_to_host_file_result. func_to_host_file () { $debug_cmd $to_host_file_cmd "$1" } # end func_to_host_file # func_to_tool_file ARG LAZY # converts the file name ARG from $build format to toolchain format. Return # result in func_to_tool_file_result. If the conversion in use is listed # in (the comma separated) LAZY, no conversion takes place. func_to_tool_file () { $debug_cmd case ,$2, in *,"$to_tool_file_cmd",*) func_to_tool_file_result=$1 ;; *) $to_tool_file_cmd "$1" func_to_tool_file_result=$func_to_host_file_result ;; esac } # end func_to_tool_file # func_convert_file_noop ARG # Copy ARG to func_to_host_file_result. func_convert_file_noop () { func_to_host_file_result=$1 } # end func_convert_file_noop # func_convert_file_msys_to_w32 ARG # Convert file name ARG from (mingw) MSYS to (mingw) w32 format; automatic # conversion to w32 is not available inside the cwrapper. Returns result in # func_to_host_file_result. func_convert_file_msys_to_w32 () { $debug_cmd func_to_host_file_result=$1 if test -n "$1"; then func_convert_core_msys_to_w32 "$1" func_to_host_file_result=$func_convert_core_msys_to_w32_result fi func_convert_file_check "$1" "$func_to_host_file_result" } # end func_convert_file_msys_to_w32 # func_convert_file_cygwin_to_w32 ARG # Convert file name ARG from Cygwin to w32 format. Returns result in # func_to_host_file_result. func_convert_file_cygwin_to_w32 () { $debug_cmd func_to_host_file_result=$1 if test -n "$1"; then # because $build is cygwin, we call "the" cygpath in $PATH; no need to use # LT_CYGPATH in this case. func_to_host_file_result=`cygpath -m "$1"` fi func_convert_file_check "$1" "$func_to_host_file_result" } # end func_convert_file_cygwin_to_w32 # func_convert_file_nix_to_w32 ARG # Convert file name ARG from *nix to w32 format. Requires a wine environment # and a working winepath. Returns result in func_to_host_file_result. func_convert_file_nix_to_w32 () { $debug_cmd func_to_host_file_result=$1 if test -n "$1"; then func_convert_core_file_wine_to_w32 "$1" func_to_host_file_result=$func_convert_core_file_wine_to_w32_result fi func_convert_file_check "$1" "$func_to_host_file_result" } # end func_convert_file_nix_to_w32 # func_convert_file_msys_to_cygwin ARG # Convert file name ARG from MSYS to Cygwin format. Requires LT_CYGPATH set. # Returns result in func_to_host_file_result. func_convert_file_msys_to_cygwin () { $debug_cmd func_to_host_file_result=$1 if test -n "$1"; then func_convert_core_msys_to_w32 "$1" func_cygpath -u "$func_convert_core_msys_to_w32_result" func_to_host_file_result=$func_cygpath_result fi func_convert_file_check "$1" "$func_to_host_file_result" } # end func_convert_file_msys_to_cygwin # func_convert_file_nix_to_cygwin ARG # Convert file name ARG from *nix to Cygwin format. Requires Cygwin installed # in a wine environment, working winepath, and LT_CYGPATH set. Returns result # in func_to_host_file_result. func_convert_file_nix_to_cygwin () { $debug_cmd func_to_host_file_result=$1 if test -n "$1"; then # convert from *nix to w32, then use cygpath to convert from w32 to cygwin. func_convert_core_file_wine_to_w32 "$1" func_cygpath -u "$func_convert_core_file_wine_to_w32_result" func_to_host_file_result=$func_cygpath_result fi func_convert_file_check "$1" "$func_to_host_file_result" } # end func_convert_file_nix_to_cygwin ############################################# # $build to $host PATH CONVERSION FUNCTIONS # ############################################# # invoked via '$to_host_path_cmd ARG' # # In each case, ARG is the path to be converted from $build to $host format. # The result will be available in $func_to_host_path_result. # # Path separators are also converted from $build format to $host format. If # ARG begins or ends with a path separator character, it is preserved (but # converted to $host format) on output. # # All path conversion functions are named using the following convention: # file name conversion function : func_convert_file_X_to_Y () # path conversion function : func_convert_path_X_to_Y () # where, for any given $build/$host combination the 'X_to_Y' value is the # same. If conversion functions are added for new $build/$host combinations, # the two new functions must follow this pattern, or func_init_to_host_path_cmd # will break. # func_init_to_host_path_cmd # Ensures that function "pointer" variable $to_host_path_cmd is set to the # appropriate value, based on the value of $to_host_file_cmd. to_host_path_cmd= func_init_to_host_path_cmd () { $debug_cmd if test -z "$to_host_path_cmd"; then func_stripname 'func_convert_file_' '' "$to_host_file_cmd" to_host_path_cmd=func_convert_path_$func_stripname_result fi } # func_to_host_path ARG # Converts the path ARG from $build format to $host format. Return result # in func_to_host_path_result. func_to_host_path () { $debug_cmd func_init_to_host_path_cmd $to_host_path_cmd "$1" } # end func_to_host_path # func_convert_path_noop ARG # Copy ARG to func_to_host_path_result. func_convert_path_noop () { func_to_host_path_result=$1 } # end func_convert_path_noop # func_convert_path_msys_to_w32 ARG # Convert path ARG from (mingw) MSYS to (mingw) w32 format; automatic # conversion to w32 is not available inside the cwrapper. Returns result in # func_to_host_path_result. func_convert_path_msys_to_w32 () { $debug_cmd func_to_host_path_result=$1 if test -n "$1"; then # Remove leading and trailing path separator characters from ARG. MSYS # behavior is inconsistent here; cygpath turns them into '.;' and ';.'; # and winepath ignores them completely. func_stripname : : "$1" func_to_host_path_tmp1=$func_stripname_result func_convert_core_msys_to_w32 "$func_to_host_path_tmp1" func_to_host_path_result=$func_convert_core_msys_to_w32_result func_convert_path_check : ";" \ "$func_to_host_path_tmp1" "$func_to_host_path_result" func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" fi } # end func_convert_path_msys_to_w32 # func_convert_path_cygwin_to_w32 ARG # Convert path ARG from Cygwin to w32 format. Returns result in # func_to_host_file_result. func_convert_path_cygwin_to_w32 () { $debug_cmd func_to_host_path_result=$1 if test -n "$1"; then # See func_convert_path_msys_to_w32: func_stripname : : "$1" func_to_host_path_tmp1=$func_stripname_result func_to_host_path_result=`cygpath -m -p "$func_to_host_path_tmp1"` func_convert_path_check : ";" \ "$func_to_host_path_tmp1" "$func_to_host_path_result" func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" fi } # end func_convert_path_cygwin_to_w32 # func_convert_path_nix_to_w32 ARG # Convert path ARG from *nix to w32 format. Requires a wine environment and # a working winepath. Returns result in func_to_host_file_result. func_convert_path_nix_to_w32 () { $debug_cmd func_to_host_path_result=$1 if test -n "$1"; then # See func_convert_path_msys_to_w32: func_stripname : : "$1" func_to_host_path_tmp1=$func_stripname_result func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1" func_to_host_path_result=$func_convert_core_path_wine_to_w32_result func_convert_path_check : ";" \ "$func_to_host_path_tmp1" "$func_to_host_path_result" func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" fi } # end func_convert_path_nix_to_w32 # func_convert_path_msys_to_cygwin ARG # Convert path ARG from MSYS to Cygwin format. Requires LT_CYGPATH set. # Returns result in func_to_host_file_result. func_convert_path_msys_to_cygwin () { $debug_cmd func_to_host_path_result=$1 if test -n "$1"; then # See func_convert_path_msys_to_w32: func_stripname : : "$1" func_to_host_path_tmp1=$func_stripname_result func_convert_core_msys_to_w32 "$func_to_host_path_tmp1" func_cygpath -u -p "$func_convert_core_msys_to_w32_result" func_to_host_path_result=$func_cygpath_result func_convert_path_check : : \ "$func_to_host_path_tmp1" "$func_to_host_path_result" func_convert_path_front_back_pathsep ":*" "*:" : "$1" fi } # end func_convert_path_msys_to_cygwin # func_convert_path_nix_to_cygwin ARG # Convert path ARG from *nix to Cygwin format. Requires Cygwin installed in a # a wine environment, working winepath, and LT_CYGPATH set. Returns result in # func_to_host_file_result. func_convert_path_nix_to_cygwin () { $debug_cmd func_to_host_path_result=$1 if test -n "$1"; then # Remove leading and trailing path separator characters from # ARG. msys behavior is inconsistent here, cygpath turns them # into '.;' and ';.', and winepath ignores them completely. func_stripname : : "$1" func_to_host_path_tmp1=$func_stripname_result func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1" func_cygpath -u -p "$func_convert_core_path_wine_to_w32_result" func_to_host_path_result=$func_cygpath_result func_convert_path_check : : \ "$func_to_host_path_tmp1" "$func_to_host_path_result" func_convert_path_front_back_pathsep ":*" "*:" : "$1" fi } # end func_convert_path_nix_to_cygwin # func_dll_def_p FILE # True iff FILE is a Windows DLL '.def' file. # Keep in sync with _LT_DLL_DEF_P in libtool.m4 func_dll_def_p () { $debug_cmd func_dll_def_p_tmp=`$SED -n \ -e 's/^[ ]*//' \ -e '/^\(;.*\)*$/d' \ -e 's/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p' \ -e q \ "$1"` test DEF = "$func_dll_def_p_tmp" } # func_mode_compile arg... func_mode_compile () { $debug_cmd # Get the compilation command and the source file. base_compile= srcfile=$nonopt # always keep a non-empty value in "srcfile" suppress_opt=yes suppress_output= arg_mode=normal libobj= later= pie_flag= for arg do case $arg_mode in arg ) # do not "continue". Instead, add this to base_compile lastarg=$arg arg_mode=normal ;; target ) libobj=$arg arg_mode=normal continue ;; normal ) # Accept any command-line options. case $arg in -o) test -n "$libobj" && \ func_fatal_error "you cannot specify '-o' more than once" arg_mode=target continue ;; -pie | -fpie | -fPIE) func_append pie_flag " $arg" continue ;; -shared | -static | -prefer-pic | -prefer-non-pic) func_append later " $arg" continue ;; -no-suppress) suppress_opt=no continue ;; -Xcompiler) arg_mode=arg # the next one goes into the "base_compile" arg list continue # The current "srcfile" will either be retained or ;; # replaced later. I would guess that would be a bug. -Wc,*) func_stripname '-Wc,' '' "$arg" args=$func_stripname_result lastarg= save_ifs=$IFS; IFS=, for arg in $args; do IFS=$save_ifs func_append_quoted lastarg "$arg" done IFS=$save_ifs func_stripname ' ' '' "$lastarg" lastarg=$func_stripname_result # Add the arguments to base_compile. func_append base_compile " $lastarg" continue ;; *) # Accept the current argument as the source file. # The previous "srcfile" becomes the current argument. # lastarg=$srcfile srcfile=$arg ;; esac # case $arg ;; esac # case $arg_mode # Aesthetically quote the previous argument. func_append_quoted base_compile "$lastarg" done # for arg case $arg_mode in arg) func_fatal_error "you must specify an argument for -Xcompile" ;; target) func_fatal_error "you must specify a target with '-o'" ;; *) # Get the name of the library object. test -z "$libobj" && { func_basename "$srcfile" libobj=$func_basename_result } ;; esac # Recognize several different file suffixes. # If the user specifies -o file.o, it is replaced with file.lo case $libobj in *.[cCFSifmso] | \ *.ada | *.adb | *.ads | *.asm | \ *.c++ | *.cc | *.ii | *.class | *.cpp | *.cxx | \ *.[fF][09]? | *.for | *.java | *.go | *.obj | *.sx | *.cu | *.cup) func_xform "$libobj" libobj=$func_xform_result ;; esac case $libobj in *.lo) func_lo2o "$libobj"; obj=$func_lo2o_result ;; *) func_fatal_error "cannot determine name of library object from '$libobj'" ;; esac func_infer_tag $base_compile for arg in $later; do case $arg in -shared) test yes = "$build_libtool_libs" \ || func_fatal_configuration "cannot build a shared library" build_old_libs=no continue ;; -static) build_libtool_libs=no build_old_libs=yes continue ;; -prefer-pic) pic_mode=yes continue ;; -prefer-non-pic) pic_mode=no continue ;; esac done func_quote_arg pretty "$libobj" test "X$libobj" != "X$func_quote_arg_result" \ && $ECHO "X$libobj" | $GREP '[]~#^*{};<>?"'"'"' &()|`$[]' \ && func_warning "libobj name '$libobj' may not contain shell special characters." func_dirname_and_basename "$obj" "/" "" objname=$func_basename_result xdir=$func_dirname_result lobj=$xdir$objdir/$objname test -z "$base_compile" && \ func_fatal_help "you must specify a compilation command" # Delete any leftover library objects. if test yes = "$build_old_libs"; then removelist="$obj $lobj $libobj ${libobj}T" else removelist="$lobj $libobj ${libobj}T" fi # On Cygwin there's no "real" PIC flag so we must build both object types case $host_os in cygwin* | mingw* | pw32* | os2* | cegcc*) pic_mode=default ;; esac if test no = "$pic_mode" && test pass_all != "$deplibs_check_method"; then # non-PIC code in shared libraries is not supported pic_mode=default fi # Calculate the filename of the output object if compiler does # not support -o with -c if test no = "$compiler_c_o"; then output_obj=`$ECHO "$srcfile" | $SED 's%^.*/%%; s%\.[^.]*$%%'`.$objext lockfile=$output_obj.lock else output_obj= need_locks=no lockfile= fi # Lock this critical section if it is needed # We use this script file to make the link, it avoids creating a new file if test yes = "$need_locks"; then until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do func_echo "Waiting for $lockfile to be removed" sleep 2 done elif test warn = "$need_locks"; then if test -f "$lockfile"; then $ECHO "\ *** ERROR, $lockfile exists and contains: `cat $lockfile 2>/dev/null` This indicates that another process is trying to use the same temporary object file, and libtool could not work around it because your compiler does not support '-c' and '-o' together. If you repeat this compilation, it may succeed, by chance, but you had better avoid parallel builds (make -j) in this platform, or get a better compiler." $opt_dry_run || $RM $removelist exit $EXIT_FAILURE fi func_append removelist " $output_obj" $ECHO "$srcfile" > "$lockfile" fi $opt_dry_run || $RM $removelist func_append removelist " $lockfile" trap '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' 1 2 15 func_to_tool_file "$srcfile" func_convert_file_msys_to_w32 srcfile=$func_to_tool_file_result func_quote_arg pretty "$srcfile" qsrcfile=$func_quote_arg_result # Only build a PIC object if we are building libtool libraries. if test yes = "$build_libtool_libs"; then # Without this assignment, base_compile gets emptied. fbsd_hideous_sh_bug=$base_compile if test no != "$pic_mode"; then command="$base_compile $qsrcfile $pic_flag" else # Don't build PIC code command="$base_compile $qsrcfile" fi func_mkdir_p "$xdir$objdir" if test -z "$output_obj"; then # Place PIC objects in $objdir func_append command " -o $lobj" fi func_show_eval_locale "$command" \ 'test -n "$output_obj" && $RM $removelist; exit $EXIT_FAILURE' if test warn = "$need_locks" && test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then $ECHO "\ *** ERROR, $lockfile contains: `cat $lockfile 2>/dev/null` but it should contain: $srcfile This indicates that another process is trying to use the same temporary object file, and libtool could not work around it because your compiler does not support '-c' and '-o' together. If you repeat this compilation, it may succeed, by chance, but you had better avoid parallel builds (make -j) in this platform, or get a better compiler." $opt_dry_run || $RM $removelist exit $EXIT_FAILURE fi # Just move the object if needed, then go on to compile the next one if test -n "$output_obj" && test "X$output_obj" != "X$lobj"; then func_show_eval '$MV "$output_obj" "$lobj"' \ 'error=$?; $opt_dry_run || $RM $removelist; exit $error' fi # Allow error messages only from the first compilation. if test yes = "$suppress_opt"; then suppress_output=' >/dev/null 2>&1' fi fi # Only build a position-dependent object if we build old libraries. if test yes = "$build_old_libs"; then if test yes != "$pic_mode"; then # Don't build PIC code command="$base_compile $qsrcfile$pie_flag" else command="$base_compile $qsrcfile $pic_flag" fi if test yes = "$compiler_c_o"; then func_append command " -o $obj" fi # Suppress compiler output if we already did a PIC compilation. func_append command "$suppress_output" func_show_eval_locale "$command" \ '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' if test warn = "$need_locks" && test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then $ECHO "\ *** ERROR, $lockfile contains: `cat $lockfile 2>/dev/null` but it should contain: $srcfile This indicates that another process is trying to use the same temporary object file, and libtool could not work around it because your compiler does not support '-c' and '-o' together. If you repeat this compilation, it may succeed, by chance, but you had better avoid parallel builds (make -j) in this platform, or get a better compiler." $opt_dry_run || $RM $removelist exit $EXIT_FAILURE fi # Just move the object if needed if test -n "$output_obj" && test "X$output_obj" != "X$obj"; then func_show_eval '$MV "$output_obj" "$obj"' \ 'error=$?; $opt_dry_run || $RM $removelist; exit $error' fi fi $opt_dry_run || { func_write_libtool_object "$libobj" "$objdir/$objname" "$objname" # Unlock the critical section if it was locked if test no != "$need_locks"; then removelist=$lockfile $RM "$lockfile" fi } exit $EXIT_SUCCESS } $opt_help || { test compile = "$opt_mode" && func_mode_compile ${1+"$@"} } func_mode_help () { # We need to display help for each of the modes. case $opt_mode in "") # Generic help is extracted from the usage comments # at the start of this file. func_help ;; clean) $ECHO \ "Usage: $progname [OPTION]... --mode=clean RM [RM-OPTION]... FILE... Remove files from the build directory. RM is the name of the program to use to delete files associated with each FILE (typically '/bin/rm'). RM-OPTIONS are options (such as '-f') to be passed to RM. If FILE is a libtool library, object or program, all the files associated with it are deleted. Otherwise, only FILE itself is deleted using RM." ;; compile) $ECHO \ "Usage: $progname [OPTION]... --mode=compile COMPILE-COMMAND... SOURCEFILE Compile a source file into a libtool library object. This mode accepts the following additional options: -o OUTPUT-FILE set the output file name to OUTPUT-FILE -no-suppress do not suppress compiler output for multiple passes -prefer-pic try to build PIC objects only -prefer-non-pic try to build non-PIC objects only -shared do not build a '.o' file suitable for static linking -static only build a '.o' file suitable for static linking -Wc,FLAG -Xcompiler FLAG pass FLAG directly to the compiler COMPILE-COMMAND is a command to be used in creating a 'standard' object file from the given SOURCEFILE. The output file name is determined by removing the directory component from SOURCEFILE, then substituting the C source code suffix '.c' with the library object suffix, '.lo'." ;; execute) $ECHO \ "Usage: $progname [OPTION]... --mode=execute COMMAND [ARGS]... Automatically set library path, then run a program. This mode accepts the following additional options: -dlopen FILE add the directory containing FILE to the library path This mode sets the library path environment variable according to '-dlopen' flags. If any of the ARGS are libtool executable wrappers, then they are translated into their corresponding uninstalled binary, and any of their required library directories are added to the library path. Then, COMMAND is executed, with ARGS as arguments." ;; finish) $ECHO \ "Usage: $progname [OPTION]... --mode=finish [LIBDIR]... Complete the installation of libtool libraries. Each LIBDIR is a directory that contains libtool libraries. The commands that this mode executes may require superuser privileges. Use the '--dry-run' option if you just want to see what would be executed." ;; install) $ECHO \ "Usage: $progname [OPTION]... --mode=install INSTALL-COMMAND... Install executables or libraries. INSTALL-COMMAND is the installation command. The first component should be either the 'install' or 'cp' program. The following components of INSTALL-COMMAND are treated specially: -inst-prefix-dir PREFIX-DIR Use PREFIX-DIR as a staging area for installation The rest of the components are interpreted as arguments to that command (only BSD-compatible install options are recognized)." ;; link) $ECHO \ "Usage: $progname [OPTION]... --mode=link LINK-COMMAND... Link object files or libraries together to form another library, or to create an executable program. LINK-COMMAND is a command using the C compiler that you would use to create a program from several object files. The following components of LINK-COMMAND are treated specially: -all-static do not do any dynamic linking at all -avoid-version do not add a version suffix if possible -bindir BINDIR specify path to binaries directory (for systems where libraries must be found in the PATH setting at runtime) -dlopen FILE '-dlpreopen' FILE if it cannot be dlopened at runtime -dlpreopen FILE link in FILE and add its symbols to lt_preloaded_symbols -export-dynamic allow symbols from OUTPUT-FILE to be resolved with dlsym(3) -export-symbols SYMFILE try to export only the symbols listed in SYMFILE -export-symbols-regex REGEX try to export only the symbols matching REGEX -LLIBDIR search LIBDIR for required installed libraries -lNAME OUTPUT-FILE requires the installed library libNAME -module build a library that can dlopened -no-fast-install disable the fast-install mode -no-install link a not-installable executable -no-undefined declare that a library does not refer to external symbols -o OUTPUT-FILE create OUTPUT-FILE from the specified objects -objectlist FILE use a list of object files found in FILE to specify objects -os2dllname NAME force a short DLL name on OS/2 (no effect on other OSes) -precious-files-regex REGEX don't remove output files matching REGEX -release RELEASE specify package release information -rpath LIBDIR the created library will eventually be installed in LIBDIR -R[ ]LIBDIR add LIBDIR to the runtime path of programs and libraries -shared only do dynamic linking of libtool libraries -shrext SUFFIX override the standard shared library file extension -static do not do any dynamic linking of uninstalled libtool libraries -static-libtool-libs do not do any dynamic linking of libtool libraries -version-info CURRENT[:REVISION[:AGE]] specify library version info [each variable defaults to 0] -weak LIBNAME declare that the target provides the LIBNAME interface -Wc,FLAG -Xcompiler FLAG pass linker-specific FLAG directly to the compiler -Wa,FLAG -Xassembler FLAG pass linker-specific FLAG directly to the assembler -Wl,FLAG -Xlinker FLAG pass linker-specific FLAG directly to the linker -XCClinker FLAG pass link-specific FLAG to the compiler driver (CC) All other options (arguments beginning with '-') are ignored. Every other argument is treated as a filename. Files ending in '.la' are treated as uninstalled libtool libraries, other files are standard or library object files. If the OUTPUT-FILE ends in '.la', then a libtool library is created, only library objects ('.lo' files) may be specified, and '-rpath' is required, except when creating a convenience library. If OUTPUT-FILE ends in '.a' or '.lib', then a standard library is created using 'ar' and 'ranlib', or on Windows using 'lib'. If OUTPUT-FILE ends in '.lo' or '.$objext', then a reloadable object file is created, otherwise an executable program is created." ;; uninstall) $ECHO \ "Usage: $progname [OPTION]... --mode=uninstall RM [RM-OPTION]... FILE... Remove libraries from an installation directory. RM is the name of the program to use to delete files associated with each FILE (typically '/bin/rm'). RM-OPTIONS are options (such as '-f') to be passed to RM. If FILE is a libtool library, all the files associated with it are deleted. Otherwise, only FILE itself is deleted using RM." ;; *) func_fatal_help "invalid operation mode '$opt_mode'" ;; esac echo $ECHO "Try '$progname --help' for more information about other modes." } # Now that we've collected a possible --mode arg, show help if necessary if $opt_help; then if test : = "$opt_help"; then func_mode_help else { func_help noexit for opt_mode in compile link execute install finish uninstall clean; do func_mode_help done } | $SED -n '1p; 2,$s/^Usage:/ or: /p' { func_help noexit for opt_mode in compile link execute install finish uninstall clean; do echo func_mode_help done } | $SED '1d /^When reporting/,/^Report/{ H d } $x /information about other modes/d /more detailed .*MODE/d s/^Usage:.*--mode=\([^ ]*\) .*/Description of \1 mode:/' fi exit $? fi # func_mode_execute arg... func_mode_execute () { $debug_cmd # The first argument is the command name. cmd=$nonopt test -z "$cmd" && \ func_fatal_help "you must specify a COMMAND" # Handle -dlopen flags immediately. for file in $opt_dlopen; do test -f "$file" \ || func_fatal_help "'$file' is not a file" dir= case $file in *.la) func_resolve_sysroot "$file" file=$func_resolve_sysroot_result # Check to see that this really is a libtool archive. func_lalib_unsafe_p "$file" \ || func_fatal_help "'$lib' is not a valid libtool archive" # Read the libtool library. dlname= library_names= func_source "$file" # Skip this library if it cannot be dlopened. if test -z "$dlname"; then # Warn if it was a shared library. test -n "$library_names" && \ func_warning "'$file' was not linked with '-export-dynamic'" continue fi func_dirname "$file" "" "." dir=$func_dirname_result if test -f "$dir/$objdir/$dlname"; then func_append dir "/$objdir" else if test ! -f "$dir/$dlname"; then func_fatal_error "cannot find '$dlname' in '$dir' or '$dir/$objdir'" fi fi ;; *.lo) # Just add the directory containing the .lo file. func_dirname "$file" "" "." dir=$func_dirname_result ;; *) func_warning "'-dlopen' is ignored for non-libtool libraries and objects" continue ;; esac # Get the absolute pathname. absdir=`cd "$dir" && pwd` test -n "$absdir" && dir=$absdir # Now add the directory to shlibpath_var. if eval "test -z \"\$$shlibpath_var\""; then eval "$shlibpath_var=\"\$dir\"" else eval "$shlibpath_var=\"\$dir:\$$shlibpath_var\"" fi done # This variable tells wrapper scripts just to set shlibpath_var # rather than running their programs. libtool_execute_magic=$magic # Check if any of the arguments is a wrapper script. args= for file do case $file in -* | *.la | *.lo ) ;; *) # Do a test to see if this is really a libtool program. if func_ltwrapper_script_p "$file"; then func_source "$file" # Transform arg to wrapped name. file=$progdir/$program elif func_ltwrapper_executable_p "$file"; then func_ltwrapper_scriptname "$file" func_source "$func_ltwrapper_scriptname_result" # Transform arg to wrapped name. file=$progdir/$program fi ;; esac # Quote arguments (to preserve shell metacharacters). func_append_quoted args "$file" done if $opt_dry_run; then # Display what would be done. if test -n "$shlibpath_var"; then eval "\$ECHO \"\$shlibpath_var=\$$shlibpath_var\"" echo "export $shlibpath_var" fi $ECHO "$cmd$args" exit $EXIT_SUCCESS else if test -n "$shlibpath_var"; then # Export the shlibpath_var. eval "export $shlibpath_var" fi # Restore saved environment variables for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES do eval "if test \"\${save_$lt_var+set}\" = set; then $lt_var=\$save_$lt_var; export $lt_var else $lt_unset $lt_var fi" done # Now prepare to actually exec the command. exec_cmd=\$cmd$args fi } test execute = "$opt_mode" && func_mode_execute ${1+"$@"} # func_mode_finish arg... func_mode_finish () { $debug_cmd libs= libdirs= admincmds= for opt in "$nonopt" ${1+"$@"} do if test -d "$opt"; then func_append libdirs " $opt" elif test -f "$opt"; then if func_lalib_unsafe_p "$opt"; then func_append libs " $opt" else func_warning "'$opt' is not a valid libtool archive" fi else func_fatal_error "invalid argument '$opt'" fi done if test -n "$libs"; then if test -n "$lt_sysroot"; then sysroot_regex=`$ECHO "$lt_sysroot" | $SED "$sed_make_literal_regex"` sysroot_cmd="s/\([ ']\)$sysroot_regex/\1/g;" else sysroot_cmd= fi # Remove sysroot references if $opt_dry_run; then for lib in $libs; do echo "removing references to $lt_sysroot and '=' prefixes from $lib" done else tmpdir=`func_mktempdir` for lib in $libs; do $SED -e "$sysroot_cmd s/\([ ']-[LR]\)=/\1/g; s/\([ ']\)=/\1/g" $lib \ > $tmpdir/tmp-la mv -f $tmpdir/tmp-la $lib done ${RM}r "$tmpdir" fi fi if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then for libdir in $libdirs; do if test -n "$finish_cmds"; then # Do each command in the finish commands. func_execute_cmds "$finish_cmds" 'admincmds="$admincmds '"$cmd"'"' fi if test -n "$finish_eval"; then # Do the single finish_eval. eval cmds=\"$finish_eval\" $opt_dry_run || eval "$cmds" || func_append admincmds " $cmds" fi done fi # Exit here if they wanted silent mode. $opt_quiet && exit $EXIT_SUCCESS if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then echo "----------------------------------------------------------------------" echo "Libraries have been installed in:" for libdir in $libdirs; do $ECHO " $libdir" done echo echo "If you ever happen to want to link against installed libraries" echo "in a given directory, LIBDIR, you must either use libtool, and" echo "specify the full pathname of the library, or use the '-LLIBDIR'" echo "flag during linking and do at least one of the following:" if test -n "$shlibpath_var"; then echo " - add LIBDIR to the '$shlibpath_var' environment variable" echo " during execution" fi if test -n "$runpath_var"; then echo " - add LIBDIR to the '$runpath_var' environment variable" echo " during linking" fi if test -n "$hardcode_libdir_flag_spec"; then libdir=LIBDIR eval flag=\"$hardcode_libdir_flag_spec\" $ECHO " - use the '$flag' linker flag" fi if test -n "$admincmds"; then $ECHO " - have your system administrator run these commands:$admincmds" fi if test -f /etc/ld.so.conf; then echo " - have your system administrator add LIBDIR to '/etc/ld.so.conf'" fi echo echo "See any operating system documentation about shared libraries for" case $host in solaris2.[6789]|solaris2.1[0-9]) echo "more information, such as the ld(1), crle(1) and ld.so(8) manual" echo "pages." ;; *) echo "more information, such as the ld(1) and ld.so(8) manual pages." ;; esac echo "----------------------------------------------------------------------" fi exit $EXIT_SUCCESS } test finish = "$opt_mode" && func_mode_finish ${1+"$@"} # func_mode_install arg... func_mode_install () { $debug_cmd # There may be an optional sh(1) argument at the beginning of # install_prog (especially on Windows NT). if test "$SHELL" = "$nonopt" || test /bin/sh = "$nonopt" || # Allow the use of GNU shtool's install command. case $nonopt in *shtool*) :;; *) false;; esac then # Aesthetically quote it. func_quote_arg pretty "$nonopt" install_prog="$func_quote_arg_result " arg=$1 shift else install_prog= arg=$nonopt fi # The real first argument should be the name of the installation program. # Aesthetically quote it. func_quote_arg pretty "$arg" func_append install_prog "$func_quote_arg_result" install_shared_prog=$install_prog case " $install_prog " in *[\\\ /]cp\ *) install_cp=: ;; *) install_cp=false ;; esac # We need to accept at least all the BSD install flags. dest= files= opts= prev= install_type= isdir=false stripme= no_mode=: for arg do arg2= if test -n "$dest"; then func_append files " $dest" dest=$arg continue fi case $arg in -d) isdir=: ;; -f) if $install_cp; then :; else prev=$arg fi ;; -g | -m | -o) prev=$arg ;; -s) stripme=" -s" continue ;; -*) ;; *) # If the previous option needed an argument, then skip it. if test -n "$prev"; then if test X-m = "X$prev" && test -n "$install_override_mode"; then arg2=$install_override_mode no_mode=false fi prev= else dest=$arg continue fi ;; esac # Aesthetically quote the argument. func_quote_arg pretty "$arg" func_append install_prog " $func_quote_arg_result" if test -n "$arg2"; then func_quote_arg pretty "$arg2" fi func_append install_shared_prog " $func_quote_arg_result" done test -z "$install_prog" && \ func_fatal_help "you must specify an install program" test -n "$prev" && \ func_fatal_help "the '$prev' option requires an argument" if test -n "$install_override_mode" && $no_mode; then if $install_cp; then :; else func_quote_arg pretty "$install_override_mode" func_append install_shared_prog " -m $func_quote_arg_result" fi fi if test -z "$files"; then if test -z "$dest"; then func_fatal_help "no file or destination specified" else func_fatal_help "you must specify a destination" fi fi # Strip any trailing slash from the destination. func_stripname '' '/' "$dest" dest=$func_stripname_result # Check to see that the destination is a directory. test -d "$dest" && isdir=: if $isdir; then destdir=$dest destname= else func_dirname_and_basename "$dest" "" "." destdir=$func_dirname_result destname=$func_basename_result # Not a directory, so check to see that there is only one file specified. set dummy $files; shift test "$#" -gt 1 && \ func_fatal_help "'$dest' is not a directory" fi case $destdir in [\\/]* | [A-Za-z]:[\\/]*) ;; *) for file in $files; do case $file in *.lo) ;; *) func_fatal_help "'$destdir' must be an absolute directory name" ;; esac done ;; esac # This variable tells wrapper scripts just to set variables rather # than running their programs. libtool_install_magic=$magic staticlibs= future_libdirs= current_libdirs= for file in $files; do # Do each installation. case $file in *.$libext) # Do the static libraries later. func_append staticlibs " $file" ;; *.la) func_resolve_sysroot "$file" file=$func_resolve_sysroot_result # Check to see that this really is a libtool archive. func_lalib_unsafe_p "$file" \ || func_fatal_help "'$file' is not a valid libtool archive" library_names= old_library= relink_command= func_source "$file" # Add the libdir to current_libdirs if it is the destination. if test "X$destdir" = "X$libdir"; then case "$current_libdirs " in *" $libdir "*) ;; *) func_append current_libdirs " $libdir" ;; esac else # Note the libdir as a future libdir. case "$future_libdirs " in *" $libdir "*) ;; *) func_append future_libdirs " $libdir" ;; esac fi func_dirname "$file" "/" "" dir=$func_dirname_result func_append dir "$objdir" if test -n "$relink_command"; then # Determine the prefix the user has applied to our future dir. inst_prefix_dir=`$ECHO "$destdir" | $SED -e "s%$libdir\$%%"` # Don't allow the user to place us outside of our expected # location b/c this prevents finding dependent libraries that # are installed to the same prefix. # At present, this check doesn't affect windows .dll's that # are installed into $libdir/../bin (currently, that works fine) # but it's something to keep an eye on. test "$inst_prefix_dir" = "$destdir" && \ func_fatal_error "error: cannot install '$file' to a directory not ending in $libdir" if test -n "$inst_prefix_dir"; then # Stick the inst_prefix_dir data into the link command. relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%"` else relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%%"` fi func_warning "relinking '$file'" func_show_eval "$relink_command" \ 'func_fatal_error "error: relink '\''$file'\'' with the above command before installing it"' fi # See the names of the shared library. set dummy $library_names; shift if test -n "$1"; then realname=$1 shift srcname=$realname test -n "$relink_command" && srcname=${realname}T # Install the shared library and build the symlinks. func_show_eval "$install_shared_prog $dir/$srcname $destdir/$realname" \ 'exit $?' tstripme=$stripme case $host_os in cygwin* | mingw* | pw32* | cegcc*) case $realname in *.dll.a) tstripme= ;; esac ;; os2*) case $realname in *_dll.a) tstripme= ;; esac ;; esac if test -n "$tstripme" && test -n "$striplib"; then func_show_eval "$striplib $destdir/$realname" 'exit $?' fi if test "$#" -gt 0; then # Delete the old symlinks, and create new ones. # Try 'ln -sf' first, because the 'ln' binary might depend on # the symlink we replace! Solaris /bin/ln does not understand -f, # so we also need to try rm && ln -s. for linkname do test "$linkname" != "$realname" \ && func_show_eval "(cd $destdir && { $LN_S -f $realname $linkname || { $RM $linkname && $LN_S $realname $linkname; }; })" done fi # Do each command in the postinstall commands. lib=$destdir/$realname func_execute_cmds "$postinstall_cmds" 'exit $?' fi # Install the pseudo-library for information purposes. func_basename "$file" name=$func_basename_result instname=$dir/${name}i func_show_eval "$install_prog $instname $destdir/$name" 'exit $?' # Maybe install the static library, too. test -n "$old_library" && func_append staticlibs " $dir/$old_library" ;; *.lo) # Install (i.e. copy) a libtool object. # Figure out destination file name, if it wasn't already specified. if test -n "$destname"; then destfile=$destdir/$destname else func_basename "$file" destfile=$func_basename_result destfile=$destdir/$destfile fi # Deduce the name of the destination old-style object file. case $destfile in *.lo) func_lo2o "$destfile" staticdest=$func_lo2o_result ;; *.$objext) staticdest=$destfile destfile= ;; *) func_fatal_help "cannot copy a libtool object to '$destfile'" ;; esac # Install the libtool object if requested. test -n "$destfile" && \ func_show_eval "$install_prog $file $destfile" 'exit $?' # Install the old object if enabled. if test yes = "$build_old_libs"; then # Deduce the name of the old-style object file. func_lo2o "$file" staticobj=$func_lo2o_result func_show_eval "$install_prog \$staticobj \$staticdest" 'exit $?' fi exit $EXIT_SUCCESS ;; *) # Figure out destination file name, if it wasn't already specified. if test -n "$destname"; then destfile=$destdir/$destname else func_basename "$file" destfile=$func_basename_result destfile=$destdir/$destfile fi # If the file is missing, and there is a .exe on the end, strip it # because it is most likely a libtool script we actually want to # install stripped_ext= case $file in *.exe) if test ! -f "$file"; then func_stripname '' '.exe' "$file" file=$func_stripname_result stripped_ext=.exe fi ;; esac # Do a test to see if this is really a libtool program. case $host in *cygwin* | *mingw*) if func_ltwrapper_executable_p "$file"; then func_ltwrapper_scriptname "$file" wrapper=$func_ltwrapper_scriptname_result else func_stripname '' '.exe' "$file" wrapper=$func_stripname_result fi ;; *) wrapper=$file ;; esac if func_ltwrapper_script_p "$wrapper"; then notinst_deplibs= relink_command= func_source "$wrapper" # Check the variables that should have been set. test -z "$generated_by_libtool_version" && \ func_fatal_error "invalid libtool wrapper script '$wrapper'" finalize=: for lib in $notinst_deplibs; do # Check to see that each library is installed. libdir= if test -f "$lib"; then func_source "$lib" fi libfile=$libdir/`$ECHO "$lib" | $SED 's%^.*/%%g'` if test -n "$libdir" && test ! -f "$libfile"; then func_warning "'$lib' has not been installed in '$libdir'" finalize=false fi done relink_command= func_source "$wrapper" outputname= if test no = "$fast_install" && test -n "$relink_command"; then $opt_dry_run || { if $finalize; then tmpdir=`func_mktempdir` func_basename "$file$stripped_ext" file=$func_basename_result outputname=$tmpdir/$file # Replace the output file specification. relink_command=`$ECHO "$relink_command" | $SED 's%@OUTPUT@%'"$outputname"'%g'` $opt_quiet || { func_quote_arg expand,pretty "$relink_command" eval "func_echo $func_quote_arg_result" } if eval "$relink_command"; then : else func_error "error: relink '$file' with the above command before installing it" $opt_dry_run || ${RM}r "$tmpdir" continue fi file=$outputname else func_warning "cannot relink '$file'" fi } else # Install the binary that we compiled earlier. file=`$ECHO "$file$stripped_ext" | $SED "s%\([^/]*\)$%$objdir/\1%"` fi fi # remove .exe since cygwin /usr/bin/install will append another # one anyway case $install_prog,$host in */usr/bin/install*,*cygwin*) case $file:$destfile in *.exe:*.exe) # this is ok ;; *.exe:*) destfile=$destfile.exe ;; *:*.exe) func_stripname '' '.exe' "$destfile" destfile=$func_stripname_result ;; esac ;; esac func_show_eval "$install_prog\$stripme \$file \$destfile" 'exit $?' $opt_dry_run || if test -n "$outputname"; then ${RM}r "$tmpdir" fi ;; esac done for file in $staticlibs; do func_basename "$file" name=$func_basename_result # Set up the ranlib parameters. oldlib=$destdir/$name func_to_tool_file "$oldlib" func_convert_file_msys_to_w32 tool_oldlib=$func_to_tool_file_result func_show_eval "$install_prog \$file \$oldlib" 'exit $?' if test -n "$stripme" && test -n "$old_striplib"; then func_show_eval "$old_striplib $tool_oldlib" 'exit $?' fi # Do each command in the postinstall commands. func_execute_cmds "$old_postinstall_cmds" 'exit $?' done test -n "$future_libdirs" && \ func_warning "remember to run '$progname --finish$future_libdirs'" if test -n "$current_libdirs"; then # Maybe just do a dry run. $opt_dry_run && current_libdirs=" -n$current_libdirs" exec_cmd='$SHELL "$progpath" $preserve_args --finish$current_libdirs' else exit $EXIT_SUCCESS fi } test install = "$opt_mode" && func_mode_install ${1+"$@"} # func_generate_dlsyms outputname originator pic_p # Extract symbols from dlprefiles and create ${outputname}S.o with # a dlpreopen symbol table. func_generate_dlsyms () { $debug_cmd my_outputname=$1 my_originator=$2 my_pic_p=${3-false} my_prefix=`$ECHO "$my_originator" | $SED 's%[^a-zA-Z0-9]%_%g'` my_dlsyms= if test -n "$dlfiles$dlprefiles" || test no != "$dlself"; then if test -n "$NM" && test -n "$global_symbol_pipe"; then my_dlsyms=${my_outputname}S.c else func_error "not configured to extract global symbols from dlpreopened files" fi fi if test -n "$my_dlsyms"; then case $my_dlsyms in "") ;; *.c) # Discover the nlist of each of the dlfiles. nlist=$output_objdir/$my_outputname.nm func_show_eval "$RM $nlist ${nlist}S ${nlist}T" # Parse the name list into a source file. func_verbose "creating $output_objdir/$my_dlsyms" $opt_dry_run || $ECHO > "$output_objdir/$my_dlsyms" "\ /* $my_dlsyms - symbol resolution table for '$my_outputname' dlsym emulation. */ /* Generated by $PROGRAM (GNU $PACKAGE) $VERSION */ #ifdef __cplusplus extern \"C\" { #endif #if defined __GNUC__ && (((__GNUC__ == 4) && (__GNUC_MINOR__ >= 4)) || (__GNUC__ > 4)) #pragma GCC diagnostic ignored \"-Wstrict-prototypes\" #endif /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ #if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE /* DATA imports from DLLs on WIN32 can't be const, because runtime relocations are performed -- see ld's documentation on pseudo-relocs. */ # define LT_DLSYM_CONST #elif defined __osf__ /* This system does not cope well with relocations in const data. */ # define LT_DLSYM_CONST #else # define LT_DLSYM_CONST const #endif #define STREQ(s1, s2) (strcmp ((s1), (s2)) == 0) /* External symbol declarations for the compiler. */\ " if test yes = "$dlself"; then func_verbose "generating symbol list for '$output'" $opt_dry_run || echo ': @PROGRAM@ ' > "$nlist" # Add our own program objects to the symbol list. progfiles=`$ECHO "$objs$old_deplibs" | $SP2NL | $SED "$lo2o" | $NL2SP` for progfile in $progfiles; do func_to_tool_file "$progfile" func_convert_file_msys_to_w32 func_verbose "extracting global C symbols from '$func_to_tool_file_result'" $opt_dry_run || eval "$NM $func_to_tool_file_result | $global_symbol_pipe >> '$nlist'" done if test -n "$exclude_expsyms"; then $opt_dry_run || { eval '$EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T' eval '$MV "$nlist"T "$nlist"' } fi if test -n "$export_symbols_regex"; then $opt_dry_run || { eval '$EGREP -e "$export_symbols_regex" "$nlist" > "$nlist"T' eval '$MV "$nlist"T "$nlist"' } fi # Prepare the list of exported symbols if test -z "$export_symbols"; then export_symbols=$output_objdir/$outputname.exp $opt_dry_run || { $RM $export_symbols eval "$SED -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"' case $host in *cygwin* | *mingw* | *cegcc* ) eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"' ;; esac } else $opt_dry_run || { eval "$SED -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"' eval '$GREP -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T' eval '$MV "$nlist"T "$nlist"' case $host in *cygwin* | *mingw* | *cegcc* ) eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' eval 'cat "$nlist" >> "$output_objdir/$outputname.def"' ;; esac } fi fi for dlprefile in $dlprefiles; do func_verbose "extracting global C symbols from '$dlprefile'" func_basename "$dlprefile" name=$func_basename_result case $host in *cygwin* | *mingw* | *cegcc* ) # if an import library, we need to obtain dlname if func_win32_import_lib_p "$dlprefile"; then func_tr_sh "$dlprefile" eval "curr_lafile=\$libfile_$func_tr_sh_result" dlprefile_dlbasename= if test -n "$curr_lafile" && func_lalib_p "$curr_lafile"; then # Use subshell, to avoid clobbering current variable values dlprefile_dlname=`source "$curr_lafile" && echo "$dlname"` if test -n "$dlprefile_dlname"; then func_basename "$dlprefile_dlname" dlprefile_dlbasename=$func_basename_result else # no lafile. user explicitly requested -dlpreopen . $sharedlib_from_linklib_cmd "$dlprefile" dlprefile_dlbasename=$sharedlib_from_linklib_result fi fi $opt_dry_run || { if test -n "$dlprefile_dlbasename"; then eval '$ECHO ": $dlprefile_dlbasename" >> "$nlist"' else func_warning "Could not compute DLL name from $name" eval '$ECHO ": $name " >> "$nlist"' fi func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe | $SED -e '/I __imp/d' -e 's/I __nm_/D /;s/_nm__//' >> '$nlist'" } else # not an import lib $opt_dry_run || { eval '$ECHO ": $name " >> "$nlist"' func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" } fi ;; *) $opt_dry_run || { eval '$ECHO ": $name " >> "$nlist"' func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" } ;; esac done $opt_dry_run || { # Make sure we have at least an empty file. test -f "$nlist" || : > "$nlist" if test -n "$exclude_expsyms"; then $EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T $MV "$nlist"T "$nlist" fi # Try sorting and uniquifying the output. if $GREP -v "^: " < "$nlist" | if sort -k 3 /dev/null 2>&1; then sort -k 3 else sort +2 fi | uniq > "$nlist"S; then : else $GREP -v "^: " < "$nlist" > "$nlist"S fi if test -f "$nlist"S; then eval "$global_symbol_to_cdecl"' < "$nlist"S >> "$output_objdir/$my_dlsyms"' else echo '/* NONE */' >> "$output_objdir/$my_dlsyms" fi func_show_eval '$RM "${nlist}I"' if test -n "$global_symbol_to_import"; then eval "$global_symbol_to_import"' < "$nlist"S > "$nlist"I' fi echo >> "$output_objdir/$my_dlsyms" "\ /* The mapping between symbol names and symbols. */ typedef struct { const char *name; void *address; } lt_dlsymlist; extern LT_DLSYM_CONST lt_dlsymlist lt_${my_prefix}_LTX_preloaded_symbols[];\ " if test -s "$nlist"I; then echo >> "$output_objdir/$my_dlsyms" "\ static void lt_syminit(void) { LT_DLSYM_CONST lt_dlsymlist *symbol = lt_${my_prefix}_LTX_preloaded_symbols; for (; symbol->name; ++symbol) {" $SED 's/.*/ if (STREQ (symbol->name, \"&\")) symbol->address = (void *) \&&;/' < "$nlist"I >> "$output_objdir/$my_dlsyms" echo >> "$output_objdir/$my_dlsyms" "\ } }" fi echo >> "$output_objdir/$my_dlsyms" "\ LT_DLSYM_CONST lt_dlsymlist lt_${my_prefix}_LTX_preloaded_symbols[] = { {\"$my_originator\", (void *) 0}," if test -s "$nlist"I; then echo >> "$output_objdir/$my_dlsyms" "\ {\"@INIT@\", (void *) <_syminit}," fi case $need_lib_prefix in no) eval "$global_symbol_to_c_name_address" < "$nlist" >> "$output_objdir/$my_dlsyms" ;; *) eval "$global_symbol_to_c_name_address_lib_prefix" < "$nlist" >> "$output_objdir/$my_dlsyms" ;; esac echo >> "$output_objdir/$my_dlsyms" "\ {0, (void *) 0} }; /* This works around a problem in FreeBSD linker */ #ifdef FREEBSD_WORKAROUND static const void *lt_preloaded_setup() { return lt_${my_prefix}_LTX_preloaded_symbols; } #endif #ifdef __cplusplus } #endif\ " } # !$opt_dry_run pic_flag_for_symtable= case "$compile_command " in *" -static "*) ;; *) case $host in # compiling the symbol table file with pic_flag works around # a FreeBSD bug that causes programs to crash when -lm is # linked before any other PIC object. But we must not use # pic_flag when linking with -static. The problem exists in # FreeBSD 2.2.6 and is fixed in FreeBSD 3.1. *-*-freebsd2.*|*-*-freebsd3.0*|*-*-freebsdelf3.0*) pic_flag_for_symtable=" $pic_flag -DFREEBSD_WORKAROUND" ;; *-*-hpux*) pic_flag_for_symtable=" $pic_flag" ;; *) $my_pic_p && pic_flag_for_symtable=" $pic_flag" ;; esac ;; esac symtab_cflags= for arg in $LTCFLAGS; do case $arg in -pie | -fpie | -fPIE) ;; *) func_append symtab_cflags " $arg" ;; esac done # Now compile the dynamic symbol file. func_show_eval '(cd $output_objdir && $LTCC$symtab_cflags -c$no_builtin_flag$pic_flag_for_symtable "$my_dlsyms")' 'exit $?' # Clean up the generated files. func_show_eval '$RM "$output_objdir/$my_dlsyms" "$nlist" "${nlist}S" "${nlist}T" "${nlist}I"' # Transform the symbol file into the correct name. symfileobj=$output_objdir/${my_outputname}S.$objext case $host in *cygwin* | *mingw* | *cegcc* ) if test -f "$output_objdir/$my_outputname.def"; then compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` else compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"` finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"` fi ;; *) compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"` finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"` ;; esac ;; *) func_fatal_error "unknown suffix for '$my_dlsyms'" ;; esac else # We keep going just in case the user didn't refer to # lt_preloaded_symbols. The linker will fail if global_symbol_pipe # really was required. # Nullify the symbol file. compile_command=`$ECHO "$compile_command" | $SED "s% @SYMFILE@%%"` finalize_command=`$ECHO "$finalize_command" | $SED "s% @SYMFILE@%%"` fi } # func_cygming_gnu_implib_p ARG # This predicate returns with zero status (TRUE) if # ARG is a GNU/binutils-style import library. Returns # with nonzero status (FALSE) otherwise. func_cygming_gnu_implib_p () { $debug_cmd func_to_tool_file "$1" func_convert_file_msys_to_w32 func_cygming_gnu_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $EGREP ' (_head_[A-Za-z0-9_]+_[ad]l*|[A-Za-z0-9_]+_[ad]l*_iname)$'` test -n "$func_cygming_gnu_implib_tmp" } # func_cygming_ms_implib_p ARG # This predicate returns with zero status (TRUE) if # ARG is an MS-style import library. Returns # with nonzero status (FALSE) otherwise. func_cygming_ms_implib_p () { $debug_cmd func_to_tool_file "$1" func_convert_file_msys_to_w32 func_cygming_ms_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $GREP '_NULL_IMPORT_DESCRIPTOR'` test -n "$func_cygming_ms_implib_tmp" } # func_win32_libid arg # return the library type of file 'arg' # # Need a lot of goo to handle *both* DLLs and import libs # Has to be a shell function in order to 'eat' the argument # that is supplied when $file_magic_command is called. # Despite the name, also deal with 64 bit binaries. func_win32_libid () { $debug_cmd win32_libid_type=unknown win32_fileres=`file -L $1 2>/dev/null` case $win32_fileres in *ar\ archive\ import\ library*) # definitely import win32_libid_type="x86 archive import" ;; *ar\ archive*) # could be an import, or static # Keep the egrep pattern in sync with the one in _LT_CHECK_MAGIC_METHOD. if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null | $EGREP 'file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' >/dev/null; then case $nm_interface in "MS dumpbin") if func_cygming_ms_implib_p "$1" || func_cygming_gnu_implib_p "$1" then win32_nmres=import else win32_nmres= fi ;; *) func_to_tool_file "$1" func_convert_file_msys_to_w32 win32_nmres=`eval $NM -f posix -A \"$func_to_tool_file_result\" | $SED -n -e ' 1,100{ / I /{ s|.*|import| p q } }'` ;; esac case $win32_nmres in import*) win32_libid_type="x86 archive import";; *) win32_libid_type="x86 archive static";; esac fi ;; *DLL*) win32_libid_type="x86 DLL" ;; *executable*) # but shell scripts are "executable" too... case $win32_fileres in *MS\ Windows\ PE\ Intel*) win32_libid_type="x86 DLL" ;; esac ;; esac $ECHO "$win32_libid_type" } # func_cygming_dll_for_implib ARG # # Platform-specific function to extract the # name of the DLL associated with the specified # import library ARG. # Invoked by eval'ing the libtool variable # $sharedlib_from_linklib_cmd # Result is available in the variable # $sharedlib_from_linklib_result func_cygming_dll_for_implib () { $debug_cmd sharedlib_from_linklib_result=`$DLLTOOL --identify-strict --identify "$1"` } # func_cygming_dll_for_implib_fallback_core SECTION_NAME LIBNAMEs # # The is the core of a fallback implementation of a # platform-specific function to extract the name of the # DLL associated with the specified import library LIBNAME. # # SECTION_NAME is either .idata$6 or .idata$7, depending # on the platform and compiler that created the implib. # # Echos the name of the DLL associated with the # specified import library. func_cygming_dll_for_implib_fallback_core () { $debug_cmd match_literal=`$ECHO "$1" | $SED "$sed_make_literal_regex"` $OBJDUMP -s --section "$1" "$2" 2>/dev/null | $SED '/^Contents of section '"$match_literal"':/{ # Place marker at beginning of archive member dllname section s/.*/====MARK====/ p d } # These lines can sometimes be longer than 43 characters, but # are always uninteresting /:[ ]*file format pe[i]\{,1\}-/d /^In archive [^:]*:/d # Ensure marker is printed /^====MARK====/p # Remove all lines with less than 43 characters /^.\{43\}/!d # From remaining lines, remove first 43 characters s/^.\{43\}//' | $SED -n ' # Join marker and all lines until next marker into a single line /^====MARK====/ b para H $ b para b :para x s/\n//g # Remove the marker s/^====MARK====// # Remove trailing dots and whitespace s/[\. \t]*$// # Print /./p' | # we now have a list, one entry per line, of the stringified # contents of the appropriate section of all members of the # archive that possess that section. Heuristic: eliminate # all those that have a first or second character that is # a '.' (that is, objdump's representation of an unprintable # character.) This should work for all archives with less than # 0x302f exports -- but will fail for DLLs whose name actually # begins with a literal '.' or a single character followed by # a '.'. # # Of those that remain, print the first one. $SED -e '/^\./d;/^.\./d;q' } # func_cygming_dll_for_implib_fallback ARG # Platform-specific function to extract the # name of the DLL associated with the specified # import library ARG. # # This fallback implementation is for use when $DLLTOOL # does not support the --identify-strict option. # Invoked by eval'ing the libtool variable # $sharedlib_from_linklib_cmd # Result is available in the variable # $sharedlib_from_linklib_result func_cygming_dll_for_implib_fallback () { $debug_cmd if func_cygming_gnu_implib_p "$1"; then # binutils import library sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$7' "$1"` elif func_cygming_ms_implib_p "$1"; then # ms-generated import library sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$6' "$1"` else # unknown sharedlib_from_linklib_result= fi } # func_extract_an_archive dir oldlib func_extract_an_archive () { $debug_cmd f_ex_an_ar_dir=$1; shift f_ex_an_ar_oldlib=$1 if test yes = "$lock_old_archive_extraction"; then lockfile=$f_ex_an_ar_oldlib.lock until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do func_echo "Waiting for $lockfile to be removed" sleep 2 done fi func_show_eval "(cd \$f_ex_an_ar_dir && $AR x \"\$f_ex_an_ar_oldlib\")" \ 'stat=$?; rm -f "$lockfile"; exit $stat' if test yes = "$lock_old_archive_extraction"; then $opt_dry_run || rm -f "$lockfile" fi if ($AR t "$f_ex_an_ar_oldlib" | sort | sort -uc >/dev/null 2>&1); then : else func_fatal_error "object name conflicts in archive: $f_ex_an_ar_dir/$f_ex_an_ar_oldlib" fi } # func_extract_archives gentop oldlib ... func_extract_archives () { $debug_cmd my_gentop=$1; shift my_oldlibs=${1+"$@"} my_oldobjs= my_xlib= my_xabs= my_xdir= for my_xlib in $my_oldlibs; do # Extract the objects. case $my_xlib in [\\/]* | [A-Za-z]:[\\/]*) my_xabs=$my_xlib ;; *) my_xabs=`pwd`"/$my_xlib" ;; esac func_basename "$my_xlib" my_xlib=$func_basename_result my_xlib_u=$my_xlib while :; do case " $extracted_archives " in *" $my_xlib_u "*) func_arith $extracted_serial + 1 extracted_serial=$func_arith_result my_xlib_u=lt$extracted_serial-$my_xlib ;; *) break ;; esac done extracted_archives="$extracted_archives $my_xlib_u" my_xdir=$my_gentop/$my_xlib_u func_mkdir_p "$my_xdir" case $host in *-darwin*) func_verbose "Extracting $my_xabs" # Do not bother doing anything if just a dry run $opt_dry_run || { darwin_orig_dir=`pwd` cd $my_xdir || exit $? darwin_archive=$my_xabs darwin_curdir=`pwd` func_basename "$darwin_archive" darwin_base_archive=$func_basename_result darwin_arches=`$LIPO -info "$darwin_archive" 2>/dev/null | $GREP Architectures 2>/dev/null || true` if test -n "$darwin_arches"; then darwin_arches=`$ECHO "$darwin_arches" | $SED -e 's/.*are://'` darwin_arch= func_verbose "$darwin_base_archive has multiple architectures $darwin_arches" for darwin_arch in $darwin_arches; do func_mkdir_p "unfat-$$/$darwin_base_archive-$darwin_arch" $LIPO -thin $darwin_arch -output "unfat-$$/$darwin_base_archive-$darwin_arch/$darwin_base_archive" "$darwin_archive" cd "unfat-$$/$darwin_base_archive-$darwin_arch" func_extract_an_archive "`pwd`" "$darwin_base_archive" cd "$darwin_curdir" $RM "unfat-$$/$darwin_base_archive-$darwin_arch/$darwin_base_archive" done # $darwin_arches ## Okay now we've a bunch of thin objects, gotta fatten them up :) darwin_filelist=`find unfat-$$ -type f -name \*.o -print -o -name \*.lo -print | $SED -e "$sed_basename" | sort -u` darwin_file= darwin_files= for darwin_file in $darwin_filelist; do darwin_files=`find unfat-$$ -name $darwin_file -print | sort | $NL2SP` $LIPO -create -output "$darwin_file" $darwin_files done # $darwin_filelist $RM -rf unfat-$$ cd "$darwin_orig_dir" else cd $darwin_orig_dir func_extract_an_archive "$my_xdir" "$my_xabs" fi # $darwin_arches } # !$opt_dry_run ;; *) func_extract_an_archive "$my_xdir" "$my_xabs" ;; esac my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | sort | $NL2SP` done func_extract_archives_result=$my_oldobjs } # func_emit_wrapper [arg=no] # # Emit a libtool wrapper script on stdout. # Don't directly open a file because we may want to # incorporate the script contents within a cygwin/mingw # wrapper executable. Must ONLY be called from within # func_mode_link because it depends on a number of variables # set therein. # # ARG is the value that the WRAPPER_SCRIPT_BELONGS_IN_OBJDIR # variable will take. If 'yes', then the emitted script # will assume that the directory where it is stored is # the $objdir directory. This is a cygwin/mingw-specific # behavior. func_emit_wrapper () { func_emit_wrapper_arg1=${1-no} $ECHO "\ #! $SHELL # $output - temporary wrapper script for $objdir/$outputname # Generated by $PROGRAM (GNU $PACKAGE) $VERSION # # The $output program cannot be directly executed until all the libtool # libraries that it depends on are installed. # # This wrapper script should never be moved out of the build directory. # If it is, it will not operate correctly. # Sed substitution that helps us do robust quoting. It backslashifies # metacharacters that are still active within double-quoted strings. sed_quote_subst='$sed_quote_subst' # Be Bourne compatible if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: # Zsh 3.x and 4.x performs word splitting on \${1+\"\$@\"}, which # is contrary to our usage. Disable this feature. alias -g '\${1+\"\$@\"}'='\"\$@\"' setopt NO_GLOB_SUBST else case \`(set -o) 2>/dev/null\` in *posix*) set -o posix;; esac fi BIN_SH=xpg4; export BIN_SH # for Tru64 DUALCASE=1; export DUALCASE # for MKS sh # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH relink_command=\"$relink_command\" # This environment variable determines our operation mode. if test \"\$libtool_install_magic\" = \"$magic\"; then # install mode needs the following variables: generated_by_libtool_version='$macro_version' notinst_deplibs='$notinst_deplibs' else # When we are sourced in execute mode, \$file and \$ECHO are already set. if test \"\$libtool_execute_magic\" != \"$magic\"; then file=\"\$0\"" func_quote_arg pretty "$ECHO" qECHO=$func_quote_arg_result $ECHO "\ # A function that is used when there is no print builtin or printf. func_fallback_echo () { eval 'cat <<_LTECHO_EOF \$1 _LTECHO_EOF' } ECHO=$qECHO fi # Very basic option parsing. These options are (a) specific to # the libtool wrapper, (b) are identical between the wrapper # /script/ and the wrapper /executable/ that is used only on # windows platforms, and (c) all begin with the string "--lt-" # (application programs are unlikely to have options that match # this pattern). # # There are only two supported options: --lt-debug and # --lt-dump-script. There is, deliberately, no --lt-help. # # The first argument to this parsing function should be the # script's $0 value, followed by "$@". lt_option_debug= func_parse_lt_options () { lt_script_arg0=\$0 shift for lt_opt do case \"\$lt_opt\" in --lt-debug) lt_option_debug=1 ;; --lt-dump-script) lt_dump_D=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%/[^/]*$%%'\` test \"X\$lt_dump_D\" = \"X\$lt_script_arg0\" && lt_dump_D=. lt_dump_F=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%^.*/%%'\` cat \"\$lt_dump_D/\$lt_dump_F\" exit 0 ;; --lt-*) \$ECHO \"Unrecognized --lt- option: '\$lt_opt'\" 1>&2 exit 1 ;; esac done # Print the debug banner immediately: if test -n \"\$lt_option_debug\"; then echo \"$outputname:$output:\$LINENO: libtool wrapper (GNU $PACKAGE) $VERSION\" 1>&2 fi } # Used when --lt-debug. Prints its arguments to stdout # (redirection is the responsibility of the caller) func_lt_dump_args () { lt_dump_args_N=1; for lt_arg do \$ECHO \"$outputname:$output:\$LINENO: newargv[\$lt_dump_args_N]: \$lt_arg\" lt_dump_args_N=\`expr \$lt_dump_args_N + 1\` done } # Core function for launching the target application func_exec_program_core () { " case $host in # Backslashes separate directories on plain windows *-*-mingw | *-*-os2* | *-cegcc*) $ECHO "\ if test -n \"\$lt_option_debug\"; then \$ECHO \"$outputname:$output:\$LINENO: newargv[0]: \$progdir\\\\\$program\" 1>&2 func_lt_dump_args \${1+\"\$@\"} 1>&2 fi exec \"\$progdir\\\\\$program\" \${1+\"\$@\"} " ;; *) $ECHO "\ if test -n \"\$lt_option_debug\"; then \$ECHO \"$outputname:$output:\$LINENO: newargv[0]: \$progdir/\$program\" 1>&2 func_lt_dump_args \${1+\"\$@\"} 1>&2 fi exec \"\$progdir/\$program\" \${1+\"\$@\"} " ;; esac $ECHO "\ \$ECHO \"\$0: cannot exec \$program \$*\" 1>&2 exit 1 } # A function to encapsulate launching the target application # Strips options in the --lt-* namespace from \$@ and # launches target application with the remaining arguments. func_exec_program () { case \" \$* \" in *\\ --lt-*) for lt_wr_arg do case \$lt_wr_arg in --lt-*) ;; *) set x \"\$@\" \"\$lt_wr_arg\"; shift;; esac shift done ;; esac func_exec_program_core \${1+\"\$@\"} } # Parse options func_parse_lt_options \"\$0\" \${1+\"\$@\"} # Find the directory that this script lives in. thisdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*$%%'\` test \"x\$thisdir\" = \"x\$file\" && thisdir=. # Follow symbolic links until we get to the real thisdir. file=\`ls -ld \"\$file\" | $SED -n 's/.*-> //p'\` while test -n \"\$file\"; do destdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*\$%%'\` # If there was a directory component, then change thisdir. if test \"x\$destdir\" != \"x\$file\"; then case \"\$destdir\" in [\\\\/]* | [A-Za-z]:[\\\\/]*) thisdir=\"\$destdir\" ;; *) thisdir=\"\$thisdir/\$destdir\" ;; esac fi file=\`\$ECHO \"\$file\" | $SED 's%^.*/%%'\` file=\`ls -ld \"\$thisdir/\$file\" | $SED -n 's/.*-> //p'\` done # Usually 'no', except on cygwin/mingw when embedded into # the cwrapper. WRAPPER_SCRIPT_BELONGS_IN_OBJDIR=$func_emit_wrapper_arg1 if test \"\$WRAPPER_SCRIPT_BELONGS_IN_OBJDIR\" = \"yes\"; then # special case for '.' if test \"\$thisdir\" = \".\"; then thisdir=\`pwd\` fi # remove .libs from thisdir case \"\$thisdir\" in *[\\\\/]$objdir ) thisdir=\`\$ECHO \"\$thisdir\" | $SED 's%[\\\\/][^\\\\/]*$%%'\` ;; $objdir ) thisdir=. ;; esac fi # Try to get the absolute directory name. absdir=\`cd \"\$thisdir\" && pwd\` test -n \"\$absdir\" && thisdir=\"\$absdir\" " if test yes = "$fast_install"; then $ECHO "\ program=lt-'$outputname'$exeext progdir=\"\$thisdir/$objdir\" if test ! -f \"\$progdir/\$program\" || { file=\`ls -1dt \"\$progdir/\$program\" \"\$progdir/../\$program\" 2>/dev/null | $SED 1q\`; \\ test \"X\$file\" != \"X\$progdir/\$program\"; }; then file=\"\$\$-\$program\" if test ! -d \"\$progdir\"; then $MKDIR \"\$progdir\" else $RM \"\$progdir/\$file\" fi" $ECHO "\ # relink executable if necessary if test -n \"\$relink_command\"; then if relink_command_output=\`eval \$relink_command 2>&1\`; then : else \$ECHO \"\$relink_command_output\" >&2 $RM \"\$progdir/\$file\" exit 1 fi fi $MV \"\$progdir/\$file\" \"\$progdir/\$program\" 2>/dev/null || { $RM \"\$progdir/\$program\"; $MV \"\$progdir/\$file\" \"\$progdir/\$program\"; } $RM \"\$progdir/\$file\" fi" else $ECHO "\ program='$outputname' progdir=\"\$thisdir/$objdir\" " fi $ECHO "\ if test -f \"\$progdir/\$program\"; then" # fixup the dll searchpath if we need to. # # Fix the DLL searchpath if we need to. Do this before prepending # to shlibpath, because on Windows, both are PATH and uninstalled # libraries must come first. if test -n "$dllsearchpath"; then $ECHO "\ # Add the dll search path components to the executable PATH PATH=$dllsearchpath:\$PATH " fi # Export our shlibpath_var if we have one. if test yes = "$shlibpath_overrides_runpath" && test -n "$shlibpath_var" && test -n "$temp_rpath"; then $ECHO "\ # Add our own library path to $shlibpath_var $shlibpath_var=\"$temp_rpath\$$shlibpath_var\" # Some systems cannot cope with colon-terminated $shlibpath_var # The second colon is a workaround for a bug in BeOS R4 sed $shlibpath_var=\`\$ECHO \"\$$shlibpath_var\" | $SED 's/::*\$//'\` export $shlibpath_var " fi $ECHO "\ if test \"\$libtool_execute_magic\" != \"$magic\"; then # Run the actual program with our arguments. func_exec_program \${1+\"\$@\"} fi else # The program doesn't exist. \$ECHO \"\$0: error: '\$progdir/\$program' does not exist\" 1>&2 \$ECHO \"This script is just a wrapper for \$program.\" 1>&2 \$ECHO \"See the $PACKAGE documentation for more information.\" 1>&2 exit 1 fi fi\ " } # func_emit_cwrapperexe_src # emit the source code for a wrapper executable on stdout # Must ONLY be called from within func_mode_link because # it depends on a number of variable set therein. func_emit_cwrapperexe_src () { cat < #include #ifdef _MSC_VER # include # include # include #else # include # include # ifdef __CYGWIN__ # include # endif #endif #include #include #include #include #include #include #include #include #define STREQ(s1, s2) (strcmp ((s1), (s2)) == 0) /* declarations of non-ANSI functions */ #if defined __MINGW32__ # ifdef __STRICT_ANSI__ int _putenv (const char *); # endif #elif defined __CYGWIN__ # ifdef __STRICT_ANSI__ char *realpath (const char *, char *); int putenv (char *); int setenv (const char *, const char *, int); # endif /* #elif defined other_platform || defined ... */ #endif /* portability defines, excluding path handling macros */ #if defined _MSC_VER # define setmode _setmode # define stat _stat # define chmod _chmod # define getcwd _getcwd # define putenv _putenv # define S_IXUSR _S_IEXEC #elif defined __MINGW32__ # define setmode _setmode # define stat _stat # define chmod _chmod # define getcwd _getcwd # define putenv _putenv #elif defined __CYGWIN__ # define HAVE_SETENV # define FOPEN_WB "wb" /* #elif defined other platforms ... */ #endif #if defined PATH_MAX # define LT_PATHMAX PATH_MAX #elif defined MAXPATHLEN # define LT_PATHMAX MAXPATHLEN #else # define LT_PATHMAX 1024 #endif #ifndef S_IXOTH # define S_IXOTH 0 #endif #ifndef S_IXGRP # define S_IXGRP 0 #endif /* path handling portability macros */ #ifndef DIR_SEPARATOR # define DIR_SEPARATOR '/' # define PATH_SEPARATOR ':' #endif #if defined _WIN32 || defined __MSDOS__ || defined __DJGPP__ || \ defined __OS2__ # define HAVE_DOS_BASED_FILE_SYSTEM # define FOPEN_WB "wb" # ifndef DIR_SEPARATOR_2 # define DIR_SEPARATOR_2 '\\' # endif # ifndef PATH_SEPARATOR_2 # define PATH_SEPARATOR_2 ';' # endif #endif #ifndef DIR_SEPARATOR_2 # define IS_DIR_SEPARATOR(ch) ((ch) == DIR_SEPARATOR) #else /* DIR_SEPARATOR_2 */ # define IS_DIR_SEPARATOR(ch) \ (((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2)) #endif /* DIR_SEPARATOR_2 */ #ifndef PATH_SEPARATOR_2 # define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR) #else /* PATH_SEPARATOR_2 */ # define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR_2) #endif /* PATH_SEPARATOR_2 */ #ifndef FOPEN_WB # define FOPEN_WB "w" #endif #ifndef _O_BINARY # define _O_BINARY 0 #endif #define XMALLOC(type, num) ((type *) xmalloc ((num) * sizeof(type))) #define XFREE(stale) do { \ if (stale) { free (stale); stale = 0; } \ } while (0) #if defined LT_DEBUGWRAPPER static int lt_debug = 1; #else static int lt_debug = 0; #endif const char *program_name = "libtool-wrapper"; /* in case xstrdup fails */ void *xmalloc (size_t num); char *xstrdup (const char *string); const char *base_name (const char *name); char *find_executable (const char *wrapper); char *chase_symlinks (const char *pathspec); int make_executable (const char *path); int check_executable (const char *path); char *strendzap (char *str, const char *pat); void lt_debugprintf (const char *file, int line, const char *fmt, ...); void lt_fatal (const char *file, int line, const char *message, ...); static const char *nonnull (const char *s); static const char *nonempty (const char *s); void lt_setenv (const char *name, const char *value); char *lt_extend_str (const char *orig_value, const char *add, int to_end); void lt_update_exe_path (const char *name, const char *value); void lt_update_lib_path (const char *name, const char *value); char **prepare_spawn (char **argv); void lt_dump_script (FILE *f); EOF cat <= 0) && (st.st_mode & (S_IXUSR | S_IXGRP | S_IXOTH))) return 1; else return 0; } int make_executable (const char *path) { int rval = 0; struct stat st; lt_debugprintf (__FILE__, __LINE__, "(make_executable): %s\n", nonempty (path)); if ((!path) || (!*path)) return 0; if (stat (path, &st) >= 0) { rval = chmod (path, st.st_mode | S_IXOTH | S_IXGRP | S_IXUSR); } return rval; } /* Searches for the full path of the wrapper. Returns newly allocated full path name if found, NULL otherwise Does not chase symlinks, even on platforms that support them. */ char * find_executable (const char *wrapper) { int has_slash = 0; const char *p; const char *p_next; /* static buffer for getcwd */ char tmp[LT_PATHMAX + 1]; size_t tmp_len; char *concat_name; lt_debugprintf (__FILE__, __LINE__, "(find_executable): %s\n", nonempty (wrapper)); if ((wrapper == NULL) || (*wrapper == '\0')) return NULL; /* Absolute path? */ #if defined HAVE_DOS_BASED_FILE_SYSTEM if (isalpha ((unsigned char) wrapper[0]) && wrapper[1] == ':') { concat_name = xstrdup (wrapper); if (check_executable (concat_name)) return concat_name; XFREE (concat_name); } else { #endif if (IS_DIR_SEPARATOR (wrapper[0])) { concat_name = xstrdup (wrapper); if (check_executable (concat_name)) return concat_name; XFREE (concat_name); } #if defined HAVE_DOS_BASED_FILE_SYSTEM } #endif for (p = wrapper; *p; p++) if (*p == '/') { has_slash = 1; break; } if (!has_slash) { /* no slashes; search PATH */ const char *path = getenv ("PATH"); if (path != NULL) { for (p = path; *p; p = p_next) { const char *q; size_t p_len; for (q = p; *q; q++) if (IS_PATH_SEPARATOR (*q)) break; p_len = (size_t) (q - p); p_next = (*q == '\0' ? q : q + 1); if (p_len == 0) { /* empty path: current directory */ if (getcwd (tmp, LT_PATHMAX) == NULL) lt_fatal (__FILE__, __LINE__, "getcwd failed: %s", nonnull (strerror (errno))); tmp_len = strlen (tmp); concat_name = XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1); memcpy (concat_name, tmp, tmp_len); concat_name[tmp_len] = '/'; strcpy (concat_name + tmp_len + 1, wrapper); } else { concat_name = XMALLOC (char, p_len + 1 + strlen (wrapper) + 1); memcpy (concat_name, p, p_len); concat_name[p_len] = '/'; strcpy (concat_name + p_len + 1, wrapper); } if (check_executable (concat_name)) return concat_name; XFREE (concat_name); } } /* not found in PATH; assume curdir */ } /* Relative path | not found in path: prepend cwd */ if (getcwd (tmp, LT_PATHMAX) == NULL) lt_fatal (__FILE__, __LINE__, "getcwd failed: %s", nonnull (strerror (errno))); tmp_len = strlen (tmp); concat_name = XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1); memcpy (concat_name, tmp, tmp_len); concat_name[tmp_len] = '/'; strcpy (concat_name + tmp_len + 1, wrapper); if (check_executable (concat_name)) return concat_name; XFREE (concat_name); return NULL; } char * chase_symlinks (const char *pathspec) { #ifndef S_ISLNK return xstrdup (pathspec); #else char buf[LT_PATHMAX]; struct stat s; char *tmp_pathspec = xstrdup (pathspec); char *p; int has_symlinks = 0; while (strlen (tmp_pathspec) && !has_symlinks) { lt_debugprintf (__FILE__, __LINE__, "checking path component for symlinks: %s\n", tmp_pathspec); if (lstat (tmp_pathspec, &s) == 0) { if (S_ISLNK (s.st_mode) != 0) { has_symlinks = 1; break; } /* search backwards for last DIR_SEPARATOR */ p = tmp_pathspec + strlen (tmp_pathspec) - 1; while ((p > tmp_pathspec) && (!IS_DIR_SEPARATOR (*p))) p--; if ((p == tmp_pathspec) && (!IS_DIR_SEPARATOR (*p))) { /* no more DIR_SEPARATORS left */ break; } *p = '\0'; } else { lt_fatal (__FILE__, __LINE__, "error accessing file \"%s\": %s", tmp_pathspec, nonnull (strerror (errno))); } } XFREE (tmp_pathspec); if (!has_symlinks) { return xstrdup (pathspec); } tmp_pathspec = realpath (pathspec, buf); if (tmp_pathspec == 0) { lt_fatal (__FILE__, __LINE__, "could not follow symlinks for %s", pathspec); } return xstrdup (tmp_pathspec); #endif } char * strendzap (char *str, const char *pat) { size_t len, patlen; assert (str != NULL); assert (pat != NULL); len = strlen (str); patlen = strlen (pat); if (patlen <= len) { str += len - patlen; if (STREQ (str, pat)) *str = '\0'; } return str; } void lt_debugprintf (const char *file, int line, const char *fmt, ...) { va_list args; if (lt_debug) { (void) fprintf (stderr, "%s:%s:%d: ", program_name, file, line); va_start (args, fmt); (void) vfprintf (stderr, fmt, args); va_end (args); } } static void lt_error_core (int exit_status, const char *file, int line, const char *mode, const char *message, va_list ap) { fprintf (stderr, "%s:%s:%d: %s: ", program_name, file, line, mode); vfprintf (stderr, message, ap); fprintf (stderr, ".\n"); if (exit_status >= 0) exit (exit_status); } void lt_fatal (const char *file, int line, const char *message, ...) { va_list ap; va_start (ap, message); lt_error_core (EXIT_FAILURE, file, line, "FATAL", message, ap); va_end (ap); } static const char * nonnull (const char *s) { return s ? s : "(null)"; } static const char * nonempty (const char *s) { return (s && !*s) ? "(empty)" : nonnull (s); } void lt_setenv (const char *name, const char *value) { lt_debugprintf (__FILE__, __LINE__, "(lt_setenv) setting '%s' to '%s'\n", nonnull (name), nonnull (value)); { #ifdef HAVE_SETENV /* always make a copy, for consistency with !HAVE_SETENV */ char *str = xstrdup (value); setenv (name, str, 1); #else size_t len = strlen (name) + 1 + strlen (value) + 1; char *str = XMALLOC (char, len); sprintf (str, "%s=%s", name, value); if (putenv (str) != EXIT_SUCCESS) { XFREE (str); } #endif } } char * lt_extend_str (const char *orig_value, const char *add, int to_end) { char *new_value; if (orig_value && *orig_value) { size_t orig_value_len = strlen (orig_value); size_t add_len = strlen (add); new_value = XMALLOC (char, add_len + orig_value_len + 1); if (to_end) { strcpy (new_value, orig_value); strcpy (new_value + orig_value_len, add); } else { strcpy (new_value, add); strcpy (new_value + add_len, orig_value); } } else { new_value = xstrdup (add); } return new_value; } void lt_update_exe_path (const char *name, const char *value) { lt_debugprintf (__FILE__, __LINE__, "(lt_update_exe_path) modifying '%s' by prepending '%s'\n", nonnull (name), nonnull (value)); if (name && *name && value && *value) { char *new_value = lt_extend_str (getenv (name), value, 0); /* some systems can't cope with a ':'-terminated path #' */ size_t len = strlen (new_value); while ((len > 0) && IS_PATH_SEPARATOR (new_value[len-1])) { new_value[--len] = '\0'; } lt_setenv (name, new_value); XFREE (new_value); } } void lt_update_lib_path (const char *name, const char *value) { lt_debugprintf (__FILE__, __LINE__, "(lt_update_lib_path) modifying '%s' by prepending '%s'\n", nonnull (name), nonnull (value)); if (name && *name && value && *value) { char *new_value = lt_extend_str (getenv (name), value, 0); lt_setenv (name, new_value); XFREE (new_value); } } EOF case $host_os in mingw*) cat <<"EOF" /* Prepares an argument vector before calling spawn(). Note that spawn() does not by itself call the command interpreter (getenv ("COMSPEC") != NULL ? getenv ("COMSPEC") : ({ OSVERSIONINFO v; v.dwOSVersionInfoSize = sizeof(OSVERSIONINFO); GetVersionEx(&v); v.dwPlatformId == VER_PLATFORM_WIN32_NT; }) ? "cmd.exe" : "command.com"). Instead it simply concatenates the arguments, separated by ' ', and calls CreateProcess(). We must quote the arguments since Win32 CreateProcess() interprets characters like ' ', '\t', '\\', '"' (but not '<' and '>') in a special way: - Space and tab are interpreted as delimiters. They are not treated as delimiters if they are surrounded by double quotes: "...". - Unescaped double quotes are removed from the input. Their only effect is that within double quotes, space and tab are treated like normal characters. - Backslashes not followed by double quotes are not special. - But 2*n+1 backslashes followed by a double quote become n backslashes followed by a double quote (n >= 0): \" -> " \\\" -> \" \\\\\" -> \\" */ #define SHELL_SPECIAL_CHARS "\"\\ \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037" #define SHELL_SPACE_CHARS " \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037" char ** prepare_spawn (char **argv) { size_t argc; char **new_argv; size_t i; /* Count number of arguments. */ for (argc = 0; argv[argc] != NULL; argc++) ; /* Allocate new argument vector. */ new_argv = XMALLOC (char *, argc + 1); /* Put quoted arguments into the new argument vector. */ for (i = 0; i < argc; i++) { const char *string = argv[i]; if (string[0] == '\0') new_argv[i] = xstrdup ("\"\""); else if (strpbrk (string, SHELL_SPECIAL_CHARS) != NULL) { int quote_around = (strpbrk (string, SHELL_SPACE_CHARS) != NULL); size_t length; unsigned int backslashes; const char *s; char *quoted_string; char *p; length = 0; backslashes = 0; if (quote_around) length++; for (s = string; *s != '\0'; s++) { char c = *s; if (c == '"') length += backslashes + 1; length++; if (c == '\\') backslashes++; else backslashes = 0; } if (quote_around) length += backslashes + 1; quoted_string = XMALLOC (char, length + 1); p = quoted_string; backslashes = 0; if (quote_around) *p++ = '"'; for (s = string; *s != '\0'; s++) { char c = *s; if (c == '"') { unsigned int j; for (j = backslashes + 1; j > 0; j--) *p++ = '\\'; } *p++ = c; if (c == '\\') backslashes++; else backslashes = 0; } if (quote_around) { unsigned int j; for (j = backslashes; j > 0; j--) *p++ = '\\'; *p++ = '"'; } *p = '\0'; new_argv[i] = quoted_string; } else new_argv[i] = (char *) string; } new_argv[argc] = NULL; return new_argv; } EOF ;; esac cat <<"EOF" void lt_dump_script (FILE* f) { EOF func_emit_wrapper yes | $SED -n -e ' s/^\(.\{79\}\)\(..*\)/\1\ \2/ h s/\([\\"]\)/\\\1/g s/$/\\n/ s/\([^\n]*\).*/ fputs ("\1", f);/p g D' cat <<"EOF" } EOF } # end: func_emit_cwrapperexe_src # func_win32_import_lib_p ARG # True if ARG is an import lib, as indicated by $file_magic_cmd func_win32_import_lib_p () { $debug_cmd case `eval $file_magic_cmd \"\$1\" 2>/dev/null | $SED -e 10q` in *import*) : ;; *) false ;; esac } # func_suncc_cstd_abi # !!ONLY CALL THIS FOR SUN CC AFTER $compile_command IS FULLY EXPANDED!! # Several compiler flags select an ABI that is incompatible with the # Cstd library. Avoid specifying it if any are in CXXFLAGS. func_suncc_cstd_abi () { $debug_cmd case " $compile_command " in *" -compat=g "*|*\ -std=c++[0-9][0-9]\ *|*" -library=stdcxx4 "*|*" -library=stlport4 "*) suncc_use_cstd_abi=no ;; *) suncc_use_cstd_abi=yes ;; esac } # func_mode_link arg... func_mode_link () { $debug_cmd case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) # It is impossible to link a dll without this setting, and # we shouldn't force the makefile maintainer to figure out # what system we are compiling for in order to pass an extra # flag for every libtool invocation. # allow_undefined=no # FIXME: Unfortunately, there are problems with the above when trying # to make a dll that has undefined symbols, in which case not # even a static library is built. For now, we need to specify # -no-undefined on the libtool link line when we can be certain # that all symbols are satisfied, otherwise we get a static library. allow_undefined=yes ;; *) allow_undefined=yes ;; esac libtool_args=$nonopt base_compile="$nonopt $@" compile_command=$nonopt finalize_command=$nonopt compile_rpath= finalize_rpath= compile_shlibpath= finalize_shlibpath= convenience= old_convenience= deplibs= old_deplibs= compiler_flags= linker_flags= dllsearchpath= lib_search_path=`pwd` inst_prefix_dir= new_inherited_linker_flags= avoid_version=no bindir= dlfiles= dlprefiles= dlself=no export_dynamic=no export_symbols= export_symbols_regex= generated= libobjs= ltlibs= module=no no_install=no objs= os2dllname= non_pic_objects= precious_files_regex= prefer_static_libs=no preload=false prev= prevarg= release= rpath= xrpath= perm_rpath= temp_rpath= thread_safe=no vinfo= vinfo_number=no weak_libs= single_module=$wl-single_module func_infer_tag $base_compile # We need to know -static, to get the right output filenames. for arg do case $arg in -shared) test yes != "$build_libtool_libs" \ && func_fatal_configuration "cannot build a shared library" build_old_libs=no break ;; -all-static | -static | -static-libtool-libs) case $arg in -all-static) if test yes = "$build_libtool_libs" && test -z "$link_static_flag"; then func_warning "complete static linking is impossible in this configuration" fi if test -n "$link_static_flag"; then dlopen_self=$dlopen_self_static fi prefer_static_libs=yes ;; -static) if test -z "$pic_flag" && test -n "$link_static_flag"; then dlopen_self=$dlopen_self_static fi prefer_static_libs=built ;; -static-libtool-libs) if test -z "$pic_flag" && test -n "$link_static_flag"; then dlopen_self=$dlopen_self_static fi prefer_static_libs=yes ;; esac build_libtool_libs=no build_old_libs=yes break ;; esac done # See if our shared archives depend on static archives. test -n "$old_archive_from_new_cmds" && build_old_libs=yes # Go through the arguments, transforming them on the way. while test "$#" -gt 0; do arg=$1 shift func_quote_arg pretty,unquoted "$arg" qarg=$func_quote_arg_unquoted_result func_append libtool_args " $func_quote_arg_result" # If the previous option needs an argument, assign it. if test -n "$prev"; then case $prev in output) func_append compile_command " @OUTPUT@" func_append finalize_command " @OUTPUT@" ;; esac case $prev in bindir) bindir=$arg prev= continue ;; dlfiles|dlprefiles) $preload || { # Add the symbol object into the linking commands. func_append compile_command " @SYMFILE@" func_append finalize_command " @SYMFILE@" preload=: } case $arg in *.la | *.lo) ;; # We handle these cases below. force) if test no = "$dlself"; then dlself=needless export_dynamic=yes fi prev= continue ;; self) if test dlprefiles = "$prev"; then dlself=yes elif test dlfiles = "$prev" && test yes != "$dlopen_self"; then dlself=yes else dlself=needless export_dynamic=yes fi prev= continue ;; *) if test dlfiles = "$prev"; then func_append dlfiles " $arg" else func_append dlprefiles " $arg" fi prev= continue ;; esac ;; expsyms) export_symbols=$arg test -f "$arg" \ || func_fatal_error "symbol file '$arg' does not exist" prev= continue ;; expsyms_regex) export_symbols_regex=$arg prev= continue ;; framework) case $host in *-*-darwin*) case "$deplibs " in *" $qarg.ltframework "*) ;; *) func_append deplibs " $qarg.ltframework" # this is fixed later ;; esac ;; esac prev= continue ;; inst_prefix) inst_prefix_dir=$arg prev= continue ;; mllvm) # Clang does not use LLVM to link, so we can simply discard any # '-mllvm $arg' options when doing the link step. prev= continue ;; objectlist) if test -f "$arg"; then save_arg=$arg moreargs= for fil in `cat "$save_arg"` do # func_append moreargs " $fil" arg=$fil # A libtool-controlled object. # Check to see that this really is a libtool object. if func_lalib_unsafe_p "$arg"; then pic_object= non_pic_object= # Read the .lo file func_source "$arg" if test -z "$pic_object" || test -z "$non_pic_object" || test none = "$pic_object" && test none = "$non_pic_object"; then func_fatal_error "cannot find name of object for '$arg'" fi # Extract subdirectory from the argument. func_dirname "$arg" "/" "" xdir=$func_dirname_result if test none != "$pic_object"; then # Prepend the subdirectory the object is found in. pic_object=$xdir$pic_object if test dlfiles = "$prev"; then if test yes = "$build_libtool_libs" && test yes = "$dlopen_support"; then func_append dlfiles " $pic_object" prev= continue else # If libtool objects are unsupported, then we need to preload. prev=dlprefiles fi fi # CHECK ME: I think I busted this. -Ossama if test dlprefiles = "$prev"; then # Preload the old-style object. func_append dlprefiles " $pic_object" prev= fi # A PIC object. func_append libobjs " $pic_object" arg=$pic_object fi # Non-PIC object. if test none != "$non_pic_object"; then # Prepend the subdirectory the object is found in. non_pic_object=$xdir$non_pic_object # A standard non-PIC object func_append non_pic_objects " $non_pic_object" if test -z "$pic_object" || test none = "$pic_object"; then arg=$non_pic_object fi else # If the PIC object exists, use it instead. # $xdir was prepended to $pic_object above. non_pic_object=$pic_object func_append non_pic_objects " $non_pic_object" fi else # Only an error if not doing a dry-run. if $opt_dry_run; then # Extract subdirectory from the argument. func_dirname "$arg" "/" "" xdir=$func_dirname_result func_lo2o "$arg" pic_object=$xdir$objdir/$func_lo2o_result non_pic_object=$xdir$func_lo2o_result func_append libobjs " $pic_object" func_append non_pic_objects " $non_pic_object" else func_fatal_error "'$arg' is not a valid libtool object" fi fi done else func_fatal_error "link input file '$arg' does not exist" fi arg=$save_arg prev= continue ;; os2dllname) os2dllname=$arg prev= continue ;; precious_regex) precious_files_regex=$arg prev= continue ;; release) release=-$arg prev= continue ;; rpath | xrpath) # We need an absolute path. case $arg in [\\/]* | [A-Za-z]:[\\/]*) ;; *) func_fatal_error "only absolute run-paths are allowed" ;; esac if test rpath = "$prev"; then case "$rpath " in *" $arg "*) ;; *) func_append rpath " $arg" ;; esac else case "$xrpath " in *" $arg "*) ;; *) func_append xrpath " $arg" ;; esac fi prev= continue ;; shrext) shrext_cmds=$arg prev= continue ;; weak) func_append weak_libs " $arg" prev= continue ;; xassembler) func_append compiler_flags " -Xassembler $qarg" prev= func_append compile_command " -Xassembler $qarg" func_append finalize_command " -Xassembler $qarg" continue ;; xcclinker) func_append linker_flags " $qarg" func_append compiler_flags " $qarg" prev= func_append compile_command " $qarg" func_append finalize_command " $qarg" continue ;; xcompiler) func_append compiler_flags " $qarg" prev= func_append compile_command " $qarg" func_append finalize_command " $qarg" continue ;; xlinker) func_append linker_flags " $qarg" func_append compiler_flags " $wl$qarg" prev= func_append compile_command " $wl$qarg" func_append finalize_command " $wl$qarg" continue ;; *) eval "$prev=\"\$arg\"" prev= continue ;; esac fi # test -n "$prev" prevarg=$arg case $arg in -all-static) if test -n "$link_static_flag"; then # See comment for -static flag below, for more details. func_append compile_command " $link_static_flag" func_append finalize_command " $link_static_flag" fi continue ;; -allow-undefined) # FIXME: remove this flag sometime in the future. func_fatal_error "'-allow-undefined' must not be used because it is the default" ;; -avoid-version) avoid_version=yes continue ;; -bindir) prev=bindir continue ;; -dlopen) prev=dlfiles continue ;; -dlpreopen) prev=dlprefiles continue ;; -export-dynamic) export_dynamic=yes continue ;; -export-symbols | -export-symbols-regex) if test -n "$export_symbols" || test -n "$export_symbols_regex"; then func_fatal_error "more than one -exported-symbols argument is not allowed" fi if test X-export-symbols = "X$arg"; then prev=expsyms else prev=expsyms_regex fi continue ;; -framework) prev=framework continue ;; -inst-prefix-dir) prev=inst_prefix continue ;; # The native IRIX linker understands -LANG:*, -LIST:* and -LNO:* # so, if we see these flags be careful not to treat them like -L -L[A-Z][A-Z]*:*) case $with_gcc/$host in no/*-*-irix* | /*-*-irix*) func_append compile_command " $arg" func_append finalize_command " $arg" ;; esac continue ;; -L*) func_stripname "-L" '' "$arg" if test -z "$func_stripname_result"; then if test "$#" -gt 0; then func_fatal_error "require no space between '-L' and '$1'" else func_fatal_error "need path for '-L' option" fi fi func_resolve_sysroot "$func_stripname_result" dir=$func_resolve_sysroot_result # We need an absolute path. case $dir in [\\/]* | [A-Za-z]:[\\/]*) ;; *) absdir=`cd "$dir" && pwd` test -z "$absdir" && \ func_fatal_error "cannot determine absolute directory name of '$dir'" dir=$absdir ;; esac case "$deplibs " in *" -L$dir "* | *" $arg "*) # Will only happen for absolute or sysroot arguments ;; *) # Preserve sysroot, but never include relative directories case $dir in [\\/]* | [A-Za-z]:[\\/]* | =*) func_append deplibs " $arg" ;; *) func_append deplibs " -L$dir" ;; esac func_append lib_search_path " $dir" ;; esac case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) testbindir=`$ECHO "$dir" | $SED 's*/lib$*/bin*'` case :$dllsearchpath: in *":$dir:"*) ;; ::) dllsearchpath=$dir;; *) func_append dllsearchpath ":$dir";; esac case :$dllsearchpath: in *":$testbindir:"*) ;; ::) dllsearchpath=$testbindir;; *) func_append dllsearchpath ":$testbindir";; esac ;; esac continue ;; -l*) if test X-lc = "X$arg" || test X-lm = "X$arg"; then case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos* | *-cegcc* | *-*-haiku*) # These systems don't actually have a C or math library (as such) continue ;; *-*-os2*) # These systems don't actually have a C library (as such) test X-lc = "X$arg" && continue ;; *-*-openbsd* | *-*-freebsd* | *-*-dragonfly* | *-*-bitrig* | *-*-midnightbsd*) # Do not include libc due to us having libc/libc_r. test X-lc = "X$arg" && continue ;; *-*-rhapsody* | *-*-darwin1.[012]) # Rhapsody C and math libraries are in the System framework func_append deplibs " System.ltframework" continue ;; *-*-sco3.2v5* | *-*-sco5v6*) # Causes problems with __ctype test X-lc = "X$arg" && continue ;; *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) # Compiler inserts libc in the correct place for threads to work test X-lc = "X$arg" && continue ;; esac elif test X-lc_r = "X$arg"; then case $host in *-*-openbsd* | *-*-freebsd* | *-*-dragonfly* | *-*-bitrig* | *-*-midnightbsd*) # Do not include libc_r directly, use -pthread flag. continue ;; esac fi func_append deplibs " $arg" continue ;; -mllvm) prev=mllvm continue ;; -module) module=yes continue ;; # Tru64 UNIX uses -model [arg] to determine the layout of C++ # classes, name mangling, and exception handling. # Darwin uses the -arch flag to determine output architecture. -model|-arch|-isysroot|--sysroot) func_append compiler_flags " $arg" func_append compile_command " $arg" func_append finalize_command " $arg" prev=xcompiler continue ;; # Solaris ld rejects as of 11.4. Refer to Oracle bug 22985199. -pthread) case $host in *solaris2*) ;; *) case "$new_inherited_linker_flags " in *" $arg "*) ;; * ) func_append new_inherited_linker_flags " $arg" ;; esac ;; esac continue ;; -mt|-mthreads|-kthread|-Kthread|-pthreads|--thread-safe \ |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*) func_append compiler_flags " $arg" func_append compile_command " $arg" func_append finalize_command " $arg" case "$new_inherited_linker_flags " in *" $arg "*) ;; * ) func_append new_inherited_linker_flags " $arg" ;; esac continue ;; -multi_module) single_module=$wl-multi_module continue ;; -no-fast-install) fast_install=no continue ;; -no-install) case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-darwin* | *-cegcc*) # The PATH hackery in wrapper scripts is required on Windows # and Darwin in order for the loader to find any dlls it needs. func_warning "'-no-install' is ignored for $host" func_warning "assuming '-no-fast-install' instead" fast_install=no ;; *) no_install=yes ;; esac continue ;; -no-undefined) allow_undefined=no continue ;; -objectlist) prev=objectlist continue ;; -os2dllname) prev=os2dllname continue ;; -o) prev=output ;; -precious-files-regex) prev=precious_regex continue ;; -release) prev=release continue ;; -rpath) prev=rpath continue ;; -R) prev=xrpath continue ;; -R*) func_stripname '-R' '' "$arg" dir=$func_stripname_result # We need an absolute path. case $dir in [\\/]* | [A-Za-z]:[\\/]*) ;; =*) func_stripname '=' '' "$dir" dir=$lt_sysroot$func_stripname_result ;; *) func_fatal_error "only absolute run-paths are allowed" ;; esac case "$xrpath " in *" $dir "*) ;; *) func_append xrpath " $dir" ;; esac continue ;; -shared) # The effects of -shared are defined in a previous loop. continue ;; -shrext) prev=shrext continue ;; -static | -static-libtool-libs) # The effects of -static are defined in a previous loop. # We used to do the same as -all-static on platforms that # didn't have a PIC flag, but the assumption that the effects # would be equivalent was wrong. It would break on at least # Digital Unix and AIX. continue ;; -thread-safe) thread_safe=yes continue ;; -version-info) prev=vinfo continue ;; -version-number) prev=vinfo vinfo_number=yes continue ;; -weak) prev=weak continue ;; -Wc,*) func_stripname '-Wc,' '' "$arg" args=$func_stripname_result arg= save_ifs=$IFS; IFS=, for flag in $args; do IFS=$save_ifs func_quote_arg pretty "$flag" func_append arg " $func_quote_arg_result" func_append compiler_flags " $func_quote_arg_result" done IFS=$save_ifs func_stripname ' ' '' "$arg" arg=$func_stripname_result ;; -Wl,*) func_stripname '-Wl,' '' "$arg" args=$func_stripname_result arg= save_ifs=$IFS; IFS=, for flag in $args; do IFS=$save_ifs func_quote_arg pretty "$flag" func_append arg " $wl$func_quote_arg_result" func_append compiler_flags " $wl$func_quote_arg_result" func_append linker_flags " $func_quote_arg_result" done IFS=$save_ifs func_stripname ' ' '' "$arg" arg=$func_stripname_result ;; -Xassembler) prev=xassembler continue ;; -Xcompiler) prev=xcompiler continue ;; -Xlinker) prev=xlinker continue ;; -XCClinker) prev=xcclinker continue ;; # -msg_* for osf cc -msg_*) func_quote_arg pretty "$arg" arg=$func_quote_arg_result ;; # Flags to be passed through unchanged, with rationale: # -64, -mips[0-9] enable 64-bit mode for the SGI compiler # -r[0-9][0-9]* specify processor for the SGI compiler # -xarch=*, -xtarget=* enable 64-bit mode for the Sun compiler # +DA*, +DD* enable 64-bit mode for the HP compiler # -q* compiler args for the IBM compiler # -m*, -t[45]*, -txscale* architecture-specific flags for GCC # -F/path path to uninstalled frameworks, gcc on darwin # -p, -pg, --coverage, -fprofile-* profiling flags for GCC # -fstack-protector* stack protector flags for GCC # @file GCC response files # -tp=* Portland pgcc target processor selection # --sysroot=* for sysroot support # -O*, -g*, -flto*, -fwhopr*, -fuse-linker-plugin GCC link-time optimization # -specs=* GCC specs files # -stdlib=* select c++ std lib with clang # -fsanitize=* Clang/GCC memory and address sanitizer # -fuse-ld=* Linker select flags for GCC # -static-* direct GCC to link specific libraries statically # -fcilkplus Cilk Plus language extension features for C/C++ # -Wa,* Pass flags directly to the assembler -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \ -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \ -O*|-g*|-flto*|-fwhopr*|-fuse-linker-plugin|-fstack-protector*|-stdlib=*| \ -specs=*|-fsanitize=*|-fuse-ld=*|-static-*|-fcilkplus|-Wa,*) func_quote_arg pretty "$arg" arg=$func_quote_arg_result func_append compile_command " $arg" func_append finalize_command " $arg" func_append compiler_flags " $arg" continue ;; -Z*) if test os2 = "`expr $host : '.*\(os2\)'`"; then # OS/2 uses -Zxxx to specify OS/2-specific options compiler_flags="$compiler_flags $arg" func_append compile_command " $arg" func_append finalize_command " $arg" case $arg in -Zlinker | -Zstack) prev=xcompiler ;; esac continue else # Otherwise treat like 'Some other compiler flag' below func_quote_arg pretty "$arg" arg=$func_quote_arg_result fi ;; # Some other compiler flag. -* | +*) func_quote_arg pretty "$arg" arg=$func_quote_arg_result ;; *.$objext) # A standard object. func_append objs " $arg" ;; *.lo) # A libtool-controlled object. # Check to see that this really is a libtool object. if func_lalib_unsafe_p "$arg"; then pic_object= non_pic_object= # Read the .lo file func_source "$arg" if test -z "$pic_object" || test -z "$non_pic_object" || test none = "$pic_object" && test none = "$non_pic_object"; then func_fatal_error "cannot find name of object for '$arg'" fi # Extract subdirectory from the argument. func_dirname "$arg" "/" "" xdir=$func_dirname_result test none = "$pic_object" || { # Prepend the subdirectory the object is found in. pic_object=$xdir$pic_object if test dlfiles = "$prev"; then if test yes = "$build_libtool_libs" && test yes = "$dlopen_support"; then func_append dlfiles " $pic_object" prev= continue else # If libtool objects are unsupported, then we need to preload. prev=dlprefiles fi fi # CHECK ME: I think I busted this. -Ossama if test dlprefiles = "$prev"; then # Preload the old-style object. func_append dlprefiles " $pic_object" prev= fi # A PIC object. func_append libobjs " $pic_object" arg=$pic_object } # Non-PIC object. if test none != "$non_pic_object"; then # Prepend the subdirectory the object is found in. non_pic_object=$xdir$non_pic_object # A standard non-PIC object func_append non_pic_objects " $non_pic_object" if test -z "$pic_object" || test none = "$pic_object"; then arg=$non_pic_object fi else # If the PIC object exists, use it instead. # $xdir was prepended to $pic_object above. non_pic_object=$pic_object func_append non_pic_objects " $non_pic_object" fi else # Only an error if not doing a dry-run. if $opt_dry_run; then # Extract subdirectory from the argument. func_dirname "$arg" "/" "" xdir=$func_dirname_result func_lo2o "$arg" pic_object=$xdir$objdir/$func_lo2o_result non_pic_object=$xdir$func_lo2o_result func_append libobjs " $pic_object" func_append non_pic_objects " $non_pic_object" else func_fatal_error "'$arg' is not a valid libtool object" fi fi ;; *.$libext) # An archive. func_append deplibs " $arg" func_append old_deplibs " $arg" continue ;; *.la) # A libtool-controlled library. func_resolve_sysroot "$arg" if test dlfiles = "$prev"; then # This library was specified with -dlopen. func_append dlfiles " $func_resolve_sysroot_result" prev= elif test dlprefiles = "$prev"; then # The library was specified with -dlpreopen. func_append dlprefiles " $func_resolve_sysroot_result" prev= else func_append deplibs " $func_resolve_sysroot_result" fi continue ;; # Some other compiler argument. *) # Unknown arguments in both finalize_command and compile_command need # to be aesthetically quoted because they are evaled later. func_quote_arg pretty "$arg" arg=$func_quote_arg_result ;; esac # arg # Now actually substitute the argument into the commands. if test -n "$arg"; then func_append compile_command " $arg" func_append finalize_command " $arg" fi done # argument parsing loop test -n "$prev" && \ func_fatal_help "the '$prevarg' option requires an argument" if test yes = "$export_dynamic" && test -n "$export_dynamic_flag_spec"; then eval arg=\"$export_dynamic_flag_spec\" func_append compile_command " $arg" func_append finalize_command " $arg" fi oldlibs= # calculate the name of the file, without its directory func_basename "$output" outputname=$func_basename_result libobjs_save=$libobjs if test -n "$shlibpath_var"; then # get the directories listed in $shlibpath_var eval shlib_search_path=\`\$ECHO \"\$$shlibpath_var\" \| \$SED \'s/:/ /g\'\` else shlib_search_path= fi eval sys_lib_search_path=\"$sys_lib_search_path_spec\" eval sys_lib_dlsearch_path=\"$sys_lib_dlsearch_path_spec\" # Definition is injected by LT_CONFIG during libtool generation. func_munge_path_list sys_lib_dlsearch_path "$LT_SYS_LIBRARY_PATH" func_dirname "$output" "/" "" output_objdir=$func_dirname_result$objdir func_to_tool_file "$output_objdir/" tool_output_objdir=$func_to_tool_file_result # Create the object directory. func_mkdir_p "$output_objdir" # Determine the type of output case $output in "") func_fatal_help "you must specify an output file" ;; *.$libext) linkmode=oldlib ;; *.lo | *.$objext) linkmode=obj ;; *.la) linkmode=lib ;; *) linkmode=prog ;; # Anything else should be a program. esac specialdeplibs= libs= # Find all interdependent deplibs by searching for libraries # that are linked more than once (e.g. -la -lb -la) for deplib in $deplibs; do if $opt_preserve_dup_deps; then case "$libs " in *" $deplib "*) func_append specialdeplibs " $deplib" ;; esac fi func_append libs " $deplib" done if test lib = "$linkmode"; then libs="$predeps $libs $compiler_lib_search_path $postdeps" # Compute libraries that are listed more than once in $predeps # $postdeps and mark them as special (i.e., whose duplicates are # not to be eliminated). pre_post_deps= if $opt_duplicate_compiler_generated_deps; then for pre_post_dep in $predeps $postdeps; do case "$pre_post_deps " in *" $pre_post_dep "*) func_append specialdeplibs " $pre_post_deps" ;; esac func_append pre_post_deps " $pre_post_dep" done fi pre_post_deps= fi deplibs= newdependency_libs= newlib_search_path= need_relink=no # whether we're linking any uninstalled libtool libraries notinst_deplibs= # not-installed libtool libraries notinst_path= # paths that contain not-installed libtool libraries case $linkmode in lib) passes="conv dlpreopen link" for file in $dlfiles $dlprefiles; do case $file in *.la) ;; *) func_fatal_help "libraries can '-dlopen' only libtool libraries: $file" ;; esac done ;; prog) compile_deplibs= finalize_deplibs= alldeplibs=false newdlfiles= newdlprefiles= passes="conv scan dlopen dlpreopen link" ;; *) passes="conv" ;; esac for pass in $passes; do # The preopen pass in lib mode reverses $deplibs; put it back here # so that -L comes before libs that need it for instance... if test lib,link = "$linkmode,$pass"; then ## FIXME: Find the place where the list is rebuilt in the wrong ## order, and fix it there properly tmp_deplibs= for deplib in $deplibs; do tmp_deplibs="$deplib $tmp_deplibs" done deplibs=$tmp_deplibs fi if test lib,link = "$linkmode,$pass" || test prog,scan = "$linkmode,$pass"; then libs=$deplibs deplibs= fi if test prog = "$linkmode"; then case $pass in dlopen) libs=$dlfiles ;; dlpreopen) libs=$dlprefiles ;; link) libs="$deplibs %DEPLIBS%" test "X$link_all_deplibs" != Xno && libs="$libs $dependency_libs" ;; esac fi if test lib,dlpreopen = "$linkmode,$pass"; then # Collect and forward deplibs of preopened libtool libs for lib in $dlprefiles; do # Ignore non-libtool-libs dependency_libs= func_resolve_sysroot "$lib" case $lib in *.la) func_source "$func_resolve_sysroot_result" ;; esac # Collect preopened libtool deplibs, except any this library # has declared as weak libs for deplib in $dependency_libs; do func_basename "$deplib" deplib_base=$func_basename_result case " $weak_libs " in *" $deplib_base "*) ;; *) func_append deplibs " $deplib" ;; esac done done libs=$dlprefiles fi if test dlopen = "$pass"; then # Collect dlpreopened libraries save_deplibs=$deplibs deplibs= fi for deplib in $libs; do lib= found=false case $deplib in -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \ |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*) if test prog,link = "$linkmode,$pass"; then compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else func_append compiler_flags " $deplib" if test lib = "$linkmode"; then case "$new_inherited_linker_flags " in *" $deplib "*) ;; * ) func_append new_inherited_linker_flags " $deplib" ;; esac fi fi continue ;; -l*) if test lib != "$linkmode" && test prog != "$linkmode"; then func_warning "'-l' is ignored for archives/objects" continue fi func_stripname '-l' '' "$deplib" name=$func_stripname_result if test lib = "$linkmode"; then searchdirs="$newlib_search_path $lib_search_path $compiler_lib_search_dirs $sys_lib_search_path $shlib_search_path" else searchdirs="$newlib_search_path $lib_search_path $sys_lib_search_path $shlib_search_path" fi for searchdir in $searchdirs; do for search_ext in .la $std_shrext .so .a; do # Search the libtool library lib=$searchdir/lib$name$search_ext if test -f "$lib"; then if test .la = "$search_ext"; then found=: else found=false fi break 2 fi done done if $found; then # deplib is a libtool library # If $allow_libtool_libs_with_static_runtimes && $deplib is a stdlib, # We need to do some special things here, and not later. if test yes = "$allow_libtool_libs_with_static_runtimes"; then case " $predeps $postdeps " in *" $deplib "*) if func_lalib_p "$lib"; then library_names= old_library= func_source "$lib" for l in $old_library $library_names; do ll=$l done if test "X$ll" = "X$old_library"; then # only static version available found=false func_dirname "$lib" "" "." ladir=$func_dirname_result lib=$ladir/$old_library if test prog,link = "$linkmode,$pass"; then compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else deplibs="$deplib $deplibs" test lib = "$linkmode" && newdependency_libs="$deplib $newdependency_libs" fi continue fi fi ;; *) ;; esac fi else # deplib doesn't seem to be a libtool library if test prog,link = "$linkmode,$pass"; then compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else deplibs="$deplib $deplibs" test lib = "$linkmode" && newdependency_libs="$deplib $newdependency_libs" fi continue fi ;; # -l *.ltframework) if test prog,link = "$linkmode,$pass"; then compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else deplibs="$deplib $deplibs" if test lib = "$linkmode"; then case "$new_inherited_linker_flags " in *" $deplib "*) ;; * ) func_append new_inherited_linker_flags " $deplib" ;; esac fi fi continue ;; -L*) case $linkmode in lib) deplibs="$deplib $deplibs" test conv = "$pass" && continue newdependency_libs="$deplib $newdependency_libs" func_stripname '-L' '' "$deplib" func_resolve_sysroot "$func_stripname_result" func_append newlib_search_path " $func_resolve_sysroot_result" ;; prog) if test conv = "$pass"; then deplibs="$deplib $deplibs" continue fi if test scan = "$pass"; then deplibs="$deplib $deplibs" else compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" fi func_stripname '-L' '' "$deplib" func_resolve_sysroot "$func_stripname_result" func_append newlib_search_path " $func_resolve_sysroot_result" ;; *) func_warning "'-L' is ignored for archives/objects" ;; esac # linkmode continue ;; # -L -R*) if test link = "$pass"; then func_stripname '-R' '' "$deplib" func_resolve_sysroot "$func_stripname_result" dir=$func_resolve_sysroot_result # Make sure the xrpath contains only unique directories. case "$xrpath " in *" $dir "*) ;; *) func_append xrpath " $dir" ;; esac fi deplibs="$deplib $deplibs" continue ;; *.la) func_resolve_sysroot "$deplib" lib=$func_resolve_sysroot_result ;; *.$libext) if test conv = "$pass"; then deplibs="$deplib $deplibs" continue fi case $linkmode in lib) # Linking convenience modules into shared libraries is allowed, # but linking other static libraries is non-portable. case " $dlpreconveniencelibs " in *" $deplib "*) ;; *) valid_a_lib=false case $deplibs_check_method in match_pattern*) set dummy $deplibs_check_method; shift match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` if eval "\$ECHO \"$deplib\"" 2>/dev/null | $SED 10q \ | $EGREP "$match_pattern_regex" > /dev/null; then valid_a_lib=: fi ;; pass_all) valid_a_lib=: ;; esac if $valid_a_lib; then echo $ECHO "*** Warning: Linking the shared library $output against the" $ECHO "*** static library $deplib is not portable!" deplibs="$deplib $deplibs" else echo $ECHO "*** Warning: Trying to link with static lib archive $deplib." echo "*** I have the capability to make that library automatically link in when" echo "*** you link to this library. But I can only do this if you have a" echo "*** shared version of the library, which you do not appear to have" echo "*** because the file extensions .$libext of this argument makes me believe" echo "*** that it is just a static archive that I should not use here." fi ;; esac continue ;; prog) if test link != "$pass"; then deplibs="$deplib $deplibs" else compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" fi continue ;; esac # linkmode ;; # *.$libext *.lo | *.$objext) if test conv = "$pass"; then deplibs="$deplib $deplibs" elif test prog = "$linkmode"; then if test dlpreopen = "$pass" || test yes != "$dlopen_support" || test no = "$build_libtool_libs"; then # If there is no dlopen support or we're linking statically, # we need to preload. func_append newdlprefiles " $deplib" compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else func_append newdlfiles " $deplib" fi fi continue ;; %DEPLIBS%) alldeplibs=: continue ;; esac # case $deplib $found || test -f "$lib" \ || func_fatal_error "cannot find the library '$lib' or unhandled argument '$deplib'" # Check to see that this really is a libtool archive. func_lalib_unsafe_p "$lib" \ || func_fatal_error "'$lib' is not a valid libtool archive" func_dirname "$lib" "" "." ladir=$func_dirname_result dlname= dlopen= dlpreopen= libdir= library_names= old_library= inherited_linker_flags= # If the library was installed with an old release of libtool, # it will not redefine variables installed, or shouldnotlink installed=yes shouldnotlink=no avoidtemprpath= # Read the .la file func_source "$lib" # Convert "-framework foo" to "foo.ltframework" if test -n "$inherited_linker_flags"; then tmp_inherited_linker_flags=`$ECHO "$inherited_linker_flags" | $SED 's/-framework \([^ $]*\)/\1.ltframework/g'` for tmp_inherited_linker_flag in $tmp_inherited_linker_flags; do case " $new_inherited_linker_flags " in *" $tmp_inherited_linker_flag "*) ;; *) func_append new_inherited_linker_flags " $tmp_inherited_linker_flag";; esac done fi dependency_libs=`$ECHO " $dependency_libs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` if test lib,link = "$linkmode,$pass" || test prog,scan = "$linkmode,$pass" || { test prog != "$linkmode" && test lib != "$linkmode"; }; then test -n "$dlopen" && func_append dlfiles " $dlopen" test -n "$dlpreopen" && func_append dlprefiles " $dlpreopen" fi if test conv = "$pass"; then # Only check for convenience libraries deplibs="$lib $deplibs" if test -z "$libdir"; then if test -z "$old_library"; then func_fatal_error "cannot find name of link library for '$lib'" fi # It is a libtool convenience library, so add in its objects. func_append convenience " $ladir/$objdir/$old_library" func_append old_convenience " $ladir/$objdir/$old_library" tmp_libs= for deplib in $dependency_libs; do deplibs="$deplib $deplibs" if $opt_preserve_dup_deps; then case "$tmp_libs " in *" $deplib "*) func_append specialdeplibs " $deplib" ;; esac fi func_append tmp_libs " $deplib" done elif test prog != "$linkmode" && test lib != "$linkmode"; then func_fatal_error "'$lib' is not a convenience library" fi continue fi # $pass = conv # Get the name of the library we link against. linklib= if test -n "$old_library" && { test yes = "$prefer_static_libs" || test built,no = "$prefer_static_libs,$installed"; }; then linklib=$old_library else for l in $old_library $library_names; do linklib=$l done fi if test -z "$linklib"; then func_fatal_error "cannot find name of link library for '$lib'" fi # This library was specified with -dlopen. if test dlopen = "$pass"; then test -z "$libdir" \ && func_fatal_error "cannot -dlopen a convenience library: '$lib'" if test -z "$dlname" || test yes != "$dlopen_support" || test no = "$build_libtool_libs" then # If there is no dlname, no dlopen support or we're linking # statically, we need to preload. We also need to preload any # dependent libraries so libltdl's deplib preloader doesn't # bomb out in the load deplibs phase. func_append dlprefiles " $lib $dependency_libs" else func_append newdlfiles " $lib" fi continue fi # $pass = dlopen # We need an absolute path. case $ladir in [\\/]* | [A-Za-z]:[\\/]*) abs_ladir=$ladir ;; *) abs_ladir=`cd "$ladir" && pwd` if test -z "$abs_ladir"; then func_warning "cannot determine absolute directory name of '$ladir'" func_warning "passing it literally to the linker, although it might fail" abs_ladir=$ladir fi ;; esac func_basename "$lib" laname=$func_basename_result # Find the relevant object directory and library name. if test yes = "$installed"; then if test ! -f "$lt_sysroot$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then func_warning "library '$lib' was moved." dir=$ladir absdir=$abs_ladir libdir=$abs_ladir else dir=$lt_sysroot$libdir absdir=$lt_sysroot$libdir fi test yes = "$hardcode_automatic" && avoidtemprpath=yes else if test ! -f "$ladir/$objdir/$linklib" && test -f "$abs_ladir/$linklib"; then dir=$ladir absdir=$abs_ladir # Remove this search path later func_append notinst_path " $abs_ladir" else dir=$ladir/$objdir absdir=$abs_ladir/$objdir # Remove this search path later func_append notinst_path " $abs_ladir" fi fi # $installed = yes func_stripname 'lib' '.la' "$laname" name=$func_stripname_result # This library was specified with -dlpreopen. if test dlpreopen = "$pass"; then if test -z "$libdir" && test prog = "$linkmode"; then func_fatal_error "only libraries may -dlpreopen a convenience library: '$lib'" fi case $host in # special handling for platforms with PE-DLLs. *cygwin* | *mingw* | *cegcc* ) # Linker will automatically link against shared library if both # static and shared are present. Therefore, ensure we extract # symbols from the import library if a shared library is present # (otherwise, the dlopen module name will be incorrect). We do # this by putting the import library name into $newdlprefiles. # We recover the dlopen module name by 'saving' the la file # name in a special purpose variable, and (later) extracting the # dlname from the la file. if test -n "$dlname"; then func_tr_sh "$dir/$linklib" eval "libfile_$func_tr_sh_result=\$abs_ladir/\$laname" func_append newdlprefiles " $dir/$linklib" else func_append newdlprefiles " $dir/$old_library" # Keep a list of preopened convenience libraries to check # that they are being used correctly in the link pass. test -z "$libdir" && \ func_append dlpreconveniencelibs " $dir/$old_library" fi ;; * ) # Prefer using a static library (so that no silly _DYNAMIC symbols # are required to link). if test -n "$old_library"; then func_append newdlprefiles " $dir/$old_library" # Keep a list of preopened convenience libraries to check # that they are being used correctly in the link pass. test -z "$libdir" && \ func_append dlpreconveniencelibs " $dir/$old_library" # Otherwise, use the dlname, so that lt_dlopen finds it. elif test -n "$dlname"; then func_append newdlprefiles " $dir/$dlname" else func_append newdlprefiles " $dir/$linklib" fi ;; esac fi # $pass = dlpreopen if test -z "$libdir"; then # Link the convenience library if test lib = "$linkmode"; then deplibs="$dir/$old_library $deplibs" elif test prog,link = "$linkmode,$pass"; then compile_deplibs="$dir/$old_library $compile_deplibs" finalize_deplibs="$dir/$old_library $finalize_deplibs" else deplibs="$lib $deplibs" # used for prog,scan pass fi continue fi if test prog = "$linkmode" && test link != "$pass"; then func_append newlib_search_path " $ladir" deplibs="$lib $deplibs" linkalldeplibs=false if test no != "$link_all_deplibs" || test -z "$library_names" || test no = "$build_libtool_libs"; then linkalldeplibs=: fi tmp_libs= for deplib in $dependency_libs; do case $deplib in -L*) func_stripname '-L' '' "$deplib" func_resolve_sysroot "$func_stripname_result" func_append newlib_search_path " $func_resolve_sysroot_result" ;; esac # Need to link against all dependency_libs? if $linkalldeplibs; then deplibs="$deplib $deplibs" else # Need to hardcode shared library paths # or/and link against static libraries newdependency_libs="$deplib $newdependency_libs" fi if $opt_preserve_dup_deps; then case "$tmp_libs " in *" $deplib "*) func_append specialdeplibs " $deplib" ;; esac fi func_append tmp_libs " $deplib" done # for deplib continue fi # $linkmode = prog... if test prog,link = "$linkmode,$pass"; then if test -n "$library_names" && { { test no = "$prefer_static_libs" || test built,yes = "$prefer_static_libs,$installed"; } || test -z "$old_library"; }; then # We need to hardcode the library path if test -n "$shlibpath_var" && test -z "$avoidtemprpath"; then # Make sure the rpath contains only unique directories. case $temp_rpath: in *"$absdir:"*) ;; *) func_append temp_rpath "$absdir:" ;; esac fi # Hardcode the library path. # Skip directories that are in the system default run-time # search path. case " $sys_lib_dlsearch_path " in *" $absdir "*) ;; *) case "$compile_rpath " in *" $absdir "*) ;; *) func_append compile_rpath " $absdir" ;; esac ;; esac case " $sys_lib_dlsearch_path " in *" $libdir "*) ;; *) case "$finalize_rpath " in *" $libdir "*) ;; *) func_append finalize_rpath " $libdir" ;; esac ;; esac fi # $linkmode,$pass = prog,link... if $alldeplibs && { test pass_all = "$deplibs_check_method" || { test yes = "$build_libtool_libs" && test -n "$library_names"; }; }; then # We only need to search for static libraries continue fi fi link_static=no # Whether the deplib will be linked statically use_static_libs=$prefer_static_libs if test built = "$use_static_libs" && test yes = "$installed"; then use_static_libs=no fi if test -n "$library_names" && { test no = "$use_static_libs" || test -z "$old_library"; }; then case $host in *cygwin* | *mingw* | *cegcc* | *os2*) # No point in relinking DLLs because paths are not encoded func_append notinst_deplibs " $lib" need_relink=no ;; *) if test no = "$installed"; then func_append notinst_deplibs " $lib" need_relink=yes fi ;; esac # This is a shared library # Warn about portability, can't link against -module's on some # systems (darwin). Don't bleat about dlopened modules though! dlopenmodule= for dlpremoduletest in $dlprefiles; do if test "X$dlpremoduletest" = "X$lib"; then dlopenmodule=$dlpremoduletest break fi done if test -z "$dlopenmodule" && test yes = "$shouldnotlink" && test link = "$pass"; then echo if test prog = "$linkmode"; then $ECHO "*** Warning: Linking the executable $output against the loadable module" else $ECHO "*** Warning: Linking the shared library $output against the loadable module" fi $ECHO "*** $linklib is not portable!" fi if test lib = "$linkmode" && test yes = "$hardcode_into_libs"; then # Hardcode the library path. # Skip directories that are in the system default run-time # search path. case " $sys_lib_dlsearch_path " in *" $absdir "*) ;; *) case "$compile_rpath " in *" $absdir "*) ;; *) func_append compile_rpath " $absdir" ;; esac ;; esac case " $sys_lib_dlsearch_path " in *" $libdir "*) ;; *) case "$finalize_rpath " in *" $libdir "*) ;; *) func_append finalize_rpath " $libdir" ;; esac ;; esac fi if test -n "$old_archive_from_expsyms_cmds"; then # figure out the soname set dummy $library_names shift realname=$1 shift libname=`eval "\\$ECHO \"$libname_spec\""` # use dlname if we got it. it's perfectly good, no? if test -n "$dlname"; then soname=$dlname elif test -n "$soname_spec"; then # bleh windows case $host in *cygwin* | mingw* | *cegcc* | *os2*) func_arith $current - $age major=$func_arith_result versuffix=-$major ;; esac eval soname=\"$soname_spec\" else soname=$realname fi # Make a new name for the extract_expsyms_cmds to use soroot=$soname func_basename "$soroot" soname=$func_basename_result func_stripname 'lib' '.dll' "$soname" newlib=libimp-$func_stripname_result.a # If the library has no export list, then create one now if test -f "$output_objdir/$soname-def"; then : else func_verbose "extracting exported symbol list from '$soname'" func_execute_cmds "$extract_expsyms_cmds" 'exit $?' fi # Create $newlib if test -f "$output_objdir/$newlib"; then :; else func_verbose "generating import library for '$soname'" func_execute_cmds "$old_archive_from_expsyms_cmds" 'exit $?' fi # make sure the library variables are pointing to the new library dir=$output_objdir linklib=$newlib fi # test -n "$old_archive_from_expsyms_cmds" if test prog = "$linkmode" || test relink != "$opt_mode"; then add_shlibpath= add_dir= add= lib_linked=yes case $hardcode_action in immediate | unsupported) if test no = "$hardcode_direct"; then add=$dir/$linklib case $host in *-*-sco3.2v5.0.[024]*) add_dir=-L$dir ;; *-*-sysv4*uw2*) add_dir=-L$dir ;; *-*-sysv5OpenUNIX* | *-*-sysv5UnixWare7.[01].[10]* | \ *-*-unixware7*) add_dir=-L$dir ;; *-*-darwin* ) # if the lib is a (non-dlopened) module then we cannot # link against it, someone is ignoring the earlier warnings if /usr/bin/file -L $add 2> /dev/null | $GREP ": [^:]* bundle" >/dev/null; then if test "X$dlopenmodule" != "X$lib"; then $ECHO "*** Warning: lib $linklib is a module, not a shared library" if test -z "$old_library"; then echo echo "*** And there doesn't seem to be a static archive available" echo "*** The link will probably fail, sorry" else add=$dir/$old_library fi elif test -n "$old_library"; then add=$dir/$old_library fi fi esac elif test no = "$hardcode_minus_L"; then case $host in *-*-sunos*) add_shlibpath=$dir ;; esac add_dir=-L$dir add=-l$name elif test no = "$hardcode_shlibpath_var"; then add_shlibpath=$dir add=-l$name else lib_linked=no fi ;; relink) if test yes = "$hardcode_direct" && test no = "$hardcode_direct_absolute"; then add=$dir/$linklib elif test yes = "$hardcode_minus_L"; then add_dir=-L$absdir # Try looking first in the location we're being installed to. if test -n "$inst_prefix_dir"; then case $libdir in [\\/]*) func_append add_dir " -L$inst_prefix_dir$libdir" ;; esac fi add=-l$name elif test yes = "$hardcode_shlibpath_var"; then add_shlibpath=$dir add=-l$name else lib_linked=no fi ;; *) lib_linked=no ;; esac if test yes != "$lib_linked"; then func_fatal_configuration "unsupported hardcode properties" fi if test -n "$add_shlibpath"; then case :$compile_shlibpath: in *":$add_shlibpath:"*) ;; *) func_append compile_shlibpath "$add_shlibpath:" ;; esac fi if test prog = "$linkmode"; then test -n "$add_dir" && compile_deplibs="$add_dir $compile_deplibs" test -n "$add" && compile_deplibs="$add $compile_deplibs" else test -n "$add_dir" && deplibs="$add_dir $deplibs" test -n "$add" && deplibs="$add $deplibs" if test yes != "$hardcode_direct" && test yes != "$hardcode_minus_L" && test yes = "$hardcode_shlibpath_var"; then case :$finalize_shlibpath: in *":$libdir:"*) ;; *) func_append finalize_shlibpath "$libdir:" ;; esac fi fi fi if test prog = "$linkmode" || test relink = "$opt_mode"; then add_shlibpath= add_dir= add= # Finalize command for both is simple: just hardcode it. if test yes = "$hardcode_direct" && test no = "$hardcode_direct_absolute"; then add=$libdir/$linklib elif test yes = "$hardcode_minus_L"; then add_dir=-L$libdir add=-l$name elif test yes = "$hardcode_shlibpath_var"; then case :$finalize_shlibpath: in *":$libdir:"*) ;; *) func_append finalize_shlibpath "$libdir:" ;; esac add=-l$name elif test yes = "$hardcode_automatic"; then if test -n "$inst_prefix_dir" && test -f "$inst_prefix_dir$libdir/$linklib"; then add=$inst_prefix_dir$libdir/$linklib else add=$libdir/$linklib fi else # We cannot seem to hardcode it, guess we'll fake it. add_dir=-L$libdir # Try looking first in the location we're being installed to. if test -n "$inst_prefix_dir"; then case $libdir in [\\/]*) func_append add_dir " -L$inst_prefix_dir$libdir" ;; esac fi add=-l$name fi if test prog = "$linkmode"; then test -n "$add_dir" && finalize_deplibs="$add_dir $finalize_deplibs" test -n "$add" && finalize_deplibs="$add $finalize_deplibs" else test -n "$add_dir" && deplibs="$add_dir $deplibs" test -n "$add" && deplibs="$add $deplibs" fi fi elif test prog = "$linkmode"; then # Here we assume that one of hardcode_direct or hardcode_minus_L # is not unsupported. This is valid on all known static and # shared platforms. if test unsupported != "$hardcode_direct"; then test -n "$old_library" && linklib=$old_library compile_deplibs="$dir/$linklib $compile_deplibs" finalize_deplibs="$dir/$linklib $finalize_deplibs" else compile_deplibs="-l$name -L$dir $compile_deplibs" finalize_deplibs="-l$name -L$dir $finalize_deplibs" fi elif test yes = "$build_libtool_libs"; then # Not a shared library if test pass_all != "$deplibs_check_method"; then # We're trying link a shared library against a static one # but the system doesn't support it. # Just print a warning and add the library to dependency_libs so # that the program can be linked against the static library. echo $ECHO "*** Warning: This system cannot link to static lib archive $lib." echo "*** I have the capability to make that library automatically link in when" echo "*** you link to this library. But I can only do this if you have a" echo "*** shared version of the library, which you do not appear to have." if test yes = "$module"; then echo "*** But as you try to build a module library, libtool will still create " echo "*** a static module, that should work as long as the dlopening application" echo "*** is linked with the -dlopen flag to resolve symbols at runtime." if test -z "$global_symbol_pipe"; then echo echo "*** However, this would only work if libtool was able to extract symbol" echo "*** lists from a program, using 'nm' or equivalent, but libtool could" echo "*** not find such a program. So, this module is probably useless." echo "*** 'nm' from GNU binutils and a full rebuild may help." fi if test no = "$build_old_libs"; then build_libtool_libs=module build_old_libs=yes else build_libtool_libs=no fi fi else deplibs="$dir/$old_library $deplibs" link_static=yes fi fi # link shared/static library? if test lib = "$linkmode"; then if test -n "$dependency_libs" && { test yes != "$hardcode_into_libs" || test yes = "$build_old_libs" || test yes = "$link_static"; }; then # Extract -R from dependency_libs temp_deplibs= for libdir in $dependency_libs; do case $libdir in -R*) func_stripname '-R' '' "$libdir" temp_xrpath=$func_stripname_result case " $xrpath " in *" $temp_xrpath "*) ;; *) func_append xrpath " $temp_xrpath";; esac;; *) func_append temp_deplibs " $libdir";; esac done dependency_libs=$temp_deplibs fi func_append newlib_search_path " $absdir" # Link against this library test no = "$link_static" && newdependency_libs="$abs_ladir/$laname $newdependency_libs" # ... and its dependency_libs tmp_libs= for deplib in $dependency_libs; do newdependency_libs="$deplib $newdependency_libs" case $deplib in -L*) func_stripname '-L' '' "$deplib" func_resolve_sysroot "$func_stripname_result";; *) func_resolve_sysroot "$deplib" ;; esac if $opt_preserve_dup_deps; then case "$tmp_libs " in *" $func_resolve_sysroot_result "*) func_append specialdeplibs " $func_resolve_sysroot_result" ;; esac fi func_append tmp_libs " $func_resolve_sysroot_result" done if test no != "$link_all_deplibs"; then # Add the search paths of all dependency libraries for deplib in $dependency_libs; do path= case $deplib in -L*) path=$deplib ;; *.la) func_resolve_sysroot "$deplib" deplib=$func_resolve_sysroot_result func_dirname "$deplib" "" "." dir=$func_dirname_result # We need an absolute path. case $dir in [\\/]* | [A-Za-z]:[\\/]*) absdir=$dir ;; *) absdir=`cd "$dir" && pwd` if test -z "$absdir"; then func_warning "cannot determine absolute directory name of '$dir'" absdir=$dir fi ;; esac if $GREP "^installed=no" $deplib > /dev/null; then case $host in *-*-darwin*) depdepl= eval deplibrary_names=`$SED -n -e 's/^library_names=\(.*\)$/\1/p' $deplib` if test -n "$deplibrary_names"; then for tmp in $deplibrary_names; do depdepl=$tmp done if test -f "$absdir/$objdir/$depdepl"; then depdepl=$absdir/$objdir/$depdepl darwin_install_name=`$OTOOL -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'` if test -z "$darwin_install_name"; then darwin_install_name=`$OTOOL64 -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'` fi func_append compiler_flags " $wl-dylib_file $wl$darwin_install_name:$depdepl" func_append linker_flags " -dylib_file $darwin_install_name:$depdepl" path= fi fi ;; *) path=-L$absdir/$objdir ;; esac else eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` test -z "$libdir" && \ func_fatal_error "'$deplib' is not a valid libtool archive" test "$absdir" != "$libdir" && \ func_warning "'$deplib' seems to be moved" path=-L$absdir fi ;; esac case " $deplibs " in *" $path "*) ;; *) deplibs="$path $deplibs" ;; esac done fi # link_all_deplibs != no fi # linkmode = lib done # for deplib in $libs if test link = "$pass"; then if test prog = "$linkmode"; then compile_deplibs="$new_inherited_linker_flags $compile_deplibs" finalize_deplibs="$new_inherited_linker_flags $finalize_deplibs" else compiler_flags="$compiler_flags "`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` fi fi dependency_libs=$newdependency_libs if test dlpreopen = "$pass"; then # Link the dlpreopened libraries before other libraries for deplib in $save_deplibs; do deplibs="$deplib $deplibs" done fi if test dlopen != "$pass"; then test conv = "$pass" || { # Make sure lib_search_path contains only unique directories. lib_search_path= for dir in $newlib_search_path; do case "$lib_search_path " in *" $dir "*) ;; *) func_append lib_search_path " $dir" ;; esac done newlib_search_path= } if test prog,link = "$linkmode,$pass"; then vars="compile_deplibs finalize_deplibs" else vars=deplibs fi for var in $vars dependency_libs; do # Add libraries to $var in reverse order eval tmp_libs=\"\$$var\" new_libs= for deplib in $tmp_libs; do # FIXME: Pedantically, this is the right thing to do, so # that some nasty dependency loop isn't accidentally # broken: #new_libs="$deplib $new_libs" # Pragmatically, this seems to cause very few problems in # practice: case $deplib in -L*) new_libs="$deplib $new_libs" ;; -R*) ;; *) # And here is the reason: when a library appears more # than once as an explicit dependence of a library, or # is implicitly linked in more than once by the # compiler, it is considered special, and multiple # occurrences thereof are not removed. Compare this # with having the same library being listed as a # dependency of multiple other libraries: in this case, # we know (pedantically, we assume) the library does not # need to be listed more than once, so we keep only the # last copy. This is not always right, but it is rare # enough that we require users that really mean to play # such unportable linking tricks to link the library # using -Wl,-lname, so that libtool does not consider it # for duplicate removal. case " $specialdeplibs " in *" $deplib "*) new_libs="$deplib $new_libs" ;; *) case " $new_libs " in *" $deplib "*) ;; *) new_libs="$deplib $new_libs" ;; esac ;; esac ;; esac done tmp_libs= for deplib in $new_libs; do case $deplib in -L*) case " $tmp_libs " in *" $deplib "*) ;; *) func_append tmp_libs " $deplib" ;; esac ;; *) func_append tmp_libs " $deplib" ;; esac done eval $var=\"$tmp_libs\" done # for var fi # Add Sun CC postdeps if required: test CXX = "$tagname" && { case $host_os in linux*) case `$CC -V 2>&1 | $SED 5q` in *Sun\ C*) # Sun C++ 5.9 func_suncc_cstd_abi if test no != "$suncc_use_cstd_abi"; then func_append postdeps ' -library=Cstd -library=Crun' fi ;; esac ;; solaris*) func_cc_basename "$CC" case $func_cc_basename_result in CC* | sunCC*) func_suncc_cstd_abi if test no != "$suncc_use_cstd_abi"; then func_append postdeps ' -library=Cstd -library=Crun' fi ;; esac ;; esac } # Last step: remove runtime libs from dependency_libs # (they stay in deplibs) tmp_libs= for i in $dependency_libs; do case " $predeps $postdeps $compiler_lib_search_path " in *" $i "*) i= ;; esac if test -n "$i"; then func_append tmp_libs " $i" fi done dependency_libs=$tmp_libs done # for pass if test prog = "$linkmode"; then dlfiles=$newdlfiles fi if test prog = "$linkmode" || test lib = "$linkmode"; then dlprefiles=$newdlprefiles fi case $linkmode in oldlib) if test -n "$dlfiles$dlprefiles" || test no != "$dlself"; then func_warning "'-dlopen' is ignored for archives" fi case " $deplibs" in *\ -l* | *\ -L*) func_warning "'-l' and '-L' are ignored for archives" ;; esac test -n "$rpath" && \ func_warning "'-rpath' is ignored for archives" test -n "$xrpath" && \ func_warning "'-R' is ignored for archives" test -n "$vinfo" && \ func_warning "'-version-info/-version-number' is ignored for archives" test -n "$release" && \ func_warning "'-release' is ignored for archives" test -n "$export_symbols$export_symbols_regex" && \ func_warning "'-export-symbols' is ignored for archives" # Now set the variables for building old libraries. build_libtool_libs=no oldlibs=$output func_append objs "$old_deplibs" ;; lib) # Make sure we only generate libraries of the form 'libNAME.la'. case $outputname in lib*) func_stripname 'lib' '.la' "$outputname" name=$func_stripname_result eval shared_ext=\"$shrext_cmds\" eval libname=\"$libname_spec\" ;; *) test no = "$module" \ && func_fatal_help "libtool library '$output' must begin with 'lib'" if test no != "$need_lib_prefix"; then # Add the "lib" prefix for modules if required func_stripname '' '.la' "$outputname" name=$func_stripname_result eval shared_ext=\"$shrext_cmds\" eval libname=\"$libname_spec\" else func_stripname '' '.la' "$outputname" libname=$func_stripname_result fi ;; esac if test -n "$objs"; then if test pass_all != "$deplibs_check_method"; then func_fatal_error "cannot build libtool library '$output' from non-libtool objects on this host:$objs" else echo $ECHO "*** Warning: Linking the shared library $output against the non-libtool" $ECHO "*** objects $objs is not portable!" func_append libobjs " $objs" fi fi test no = "$dlself" \ || func_warning "'-dlopen self' is ignored for libtool libraries" set dummy $rpath shift test 1 -lt "$#" \ && func_warning "ignoring multiple '-rpath's for a libtool library" install_libdir=$1 oldlibs= if test -z "$rpath"; then if test yes = "$build_libtool_libs"; then # Building a libtool convenience library. # Some compilers have problems with a '.al' extension so # convenience libraries should have the same extension an # archive normally would. oldlibs="$output_objdir/$libname.$libext $oldlibs" build_libtool_libs=convenience build_old_libs=yes fi test -n "$vinfo" && \ func_warning "'-version-info/-version-number' is ignored for convenience libraries" test -n "$release" && \ func_warning "'-release' is ignored for convenience libraries" else # Parse the version information argument. save_ifs=$IFS; IFS=: set dummy $vinfo 0 0 0 shift IFS=$save_ifs test -n "$7" && \ func_fatal_help "too many parameters to '-version-info'" # convert absolute version numbers to libtool ages # this retains compatibility with .la files and attempts # to make the code below a bit more comprehensible case $vinfo_number in yes) number_major=$1 number_minor=$2 number_revision=$3 # # There are really only two kinds -- those that # use the current revision as the major version # and those that subtract age and use age as # a minor version. But, then there is irix # that has an extra 1 added just for fun # case $version_type in # correct linux to gnu/linux during the next big refactor darwin|freebsd-elf|linux|midnightbsd-elf|osf|windows|none) func_arith $number_major + $number_minor current=$func_arith_result age=$number_minor revision=$number_revision ;; freebsd-aout|qnx|sunos) current=$number_major revision=$number_minor age=0 ;; irix|nonstopux) func_arith $number_major + $number_minor current=$func_arith_result age=$number_minor revision=$number_minor lt_irix_increment=no ;; *) func_fatal_configuration "$modename: unknown library version type '$version_type'" ;; esac ;; no) current=$1 revision=$2 age=$3 ;; esac # Check that each of the things are valid numbers. case $current in 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; *) func_error "CURRENT '$current' must be a nonnegative integer" func_fatal_error "'$vinfo' is not valid version information" ;; esac case $revision in 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; *) func_error "REVISION '$revision' must be a nonnegative integer" func_fatal_error "'$vinfo' is not valid version information" ;; esac case $age in 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; *) func_error "AGE '$age' must be a nonnegative integer" func_fatal_error "'$vinfo' is not valid version information" ;; esac if test "$age" -gt "$current"; then func_error "AGE '$age' is greater than the current interface number '$current'" func_fatal_error "'$vinfo' is not valid version information" fi # Calculate the version variables. major= versuffix= verstring= case $version_type in none) ;; darwin) # Like Linux, but with the current version available in # verstring for coding it into the library header func_arith $current - $age major=.$func_arith_result versuffix=$major.$age.$revision # Darwin ld doesn't like 0 for these options... func_arith $current + 1 minor_current=$func_arith_result xlcverstring="$wl-compatibility_version $wl$minor_current $wl-current_version $wl$minor_current.$revision" verstring="-compatibility_version $minor_current -current_version $minor_current.$revision" # On Darwin other compilers case $CC in nagfor*) verstring="$wl-compatibility_version $wl$minor_current $wl-current_version $wl$minor_current.$revision" ;; *) verstring="-compatibility_version $minor_current -current_version $minor_current.$revision" ;; esac ;; freebsd-aout) major=.$current versuffix=.$current.$revision ;; freebsd-elf | midnightbsd-elf) func_arith $current - $age major=.$func_arith_result versuffix=$major.$age.$revision ;; irix | nonstopux) if test no = "$lt_irix_increment"; then func_arith $current - $age else func_arith $current - $age + 1 fi major=$func_arith_result case $version_type in nonstopux) verstring_prefix=nonstopux ;; *) verstring_prefix=sgi ;; esac verstring=$verstring_prefix$major.$revision # Add in all the interfaces that we are compatible with. loop=$revision while test 0 -ne "$loop"; do func_arith $revision - $loop iface=$func_arith_result func_arith $loop - 1 loop=$func_arith_result verstring=$verstring_prefix$major.$iface:$verstring done # Before this point, $major must not contain '.'. major=.$major versuffix=$major.$revision ;; linux) # correct to gnu/linux during the next big refactor func_arith $current - $age major=.$func_arith_result versuffix=$major.$age.$revision ;; osf) func_arith $current - $age major=.$func_arith_result versuffix=.$current.$age.$revision verstring=$current.$age.$revision # Add in all the interfaces that we are compatible with. loop=$age while test 0 -ne "$loop"; do func_arith $current - $loop iface=$func_arith_result func_arith $loop - 1 loop=$func_arith_result verstring=$verstring:$iface.0 done # Make executables depend on our current version. func_append verstring ":$current.0" ;; qnx) major=.$current versuffix=.$current ;; sco) major=.$current versuffix=.$current ;; sunos) major=.$current versuffix=.$current.$revision ;; windows) # Use '-' rather than '.', since we only want one # extension on DOS 8.3 file systems. func_arith $current - $age major=$func_arith_result versuffix=-$major ;; *) func_fatal_configuration "unknown library version type '$version_type'" ;; esac # Clear the version info if we defaulted, and they specified a release. if test -z "$vinfo" && test -n "$release"; then major= case $version_type in darwin) # we can't check for "0.0" in archive_cmds due to quoting # problems, so we reset it completely verstring= ;; *) verstring=0.0 ;; esac if test no = "$need_version"; then versuffix= else versuffix=.0.0 fi fi # Remove version info from name if versioning should be avoided if test yes,no = "$avoid_version,$need_version"; then major= versuffix= verstring= fi # Check to see if the archive will have undefined symbols. if test yes = "$allow_undefined"; then if test unsupported = "$allow_undefined_flag"; then if test yes = "$build_old_libs"; then func_warning "undefined symbols not allowed in $host shared libraries; building static only" build_libtool_libs=no else func_fatal_error "can't build $host shared library unless -no-undefined is specified" fi fi else # Don't allow undefined symbols. allow_undefined_flag=$no_undefined_flag fi fi func_generate_dlsyms "$libname" "$libname" : func_append libobjs " $symfileobj" test " " = "$libobjs" && libobjs= if test relink != "$opt_mode"; then # Remove our outputs, but don't remove object files since they # may have been created when compiling PIC objects. removelist= tempremovelist=`$ECHO "$output_objdir/*"` for p in $tempremovelist; do case $p in *.$objext | *.gcno) ;; $output_objdir/$outputname | $output_objdir/$libname.* | $output_objdir/$libname$release.*) if test -n "$precious_files_regex"; then if $ECHO "$p" | $EGREP -e "$precious_files_regex" >/dev/null 2>&1 then continue fi fi func_append removelist " $p" ;; *) ;; esac done test -n "$removelist" && \ func_show_eval "${RM}r \$removelist" fi # Now set the variables for building old libraries. if test yes = "$build_old_libs" && test convenience != "$build_libtool_libs"; then func_append oldlibs " $output_objdir/$libname.$libext" # Transform .lo files to .o files. oldobjs="$objs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.$libext$/d; $lo2o" | $NL2SP` fi # Eliminate all temporary directories. #for path in $notinst_path; do # lib_search_path=`$ECHO "$lib_search_path " | $SED "s% $path % %g"` # deplibs=`$ECHO "$deplibs " | $SED "s% -L$path % %g"` # dependency_libs=`$ECHO "$dependency_libs " | $SED "s% -L$path % %g"` #done if test -n "$xrpath"; then # If the user specified any rpath flags, then add them. temp_xrpath= for libdir in $xrpath; do func_replace_sysroot "$libdir" func_append temp_xrpath " -R$func_replace_sysroot_result" case "$finalize_rpath " in *" $libdir "*) ;; *) func_append finalize_rpath " $libdir" ;; esac done if test yes != "$hardcode_into_libs" || test yes = "$build_old_libs"; then dependency_libs="$temp_xrpath $dependency_libs" fi fi # Make sure dlfiles contains only unique files that won't be dlpreopened old_dlfiles=$dlfiles dlfiles= for lib in $old_dlfiles; do case " $dlprefiles $dlfiles " in *" $lib "*) ;; *) func_append dlfiles " $lib" ;; esac done # Make sure dlprefiles contains only unique files old_dlprefiles=$dlprefiles dlprefiles= for lib in $old_dlprefiles; do case "$dlprefiles " in *" $lib "*) ;; *) func_append dlprefiles " $lib" ;; esac done if test yes = "$build_libtool_libs"; then if test -n "$rpath"; then case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos* | *-cegcc* | *-*-haiku*) # these systems don't actually have a c library (as such)! ;; *-*-rhapsody* | *-*-darwin1.[012]) # Rhapsody C library is in the System framework func_append deplibs " System.ltframework" ;; *-*-netbsd*) # Don't link with libc until the a.out ld.so is fixed. ;; *-*-openbsd* | *-*-freebsd* | *-*-dragonfly* | *-*-midnightbsd*) # Do not include libc due to us having libc/libc_r. ;; *-*-sco3.2v5* | *-*-sco5v6*) # Causes problems with __ctype ;; *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) # Compiler inserts libc in the correct place for threads to work ;; *) # Add libc to deplibs on all other systems if necessary. if test yes = "$build_libtool_need_lc"; then func_append deplibs " -lc" fi ;; esac fi # Transform deplibs into only deplibs that can be linked in shared. name_save=$name libname_save=$libname release_save=$release versuffix_save=$versuffix major_save=$major # I'm not sure if I'm treating the release correctly. I think # release should show up in the -l (ie -lgmp5) so we don't want to # add it in twice. Is that correct? release= versuffix= major= newdeplibs= droppeddeps=no case $deplibs_check_method in pass_all) # Don't check for shared/static. Everything works. # This might be a little naive. We might want to check # whether the library exists or not. But this is on # osf3 & osf4 and I'm not really sure... Just # implementing what was already the behavior. newdeplibs=$deplibs ;; test_compile) # This code stresses the "libraries are programs" paradigm to its # limits. Maybe even breaks it. We compile a program, linking it # against the deplibs as a proxy for the library. Then we can check # whether they linked in statically or dynamically with ldd. $opt_dry_run || $RM conftest.c cat > conftest.c </dev/null` $nocaseglob else potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null` fi for potent_lib in $potential_libs; do # Follow soft links. if ls -lLd "$potent_lib" 2>/dev/null | $GREP " -> " >/dev/null; then continue fi # The statement above tries to avoid entering an # endless loop below, in case of cyclic links. # We might still enter an endless loop, since a link # loop can be closed while we follow links, # but so what? potlib=$potent_lib while test -h "$potlib" 2>/dev/null; do potliblink=`ls -ld $potlib | $SED 's/.* -> //'` case $potliblink in [\\/]* | [A-Za-z]:[\\/]*) potlib=$potliblink;; *) potlib=`$ECHO "$potlib" | $SED 's|[^/]*$||'`"$potliblink";; esac done if eval $file_magic_cmd \"\$potlib\" 2>/dev/null | $SED -e 10q | $EGREP "$file_magic_regex" > /dev/null; then func_append newdeplibs " $a_deplib" a_deplib= break 2 fi done done fi if test -n "$a_deplib"; then droppeddeps=yes echo $ECHO "*** Warning: linker path does not have real file for library $a_deplib." echo "*** I have the capability to make that library automatically link in when" echo "*** you link to this library. But I can only do this if you have a" echo "*** shared version of the library, which you do not appear to have" echo "*** because I did check the linker path looking for a file starting" if test -z "$potlib"; then $ECHO "*** with $libname but no candidates were found. (...for file magic test)" else $ECHO "*** with $libname and none of the candidates passed a file format test" $ECHO "*** using a file magic. Last file checked: $potlib" fi fi ;; *) # Add a -L argument. func_append newdeplibs " $a_deplib" ;; esac done # Gone through all deplibs. ;; match_pattern*) set dummy $deplibs_check_method; shift match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` for a_deplib in $deplibs; do case $a_deplib in -l*) func_stripname -l '' "$a_deplib" name=$func_stripname_result if test yes = "$allow_libtool_libs_with_static_runtimes"; then case " $predeps $postdeps " in *" $a_deplib "*) func_append newdeplibs " $a_deplib" a_deplib= ;; esac fi if test -n "$a_deplib"; then libname=`eval "\\$ECHO \"$libname_spec\""` for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do potential_libs=`ls $i/$libname[.-]* 2>/dev/null` for potent_lib in $potential_libs; do potlib=$potent_lib # see symlink-check above in file_magic test if eval "\$ECHO \"$potent_lib\"" 2>/dev/null | $SED 10q | \ $EGREP "$match_pattern_regex" > /dev/null; then func_append newdeplibs " $a_deplib" a_deplib= break 2 fi done done fi if test -n "$a_deplib"; then droppeddeps=yes echo $ECHO "*** Warning: linker path does not have real file for library $a_deplib." echo "*** I have the capability to make that library automatically link in when" echo "*** you link to this library. But I can only do this if you have a" echo "*** shared version of the library, which you do not appear to have" echo "*** because I did check the linker path looking for a file starting" if test -z "$potlib"; then $ECHO "*** with $libname but no candidates were found. (...for regex pattern test)" else $ECHO "*** with $libname and none of the candidates passed a file format test" $ECHO "*** using a regex pattern. Last file checked: $potlib" fi fi ;; *) # Add a -L argument. func_append newdeplibs " $a_deplib" ;; esac done # Gone through all deplibs. ;; none | unknown | *) newdeplibs= tmp_deplibs=`$ECHO " $deplibs" | $SED 's/ -lc$//; s/ -[LR][^ ]*//g'` if test yes = "$allow_libtool_libs_with_static_runtimes"; then for i in $predeps $postdeps; do # can't use Xsed below, because $i might contain '/' tmp_deplibs=`$ECHO " $tmp_deplibs" | $SED "s|$i||"` done fi case $tmp_deplibs in *[!\ \ ]*) echo if test none = "$deplibs_check_method"; then echo "*** Warning: inter-library dependencies are not supported in this platform." else echo "*** Warning: inter-library dependencies are not known to be supported." fi echo "*** All declared inter-library dependencies are being dropped." droppeddeps=yes ;; esac ;; esac versuffix=$versuffix_save major=$major_save release=$release_save libname=$libname_save name=$name_save case $host in *-*-rhapsody* | *-*-darwin1.[012]) # On Rhapsody replace the C library with the System framework newdeplibs=`$ECHO " $newdeplibs" | $SED 's/ -lc / System.ltframework /'` ;; esac if test yes = "$droppeddeps"; then if test yes = "$module"; then echo echo "*** Warning: libtool could not satisfy all declared inter-library" $ECHO "*** dependencies of module $libname. Therefore, libtool will create" echo "*** a static module, that should work as long as the dlopening" echo "*** application is linked with the -dlopen flag." if test -z "$global_symbol_pipe"; then echo echo "*** However, this would only work if libtool was able to extract symbol" echo "*** lists from a program, using 'nm' or equivalent, but libtool could" echo "*** not find such a program. So, this module is probably useless." echo "*** 'nm' from GNU binutils and a full rebuild may help." fi if test no = "$build_old_libs"; then oldlibs=$output_objdir/$libname.$libext build_libtool_libs=module build_old_libs=yes else build_libtool_libs=no fi else echo "*** The inter-library dependencies that have been dropped here will be" echo "*** automatically added whenever a program is linked with this library" echo "*** or is declared to -dlopen it." if test no = "$allow_undefined"; then echo echo "*** Since this library must not contain undefined symbols," echo "*** because either the platform does not support them or" echo "*** it was explicitly requested with -no-undefined," echo "*** libtool will only create a static version of it." if test no = "$build_old_libs"; then oldlibs=$output_objdir/$libname.$libext build_libtool_libs=module build_old_libs=yes else build_libtool_libs=no fi fi fi fi # Done checking deplibs! deplibs=$newdeplibs fi # Time to change all our "foo.ltframework" stuff back to "-framework foo" case $host in *-*-darwin*) newdeplibs=`$ECHO " $newdeplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` new_inherited_linker_flags=`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` deplibs=`$ECHO " $deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` ;; esac # move library search paths that coincide with paths to not yet # installed libraries to the beginning of the library search list new_libs= for path in $notinst_path; do case " $new_libs " in *" -L$path/$objdir "*) ;; *) case " $deplibs " in *" -L$path/$objdir "*) func_append new_libs " -L$path/$objdir" ;; esac ;; esac done for deplib in $deplibs; do case $deplib in -L*) case " $new_libs " in *" $deplib "*) ;; *) func_append new_libs " $deplib" ;; esac ;; *) func_append new_libs " $deplib" ;; esac done deplibs=$new_libs # All the library-specific variables (install_libdir is set above). library_names= old_library= dlname= # Test again, we may have decided not to build it any more if test yes = "$build_libtool_libs"; then # Remove $wl instances when linking with ld. # FIXME: should test the right _cmds variable. case $archive_cmds in *\$LD\ *) wl= ;; esac if test yes = "$hardcode_into_libs"; then # Hardcode the library paths hardcode_libdirs= dep_rpath= rpath=$finalize_rpath test relink = "$opt_mode" || rpath=$compile_rpath$rpath for libdir in $rpath; do if test -n "$hardcode_libdir_flag_spec"; then if test -n "$hardcode_libdir_separator"; then func_replace_sysroot "$libdir" libdir=$func_replace_sysroot_result if test -z "$hardcode_libdirs"; then hardcode_libdirs=$libdir else # Just accumulate the unique libdirs. case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) ;; *) func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" ;; esac fi else eval flag=\"$hardcode_libdir_flag_spec\" func_append dep_rpath " $flag" fi elif test -n "$runpath_var"; then case "$perm_rpath " in *" $libdir "*) ;; *) func_append perm_rpath " $libdir" ;; esac fi done # Substitute the hardcoded libdirs into the rpath. if test -n "$hardcode_libdir_separator" && test -n "$hardcode_libdirs"; then libdir=$hardcode_libdirs eval "dep_rpath=\"$hardcode_libdir_flag_spec\"" fi if test -n "$runpath_var" && test -n "$perm_rpath"; then # We should set the runpath_var. rpath= for dir in $perm_rpath; do func_append rpath "$dir:" done eval "$runpath_var='$rpath\$$runpath_var'; export $runpath_var" fi test -n "$dep_rpath" && deplibs="$dep_rpath $deplibs" fi shlibpath=$finalize_shlibpath test relink = "$opt_mode" || shlibpath=$compile_shlibpath$shlibpath if test -n "$shlibpath"; then eval "$shlibpath_var='$shlibpath\$$shlibpath_var'; export $shlibpath_var" fi # Get the real and link names of the library. eval shared_ext=\"$shrext_cmds\" eval library_names=\"$library_names_spec\" set dummy $library_names shift realname=$1 shift if test -n "$soname_spec"; then eval soname=\"$soname_spec\" else soname=$realname fi if test -z "$dlname"; then dlname=$soname fi lib=$output_objdir/$realname linknames= for link do func_append linknames " $link" done # Use standard objects if they are pic test -z "$pic_flag" && libobjs=`$ECHO "$libobjs" | $SP2NL | $SED "$lo2o" | $NL2SP` test "X$libobjs" = "X " && libobjs= delfiles= if test -n "$export_symbols" && test -n "$include_expsyms"; then $opt_dry_run || cp "$export_symbols" "$output_objdir/$libname.uexp" export_symbols=$output_objdir/$libname.uexp func_append delfiles " $export_symbols" fi orig_export_symbols= case $host_os in cygwin* | mingw* | cegcc*) if test -n "$export_symbols" && test -z "$export_symbols_regex"; then # exporting using user supplied symfile func_dll_def_p "$export_symbols" || { # and it's NOT already a .def file. Must figure out # which of the given symbols are data symbols and tag # them as such. So, trigger use of export_symbols_cmds. # export_symbols gets reassigned inside the "prepare # the list of exported symbols" if statement, so the # include_expsyms logic still works. orig_export_symbols=$export_symbols export_symbols= always_export_symbols=yes } fi ;; esac # Prepare the list of exported symbols if test -z "$export_symbols"; then if test yes = "$always_export_symbols" || test -n "$export_symbols_regex"; then func_verbose "generating symbol list for '$libname.la'" export_symbols=$output_objdir/$libname.exp $opt_dry_run || $RM $export_symbols cmds=$export_symbols_cmds save_ifs=$IFS; IFS='~' for cmd1 in $cmds; do IFS=$save_ifs # Take the normal branch if the nm_file_list_spec branch # doesn't work or if tool conversion is not needed. case $nm_file_list_spec~$to_tool_file_cmd in *~func_convert_file_noop | *~func_convert_file_msys_to_w32 | ~*) try_normal_branch=yes eval cmd=\"$cmd1\" func_len " $cmd" len=$func_len_result ;; *) try_normal_branch=no ;; esac if test yes = "$try_normal_branch" \ && { test "$len" -lt "$max_cmd_len" \ || test "$max_cmd_len" -le -1; } then func_show_eval "$cmd" 'exit $?' skipped_export=false elif test -n "$nm_file_list_spec"; then func_basename "$output" output_la=$func_basename_result save_libobjs=$libobjs save_output=$output output=$output_objdir/$output_la.nm func_to_tool_file "$output" libobjs=$nm_file_list_spec$func_to_tool_file_result func_append delfiles " $output" func_verbose "creating $NM input file list: $output" for obj in $save_libobjs; do func_to_tool_file "$obj" $ECHO "$func_to_tool_file_result" done > "$output" eval cmd=\"$cmd1\" func_show_eval "$cmd" 'exit $?' output=$save_output libobjs=$save_libobjs skipped_export=false else # The command line is too long to execute in one step. func_verbose "using reloadable object file for export list..." skipped_export=: # Break out early, otherwise skipped_export may be # set to false by a later but shorter cmd. break fi done IFS=$save_ifs if test -n "$export_symbols_regex" && test : != "$skipped_export"; then func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' func_show_eval '$MV "${export_symbols}T" "$export_symbols"' fi fi fi if test -n "$export_symbols" && test -n "$include_expsyms"; then tmp_export_symbols=$export_symbols test -n "$orig_export_symbols" && tmp_export_symbols=$orig_export_symbols $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"' fi if test : != "$skipped_export" && test -n "$orig_export_symbols"; then # The given exports_symbols file has to be filtered, so filter it. func_verbose "filter symbol list for '$libname.la' to tag DATA exports" # FIXME: $output_objdir/$libname.filter potentially contains lots of # 's' commands, which not all seds can handle. GNU sed should be fine # though. Also, the filter scales superlinearly with the number of # global variables. join(1) would be nice here, but unfortunately # isn't a blessed tool. $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter func_append delfiles " $export_symbols $output_objdir/$libname.filter" export_symbols=$output_objdir/$libname.def $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols fi tmp_deplibs= for test_deplib in $deplibs; do case " $convenience " in *" $test_deplib "*) ;; *) func_append tmp_deplibs " $test_deplib" ;; esac done deplibs=$tmp_deplibs if test -n "$convenience"; then if test -n "$whole_archive_flag_spec" && test yes = "$compiler_needs_object" && test -z "$libobjs"; then # extract the archives, so we have objects to list. # TODO: could optimize this to just extract one archive. whole_archive_flag_spec= fi if test -n "$whole_archive_flag_spec"; then save_libobjs=$libobjs eval libobjs=\"\$libobjs $whole_archive_flag_spec\" test "X$libobjs" = "X " && libobjs= else gentop=$output_objdir/${outputname}x func_append generated " $gentop" func_extract_archives $gentop $convenience func_append libobjs " $func_extract_archives_result" test "X$libobjs" = "X " && libobjs= fi fi if test yes = "$thread_safe" && test -n "$thread_safe_flag_spec"; then eval flag=\"$thread_safe_flag_spec\" func_append linker_flags " $flag" fi # Make a backup of the uninstalled library when relinking if test relink = "$opt_mode"; then $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}U && $MV $realname ${realname}U)' || exit $? fi # Do each of the archive commands. if test yes = "$module" && test -n "$module_cmds"; then if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then eval test_cmds=\"$module_expsym_cmds\" cmds=$module_expsym_cmds else eval test_cmds=\"$module_cmds\" cmds=$module_cmds fi else if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then eval test_cmds=\"$archive_expsym_cmds\" cmds=$archive_expsym_cmds else eval test_cmds=\"$archive_cmds\" cmds=$archive_cmds fi fi if test : != "$skipped_export" && func_len " $test_cmds" && len=$func_len_result && test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then : else # The command line is too long to link in one step, link piecewise # or, if using GNU ld and skipped_export is not :, use a linker # script. # Save the value of $output and $libobjs because we want to # use them later. If we have whole_archive_flag_spec, we # want to use save_libobjs as it was before # whole_archive_flag_spec was expanded, because we can't # assume the linker understands whole_archive_flag_spec. # This may have to be revisited, in case too many # convenience libraries get linked in and end up exceeding # the spec. if test -z "$convenience" || test -z "$whole_archive_flag_spec"; then save_libobjs=$libobjs fi save_output=$output func_basename "$output" output_la=$func_basename_result # Clear the reloadable object creation command queue and # initialize k to one. test_cmds= concat_cmds= objlist= last_robj= k=1 if test -n "$save_libobjs" && test : != "$skipped_export" && test yes = "$with_gnu_ld"; then output=$output_objdir/$output_la.lnkscript func_verbose "creating GNU ld script: $output" echo 'INPUT (' > $output for obj in $save_libobjs do func_to_tool_file "$obj" $ECHO "$func_to_tool_file_result" >> $output done echo ')' >> $output func_append delfiles " $output" func_to_tool_file "$output" output=$func_to_tool_file_result elif test -n "$save_libobjs" && test : != "$skipped_export" && test -n "$file_list_spec"; then output=$output_objdir/$output_la.lnk func_verbose "creating linker input file list: $output" : > $output set x $save_libobjs shift firstobj= if test yes = "$compiler_needs_object"; then firstobj="$1 " shift fi for obj do func_to_tool_file "$obj" $ECHO "$func_to_tool_file_result" >> $output done func_append delfiles " $output" func_to_tool_file "$output" output=$firstobj\"$file_list_spec$func_to_tool_file_result\" else if test -n "$save_libobjs"; then func_verbose "creating reloadable object files..." output=$output_objdir/$output_la-$k.$objext eval test_cmds=\"$reload_cmds\" func_len " $test_cmds" len0=$func_len_result len=$len0 # Loop over the list of objects to be linked. for obj in $save_libobjs do func_len " $obj" func_arith $len + $func_len_result len=$func_arith_result if test -z "$objlist" || test "$len" -lt "$max_cmd_len"; then func_append objlist " $obj" else # The command $test_cmds is almost too long, add a # command to the queue. if test 1 -eq "$k"; then # The first file doesn't have a previous command to add. reload_objs=$objlist eval concat_cmds=\"$reload_cmds\" else # All subsequent reloadable object files will link in # the last one created. reload_objs="$objlist $last_robj" eval concat_cmds=\"\$concat_cmds~$reload_cmds~\$RM $last_robj\" fi last_robj=$output_objdir/$output_la-$k.$objext func_arith $k + 1 k=$func_arith_result output=$output_objdir/$output_la-$k.$objext objlist=" $obj" func_len " $last_robj" func_arith $len0 + $func_len_result len=$func_arith_result fi done # Handle the remaining objects by creating one last # reloadable object file. All subsequent reloadable object # files will link in the last one created. test -z "$concat_cmds" || concat_cmds=$concat_cmds~ reload_objs="$objlist $last_robj" eval concat_cmds=\"\$concat_cmds$reload_cmds\" if test -n "$last_robj"; then eval concat_cmds=\"\$concat_cmds~\$RM $last_robj\" fi func_append delfiles " $output" else output= fi ${skipped_export-false} && { func_verbose "generating symbol list for '$libname.la'" export_symbols=$output_objdir/$libname.exp $opt_dry_run || $RM $export_symbols libobjs=$output # Append the command to create the export file. test -z "$concat_cmds" || concat_cmds=$concat_cmds~ eval concat_cmds=\"\$concat_cmds$export_symbols_cmds\" if test -n "$last_robj"; then eval concat_cmds=\"\$concat_cmds~\$RM $last_robj\" fi } test -n "$save_libobjs" && func_verbose "creating a temporary reloadable object file: $output" # Loop through the commands generated above and execute them. save_ifs=$IFS; IFS='~' for cmd in $concat_cmds; do IFS=$save_ifs $opt_quiet || { func_quote_arg expand,pretty "$cmd" eval "func_echo $func_quote_arg_result" } $opt_dry_run || eval "$cmd" || { lt_exit=$? # Restore the uninstalled library and exit if test relink = "$opt_mode"; then ( cd "$output_objdir" && \ $RM "${realname}T" && \ $MV "${realname}U" "$realname" ) fi exit $lt_exit } done IFS=$save_ifs if test -n "$export_symbols_regex" && ${skipped_export-false}; then func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' func_show_eval '$MV "${export_symbols}T" "$export_symbols"' fi fi ${skipped_export-false} && { if test -n "$export_symbols" && test -n "$include_expsyms"; then tmp_export_symbols=$export_symbols test -n "$orig_export_symbols" && tmp_export_symbols=$orig_export_symbols $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"' fi if test -n "$orig_export_symbols"; then # The given exports_symbols file has to be filtered, so filter it. func_verbose "filter symbol list for '$libname.la' to tag DATA exports" # FIXME: $output_objdir/$libname.filter potentially contains lots of # 's' commands, which not all seds can handle. GNU sed should be fine # though. Also, the filter scales superlinearly with the number of # global variables. join(1) would be nice here, but unfortunately # isn't a blessed tool. $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter func_append delfiles " $export_symbols $output_objdir/$libname.filter" export_symbols=$output_objdir/$libname.def $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols fi } libobjs=$output # Restore the value of output. output=$save_output if test -n "$convenience" && test -n "$whole_archive_flag_spec"; then eval libobjs=\"\$libobjs $whole_archive_flag_spec\" test "X$libobjs" = "X " && libobjs= fi # Expand the library linking commands again to reset the # value of $libobjs for piecewise linking. # Do each of the archive commands. if test yes = "$module" && test -n "$module_cmds"; then if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then cmds=$module_expsym_cmds else cmds=$module_cmds fi else if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then cmds=$archive_expsym_cmds else cmds=$archive_cmds fi fi fi if test -n "$delfiles"; then # Append the command to remove temporary files to $cmds. eval cmds=\"\$cmds~\$RM $delfiles\" fi # Add any objects from preloaded convenience libraries if test -n "$dlprefiles"; then gentop=$output_objdir/${outputname}x func_append generated " $gentop" func_extract_archives $gentop $dlprefiles func_append libobjs " $func_extract_archives_result" test "X$libobjs" = "X " && libobjs= fi save_ifs=$IFS; IFS='~' for cmd in $cmds; do IFS=$sp$nl eval cmd=\"$cmd\" IFS=$save_ifs $opt_quiet || { func_quote_arg expand,pretty "$cmd" eval "func_echo $func_quote_arg_result" } $opt_dry_run || eval "$cmd" || { lt_exit=$? # Restore the uninstalled library and exit if test relink = "$opt_mode"; then ( cd "$output_objdir" && \ $RM "${realname}T" && \ $MV "${realname}U" "$realname" ) fi exit $lt_exit } done IFS=$save_ifs # Restore the uninstalled library and exit if test relink = "$opt_mode"; then $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}T && $MV $realname ${realname}T && $MV ${realname}U $realname)' || exit $? if test -n "$convenience"; then if test -z "$whole_archive_flag_spec"; then func_show_eval '${RM}r "$gentop"' fi fi exit $EXIT_SUCCESS fi # Create links to the real library. for linkname in $linknames; do if test "$realname" != "$linkname"; then func_show_eval '(cd "$output_objdir" && $RM "$linkname" && $LN_S "$realname" "$linkname")' 'exit $?' fi done # If -module or -export-dynamic was specified, set the dlname. if test yes = "$module" || test yes = "$export_dynamic"; then # On all known operating systems, these are identical. dlname=$soname fi fi ;; obj) if test -n "$dlfiles$dlprefiles" || test no != "$dlself"; then func_warning "'-dlopen' is ignored for objects" fi case " $deplibs" in *\ -l* | *\ -L*) func_warning "'-l' and '-L' are ignored for objects" ;; esac test -n "$rpath" && \ func_warning "'-rpath' is ignored for objects" test -n "$xrpath" && \ func_warning "'-R' is ignored for objects" test -n "$vinfo" && \ func_warning "'-version-info' is ignored for objects" test -n "$release" && \ func_warning "'-release' is ignored for objects" case $output in *.lo) test -n "$objs$old_deplibs" && \ func_fatal_error "cannot build library object '$output' from non-libtool objects" libobj=$output func_lo2o "$libobj" obj=$func_lo2o_result ;; *) libobj= obj=$output ;; esac # Delete the old objects. $opt_dry_run || $RM $obj $libobj # Objects from convenience libraries. This assumes # single-version convenience libraries. Whenever we create # different ones for PIC/non-PIC, this we'll have to duplicate # the extraction. reload_conv_objs= gentop= # if reload_cmds runs $LD directly, get rid of -Wl from # whole_archive_flag_spec and hope we can get by with turning comma # into space. case $reload_cmds in *\$LD[\ \$]*) wl= ;; esac if test -n "$convenience"; then if test -n "$whole_archive_flag_spec"; then eval tmp_whole_archive_flags=\"$whole_archive_flag_spec\" test -n "$wl" || tmp_whole_archive_flags=`$ECHO "$tmp_whole_archive_flags" | $SED 's|,| |g'` reload_conv_objs=$reload_objs\ $tmp_whole_archive_flags else gentop=$output_objdir/${obj}x func_append generated " $gentop" func_extract_archives $gentop $convenience reload_conv_objs="$reload_objs $func_extract_archives_result" fi fi # If we're not building shared, we need to use non_pic_objs test yes = "$build_libtool_libs" || libobjs=$non_pic_objects # Create the old-style object. reload_objs=$objs$old_deplibs' '`$ECHO "$libobjs" | $SP2NL | $SED "/\.$libext$/d; /\.lib$/d; $lo2o" | $NL2SP`' '$reload_conv_objs output=$obj func_execute_cmds "$reload_cmds" 'exit $?' # Exit if we aren't doing a library object file. if test -z "$libobj"; then if test -n "$gentop"; then func_show_eval '${RM}r "$gentop"' fi exit $EXIT_SUCCESS fi test yes = "$build_libtool_libs" || { if test -n "$gentop"; then func_show_eval '${RM}r "$gentop"' fi # Create an invalid libtool object if no PIC, so that we don't # accidentally link it into a program. # $show "echo timestamp > $libobj" # $opt_dry_run || eval "echo timestamp > $libobj" || exit $? exit $EXIT_SUCCESS } if test -n "$pic_flag" || test default != "$pic_mode"; then # Only do commands if we really have different PIC objects. reload_objs="$libobjs $reload_conv_objs" output=$libobj func_execute_cmds "$reload_cmds" 'exit $?' fi if test -n "$gentop"; then func_show_eval '${RM}r "$gentop"' fi exit $EXIT_SUCCESS ;; prog) case $host in *cygwin*) func_stripname '' '.exe' "$output" output=$func_stripname_result.exe;; esac test -n "$vinfo" && \ func_warning "'-version-info' is ignored for programs" test -n "$release" && \ func_warning "'-release' is ignored for programs" $preload \ && test unknown,unknown,unknown = "$dlopen_support,$dlopen_self,$dlopen_self_static" \ && func_warning "'LT_INIT([dlopen])' not used. Assuming no dlopen support." case $host in *-*-rhapsody* | *-*-darwin1.[012]) # On Rhapsody replace the C library is the System framework compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's/ -lc / System.ltframework /'` finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's/ -lc / System.ltframework /'` ;; esac case $host in *-*-darwin*) # Don't allow lazy linking, it breaks C++ global constructors # But is supposedly fixed on 10.4 or later (yay!). if test CXX = "$tagname"; then case ${MACOSX_DEPLOYMENT_TARGET-10.0} in 10.[0123]) func_append compile_command " $wl-bind_at_load" func_append finalize_command " $wl-bind_at_load" ;; esac fi # Time to change all our "foo.ltframework" stuff back to "-framework foo" compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` ;; esac # move library search paths that coincide with paths to not yet # installed libraries to the beginning of the library search list new_libs= for path in $notinst_path; do case " $new_libs " in *" -L$path/$objdir "*) ;; *) case " $compile_deplibs " in *" -L$path/$objdir "*) func_append new_libs " -L$path/$objdir" ;; esac ;; esac done for deplib in $compile_deplibs; do case $deplib in -L*) case " $new_libs " in *" $deplib "*) ;; *) func_append new_libs " $deplib" ;; esac ;; *) func_append new_libs " $deplib" ;; esac done compile_deplibs=$new_libs func_append compile_command " $compile_deplibs" func_append finalize_command " $finalize_deplibs" if test -n "$rpath$xrpath"; then # If the user specified any rpath flags, then add them. for libdir in $rpath $xrpath; do # This is the magic to use -rpath. case "$finalize_rpath " in *" $libdir "*) ;; *) func_append finalize_rpath " $libdir" ;; esac done fi # Now hardcode the library paths rpath= hardcode_libdirs= for libdir in $compile_rpath $finalize_rpath; do if test -n "$hardcode_libdir_flag_spec"; then if test -n "$hardcode_libdir_separator"; then if test -z "$hardcode_libdirs"; then hardcode_libdirs=$libdir else # Just accumulate the unique libdirs. case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) ;; *) func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" ;; esac fi else eval flag=\"$hardcode_libdir_flag_spec\" func_append rpath " $flag" fi elif test -n "$runpath_var"; then case "$perm_rpath " in *" $libdir "*) ;; *) func_append perm_rpath " $libdir" ;; esac fi case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) testbindir=`$ECHO "$libdir" | $SED -e 's*/lib$*/bin*'` case :$dllsearchpath: in *":$libdir:"*) ;; ::) dllsearchpath=$libdir;; *) func_append dllsearchpath ":$libdir";; esac case :$dllsearchpath: in *":$testbindir:"*) ;; ::) dllsearchpath=$testbindir;; *) func_append dllsearchpath ":$testbindir";; esac ;; esac done # Substitute the hardcoded libdirs into the rpath. if test -n "$hardcode_libdir_separator" && test -n "$hardcode_libdirs"; then libdir=$hardcode_libdirs eval rpath=\" $hardcode_libdir_flag_spec\" fi compile_rpath=$rpath rpath= hardcode_libdirs= for libdir in $finalize_rpath; do if test -n "$hardcode_libdir_flag_spec"; then if test -n "$hardcode_libdir_separator"; then if test -z "$hardcode_libdirs"; then hardcode_libdirs=$libdir else # Just accumulate the unique libdirs. case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) ;; *) func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" ;; esac fi else eval flag=\"$hardcode_libdir_flag_spec\" func_append rpath " $flag" fi elif test -n "$runpath_var"; then case "$finalize_perm_rpath " in *" $libdir "*) ;; *) func_append finalize_perm_rpath " $libdir" ;; esac fi done # Substitute the hardcoded libdirs into the rpath. if test -n "$hardcode_libdir_separator" && test -n "$hardcode_libdirs"; then libdir=$hardcode_libdirs eval rpath=\" $hardcode_libdir_flag_spec\" fi finalize_rpath=$rpath if test -n "$libobjs" && test yes = "$build_old_libs"; then # Transform all the library objects into standard objects. compile_command=`$ECHO "$compile_command" | $SP2NL | $SED "$lo2o" | $NL2SP` finalize_command=`$ECHO "$finalize_command" | $SP2NL | $SED "$lo2o" | $NL2SP` fi func_generate_dlsyms "$outputname" "@PROGRAM@" false # template prelinking step if test -n "$prelink_cmds"; then func_execute_cmds "$prelink_cmds" 'exit $?' fi wrappers_required=: case $host in *cegcc* | *mingw32ce*) # Disable wrappers for cegcc and mingw32ce hosts, we are cross compiling anyway. wrappers_required=false ;; *cygwin* | *mingw* ) test yes = "$build_libtool_libs" || wrappers_required=false ;; *) if test no = "$need_relink" || test yes != "$build_libtool_libs"; then wrappers_required=false fi ;; esac $wrappers_required || { # Replace the output file specification. compile_command=`$ECHO "$compile_command" | $SED 's%@OUTPUT@%'"$output"'%g'` link_command=$compile_command$compile_rpath # We have no uninstalled library dependencies, so finalize right now. exit_status=0 func_show_eval "$link_command" 'exit_status=$?' if test -n "$postlink_cmds"; then func_to_tool_file "$output" postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` func_execute_cmds "$postlink_cmds" 'exit $?' fi # Delete the generated files. if test -f "$output_objdir/${outputname}S.$objext"; then func_show_eval '$RM "$output_objdir/${outputname}S.$objext"' fi exit $exit_status } if test -n "$compile_shlibpath$finalize_shlibpath"; then compile_command="$shlibpath_var=\"$compile_shlibpath$finalize_shlibpath\$$shlibpath_var\" $compile_command" fi if test -n "$finalize_shlibpath"; then finalize_command="$shlibpath_var=\"$finalize_shlibpath\$$shlibpath_var\" $finalize_command" fi compile_var= finalize_var= if test -n "$runpath_var"; then if test -n "$perm_rpath"; then # We should set the runpath_var. rpath= for dir in $perm_rpath; do func_append rpath "$dir:" done compile_var="$runpath_var=\"$rpath\$$runpath_var\" " fi if test -n "$finalize_perm_rpath"; then # We should set the runpath_var. rpath= for dir in $finalize_perm_rpath; do func_append rpath "$dir:" done finalize_var="$runpath_var=\"$rpath\$$runpath_var\" " fi fi if test yes = "$no_install"; then # We don't need to create a wrapper script. link_command=$compile_var$compile_command$compile_rpath # Replace the output file specification. link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output"'%g'` # Delete the old output file. $opt_dry_run || $RM $output # Link the executable and exit func_show_eval "$link_command" 'exit $?' if test -n "$postlink_cmds"; then func_to_tool_file "$output" postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` func_execute_cmds "$postlink_cmds" 'exit $?' fi exit $EXIT_SUCCESS fi case $hardcode_action,$fast_install in relink,*) # Fast installation is not supported link_command=$compile_var$compile_command$compile_rpath relink_command=$finalize_var$finalize_command$finalize_rpath func_warning "this platform does not like uninstalled shared libraries" func_warning "'$output' will be relinked during installation" ;; *,yes) link_command=$finalize_var$compile_command$finalize_rpath relink_command=`$ECHO "$compile_var$compile_command$compile_rpath" | $SED 's%@OUTPUT@%\$progdir/\$file%g'` ;; *,no) link_command=$compile_var$compile_command$compile_rpath relink_command=$finalize_var$finalize_command$finalize_rpath ;; *,needless) link_command=$finalize_var$compile_command$finalize_rpath relink_command= ;; esac # Replace the output file specification. link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'` # Delete the old output files. $opt_dry_run || $RM $output $output_objdir/$outputname $output_objdir/lt-$outputname func_show_eval "$link_command" 'exit $?' if test -n "$postlink_cmds"; then func_to_tool_file "$output_objdir/$outputname" postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` func_execute_cmds "$postlink_cmds" 'exit $?' fi # Now create the wrapper script. func_verbose "creating $output" # Quote the relink command for shipping. if test -n "$relink_command"; then # Preserve any variables that may affect compiler behavior for var in $variables_saved_for_relink; do if eval test -z \"\${$var+set}\"; then relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command" elif eval var_value=\$$var; test -z "$var_value"; then relink_command="$var=; export $var; $relink_command" else func_quote_arg pretty "$var_value" relink_command="$var=$func_quote_arg_result; export $var; $relink_command" fi done func_quote eval cd "`pwd`" func_quote_arg pretty,unquoted "($func_quote_result; $relink_command)" relink_command=$func_quote_arg_unquoted_result fi # Only actually do things if not in dry run mode. $opt_dry_run || { # win32 will think the script is a binary if it has # a .exe suffix, so we strip it off here. case $output in *.exe) func_stripname '' '.exe' "$output" output=$func_stripname_result ;; esac # test for cygwin because mv fails w/o .exe extensions case $host in *cygwin*) exeext=.exe func_stripname '' '.exe' "$outputname" outputname=$func_stripname_result ;; *) exeext= ;; esac case $host in *cygwin* | *mingw* ) func_dirname_and_basename "$output" "" "." output_name=$func_basename_result output_path=$func_dirname_result cwrappersource=$output_path/$objdir/lt-$output_name.c cwrapper=$output_path/$output_name.exe $RM $cwrappersource $cwrapper trap "$RM $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15 func_emit_cwrapperexe_src > $cwrappersource # The wrapper executable is built using the $host compiler, # because it contains $host paths and files. If cross- # compiling, it, like the target executable, must be # executed on the $host or under an emulation environment. $opt_dry_run || { $LTCC $LTCFLAGS -o $cwrapper $cwrappersource $STRIP $cwrapper } # Now, create the wrapper script for func_source use: func_ltwrapper_scriptname $cwrapper $RM $func_ltwrapper_scriptname_result trap "$RM $func_ltwrapper_scriptname_result; exit $EXIT_FAILURE" 1 2 15 $opt_dry_run || { # note: this script will not be executed, so do not chmod. if test "x$build" = "x$host"; then $cwrapper --lt-dump-script > $func_ltwrapper_scriptname_result else func_emit_wrapper no > $func_ltwrapper_scriptname_result fi } ;; * ) $RM $output trap "$RM $output; exit $EXIT_FAILURE" 1 2 15 func_emit_wrapper no > $output chmod +x $output ;; esac } exit $EXIT_SUCCESS ;; esac # See if we need to build an old-fashioned archive. for oldlib in $oldlibs; do case $build_libtool_libs in convenience) oldobjs="$libobjs_save $symfileobj" addlibs=$convenience build_libtool_libs=no ;; module) oldobjs=$libobjs_save addlibs=$old_convenience build_libtool_libs=no ;; *) oldobjs="$old_deplibs $non_pic_objects" $preload && test -f "$symfileobj" \ && func_append oldobjs " $symfileobj" addlibs=$old_convenience ;; esac if test -n "$addlibs"; then gentop=$output_objdir/${outputname}x func_append generated " $gentop" func_extract_archives $gentop $addlibs func_append oldobjs " $func_extract_archives_result" fi # Do each command in the archive commands. if test -n "$old_archive_from_new_cmds" && test yes = "$build_libtool_libs"; then cmds=$old_archive_from_new_cmds else # Add any objects from preloaded convenience libraries if test -n "$dlprefiles"; then gentop=$output_objdir/${outputname}x func_append generated " $gentop" func_extract_archives $gentop $dlprefiles func_append oldobjs " $func_extract_archives_result" fi # POSIX demands no paths to be encoded in archives. We have # to avoid creating archives with duplicate basenames if we # might have to extract them afterwards, e.g., when creating a # static archive out of a convenience library, or when linking # the entirety of a libtool archive into another (currently # not supported by libtool). if (for obj in $oldobjs do func_basename "$obj" $ECHO "$func_basename_result" done | sort | sort -uc >/dev/null 2>&1); then : else echo "copying selected object files to avoid basename conflicts..." gentop=$output_objdir/${outputname}x func_append generated " $gentop" func_mkdir_p "$gentop" save_oldobjs=$oldobjs oldobjs= counter=1 for obj in $save_oldobjs do func_basename "$obj" objbase=$func_basename_result case " $oldobjs " in " ") oldobjs=$obj ;; *[\ /]"$objbase "*) while :; do # Make sure we don't pick an alternate name that also # overlaps. newobj=lt$counter-$objbase func_arith $counter + 1 counter=$func_arith_result case " $oldobjs " in *[\ /]"$newobj "*) ;; *) if test ! -f "$gentop/$newobj"; then break; fi ;; esac done func_show_eval "ln $obj $gentop/$newobj || cp $obj $gentop/$newobj" func_append oldobjs " $gentop/$newobj" ;; *) func_append oldobjs " $obj" ;; esac done fi func_to_tool_file "$oldlib" func_convert_file_msys_to_w32 tool_oldlib=$func_to_tool_file_result eval cmds=\"$old_archive_cmds\" func_len " $cmds" len=$func_len_result if test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then cmds=$old_archive_cmds elif test -n "$archiver_list_spec"; then func_verbose "using command file archive linking..." for obj in $oldobjs do func_to_tool_file "$obj" $ECHO "$func_to_tool_file_result" done > $output_objdir/$libname.libcmd func_to_tool_file "$output_objdir/$libname.libcmd" oldobjs=" $archiver_list_spec$func_to_tool_file_result" cmds=$old_archive_cmds else # the command line is too long to link in one step, link in parts func_verbose "using piecewise archive linking..." save_RANLIB=$RANLIB RANLIB=: objlist= concat_cmds= save_oldobjs=$oldobjs oldobjs= # Is there a better way of finding the last object in the list? for obj in $save_oldobjs do last_oldobj=$obj done eval test_cmds=\"$old_archive_cmds\" func_len " $test_cmds" len0=$func_len_result len=$len0 for obj in $save_oldobjs do func_len " $obj" func_arith $len + $func_len_result len=$func_arith_result func_append objlist " $obj" if test "$len" -lt "$max_cmd_len"; then : else # the above command should be used before it gets too long oldobjs=$objlist if test "$obj" = "$last_oldobj"; then RANLIB=$save_RANLIB fi test -z "$concat_cmds" || concat_cmds=$concat_cmds~ eval concat_cmds=\"\$concat_cmds$old_archive_cmds\" objlist= len=$len0 fi done RANLIB=$save_RANLIB oldobjs=$objlist if test -z "$oldobjs"; then eval cmds=\"\$concat_cmds\" else eval cmds=\"\$concat_cmds~\$old_archive_cmds\" fi fi fi func_execute_cmds "$cmds" 'exit $?' done test -n "$generated" && \ func_show_eval "${RM}r$generated" # Now create the libtool archive. case $output in *.la) old_library= test yes = "$build_old_libs" && old_library=$libname.$libext func_verbose "creating $output" # Preserve any variables that may affect compiler behavior for var in $variables_saved_for_relink; do if eval test -z \"\${$var+set}\"; then relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command" elif eval var_value=\$$var; test -z "$var_value"; then relink_command="$var=; export $var; $relink_command" else func_quote_arg pretty,unquoted "$var_value" relink_command="$var=$func_quote_arg_unquoted_result; export $var; $relink_command" fi done # Quote the link command for shipping. func_quote eval cd "`pwd`" relink_command="($func_quote_result; $SHELL \"$progpath\" $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)" func_quote_arg pretty,unquoted "$relink_command" relink_command=$func_quote_arg_unquoted_result if test yes = "$hardcode_automatic"; then relink_command= fi # Only create the output if not a dry run. $opt_dry_run || { for installed in no yes; do if test yes = "$installed"; then if test -z "$install_libdir"; then break fi output=$output_objdir/${outputname}i # Replace all uninstalled libtool libraries with the installed ones newdependency_libs= for deplib in $dependency_libs; do case $deplib in *.la) func_basename "$deplib" name=$func_basename_result func_resolve_sysroot "$deplib" eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $func_resolve_sysroot_result` test -z "$libdir" && \ func_fatal_error "'$deplib' is not a valid libtool archive" func_append newdependency_libs " ${lt_sysroot:+=}$libdir/$name" ;; -L*) func_stripname -L '' "$deplib" func_replace_sysroot "$func_stripname_result" func_append newdependency_libs " -L$func_replace_sysroot_result" ;; -R*) func_stripname -R '' "$deplib" func_replace_sysroot "$func_stripname_result" func_append newdependency_libs " -R$func_replace_sysroot_result" ;; *) func_append newdependency_libs " $deplib" ;; esac done dependency_libs=$newdependency_libs newdlfiles= for lib in $dlfiles; do case $lib in *.la) func_basename "$lib" name=$func_basename_result eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $lib` test -z "$libdir" && \ func_fatal_error "'$lib' is not a valid libtool archive" func_append newdlfiles " ${lt_sysroot:+=}$libdir/$name" ;; *) func_append newdlfiles " $lib" ;; esac done dlfiles=$newdlfiles newdlprefiles= for lib in $dlprefiles; do case $lib in *.la) # Only pass preopened files to the pseudo-archive (for # eventual linking with the app. that links it) if we # didn't already link the preopened objects directly into # the library: func_basename "$lib" name=$func_basename_result eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $lib` test -z "$libdir" && \ func_fatal_error "'$lib' is not a valid libtool archive" func_append newdlprefiles " ${lt_sysroot:+=}$libdir/$name" ;; esac done dlprefiles=$newdlprefiles else newdlfiles= for lib in $dlfiles; do case $lib in [\\/]* | [A-Za-z]:[\\/]*) abs=$lib ;; *) abs=`pwd`"/$lib" ;; esac func_append newdlfiles " $abs" done dlfiles=$newdlfiles newdlprefiles= for lib in $dlprefiles; do case $lib in [\\/]* | [A-Za-z]:[\\/]*) abs=$lib ;; *) abs=`pwd`"/$lib" ;; esac func_append newdlprefiles " $abs" done dlprefiles=$newdlprefiles fi $RM $output # place dlname in correct position for cygwin # In fact, it would be nice if we could use this code for all target # systems that can't hard-code library paths into their executables # and that have no shared library path variable independent of PATH, # but it turns out we can't easily determine that from inspecting # libtool variables, so we have to hard-code the OSs to which it # applies here; at the moment, that means platforms that use the PE # object format with DLL files. See the long comment at the top of # tests/bindir.at for full details. tdlname=$dlname case $host,$output,$installed,$module,$dlname in *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll | *cegcc*,*lai,yes,no,*.dll) # If a -bindir argument was supplied, place the dll there. if test -n "$bindir"; then func_relative_path "$install_libdir" "$bindir" tdlname=$func_relative_path_result/$dlname else # Otherwise fall back on heuristic. tdlname=../bin/$dlname fi ;; esac $ECHO > $output "\ # $outputname - a libtool library file # Generated by $PROGRAM (GNU $PACKAGE) $VERSION # # Please DO NOT delete this file! # It is necessary for linking the library. # The name that we can dlopen(3). dlname='$tdlname' # Names of this library. library_names='$library_names' # The name of the static archive. old_library='$old_library' # Linker flags that cannot go in dependency_libs. inherited_linker_flags='$new_inherited_linker_flags' # Libraries that this one depends upon. dependency_libs='$dependency_libs' # Names of additional weak libraries provided by this library weak_library_names='$weak_libs' # Version information for $libname. current=$current age=$age revision=$revision # Is this an already installed library? installed=$installed # Should we warn about portability when linking against -modules? shouldnotlink=$module # Files to dlopen/dlpreopen dlopen='$dlfiles' dlpreopen='$dlprefiles' # Directory that this library needs to be installed in: libdir='$install_libdir'" if test no,yes = "$installed,$need_relink"; then $ECHO >> $output "\ relink_command=\"$relink_command\"" fi done } # Do a symbolic link so that the libtool archive can be found in # LD_LIBRARY_PATH before the program is installed. func_show_eval '( cd "$output_objdir" && $RM "$outputname" && $LN_S "../$outputname" "$outputname" )' 'exit $?' ;; esac exit $EXIT_SUCCESS } if test link = "$opt_mode" || test relink = "$opt_mode"; then func_mode_link ${1+"$@"} fi # func_mode_uninstall arg... func_mode_uninstall () { $debug_cmd RM=$nonopt files= rmforce=false exit_status=0 # This variable tells wrapper scripts just to set variables rather # than running their programs. libtool_install_magic=$magic for arg do case $arg in -f) func_append RM " $arg"; rmforce=: ;; -*) func_append RM " $arg" ;; *) func_append files " $arg" ;; esac done test -z "$RM" && \ func_fatal_help "you must specify an RM program" rmdirs= for file in $files; do func_dirname "$file" "" "." dir=$func_dirname_result if test . = "$dir"; then odir=$objdir else odir=$dir/$objdir fi func_basename "$file" name=$func_basename_result test uninstall = "$opt_mode" && odir=$dir # Remember odir for removal later, being careful to avoid duplicates if test clean = "$opt_mode"; then case " $rmdirs " in *" $odir "*) ;; *) func_append rmdirs " $odir" ;; esac fi # Don't error if the file doesn't exist and rm -f was used. if { test -L "$file"; } >/dev/null 2>&1 || { test -h "$file"; } >/dev/null 2>&1 || test -f "$file"; then : elif test -d "$file"; then exit_status=1 continue elif $rmforce; then continue fi rmfiles=$file case $name in *.la) # Possibly a libtool archive, so verify it. if func_lalib_p "$file"; then func_source $dir/$name # Delete the libtool libraries and symlinks. for n in $library_names; do func_append rmfiles " $odir/$n" done test -n "$old_library" && func_append rmfiles " $odir/$old_library" case $opt_mode in clean) case " $library_names " in *" $dlname "*) ;; *) test -n "$dlname" && func_append rmfiles " $odir/$dlname" ;; esac test -n "$libdir" && func_append rmfiles " $odir/$name $odir/${name}i" ;; uninstall) if test -n "$library_names"; then # Do each command in the postuninstall commands. func_execute_cmds "$postuninstall_cmds" '$rmforce || exit_status=1' fi if test -n "$old_library"; then # Do each command in the old_postuninstall commands. func_execute_cmds "$old_postuninstall_cmds" '$rmforce || exit_status=1' fi # FIXME: should reinstall the best remaining shared library. ;; esac fi ;; *.lo) # Possibly a libtool object, so verify it. if func_lalib_p "$file"; then # Read the .lo file func_source $dir/$name # Add PIC object to the list of files to remove. if test -n "$pic_object" && test none != "$pic_object"; then func_append rmfiles " $dir/$pic_object" fi # Add non-PIC object to the list of files to remove. if test -n "$non_pic_object" && test none != "$non_pic_object"; then func_append rmfiles " $dir/$non_pic_object" fi fi ;; *) if test clean = "$opt_mode"; then noexename=$name case $file in *.exe) func_stripname '' '.exe' "$file" file=$func_stripname_result func_stripname '' '.exe' "$name" noexename=$func_stripname_result # $file with .exe has already been added to rmfiles, # add $file without .exe func_append rmfiles " $file" ;; esac # Do a test to see if this is a libtool program. if func_ltwrapper_p "$file"; then if func_ltwrapper_executable_p "$file"; then func_ltwrapper_scriptname "$file" relink_command= func_source $func_ltwrapper_scriptname_result func_append rmfiles " $func_ltwrapper_scriptname_result" else relink_command= func_source $dir/$noexename fi # note $name still contains .exe if it was in $file originally # as does the version of $file that was added into $rmfiles func_append rmfiles " $odir/$name $odir/${name}S.$objext" if test yes = "$fast_install" && test -n "$relink_command"; then func_append rmfiles " $odir/lt-$name" fi if test "X$noexename" != "X$name"; then func_append rmfiles " $odir/lt-$noexename.c" fi fi fi ;; esac func_show_eval "$RM $rmfiles" 'exit_status=1' done # Try to remove the $objdir's in the directories where we deleted files for dir in $rmdirs; do if test -d "$dir"; then func_show_eval "rmdir $dir >/dev/null 2>&1" fi done exit $exit_status } if test uninstall = "$opt_mode" || test clean = "$opt_mode"; then func_mode_uninstall ${1+"$@"} fi test -z "$opt_mode" && { help=$generic_help func_fatal_help "you must specify a MODE" } test -z "$exec_cmd" && \ func_fatal_help "invalid operation mode '$opt_mode'" if test -n "$exec_cmd"; then eval exec "$exec_cmd" exit $EXIT_FAILURE fi exit $exit_status # The TAGs below are defined such that we never get into a situation # where we disable both kinds of libraries. Given conflicting # choices, we go for a static library, that is the most portable, # since we can't tell whether shared libraries were disabled because # the user asked for that or because the platform doesn't support # them. This is particularly important on AIX, because we don't # support having both static and shared libraries enabled at the same # time on that platform, so we default to a shared-only configuration. # If a disable-shared tag is given, we'll fallback to a static-only # configuration. But we'll never go from static-only to shared-only. # ### BEGIN LIBTOOL TAG CONFIG: disable-shared build_libtool_libs=no build_old_libs=yes # ### END LIBTOOL TAG CONFIG: disable-shared # ### BEGIN LIBTOOL TAG CONFIG: disable-static build_old_libs=`case $build_libtool_libs in yes) echo no;; *) echo yes;; esac` # ### END LIBTOOL TAG CONFIG: disable-static # Local Variables: # mode:shell-script # sh-indentation:2 # End: httrack-3.49.5/install-sh0000755000175000017500000003577614555203165012231 00000000000000#!/bin/sh # install - install a program, script, or datafile scriptversion=2020-11-14.01; # UTC # This originates from X11R5 (mit/util/scripts/install.sh), which was # later released in X11R6 (xc/config/util/install.sh) with the # following copyright and license. # # Copyright (C) 1994 X Consortium # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to # deal in the Software without restriction, including without limitation the # rights to use, copy, modify, merge, publish, distribute, sublicense, and/or # sell copies of the Software, and to permit persons to whom the Software is # furnished to do so, subject to the following conditions: # # The above copyright notice and this permission notice shall be included in # all copies or substantial portions of the Software. # # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE # X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN # AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNEC- # TION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. # # Except as contained in this notice, the name of the X Consortium shall not # be used in advertising or otherwise to promote the sale, use or other deal- # ings in this Software without prior written authorization from the X Consor- # tium. # # # FSF changes to this file are in the public domain. # # Calling this script install-sh is preferred over install.sh, to prevent # 'make' implicit rules from creating a file called install from it # when there is no Makefile. # # This script is compatible with the BSD install script, but was written # from scratch. tab=' ' nl=' ' IFS=" $tab$nl" # Set DOITPROG to "echo" to test this script. doit=${DOITPROG-} doit_exec=${doit:-exec} # Put in absolute file names if you don't have them in your path; # or use environment vars. chgrpprog=${CHGRPPROG-chgrp} chmodprog=${CHMODPROG-chmod} chownprog=${CHOWNPROG-chown} cmpprog=${CMPPROG-cmp} cpprog=${CPPROG-cp} mkdirprog=${MKDIRPROG-mkdir} mvprog=${MVPROG-mv} rmprog=${RMPROG-rm} stripprog=${STRIPPROG-strip} posix_mkdir= # Desired mode of installed file. mode=0755 # Create dirs (including intermediate dirs) using mode 755. # This is like GNU 'install' as of coreutils 8.32 (2020). mkdir_umask=22 backupsuffix= chgrpcmd= chmodcmd=$chmodprog chowncmd= mvcmd=$mvprog rmcmd="$rmprog -f" stripcmd= src= dst= dir_arg= dst_arg= copy_on_change=false is_target_a_directory=possibly usage="\ Usage: $0 [OPTION]... [-T] SRCFILE DSTFILE or: $0 [OPTION]... SRCFILES... DIRECTORY or: $0 [OPTION]... -t DIRECTORY SRCFILES... or: $0 [OPTION]... -d DIRECTORIES... In the 1st form, copy SRCFILE to DSTFILE. In the 2nd and 3rd, copy all SRCFILES to DIRECTORY. In the 4th, create DIRECTORIES. Options: --help display this help and exit. --version display version info and exit. -c (ignored) -C install only if different (preserve data modification time) -d create directories instead of installing files. -g GROUP $chgrpprog installed files to GROUP. -m MODE $chmodprog installed files to MODE. -o USER $chownprog installed files to USER. -p pass -p to $cpprog. -s $stripprog installed files. -S SUFFIX attempt to back up existing files, with suffix SUFFIX. -t DIRECTORY install into DIRECTORY. -T report an error if DSTFILE is a directory. Environment variables override the default commands: CHGRPPROG CHMODPROG CHOWNPROG CMPPROG CPPROG MKDIRPROG MVPROG RMPROG STRIPPROG By default, rm is invoked with -f; when overridden with RMPROG, it's up to you to specify -f if you want it. If -S is not specified, no backups are attempted. Email bug reports to bug-automake@gnu.org. Automake home page: https://www.gnu.org/software/automake/ " while test $# -ne 0; do case $1 in -c) ;; -C) copy_on_change=true;; -d) dir_arg=true;; -g) chgrpcmd="$chgrpprog $2" shift;; --help) echo "$usage"; exit $?;; -m) mode=$2 case $mode in *' '* | *"$tab"* | *"$nl"* | *'*'* | *'?'* | *'['*) echo "$0: invalid mode: $mode" >&2 exit 1;; esac shift;; -o) chowncmd="$chownprog $2" shift;; -p) cpprog="$cpprog -p";; -s) stripcmd=$stripprog;; -S) backupsuffix="$2" shift;; -t) is_target_a_directory=always dst_arg=$2 # Protect names problematic for 'test' and other utilities. case $dst_arg in -* | [=\(\)!]) dst_arg=./$dst_arg;; esac shift;; -T) is_target_a_directory=never;; --version) echo "$0 $scriptversion"; exit $?;; --) shift break;; -*) echo "$0: invalid option: $1" >&2 exit 1;; *) break;; esac shift done # We allow the use of options -d and -T together, by making -d # take the precedence; this is for compatibility with GNU install. if test -n "$dir_arg"; then if test -n "$dst_arg"; then echo "$0: target directory not allowed when installing a directory." >&2 exit 1 fi fi if test $# -ne 0 && test -z "$dir_arg$dst_arg"; then # When -d is used, all remaining arguments are directories to create. # When -t is used, the destination is already specified. # Otherwise, the last argument is the destination. Remove it from $@. for arg do if test -n "$dst_arg"; then # $@ is not empty: it contains at least $arg. set fnord "$@" "$dst_arg" shift # fnord fi shift # arg dst_arg=$arg # Protect names problematic for 'test' and other utilities. case $dst_arg in -* | [=\(\)!]) dst_arg=./$dst_arg;; esac done fi if test $# -eq 0; then if test -z "$dir_arg"; then echo "$0: no input file specified." >&2 exit 1 fi # It's OK to call 'install-sh -d' without argument. # This can happen when creating conditional directories. exit 0 fi if test -z "$dir_arg"; then if test $# -gt 1 || test "$is_target_a_directory" = always; then if test ! -d "$dst_arg"; then echo "$0: $dst_arg: Is not a directory." >&2 exit 1 fi fi fi if test -z "$dir_arg"; then do_exit='(exit $ret); exit $ret' trap "ret=129; $do_exit" 1 trap "ret=130; $do_exit" 2 trap "ret=141; $do_exit" 13 trap "ret=143; $do_exit" 15 # Set umask so as not to create temps with too-generous modes. # However, 'strip' requires both read and write access to temps. case $mode in # Optimize common cases. *644) cp_umask=133;; *755) cp_umask=22;; *[0-7]) if test -z "$stripcmd"; then u_plus_rw= else u_plus_rw='% 200' fi cp_umask=`expr '(' 777 - $mode % 1000 ')' $u_plus_rw`;; *) if test -z "$stripcmd"; then u_plus_rw= else u_plus_rw=,u+rw fi cp_umask=$mode$u_plus_rw;; esac fi for src do # Protect names problematic for 'test' and other utilities. case $src in -* | [=\(\)!]) src=./$src;; esac if test -n "$dir_arg"; then dst=$src dstdir=$dst test -d "$dstdir" dstdir_status=$? # Don't chown directories that already exist. if test $dstdir_status = 0; then chowncmd="" fi else # Waiting for this to be detected by the "$cpprog $src $dsttmp" command # might cause directories to be created, which would be especially bad # if $src (and thus $dsttmp) contains '*'. if test ! -f "$src" && test ! -d "$src"; then echo "$0: $src does not exist." >&2 exit 1 fi if test -z "$dst_arg"; then echo "$0: no destination specified." >&2 exit 1 fi dst=$dst_arg # If destination is a directory, append the input filename. if test -d "$dst"; then if test "$is_target_a_directory" = never; then echo "$0: $dst_arg: Is a directory" >&2 exit 1 fi dstdir=$dst dstbase=`basename "$src"` case $dst in */) dst=$dst$dstbase;; *) dst=$dst/$dstbase;; esac dstdir_status=0 else dstdir=`dirname "$dst"` test -d "$dstdir" dstdir_status=$? fi fi case $dstdir in */) dstdirslash=$dstdir;; *) dstdirslash=$dstdir/;; esac obsolete_mkdir_used=false if test $dstdir_status != 0; then case $posix_mkdir in '') # With -d, create the new directory with the user-specified mode. # Otherwise, rely on $mkdir_umask. if test -n "$dir_arg"; then mkdir_mode=-m$mode else mkdir_mode= fi posix_mkdir=false # The $RANDOM variable is not portable (e.g., dash). Use it # here however when possible just to lower collision chance. tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$ trap ' ret=$? rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir" 2>/dev/null exit $ret ' 0 # Because "mkdir -p" follows existing symlinks and we likely work # directly in world-writeable /tmp, make sure that the '$tmpdir' # directory is successfully created first before we actually test # 'mkdir -p'. if (umask $mkdir_umask && $mkdirprog $mkdir_mode "$tmpdir" && exec $mkdirprog $mkdir_mode -p -- "$tmpdir/a/b") >/dev/null 2>&1 then if test -z "$dir_arg" || { # Check for POSIX incompatibilities with -m. # HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or # other-writable bit of parent directory when it shouldn't. # FreeBSD 6.1 mkdir -m -p sets mode of existing directory. test_tmpdir="$tmpdir/a" ls_ld_tmpdir=`ls -ld "$test_tmpdir"` case $ls_ld_tmpdir in d????-?r-*) different_mode=700;; d????-?--*) different_mode=755;; *) false;; esac && $mkdirprog -m$different_mode -p -- "$test_tmpdir" && { ls_ld_tmpdir_1=`ls -ld "$test_tmpdir"` test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1" } } then posix_mkdir=: fi rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir" else # Remove any dirs left behind by ancient mkdir implementations. rmdir ./$mkdir_mode ./-p ./-- "$tmpdir" 2>/dev/null fi trap '' 0;; esac if $posix_mkdir && ( umask $mkdir_umask && $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir" ) then : else # mkdir does not conform to POSIX, # or it failed possibly due to a race condition. Create the # directory the slow way, step by step, checking for races as we go. case $dstdir in /*) prefix='/';; [-=\(\)!]*) prefix='./';; *) prefix='';; esac oIFS=$IFS IFS=/ set -f set fnord $dstdir shift set +f IFS=$oIFS prefixes= for d do test X"$d" = X && continue prefix=$prefix$d if test -d "$prefix"; then prefixes= else if $posix_mkdir; then (umask $mkdir_umask && $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir") && break # Don't fail if two instances are running concurrently. test -d "$prefix" || exit 1 else case $prefix in *\'*) qprefix=`echo "$prefix" | sed "s/'/'\\\\\\\\''/g"`;; *) qprefix=$prefix;; esac prefixes="$prefixes '$qprefix'" fi fi prefix=$prefix/ done if test -n "$prefixes"; then # Don't fail if two instances are running concurrently. (umask $mkdir_umask && eval "\$doit_exec \$mkdirprog $prefixes") || test -d "$dstdir" || exit 1 obsolete_mkdir_used=true fi fi fi if test -n "$dir_arg"; then { test -z "$chowncmd" || $doit $chowncmd "$dst"; } && { test -z "$chgrpcmd" || $doit $chgrpcmd "$dst"; } && { test "$obsolete_mkdir_used$chowncmd$chgrpcmd" = false || test -z "$chmodcmd" || $doit $chmodcmd $mode "$dst"; } || exit 1 else # Make a couple of temp file names in the proper directory. dsttmp=${dstdirslash}_inst.$$_ rmtmp=${dstdirslash}_rm.$$_ # Trap to clean up those temp files at exit. trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0 # Copy the file name to the temp name. (umask $cp_umask && { test -z "$stripcmd" || { # Create $dsttmp read-write so that cp doesn't create it read-only, # which would cause strip to fail. if test -z "$doit"; then : >"$dsttmp" # No need to fork-exec 'touch'. else $doit touch "$dsttmp" fi } } && $doit_exec $cpprog "$src" "$dsttmp") && # and set any options; do chmod last to preserve setuid bits. # # If any of these fail, we abort the whole thing. If we want to # ignore errors from any of these, just make sure not to ignore # errors from the above "$doit $cpprog $src $dsttmp" command. # { test -z "$chowncmd" || $doit $chowncmd "$dsttmp"; } && { test -z "$chgrpcmd" || $doit $chgrpcmd "$dsttmp"; } && { test -z "$stripcmd" || $doit $stripcmd "$dsttmp"; } && { test -z "$chmodcmd" || $doit $chmodcmd $mode "$dsttmp"; } && # If -C, don't bother to copy if it wouldn't change the file. if $copy_on_change && old=`LC_ALL=C ls -dlL "$dst" 2>/dev/null` && new=`LC_ALL=C ls -dlL "$dsttmp" 2>/dev/null` && set -f && set X $old && old=:$2:$4:$5:$6 && set X $new && new=:$2:$4:$5:$6 && set +f && test "$old" = "$new" && $cmpprog "$dst" "$dsttmp" >/dev/null 2>&1 then rm -f "$dsttmp" else # If $backupsuffix is set, and the file being installed # already exists, attempt a backup. Don't worry if it fails, # e.g., if mv doesn't support -f. if test -n "$backupsuffix" && test -f "$dst"; then $doit $mvcmd -f "$dst" "$dst$backupsuffix" 2>/dev/null fi # Rename the file to the real destination. $doit $mvcmd -f "$dsttmp" "$dst" 2>/dev/null || # The rename failed, perhaps because mv can't rename something else # to itself, or perhaps because mv is so ancient that it does not # support -f. { # Now remove or move aside any old file at destination location. # We try this two ways since rm can't unlink itself on some # systems and the destination file might be busy for other # reasons. In this case, the final cleanup might fail but the new # file should still install successfully. { test ! -f "$dst" || $doit $rmcmd "$dst" 2>/dev/null || { $doit $mvcmd -f "$dst" "$rmtmp" 2>/dev/null && { $doit $rmcmd "$rmtmp" 2>/dev/null; :; } } || { echo "$0: cannot unlink or rename $dst" >&2 (exit 1); exit 1 } } && # Now rename the file to the real destination. $doit $mvcmd "$dsttmp" "$dst" } fi || exit 1 trap '' 0 fi done # Local variables: # eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" # time-stamp-end: "; # UTC" # End: httrack-3.49.5/depcomp0000755000175000017500000005602014555203165011563 00000000000000#! /bin/sh # depcomp - compile a program generating dependencies as side-effects scriptversion=2018-03-07.03; # UTC # Copyright (C) 1999-2021 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2, or (at your option) # any later version. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # You should have received a copy of the GNU General Public License # along with this program. If not, see . # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. # Originally written by Alexandre Oliva . case $1 in '') echo "$0: No command. Try '$0 --help' for more information." 1>&2 exit 1; ;; -h | --h*) cat <<\EOF Usage: depcomp [--help] [--version] PROGRAM [ARGS] Run PROGRAMS ARGS to compile a file, generating dependencies as side-effects. Environment variables: depmode Dependency tracking mode. source Source file read by 'PROGRAMS ARGS'. object Object file output by 'PROGRAMS ARGS'. DEPDIR directory where to store dependencies. depfile Dependency file to output. tmpdepfile Temporary file to use when outputting dependencies. libtool Whether libtool is used (yes/no). Report bugs to . EOF exit $? ;; -v | --v*) echo "depcomp $scriptversion" exit $? ;; esac # Get the directory component of the given path, and save it in the # global variables '$dir'. Note that this directory component will # be either empty or ending with a '/' character. This is deliberate. set_dir_from () { case $1 in */*) dir=`echo "$1" | sed -e 's|/[^/]*$|/|'`;; *) dir=;; esac } # Get the suffix-stripped basename of the given path, and save it the # global variable '$base'. set_base_from () { base=`echo "$1" | sed -e 's|^.*/||' -e 's/\.[^.]*$//'` } # If no dependency file was actually created by the compiler invocation, # we still have to create a dummy depfile, to avoid errors with the # Makefile "include basename.Plo" scheme. make_dummy_depfile () { echo "#dummy" > "$depfile" } # Factor out some common post-processing of the generated depfile. # Requires the auxiliary global variable '$tmpdepfile' to be set. aix_post_process_depfile () { # If the compiler actually managed to produce a dependency file, # post-process it. if test -f "$tmpdepfile"; then # Each line is of the form 'foo.o: dependency.h'. # Do two passes, one to just change these to # $object: dependency.h # and one to simply output # dependency.h: # which is needed to avoid the deleted-header problem. { sed -e "s,^.*\.[$lower]*:,$object:," < "$tmpdepfile" sed -e "s,^.*\.[$lower]*:[$tab ]*,," -e 's,$,:,' < "$tmpdepfile" } > "$depfile" rm -f "$tmpdepfile" else make_dummy_depfile fi } # A tabulation character. tab=' ' # A newline character. nl=' ' # Character ranges might be problematic outside the C locale. # These definitions help. upper=ABCDEFGHIJKLMNOPQRSTUVWXYZ lower=abcdefghijklmnopqrstuvwxyz digits=0123456789 alpha=${upper}${lower} if test -z "$depmode" || test -z "$source" || test -z "$object"; then echo "depcomp: Variables source, object and depmode must be set" 1>&2 exit 1 fi # Dependencies for sub/bar.o or sub/bar.obj go into sub/.deps/bar.Po. depfile=${depfile-`echo "$object" | sed 's|[^\\/]*$|'${DEPDIR-.deps}'/&|;s|\.\([^.]*\)$|.P\1|;s|Pobj$|Po|'`} tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`} rm -f "$tmpdepfile" # Avoid interferences from the environment. gccflag= dashmflag= # Some modes work just like other modes, but use different flags. We # parameterize here, but still list the modes in the big case below, # to make depend.m4 easier to write. Note that we *cannot* use a case # here, because this file can only contain one case statement. if test "$depmode" = hp; then # HP compiler uses -M and no extra arg. gccflag=-M depmode=gcc fi if test "$depmode" = dashXmstdout; then # This is just like dashmstdout with a different argument. dashmflag=-xM depmode=dashmstdout fi cygpath_u="cygpath -u -f -" if test "$depmode" = msvcmsys; then # This is just like msvisualcpp but w/o cygpath translation. # Just convert the backslash-escaped backslashes to single forward # slashes to satisfy depend.m4 cygpath_u='sed s,\\\\,/,g' depmode=msvisualcpp fi if test "$depmode" = msvc7msys; then # This is just like msvc7 but w/o cygpath translation. # Just convert the backslash-escaped backslashes to single forward # slashes to satisfy depend.m4 cygpath_u='sed s,\\\\,/,g' depmode=msvc7 fi if test "$depmode" = xlc; then # IBM C/C++ Compilers xlc/xlC can output gcc-like dependency information. gccflag=-qmakedep=gcc,-MF depmode=gcc fi case "$depmode" in gcc3) ## gcc 3 implements dependency tracking that does exactly what ## we want. Yay! Note: for some reason libtool 1.4 doesn't like ## it if -MD -MP comes after the -MF stuff. Hmm. ## Unfortunately, FreeBSD c89 acceptance of flags depends upon ## the command line argument order; so add the flags where they ## appear in depend2.am. Note that the slowdown incurred here ## affects only configure: in makefiles, %FASTDEP% shortcuts this. for arg do case $arg in -c) set fnord "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" "$arg" ;; *) set fnord "$@" "$arg" ;; esac shift # fnord shift # $arg done "$@" stat=$? if test $stat -ne 0; then rm -f "$tmpdepfile" exit $stat fi mv "$tmpdepfile" "$depfile" ;; gcc) ## Note that this doesn't just cater to obsosete pre-3.x GCC compilers. ## but also to in-use compilers like IMB xlc/xlC and the HP C compiler. ## (see the conditional assignment to $gccflag above). ## There are various ways to get dependency output from gcc. Here's ## why we pick this rather obscure method: ## - Don't want to use -MD because we'd like the dependencies to end ## up in a subdir. Having to rename by hand is ugly. ## (We might end up doing this anyway to support other compilers.) ## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like ## -MM, not -M (despite what the docs say). Also, it might not be ## supported by the other compilers which use the 'gcc' depmode. ## - Using -M directly means running the compiler twice (even worse ## than renaming). if test -z "$gccflag"; then gccflag=-MD, fi "$@" -Wp,"$gccflag$tmpdepfile" stat=$? if test $stat -ne 0; then rm -f "$tmpdepfile" exit $stat fi rm -f "$depfile" echo "$object : \\" > "$depfile" # The second -e expression handles DOS-style file names with drive # letters. sed -e 's/^[^:]*: / /' \ -e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile" ## This next piece of magic avoids the "deleted header file" problem. ## The problem is that when a header file which appears in a .P file ## is deleted, the dependency causes make to die (because there is ## typically no way to rebuild the header). We avoid this by adding ## dummy dependencies for each header file. Too bad gcc doesn't do ## this for us directly. ## Some versions of gcc put a space before the ':'. On the theory ## that the space means something, we add a space to the output as ## well. hp depmode also adds that space, but also prefixes the VPATH ## to the object. Take care to not repeat it in the output. ## Some versions of the HPUX 10.20 sed can't process this invocation ## correctly. Breaking it into two sed invocations is a workaround. tr ' ' "$nl" < "$tmpdepfile" \ | sed -e 's/^\\$//' -e '/^$/d' -e "s|.*$object$||" -e '/:$/d' \ | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; hp) # This case exists only to let depend.m4 do its work. It works by # looking at the text of this script. This case will never be run, # since it is checked for above. exit 1 ;; sgi) if test "$libtool" = yes; then "$@" "-Wp,-MDupdate,$tmpdepfile" else "$@" -MDupdate "$tmpdepfile" fi stat=$? if test $stat -ne 0; then rm -f "$tmpdepfile" exit $stat fi rm -f "$depfile" if test -f "$tmpdepfile"; then # yes, the sourcefile depend on other files echo "$object : \\" > "$depfile" # Clip off the initial element (the dependent). Don't try to be # clever and replace this with sed code, as IRIX sed won't handle # lines with more than a fixed number of characters (4096 in # IRIX 6.2 sed, 8192 in IRIX 6.5). We also remove comment lines; # the IRIX cc adds comments like '#:fec' to the end of the # dependency line. tr ' ' "$nl" < "$tmpdepfile" \ | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' \ | tr "$nl" ' ' >> "$depfile" echo >> "$depfile" # The second pass generates a dummy entry for each header file. tr ' ' "$nl" < "$tmpdepfile" \ | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \ >> "$depfile" else make_dummy_depfile fi rm -f "$tmpdepfile" ;; xlc) # This case exists only to let depend.m4 do its work. It works by # looking at the text of this script. This case will never be run, # since it is checked for above. exit 1 ;; aix) # The C for AIX Compiler uses -M and outputs the dependencies # in a .u file. In older versions, this file always lives in the # current directory. Also, the AIX compiler puts '$object:' at the # start of each line; $object doesn't have directory information. # Version 6 uses the directory in both cases. set_dir_from "$object" set_base_from "$object" if test "$libtool" = yes; then tmpdepfile1=$dir$base.u tmpdepfile2=$base.u tmpdepfile3=$dir.libs/$base.u "$@" -Wc,-M else tmpdepfile1=$dir$base.u tmpdepfile2=$dir$base.u tmpdepfile3=$dir$base.u "$@" -M fi stat=$? if test $stat -ne 0; then rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" exit $stat fi for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" do test -f "$tmpdepfile" && break done aix_post_process_depfile ;; tcc) # tcc (Tiny C Compiler) understand '-MD -MF file' since version 0.9.26 # FIXME: That version still under development at the moment of writing. # Make that this statement remains true also for stable, released # versions. # It will wrap lines (doesn't matter whether long or short) with a # trailing '\', as in: # # foo.o : \ # foo.c \ # foo.h \ # # It will put a trailing '\' even on the last line, and will use leading # spaces rather than leading tabs (at least since its commit 0394caf7 # "Emit spaces for -MD"). "$@" -MD -MF "$tmpdepfile" stat=$? if test $stat -ne 0; then rm -f "$tmpdepfile" exit $stat fi rm -f "$depfile" # Each non-empty line is of the form 'foo.o : \' or ' dep.h \'. # We have to change lines of the first kind to '$object: \'. sed -e "s|.*:|$object :|" < "$tmpdepfile" > "$depfile" # And for each line of the second kind, we have to emit a 'dep.h:' # dummy dependency, to avoid the deleted-header problem. sed -n -e 's|^ *\(.*\) *\\$|\1:|p' < "$tmpdepfile" >> "$depfile" rm -f "$tmpdepfile" ;; ## The order of this option in the case statement is important, since the ## shell code in configure will try each of these formats in the order ## listed in this file. A plain '-MD' option would be understood by many ## compilers, so we must ensure this comes after the gcc and icc options. pgcc) # Portland's C compiler understands '-MD'. # Will always output deps to 'file.d' where file is the root name of the # source file under compilation, even if file resides in a subdirectory. # The object file name does not affect the name of the '.d' file. # pgcc 10.2 will output # foo.o: sub/foo.c sub/foo.h # and will wrap long lines using '\' : # foo.o: sub/foo.c ... \ # sub/foo.h ... \ # ... set_dir_from "$object" # Use the source, not the object, to determine the base name, since # that's sadly what pgcc will do too. set_base_from "$source" tmpdepfile=$base.d # For projects that build the same source file twice into different object # files, the pgcc approach of using the *source* file root name can cause # problems in parallel builds. Use a locking strategy to avoid stomping on # the same $tmpdepfile. lockdir=$base.d-lock trap " echo '$0: caught signal, cleaning up...' >&2 rmdir '$lockdir' exit 1 " 1 2 13 15 numtries=100 i=$numtries while test $i -gt 0; do # mkdir is a portable test-and-set. if mkdir "$lockdir" 2>/dev/null; then # This process acquired the lock. "$@" -MD stat=$? # Release the lock. rmdir "$lockdir" break else # If the lock is being held by a different process, wait # until the winning process is done or we timeout. while test -d "$lockdir" && test $i -gt 0; do sleep 1 i=`expr $i - 1` done fi i=`expr $i - 1` done trap - 1 2 13 15 if test $i -le 0; then echo "$0: failed to acquire lock after $numtries attempts" >&2 echo "$0: check lockdir '$lockdir'" >&2 exit 1 fi if test $stat -ne 0; then rm -f "$tmpdepfile" exit $stat fi rm -f "$depfile" # Each line is of the form `foo.o: dependent.h', # or `foo.o: dep1.h dep2.h \', or ` dep3.h dep4.h \'. # Do two passes, one to just change these to # `$object: dependent.h' and one to simply `dependent.h:'. sed "s,^[^:]*:,$object :," < "$tmpdepfile" > "$depfile" # Some versions of the HPUX 10.20 sed can't process this invocation # correctly. Breaking it into two sed invocations is a workaround. sed 's,^[^:]*: \(.*\)$,\1,;s/^\\$//;/^$/d;/:$/d' < "$tmpdepfile" \ | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; hp2) # The "hp" stanza above does not work with aCC (C++) and HP's ia64 # compilers, which have integrated preprocessors. The correct option # to use with these is +Maked; it writes dependencies to a file named # 'foo.d', which lands next to the object file, wherever that # happens to be. # Much of this is similar to the tru64 case; see comments there. set_dir_from "$object" set_base_from "$object" if test "$libtool" = yes; then tmpdepfile1=$dir$base.d tmpdepfile2=$dir.libs/$base.d "$@" -Wc,+Maked else tmpdepfile1=$dir$base.d tmpdepfile2=$dir$base.d "$@" +Maked fi stat=$? if test $stat -ne 0; then rm -f "$tmpdepfile1" "$tmpdepfile2" exit $stat fi for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" do test -f "$tmpdepfile" && break done if test -f "$tmpdepfile"; then sed -e "s,^.*\.[$lower]*:,$object:," "$tmpdepfile" > "$depfile" # Add 'dependent.h:' lines. sed -ne '2,${ s/^ *// s/ \\*$// s/$/:/ p }' "$tmpdepfile" >> "$depfile" else make_dummy_depfile fi rm -f "$tmpdepfile" "$tmpdepfile2" ;; tru64) # The Tru64 compiler uses -MD to generate dependencies as a side # effect. 'cc -MD -o foo.o ...' puts the dependencies into 'foo.o.d'. # At least on Alpha/Redhat 6.1, Compaq CCC V6.2-504 seems to put # dependencies in 'foo.d' instead, so we check for that too. # Subdirectories are respected. set_dir_from "$object" set_base_from "$object" if test "$libtool" = yes; then # Libtool generates 2 separate objects for the 2 libraries. These # two compilations output dependencies in $dir.libs/$base.o.d and # in $dir$base.o.d. We have to check for both files, because # one of the two compilations can be disabled. We should prefer # $dir$base.o.d over $dir.libs/$base.o.d because the latter is # automatically cleaned when .libs/ is deleted, while ignoring # the former would cause a distcleancheck panic. tmpdepfile1=$dir$base.o.d # libtool 1.5 tmpdepfile2=$dir.libs/$base.o.d # Likewise. tmpdepfile3=$dir.libs/$base.d # Compaq CCC V6.2-504 "$@" -Wc,-MD else tmpdepfile1=$dir$base.d tmpdepfile2=$dir$base.d tmpdepfile3=$dir$base.d "$@" -MD fi stat=$? if test $stat -ne 0; then rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" exit $stat fi for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" do test -f "$tmpdepfile" && break done # Same post-processing that is required for AIX mode. aix_post_process_depfile ;; msvc7) if test "$libtool" = yes; then showIncludes=-Wc,-showIncludes else showIncludes=-showIncludes fi "$@" $showIncludes > "$tmpdepfile" stat=$? grep -v '^Note: including file: ' "$tmpdepfile" if test $stat -ne 0; then rm -f "$tmpdepfile" exit $stat fi rm -f "$depfile" echo "$object : \\" > "$depfile" # The first sed program below extracts the file names and escapes # backslashes for cygpath. The second sed program outputs the file # name when reading, but also accumulates all include files in the # hold buffer in order to output them again at the end. This only # works with sed implementations that can handle large buffers. sed < "$tmpdepfile" -n ' /^Note: including file: *\(.*\)/ { s//\1/ s/\\/\\\\/g p }' | $cygpath_u | sort -u | sed -n ' s/ /\\ /g s/\(.*\)/'"$tab"'\1 \\/p s/.\(.*\) \\/\1:/ H $ { s/.*/'"$tab"'/ G p }' >> "$depfile" echo >> "$depfile" # make sure the fragment doesn't end with a backslash rm -f "$tmpdepfile" ;; msvc7msys) # This case exists only to let depend.m4 do its work. It works by # looking at the text of this script. This case will never be run, # since it is checked for above. exit 1 ;; #nosideeffect) # This comment above is used by automake to tell side-effect # dependency tracking mechanisms from slower ones. dashmstdout) # Important note: in order to support this mode, a compiler *must* # always write the preprocessed file to stdout, regardless of -o. "$@" || exit $? # Remove the call to Libtool. if test "$libtool" = yes; then while test "X$1" != 'X--mode=compile'; do shift done shift fi # Remove '-o $object'. IFS=" " for arg do case $arg in -o) shift ;; $object) shift ;; *) set fnord "$@" "$arg" shift # fnord shift # $arg ;; esac done test -z "$dashmflag" && dashmflag=-M # Require at least two characters before searching for ':' # in the target name. This is to cope with DOS-style filenames: # a dependency such as 'c:/foo/bar' could be seen as target 'c' otherwise. "$@" $dashmflag | sed "s|^[$tab ]*[^:$tab ][^:][^:]*:[$tab ]*|$object: |" > "$tmpdepfile" rm -f "$depfile" cat < "$tmpdepfile" > "$depfile" # Some versions of the HPUX 10.20 sed can't process this sed invocation # correctly. Breaking it into two sed invocations is a workaround. tr ' ' "$nl" < "$tmpdepfile" \ | sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' \ | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; dashXmstdout) # This case only exists to satisfy depend.m4. It is never actually # run, as this mode is specially recognized in the preamble. exit 1 ;; makedepend) "$@" || exit $? # Remove any Libtool call if test "$libtool" = yes; then while test "X$1" != 'X--mode=compile'; do shift done shift fi # X makedepend shift cleared=no eat=no for arg do case $cleared in no) set ""; shift cleared=yes ;; esac if test $eat = yes; then eat=no continue fi case "$arg" in -D*|-I*) set fnord "$@" "$arg"; shift ;; # Strip any option that makedepend may not understand. Remove # the object too, otherwise makedepend will parse it as a source file. -arch) eat=yes ;; -*|$object) ;; *) set fnord "$@" "$arg"; shift ;; esac done obj_suffix=`echo "$object" | sed 's/^.*\././'` touch "$tmpdepfile" ${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@" rm -f "$depfile" # makedepend may prepend the VPATH from the source file name to the object. # No need to regex-escape $object, excess matching of '.' is harmless. sed "s|^.*\($object *:\)|\1|" "$tmpdepfile" > "$depfile" # Some versions of the HPUX 10.20 sed can't process the last invocation # correctly. Breaking it into two sed invocations is a workaround. sed '1,2d' "$tmpdepfile" \ | tr ' ' "$nl" \ | sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' \ | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" "$tmpdepfile".bak ;; cpp) # Important note: in order to support this mode, a compiler *must* # always write the preprocessed file to stdout. "$@" || exit $? # Remove the call to Libtool. if test "$libtool" = yes; then while test "X$1" != 'X--mode=compile'; do shift done shift fi # Remove '-o $object'. IFS=" " for arg do case $arg in -o) shift ;; $object) shift ;; *) set fnord "$@" "$arg" shift # fnord shift # $arg ;; esac done "$@" -E \ | sed -n -e '/^# [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \ -e '/^#line [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \ | sed '$ s: \\$::' > "$tmpdepfile" rm -f "$depfile" echo "$object : \\" > "$depfile" cat < "$tmpdepfile" >> "$depfile" sed < "$tmpdepfile" '/^$/d;s/^ //;s/ \\$//;s/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; msvisualcpp) # Important note: in order to support this mode, a compiler *must* # always write the preprocessed file to stdout. "$@" || exit $? # Remove the call to Libtool. if test "$libtool" = yes; then while test "X$1" != 'X--mode=compile'; do shift done shift fi IFS=" " for arg do case "$arg" in -o) shift ;; $object) shift ;; "-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI") set fnord "$@" shift shift ;; *) set fnord "$@" "$arg" shift shift ;; esac done "$@" -E 2>/dev/null | sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::\1:p' | $cygpath_u | sort -u > "$tmpdepfile" rm -f "$depfile" echo "$object : \\" > "$depfile" sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::'"$tab"'\1 \\:p' >> "$depfile" echo "$tab" >> "$depfile" sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::\1\::p' >> "$depfile" rm -f "$tmpdepfile" ;; msvcmsys) # This case exists only to let depend.m4 do its work. It works by # looking at the text of this script. This case will never be run, # since it is checked for above. exit 1 ;; none) exec "$@" ;; *) echo "Unknown depmode $depmode" 1>&2 exit 1 ;; esac exit 0 # Local Variables: # mode: shell-script # sh-indentation: 2 # eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" # time-stamp-end: "; # UTC" # End: httrack-3.49.5/config.sub0000755000175000017500000010511614555203165012172 00000000000000#! /bin/sh # Configuration validation subroutine script. # Copyright 1992-2022 Free Software Foundation, Inc. # shellcheck disable=SC2006,SC2268 # see below for rationale timestamp='2022-01-03' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, see . # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that # program. This Exception is an additional permission under section 7 # of the GNU General Public License, version 3 ("GPLv3"). # Please send patches to . # # Configuration subroutine to validate and canonicalize a configuration type. # Supply the specified configuration type as an argument. # If it is invalid, we print an error message on stderr and exit with code 1. # Otherwise, we print the canonical config type on stdout and succeed. # You can get the latest version of this script from: # https://git.savannah.gnu.org/cgit/config.git/plain/config.sub # This file is supposed to be the same for all GNU packages # and recognize all the CPU types, system types and aliases # that are meaningful with *any* GNU software. # Each package is responsible for reporting which valid configurations # it does not support. The user should be able to distinguish # a failure to support a valid configuration from a meaningless # configuration. # The goal of this file is to map all the various variations of a given # machine specification into a single specification in the form: # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM # or in some cases, the newer four-part form: # CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM # It is wrong to echo any other type of specification. # The "shellcheck disable" line above the timestamp inhibits complaints # about features and limitations of the classic Bourne shell that were # superseded or lifted in POSIX. However, this script identifies a wide # variety of pre-POSIX systems that do not have POSIX shells at all, and # even some reasonably current systems (Solaris 10 as case-in-point) still # have a pre-POSIX /bin/sh. me=`echo "$0" | sed -e 's,.*/,,'` usage="\ Usage: $0 [OPTION] CPU-MFR-OPSYS or ALIAS Canonicalize a configuration name. Options: -h, --help print this help, then exit -t, --time-stamp print date of last modification, then exit -v, --version print version number, then exit Report bugs and patches to ." version="\ GNU config.sub ($timestamp) Copyright 1992-2022 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." help=" Try \`$me --help' for more information." # Parse command line while test $# -gt 0 ; do case $1 in --time-stamp | --time* | -t ) echo "$timestamp" ; exit ;; --version | -v ) echo "$version" ; exit ;; --help | --h* | -h ) echo "$usage"; exit ;; -- ) # Stop option processing shift; break ;; - ) # Use stdin as input. break ;; -* ) echo "$me: invalid option $1$help" >&2 exit 1 ;; *local*) # First pass through any local machine types. echo "$1" exit ;; * ) break ;; esac done case $# in 0) echo "$me: missing argument$help" >&2 exit 1;; 1) ;; *) echo "$me: too many arguments$help" >&2 exit 1;; esac # Split fields of configuration type # shellcheck disable=SC2162 saved_IFS=$IFS IFS="-" read field1 field2 field3 field4 <&2 exit 1 ;; *-*-*-*) basic_machine=$field1-$field2 basic_os=$field3-$field4 ;; *-*-*) # Ambiguous whether COMPANY is present, or skipped and KERNEL-OS is two # parts maybe_os=$field2-$field3 case $maybe_os in nto-qnx* | linux-* | uclinux-uclibc* \ | uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* \ | netbsd*-eabi* | kopensolaris*-gnu* | cloudabi*-eabi* \ | storm-chaos* | os2-emx* | rtmk-nova*) basic_machine=$field1 basic_os=$maybe_os ;; android-linux) basic_machine=$field1-unknown basic_os=linux-android ;; *) basic_machine=$field1-$field2 basic_os=$field3 ;; esac ;; *-*) # A lone config we happen to match not fitting any pattern case $field1-$field2 in decstation-3100) basic_machine=mips-dec basic_os= ;; *-*) # Second component is usually, but not always the OS case $field2 in # Prevent following clause from handling this valid os sun*os*) basic_machine=$field1 basic_os=$field2 ;; zephyr*) basic_machine=$field1-unknown basic_os=$field2 ;; # Manufacturers dec* | mips* | sequent* | encore* | pc533* | sgi* | sony* \ | att* | 7300* | 3300* | delta* | motorola* | sun[234]* \ | unicom* | ibm* | next | hp | isi* | apollo | altos* \ | convergent* | ncr* | news | 32* | 3600* | 3100* \ | hitachi* | c[123]* | convex* | sun | crds | omron* | dg \ | ultra | tti* | harris | dolphin | highlevel | gould \ | cbm | ns | masscomp | apple | axis | knuth | cray \ | microblaze* | sim | cisco \ | oki | wec | wrs | winbond) basic_machine=$field1-$field2 basic_os= ;; *) basic_machine=$field1 basic_os=$field2 ;; esac ;; esac ;; *) # Convert single-component short-hands not valid as part of # multi-component configurations. case $field1 in 386bsd) basic_machine=i386-pc basic_os=bsd ;; a29khif) basic_machine=a29k-amd basic_os=udi ;; adobe68k) basic_machine=m68010-adobe basic_os=scout ;; alliant) basic_machine=fx80-alliant basic_os= ;; altos | altos3068) basic_machine=m68k-altos basic_os= ;; am29k) basic_machine=a29k-none basic_os=bsd ;; amdahl) basic_machine=580-amdahl basic_os=sysv ;; amiga) basic_machine=m68k-unknown basic_os= ;; amigaos | amigados) basic_machine=m68k-unknown basic_os=amigaos ;; amigaunix | amix) basic_machine=m68k-unknown basic_os=sysv4 ;; apollo68) basic_machine=m68k-apollo basic_os=sysv ;; apollo68bsd) basic_machine=m68k-apollo basic_os=bsd ;; aros) basic_machine=i386-pc basic_os=aros ;; aux) basic_machine=m68k-apple basic_os=aux ;; balance) basic_machine=ns32k-sequent basic_os=dynix ;; blackfin) basic_machine=bfin-unknown basic_os=linux ;; cegcc) basic_machine=arm-unknown basic_os=cegcc ;; convex-c1) basic_machine=c1-convex basic_os=bsd ;; convex-c2) basic_machine=c2-convex basic_os=bsd ;; convex-c32) basic_machine=c32-convex basic_os=bsd ;; convex-c34) basic_machine=c34-convex basic_os=bsd ;; convex-c38) basic_machine=c38-convex basic_os=bsd ;; cray) basic_machine=j90-cray basic_os=unicos ;; crds | unos) basic_machine=m68k-crds basic_os= ;; da30) basic_machine=m68k-da30 basic_os= ;; decstation | pmax | pmin | dec3100 | decstatn) basic_machine=mips-dec basic_os= ;; delta88) basic_machine=m88k-motorola basic_os=sysv3 ;; dicos) basic_machine=i686-pc basic_os=dicos ;; djgpp) basic_machine=i586-pc basic_os=msdosdjgpp ;; ebmon29k) basic_machine=a29k-amd basic_os=ebmon ;; es1800 | OSE68k | ose68k | ose | OSE) basic_machine=m68k-ericsson basic_os=ose ;; gmicro) basic_machine=tron-gmicro basic_os=sysv ;; go32) basic_machine=i386-pc basic_os=go32 ;; h8300hms) basic_machine=h8300-hitachi basic_os=hms ;; h8300xray) basic_machine=h8300-hitachi basic_os=xray ;; h8500hms) basic_machine=h8500-hitachi basic_os=hms ;; harris) basic_machine=m88k-harris basic_os=sysv3 ;; hp300 | hp300hpux) basic_machine=m68k-hp basic_os=hpux ;; hp300bsd) basic_machine=m68k-hp basic_os=bsd ;; hppaosf) basic_machine=hppa1.1-hp basic_os=osf ;; hppro) basic_machine=hppa1.1-hp basic_os=proelf ;; i386mach) basic_machine=i386-mach basic_os=mach ;; isi68 | isi) basic_machine=m68k-isi basic_os=sysv ;; m68knommu) basic_machine=m68k-unknown basic_os=linux ;; magnum | m3230) basic_machine=mips-mips basic_os=sysv ;; merlin) basic_machine=ns32k-utek basic_os=sysv ;; mingw64) basic_machine=x86_64-pc basic_os=mingw64 ;; mingw32) basic_machine=i686-pc basic_os=mingw32 ;; mingw32ce) basic_machine=arm-unknown basic_os=mingw32ce ;; monitor) basic_machine=m68k-rom68k basic_os=coff ;; morphos) basic_machine=powerpc-unknown basic_os=morphos ;; moxiebox) basic_machine=moxie-unknown basic_os=moxiebox ;; msdos) basic_machine=i386-pc basic_os=msdos ;; msys) basic_machine=i686-pc basic_os=msys ;; mvs) basic_machine=i370-ibm basic_os=mvs ;; nacl) basic_machine=le32-unknown basic_os=nacl ;; ncr3000) basic_machine=i486-ncr basic_os=sysv4 ;; netbsd386) basic_machine=i386-pc basic_os=netbsd ;; netwinder) basic_machine=armv4l-rebel basic_os=linux ;; news | news700 | news800 | news900) basic_machine=m68k-sony basic_os=newsos ;; news1000) basic_machine=m68030-sony basic_os=newsos ;; necv70) basic_machine=v70-nec basic_os=sysv ;; nh3000) basic_machine=m68k-harris basic_os=cxux ;; nh[45]000) basic_machine=m88k-harris basic_os=cxux ;; nindy960) basic_machine=i960-intel basic_os=nindy ;; mon960) basic_machine=i960-intel basic_os=mon960 ;; nonstopux) basic_machine=mips-compaq basic_os=nonstopux ;; os400) basic_machine=powerpc-ibm basic_os=os400 ;; OSE68000 | ose68000) basic_machine=m68000-ericsson basic_os=ose ;; os68k) basic_machine=m68k-none basic_os=os68k ;; paragon) basic_machine=i860-intel basic_os=osf ;; parisc) basic_machine=hppa-unknown basic_os=linux ;; psp) basic_machine=mipsallegrexel-sony basic_os=psp ;; pw32) basic_machine=i586-unknown basic_os=pw32 ;; rdos | rdos64) basic_machine=x86_64-pc basic_os=rdos ;; rdos32) basic_machine=i386-pc basic_os=rdos ;; rom68k) basic_machine=m68k-rom68k basic_os=coff ;; sa29200) basic_machine=a29k-amd basic_os=udi ;; sei) basic_machine=mips-sei basic_os=seiux ;; sequent) basic_machine=i386-sequent basic_os= ;; sps7) basic_machine=m68k-bull basic_os=sysv2 ;; st2000) basic_machine=m68k-tandem basic_os= ;; stratus) basic_machine=i860-stratus basic_os=sysv4 ;; sun2) basic_machine=m68000-sun basic_os= ;; sun2os3) basic_machine=m68000-sun basic_os=sunos3 ;; sun2os4) basic_machine=m68000-sun basic_os=sunos4 ;; sun3) basic_machine=m68k-sun basic_os= ;; sun3os3) basic_machine=m68k-sun basic_os=sunos3 ;; sun3os4) basic_machine=m68k-sun basic_os=sunos4 ;; sun4) basic_machine=sparc-sun basic_os= ;; sun4os3) basic_machine=sparc-sun basic_os=sunos3 ;; sun4os4) basic_machine=sparc-sun basic_os=sunos4 ;; sun4sol2) basic_machine=sparc-sun basic_os=solaris2 ;; sun386 | sun386i | roadrunner) basic_machine=i386-sun basic_os= ;; sv1) basic_machine=sv1-cray basic_os=unicos ;; symmetry) basic_machine=i386-sequent basic_os=dynix ;; t3e) basic_machine=alphaev5-cray basic_os=unicos ;; t90) basic_machine=t90-cray basic_os=unicos ;; toad1) basic_machine=pdp10-xkl basic_os=tops20 ;; tpf) basic_machine=s390x-ibm basic_os=tpf ;; udi29k) basic_machine=a29k-amd basic_os=udi ;; ultra3) basic_machine=a29k-nyu basic_os=sym1 ;; v810 | necv810) basic_machine=v810-nec basic_os=none ;; vaxv) basic_machine=vax-dec basic_os=sysv ;; vms) basic_machine=vax-dec basic_os=vms ;; vsta) basic_machine=i386-pc basic_os=vsta ;; vxworks960) basic_machine=i960-wrs basic_os=vxworks ;; vxworks68) basic_machine=m68k-wrs basic_os=vxworks ;; vxworks29k) basic_machine=a29k-wrs basic_os=vxworks ;; xbox) basic_machine=i686-pc basic_os=mingw32 ;; ymp) basic_machine=ymp-cray basic_os=unicos ;; *) basic_machine=$1 basic_os= ;; esac ;; esac # Decode 1-component or ad-hoc basic machines case $basic_machine in # Here we handle the default manufacturer of certain CPU types. It is in # some cases the only manufacturer, in others, it is the most popular. w89k) cpu=hppa1.1 vendor=winbond ;; op50n) cpu=hppa1.1 vendor=oki ;; op60c) cpu=hppa1.1 vendor=oki ;; ibm*) cpu=i370 vendor=ibm ;; orion105) cpu=clipper vendor=highlevel ;; mac | mpw | mac-mpw) cpu=m68k vendor=apple ;; pmac | pmac-mpw) cpu=powerpc vendor=apple ;; # Recognize the various machine names and aliases which stand # for a CPU type and a company and sometimes even an OS. 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc) cpu=m68000 vendor=att ;; 3b*) cpu=we32k vendor=att ;; bluegene*) cpu=powerpc vendor=ibm basic_os=cnk ;; decsystem10* | dec10*) cpu=pdp10 vendor=dec basic_os=tops10 ;; decsystem20* | dec20*) cpu=pdp10 vendor=dec basic_os=tops20 ;; delta | 3300 | motorola-3300 | motorola-delta \ | 3300-motorola | delta-motorola) cpu=m68k vendor=motorola ;; dpx2*) cpu=m68k vendor=bull basic_os=sysv3 ;; encore | umax | mmax) cpu=ns32k vendor=encore ;; elxsi) cpu=elxsi vendor=elxsi basic_os=${basic_os:-bsd} ;; fx2800) cpu=i860 vendor=alliant ;; genix) cpu=ns32k vendor=ns ;; h3050r* | hiux*) cpu=hppa1.1 vendor=hitachi basic_os=hiuxwe2 ;; hp3k9[0-9][0-9] | hp9[0-9][0-9]) cpu=hppa1.0 vendor=hp ;; hp9k2[0-9][0-9] | hp9k31[0-9]) cpu=m68000 vendor=hp ;; hp9k3[2-9][0-9]) cpu=m68k vendor=hp ;; hp9k6[0-9][0-9] | hp6[0-9][0-9]) cpu=hppa1.0 vendor=hp ;; hp9k7[0-79][0-9] | hp7[0-79][0-9]) cpu=hppa1.1 vendor=hp ;; hp9k78[0-9] | hp78[0-9]) # FIXME: really hppa2.0-hp cpu=hppa1.1 vendor=hp ;; hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893) # FIXME: really hppa2.0-hp cpu=hppa1.1 vendor=hp ;; hp9k8[0-9][13679] | hp8[0-9][13679]) cpu=hppa1.1 vendor=hp ;; hp9k8[0-9][0-9] | hp8[0-9][0-9]) cpu=hppa1.0 vendor=hp ;; i*86v32) cpu=`echo "$1" | sed -e 's/86.*/86/'` vendor=pc basic_os=sysv32 ;; i*86v4*) cpu=`echo "$1" | sed -e 's/86.*/86/'` vendor=pc basic_os=sysv4 ;; i*86v) cpu=`echo "$1" | sed -e 's/86.*/86/'` vendor=pc basic_os=sysv ;; i*86sol2) cpu=`echo "$1" | sed -e 's/86.*/86/'` vendor=pc basic_os=solaris2 ;; j90 | j90-cray) cpu=j90 vendor=cray basic_os=${basic_os:-unicos} ;; iris | iris4d) cpu=mips vendor=sgi case $basic_os in irix*) ;; *) basic_os=irix4 ;; esac ;; miniframe) cpu=m68000 vendor=convergent ;; *mint | mint[0-9]* | *MiNT | *MiNT[0-9]*) cpu=m68k vendor=atari basic_os=mint ;; news-3600 | risc-news) cpu=mips vendor=sony basic_os=newsos ;; next | m*-next) cpu=m68k vendor=next case $basic_os in openstep*) ;; nextstep*) ;; ns2*) basic_os=nextstep2 ;; *) basic_os=nextstep3 ;; esac ;; np1) cpu=np1 vendor=gould ;; op50n-* | op60c-*) cpu=hppa1.1 vendor=oki basic_os=proelf ;; pa-hitachi) cpu=hppa1.1 vendor=hitachi basic_os=hiuxwe2 ;; pbd) cpu=sparc vendor=tti ;; pbb) cpu=m68k vendor=tti ;; pc532) cpu=ns32k vendor=pc532 ;; pn) cpu=pn vendor=gould ;; power) cpu=power vendor=ibm ;; ps2) cpu=i386 vendor=ibm ;; rm[46]00) cpu=mips vendor=siemens ;; rtpc | rtpc-*) cpu=romp vendor=ibm ;; sde) cpu=mipsisa32 vendor=sde basic_os=${basic_os:-elf} ;; simso-wrs) cpu=sparclite vendor=wrs basic_os=vxworks ;; tower | tower-32) cpu=m68k vendor=ncr ;; vpp*|vx|vx-*) cpu=f301 vendor=fujitsu ;; w65) cpu=w65 vendor=wdc ;; w89k-*) cpu=hppa1.1 vendor=winbond basic_os=proelf ;; none) cpu=none vendor=none ;; leon|leon[3-9]) cpu=sparc vendor=$basic_machine ;; leon-*|leon[3-9]-*) cpu=sparc vendor=`echo "$basic_machine" | sed 's/-.*//'` ;; *-*) # shellcheck disable=SC2162 saved_IFS=$IFS IFS="-" read cpu vendor <&2 exit 1 ;; esac ;; esac # Here we canonicalize certain aliases for manufacturers. case $vendor in digital*) vendor=dec ;; commodore*) vendor=cbm ;; *) ;; esac # Decode manufacturer-specific aliases for certain operating systems. if test x$basic_os != x then # First recognize some ad-hoc cases, or perhaps split kernel-os, or else just # set os. case $basic_os in gnu/linux*) kernel=linux os=`echo "$basic_os" | sed -e 's|gnu/linux|gnu|'` ;; os2-emx) kernel=os2 os=`echo "$basic_os" | sed -e 's|os2-emx|emx|'` ;; nto-qnx*) kernel=nto os=`echo "$basic_os" | sed -e 's|nto-qnx|qnx|'` ;; *-*) # shellcheck disable=SC2162 saved_IFS=$IFS IFS="-" read kernel os <&2 exit 1 ;; esac # As a final step for OS-related things, validate the OS-kernel combination # (given a valid OS), if there is a kernel. case $kernel-$os in linux-gnu* | linux-dietlibc* | linux-android* | linux-newlib* \ | linux-musl* | linux-relibc* | linux-uclibc* ) ;; uclinux-uclibc* ) ;; -dietlibc* | -newlib* | -musl* | -relibc* | -uclibc* ) # These are just libc implementations, not actual OSes, and thus # require a kernel. echo "Invalid configuration \`$1': libc \`$os' needs explicit kernel." 1>&2 exit 1 ;; kfreebsd*-gnu* | kopensolaris*-gnu*) ;; vxworks-simlinux | vxworks-simwindows | vxworks-spe) ;; nto-qnx*) ;; os2-emx) ;; *-eabi* | *-gnueabi*) ;; -*) # Blank kernel with real OS is always fine. ;; *-*) echo "Invalid configuration \`$1': Kernel \`$kernel' not known to work with OS \`$os'." 1>&2 exit 1 ;; esac # Here we handle the case where we know the os, and the CPU type, but not the # manufacturer. We pick the logical manufacturer. case $vendor in unknown) case $cpu-$os in *-riscix*) vendor=acorn ;; *-sunos*) vendor=sun ;; *-cnk* | *-aix*) vendor=ibm ;; *-beos*) vendor=be ;; *-hpux*) vendor=hp ;; *-mpeix*) vendor=hp ;; *-hiux*) vendor=hitachi ;; *-unos*) vendor=crds ;; *-dgux*) vendor=dg ;; *-luna*) vendor=omron ;; *-genix*) vendor=ns ;; *-clix*) vendor=intergraph ;; *-mvs* | *-opened*) vendor=ibm ;; *-os400*) vendor=ibm ;; s390-* | s390x-*) vendor=ibm ;; *-ptx*) vendor=sequent ;; *-tpf*) vendor=ibm ;; *-vxsim* | *-vxworks* | *-windiss*) vendor=wrs ;; *-aux*) vendor=apple ;; *-hms*) vendor=hitachi ;; *-mpw* | *-macos*) vendor=apple ;; *-*mint | *-mint[0-9]* | *-*MiNT | *-MiNT[0-9]*) vendor=atari ;; *-vos*) vendor=stratus ;; esac ;; esac echo "$cpu-$vendor-${kernel:+$kernel-}$os" exit # Local variables: # eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "timestamp='" # time-stamp-format: "%:y-%02m-%02d" # time-stamp-end: "'" # End: httrack-3.49.5/config.guess0000755000175000017500000014051214555203165012526 00000000000000#! /bin/sh # Attempt to guess a canonical system name. # Copyright 1992-2022 Free Software Foundation, Inc. # shellcheck disable=SC2006,SC2268 # see below for rationale timestamp='2022-01-09' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, see . # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that # program. This Exception is an additional permission under section 7 # of the GNU General Public License, version 3 ("GPLv3"). # # Originally written by Per Bothner; maintained since 2000 by Ben Elliston. # # You can get the latest version of this script from: # https://git.savannah.gnu.org/cgit/config.git/plain/config.guess # # Please send patches to . # The "shellcheck disable" line above the timestamp inhibits complaints # about features and limitations of the classic Bourne shell that were # superseded or lifted in POSIX. However, this script identifies a wide # variety of pre-POSIX systems that do not have POSIX shells at all, and # even some reasonably current systems (Solaris 10 as case-in-point) still # have a pre-POSIX /bin/sh. me=`echo "$0" | sed -e 's,.*/,,'` usage="\ Usage: $0 [OPTION] Output the configuration name of the system \`$me' is run on. Options: -h, --help print this help, then exit -t, --time-stamp print date of last modification, then exit -v, --version print version number, then exit Report bugs and patches to ." version="\ GNU config.guess ($timestamp) Originally written by Per Bothner. Copyright 1992-2022 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." help=" Try \`$me --help' for more information." # Parse command line while test $# -gt 0 ; do case $1 in --time-stamp | --time* | -t ) echo "$timestamp" ; exit ;; --version | -v ) echo "$version" ; exit ;; --help | --h* | -h ) echo "$usage"; exit ;; -- ) # Stop option processing shift; break ;; - ) # Use stdin as input. break ;; -* ) echo "$me: invalid option $1$help" >&2 exit 1 ;; * ) break ;; esac done if test $# != 0; then echo "$me: too many arguments$help" >&2 exit 1 fi # Just in case it came from the environment. GUESS= # CC_FOR_BUILD -- compiler used by this script. Note that the use of a # compiler to aid in system detection is discouraged as it requires # temporary files to be created and, as you can see below, it is a # headache to deal with in a portable fashion. # Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still # use `HOST_CC' if defined, but it is deprecated. # Portable tmp directory creation inspired by the Autoconf team. tmp= # shellcheck disable=SC2172 trap 'test -z "$tmp" || rm -fr "$tmp"' 0 1 2 13 15 set_cc_for_build() { # prevent multiple calls if $tmp is already set test "$tmp" && return 0 : "${TMPDIR=/tmp}" # shellcheck disable=SC2039,SC3028 { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir "$tmp" 2>/dev/null) ; } || { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir "$tmp" 2>/dev/null) && echo "Warning: creating insecure temp directory" >&2 ; } || { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } dummy=$tmp/dummy case ${CC_FOR_BUILD-},${HOST_CC-},${CC-} in ,,) echo "int x;" > "$dummy.c" for driver in cc gcc c89 c99 ; do if ($driver -c -o "$dummy.o" "$dummy.c") >/dev/null 2>&1 ; then CC_FOR_BUILD=$driver break fi done if test x"$CC_FOR_BUILD" = x ; then CC_FOR_BUILD=no_compiler_found fi ;; ,,*) CC_FOR_BUILD=$CC ;; ,*,*) CC_FOR_BUILD=$HOST_CC ;; esac } # This is needed to find uname on a Pyramid OSx when run in the BSD universe. # (ghazi@noc.rutgers.edu 1994-08-24) if test -f /.attbin/uname ; then PATH=$PATH:/.attbin ; export PATH fi UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown case $UNAME_SYSTEM in Linux|GNU|GNU/*) LIBC=unknown set_cc_for_build cat <<-EOF > "$dummy.c" #include #if defined(__UCLIBC__) LIBC=uclibc #elif defined(__dietlibc__) LIBC=dietlibc #elif defined(__GLIBC__) LIBC=gnu #else #include /* First heuristic to detect musl libc. */ #ifdef __DEFINED_va_list LIBC=musl #endif #endif EOF cc_set_libc=`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^LIBC' | sed 's, ,,g'` eval "$cc_set_libc" # Second heuristic to detect musl libc. if [ "$LIBC" = unknown ] && command -v ldd >/dev/null && ldd --version 2>&1 | grep -q ^musl; then LIBC=musl fi # If the system lacks a compiler, then just pick glibc. # We could probably try harder. if [ "$LIBC" = unknown ]; then LIBC=gnu fi ;; esac # Note: order is significant - the case branches are not exclusive. case $UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION in *:NetBSD:*:*) # NetBSD (nbsd) targets should (where applicable) match one or # more of the tuples: *-*-netbsdelf*, *-*-netbsdaout*, # *-*-netbsdecoff* and *-*-netbsd*. For targets that recently # switched to ELF, *-*-netbsd* would select the old # object file format. This provides both forward # compatibility and a consistent mechanism for selecting the # object file format. # # Note: NetBSD doesn't particularly care about the vendor # portion of the name. We always set it to "unknown". UNAME_MACHINE_ARCH=`(uname -p 2>/dev/null || \ /sbin/sysctl -n hw.machine_arch 2>/dev/null || \ /usr/sbin/sysctl -n hw.machine_arch 2>/dev/null || \ echo unknown)` case $UNAME_MACHINE_ARCH in aarch64eb) machine=aarch64_be-unknown ;; armeb) machine=armeb-unknown ;; arm*) machine=arm-unknown ;; sh3el) machine=shl-unknown ;; sh3eb) machine=sh-unknown ;; sh5el) machine=sh5le-unknown ;; earmv*) arch=`echo "$UNAME_MACHINE_ARCH" | sed -e 's,^e\(armv[0-9]\).*$,\1,'` endian=`echo "$UNAME_MACHINE_ARCH" | sed -ne 's,^.*\(eb\)$,\1,p'` machine=${arch}${endian}-unknown ;; *) machine=$UNAME_MACHINE_ARCH-unknown ;; esac # The Operating System including object format, if it has switched # to ELF recently (or will in the future) and ABI. case $UNAME_MACHINE_ARCH in earm*) os=netbsdelf ;; arm*|i386|m68k|ns32k|sh3*|sparc|vax) set_cc_for_build if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ELF__ then # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout). # Return netbsd for either. FIX? os=netbsd else os=netbsdelf fi ;; *) os=netbsd ;; esac # Determine ABI tags. case $UNAME_MACHINE_ARCH in earm*) expr='s/^earmv[0-9]/-eabi/;s/eb$//' abi=`echo "$UNAME_MACHINE_ARCH" | sed -e "$expr"` ;; esac # The OS release # Debian GNU/NetBSD machines have a different userland, and # thus, need a distinct triplet. However, they do not need # kernel version information, so it can be replaced with a # suitable tag, in the style of linux-gnu. case $UNAME_VERSION in Debian*) release='-gnu' ;; *) release=`echo "$UNAME_RELEASE" | sed -e 's/[-_].*//' | cut -d. -f1,2` ;; esac # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM: # contains redundant information, the shorter form: # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. GUESS=$machine-${os}${release}${abi-} ;; *:Bitrig:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'` GUESS=$UNAME_MACHINE_ARCH-unknown-bitrig$UNAME_RELEASE ;; *:OpenBSD:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'` GUESS=$UNAME_MACHINE_ARCH-unknown-openbsd$UNAME_RELEASE ;; *:SecBSD:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/SecBSD.//'` GUESS=$UNAME_MACHINE_ARCH-unknown-secbsd$UNAME_RELEASE ;; *:LibertyBSD:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/^.*BSD\.//'` GUESS=$UNAME_MACHINE_ARCH-unknown-libertybsd$UNAME_RELEASE ;; *:MidnightBSD:*:*) GUESS=$UNAME_MACHINE-unknown-midnightbsd$UNAME_RELEASE ;; *:ekkoBSD:*:*) GUESS=$UNAME_MACHINE-unknown-ekkobsd$UNAME_RELEASE ;; *:SolidBSD:*:*) GUESS=$UNAME_MACHINE-unknown-solidbsd$UNAME_RELEASE ;; *:OS108:*:*) GUESS=$UNAME_MACHINE-unknown-os108_$UNAME_RELEASE ;; macppc:MirBSD:*:*) GUESS=powerpc-unknown-mirbsd$UNAME_RELEASE ;; *:MirBSD:*:*) GUESS=$UNAME_MACHINE-unknown-mirbsd$UNAME_RELEASE ;; *:Sortix:*:*) GUESS=$UNAME_MACHINE-unknown-sortix ;; *:Twizzler:*:*) GUESS=$UNAME_MACHINE-unknown-twizzler ;; *:Redox:*:*) GUESS=$UNAME_MACHINE-unknown-redox ;; mips:OSF1:*.*) GUESS=mips-dec-osf1 ;; alpha:OSF1:*:*) # Reset EXIT trap before exiting to avoid spurious non-zero exit code. trap '' 0 case $UNAME_RELEASE in *4.0) UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` ;; *5.*) UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` ;; esac # According to Compaq, /usr/sbin/psrinfo has been available on # OSF/1 and Tru64 systems produced since 1995. I hope that # covers most systems running today. This code pipes the CPU # types through head -n 1, so we only detect the type of CPU 0. ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1` case $ALPHA_CPU_TYPE in "EV4 (21064)") UNAME_MACHINE=alpha ;; "EV4.5 (21064)") UNAME_MACHINE=alpha ;; "LCA4 (21066/21068)") UNAME_MACHINE=alpha ;; "EV5 (21164)") UNAME_MACHINE=alphaev5 ;; "EV5.6 (21164A)") UNAME_MACHINE=alphaev56 ;; "EV5.6 (21164PC)") UNAME_MACHINE=alphapca56 ;; "EV5.7 (21164PC)") UNAME_MACHINE=alphapca57 ;; "EV6 (21264)") UNAME_MACHINE=alphaev6 ;; "EV6.7 (21264A)") UNAME_MACHINE=alphaev67 ;; "EV6.8CB (21264C)") UNAME_MACHINE=alphaev68 ;; "EV6.8AL (21264B)") UNAME_MACHINE=alphaev68 ;; "EV6.8CX (21264D)") UNAME_MACHINE=alphaev68 ;; "EV6.9A (21264/EV69A)") UNAME_MACHINE=alphaev69 ;; "EV7 (21364)") UNAME_MACHINE=alphaev7 ;; "EV7.9 (21364A)") UNAME_MACHINE=alphaev79 ;; esac # A Pn.n version is a patched version. # A Vn.n version is a released version. # A Tn.n version is a released field test version. # A Xn.n version is an unreleased experimental baselevel. # 1.2 uses "1.2" for uname -r. OSF_REL=`echo "$UNAME_RELEASE" | sed -e 's/^[PVTX]//' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz` GUESS=$UNAME_MACHINE-dec-osf$OSF_REL ;; Amiga*:UNIX_System_V:4.0:*) GUESS=m68k-unknown-sysv4 ;; *:[Aa]miga[Oo][Ss]:*:*) GUESS=$UNAME_MACHINE-unknown-amigaos ;; *:[Mm]orph[Oo][Ss]:*:*) GUESS=$UNAME_MACHINE-unknown-morphos ;; *:OS/390:*:*) GUESS=i370-ibm-openedition ;; *:z/VM:*:*) GUESS=s390-ibm-zvmoe ;; *:OS400:*:*) GUESS=powerpc-ibm-os400 ;; arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) GUESS=arm-acorn-riscix$UNAME_RELEASE ;; arm*:riscos:*:*|arm*:RISCOS:*:*) GUESS=arm-unknown-riscos ;; SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*) GUESS=hppa1.1-hitachi-hiuxmpp ;; Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*) # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE. case `(/bin/universe) 2>/dev/null` in att) GUESS=pyramid-pyramid-sysv3 ;; *) GUESS=pyramid-pyramid-bsd ;; esac ;; NILE*:*:*:dcosx) GUESS=pyramid-pyramid-svr4 ;; DRS?6000:unix:4.0:6*) GUESS=sparc-icl-nx6 ;; DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*) case `/usr/bin/uname -p` in sparc) GUESS=sparc-icl-nx7 ;; esac ;; s390x:SunOS:*:*) SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` GUESS=$UNAME_MACHINE-ibm-solaris2$SUN_REL ;; sun4H:SunOS:5.*:*) SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` GUESS=sparc-hal-solaris2$SUN_REL ;; sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` GUESS=sparc-sun-solaris2$SUN_REL ;; i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*) GUESS=i386-pc-auroraux$UNAME_RELEASE ;; i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*) set_cc_for_build SUN_ARCH=i386 # If there is a compiler, see if it is configured for 64-bit objects. # Note that the Sun cc does not turn __LP64__ into 1 like gcc does. # This test works for both compilers. if test "$CC_FOR_BUILD" != no_compiler_found; then if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \ (CCOPTS="" $CC_FOR_BUILD -m64 -E - 2>/dev/null) | \ grep IS_64BIT_ARCH >/dev/null then SUN_ARCH=x86_64 fi fi SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` GUESS=$SUN_ARCH-pc-solaris2$SUN_REL ;; sun4*:SunOS:6*:*) # According to config.sub, this is the proper way to canonicalize # SunOS6. Hard to guess exactly what SunOS6 will be like, but # it's likely to be more like Solaris than SunOS4. SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` GUESS=sparc-sun-solaris3$SUN_REL ;; sun4*:SunOS:*:*) case `/usr/bin/arch -k` in Series*|S4*) UNAME_RELEASE=`uname -v` ;; esac # Japanese Language versions have a version number like `4.1.3-JL'. SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/-/_/'` GUESS=sparc-sun-sunos$SUN_REL ;; sun3*:SunOS:*:*) GUESS=m68k-sun-sunos$UNAME_RELEASE ;; sun*:*:4.2BSD:*) UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null` test "x$UNAME_RELEASE" = x && UNAME_RELEASE=3 case `/bin/arch` in sun3) GUESS=m68k-sun-sunos$UNAME_RELEASE ;; sun4) GUESS=sparc-sun-sunos$UNAME_RELEASE ;; esac ;; aushp:SunOS:*:*) GUESS=sparc-auspex-sunos$UNAME_RELEASE ;; # The situation for MiNT is a little confusing. The machine name # can be virtually everything (everything which is not # "atarist" or "atariste" at least should have a processor # > m68000). The system name ranges from "MiNT" over "FreeMiNT" # to the lowercase version "mint" (or "freemint"). Finally # the system name "TOS" denotes a system which is actually not # MiNT. But MiNT is downward compatible to TOS, so this should # be no problem. atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) GUESS=m68k-atari-mint$UNAME_RELEASE ;; atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) GUESS=m68k-atari-mint$UNAME_RELEASE ;; *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) GUESS=m68k-atari-mint$UNAME_RELEASE ;; milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) GUESS=m68k-milan-mint$UNAME_RELEASE ;; hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) GUESS=m68k-hades-mint$UNAME_RELEASE ;; *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) GUESS=m68k-unknown-mint$UNAME_RELEASE ;; m68k:machten:*:*) GUESS=m68k-apple-machten$UNAME_RELEASE ;; powerpc:machten:*:*) GUESS=powerpc-apple-machten$UNAME_RELEASE ;; RISC*:Mach:*:*) GUESS=mips-dec-mach_bsd4.3 ;; RISC*:ULTRIX:*:*) GUESS=mips-dec-ultrix$UNAME_RELEASE ;; VAX*:ULTRIX*:*:*) GUESS=vax-dec-ultrix$UNAME_RELEASE ;; 2020:CLIX:*:* | 2430:CLIX:*:*) GUESS=clipper-intergraph-clix$UNAME_RELEASE ;; mips:*:*:UMIPS | mips:*:*:RISCos) set_cc_for_build sed 's/^ //' << EOF > "$dummy.c" #ifdef __cplusplus #include /* for printf() prototype */ int main (int argc, char *argv[]) { #else int main (argc, argv) int argc; char *argv[]; { #endif #if defined (host_mips) && defined (MIPSEB) #if defined (SYSTYPE_SYSV) printf ("mips-mips-riscos%ssysv\\n", argv[1]); exit (0); #endif #if defined (SYSTYPE_SVR4) printf ("mips-mips-riscos%ssvr4\\n", argv[1]); exit (0); #endif #if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD) printf ("mips-mips-riscos%sbsd\\n", argv[1]); exit (0); #endif #endif exit (-1); } EOF $CC_FOR_BUILD -o "$dummy" "$dummy.c" && dummyarg=`echo "$UNAME_RELEASE" | sed -n 's/\([0-9]*\).*/\1/p'` && SYSTEM_NAME=`"$dummy" "$dummyarg"` && { echo "$SYSTEM_NAME"; exit; } GUESS=mips-mips-riscos$UNAME_RELEASE ;; Motorola:PowerMAX_OS:*:*) GUESS=powerpc-motorola-powermax ;; Motorola:*:4.3:PL8-*) GUESS=powerpc-harris-powermax ;; Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*) GUESS=powerpc-harris-powermax ;; Night_Hawk:Power_UNIX:*:*) GUESS=powerpc-harris-powerunix ;; m88k:CX/UX:7*:*) GUESS=m88k-harris-cxux7 ;; m88k:*:4*:R4*) GUESS=m88k-motorola-sysv4 ;; m88k:*:3*:R3*) GUESS=m88k-motorola-sysv3 ;; AViiON:dgux:*:*) # DG/UX returns AViiON for all architectures UNAME_PROCESSOR=`/usr/bin/uname -p` if test "$UNAME_PROCESSOR" = mc88100 || test "$UNAME_PROCESSOR" = mc88110 then if test "$TARGET_BINARY_INTERFACE"x = m88kdguxelfx || \ test "$TARGET_BINARY_INTERFACE"x = x then GUESS=m88k-dg-dgux$UNAME_RELEASE else GUESS=m88k-dg-dguxbcs$UNAME_RELEASE fi else GUESS=i586-dg-dgux$UNAME_RELEASE fi ;; M88*:DolphinOS:*:*) # DolphinOS (SVR3) GUESS=m88k-dolphin-sysv3 ;; M88*:*:R3*:*) # Delta 88k system running SVR3 GUESS=m88k-motorola-sysv3 ;; XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3) GUESS=m88k-tektronix-sysv3 ;; Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD) GUESS=m68k-tektronix-bsd ;; *:IRIX*:*:*) IRIX_REL=`echo "$UNAME_RELEASE" | sed -e 's/-/_/g'` GUESS=mips-sgi-irix$IRIX_REL ;; ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. GUESS=romp-ibm-aix # uname -m gives an 8 hex-code CPU id ;; # Note that: echo "'`uname -s`'" gives 'AIX ' i*86:AIX:*:*) GUESS=i386-ibm-aix ;; ia64:AIX:*:*) if test -x /usr/bin/oslevel ; then IBM_REV=`/usr/bin/oslevel` else IBM_REV=$UNAME_VERSION.$UNAME_RELEASE fi GUESS=$UNAME_MACHINE-ibm-aix$IBM_REV ;; *:AIX:2:3) if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then set_cc_for_build sed 's/^ //' << EOF > "$dummy.c" #include main() { if (!__power_pc()) exit(1); puts("powerpc-ibm-aix3.2.5"); exit(0); } EOF if $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"` then GUESS=$SYSTEM_NAME else GUESS=rs6000-ibm-aix3.2.5 fi elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then GUESS=rs6000-ibm-aix3.2.4 else GUESS=rs6000-ibm-aix3.2 fi ;; *:AIX:*:[4567]) IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` if /usr/sbin/lsattr -El "$IBM_CPU_ID" | grep ' POWER' >/dev/null 2>&1; then IBM_ARCH=rs6000 else IBM_ARCH=powerpc fi if test -x /usr/bin/lslpp ; then IBM_REV=`/usr/bin/lslpp -Lqc bos.rte.libc | \ awk -F: '{ print $3 }' | sed s/[0-9]*$/0/` else IBM_REV=$UNAME_VERSION.$UNAME_RELEASE fi GUESS=$IBM_ARCH-ibm-aix$IBM_REV ;; *:AIX:*:*) GUESS=rs6000-ibm-aix ;; ibmrt:4.4BSD:*|romp-ibm:4.4BSD:*) GUESS=romp-ibm-bsd4.4 ;; ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and GUESS=romp-ibm-bsd$UNAME_RELEASE # 4.3 with uname added to ;; # report: romp-ibm BSD 4.3 *:BOSX:*:*) GUESS=rs6000-bull-bosx ;; DPX/2?00:B.O.S.:*:*) GUESS=m68k-bull-sysv3 ;; 9000/[34]??:4.3bsd:1.*:*) GUESS=m68k-hp-bsd ;; hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*) GUESS=m68k-hp-bsd4.4 ;; 9000/[34678]??:HP-UX:*:*) HPUX_REV=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*.[0B]*//'` case $UNAME_MACHINE in 9000/31?) HP_ARCH=m68000 ;; 9000/[34]??) HP_ARCH=m68k ;; 9000/[678][0-9][0-9]) if test -x /usr/bin/getconf; then sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` case $sc_cpu_version in 523) HP_ARCH=hppa1.0 ;; # CPU_PA_RISC1_0 528) HP_ARCH=hppa1.1 ;; # CPU_PA_RISC1_1 532) # CPU_PA_RISC2_0 case $sc_kernel_bits in 32) HP_ARCH=hppa2.0n ;; 64) HP_ARCH=hppa2.0w ;; '') HP_ARCH=hppa2.0 ;; # HP-UX 10.20 esac ;; esac fi if test "$HP_ARCH" = ""; then set_cc_for_build sed 's/^ //' << EOF > "$dummy.c" #define _HPUX_SOURCE #include #include int main () { #if defined(_SC_KERNEL_BITS) long bits = sysconf(_SC_KERNEL_BITS); #endif long cpu = sysconf (_SC_CPU_VERSION); switch (cpu) { case CPU_PA_RISC1_0: puts ("hppa1.0"); break; case CPU_PA_RISC1_1: puts ("hppa1.1"); break; case CPU_PA_RISC2_0: #if defined(_SC_KERNEL_BITS) switch (bits) { case 64: puts ("hppa2.0w"); break; case 32: puts ("hppa2.0n"); break; default: puts ("hppa2.0"); break; } break; #else /* !defined(_SC_KERNEL_BITS) */ puts ("hppa2.0"); break; #endif default: puts ("hppa1.0"); break; } exit (0); } EOF (CCOPTS="" $CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null) && HP_ARCH=`"$dummy"` test -z "$HP_ARCH" && HP_ARCH=hppa fi ;; esac if test "$HP_ARCH" = hppa2.0w then set_cc_for_build # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating # 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler # generating 64-bit code. GNU and HP use different nomenclature: # # $ CC_FOR_BUILD=cc ./config.guess # => hppa2.0w-hp-hpux11.23 # $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess # => hppa64-hp-hpux11.23 if echo __LP64__ | (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | grep -q __LP64__ then HP_ARCH=hppa2.0w else HP_ARCH=hppa64 fi fi GUESS=$HP_ARCH-hp-hpux$HPUX_REV ;; ia64:HP-UX:*:*) HPUX_REV=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*.[0B]*//'` GUESS=ia64-hp-hpux$HPUX_REV ;; 3050*:HI-UX:*:*) set_cc_for_build sed 's/^ //' << EOF > "$dummy.c" #include int main () { long cpu = sysconf (_SC_CPU_VERSION); /* The order matters, because CPU_IS_HP_MC68K erroneously returns true for CPU_PA_RISC1_0. CPU_IS_PA_RISC returns correct results, however. */ if (CPU_IS_PA_RISC (cpu)) { switch (cpu) { case CPU_PA_RISC1_0: puts ("hppa1.0-hitachi-hiuxwe2"); break; case CPU_PA_RISC1_1: puts ("hppa1.1-hitachi-hiuxwe2"); break; case CPU_PA_RISC2_0: puts ("hppa2.0-hitachi-hiuxwe2"); break; default: puts ("hppa-hitachi-hiuxwe2"); break; } } else if (CPU_IS_HP_MC68K (cpu)) puts ("m68k-hitachi-hiuxwe2"); else puts ("unknown-hitachi-hiuxwe2"); exit (0); } EOF $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"` && { echo "$SYSTEM_NAME"; exit; } GUESS=unknown-hitachi-hiuxwe2 ;; 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:*) GUESS=hppa1.1-hp-bsd ;; 9000/8??:4.3bsd:*:*) GUESS=hppa1.0-hp-bsd ;; *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*) GUESS=hppa1.0-hp-mpeix ;; hp7??:OSF1:*:* | hp8?[79]:OSF1:*:*) GUESS=hppa1.1-hp-osf ;; hp8??:OSF1:*:*) GUESS=hppa1.0-hp-osf ;; i*86:OSF1:*:*) if test -x /usr/sbin/sysversion ; then GUESS=$UNAME_MACHINE-unknown-osf1mk else GUESS=$UNAME_MACHINE-unknown-osf1 fi ;; parisc*:Lites*:*:*) GUESS=hppa1.1-hp-lites ;; C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*) GUESS=c1-convex-bsd ;; C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*) if getsysinfo -f scalar_acc then echo c32-convex-bsd else echo c2-convex-bsd fi exit ;; C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*) GUESS=c34-convex-bsd ;; C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*) GUESS=c38-convex-bsd ;; C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*) GUESS=c4-convex-bsd ;; CRAY*Y-MP:*:*:*) CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'` GUESS=ymp-cray-unicos$CRAY_REL ;; CRAY*[A-Z]90:*:*:*) echo "$UNAME_MACHINE"-cray-unicos"$UNAME_RELEASE" \ | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \ -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \ -e 's/\.[^.]*$/.X/' exit ;; CRAY*TS:*:*:*) CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'` GUESS=t90-cray-unicos$CRAY_REL ;; CRAY*T3E:*:*:*) CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'` GUESS=alphaev5-cray-unicosmk$CRAY_REL ;; CRAY*SV1:*:*:*) CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'` GUESS=sv1-cray-unicos$CRAY_REL ;; *:UNICOS/mp:*:*) CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'` GUESS=craynv-cray-unicosmp$CRAY_REL ;; F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*) FUJITSU_PROC=`uname -m | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz` FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'` FUJITSU_REL=`echo "$UNAME_RELEASE" | sed -e 's/ /_/'` GUESS=${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL} ;; 5000:UNIX_System_V:4.*:*) FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'` FUJITSU_REL=`echo "$UNAME_RELEASE" | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/ /_/'` GUESS=sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL} ;; i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) GUESS=$UNAME_MACHINE-pc-bsdi$UNAME_RELEASE ;; sparc*:BSD/OS:*:*) GUESS=sparc-unknown-bsdi$UNAME_RELEASE ;; *:BSD/OS:*:*) GUESS=$UNAME_MACHINE-unknown-bsdi$UNAME_RELEASE ;; arm:FreeBSD:*:*) UNAME_PROCESSOR=`uname -p` set_cc_for_build if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ARM_PCS_VFP then FREEBSD_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'` GUESS=$UNAME_PROCESSOR-unknown-freebsd$FREEBSD_REL-gnueabi else FREEBSD_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'` GUESS=$UNAME_PROCESSOR-unknown-freebsd$FREEBSD_REL-gnueabihf fi ;; *:FreeBSD:*:*) UNAME_PROCESSOR=`/usr/bin/uname -p` case $UNAME_PROCESSOR in amd64) UNAME_PROCESSOR=x86_64 ;; i386) UNAME_PROCESSOR=i586 ;; esac FREEBSD_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'` GUESS=$UNAME_PROCESSOR-unknown-freebsd$FREEBSD_REL ;; i*:CYGWIN*:*) GUESS=$UNAME_MACHINE-pc-cygwin ;; *:MINGW64*:*) GUESS=$UNAME_MACHINE-pc-mingw64 ;; *:MINGW*:*) GUESS=$UNAME_MACHINE-pc-mingw32 ;; *:MSYS*:*) GUESS=$UNAME_MACHINE-pc-msys ;; i*:PW*:*) GUESS=$UNAME_MACHINE-pc-pw32 ;; *:SerenityOS:*:*) GUESS=$UNAME_MACHINE-pc-serenity ;; *:Interix*:*) case $UNAME_MACHINE in x86) GUESS=i586-pc-interix$UNAME_RELEASE ;; authenticamd | genuineintel | EM64T) GUESS=x86_64-unknown-interix$UNAME_RELEASE ;; IA64) GUESS=ia64-unknown-interix$UNAME_RELEASE ;; esac ;; i*:UWIN*:*) GUESS=$UNAME_MACHINE-pc-uwin ;; amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) GUESS=x86_64-pc-cygwin ;; prep*:SunOS:5.*:*) SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` GUESS=powerpcle-unknown-solaris2$SUN_REL ;; *:GNU:*:*) # the GNU system GNU_ARCH=`echo "$UNAME_MACHINE" | sed -e 's,[-/].*$,,'` GNU_REL=`echo "$UNAME_RELEASE" | sed -e 's,/.*$,,'` GUESS=$GNU_ARCH-unknown-$LIBC$GNU_REL ;; *:GNU/*:*:*) # other systems with GNU libc and userland GNU_SYS=`echo "$UNAME_SYSTEM" | sed 's,^[^/]*/,,' | tr "[:upper:]" "[:lower:]"` GNU_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'` GUESS=$UNAME_MACHINE-unknown-$GNU_SYS$GNU_REL-$LIBC ;; *:Minix:*:*) GUESS=$UNAME_MACHINE-unknown-minix ;; aarch64:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; aarch64_be:Linux:*:*) UNAME_MACHINE=aarch64_be GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; alpha:Linux:*:*) case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' /proc/cpuinfo 2>/dev/null` in EV5) UNAME_MACHINE=alphaev5 ;; EV56) UNAME_MACHINE=alphaev56 ;; PCA56) UNAME_MACHINE=alphapca56 ;; PCA57) UNAME_MACHINE=alphapca56 ;; EV6) UNAME_MACHINE=alphaev6 ;; EV67) UNAME_MACHINE=alphaev67 ;; EV68*) UNAME_MACHINE=alphaev68 ;; esac objdump --private-headers /bin/sh | grep -q ld.so.1 if test "$?" = 0 ; then LIBC=gnulibc1 ; fi GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; arc:Linux:*:* | arceb:Linux:*:* | arc32:Linux:*:* | arc64:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; arm*:Linux:*:*) set_cc_for_build if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ARM_EABI__ then GUESS=$UNAME_MACHINE-unknown-linux-$LIBC else if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ARM_PCS_VFP then GUESS=$UNAME_MACHINE-unknown-linux-${LIBC}eabi else GUESS=$UNAME_MACHINE-unknown-linux-${LIBC}eabihf fi fi ;; avr32*:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; cris:Linux:*:*) GUESS=$UNAME_MACHINE-axis-linux-$LIBC ;; crisv32:Linux:*:*) GUESS=$UNAME_MACHINE-axis-linux-$LIBC ;; e2k:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; frv:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; hexagon:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; i*86:Linux:*:*) GUESS=$UNAME_MACHINE-pc-linux-$LIBC ;; ia64:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; k1om:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; loongarch32:Linux:*:* | loongarch64:Linux:*:* | loongarchx32:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; m32r*:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; m68*:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; mips:Linux:*:* | mips64:Linux:*:*) set_cc_for_build IS_GLIBC=0 test x"${LIBC}" = xgnu && IS_GLIBC=1 sed 's/^ //' << EOF > "$dummy.c" #undef CPU #undef mips #undef mipsel #undef mips64 #undef mips64el #if ${IS_GLIBC} && defined(_ABI64) LIBCABI=gnuabi64 #else #if ${IS_GLIBC} && defined(_ABIN32) LIBCABI=gnuabin32 #else LIBCABI=${LIBC} #endif #endif #if ${IS_GLIBC} && defined(__mips64) && defined(__mips_isa_rev) && __mips_isa_rev>=6 CPU=mipsisa64r6 #else #if ${IS_GLIBC} && !defined(__mips64) && defined(__mips_isa_rev) && __mips_isa_rev>=6 CPU=mipsisa32r6 #else #if defined(__mips64) CPU=mips64 #else CPU=mips #endif #endif #endif #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) MIPS_ENDIAN=el #else #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) MIPS_ENDIAN= #else MIPS_ENDIAN= #endif #endif EOF cc_set_vars=`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^CPU\|^MIPS_ENDIAN\|^LIBCABI'` eval "$cc_set_vars" test "x$CPU" != x && { echo "$CPU${MIPS_ENDIAN}-unknown-linux-$LIBCABI"; exit; } ;; mips64el:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; openrisc*:Linux:*:*) GUESS=or1k-unknown-linux-$LIBC ;; or32:Linux:*:* | or1k*:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; padre:Linux:*:*) GUESS=sparc-unknown-linux-$LIBC ;; parisc64:Linux:*:* | hppa64:Linux:*:*) GUESS=hppa64-unknown-linux-$LIBC ;; parisc:Linux:*:* | hppa:Linux:*:*) # Look for CPU level case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in PA7*) GUESS=hppa1.1-unknown-linux-$LIBC ;; PA8*) GUESS=hppa2.0-unknown-linux-$LIBC ;; *) GUESS=hppa-unknown-linux-$LIBC ;; esac ;; ppc64:Linux:*:*) GUESS=powerpc64-unknown-linux-$LIBC ;; ppc:Linux:*:*) GUESS=powerpc-unknown-linux-$LIBC ;; ppc64le:Linux:*:*) GUESS=powerpc64le-unknown-linux-$LIBC ;; ppcle:Linux:*:*) GUESS=powerpcle-unknown-linux-$LIBC ;; riscv32:Linux:*:* | riscv32be:Linux:*:* | riscv64:Linux:*:* | riscv64be:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; s390:Linux:*:* | s390x:Linux:*:*) GUESS=$UNAME_MACHINE-ibm-linux-$LIBC ;; sh64*:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; sh*:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; sparc:Linux:*:* | sparc64:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; tile*:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; vax:Linux:*:*) GUESS=$UNAME_MACHINE-dec-linux-$LIBC ;; x86_64:Linux:*:*) set_cc_for_build LIBCABI=$LIBC if test "$CC_FOR_BUILD" != no_compiler_found; then if (echo '#ifdef __ILP32__'; echo IS_X32; echo '#endif') | \ (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \ grep IS_X32 >/dev/null then LIBCABI=${LIBC}x32 fi fi GUESS=$UNAME_MACHINE-pc-linux-$LIBCABI ;; xtensa*:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; i*86:DYNIX/ptx:4*:*) # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. # earlier versions are messed up and put the nodename in both # sysname and nodename. GUESS=i386-sequent-sysv4 ;; i*86:UNIX_SV:4.2MP:2.*) # Unixware is an offshoot of SVR4, but it has its own version # number series starting with 2... # I am not positive that other SVR4 systems won't match this, # I just have to hope. -- rms. # Use sysv4.2uw... so that sysv4* matches it. GUESS=$UNAME_MACHINE-pc-sysv4.2uw$UNAME_VERSION ;; i*86:OS/2:*:*) # If we were able to find `uname', then EMX Unix compatibility # is probably installed. GUESS=$UNAME_MACHINE-pc-os2-emx ;; i*86:XTS-300:*:STOP) GUESS=$UNAME_MACHINE-unknown-stop ;; i*86:atheos:*:*) GUESS=$UNAME_MACHINE-unknown-atheos ;; i*86:syllable:*:*) GUESS=$UNAME_MACHINE-pc-syllable ;; i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*) GUESS=i386-unknown-lynxos$UNAME_RELEASE ;; i*86:*DOS:*:*) GUESS=$UNAME_MACHINE-pc-msdosdjgpp ;; i*86:*:4.*:*) UNAME_REL=`echo "$UNAME_RELEASE" | sed 's/\/MP$//'` if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then GUESS=$UNAME_MACHINE-univel-sysv$UNAME_REL else GUESS=$UNAME_MACHINE-pc-sysv$UNAME_REL fi ;; i*86:*:5:[678]*) # UnixWare 7.x, OpenUNIX and OpenServer 6. case `/bin/uname -X | grep "^Machine"` in *486*) UNAME_MACHINE=i486 ;; *Pentium) UNAME_MACHINE=i586 ;; *Pent*|*Celeron) UNAME_MACHINE=i686 ;; esac GUESS=$UNAME_MACHINE-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION} ;; i*86:*:3.2:*) if test -f /usr/options/cb.name; then UNAME_REL=`sed -n 's/.*Version //p' /dev/null >/dev/null ; then UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')` (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486 (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \ && UNAME_MACHINE=i586 (/bin/uname -X|grep '^Machine.*Pent *II' >/dev/null) \ && UNAME_MACHINE=i686 (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \ && UNAME_MACHINE=i686 GUESS=$UNAME_MACHINE-pc-sco$UNAME_REL else GUESS=$UNAME_MACHINE-pc-sysv32 fi ;; pc:*:*:*) # Left here for compatibility: # uname -m prints for DJGPP always 'pc', but it prints nothing about # the processor, so we play safe by assuming i586. # Note: whatever this is, it MUST be the same as what config.sub # prints for the "djgpp" host, or else GDB configure will decide that # this is a cross-build. GUESS=i586-pc-msdosdjgpp ;; Intel:Mach:3*:*) GUESS=i386-pc-mach3 ;; paragon:*:*:*) GUESS=i860-intel-osf1 ;; i860:*:4.*:*) # i860-SVR4 if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then GUESS=i860-stardent-sysv$UNAME_RELEASE # Stardent Vistra i860-SVR4 else # Add other i860-SVR4 vendors below as they are discovered. GUESS=i860-unknown-sysv$UNAME_RELEASE # Unknown i860-SVR4 fi ;; mini*:CTIX:SYS*5:*) # "miniframe" GUESS=m68010-convergent-sysv ;; mc68k:UNIX:SYSTEM5:3.51m) GUESS=m68k-convergent-sysv ;; M680?0:D-NIX:5.3:*) GUESS=m68k-diab-dnix ;; M68*:*:R3V[5678]*:*) test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; } ;; 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0) OS_REL='' test -r /etc/.relid \ && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ && { echo i486-ncr-sysv4.3"$OS_REL"; exit; } /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ && { echo i586-ncr-sysv4.3"$OS_REL"; exit; } ;; 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ && { echo i486-ncr-sysv4; exit; } ;; NCR*:*:4.2:* | MPRAS*:*:4.2:*) OS_REL='.3' test -r /etc/.relid \ && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ && { echo i486-ncr-sysv4.3"$OS_REL"; exit; } /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ && { echo i586-ncr-sysv4.3"$OS_REL"; exit; } /bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \ && { echo i586-ncr-sysv4.3"$OS_REL"; exit; } ;; m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) GUESS=m68k-unknown-lynxos$UNAME_RELEASE ;; mc68030:UNIX_System_V:4.*:*) GUESS=m68k-atari-sysv4 ;; TSUNAMI:LynxOS:2.*:*) GUESS=sparc-unknown-lynxos$UNAME_RELEASE ;; rs6000:LynxOS:2.*:*) GUESS=rs6000-unknown-lynxos$UNAME_RELEASE ;; PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*) GUESS=powerpc-unknown-lynxos$UNAME_RELEASE ;; SM[BE]S:UNIX_SV:*:*) GUESS=mips-dde-sysv$UNAME_RELEASE ;; RM*:ReliantUNIX-*:*:*) GUESS=mips-sni-sysv4 ;; RM*:SINIX-*:*:*) GUESS=mips-sni-sysv4 ;; *:SINIX-*:*:*) if uname -p 2>/dev/null >/dev/null ; then UNAME_MACHINE=`(uname -p) 2>/dev/null` GUESS=$UNAME_MACHINE-sni-sysv4 else GUESS=ns32k-sni-sysv fi ;; PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort # says GUESS=i586-unisys-sysv4 ;; *:UNIX_System_V:4*:FTX*) # From Gerald Hewes . # How about differentiating between stratus architectures? -djm GUESS=hppa1.1-stratus-sysv4 ;; *:*:*:FTX*) # From seanf@swdc.stratus.com. GUESS=i860-stratus-sysv4 ;; i*86:VOS:*:*) # From Paul.Green@stratus.com. GUESS=$UNAME_MACHINE-stratus-vos ;; *:VOS:*:*) # From Paul.Green@stratus.com. GUESS=hppa1.1-stratus-vos ;; mc68*:A/UX:*:*) GUESS=m68k-apple-aux$UNAME_RELEASE ;; news*:NEWS-OS:6*:*) GUESS=mips-sony-newsos6 ;; R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) if test -d /usr/nec; then GUESS=mips-nec-sysv$UNAME_RELEASE else GUESS=mips-unknown-sysv$UNAME_RELEASE fi ;; BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. GUESS=powerpc-be-beos ;; BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only. GUESS=powerpc-apple-beos ;; BePC:BeOS:*:*) # BeOS running on Intel PC compatible. GUESS=i586-pc-beos ;; BePC:Haiku:*:*) # Haiku running on Intel PC compatible. GUESS=i586-pc-haiku ;; x86_64:Haiku:*:*) GUESS=x86_64-unknown-haiku ;; SX-4:SUPER-UX:*:*) GUESS=sx4-nec-superux$UNAME_RELEASE ;; SX-5:SUPER-UX:*:*) GUESS=sx5-nec-superux$UNAME_RELEASE ;; SX-6:SUPER-UX:*:*) GUESS=sx6-nec-superux$UNAME_RELEASE ;; SX-7:SUPER-UX:*:*) GUESS=sx7-nec-superux$UNAME_RELEASE ;; SX-8:SUPER-UX:*:*) GUESS=sx8-nec-superux$UNAME_RELEASE ;; SX-8R:SUPER-UX:*:*) GUESS=sx8r-nec-superux$UNAME_RELEASE ;; SX-ACE:SUPER-UX:*:*) GUESS=sxace-nec-superux$UNAME_RELEASE ;; Power*:Rhapsody:*:*) GUESS=powerpc-apple-rhapsody$UNAME_RELEASE ;; *:Rhapsody:*:*) GUESS=$UNAME_MACHINE-apple-rhapsody$UNAME_RELEASE ;; arm64:Darwin:*:*) GUESS=aarch64-apple-darwin$UNAME_RELEASE ;; *:Darwin:*:*) UNAME_PROCESSOR=`uname -p` case $UNAME_PROCESSOR in unknown) UNAME_PROCESSOR=powerpc ;; esac if command -v xcode-select > /dev/null 2> /dev/null && \ ! xcode-select --print-path > /dev/null 2> /dev/null ; then # Avoid executing cc if there is no toolchain installed as # cc will be a stub that puts up a graphical alert # prompting the user to install developer tools. CC_FOR_BUILD=no_compiler_found else set_cc_for_build fi if test "$CC_FOR_BUILD" != no_compiler_found; then if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \ (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \ grep IS_64BIT_ARCH >/dev/null then case $UNAME_PROCESSOR in i386) UNAME_PROCESSOR=x86_64 ;; powerpc) UNAME_PROCESSOR=powerpc64 ;; esac fi # On 10.4-10.6 one might compile for PowerPC via gcc -arch ppc if (echo '#ifdef __POWERPC__'; echo IS_PPC; echo '#endif') | \ (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \ grep IS_PPC >/dev/null then UNAME_PROCESSOR=powerpc fi elif test "$UNAME_PROCESSOR" = i386 ; then # uname -m returns i386 or x86_64 UNAME_PROCESSOR=$UNAME_MACHINE fi GUESS=$UNAME_PROCESSOR-apple-darwin$UNAME_RELEASE ;; *:procnto*:*:* | *:QNX:[0123456789]*:*) UNAME_PROCESSOR=`uname -p` if test "$UNAME_PROCESSOR" = x86; then UNAME_PROCESSOR=i386 UNAME_MACHINE=pc fi GUESS=$UNAME_PROCESSOR-$UNAME_MACHINE-nto-qnx$UNAME_RELEASE ;; *:QNX:*:4*) GUESS=i386-pc-qnx ;; NEO-*:NONSTOP_KERNEL:*:*) GUESS=neo-tandem-nsk$UNAME_RELEASE ;; NSE-*:NONSTOP_KERNEL:*:*) GUESS=nse-tandem-nsk$UNAME_RELEASE ;; NSR-*:NONSTOP_KERNEL:*:*) GUESS=nsr-tandem-nsk$UNAME_RELEASE ;; NSV-*:NONSTOP_KERNEL:*:*) GUESS=nsv-tandem-nsk$UNAME_RELEASE ;; NSX-*:NONSTOP_KERNEL:*:*) GUESS=nsx-tandem-nsk$UNAME_RELEASE ;; *:NonStop-UX:*:*) GUESS=mips-compaq-nonstopux ;; BS2000:POSIX*:*:*) GUESS=bs2000-siemens-sysv ;; DS/*:UNIX_System_V:*:*) GUESS=$UNAME_MACHINE-$UNAME_SYSTEM-$UNAME_RELEASE ;; *:Plan9:*:*) # "uname -m" is not consistent, so use $cputype instead. 386 # is converted to i386 for consistency with other x86 # operating systems. if test "${cputype-}" = 386; then UNAME_MACHINE=i386 elif test "x${cputype-}" != x; then UNAME_MACHINE=$cputype fi GUESS=$UNAME_MACHINE-unknown-plan9 ;; *:TOPS-10:*:*) GUESS=pdp10-unknown-tops10 ;; *:TENEX:*:*) GUESS=pdp10-unknown-tenex ;; KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*) GUESS=pdp10-dec-tops20 ;; XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*) GUESS=pdp10-xkl-tops20 ;; *:TOPS-20:*:*) GUESS=pdp10-unknown-tops20 ;; *:ITS:*:*) GUESS=pdp10-unknown-its ;; SEI:*:*:SEIUX) GUESS=mips-sei-seiux$UNAME_RELEASE ;; *:DragonFly:*:*) DRAGONFLY_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'` GUESS=$UNAME_MACHINE-unknown-dragonfly$DRAGONFLY_REL ;; *:*VMS:*:*) UNAME_MACHINE=`(uname -p) 2>/dev/null` case $UNAME_MACHINE in A*) GUESS=alpha-dec-vms ;; I*) GUESS=ia64-dec-vms ;; V*) GUESS=vax-dec-vms ;; esac ;; *:XENIX:*:SysV) GUESS=i386-pc-xenix ;; i*86:skyos:*:*) SKYOS_REL=`echo "$UNAME_RELEASE" | sed -e 's/ .*$//'` GUESS=$UNAME_MACHINE-pc-skyos$SKYOS_REL ;; i*86:rdos:*:*) GUESS=$UNAME_MACHINE-pc-rdos ;; i*86:Fiwix:*:*) GUESS=$UNAME_MACHINE-pc-fiwix ;; *:AROS:*:*) GUESS=$UNAME_MACHINE-unknown-aros ;; x86_64:VMkernel:*:*) GUESS=$UNAME_MACHINE-unknown-esx ;; amd64:Isilon\ OneFS:*:*) GUESS=x86_64-unknown-onefs ;; *:Unleashed:*:*) GUESS=$UNAME_MACHINE-unknown-unleashed$UNAME_RELEASE ;; esac # Do we have a guess based on uname results? if test "x$GUESS" != x; then echo "$GUESS" exit fi # No uname command or uname output not recognized. set_cc_for_build cat > "$dummy.c" < #include #endif #if defined(ultrix) || defined(_ultrix) || defined(__ultrix) || defined(__ultrix__) #if defined (vax) || defined (__vax) || defined (__vax__) || defined(mips) || defined(__mips) || defined(__mips__) || defined(MIPS) || defined(__MIPS__) #include #if defined(_SIZE_T_) || defined(SIGLOST) #include #endif #endif #endif main () { #if defined (sony) #if defined (MIPSEB) /* BFD wants "bsd" instead of "newsos". Perhaps BFD should be changed, I don't know.... */ printf ("mips-sony-bsd\n"); exit (0); #else #include printf ("m68k-sony-newsos%s\n", #ifdef NEWSOS4 "4" #else "" #endif ); exit (0); #endif #endif #if defined (NeXT) #if !defined (__ARCHITECTURE__) #define __ARCHITECTURE__ "m68k" #endif int version; version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`; if (version < 4) printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version); else printf ("%s-next-openstep%d\n", __ARCHITECTURE__, version); exit (0); #endif #if defined (MULTIMAX) || defined (n16) #if defined (UMAXV) printf ("ns32k-encore-sysv\n"); exit (0); #else #if defined (CMU) printf ("ns32k-encore-mach\n"); exit (0); #else printf ("ns32k-encore-bsd\n"); exit (0); #endif #endif #endif #if defined (__386BSD__) printf ("i386-pc-bsd\n"); exit (0); #endif #if defined (sequent) #if defined (i386) printf ("i386-sequent-dynix\n"); exit (0); #endif #if defined (ns32000) printf ("ns32k-sequent-dynix\n"); exit (0); #endif #endif #if defined (_SEQUENT_) struct utsname un; uname(&un); if (strncmp(un.version, "V2", 2) == 0) { printf ("i386-sequent-ptx2\n"); exit (0); } if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */ printf ("i386-sequent-ptx1\n"); exit (0); } printf ("i386-sequent-ptx\n"); exit (0); #endif #if defined (vax) #if !defined (ultrix) #include #if defined (BSD) #if BSD == 43 printf ("vax-dec-bsd4.3\n"); exit (0); #else #if BSD == 199006 printf ("vax-dec-bsd4.3reno\n"); exit (0); #else printf ("vax-dec-bsd\n"); exit (0); #endif #endif #else printf ("vax-dec-bsd\n"); exit (0); #endif #else #if defined(_SIZE_T_) || defined(SIGLOST) struct utsname un; uname (&un); printf ("vax-dec-ultrix%s\n", un.release); exit (0); #else printf ("vax-dec-ultrix\n"); exit (0); #endif #endif #endif #if defined(ultrix) || defined(_ultrix) || defined(__ultrix) || defined(__ultrix__) #if defined(mips) || defined(__mips) || defined(__mips__) || defined(MIPS) || defined(__MIPS__) #if defined(_SIZE_T_) || defined(SIGLOST) struct utsname *un; uname (&un); printf ("mips-dec-ultrix%s\n", un.release); exit (0); #else printf ("mips-dec-ultrix\n"); exit (0); #endif #endif #endif #if defined (alliant) && defined (i860) printf ("i860-alliant-bsd\n"); exit (0); #endif exit (1); } EOF $CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null && SYSTEM_NAME=`"$dummy"` && { echo "$SYSTEM_NAME"; exit; } # Apollos put the system type in the environment. test -d /usr/apollo && { echo "$ISP-apollo-$SYSTYPE"; exit; } echo "$0: unable to guess system type" >&2 case $UNAME_MACHINE:$UNAME_SYSTEM in mips:Linux | mips64:Linux) # If we got here on MIPS GNU/Linux, output extra information. cat >&2 <&2 <&2 </dev/null || echo unknown` uname -r = `(uname -r) 2>/dev/null || echo unknown` uname -s = `(uname -s) 2>/dev/null || echo unknown` uname -v = `(uname -v) 2>/dev/null || echo unknown` /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null` /bin/uname -X = `(/bin/uname -X) 2>/dev/null` hostinfo = `(hostinfo) 2>/dev/null` /bin/universe = `(/bin/universe) 2>/dev/null` /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null` /bin/arch = `(/bin/arch) 2>/dev/null` /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null` /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null` UNAME_MACHINE = "$UNAME_MACHINE" UNAME_RELEASE = "$UNAME_RELEASE" UNAME_SYSTEM = "$UNAME_SYSTEM" UNAME_VERSION = "$UNAME_VERSION" EOF fi exit 1 # Local variables: # eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "timestamp='" # time-stamp-format: "%:y-%02m-%02d" # time-stamp-end: "'" # End: httrack-3.49.5/compile0000755000175000017500000001635014555203165011566 00000000000000#! /bin/sh # Wrapper for compilers which do not understand '-c -o'. scriptversion=2018-03-07.03; # UTC # Copyright (C) 1999-2021 Free Software Foundation, Inc. # Written by Tom Tromey . # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2, or (at your option) # any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see . # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. # This file is maintained in Automake, please report # bugs to or send patches to # . nl=' ' # We need space, tab and new line, in precisely that order. Quoting is # there to prevent tools from complaining about whitespace usage. IFS=" "" $nl" file_conv= # func_file_conv build_file lazy # Convert a $build file to $host form and store it in $file # Currently only supports Windows hosts. If the determined conversion # type is listed in (the comma separated) LAZY, no conversion will # take place. func_file_conv () { file=$1 case $file in / | /[!/]*) # absolute file, and not a UNC file if test -z "$file_conv"; then # lazily determine how to convert abs files case `uname -s` in MINGW*) file_conv=mingw ;; CYGWIN* | MSYS*) file_conv=cygwin ;; *) file_conv=wine ;; esac fi case $file_conv/,$2, in *,$file_conv,*) ;; mingw/*) file=`cmd //C echo "$file " | sed -e 's/"\(.*\) " *$/\1/'` ;; cygwin/* | msys/*) file=`cygpath -m "$file" || echo "$file"` ;; wine/*) file=`winepath -w "$file" || echo "$file"` ;; esac ;; esac } # func_cl_dashL linkdir # Make cl look for libraries in LINKDIR func_cl_dashL () { func_file_conv "$1" if test -z "$lib_path"; then lib_path=$file else lib_path="$lib_path;$file" fi linker_opts="$linker_opts -LIBPATH:$file" } # func_cl_dashl library # Do a library search-path lookup for cl func_cl_dashl () { lib=$1 found=no save_IFS=$IFS IFS=';' for dir in $lib_path $LIB do IFS=$save_IFS if $shared && test -f "$dir/$lib.dll.lib"; then found=yes lib=$dir/$lib.dll.lib break fi if test -f "$dir/$lib.lib"; then found=yes lib=$dir/$lib.lib break fi if test -f "$dir/lib$lib.a"; then found=yes lib=$dir/lib$lib.a break fi done IFS=$save_IFS if test "$found" != yes; then lib=$lib.lib fi } # func_cl_wrapper cl arg... # Adjust compile command to suit cl func_cl_wrapper () { # Assume a capable shell lib_path= shared=: linker_opts= for arg do if test -n "$eat"; then eat= else case $1 in -o) # configure might choose to run compile as 'compile cc -o foo foo.c'. eat=1 case $2 in *.o | *.[oO][bB][jJ]) func_file_conv "$2" set x "$@" -Fo"$file" shift ;; *) func_file_conv "$2" set x "$@" -Fe"$file" shift ;; esac ;; -I) eat=1 func_file_conv "$2" mingw set x "$@" -I"$file" shift ;; -I*) func_file_conv "${1#-I}" mingw set x "$@" -I"$file" shift ;; -l) eat=1 func_cl_dashl "$2" set x "$@" "$lib" shift ;; -l*) func_cl_dashl "${1#-l}" set x "$@" "$lib" shift ;; -L) eat=1 func_cl_dashL "$2" ;; -L*) func_cl_dashL "${1#-L}" ;; -static) shared=false ;; -Wl,*) arg=${1#-Wl,} save_ifs="$IFS"; IFS=',' for flag in $arg; do IFS="$save_ifs" linker_opts="$linker_opts $flag" done IFS="$save_ifs" ;; -Xlinker) eat=1 linker_opts="$linker_opts $2" ;; -*) set x "$@" "$1" shift ;; *.cc | *.CC | *.cxx | *.CXX | *.[cC]++) func_file_conv "$1" set x "$@" -Tp"$file" shift ;; *.c | *.cpp | *.CPP | *.lib | *.LIB | *.Lib | *.OBJ | *.obj | *.[oO]) func_file_conv "$1" mingw set x "$@" "$file" shift ;; *) set x "$@" "$1" shift ;; esac fi shift done if test -n "$linker_opts"; then linker_opts="-link$linker_opts" fi exec "$@" $linker_opts exit 1 } eat= case $1 in '') echo "$0: No command. Try '$0 --help' for more information." 1>&2 exit 1; ;; -h | --h*) cat <<\EOF Usage: compile [--help] [--version] PROGRAM [ARGS] Wrapper for compilers which do not understand '-c -o'. Remove '-o dest.o' from ARGS, run PROGRAM with the remaining arguments, and rename the output as expected. If you are trying to build a whole package this is not the right script to run: please start by reading the file 'INSTALL'. Report bugs to . EOF exit $? ;; -v | --v*) echo "compile $scriptversion" exit $? ;; cl | *[/\\]cl | cl.exe | *[/\\]cl.exe | \ icl | *[/\\]icl | icl.exe | *[/\\]icl.exe ) func_cl_wrapper "$@" # Doesn't return... ;; esac ofile= cfile= for arg do if test -n "$eat"; then eat= else case $1 in -o) # configure might choose to run compile as 'compile cc -o foo foo.c'. # So we strip '-o arg' only if arg is an object. eat=1 case $2 in *.o | *.obj) ofile=$2 ;; *) set x "$@" -o "$2" shift ;; esac ;; *.c) cfile=$1 set x "$@" "$1" shift ;; *) set x "$@" "$1" shift ;; esac fi shift done if test -z "$ofile" || test -z "$cfile"; then # If no '-o' option was seen then we might have been invoked from a # pattern rule where we don't need one. That is ok -- this is a # normal compilation that the losing compiler can handle. If no # '.c' file was seen then we are probably linking. That is also # ok. exec "$@" fi # Name of file we expect compiler to create. cofile=`echo "$cfile" | sed 's|^.*[\\/]||; s|^[a-zA-Z]:||; s/\.c$/.o/'` # Create the lock directory. # Note: use '[/\\:.-]' here to ensure that we don't use the same name # that we are using for the .o file. Also, base the name on the expected # object file name, since that is what matters with a parallel build. lockdir=`echo "$cofile" | sed -e 's|[/\\:.-]|_|g'`.d while true; do if mkdir "$lockdir" >/dev/null 2>&1; then break fi sleep 1 done # FIXME: race condition here if user kills between mkdir and trap. trap "rmdir '$lockdir'; exit 1" 1 2 15 # Run the compile. "$@" ret=$? if test -f "$cofile"; then test "$cofile" = "$ofile" || mv "$cofile" "$ofile" elif test -f "${cofile}bj"; then test "${cofile}bj" = "$ofile" || mv "${cofile}bj" "$ofile" fi rmdir "$lockdir" exit $ret # Local Variables: # mode: shell-script # sh-indentation: 2 # eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" # time-stamp-end: "; # UTC" # End: httrack-3.49.5/README0000644000175000017500000000323414360553245011066 00000000000000HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2017 Xavier Roche and other contributors Welcome to HTTrack Website Copier! Information: The folder html/ contains the documentation You might want to read these files, especially for installing HTTrack: - See INSTALL file for installation information (NO WARRANTY) - See license.txt file for license information Contacting us: If you want to ask any question, feel free to contact us! email: httrack@httrack.com Donations: HTTrack Website Copier is free software, but if you can, please donate to the Free Software Foundation (FSF) to support free software! (Europe) http://www.fsfeurope.org/help/donate.html (World) http://www.fsf.org/help/donate.html Engine limits: These are the principals limits of HTTrack for that moment. Note that we did not heard about any other utility that would have solved them. - Several scripts generating complex filenames may not find them (ex: img.src='image'+a+Mobj.dst+'.gif') - Some java classes may not find some files on them (class included) - Cgi-bin links may not work properly in some cases (parameters needed). To avoid them: use filters like -*cgi-bin* Advanced options: These options may not be necessary for a normal usage. But they can solve several problems. - If you need more than 100,000 links: -#L1000000 (1,000,000 links) - If you need more than 500 filters: -#F1000 (1,000 filters) - If you need transfer rate statistics every minutes: -#Z - If you need transfer operations statistics every minutes: -#T - If you want log files to be refreshed after every line: -#f Thank you! Have fun with HTTrack Website Copier! The authors httrack-3.49.5/NEWS0000644000175000017500000000000014336470674010700 00000000000000httrack-3.49.5/INSTALL0000644000175000017500000003662614555203165011251 00000000000000Installation Instructions ************************* Copyright (C) 1994-1996, 1999-2002, 2004-2017, 2020-2021 Free Software Foundation, Inc. Copying and distribution of this file, with or without modification, are permitted in any medium without royalty provided the copyright notice and this notice are preserved. This file is offered as-is, without warranty of any kind. Basic Installation ================== Briefly, the shell command './configure && make && make install' should configure, build, and install this package. The following more-detailed instructions are generic; see the 'README' file for instructions specific to this package. Some packages provide this 'INSTALL' file but do not implement all of the features documented below. The lack of an optional feature in a given package is not necessarily a bug. More recommendations for GNU packages can be found in *note Makefile Conventions: (standards)Makefile Conventions. The 'configure' shell script attempts to guess correct values for various system-dependent variables used during compilation. It uses those values to create a 'Makefile' in each directory of the package. It may also create one or more '.h' files containing system-dependent definitions. Finally, it creates a shell script 'config.status' that you can run in the future to recreate the current configuration, and a file 'config.log' containing compiler output (useful mainly for debugging 'configure'). It can also use an optional file (typically called 'config.cache' and enabled with '--cache-file=config.cache' or simply '-C') that saves the results of its tests to speed up reconfiguring. Caching is disabled by default to prevent problems with accidental use of stale cache files. If you need to do unusual things to compile the package, please try to figure out how 'configure' could check whether to do them, and mail diffs or instructions to the address given in the 'README' so they can be considered for the next release. If you are using the cache, and at some point 'config.cache' contains results you don't want to keep, you may remove or edit it. The file 'configure.ac' (or 'configure.in') is used to create 'configure' by a program called 'autoconf'. You need 'configure.ac' if you want to change it or regenerate 'configure' using a newer version of 'autoconf'. The simplest way to compile this package is: 1. 'cd' to the directory containing the package's source code and type './configure' to configure the package for your system. Running 'configure' might take a while. While running, it prints some messages telling which features it is checking for. 2. Type 'make' to compile the package. 3. Optionally, type 'make check' to run any self-tests that come with the package, generally using the just-built uninstalled binaries. 4. Type 'make install' to install the programs and any data files and documentation. When installing into a prefix owned by root, it is recommended that the package be configured and built as a regular user, and only the 'make install' phase executed with root privileges. 5. Optionally, type 'make installcheck' to repeat any self-tests, but this time using the binaries in their final installed location. This target does not install anything. Running this target as a regular user, particularly if the prior 'make install' required root privileges, verifies that the installation completed correctly. 6. You can remove the program binaries and object files from the source code directory by typing 'make clean'. To also remove the files that 'configure' created (so you can compile the package for a different kind of computer), type 'make distclean'. There is also a 'make maintainer-clean' target, but that is intended mainly for the package's developers. If you use it, you may have to get all sorts of other programs in order to regenerate files that came with the distribution. 7. Often, you can also type 'make uninstall' to remove the installed files again. In practice, not all packages have tested that uninstallation works correctly, even though it is required by the GNU Coding Standards. 8. Some packages, particularly those that use Automake, provide 'make distcheck', which can by used by developers to test that all other targets like 'make install' and 'make uninstall' work correctly. This target is generally not run by end users. Compilers and Options ===================== Some systems require unusual options for compilation or linking that the 'configure' script does not know about. Run './configure --help' for details on some of the pertinent environment variables. You can give 'configure' initial values for configuration parameters by setting variables in the command line or in the environment. Here is an example: ./configure CC=c99 CFLAGS=-g LIBS=-lposix *Note Defining Variables::, for more details. Compiling For Multiple Architectures ==================================== You can compile the package for more than one kind of computer at the same time, by placing the object files for each architecture in their own directory. To do this, you can use GNU 'make'. 'cd' to the directory where you want the object files and executables to go and run the 'configure' script. 'configure' automatically checks for the source code in the directory that 'configure' is in and in '..'. This is known as a "VPATH" build. With a non-GNU 'make', it is safer to compile the package for one architecture at a time in the source code directory. After you have installed the package for one architecture, use 'make distclean' before reconfiguring for another architecture. On MacOS X 10.5 and later systems, you can create libraries and executables that work on multiple system types--known as "fat" or "universal" binaries--by specifying multiple '-arch' options to the compiler but only a single '-arch' option to the preprocessor. Like this: ./configure CC="gcc -arch i386 -arch x86_64 -arch ppc -arch ppc64" \ CXX="g++ -arch i386 -arch x86_64 -arch ppc -arch ppc64" \ CPP="gcc -E" CXXCPP="g++ -E" This is not guaranteed to produce working output in all cases, you may have to build one architecture at a time and combine the results using the 'lipo' tool if you have problems. Installation Names ================== By default, 'make install' installs the package's commands under '/usr/local/bin', include files under '/usr/local/include', etc. You can specify an installation prefix other than '/usr/local' by giving 'configure' the option '--prefix=PREFIX', where PREFIX must be an absolute file name. You can specify separate installation prefixes for architecture-specific files and architecture-independent files. If you pass the option '--exec-prefix=PREFIX' to 'configure', the package uses PREFIX as the prefix for installing programs and libraries. Documentation and other data files still use the regular prefix. In addition, if you use an unusual directory layout you can give options like '--bindir=DIR' to specify different values for particular kinds of files. Run 'configure --help' for a list of the directories you can set and what kinds of files go in them. In general, the default for these options is expressed in terms of '${prefix}', so that specifying just '--prefix' will affect all of the other directory specifications that were not explicitly provided. The most portable way to affect installation locations is to pass the correct locations to 'configure'; however, many packages provide one or both of the following shortcuts of passing variable assignments to the 'make install' command line to change installation locations without having to reconfigure or recompile. The first method involves providing an override variable for each affected directory. For example, 'make install prefix=/alternate/directory' will choose an alternate location for all directory configuration variables that were expressed in terms of '${prefix}'. Any directories that were specified during 'configure', but not in terms of '${prefix}', must each be overridden at install time for the entire installation to be relocated. The approach of makefile variable overrides for each directory variable is required by the GNU Coding Standards, and ideally causes no recompilation. However, some platforms have known limitations with the semantics of shared libraries that end up requiring recompilation when using this method, particularly noticeable in packages that use GNU Libtool. The second method involves providing the 'DESTDIR' variable. For example, 'make install DESTDIR=/alternate/directory' will prepend '/alternate/directory' before all installation names. The approach of 'DESTDIR' overrides is not required by the GNU Coding Standards, and does not work on platforms that have drive letters. On the other hand, it does better at avoiding recompilation issues, and works well even when some directory options were not specified in terms of '${prefix}' at 'configure' time. Optional Features ================= If the package supports it, you can cause programs to be installed with an extra prefix or suffix on their names by giving 'configure' the option '--program-prefix=PREFIX' or '--program-suffix=SUFFIX'. Some packages pay attention to '--enable-FEATURE' options to 'configure', where FEATURE indicates an optional part of the package. They may also pay attention to '--with-PACKAGE' options, where PACKAGE is something like 'gnu-as' or 'x' (for the X Window System). The 'README' should mention any '--enable-' and '--with-' options that the package recognizes. For packages that use the X Window System, 'configure' can usually find the X include and library files automatically, but if it doesn't, you can use the 'configure' options '--x-includes=DIR' and '--x-libraries=DIR' to specify their locations. Some packages offer the ability to configure how verbose the execution of 'make' will be. For these packages, running './configure --enable-silent-rules' sets the default to minimal output, which can be overridden with 'make V=1'; while running './configure --disable-silent-rules' sets the default to verbose, which can be overridden with 'make V=0'. Particular systems ================== On HP-UX, the default C compiler is not ANSI C compatible. If GNU CC is not installed, it is recommended to use the following options in order to use an ANSI C compiler: ./configure CC="cc -Ae -D_XOPEN_SOURCE=500" and if that doesn't work, install pre-built binaries of GCC for HP-UX. HP-UX 'make' updates targets which have the same timestamps as their prerequisites, which makes it generally unusable when shipped generated files such as 'configure' are involved. Use GNU 'make' instead. On OSF/1 a.k.a. Tru64, some versions of the default C compiler cannot parse its '' header file. The option '-nodtk' can be used as a workaround. If GNU CC is not installed, it is therefore recommended to try ./configure CC="cc" and if that doesn't work, try ./configure CC="cc -nodtk" On Solaris, don't put '/usr/ucb' early in your 'PATH'. This directory contains several dysfunctional programs; working variants of these programs are available in '/usr/bin'. So, if you need '/usr/ucb' in your 'PATH', put it _after_ '/usr/bin'. On Haiku, software installed for all users goes in '/boot/common', not '/usr/local'. It is recommended to use the following options: ./configure --prefix=/boot/common Specifying the System Type ========================== There may be some features 'configure' cannot figure out automatically, but needs to determine by the type of machine the package will run on. Usually, assuming the package is built to be run on the _same_ architectures, 'configure' can figure that out, but if it prints a message saying it cannot guess the machine type, give it the '--build=TYPE' option. TYPE can either be a short name for the system type, such as 'sun4', or a canonical name which has the form: CPU-COMPANY-SYSTEM where SYSTEM can have one of these forms: OS KERNEL-OS See the file 'config.sub' for the possible values of each field. If 'config.sub' isn't included in this package, then this package doesn't need to know the machine type. If you are _building_ compiler tools for cross-compiling, you should use the option '--target=TYPE' to select the type of system they will produce code for. If you want to _use_ a cross compiler, that generates code for a platform different from the build platform, you should specify the "host" platform (i.e., that on which the generated programs will eventually be run) with '--host=TYPE'. Sharing Defaults ================ If you want to set default values for 'configure' scripts to share, you can create a site shell script called 'config.site' that gives default values for variables like 'CC', 'cache_file', and 'prefix'. 'configure' looks for 'PREFIX/share/config.site' if it exists, then 'PREFIX/etc/config.site' if it exists. Or, you can set the 'CONFIG_SITE' environment variable to the location of the site script. A warning: not all 'configure' scripts look for a site script. Defining Variables ================== Variables not defined in a site shell script can be set in the environment passed to 'configure'. However, some packages may run configure again during the build, and the customized values of these variables may be lost. In order to avoid this problem, you should set them in the 'configure' command line, using 'VAR=value'. For example: ./configure CC=/usr/local2/bin/gcc causes the specified 'gcc' to be used as the C compiler (unless it is overridden in the site shell script). Unfortunately, this technique does not work for 'CONFIG_SHELL' due to an Autoconf limitation. Until the limitation is lifted, you can use this workaround: CONFIG_SHELL=/bin/bash ./configure CONFIG_SHELL=/bin/bash 'configure' Invocation ====================== 'configure' recognizes the following options to control how it operates. '--help' '-h' Print a summary of all of the options to 'configure', and exit. '--help=short' '--help=recursive' Print a summary of the options unique to this package's 'configure', and exit. The 'short' variant lists options used only in the top level, while the 'recursive' variant lists options also present in any nested packages. '--version' '-V' Print the version of Autoconf used to generate the 'configure' script, and exit. '--cache-file=FILE' Enable the cache: use and save the results of the tests in FILE, traditionally 'config.cache'. FILE defaults to '/dev/null' to disable caching. '--config-cache' '-C' Alias for '--cache-file=config.cache'. '--quiet' '--silent' '-q' Do not print messages saying which checks are being made. To suppress all normal output, redirect it to '/dev/null' (any error messages will still be shown). '--srcdir=DIR' Look for the package's source code in directory DIR. Usually 'configure' can determine that directory automatically. '--prefix=DIR' Use DIR as the installation prefix. *note Installation Names:: for more details, including other options available for fine-tuning the installation locations. '--no-create' '-n' Run the configure checks, but stop before creating any output files. 'configure' also accepts some other, not widely useful, options. Run 'configure --help' for more details. httrack-3.49.5/ChangeLog0000644000175000017500000000000014336470674011753 00000000000000httrack-3.49.5/COPYING0000644000175000017500000010451314336470674011252 00000000000000 GNU GENERAL PUBLIC LICENSE Version 3, 29 June 2007 Copyright (C) 2007 Free Software Foundation, Inc. Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. Preamble The GNU General Public License is a free, copyleft license for software and other kinds of works. The licenses for most software and other practical works are designed to take away your freedom to share and change the works. By contrast, the GNU General Public License is intended to guarantee your freedom to share and change all versions of a program--to make sure it remains free software for all its users. We, the Free Software Foundation, use the GNU General Public License for most of our software; it applies also to any other work released this way by its authors. You can apply it to your programs, too. When we speak of free software, we are referring to freedom, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for them if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs, and that you know you can do these things. To protect your rights, we need to prevent others from denying you these rights or asking you to surrender the rights. Therefore, you have certain responsibilities if you distribute copies of the software, or if you modify it: responsibilities to respect the freedom of others. For example, if you distribute copies of such a program, whether gratis or for a fee, you must pass on to the recipients the same freedoms that you received. You must make sure that they, too, receive or can get the source code. And you must show them these terms so they know their rights. Developers that use the GNU GPL protect your rights with two steps: (1) assert copyright on the software, and (2) offer you this License giving you legal permission to copy, distribute and/or modify it. For the developers' and authors' protection, the GPL clearly explains that there is no warranty for this free software. For both users' and authors' sake, the GPL requires that modified versions be marked as changed, so that their problems will not be attributed erroneously to authors of previous versions. Some devices are designed to deny users access to install or run modified versions of the software inside them, although the manufacturer can do so. This is fundamentally incompatible with the aim of protecting users' freedom to change the software. The systematic pattern of such abuse occurs in the area of products for individuals to use, which is precisely where it is most unacceptable. Therefore, we have designed this version of the GPL to prohibit the practice for those products. If such problems arise substantially in other domains, we stand ready to extend this provision to those domains in future versions of the GPL, as needed to protect the freedom of users. Finally, every program is threatened constantly by software patents. States should not allow patents to restrict development and use of software on general-purpose computers, but in those that do, we wish to avoid the special danger that patents applied to a free program could make it effectively proprietary. To prevent this, the GPL assures that patents cannot be used to render the program non-free. The precise terms and conditions for copying, distribution and modification follow. TERMS AND CONDITIONS 0. Definitions. "This License" refers to version 3 of the GNU General Public License. "Copyright" also means copyright-like laws that apply to other kinds of works, such as semiconductor masks. "The Program" refers to any copyrightable work licensed under this License. Each licensee is addressed as "you". "Licensees" and "recipients" may be individuals or organizations. To "modify" a work means to copy from or adapt all or part of the work in a fashion requiring copyright permission, other than the making of an exact copy. The resulting work is called a "modified version" of the earlier work or a work "based on" the earlier work. A "covered work" means either the unmodified Program or a work based on the Program. To "propagate" a work means to do anything with it that, without permission, would make you directly or secondarily liable for infringement under applicable copyright law, except executing it on a computer or modifying a private copy. Propagation includes copying, distribution (with or without modification), making available to the public, and in some countries other activities as well. To "convey" a work means any kind of propagation that enables other parties to make or receive copies. Mere interaction with a user through a computer network, with no transfer of a copy, is not conveying. An interactive user interface displays "Appropriate Legal Notices" to the extent that it includes a convenient and prominently visible feature that (1) displays an appropriate copyright notice, and (2) tells the user that there is no warranty for the work (except to the extent that warranties are provided), that licensees may convey the work under this License, and how to view a copy of this License. If the interface presents a list of user commands or options, such as a menu, a prominent item in the list meets this criterion. 1. Source Code. The "source code" for a work means the preferred form of the work for making modifications to it. "Object code" means any non-source form of a work. A "Standard Interface" means an interface that either is an official standard defined by a recognized standards body, or, in the case of interfaces specified for a particular programming language, one that is widely used among developers working in that language. The "System Libraries" of an executable work include anything, other than the work as a whole, that (a) is included in the normal form of packaging a Major Component, but which is not part of that Major Component, and (b) serves only to enable use of the work with that Major Component, or to implement a Standard Interface for which an implementation is available to the public in source code form. A "Major Component", in this context, means a major essential component (kernel, window system, and so on) of the specific operating system (if any) on which the executable work runs, or a compiler used to produce the work, or an object code interpreter used to run it. The "Corresponding Source" for a work in object code form means all the source code needed to generate, install, and (for an executable work) run the object code and to modify the work, including scripts to control those activities. However, it does not include the work's System Libraries, or general-purpose tools or generally available free programs which are used unmodified in performing those activities but which are not part of the work. For example, Corresponding Source includes interface definition files associated with source files for the work, and the source code for shared libraries and dynamically linked subprograms that the work is specifically designed to require, such as by intimate data communication or control flow between those subprograms and other parts of the work. The Corresponding Source need not include anything that users can regenerate automatically from other parts of the Corresponding Source. The Corresponding Source for a work in source code form is that same work. 2. Basic Permissions. All rights granted under this License are granted for the term of copyright on the Program, and are irrevocable provided the stated conditions are met. This License explicitly affirms your unlimited permission to run the unmodified Program. The output from running a covered work is covered by this License only if the output, given its content, constitutes a covered work. This License acknowledges your rights of fair use or other equivalent, as provided by copyright law. You may make, run and propagate covered works that you do not convey, without conditions so long as your license otherwise remains in force. You may convey covered works to others for the sole purpose of having them make modifications exclusively for you, or provide you with facilities for running those works, provided that you comply with the terms of this License in conveying all material for which you do not control copyright. Those thus making or running the covered works for you must do so exclusively on your behalf, under your direction and control, on terms that prohibit them from making any copies of your copyrighted material outside their relationship with you. Conveying under any other circumstances is permitted solely under the conditions stated below. Sublicensing is not allowed; section 10 makes it unnecessary. 3. Protecting Users' Legal Rights From Anti-Circumvention Law. No covered work shall be deemed part of an effective technological measure under any applicable law fulfilling obligations under article 11 of the WIPO copyright treaty adopted on 20 December 1996, or similar laws prohibiting or restricting circumvention of such measures. When you convey a covered work, you waive any legal power to forbid circumvention of technological measures to the extent such circumvention is effected by exercising rights under this License with respect to the covered work, and you disclaim any intention to limit operation or modification of the work as a means of enforcing, against the work's users, your or third parties' legal rights to forbid circumvention of technological measures. 4. Conveying Verbatim Copies. You may convey verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice; keep intact all notices stating that this License and any non-permissive terms added in accord with section 7 apply to the code; keep intact all notices of the absence of any warranty; and give all recipients a copy of this License along with the Program. You may charge any price or no price for each copy that you convey, and you may offer support or warranty protection for a fee. 5. Conveying Modified Source Versions. You may convey a work based on the Program, or the modifications to produce it from the Program, in the form of source code under the terms of section 4, provided that you also meet all of these conditions: a) The work must carry prominent notices stating that you modified it, and giving a relevant date. b) The work must carry prominent notices stating that it is released under this License and any conditions added under section 7. This requirement modifies the requirement in section 4 to "keep intact all notices". c) You must license the entire work, as a whole, under this License to anyone who comes into possession of a copy. This License will therefore apply, along with any applicable section 7 additional terms, to the whole of the work, and all its parts, regardless of how they are packaged. This License gives no permission to license the work in any other way, but it does not invalidate such permission if you have separately received it. d) If the work has interactive user interfaces, each must display Appropriate Legal Notices; however, if the Program has interactive interfaces that do not display Appropriate Legal Notices, your work need not make them do so. A compilation of a covered work with other separate and independent works, which are not by their nature extensions of the covered work, and which are not combined with it such as to form a larger program, in or on a volume of a storage or distribution medium, is called an "aggregate" if the compilation and its resulting copyright are not used to limit the access or legal rights of the compilation's users beyond what the individual works permit. Inclusion of a covered work in an aggregate does not cause this License to apply to the other parts of the aggregate. 6. Conveying Non-Source Forms. You may convey a covered work in object code form under the terms of sections 4 and 5, provided that you also convey the machine-readable Corresponding Source under the terms of this License, in one of these ways: a) Convey the object code in, or embodied in, a physical product (including a physical distribution medium), accompanied by the Corresponding Source fixed on a durable physical medium customarily used for software interchange. b) Convey the object code in, or embodied in, a physical product (including a physical distribution medium), accompanied by a written offer, valid for at least three years and valid for as long as you offer spare parts or customer support for that product model, to give anyone who possesses the object code either (1) a copy of the Corresponding Source for all the software in the product that is covered by this License, on a durable physical medium customarily used for software interchange, for a price no more than your reasonable cost of physically performing this conveying of source, or (2) access to copy the Corresponding Source from a network server at no charge. c) Convey individual copies of the object code with a copy of the written offer to provide the Corresponding Source. This alternative is allowed only occasionally and noncommercially, and only if you received the object code with such an offer, in accord with subsection 6b. d) Convey the object code by offering access from a designated place (gratis or for a charge), and offer equivalent access to the Corresponding Source in the same way through the same place at no further charge. You need not require recipients to copy the Corresponding Source along with the object code. If the place to copy the object code is a network server, the Corresponding Source may be on a different server (operated by you or a third party) that supports equivalent copying facilities, provided you maintain clear directions next to the object code saying where to find the Corresponding Source. Regardless of what server hosts the Corresponding Source, you remain obligated to ensure that it is available for as long as needed to satisfy these requirements. e) Convey the object code using peer-to-peer transmission, provided you inform other peers where the object code and Corresponding Source of the work are being offered to the general public at no charge under subsection 6d. A separable portion of the object code, whose source code is excluded from the Corresponding Source as a System Library, need not be included in conveying the object code work. A "User Product" is either (1) a "consumer product", which means any tangible personal property which is normally used for personal, family, or household purposes, or (2) anything designed or sold for incorporation into a dwelling. In determining whether a product is a consumer product, doubtful cases shall be resolved in favor of coverage. For a particular product received by a particular user, "normally used" refers to a typical or common use of that class of product, regardless of the status of the particular user or of the way in which the particular user actually uses, or expects or is expected to use, the product. A product is a consumer product regardless of whether the product has substantial commercial, industrial or non-consumer uses, unless such uses represent the only significant mode of use of the product. "Installation Information" for a User Product means any methods, procedures, authorization keys, or other information required to install and execute modified versions of a covered work in that User Product from a modified version of its Corresponding Source. The information must suffice to ensure that the continued functioning of the modified object code is in no case prevented or interfered with solely because modification has been made. If you convey an object code work under this section in, or with, or specifically for use in, a User Product, and the conveying occurs as part of a transaction in which the right of possession and use of the User Product is transferred to the recipient in perpetuity or for a fixed term (regardless of how the transaction is characterized), the Corresponding Source conveyed under this section must be accompanied by the Installation Information. But this requirement does not apply if neither you nor any third party retains the ability to install modified object code on the User Product (for example, the work has been installed in ROM). The requirement to provide Installation Information does not include a requirement to continue to provide support service, warranty, or updates for a work that has been modified or installed by the recipient, or for the User Product in which it has been modified or installed. Access to a network may be denied when the modification itself materially and adversely affects the operation of the network or violates the rules and protocols for communication across the network. Corresponding Source conveyed, and Installation Information provided, in accord with this section must be in a format that is publicly documented (and with an implementation available to the public in source code form), and must require no special password or key for unpacking, reading or copying. 7. Additional Terms. "Additional permissions" are terms that supplement the terms of this License by making exceptions from one or more of its conditions. Additional permissions that are applicable to the entire Program shall be treated as though they were included in this License, to the extent that they are valid under applicable law. If additional permissions apply only to part of the Program, that part may be used separately under those permissions, but the entire Program remains governed by this License without regard to the additional permissions. When you convey a copy of a covered work, you may at your option remove any additional permissions from that copy, or from any part of it. (Additional permissions may be written to require their own removal in certain cases when you modify the work.) You may place additional permissions on material, added by you to a covered work, for which you have or can give appropriate copyright permission. Notwithstanding any other provision of this License, for material you add to a covered work, you may (if authorized by the copyright holders of that material) supplement the terms of this License with terms: a) Disclaiming warranty or limiting liability differently from the terms of sections 15 and 16 of this License; or b) Requiring preservation of specified reasonable legal notices or author attributions in that material or in the Appropriate Legal Notices displayed by works containing it; or c) Prohibiting misrepresentation of the origin of that material, or requiring that modified versions of such material be marked in reasonable ways as different from the original version; or d) Limiting the use for publicity purposes of names of licensors or authors of the material; or e) Declining to grant rights under trademark law for use of some trade names, trademarks, or service marks; or f) Requiring indemnification of licensors and authors of that material by anyone who conveys the material (or modified versions of it) with contractual assumptions of liability to the recipient, for any liability that these contractual assumptions directly impose on those licensors and authors. All other non-permissive additional terms are considered "further restrictions" within the meaning of section 10. If the Program as you received it, or any part of it, contains a notice stating that it is governed by this License along with a term that is a further restriction, you may remove that term. If a license document contains a further restriction but permits relicensing or conveying under this License, you may add to a covered work material governed by the terms of that license document, provided that the further restriction does not survive such relicensing or conveying. If you add terms to a covered work in accord with this section, you must place, in the relevant source files, a statement of the additional terms that apply to those files, or a notice indicating where to find the applicable terms. Additional terms, permissive or non-permissive, may be stated in the form of a separately written license, or stated as exceptions; the above requirements apply either way. 8. Termination. You may not propagate or modify a covered work except as expressly provided under this License. Any attempt otherwise to propagate or modify it is void, and will automatically terminate your rights under this License (including any patent licenses granted under the third paragraph of section 11). However, if you cease all violation of this License, then your license from a particular copyright holder is reinstated (a) provisionally, unless and until the copyright holder explicitly and finally terminates your license, and (b) permanently, if the copyright holder fails to notify you of the violation by some reasonable means prior to 60 days after the cessation. Moreover, your license from a particular copyright holder is reinstated permanently if the copyright holder notifies you of the violation by some reasonable means, this is the first time you have received notice of violation of this License (for any work) from that copyright holder, and you cure the violation prior to 30 days after your receipt of the notice. Termination of your rights under this section does not terminate the licenses of parties who have received copies or rights from you under this License. If your rights have been terminated and not permanently reinstated, you do not qualify to receive new licenses for the same material under section 10. 9. Acceptance Not Required for Having Copies. You are not required to accept this License in order to receive or run a copy of the Program. Ancillary propagation of a covered work occurring solely as a consequence of using peer-to-peer transmission to receive a copy likewise does not require acceptance. However, nothing other than this License grants you permission to propagate or modify any covered work. These actions infringe copyright if you do not accept this License. Therefore, by modifying or propagating a covered work, you indicate your acceptance of this License to do so. 10. Automatic Licensing of Downstream Recipients. Each time you convey a covered work, the recipient automatically receives a license from the original licensors, to run, modify and propagate that work, subject to this License. You are not responsible for enforcing compliance by third parties with this License. An "entity transaction" is a transaction transferring control of an organization, or substantially all assets of one, or subdividing an organization, or merging organizations. If propagation of a covered work results from an entity transaction, each party to that transaction who receives a copy of the work also receives whatever licenses to the work the party's predecessor in interest had or could give under the previous paragraph, plus a right to possession of the Corresponding Source of the work from the predecessor in interest, if the predecessor has it or can get it with reasonable efforts. You may not impose any further restrictions on the exercise of the rights granted or affirmed under this License. For example, you may not impose a license fee, royalty, or other charge for exercise of rights granted under this License, and you may not initiate litigation (including a cross-claim or counterclaim in a lawsuit) alleging that any patent claim is infringed by making, using, selling, offering for sale, or importing the Program or any portion of it. 11. Patents. A "contributor" is a copyright holder who authorizes use under this License of the Program or a work on which the Program is based. The work thus licensed is called the contributor's "contributor version". A contributor's "essential patent claims" are all patent claims owned or controlled by the contributor, whether already acquired or hereafter acquired, that would be infringed by some manner, permitted by this License, of making, using, or selling its contributor version, but do not include claims that would be infringed only as a consequence of further modification of the contributor version. For purposes of this definition, "control" includes the right to grant patent sublicenses in a manner consistent with the requirements of this License. Each contributor grants you a non-exclusive, worldwide, royalty-free patent license under the contributor's essential patent claims, to make, use, sell, offer for sale, import and otherwise run, modify and propagate the contents of its contributor version. In the following three paragraphs, a "patent license" is any express agreement or commitment, however denominated, not to enforce a patent (such as an express permission to practice a patent or covenant not to sue for patent infringement). To "grant" such a patent license to a party means to make such an agreement or commitment not to enforce a patent against the party. If you convey a covered work, knowingly relying on a patent license, and the Corresponding Source of the work is not available for anyone to copy, free of charge and under the terms of this License, through a publicly available network server or other readily accessible means, then you must either (1) cause the Corresponding Source to be so available, or (2) arrange to deprive yourself of the benefit of the patent license for this particular work, or (3) arrange, in a manner consistent with the requirements of this License, to extend the patent license to downstream recipients. "Knowingly relying" means you have actual knowledge that, but for the patent license, your conveying the covered work in a country, or your recipient's use of the covered work in a country, would infringe one or more identifiable patents in that country that you have reason to believe are valid. If, pursuant to or in connection with a single transaction or arrangement, you convey, or propagate by procuring conveyance of, a covered work, and grant a patent license to some of the parties receiving the covered work authorizing them to use, propagate, modify or convey a specific copy of the covered work, then the patent license you grant is automatically extended to all recipients of the covered work and works based on it. A patent license is "discriminatory" if it does not include within the scope of its coverage, prohibits the exercise of, or is conditioned on the non-exercise of one or more of the rights that are specifically granted under this License. You may not convey a covered work if you are a party to an arrangement with a third party that is in the business of distributing software, under which you make payment to the third party based on the extent of your activity of conveying the work, and under which the third party grants, to any of the parties who would receive the covered work from you, a discriminatory patent license (a) in connection with copies of the covered work conveyed by you (or copies made from those copies), or (b) primarily for and in connection with specific products or compilations that contain the covered work, unless you entered into that arrangement, or that patent license was granted, prior to 28 March 2007. Nothing in this License shall be construed as excluding or limiting any implied license or other defenses to infringement that may otherwise be available to you under applicable patent law. 12. No Surrender of Others' Freedom. If conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License. If you cannot convey a covered work so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not convey it at all. For example, if you agree to terms that obligate you to collect a royalty for further conveying from those to whom you convey the Program, the only way you could satisfy both those terms and this License would be to refrain entirely from conveying the Program. 13. Use with the GNU Affero General Public License. Notwithstanding any other provision of this License, you have permission to link or combine any covered work with a work licensed under version 3 of the GNU Affero General Public License into a single combined work, and to convey the resulting work. The terms of this License will continue to apply to the part which is the covered work, but the special requirements of the GNU Affero General Public License, section 13, concerning interaction through a network will apply to the combination as such. 14. Revised Versions of this License. The Free Software Foundation may publish revised and/or new versions of the GNU General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. Each version is given a distinguishing version number. If the Program specifies that a certain numbered version of the GNU General Public License "or any later version" applies to it, you have the option of following the terms and conditions either of that numbered version or of any later version published by the Free Software Foundation. If the Program does not specify a version number of the GNU General Public License, you may choose any version ever published by the Free Software Foundation. If the Program specifies that a proxy can decide which future versions of the GNU General Public License can be used, that proxy's public statement of acceptance of a version permanently authorizes you to choose that version for the Program. Later license versions may give you additional or different permissions. However, no additional obligations are imposed on any author or copyright holder as a result of your choosing to follow a later version. 15. Disclaimer of Warranty. THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. 16. Limitation of Liability. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. 17. Interpretation of Sections 15 and 16. If the disclaimer of warranty and limitation of liability provided above cannot be given local legal effect according to their terms, reviewing courts shall apply local law that most closely approximates an absolute waiver of all civil liability in connection with the Program, unless a warranty or assumption of liability accompanies a copy of the Program in return for a fee. END OF TERMS AND CONDITIONS How to Apply These Terms to Your New Programs If you develop a new program, and you want it to be of the greatest possible use to the public, the best way to achieve this is to make it free software which everyone can redistribute and change under these terms. To do so, attach the following notices to the program. It is safest to attach them to the start of each source file to most effectively state the exclusion of warranty; and each file should have at least the "copyright" line and a pointer to where the full notice is found. Copyright (C) This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Also add information on how to contact you by electronic and paper mail. If the program does terminal interaction, make it output a short notice like this when it starts in an interactive mode: Copyright (C) This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. This is free software, and you are welcome to redistribute it under certain conditions; type `show c' for details. The hypothetical commands `show w' and `show c' should show the appropriate parts of the General Public License. Of course, your program's commands might be different; for a GUI interface, you would use an "about box". You should also get your employer (if you work as a programmer) or school, if any, to sign a "copyright disclaimer" for the program, if necessary. For more information on this, and how to apply and follow the GNU GPL, see . The GNU General Public License does not permit incorporating your program into proprietary programs. If your program is a subroutine library, you may consider it more useful to permit linking proprietary applications with the library. If this is what you want to do, use the GNU Lesser General Public License instead of this License. But first, please read . httrack-3.49.5/AUTHORS0000644000175000017500000000004114336470674011256 00000000000000Xavier Roche httrack-3.49.5/config.h.in0000644000175000017500000001353114555201650012226 00000000000000/* config.h.in. Generated from configure.ac by autoheader. */ /* Check for dlopen in c */ #undef DLLIB /* Define if pointers to integers require aligned access */ #undef HAVE_ALIGNED_ACCESS_REQUIRED /* Define to 1 if you have the header file. */ #undef HAVE_DLFCN_H /* Define to 1 if you have the header file. */ #undef HAVE_EXECINFO_H /* Define to 1 if you have the header file. */ #undef HAVE_INTTYPES_H /* Define to 1 if you have the `z' library (-lz). */ #undef HAVE_LIBZ /* Define to 1 if you have the header file. */ #undef HAVE_MINIX_CONFIG_H /* Define to 1 if you have the `snprintf' function. */ #undef HAVE_SNPRINTF /* Define to 1 if you have the header file. */ #undef HAVE_STDINT_H /* Define to 1 if you have the header file. */ #undef HAVE_STDIO_H /* Define to 1 if you have the header file. */ #undef HAVE_STDLIB_H /* Define to 1 if you have the header file. */ #undef HAVE_STRINGS_H /* Define to 1 if you have the header file. */ #undef HAVE_STRING_H /* Check for strnlen */ #undef HAVE_STRNLEN /* Define to 1 if you have the header file. */ #undef HAVE_SYS_STAT_H /* Define to 1 if you have the header file. */ #undef HAVE_SYS_TYPES_H /* Define to 1 if you have the header file. */ #undef HAVE_UNISTD_H /* Define to 1 or 0, depending whether the compiler supports simple visibility declarations. */ #undef HAVE_VISIBILITY /* Define to 1 if you have the `vsnprintf' function. */ #undef HAVE_VSNPRINTF /* Define to 1 if you have the header file. */ #undef HAVE_WCHAR_H /* Check for in_addr_t */ #undef HTS_DO_NOT_REDEFINE_in_addr_t /* Check for IPv6 */ #undef HTS_INET6 /* Check for large files support */ #undef HTS_LFS /* Check for OpenSSL */ #undef HTS_USEOPENSSL /* Check for libiconv */ #undef LIBICONV /* Check for libsocket */ #undef LIBSOCKET /* Define to the sub-directory where libtool stores uninstalled libraries. */ #undef LT_OBJDIR /* Name of package */ #undef PACKAGE /* Define to the address where bug reports for this package should be sent. */ #undef PACKAGE_BUGREPORT /* Define to the full name of this package. */ #undef PACKAGE_NAME /* Define to the full name and version of this package. */ #undef PACKAGE_STRING /* Define to the one symbol short name of this package. */ #undef PACKAGE_TARNAME /* Define to the home page for this package. */ #undef PACKAGE_URL /* Define to the version of this package. */ #undef PACKAGE_VERSION /* "enable replacement (v)snprintf if system (v)snprintf is broken" */ #undef PREFER_PORTABLE_SNPRINTF /* Check for setuid */ #undef SETUID /* The size of `long', as computed by sizeof. */ #undef SIZEOF_LONG /* The size of `long long', as computed by sizeof. */ #undef SIZEOF_LONG_LONG /* Define to 1 if all of the C90 standard headers exist (not just the ones required in a freestanding environment). This macro is provided for backward compatibility; new code need not use it. */ #undef STDC_HEADERS /* Check for pthread in pthreads */ #undef THREADS /* Enable extensions on AIX 3, Interix. */ #ifndef _ALL_SOURCE # undef _ALL_SOURCE #endif /* Enable general extensions on macOS. */ #ifndef _DARWIN_C_SOURCE # undef _DARWIN_C_SOURCE #endif /* Enable general extensions on Solaris. */ #ifndef __EXTENSIONS__ # undef __EXTENSIONS__ #endif /* Enable GNU extensions on systems that have them. */ #ifndef _GNU_SOURCE # undef _GNU_SOURCE #endif /* Enable X/Open compliant socket functions that do not require linking with -lxnet on HP-UX 11.11. */ #ifndef _HPUX_ALT_XOPEN_SOCKET_API # undef _HPUX_ALT_XOPEN_SOCKET_API #endif /* Identify the host operating system as Minix. This macro does not affect the system headers' behavior. A future release of Autoconf may stop defining this macro. */ #ifndef _MINIX # undef _MINIX #endif /* Enable general extensions on NetBSD. Enable NetBSD compatibility extensions on Minix. */ #ifndef _NETBSD_SOURCE # undef _NETBSD_SOURCE #endif /* Enable OpenBSD compatibility extensions on NetBSD. Oddly enough, this does nothing on OpenBSD. */ #ifndef _OPENBSD_SOURCE # undef _OPENBSD_SOURCE #endif /* Define to 1 if needed for POSIX-compatible behavior. */ #ifndef _POSIX_SOURCE # undef _POSIX_SOURCE #endif /* Define to 2 if needed for POSIX-compatible behavior. */ #ifndef _POSIX_1_SOURCE # undef _POSIX_1_SOURCE #endif /* Enable POSIX-compatible threading on Solaris. */ #ifndef _POSIX_PTHREAD_SEMANTICS # undef _POSIX_PTHREAD_SEMANTICS #endif /* Enable extensions specified by ISO/IEC TS 18661-5:2014. */ #ifndef __STDC_WANT_IEC_60559_ATTRIBS_EXT__ # undef __STDC_WANT_IEC_60559_ATTRIBS_EXT__ #endif /* Enable extensions specified by ISO/IEC TS 18661-1:2014. */ #ifndef __STDC_WANT_IEC_60559_BFP_EXT__ # undef __STDC_WANT_IEC_60559_BFP_EXT__ #endif /* Enable extensions specified by ISO/IEC TS 18661-2:2015. */ #ifndef __STDC_WANT_IEC_60559_DFP_EXT__ # undef __STDC_WANT_IEC_60559_DFP_EXT__ #endif /* Enable extensions specified by ISO/IEC TS 18661-4:2015. */ #ifndef __STDC_WANT_IEC_60559_FUNCS_EXT__ # undef __STDC_WANT_IEC_60559_FUNCS_EXT__ #endif /* Enable extensions specified by ISO/IEC TS 18661-3:2015. */ #ifndef __STDC_WANT_IEC_60559_TYPES_EXT__ # undef __STDC_WANT_IEC_60559_TYPES_EXT__ #endif /* Enable extensions specified by ISO/IEC TR 24731-2:2010. */ #ifndef __STDC_WANT_LIB_EXT2__ # undef __STDC_WANT_LIB_EXT2__ #endif /* Enable extensions specified by ISO/IEC 24747:2009. */ #ifndef __STDC_WANT_MATH_SPEC_FUNCS__ # undef __STDC_WANT_MATH_SPEC_FUNCS__ #endif /* Enable extensions on HP NonStop. */ #ifndef _TANDEM_SOURCE # undef _TANDEM_SOURCE #endif /* Enable X/Open extensions. Define to 500 only if necessary to make mbstate_t available. */ #ifndef _XOPEN_SOURCE # undef _XOPEN_SOURCE #endif /* Version number of package */ #undef VERSION /* in_port_t */ #undef in_port_t /* sa_family_t */ #undef sa_family_t httrack-3.49.5/Makefile.in0000644000175000017500000006413514555203173012260 00000000000000# Makefile.in generated by automake 1.16.5 from Makefile.am. # @configure_input@ # Copyright (C) 1994-2021 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ VPATH = @srcdir@ am__is_gnu_make = { \ if test -z '$(MAKELEVEL)'; then \ false; \ elif test -n '$(MAKE_HOST)'; then \ true; \ elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ true; \ else \ false; \ fi; \ } am__make_running_with_option = \ case $${target_option-} in \ ?) ;; \ *) echo "am__make_running_with_option: internal error: invalid" \ "target option '$${target_option-}' specified" >&2; \ exit 1;; \ esac; \ has_opt=no; \ sane_makeflags=$$MAKEFLAGS; \ if $(am__is_gnu_make); then \ sane_makeflags=$$MFLAGS; \ else \ case $$MAKEFLAGS in \ *\\[\ \ ]*) \ bs=\\; \ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ esac; \ fi; \ skip_next=no; \ strip_trailopt () \ { \ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ }; \ for flg in $$sane_makeflags; do \ test $$skip_next = yes && { skip_next=no; continue; }; \ case $$flg in \ *=*|--*) continue;; \ -*I) strip_trailopt 'I'; skip_next=yes;; \ -*I?*) strip_trailopt 'I';; \ -*O) strip_trailopt 'O'; skip_next=yes;; \ -*O?*) strip_trailopt 'O';; \ -*l) strip_trailopt 'l'; skip_next=yes;; \ -*l?*) strip_trailopt 'l';; \ -[dEDm]) skip_next=yes;; \ -[JT]) skip_next=yes;; \ esac; \ case $$flg in \ *$$target_option*) has_opt=yes; break;; \ esac; \ done; \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkglibexecdir = $(libexecdir)/@PACKAGE@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ subdir = . ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/check_zlib.m4 \ $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/snprintf.m4 \ $(top_srcdir)/m4/visibility.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) DIST_COMMON = $(srcdir)/Makefile.am $(top_srcdir)/configure \ $(am__configure_deps) $(am__DIST_COMMON) am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ configure.lineno config.status.lineno mkinstalldirs = $(install_sh) -d CONFIG_HEADER = config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = AM_V_P = $(am__v_P_@AM_V@) am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) am__v_P_0 = false am__v_P_1 = : AM_V_GEN = $(am__v_GEN_@AM_V@) am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) am__v_GEN_0 = @echo " GEN " $@; am__v_GEN_1 = AM_V_at = $(am__v_at_@AM_V@) am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) am__v_at_0 = @ am__v_at_1 = SOURCES = DIST_SOURCES = RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ ctags-recursive dvi-recursive html-recursive info-recursive \ install-data-recursive install-dvi-recursive \ install-exec-recursive install-html-recursive \ install-info-recursive install-pdf-recursive \ install-ps-recursive install-recursive installcheck-recursive \ installdirs-recursive pdf-recursive ps-recursive \ tags-recursive uninstall-recursive am__can_run_installinfo = \ case $$AM_UPDATE_INFO_DIR in \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ distclean-recursive maintainer-clean-recursive am__recursive_targets = \ $(RECURSIVE_TARGETS) \ $(RECURSIVE_CLEAN_TARGETS) \ $(am__extra_recursive_targets) AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ cscope distdir distdir-am dist dist-all distcheck am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) \ config.h.in # Read a list of newline-separated strings from the standard input, # and print each of them once, without duplicates. Input order is # *not* preserved. am__uniquify_input = $(AWK) '\ BEGIN { nonempty = 0; } \ { items[$$0] = 1; nonempty = 1; } \ END { if (nonempty) { for (i in items) print i; }; } \ ' # Make sure the list of sources is unique. This is necessary because, # e.g., the same source file might be shared among _SOURCES variables # for different programs/libraries. am__define_uniq_tagged_files = \ list='$(am__tagged_files)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | $(am__uniquify_input)` DIST_SUBDIRS = $(SUBDIRS) am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/config.h.in AUTHORS \ COPYING ChangeLog INSTALL NEWS README compile config.guess \ config.sub depcomp install-sh ltmain.sh missing DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) distdir = $(PACKAGE)-$(VERSION) top_distdir = $(distdir) am__remove_distdir = \ if test -d "$(distdir)"; then \ find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \ && rm -rf "$(distdir)" \ || { sleep 5 && rm -rf "$(distdir)"; }; \ else :; fi am__post_remove_distdir = $(am__remove_distdir) am__relativize = \ dir0=`pwd`; \ sed_first='s,^\([^/]*\)/.*$$,\1,'; \ sed_rest='s,^[^/]*/*,,'; \ sed_last='s,^.*/\([^/]*\)$$,\1,'; \ sed_butlast='s,/*[^/]*$$,,'; \ while test -n "$$dir1"; do \ first=`echo "$$dir1" | sed -e "$$sed_first"`; \ if test "$$first" != "."; then \ if test "$$first" = ".."; then \ dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ else \ first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ if test "$$first2" = "$$first"; then \ dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ else \ dir2="../$$dir2"; \ fi; \ dir0="$$dir0"/"$$first"; \ fi; \ fi; \ dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ done; \ reldir="$$dir2" DIST_ARCHIVES = $(distdir).tar.gz GZIP_ENV = --best DIST_TARGETS = dist-gzip # Exists only to be overridden by the user if desired. AM_DISTCHECK_DVI_TARGET = dvi distuninstallcheck_listfiles = find . -type f -print am__distuninstallcheck_listfiles = $(distuninstallcheck_listfiles) \ | sed 's|^\./|$(prefix)/|' | grep -v '$(infodir)/dir$$' distcleancheck_listfiles = find . -type f -print ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AM_CFLAGS = @AM_CFLAGS@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CFLAGS_PIE = @CFLAGS_PIE@ CFLAG_VISIBILITY = @CFLAG_VISIBILITY@ CPPFLAGS = @CPPFLAGS@ CSCOPE = @CSCOPE@ CTAGS = @CTAGS@ CYGPATH_W = @CYGPATH_W@ DEFAULT_CFLAGS = @DEFAULT_CFLAGS@ DEFAULT_LDFLAGS = @DEFAULT_LDFLAGS@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DLLTOOL = @DLLTOOL@ DL_LIBS = @DL_LIBS@ DSYMUTIL = @DSYMUTIL@ DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ ETAGS = @ETAGS@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ FILECMD = @FILECMD@ GREP = @GREP@ HAVE_VISIBILITY = @HAVE_VISIBILITY@ HTTPS_SUPPORT = @HTTPS_SUPPORT@ ICONV_LIBS = @ICONV_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LD = @LD@ LDFLAGS = @LDFLAGS@ LDFLAGS_PIE = @LDFLAGS_PIE@ LFS_FLAG = @LFS_FLAG@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ LIPO = @LIPO@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ LT_CV_OBJDIR = @LT_CV_OBJDIR@ LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ MAINT = @MAINT@ MAKEINFO = @MAKEINFO@ MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ NM = @NM@ NMEDIT = @NMEDIT@ OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ ONLINE_UNIT_TESTS = @ONLINE_UNIT_TESTS@ OPENSSL_LIBS = @OPENSSL_LIBS@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ RANLIB = @RANLIB@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ SHLIBPATH_VAR = @SHLIBPATH_VAR@ SOCKET_LIBS = @SOCKET_LIBS@ STRIP = @STRIP@ THREADS_CFLAGS = @THREADS_CFLAGS@ THREADS_LIBS = @THREADS_LIBS@ V6_FLAG = @V6_FLAG@ VERSION = @VERSION@ VERSION_INFO = @VERSION_INFO@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ builddir = @builddir@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ runstatedir = @runstatedir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ SUBDIRS = src man m4 libtest templates lang html tests ACLOCAL_AMFLAGS = -I m4 EXTRA_DIST = INSTALL.Linux \ gpl-fr.txt license.txt greetings.txt history.txt \ httrack-doc.html lang.def README.md all: config.h $(MAKE) $(AM_MAKEFLAGS) all-recursive .SUFFIXES: am--refresh: Makefile @: $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ echo ' cd $(srcdir) && $(AUTOMAKE) --gnu'; \ $(am__cd) $(srcdir) && $(AUTOMAKE) --gnu \ && exit 0; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --gnu Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ echo ' $(SHELL) ./config.status'; \ $(SHELL) ./config.status;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__maybe_remake_depfiles)'; \ cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__maybe_remake_depfiles);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) $(SHELL) ./config.status --recheck $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) $(am__cd) $(srcdir) && $(AUTOCONF) $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) $(am__cd) $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS) $(am__aclocal_m4_deps): config.h: stamp-h1 @test -f $@ || rm -f stamp-h1 @test -f $@ || $(MAKE) $(AM_MAKEFLAGS) stamp-h1 stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status @rm -f stamp-h1 cd $(top_builddir) && $(SHELL) ./config.status config.h $(srcdir)/config.h.in: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) ($(am__cd) $(top_srcdir) && $(AUTOHEADER)) rm -f stamp-h1 touch $@ distclean-hdr: -rm -f config.h stamp-h1 mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs distclean-libtool: -rm -f libtool config.lt # This directory's subdirectories are mostly independent; you can cd # into them and run 'make' without going through this Makefile. # To change the values of 'make' variables: instead of editing Makefiles, # (1) if the variable is set in 'config.status', edit 'config.status' # (which will cause the Makefiles to be regenerated when you run 'make'); # (2) otherwise, pass the desired values on the 'make' command line. $(am__recursive_targets): @fail=; \ if $(am__make_keepgoing); then \ failcom='fail=yes'; \ else \ failcom='exit 1'; \ fi; \ dot_seen=no; \ target=`echo $@ | sed s/-recursive//`; \ case "$@" in \ distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ *) list='$(SUBDIRS)' ;; \ esac; \ for subdir in $$list; do \ echo "Making $$target in $$subdir"; \ if test "$$subdir" = "."; then \ dot_seen=yes; \ local_target="$$target-am"; \ else \ local_target="$$target"; \ fi; \ ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ || eval $$failcom; \ done; \ if test "$$dot_seen" = "no"; then \ $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ fi; test -z "$$fail" ID: $(am__tagged_files) $(am__define_uniq_tagged_files); mkid -fID $$unique tags: tags-recursive TAGS: tags tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ include_option=--etags-include; \ empty_fix=.; \ else \ include_option=--include; \ empty_fix=; \ fi; \ list='$(SUBDIRS)'; for subdir in $$list; do \ if test "$$subdir" = .; then :; else \ test ! -f $$subdir/TAGS || \ set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ fi; \ done; \ $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ if test $$# -gt 0; then \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ "$$@" $$unique; \ else \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$unique; \ fi; \ fi ctags: ctags-recursive CTAGS: ctags ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" cscope: cscope.files test ! -s cscope.files \ || $(CSCOPE) -b -q $(AM_CSCOPEFLAGS) $(CSCOPEFLAGS) -i cscope.files $(CSCOPE_ARGS) clean-cscope: -rm -f cscope.files cscope.files: clean-cscope cscopelist cscopelist: cscopelist-recursive cscopelist-am: $(am__tagged_files) list='$(am__tagged_files)'; \ case "$(srcdir)" in \ [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ *) sdir=$(subdir)/$(srcdir) ;; \ esac; \ for i in $$list; do \ if test -f "$$i"; then \ echo "$(subdir)/$$i"; \ else \ echo "$$sdir/$$i"; \ fi; \ done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags -rm -f cscope.out cscope.in.out cscope.po.out cscope.files distdir: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) distdir-am distdir-am: $(DISTFILES) $(am__remove_distdir) test -d "$(distdir)" || mkdir "$(distdir)" @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ dist_files=`for file in $$list; do echo $$file; done | \ sed -e "s|^$$srcdirstrip/||;t" \ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ case $$dist_files in \ */*) $(MKDIR_P) `echo "$$dist_files" | \ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ sort -u` ;; \ esac; \ for file in $$dist_files; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ if test -d $$d/$$file; then \ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ if test -d "$(distdir)/$$file"; then \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ else \ test -f "$(distdir)/$$file" \ || cp -p $$d/$$file "$(distdir)/$$file" \ || exit 1; \ fi; \ done @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ if test "$$subdir" = .; then :; else \ $(am__make_dryrun) \ || test -d "$(distdir)/$$subdir" \ || $(MKDIR_P) "$(distdir)/$$subdir" \ || exit 1; \ dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ $(am__relativize); \ new_distdir=$$reldir; \ dir1=$$subdir; dir2="$(top_distdir)"; \ $(am__relativize); \ new_top_distdir=$$reldir; \ echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ ($(am__cd) $$subdir && \ $(MAKE) $(AM_MAKEFLAGS) \ top_distdir="$$new_top_distdir" \ distdir="$$new_distdir" \ am__remove_distdir=: \ am__skip_length_check=: \ am__skip_mode_fix=: \ distdir) \ || exit 1; \ fi; \ done -test -n "$(am__skip_mode_fix)" \ || find "$(distdir)" -type d ! -perm -755 \ -exec chmod u+rwx,go+rx {} \; -o \ ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \ ! -type d ! -perm -400 -exec chmod a+r {} \; -o \ ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \ || chmod -R a+r "$(distdir)" dist-gzip: distdir tardir=$(distdir) && $(am__tar) | eval GZIP= gzip $(GZIP_ENV) -c >$(distdir).tar.gz $(am__post_remove_distdir) dist-bzip2: distdir tardir=$(distdir) && $(am__tar) | BZIP2=$${BZIP2--9} bzip2 -c >$(distdir).tar.bz2 $(am__post_remove_distdir) dist-lzip: distdir tardir=$(distdir) && $(am__tar) | lzip -c $${LZIP_OPT--9} >$(distdir).tar.lz $(am__post_remove_distdir) dist-xz: distdir tardir=$(distdir) && $(am__tar) | XZ_OPT=$${XZ_OPT--e} xz -c >$(distdir).tar.xz $(am__post_remove_distdir) dist-zstd: distdir tardir=$(distdir) && $(am__tar) | zstd -c $${ZSTD_CLEVEL-$${ZSTD_OPT--19}} >$(distdir).tar.zst $(am__post_remove_distdir) dist-tarZ: distdir @echo WARNING: "Support for distribution archives compressed with" \ "legacy program 'compress' is deprecated." >&2 @echo WARNING: "It will be removed altogether in Automake 2.0" >&2 tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z $(am__post_remove_distdir) dist-shar: distdir @echo WARNING: "Support for shar distribution archives is" \ "deprecated." >&2 @echo WARNING: "It will be removed altogether in Automake 2.0" >&2 shar $(distdir) | eval GZIP= gzip $(GZIP_ENV) -c >$(distdir).shar.gz $(am__post_remove_distdir) dist-zip: distdir -rm -f $(distdir).zip zip -rq $(distdir).zip $(distdir) $(am__post_remove_distdir) dist dist-all: $(MAKE) $(AM_MAKEFLAGS) $(DIST_TARGETS) am__post_remove_distdir='@:' $(am__post_remove_distdir) # This target untars the dist file and tries a VPATH configuration. Then # it guarantees that the distribution is self-contained by making another # tarfile. distcheck: dist case '$(DIST_ARCHIVES)' in \ *.tar.gz*) \ eval GZIP= gzip $(GZIP_ENV) -dc $(distdir).tar.gz | $(am__untar) ;;\ *.tar.bz2*) \ bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\ *.tar.lz*) \ lzip -dc $(distdir).tar.lz | $(am__untar) ;;\ *.tar.xz*) \ xz -dc $(distdir).tar.xz | $(am__untar) ;;\ *.tar.Z*) \ uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ *.shar.gz*) \ eval GZIP= gzip $(GZIP_ENV) -dc $(distdir).shar.gz | unshar ;;\ *.zip*) \ unzip $(distdir).zip ;;\ *.tar.zst*) \ zstd -dc $(distdir).tar.zst | $(am__untar) ;;\ esac chmod -R a-w $(distdir) chmod u+w $(distdir) mkdir $(distdir)/_build $(distdir)/_build/sub $(distdir)/_inst chmod a-w $(distdir) test -d $(distdir)/_build || exit 0; \ dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \ && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \ && am__cwd=`pwd` \ && $(am__cd) $(distdir)/_build/sub \ && ../../configure \ $(AM_DISTCHECK_CONFIGURE_FLAGS) \ $(DISTCHECK_CONFIGURE_FLAGS) \ --srcdir=../.. --prefix="$$dc_install_base" \ && $(MAKE) $(AM_MAKEFLAGS) \ && $(MAKE) $(AM_MAKEFLAGS) $(AM_DISTCHECK_DVI_TARGET) \ && $(MAKE) $(AM_MAKEFLAGS) check \ && $(MAKE) $(AM_MAKEFLAGS) install \ && $(MAKE) $(AM_MAKEFLAGS) installcheck \ && $(MAKE) $(AM_MAKEFLAGS) uninstall \ && $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \ distuninstallcheck \ && chmod -R a-w "$$dc_install_base" \ && ({ \ (cd ../.. && umask 077 && mkdir "$$dc_destdir") \ && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \ && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \ && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \ distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \ } || { rm -rf "$$dc_destdir"; exit 1; }) \ && rm -rf "$$dc_destdir" \ && $(MAKE) $(AM_MAKEFLAGS) dist \ && rm -rf $(DIST_ARCHIVES) \ && $(MAKE) $(AM_MAKEFLAGS) distcleancheck \ && cd "$$am__cwd" \ || exit 1 $(am__post_remove_distdir) @(echo "$(distdir) archives ready for distribution: "; \ list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \ sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x' distuninstallcheck: @test -n '$(distuninstallcheck_dir)' || { \ echo 'ERROR: trying to run $@ with an empty' \ '$$(distuninstallcheck_dir)' >&2; \ exit 1; \ }; \ $(am__cd) '$(distuninstallcheck_dir)' || { \ echo 'ERROR: cannot chdir into $(distuninstallcheck_dir)' >&2; \ exit 1; \ }; \ test `$(am__distuninstallcheck_listfiles) | wc -l` -eq 0 \ || { echo "ERROR: files left after uninstall:" ; \ if test -n "$(DESTDIR)"; then \ echo " (check DESTDIR support)"; \ fi ; \ $(distuninstallcheck_listfiles) ; \ exit 1; } >&2 distcleancheck: distclean @if test '$(srcdir)' = . ; then \ echo "ERROR: distcleancheck can only run from a VPATH build" ; \ exit 1 ; \ fi @test `$(distcleancheck_listfiles) | wc -l` -eq 0 \ || { echo "ERROR: files left in build directory after distclean:" ; \ $(distcleancheck_listfiles) ; \ exit 1; } >&2 check-am: all-am check: check-recursive all-am: Makefile config.h installdirs: installdirs-recursive installdirs-am: install: install-recursive install-exec: install-exec-recursive install-data: install-data-recursive uninstall: uninstall-recursive install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-recursive install-strip: if test -z '$(STRIP)'; then \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ install; \ else \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ fi mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-recursive clean-am: clean-generic clean-libtool mostlyclean-am distclean: distclean-recursive -rm -f $(am__CONFIG_DISTCLEAN_FILES) -rm -f Makefile distclean-am: clean-am distclean-generic distclean-hdr \ distclean-libtool distclean-tags dvi: dvi-recursive dvi-am: html: html-recursive html-am: info: info-recursive info-am: install-data-am: install-dvi: install-dvi-recursive install-dvi-am: install-exec-am: install-html: install-html-recursive install-html-am: install-info: install-info-recursive install-info-am: install-man: install-pdf: install-pdf-recursive install-pdf-am: install-ps: install-ps-recursive install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-recursive -rm -f $(am__CONFIG_DISTCLEAN_FILES) -rm -rf $(top_srcdir)/autom4te.cache -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-recursive mostlyclean-am: mostlyclean-generic mostlyclean-libtool pdf: pdf-recursive pdf-am: ps: ps-recursive ps-am: uninstall-am: .MAKE: $(am__recursive_targets) all install-am install-strip .PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am \ am--refresh check check-am clean clean-cscope clean-generic \ clean-libtool cscope cscopelist-am ctags ctags-am dist \ dist-all dist-bzip2 dist-gzip dist-lzip dist-shar dist-tarZ \ dist-xz dist-zip dist-zstd distcheck distclean \ distclean-generic distclean-hdr distclean-libtool \ distclean-tags distcleancheck distdir distuninstallcheck dvi \ dvi-am html html-am info info-am install install-am \ install-data install-data-am install-dvi install-dvi-am \ install-exec install-exec-am install-html install-html-am \ install-info install-info-am install-man install-pdf \ install-pdf-am install-ps install-ps-am install-strip \ installcheck installcheck-am installdirs installdirs-am \ maintainer-clean maintainer-clean-generic mostlyclean \ mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ tags tags-am uninstall uninstall-am .PRECIOUS: Makefile # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: httrack-3.49.5/aclocal.m40000644000175000017500000014354014555203170012046 00000000000000# generated automatically by aclocal 1.16.5 -*- Autoconf -*- # Copyright (C) 1996-2021 Free Software Foundation, Inc. # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])]) m4_ifndef([AC_AUTOCONF_VERSION], [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.71],, [m4_warning([this file was generated for autoconf 2.71. You have another version of autoconf. It may work, but is not guaranteed to. If you have problems, you may need to regenerate the build system entirely. To do so, use the procedure documented by the package, typically 'autoreconf'.])]) # ===================================================================================== # https://www.gnu.org/software/autoconf-archive/ax_check_aligned_access_required.html # ===================================================================================== # # SYNOPSIS # # AX_CHECK_ALIGNED_ACCESS_REQUIRED # # DESCRIPTION # # While the x86 CPUs allow access to memory objects to be unaligned it # happens that most of the modern designs require objects to be aligned - # or they will fail with a buserror. That mode is quite known by # big-endian machines (sparc, etc) however the alpha cpu is little- # endian. # # The following function will test for aligned access to be required and # set a config.h define HAVE_ALIGNED_ACCESS_REQUIRED (name derived by # standard usage). Structures loaded from a file (or mmapped to memory) # should be accessed per-byte in that case to avoid segfault type errors. # # The function checks if unaligned access would ignore the lowest bit of # the address. If that happens or if the test binary crashes, aligned # access is required. # # If cross-compiling, assume that aligned access is needed to be safe. Set # ax_cv_have_aligned_access_required=no to override that assumption. # # LICENSE # # Copyright (c) 2008 Guido U. Draheim # # Copying and distribution of this file, with or without modification, are # permitted in any medium without royalty provided the copyright notice # and this notice are preserved. This file is offered as-is, without any # warranty. #serial 11 AC_DEFUN([AX_CHECK_ALIGNED_ACCESS_REQUIRED], [AC_CACHE_CHECK([if pointers to integers require aligned access], [ax_cv_have_aligned_access_required], [AC_RUN_IFELSE([ AC_LANG_PROGRAM([[@%:@include ]], [[ int i; int *p; int *q; char *str; str = (char *) malloc(40); for (i = 0; i < 40; i++) { *(str + i) = i; } p = (int *) (str + 1); q = (int *) (str + 2); return (*p == *q); ]])], [ax_cv_have_aligned_access_required=no], [ax_cv_have_aligned_access_required=yes], [ax_cv_have_aligned_access_required=maybe])]) if test "x$ax_cv_have_aligned_access_required" = "xmaybe"; then AC_MSG_WARN([Assuming aligned access is required when cross-compiling]) ax_cv_have_aligned_access_required=yes fi if test "x$ax_cv_have_aligned_access_required" = "xyes"; then AC_DEFINE([HAVE_ALIGNED_ACCESS_REQUIRED], [1], [Define if pointers to integers require aligned access]) fi ]) # =========================================================================== # https://www.gnu.org/software/autoconf-archive/ax_check_compile_flag.html # =========================================================================== # # SYNOPSIS # # AX_CHECK_COMPILE_FLAG(FLAG, [ACTION-SUCCESS], [ACTION-FAILURE], [EXTRA-FLAGS], [INPUT]) # # DESCRIPTION # # Check whether the given FLAG works with the current language's compiler # or gives an error. (Warnings, however, are ignored) # # ACTION-SUCCESS/ACTION-FAILURE are shell commands to execute on # success/failure. # # If EXTRA-FLAGS is defined, it is added to the current language's default # flags (e.g. CFLAGS) when the check is done. The check is thus made with # the flags: "CFLAGS EXTRA-FLAGS FLAG". This can for example be used to # force the compiler to issue an error when a bad flag is given. # # INPUT gives an alternative input source to AC_COMPILE_IFELSE. # # NOTE: Implementation based on AX_CFLAGS_GCC_OPTION. Please keep this # macro in sync with AX_CHECK_{PREPROC,LINK}_FLAG. # # LICENSE # # Copyright (c) 2008 Guido U. Draheim # Copyright (c) 2011 Maarten Bosmans # # Copying and distribution of this file, with or without modification, are # permitted in any medium without royalty provided the copyright notice # and this notice are preserved. This file is offered as-is, without any # warranty. #serial 6 AC_DEFUN([AX_CHECK_COMPILE_FLAG], [AC_PREREQ(2.64)dnl for _AC_LANG_PREFIX and AS_VAR_IF AS_VAR_PUSHDEF([CACHEVAR],[ax_cv_check_[]_AC_LANG_ABBREV[]flags_$4_$1])dnl AC_CACHE_CHECK([whether _AC_LANG compiler accepts $1], CACHEVAR, [ ax_check_save_flags=$[]_AC_LANG_PREFIX[]FLAGS _AC_LANG_PREFIX[]FLAGS="$[]_AC_LANG_PREFIX[]FLAGS $4 $1" AC_COMPILE_IFELSE([m4_default([$5],[AC_LANG_PROGRAM()])], [AS_VAR_SET(CACHEVAR,[yes])], [AS_VAR_SET(CACHEVAR,[no])]) _AC_LANG_PREFIX[]FLAGS=$ax_check_save_flags]) AS_VAR_IF(CACHEVAR,yes, [m4_default([$2], :)], [m4_default([$3], :)]) AS_VAR_POPDEF([CACHEVAR])dnl ])dnl AX_CHECK_COMPILE_FLAGS # =========================================================================== # https://www.gnu.org/software/autoconf-archive/ax_check_link_flag.html # =========================================================================== # # SYNOPSIS # # AX_CHECK_LINK_FLAG(FLAG, [ACTION-SUCCESS], [ACTION-FAILURE], [EXTRA-FLAGS], [INPUT]) # # DESCRIPTION # # Check whether the given FLAG works with the linker or gives an error. # (Warnings, however, are ignored) # # ACTION-SUCCESS/ACTION-FAILURE are shell commands to execute on # success/failure. # # If EXTRA-FLAGS is defined, it is added to the linker's default flags # when the check is done. The check is thus made with the flags: "LDFLAGS # EXTRA-FLAGS FLAG". This can for example be used to force the linker to # issue an error when a bad flag is given. # # INPUT gives an alternative input source to AC_LINK_IFELSE. # # NOTE: Implementation based on AX_CFLAGS_GCC_OPTION. Please keep this # macro in sync with AX_CHECK_{PREPROC,COMPILE}_FLAG. # # LICENSE # # Copyright (c) 2008 Guido U. Draheim # Copyright (c) 2011 Maarten Bosmans # # Copying and distribution of this file, with or without modification, are # permitted in any medium without royalty provided the copyright notice # and this notice are preserved. This file is offered as-is, without any # warranty. #serial 6 AC_DEFUN([AX_CHECK_LINK_FLAG], [AC_PREREQ(2.64)dnl for _AC_LANG_PREFIX and AS_VAR_IF AS_VAR_PUSHDEF([CACHEVAR],[ax_cv_check_ldflags_$4_$1])dnl AC_CACHE_CHECK([whether the linker accepts $1], CACHEVAR, [ ax_check_save_flags=$LDFLAGS LDFLAGS="$LDFLAGS $4 $1" AC_LINK_IFELSE([m4_default([$5],[AC_LANG_PROGRAM()])], [AS_VAR_SET(CACHEVAR,[yes])], [AS_VAR_SET(CACHEVAR,[no])]) LDFLAGS=$ax_check_save_flags]) AS_VAR_IF(CACHEVAR,yes, [m4_default([$2], :)], [m4_default([$3], :)]) AS_VAR_POPDEF([CACHEVAR])dnl ])dnl AX_CHECK_LINK_FLAGS # Copyright (C) 2002-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_AUTOMAKE_VERSION(VERSION) # ---------------------------- # Automake X.Y traces this macro to ensure aclocal.m4 has been # generated from the m4 files accompanying Automake X.Y. # (This private macro should not be called outside this file.) AC_DEFUN([AM_AUTOMAKE_VERSION], [am__api_version='1.16' dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to dnl require some minimum version. Point them to the right macro. m4_if([$1], [1.16.5], [], [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl ]) # _AM_AUTOCONF_VERSION(VERSION) # ----------------------------- # aclocal traces this macro to find the Autoconf version. # This is a private macro too. Using m4_define simplifies # the logic in aclocal, which can simply ignore this definition. m4_define([_AM_AUTOCONF_VERSION], []) # AM_SET_CURRENT_AUTOMAKE_VERSION # ------------------------------- # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. # This function is AC_REQUIREd by AM_INIT_AUTOMAKE. AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], [AM_AUTOMAKE_VERSION([1.16.5])dnl m4_ifndef([AC_AUTOCONF_VERSION], [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) # AM_AUX_DIR_EXPAND -*- Autoconf -*- # Copyright (C) 2001-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets # $ac_aux_dir to '$srcdir/foo'. In other projects, it is set to # '$srcdir', '$srcdir/..', or '$srcdir/../..'. # # Of course, Automake must honor this variable whenever it calls a # tool from the auxiliary directory. The problem is that $srcdir (and # therefore $ac_aux_dir as well) can be either absolute or relative, # depending on how configure is run. This is pretty annoying, since # it makes $ac_aux_dir quite unusable in subdirectories: in the top # source directory, any form will work fine, but in subdirectories a # relative path needs to be adjusted first. # # $ac_aux_dir/missing # fails when called from a subdirectory if $ac_aux_dir is relative # $top_srcdir/$ac_aux_dir/missing # fails if $ac_aux_dir is absolute, # fails when called from a subdirectory in a VPATH build with # a relative $ac_aux_dir # # The reason of the latter failure is that $top_srcdir and $ac_aux_dir # are both prefixed by $srcdir. In an in-source build this is usually # harmless because $srcdir is '.', but things will broke when you # start a VPATH build or use an absolute $srcdir. # # So we could use something similar to $top_srcdir/$ac_aux_dir/missing, # iff we strip the leading $srcdir from $ac_aux_dir. That would be: # am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"` # and then we would define $MISSING as # MISSING="\${SHELL} $am_aux_dir/missing" # This will work as long as MISSING is not called from configure, because # unfortunately $(top_srcdir) has no meaning in configure. # However there are other variables, like CC, which are often used in # configure, and could therefore not use this "fixed" $ac_aux_dir. # # Another solution, used here, is to always expand $ac_aux_dir to an # absolute PATH. The drawback is that using absolute paths prevent a # configured tree to be moved without reconfiguration. AC_DEFUN([AM_AUX_DIR_EXPAND], [AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl # Expand $ac_aux_dir to an absolute path. am_aux_dir=`cd "$ac_aux_dir" && pwd` ]) # AM_CONDITIONAL -*- Autoconf -*- # Copyright (C) 1997-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_CONDITIONAL(NAME, SHELL-CONDITION) # ------------------------------------- # Define a conditional. AC_DEFUN([AM_CONDITIONAL], [AC_PREREQ([2.52])dnl m4_if([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl AC_SUBST([$1_TRUE])dnl AC_SUBST([$1_FALSE])dnl _AM_SUBST_NOTMAKE([$1_TRUE])dnl _AM_SUBST_NOTMAKE([$1_FALSE])dnl m4_define([_AM_COND_VALUE_$1], [$2])dnl if $2; then $1_TRUE= $1_FALSE='#' else $1_TRUE='#' $1_FALSE= fi AC_CONFIG_COMMANDS_PRE( [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then AC_MSG_ERROR([[conditional "$1" was never defined. Usually this means the macro was only invoked conditionally.]]) fi])]) # Copyright (C) 1999-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # There are a few dirty hacks below to avoid letting 'AC_PROG_CC' be # written in clear, in which case automake, when reading aclocal.m4, # will think it sees a *use*, and therefore will trigger all it's # C support machinery. Also note that it means that autoscan, seeing # CC etc. in the Makefile, will ask for an AC_PROG_CC use... # _AM_DEPENDENCIES(NAME) # ---------------------- # See how the compiler implements dependency checking. # NAME is "CC", "CXX", "OBJC", "OBJCXX", "UPC", or "GJC". # We try a few techniques and use that to set a single cache variable. # # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular # dependency, and given that the user is not expected to run this macro, # just rely on AC_PROG_CC. AC_DEFUN([_AM_DEPENDENCIES], [AC_REQUIRE([AM_SET_DEPDIR])dnl AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl AC_REQUIRE([AM_MAKE_INCLUDE])dnl AC_REQUIRE([AM_DEP_TRACK])dnl m4_if([$1], [CC], [depcc="$CC" am_compiler_list=], [$1], [CXX], [depcc="$CXX" am_compiler_list=], [$1], [OBJC], [depcc="$OBJC" am_compiler_list='gcc3 gcc'], [$1], [OBJCXX], [depcc="$OBJCXX" am_compiler_list='gcc3 gcc'], [$1], [UPC], [depcc="$UPC" am_compiler_list=], [$1], [GCJ], [depcc="$GCJ" am_compiler_list='gcc3 gcc'], [depcc="$$1" am_compiler_list=]) AC_CACHE_CHECK([dependency style of $depcc], [am_cv_$1_dependencies_compiler_type], [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up # making a dummy file named 'D' -- because '-MD' means "put the output # in D". rm -rf conftest.dir mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. cp "$am_depcomp" conftest.dir cd conftest.dir # We will build objects and dependencies in a subdirectory because # it helps to detect inapplicable dependency modes. For instance # both Tru64's cc and ICC support -MD to output dependencies as a # side effect of compilation, but ICC will put the dependencies in # the current directory while Tru64 will put them in the object # directory. mkdir sub am_cv_$1_dependencies_compiler_type=none if test "$am_compiler_list" = ""; then am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp` fi am__universal=false m4_case([$1], [CC], [case " $depcc " in #( *\ -arch\ *\ -arch\ *) am__universal=true ;; esac], [CXX], [case " $depcc " in #( *\ -arch\ *\ -arch\ *) am__universal=true ;; esac]) for depmode in $am_compiler_list; do # Setup a source with many dependencies, because some compilers # like to wrap large dependency lists on column 80 (with \), and # we should not choose a depcomp mode which is confused by this. # # We need to recreate these files for each test, as the compiler may # overwrite some of them when testing with obscure command lines. # This happens at least with the AIX C compiler. : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with # Solaris 10 /bin/sh. echo '/* dummy */' > sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf # We check with '-c' and '-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly # handle '-M -o', and we need to detect this. Also, some Intel # versions had trouble with output in subdirs. am__obj=sub/conftest.${OBJEXT-o} am__minus_obj="-o $am__obj" case $depmode in gcc) # This depmode causes a compiler race in universal mode. test "$am__universal" = false || continue ;; nosideeffect) # After this tag, mechanisms are not by side-effect, so they'll # only be used when explicitly requested. if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; msvc7 | msvc7msys | msvisualcpp | msvcmsys) # This compiler won't grok '-c -o', but also, the minuso test has # not run yet. These depmodes are late enough in the game, and # so weak that their functioning should not be impacted. am__obj=conftest.${OBJEXT-o} am__minus_obj= ;; none) break ;; esac if depmode=$depmode \ source=sub/conftest.c object=$am__obj \ depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ >/dev/null 2>conftest.err && grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && grep $am__obj sub/conftest.Po > /dev/null 2>&1 && ${MAKE-make} -s -f confmf > /dev/null 2>&1; then # icc doesn't choke on unknown options, it will just issue warnings # or remarks (even with -Werror). So we grep stderr for any message # that says an option was ignored or not supported. # When given -MP, icc 7.0 and 7.1 complain thusly: # icc: Command line warning: ignoring option '-M'; no argument required # The diagnosis changed in icc 8.0: # icc: Command line remark: option '-MP' not supported if (grep 'ignoring option' conftest.err || grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else am_cv_$1_dependencies_compiler_type=$depmode break fi fi done cd .. rm -rf conftest.dir else am_cv_$1_dependencies_compiler_type=none fi ]) AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type]) AM_CONDITIONAL([am__fastdep$1], [ test "x$enable_dependency_tracking" != xno \ && test "$am_cv_$1_dependencies_compiler_type" = gcc3]) ]) # AM_SET_DEPDIR # ------------- # Choose a directory name for dependency files. # This macro is AC_REQUIREd in _AM_DEPENDENCIES. AC_DEFUN([AM_SET_DEPDIR], [AC_REQUIRE([AM_SET_LEADING_DOT])dnl AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl ]) # AM_DEP_TRACK # ------------ AC_DEFUN([AM_DEP_TRACK], [AC_ARG_ENABLE([dependency-tracking], [dnl AS_HELP_STRING( [--enable-dependency-tracking], [do not reject slow dependency extractors]) AS_HELP_STRING( [--disable-dependency-tracking], [speeds up one-time build])]) if test "x$enable_dependency_tracking" != xno; then am_depcomp="$ac_aux_dir/depcomp" AMDEPBACKSLASH='\' am__nodep='_no' fi AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) AC_SUBST([AMDEPBACKSLASH])dnl _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl AC_SUBST([am__nodep])dnl _AM_SUBST_NOTMAKE([am__nodep])dnl ]) # Generate code to set up dependency tracking. -*- Autoconf -*- # Copyright (C) 1999-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # _AM_OUTPUT_DEPENDENCY_COMMANDS # ------------------------------ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], [{ # Older Autoconf quotes --file arguments for eval, but not when files # are listed without --file. Let's play safe and only enable the eval # if we detect the quoting. # TODO: see whether this extra hack can be removed once we start # requiring Autoconf 2.70 or later. AS_CASE([$CONFIG_FILES], [*\'*], [eval set x "$CONFIG_FILES"], [*], [set x $CONFIG_FILES]) shift # Used to flag and report bootstrapping failures. am_rc=0 for am_mf do # Strip MF so we end up with the name of the file. am_mf=`AS_ECHO(["$am_mf"]) | sed -e 's/:.*$//'` # Check whether this is an Automake generated Makefile which includes # dependency-tracking related rules and includes. # Grep'ing the whole file directly is not great: AIX grep has a line # limit of 2048, but all sed's we know have understand at least 4000. sed -n 's,^am--depfiles:.*,X,p' "$am_mf" | grep X >/dev/null 2>&1 \ || continue am_dirpart=`AS_DIRNAME(["$am_mf"])` am_filepart=`AS_BASENAME(["$am_mf"])` AM_RUN_LOG([cd "$am_dirpart" \ && sed -e '/# am--include-marker/d' "$am_filepart" \ | $MAKE -f - am--depfiles]) || am_rc=$? done if test $am_rc -ne 0; then AC_MSG_FAILURE([Something went wrong bootstrapping makefile fragments for automatic dependency tracking. If GNU make was not used, consider re-running the configure script with MAKE="gmake" (or whatever is necessary). You can also try re-running configure with the '--disable-dependency-tracking' option to at least be able to build the package (albeit without support for automatic dependency tracking).]) fi AS_UNSET([am_dirpart]) AS_UNSET([am_filepart]) AS_UNSET([am_mf]) AS_UNSET([am_rc]) rm -f conftest-deps.mk } ])# _AM_OUTPUT_DEPENDENCY_COMMANDS # AM_OUTPUT_DEPENDENCY_COMMANDS # ----------------------------- # This macro should only be invoked once -- use via AC_REQUIRE. # # This code is only required when automatic dependency tracking is enabled. # This creates each '.Po' and '.Plo' makefile fragment that we'll need in # order to bootstrap the dependency handling code. AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], [AC_CONFIG_COMMANDS([depfiles], [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], [AMDEP_TRUE="$AMDEP_TRUE" MAKE="${MAKE-make}"])]) # Do all the work for Automake. -*- Autoconf -*- # Copyright (C) 1996-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This macro actually does too much. Some checks are only needed if # your package does certain things. But this isn't really a big deal. dnl Redefine AC_PROG_CC to automatically invoke _AM_PROG_CC_C_O. m4_define([AC_PROG_CC], m4_defn([AC_PROG_CC]) [_AM_PROG_CC_C_O ]) # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) # AM_INIT_AUTOMAKE([OPTIONS]) # ----------------------------------------------- # The call with PACKAGE and VERSION arguments is the old style # call (pre autoconf-2.50), which is being phased out. PACKAGE # and VERSION should now be passed to AC_INIT and removed from # the call to AM_INIT_AUTOMAKE. # We support both call styles for the transition. After # the next Automake release, Autoconf can make the AC_INIT # arguments mandatory, and then we can depend on a new Autoconf # release and drop the old call support. AC_DEFUN([AM_INIT_AUTOMAKE], [AC_PREREQ([2.65])dnl m4_ifdef([_$0_ALREADY_INIT], [m4_fatal([$0 expanded multiple times ]m4_defn([_$0_ALREADY_INIT]))], [m4_define([_$0_ALREADY_INIT], m4_expansion_stack)])dnl dnl Autoconf wants to disallow AM_ names. We explicitly allow dnl the ones we care about. m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl AC_REQUIRE([AC_PROG_INSTALL])dnl if test "`cd $srcdir && pwd`" != "`pwd`"; then # Use -I$(srcdir) only when $(srcdir) != ., so that make's output # is not polluted with repeated "-I." AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl # test to see if srcdir already configured if test -f $srcdir/config.status; then AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) fi fi # test whether we have cygpath if test -z "$CYGPATH_W"; then if (cygpath --version) >/dev/null 2>/dev/null; then CYGPATH_W='cygpath -w' else CYGPATH_W=echo fi fi AC_SUBST([CYGPATH_W]) # Define the identity of the package. dnl Distinguish between old-style and new-style calls. m4_ifval([$2], [AC_DIAGNOSE([obsolete], [$0: two- and three-arguments forms are deprecated.]) m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl AC_SUBST([PACKAGE], [$1])dnl AC_SUBST([VERSION], [$2])], [_AM_SET_OPTIONS([$1])dnl dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. m4_if( m4_ifset([AC_PACKAGE_NAME], [ok]):m4_ifset([AC_PACKAGE_VERSION], [ok]), [ok:ok],, [m4_fatal([AC_INIT should be called with package and version arguments])])dnl AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl _AM_IF_OPTION([no-define],, [AC_DEFINE_UNQUOTED([PACKAGE], ["$PACKAGE"], [Name of package]) AC_DEFINE_UNQUOTED([VERSION], ["$VERSION"], [Version number of package])])dnl # Some tools Automake needs. AC_REQUIRE([AM_SANITY_CHECK])dnl AC_REQUIRE([AC_ARG_PROGRAM])dnl AM_MISSING_PROG([ACLOCAL], [aclocal-${am__api_version}]) AM_MISSING_PROG([AUTOCONF], [autoconf]) AM_MISSING_PROG([AUTOMAKE], [automake-${am__api_version}]) AM_MISSING_PROG([AUTOHEADER], [autoheader]) AM_MISSING_PROG([MAKEINFO], [makeinfo]) AC_REQUIRE([AM_PROG_INSTALL_SH])dnl AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl AC_REQUIRE([AC_PROG_MKDIR_P])dnl # For better backward compatibility. To be removed once Automake 1.9.x # dies out for good. For more background, see: # # AC_SUBST([mkdir_p], ['$(MKDIR_P)']) # We need awk for the "check" target (and possibly the TAP driver). The # system "awk" is bad on some platforms. AC_REQUIRE([AC_PROG_AWK])dnl AC_REQUIRE([AC_PROG_MAKE_SET])dnl AC_REQUIRE([AM_SET_LEADING_DOT])dnl _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], [_AM_PROG_TAR([v7])])]) _AM_IF_OPTION([no-dependencies],, [AC_PROVIDE_IFELSE([AC_PROG_CC], [_AM_DEPENDENCIES([CC])], [m4_define([AC_PROG_CC], m4_defn([AC_PROG_CC])[_AM_DEPENDENCIES([CC])])])dnl AC_PROVIDE_IFELSE([AC_PROG_CXX], [_AM_DEPENDENCIES([CXX])], [m4_define([AC_PROG_CXX], m4_defn([AC_PROG_CXX])[_AM_DEPENDENCIES([CXX])])])dnl AC_PROVIDE_IFELSE([AC_PROG_OBJC], [_AM_DEPENDENCIES([OBJC])], [m4_define([AC_PROG_OBJC], m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl AC_PROVIDE_IFELSE([AC_PROG_OBJCXX], [_AM_DEPENDENCIES([OBJCXX])], [m4_define([AC_PROG_OBJCXX], m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl ]) # Variables for tags utilities; see am/tags.am if test -z "$CTAGS"; then CTAGS=ctags fi AC_SUBST([CTAGS]) if test -z "$ETAGS"; then ETAGS=etags fi AC_SUBST([ETAGS]) if test -z "$CSCOPE"; then CSCOPE=cscope fi AC_SUBST([CSCOPE]) AC_REQUIRE([AM_SILENT_RULES])dnl dnl The testsuite driver may need to know about EXEEXT, so add the dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below. AC_CONFIG_COMMANDS_PRE(dnl [m4_provide_if([_AM_COMPILER_EXEEXT], [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl # POSIX will say in a future version that running "rm -f" with no argument # is OK; and we want to be able to make that assumption in our Makefile # recipes. So use an aggressive probe to check that the usage we want is # actually supported "in the wild" to an acceptable degree. # See automake bug#10828. # To make any issue more visible, cause the running configure to be aborted # by default if the 'rm' program in use doesn't match our expectations; the # user can still override this though. if rm -f && rm -fr && rm -rf; then : OK; else cat >&2 <<'END' Oops! Your 'rm' program seems unable to run without file operands specified on the command line, even when the '-f' option is present. This is contrary to the behaviour of most rm programs out there, and not conforming with the upcoming POSIX standard: Please tell bug-automake@gnu.org about your system, including the value of your $PATH and any error possibly output before this message. This can help us improve future automake versions. END if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then echo 'Configuration will proceed anyway, since you have set the' >&2 echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 echo >&2 else cat >&2 <<'END' Aborting the configuration process, to ensure you take notice of the issue. You can download and install GNU coreutils to get an 'rm' implementation that behaves properly: . If you want to complete the configuration process using your problematic 'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM to "yes", and re-run configure. END AC_MSG_ERROR([Your 'rm' program is bad, sorry.]) fi fi dnl The trailing newline in this macro's definition is deliberate, for dnl backward compatibility and to allow trailing 'dnl'-style comments dnl after the AM_INIT_AUTOMAKE invocation. See automake bug#16841. ]) dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion. Do not dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further dnl mangled by Autoconf and run in a shell conditional statement. m4_define([_AC_COMPILER_EXEEXT], m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])]) # When config.status generates a header, we must update the stamp-h file. # This file resides in the same directory as the config header # that is generated. The stamp files are numbered to have different names. # Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the # loop where config.status creates the headers, so we can generate # our stamp files there. AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], [# Compute $1's index in $config_headers. _am_arg=$1 _am_stamp_count=1 for _am_header in $config_headers :; do case $_am_header in $_am_arg | $_am_arg:* ) break ;; * ) _am_stamp_count=`expr $_am_stamp_count + 1` ;; esac done echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) # Copyright (C) 2001-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_PROG_INSTALL_SH # ------------------ # Define $install_sh. AC_DEFUN([AM_PROG_INSTALL_SH], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl if test x"${install_sh+set}" != xset; then case $am_aux_dir in *\ * | *\ *) install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; *) install_sh="\${SHELL} $am_aux_dir/install-sh" esac fi AC_SUBST([install_sh])]) # Copyright (C) 2003-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # Check whether the underlying file-system supports filenames # with a leading dot. For instance MS-DOS doesn't. AC_DEFUN([AM_SET_LEADING_DOT], [rm -rf .tst 2>/dev/null mkdir .tst 2>/dev/null if test -d .tst; then am__leading_dot=. else am__leading_dot=_ fi rmdir .tst 2>/dev/null AC_SUBST([am__leading_dot])]) # Add --enable-maintainer-mode option to configure. -*- Autoconf -*- # From Jim Meyering # Copyright (C) 1996-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_MAINTAINER_MODE([DEFAULT-MODE]) # ---------------------------------- # Control maintainer-specific portions of Makefiles. # Default is to disable them, unless 'enable' is passed literally. # For symmetry, 'disable' may be passed as well. Anyway, the user # can override the default with the --enable/--disable switch. AC_DEFUN([AM_MAINTAINER_MODE], [m4_case(m4_default([$1], [disable]), [enable], [m4_define([am_maintainer_other], [disable])], [disable], [m4_define([am_maintainer_other], [enable])], [m4_define([am_maintainer_other], [enable]) m4_warn([syntax], [unexpected argument to AM@&t@_MAINTAINER_MODE: $1])]) AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles]) dnl maintainer-mode's default is 'disable' unless 'enable' is passed AC_ARG_ENABLE([maintainer-mode], [AS_HELP_STRING([--]am_maintainer_other[-maintainer-mode], am_maintainer_other[ make rules and dependencies not useful (and sometimes confusing) to the casual installer])], [USE_MAINTAINER_MODE=$enableval], [USE_MAINTAINER_MODE=]m4_if(am_maintainer_other, [enable], [no], [yes])) AC_MSG_RESULT([$USE_MAINTAINER_MODE]) AM_CONDITIONAL([MAINTAINER_MODE], [test $USE_MAINTAINER_MODE = yes]) MAINT=$MAINTAINER_MODE_TRUE AC_SUBST([MAINT])dnl ] ) # Check to see how 'make' treats includes. -*- Autoconf -*- # Copyright (C) 2001-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_MAKE_INCLUDE() # ----------------- # Check whether make has an 'include' directive that can support all # the idioms we need for our automatic dependency tracking code. AC_DEFUN([AM_MAKE_INCLUDE], [AC_MSG_CHECKING([whether ${MAKE-make} supports the include directive]) cat > confinc.mk << 'END' am__doit: @echo this is the am__doit target >confinc.out .PHONY: am__doit END am__include="#" am__quote= # BSD make does it like this. echo '.include "confinc.mk" # ignored' > confmf.BSD # Other make implementations (GNU, Solaris 10, AIX) do it like this. echo 'include confinc.mk # ignored' > confmf.GNU _am_result=no for s in GNU BSD; do AM_RUN_LOG([${MAKE-make} -f confmf.$s && cat confinc.out]) AS_CASE([$?:`cat confinc.out 2>/dev/null`], ['0:this is the am__doit target'], [AS_CASE([$s], [BSD], [am__include='.include' am__quote='"'], [am__include='include' am__quote=''])]) if test "$am__include" != "#"; then _am_result="yes ($s style)" break fi done rm -f confinc.* confmf.* AC_MSG_RESULT([${_am_result}]) AC_SUBST([am__include])]) AC_SUBST([am__quote])]) # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- # Copyright (C) 1997-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_MISSING_PROG(NAME, PROGRAM) # ------------------------------ AC_DEFUN([AM_MISSING_PROG], [AC_REQUIRE([AM_MISSING_HAS_RUN]) $1=${$1-"${am_missing_run}$2"} AC_SUBST($1)]) # AM_MISSING_HAS_RUN # ------------------ # Define MISSING if not defined so far and test if it is modern enough. # If it is, set am_missing_run to use it, otherwise, to nothing. AC_DEFUN([AM_MISSING_HAS_RUN], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl AC_REQUIRE_AUX_FILE([missing])dnl if test x"${MISSING+set}" != xset; then MISSING="\${SHELL} '$am_aux_dir/missing'" fi # Use eval to expand $SHELL if eval "$MISSING --is-lightweight"; then am_missing_run="$MISSING " else am_missing_run= AC_MSG_WARN(['missing' script is too old or missing]) fi ]) # Helper functions for option handling. -*- Autoconf -*- # Copyright (C) 2001-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # _AM_MANGLE_OPTION(NAME) # ----------------------- AC_DEFUN([_AM_MANGLE_OPTION], [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) # _AM_SET_OPTION(NAME) # -------------------- # Set option NAME. Presently that only means defining a flag for this option. AC_DEFUN([_AM_SET_OPTION], [m4_define(_AM_MANGLE_OPTION([$1]), [1])]) # _AM_SET_OPTIONS(OPTIONS) # ------------------------ # OPTIONS is a space-separated list of Automake options. AC_DEFUN([_AM_SET_OPTIONS], [m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) # ------------------------------------------- # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. AC_DEFUN([_AM_IF_OPTION], [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) # Copyright (C) 1999-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # _AM_PROG_CC_C_O # --------------- # Like AC_PROG_CC_C_O, but changed for automake. We rewrite AC_PROG_CC # to automatically call this. AC_DEFUN([_AM_PROG_CC_C_O], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl AC_REQUIRE_AUX_FILE([compile])dnl AC_LANG_PUSH([C])dnl AC_CACHE_CHECK( [whether $CC understands -c and -o together], [am_cv_prog_cc_c_o], [AC_LANG_CONFTEST([AC_LANG_PROGRAM([])]) # Make sure it works both with $CC and with simple cc. # Following AC_PROG_CC_C_O, we do the test twice because some # compilers refuse to overwrite an existing .o file with -o, # though they will create one. am_cv_prog_cc_c_o=yes for am_i in 1 2; do if AM_RUN_LOG([$CC -c conftest.$ac_ext -o conftest2.$ac_objext]) \ && test -f conftest2.$ac_objext; then : OK else am_cv_prog_cc_c_o=no break fi done rm -f core conftest* unset am_i]) if test "$am_cv_prog_cc_c_o" != yes; then # Losing compiler, so override with the script. # FIXME: It is wrong to rewrite CC. # But if we don't then we get into trouble of one sort or another. # A longer-term fix would be to have automake use am__CC in this case, # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" CC="$am_aux_dir/compile $CC" fi AC_LANG_POP([C])]) # For backward compatibility. AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])]) # Copyright (C) 2001-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_RUN_LOG(COMMAND) # ------------------- # Run COMMAND, save the exit status in ac_status, and log it. # (This has been adapted from Autoconf's _AC_RUN_LOG macro.) AC_DEFUN([AM_RUN_LOG], [{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD (exit $ac_status); }]) # Check to make sure that the build environment is sane. -*- Autoconf -*- # Copyright (C) 1996-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_SANITY_CHECK # --------------- AC_DEFUN([AM_SANITY_CHECK], [AC_MSG_CHECKING([whether build environment is sane]) # Reject unsafe characters in $srcdir or the absolute working directory # name. Accept space and tab only in the latter. am_lf=' ' case `pwd` in *[[\\\"\#\$\&\'\`$am_lf]]*) AC_MSG_ERROR([unsafe absolute working directory name]);; esac case $srcdir in *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*) AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);; esac # Do 'set' in a subshell so we don't clobber the current shell's # arguments. Must try -L first in case configure is actually a # symlink; some systems play weird games with the mod time of symlinks # (eg FreeBSD returns the mod time of the symlink's containing # directory). if ( am_has_slept=no for am_try in 1 2; do echo "timestamp, slept: $am_has_slept" > conftest.file set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` if test "$[*]" = "X"; then # -L didn't work. set X `ls -t "$srcdir/configure" conftest.file` fi if test "$[*]" != "X $srcdir/configure conftest.file" \ && test "$[*]" != "X conftest.file $srcdir/configure"; then # If neither matched, then we have a broken ls. This can happen # if, for instance, CONFIG_SHELL is bash and it inherits a # broken ls alias from the environment. This has actually # happened. Such a system could not be considered "sane". AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken alias in your environment]) fi if test "$[2]" = conftest.file || test $am_try -eq 2; then break fi # Just in case. sleep 1 am_has_slept=yes done test "$[2]" = conftest.file ) then # Ok. : else AC_MSG_ERROR([newly created file is older than distributed files! Check your system clock]) fi AC_MSG_RESULT([yes]) # If we didn't sleep, we still need to ensure time stamps of config.status and # generated files are strictly newer. am_sleep_pid= if grep 'slept: no' conftest.file >/dev/null 2>&1; then ( sleep 1 ) & am_sleep_pid=$! fi AC_CONFIG_COMMANDS_PRE( [AC_MSG_CHECKING([that generated files are newer than configure]) if test -n "$am_sleep_pid"; then # Hide warnings about reused PIDs. wait $am_sleep_pid 2>/dev/null fi AC_MSG_RESULT([done])]) rm -f conftest.file ]) # Copyright (C) 2009-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_SILENT_RULES([DEFAULT]) # -------------------------- # Enable less verbose build rules; with the default set to DEFAULT # ("yes" being less verbose, "no" or empty being verbose). AC_DEFUN([AM_SILENT_RULES], [AC_ARG_ENABLE([silent-rules], [dnl AS_HELP_STRING( [--enable-silent-rules], [less verbose build output (undo: "make V=1")]) AS_HELP_STRING( [--disable-silent-rules], [verbose build output (undo: "make V=0")])dnl ]) case $enable_silent_rules in @%:@ ((( yes) AM_DEFAULT_VERBOSITY=0;; no) AM_DEFAULT_VERBOSITY=1;; *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);; esac dnl dnl A few 'make' implementations (e.g., NonStop OS and NextStep) dnl do not support nested variable expansions. dnl See automake bug#9928 and bug#10237. am_make=${MAKE-make} AC_CACHE_CHECK([whether $am_make supports nested variables], [am_cv_make_support_nested_variables], [if AS_ECHO([['TRUE=$(BAR$(V)) BAR0=false BAR1=true V=1 am__doit: @$(TRUE) .PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then am_cv_make_support_nested_variables=yes else am_cv_make_support_nested_variables=no fi]) if test $am_cv_make_support_nested_variables = yes; then dnl Using '$V' instead of '$(V)' breaks IRIX make. AM_V='$(V)' AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' else AM_V=$AM_DEFAULT_VERBOSITY AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY fi AC_SUBST([AM_V])dnl AM_SUBST_NOTMAKE([AM_V])dnl AC_SUBST([AM_DEFAULT_V])dnl AM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl AC_SUBST([AM_DEFAULT_VERBOSITY])dnl AM_BACKSLASH='\' AC_SUBST([AM_BACKSLASH])dnl _AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl ]) # Copyright (C) 2001-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_PROG_INSTALL_STRIP # --------------------- # One issue with vendor 'install' (even GNU) is that you can't # specify the program used to strip binaries. This is especially # annoying in cross-compiling environments, where the build's strip # is unlikely to handle the host's binaries. # Fortunately install-sh will honor a STRIPPROG variable, so we # always use install-sh in "make install-strip", and initialize # STRIPPROG with the value of the STRIP variable (set by the user). AC_DEFUN([AM_PROG_INSTALL_STRIP], [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl # Installed binaries are usually stripped using 'strip' when the user # run "make install-strip". However 'strip' might not be the right # tool to use in cross-compilation environments, therefore Automake # will honor the 'STRIP' environment variable to overrule this program. dnl Don't test for $cross_compiling = yes, because it might be 'maybe'. if test "$cross_compiling" != no; then AC_CHECK_TOOL([STRIP], [strip], :) fi INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" AC_SUBST([INSTALL_STRIP_PROGRAM])]) # Copyright (C) 2006-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # _AM_SUBST_NOTMAKE(VARIABLE) # --------------------------- # Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in. # This macro is traced by Automake. AC_DEFUN([_AM_SUBST_NOTMAKE]) # AM_SUBST_NOTMAKE(VARIABLE) # -------------------------- # Public sister of _AM_SUBST_NOTMAKE. AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) # Check how to create a tarball. -*- Autoconf -*- # Copyright (C) 2004-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # _AM_PROG_TAR(FORMAT) # -------------------- # Check how to create a tarball in format FORMAT. # FORMAT should be one of 'v7', 'ustar', or 'pax'. # # Substitute a variable $(am__tar) that is a command # writing to stdout a FORMAT-tarball containing the directory # $tardir. # tardir=directory && $(am__tar) > result.tar # # Substitute a variable $(am__untar) that extract such # a tarball read from stdin. # $(am__untar) < result.tar # AC_DEFUN([_AM_PROG_TAR], [# Always define AMTAR for backward compatibility. Yes, it's still used # in the wild :-( We should find a proper way to deprecate it ... AC_SUBST([AMTAR], ['$${TAR-tar}']) # We'll loop over all known methods to create a tar archive until one works. _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' m4_if([$1], [v7], [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'], [m4_case([$1], [ustar], [# The POSIX 1988 'ustar' format is defined with fixed-size fields. # There is notably a 21 bits limit for the UID and the GID. In fact, # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343 # and bug#13588). am_max_uid=2097151 # 2^21 - 1 am_max_gid=$am_max_uid # The $UID and $GID variables are not portable, so we need to resort # to the POSIX-mandated id(1) utility. Errors in the 'id' calls # below are definitely unexpected, so allow the users to see them # (that is, avoid stderr redirection). am_uid=`id -u || echo unknown` am_gid=`id -g || echo unknown` AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format]) if test $am_uid -le $am_max_uid; then AC_MSG_RESULT([yes]) else AC_MSG_RESULT([no]) _am_tools=none fi AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format]) if test $am_gid -le $am_max_gid; then AC_MSG_RESULT([yes]) else AC_MSG_RESULT([no]) _am_tools=none fi], [pax], [], [m4_fatal([Unknown tar format])]) AC_MSG_CHECKING([how to create a $1 tar archive]) # Go ahead even if we have the value already cached. We do so because we # need to set the values for the 'am__tar' and 'am__untar' variables. _am_tools=${am_cv_prog_tar_$1-$_am_tools} for _am_tool in $_am_tools; do case $_am_tool in gnutar) for _am_tar in tar gnutar gtar; do AM_RUN_LOG([$_am_tar --version]) && break done am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' am__untar="$_am_tar -xf -" ;; plaintar) # Must skip GNU tar: if it does not support --format= it doesn't create # ustar tarball either. (tar --version) >/dev/null 2>&1 && continue am__tar='tar chf - "$$tardir"' am__tar_='tar chf - "$tardir"' am__untar='tar xf -' ;; pax) am__tar='pax -L -x $1 -w "$$tardir"' am__tar_='pax -L -x $1 -w "$tardir"' am__untar='pax -r' ;; cpio) am__tar='find "$$tardir" -print | cpio -o -H $1 -L' am__tar_='find "$tardir" -print | cpio -o -H $1 -L' am__untar='cpio -i -H $1 -d' ;; none) am__tar=false am__tar_=false am__untar=false ;; esac # If the value was cached, stop now. We just wanted to have am__tar # and am__untar set. test -n "${am_cv_prog_tar_$1}" && break # tar/untar a dummy directory, and stop if the command works. rm -rf conftest.dir mkdir conftest.dir echo GrepMe > conftest.dir/file AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) rm -rf conftest.dir if test -s conftest.tar; then AM_RUN_LOG([$am__untar /dev/null 2>&1 && break fi done rm -rf conftest.dir AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) AC_MSG_RESULT([$am_cv_prog_tar_$1])]) AC_SUBST([am__tar]) AC_SUBST([am__untar]) ]) # _AM_PROG_TAR m4_include([m4/check_zlib.m4]) m4_include([m4/libtool.m4]) m4_include([m4/ltoptions.m4]) m4_include([m4/ltsugar.m4]) m4_include([m4/ltversion.m4]) m4_include([m4/lt~obsolete.m4]) m4_include([m4/snprintf.m4]) m4_include([m4/visibility.m4]) httrack-3.49.5/configure.ac0000644000175000017500000002233414555203161012471 00000000000000AC_PREREQ([2.71]) AC_INIT([httrack], [3.49.5], [roche+packaging@httrack.com], [httrack], [http://www.httrack.com/]) AC_COPYRIGHT([ HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2015 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com ]) AC_CONFIG_SRCDIR(src/httrack.c) AC_CONFIG_MACRO_DIR([m4]) AC_CONFIG_HEADERS(config.h) AM_INIT_AUTOMAKE([subdir-objects]) VERSION_INFO="2:49:0" AM_MAINTAINER_MODE AC_USE_SYSTEM_EXTENSIONS AC_PROG_CC AM_PROG_CC_C_O m4_warn([obsolete], [The preprocessor macro `STDC_HEADERS' is obsolete. Except in unusual embedded environments, you can safely include all ISO C90 headers unconditionally.])dnl # Autoupdate added the next two lines to ensure that your configure # script's behavior did not change. They are probably safe to remove. AC_CHECK_INCLUDES_DEFAULT AC_PROG_EGREP LT_INIT AC_PROG_LN_S LT_INIT # Export LD_LIBRARY_PATH name or equivalent. AC_SUBST(SHLIBPATH_VAR,$shlibpath_var) # Export .libs or equivalent. AC_SUBST(LT_CV_OBJDIR,$lt_cv_objdir) # Export version info AC_SUBST(VERSION_INFO) ### Default CFLAGS DEFAULT_CFLAGS="-Wall -Wformat -Wformat-security \ -Wmultichar -Wwrite-strings -Wcast-qual -Wcast-align \ -Wstrict-prototypes -Wmissing-prototypes \ -Wmissing-declarations -Wdeclaration-after-statement \ -Wpointer-arith -Wsequence-point -Wnested-externs \ -D_REENTRANT" AC_SUBST(DEFAULT_CFLAGS) DEFAULT_LDFLAGS="" AC_SUBST(DEFAULT_LDFLAGS) ### Additional flags (if supported) AX_CHECK_COMPILE_FLAG([-Wparentheses], [DEFAULT_CFLAGS="$DEFAULT_CFLAGS -Wparentheses"]) AX_CHECK_COMPILE_FLAG([-Winit-self], [DEFAULT_CFLAGS="$DEFAULT_CFLAGS -Winit-self"]) AX_CHECK_COMPILE_FLAG([-Wunused-but-set-parameter], [DEFAULT_CFLAGS="$DEFAULT_CFLAGS -Wunused-but-set-parameter"]) AX_CHECK_COMPILE_FLAG([-Waddress], [DEFAULT_CFLAGS="$DEFAULT_CFLAGS -Waddress"]) AX_CHECK_COMPILE_FLAG([-Wuninitialized], [DEFAULT_CFLAGS="$DEFAULT_CFLAGS -Wuninitialized"]) AX_CHECK_COMPILE_FLAG([-Wformat=2], [DEFAULT_CFLAGS="$DEFAULT_CFLAGS -Wformat=2"]) AX_CHECK_COMPILE_FLAG([-Wformat-nonliteral], [DEFAULT_CFLAGS="$DEFAULT_CFLAGS -Wformat-nonliteral"]) AX_CHECK_COMPILE_FLAG([-Wmissing-parameter-type], [DEFAULT_CFLAGS="$DEFAULT_CFLAGS -Wmissing-parameter-type"]) AX_CHECK_COMPILE_FLAG([-Wold-style-definition], [DEFAULT_CFLAGS="$DEFAULT_CFLAGS -Wold-style-definition"]) AX_CHECK_COMPILE_FLAG([-Wignored-qualifiers], [DEFAULT_CFLAGS="$DEFAULT_CFLAGS -Wignored-qualifiers"]) AX_CHECK_COMPILE_FLAG([-fstrict-aliasing -Wstrict-aliasing], [DEFAULT_CFLAGS="$DEFAULT_CFLAGS -fstrict-aliasing -Wstrict-aliasing"]) AX_CHECK_COMPILE_FLAG([-fstack-protector], [DEFAULT_CFLAGS="$DEFAULT_CFLAGS -fstack-protector"]) AX_CHECK_COMPILE_FLAG([-fstack-clash-protection], [DEFAULT_CFLAGS="$DEFAULT_CFLAGS -fstack-clash-protection"]) AX_CHECK_COMPILE_FLAG([-fcf-protection], [DEFAULT_CFLAGS="$DEFAULT_CFLAGS -fcf-protection"]) AX_CHECK_LINK_FLAG([-Wl,--discard-all], [DEFAULT_LDFLAGS="$DEFAULT_LDFLAGS -Wl,--discard-all"]) AX_CHECK_LINK_FLAG([-Wl,--no-undefined], [DEFAULT_LDFLAGS="$DEFAULT_LDFLAGS -Wl,--no-undefined"]) AX_CHECK_LINK_FLAG([-Wl,-z,relro,-z,now], [DEFAULT_LDFLAGS="$DEFAULT_LDFLAGS -Wl,-z,relro,-z,now"]) AX_CHECK_LINK_FLAG([-Wl,-z,noexecstack], [DEFAULT_LDFLAGS="$DEFAULT_LDFLAGS -Wl,-z,noexecstack"]) ### PIE CFLAGS_PIE="" LDFLAGS_PIE="" AX_CHECK_COMPILE_FLAG([-fpie -pie], [CFLAGS_PIE="-fpie -pie"]) AX_CHECK_LINK_FLAG([-pie], [LDFLAGS_PIE="-pie"]) AC_SUBST([CFLAGS_PIE]) AC_SUBST([LDFLAGS_PIE]) ## Export all symbols for backtraces AX_CHECK_COMPILE_FLAG([-rdynamic], [DEFAULT_CFLAGS="$DEFAULT_CFLAGS -rdynamic"]) ### Check for -fvisibility=hidden support gl_VISIBILITY AM_CFLAGS="$AM_CFLAGS $CFLAG_VISIBILITY" AC_SUBST([AM_CFLAGS]) ### Check for platform #case $host in #AIX) AC_DEFINE(HTS_PLATFORM, 1, [Defined to build under AIX]);; #*-solaris*) AC_DEFINE(HTS_PLATFORM, 2, [Defined to build under solaris]);; #*-linux-gnu | *-irix6*) AC_DEFINE(HTS_PLATFORM, 3, [Defined to build under Linux]);; #*) AC_DEFINE(HTS_PLATFORM, 3, [Default value used]);; #esac ### Check size of long and long long. AC_CHECK_SIZEOF(long) AC_CHECK_SIZEOF(long long) ### check for in_addr_t AC_CHECK_TYPE(in_addr_t, AC_DEFINE(HTS_DO_NOT_REDEFINE_in_addr_t,,[Check for in_addr_t]), AC_MSG_WARN([*** in_addr_t not found]), [#include #include #include ]) # check for in_port_ AC_CHECK_TYPE(in_port_t, [], [AC_DEFINE([in_port_t], [uint16_t], [in_port_t])], [ #include #include ]) # check for sa_family_t AC_CHECK_TYPE(sa_family_t, [], [AC_DEFINE([sa_family_t], [uint16_t], [sa_family_t])], [ #include #include ]) # check wether misaligned access is possible or not AX_CHECK_ALIGNED_ACCESS_REQUIRED # check for various headers AC_CHECK_HEADERS([execinfo.h]) ### zlib CHECK_ZLIB() ### OpenSSL is explicitly enabled/disabled ? AC_MSG_CHECKING(whether to enable https support) AC_ARG_ENABLE([https], [AS_HELP_STRING([--enable-https=@<:@yes/no/auto@:>@],[Enable https support @<:@default=yes@:>@])], [ case "${enableval}" in no|yes|auto) https_support=$enableval AC_MSG_RESULT($https_support) ;; *) AC_MSG_ERROR(bad value for https, expected yes/no/auto) ;; esac ], [ https_support=yes AC_MSG_RESULT($https_support) ]) AC_SUBST(HTTPS_SUPPORT,$https_support) # Probe OpenSSL ? if test x"$https_support" = x"no"; then AC_MSG_NOTICE([disabling https support]) AC_DEFINE(HTS_USEOPENSSL, 0) else SAVE_LIBS=$LIBS AC_CHECK_LIB(crypto, EVP_get_digestbyname, [ OPENSSL_LIBS="-lcrypto" ] ) LIBS="$LIBS $OPENSSL_LIBS" AC_CHECK_LIB(ssl, SSL_CTX_new, [ OPENSSL_LIBS="$OPENSSL_LIBS -lssl" AC_DEFINE(HTS_USEOPENSSL, 1, [Check for OpenSSL]) ], [ if test x"$https_support" = x"yes"; then AC_MSG_ERROR([not available]) else AC_MSG_RESULT([not available]) fi ] ) LIBS=$SAVE_LIBS AC_SUBST(OPENSSL_LIBS) fi ### Support IPv6 AC_CHECK_LIB(c, getaddrinfo, [V6_FLAG="-DINET6" AC_DEFINE(HTS_INET6, 1, [Check for IPv6])], AC_MSG_WARN([*** IPv6 not found IPv6 compatibility disabled])) AC_SUBST(V6_FLAG) ### Check for LFS AC_CHECK_LIB(c, fopen64, [LFS_FLAG="-D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE" AC_DEFINE(HTS_LFS, 1,[Check for large files support])], AC_MSG_RESULT([not found])) AC_SUBST(LFS_FLAG) ### Check for pthread AC_CHECK_LIB(pthread, pthread_create, [THREADS_LIBS=-lpthread AC_DEFINE(THREADS, 1,[Check for pthread])], AC_MSG_RESULT([not found])) AC_SUBST(THREADS_LIBS) if test x$THREADS_LIBS = x then AC_CHECK_LIB(c, pthread_create, [THREADS_LIBS= AC_DEFINE(THREADS, 1,[Check for pthread in c])], AC_MSG_RESULT([not found])) AC_SUBST(THREADS_LIBS) if test x$THREADS_LIBS = x then AC_CHECK_LIB(pthreads, pthread_create, [THREADS_LIBS= AC_DEFINE(THREADS, 1,[Check for pthread in pthreads])], AC_MSG_WARN([*** not found])) AC_SUBST(THREADS_LIBS) fi fi THREADS_CFLAGS= AC_SUBST(THREADS_CFLAGS) ### Check for socket/nsl (solaris) AC_CHECK_LIB(socket, socket, [SOCKET_LIBS="-lnsl -lsocket" AC_DEFINE(LIBSOCKET, 1,[Check for libsocket])], AC_MSG_RESULT([not necessary])) AC_SUBST(SOCKET_LIBS) ### Check for iconv AC_CHECK_LIB(iconv, iconv, [ICONV_LIBS="-liconv" AC_DEFINE(LIBICONV, 1,[Check for libiconv])], AC_MSG_RESULT([not necessary])) AC_SUBST(ICONV_LIBS) ### Check for dlsym AC_CHECK_LIB(dl, dlopen, [DL_LIBS=-ldl AC_DEFINE(DLLIB, 1,[Check for dl])], AC_MSG_RESULT([not found])) AC_SUBST(DL_LIBS) if test x$DL_LIBS = x then AC_CHECK_LIB(c, dlopen, [DL_LIBS= AC_DEFINE(DLLIB, 1,[Check for dlopen in c])], AC_MSG_WARN([*** not found * this is bad])) AC_SUBST(DL_LIBS) fi ### Check for setuid AC_CHECK_LIB(c, setuid, [ AC_DEFINE(SETUID, 1,[Check for setuid])], AC_MSG_RESULT([not found])) ### Check for snprintf AC_FUNC_SNPRINTF() ### Check for strnlen AC_CHECK_LIB(c, strnlen, [ AC_DEFINE(HAVE_STRNLEN, 1,[Check for strnlen])], AC_MSG_RESULT([not found])) ## Online unit tests AC_MSG_CHECKING(whether to enable online unit tests) AC_ARG_ENABLE([online-unit-tests], [AS_HELP_STRING([--enable-online-unit-tests=@<:@yes/no/auto@:>@],[Enable online-unit-tests @<:@default=yes@:>@])], [ case "${enableval}" in no|yes|auto) online_unit_tests=$enableval AC_MSG_RESULT($enableval) ;; *) AC_MSG_ERROR(bad value for online-unit-tests, expected yes/no/auto) ;; esac ], [ online_unit_tests=no AC_MSG_RESULT(no) ]) AC_SUBST(ONLINE_UNIT_TESTS,$online_unit_tests) # Final output AC_CONFIG_FILES([ Makefile src/Makefile man/Makefile m4/Makefile templates/Makefile lang/Makefile html/Makefile libtest/Makefile tests/Makefile ]) AC_OUTPUT httrack-3.49.5/configure0000755000175000017500000204023414555203173012116 00000000000000#! /bin/sh # Guess values for system-dependent variables and create Makefiles. # Generated by GNU Autoconf 2.71 for httrack 3.49.5. # # Report bugs to . # # # Copyright (C) 1992-1996, 1998-2017, 2020-2021 Free Software Foundation, # Inc. # # # This configure script is free software; the Free Software Foundation # gives unlimited permission to copy, distribute and modify it. # # # HTTrack Website Copier, Offline Browser for Windows and Unix # Copyright (C) 1998-2015 Xavier Roche and other contributors # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see . # # Important notes: # # - We hereby ask people using this source NOT to use it in purpose of grabbing # emails addresses, or collecting any other private information on persons. # This would disgrace our work, and spoil the many hours we spent on it. # # Please visit our Website: http://www.httrack.com # ## -------------------- ## ## M4sh Initialization. ## ## -------------------- ## # Be more Bourne compatible DUALCASE=1; export DUALCASE # for MKS sh as_nop=: if test ${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1 then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else $as_nop case `(set -o) 2>/dev/null` in #( *posix*) : set -o posix ;; #( *) : ;; esac fi # Reset variables that may have inherited troublesome values from # the environment. # IFS needs to be set, to space, tab, and newline, in precisely that order. # (If _AS_PATH_WALK were called with IFS unset, it would have the # side effect of setting IFS to empty, thus disabling word splitting.) # Quoting is to prevent editors from complaining about space-tab. as_nl=' ' export as_nl IFS=" "" $as_nl" PS1='$ ' PS2='> ' PS4='+ ' # Ensure predictable behavior from utilities with locale-dependent output. LC_ALL=C export LC_ALL LANGUAGE=C export LANGUAGE # We cannot yet rely on "unset" to work, but we need these variables # to be unset--not just set to an empty or harmless value--now, to # avoid bugs in old shells (e.g. pre-3.0 UWIN ksh). This construct # also avoids known problems related to "unset" and subshell syntax # in other old shells (e.g. bash 2.01 and pdksh 5.2.14). for as_var in BASH_ENV ENV MAIL MAILPATH CDPATH do eval test \${$as_var+y} \ && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : done # Ensure that fds 0, 1, and 2 are open. if (exec 3>&0) 2>/dev/null; then :; else exec 0&1) 2>/dev/null; then :; else exec 1>/dev/null; fi if (exec 3>&2) ; then :; else exec 2>/dev/null; fi # The user is always right. if ${PATH_SEPARATOR+false} :; then PATH_SEPARATOR=: (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || PATH_SEPARATOR=';' } fi # 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 for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac test -r "$as_dir$0" && as_myself=$as_dir$0 && break done IFS=$as_save_IFS ;; esac # We did not find ourselves, most probably we were run as `sh COMMAND' # in which case we are not to be found in the path. if test "x$as_myself" = x; then as_myself=$0 fi if test ! -f "$as_myself"; then printf "%s\n" "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 exit 1 fi # Use a proper internal environment variable to ensure we don't fall # into an infinite loop, continuously re-executing ourselves. if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then _as_can_reexec=no; export _as_can_reexec; # 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 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+"$@"} # Admittedly, this is quite paranoid, since all the known shells bail # out after a failed `exec'. printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2 exit 255 fi # We don't want this to propagate to other subprocesses. { _as_can_reexec=; unset _as_can_reexec;} if test "x$CONFIG_SHELL" = x; then as_bourne_compatible="as_nop=: if test \${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1 then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which # is contrary to our usage. Disable this feature. alias -g '\${1+\"\$@\"}'='\"\$@\"' setopt NO_GLOB_SUBST else \$as_nop case \`(set -o) 2>/dev/null\` in #( *posix*) : set -o posix ;; #( *) : ;; esac fi " as_required="as_fn_return () { (exit \$1); } as_fn_success () { as_fn_return 0; } as_fn_failure () { as_fn_return 1; } as_fn_ret_success () { return 0; } as_fn_ret_failure () { return 1; } exitcode=0 as_fn_success || { exitcode=1; echo as_fn_success failed.; } as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } if ( set x; as_fn_ret_success y && test x = \"\$1\" ) then : else \$as_nop exitcode=1; echo positional parameters were not saved. fi test x\$exitcode = x0 || exit 1 blah=\$(echo \$(echo blah)) test x\"\$blah\" = xblah || exit 1 test -x / || exit 1" as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 test \$(( 1 + 1 )) = 2 || exit 1 test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || ( ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO PATH=/empty FPATH=/empty; export PATH FPATH test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\ || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1" if (eval "$as_required") 2>/dev/null then : as_have_required=yes else $as_nop as_have_required=no fi if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null then : else $as_nop as_save_IFS=$IFS; IFS=$PATH_SEPARATOR as_found=false for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac as_found=: case $as_dir in #( /*) for as_base in sh bash ksh sh5; do # Try only shells that exist, to save several forks. as_shell=$as_dir$as_base if { test -f "$as_shell" || test -f "$as_shell.exe"; } && as_run=a "$as_shell" -c "$as_bourne_compatible""$as_required" 2>/dev/null then : CONFIG_SHELL=$as_shell as_have_required=yes if as_run=a "$as_shell" -c "$as_bourne_compatible""$as_suggested" 2>/dev/null then : break 2 fi fi done;; esac as_found=false done IFS=$as_save_IFS if $as_found then : else $as_nop if { test -f "$SHELL" || test -f "$SHELL.exe"; } && as_run=a "$SHELL" -c "$as_bourne_compatible""$as_required" 2>/dev/null then : CONFIG_SHELL=$SHELL as_have_required=yes fi fi if test "x$CONFIG_SHELL" != x then : export CONFIG_SHELL # 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 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+"$@"} # Admittedly, this is quite paranoid, since all the known shells bail # out after a failed `exec'. printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2 exit 255 fi if test x$as_have_required = xno then : printf "%s\n" "$0: This script requires a shell more modern than all" printf "%s\n" "$0: the shells that I found on your system." if test ${ZSH_VERSION+y} ; then printf "%s\n" "$0: In particular, zsh $ZSH_VERSION has bugs and should" printf "%s\n" "$0: be upgraded to zsh 4.3.4 or later." else printf "%s\n" "$0: Please tell bug-autoconf@gnu.org and $0: roche+packaging@httrack.com about your system, $0: including any error possibly output before this $0: message. Then install a modern shell, or manually run $0: the script under such a shell if you do have one." fi exit 1 fi fi fi SHELL=${CONFIG_SHELL-/bin/sh} export SHELL # Unset more variables known to interfere with behavior of common tools. CLICOLOR_FORCE= GREP_OPTIONS= unset CLICOLOR_FORCE GREP_OPTIONS ## --------------------- ## ## M4sh Shell Functions. ## ## --------------------- ## # as_fn_unset VAR # --------------- # Portably unset VAR. as_fn_unset () { { eval $1=; unset $1;} } as_unset=as_fn_unset # as_fn_set_status STATUS # ----------------------- # Set $? to STATUS, without forking. as_fn_set_status () { return $1 } # as_fn_set_status # as_fn_exit STATUS # ----------------- # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. as_fn_exit () { set +e as_fn_set_status $1 exit $1 } # as_fn_exit # as_fn_nop # --------- # Do nothing but, unlike ":", preserve the value of $?. as_fn_nop () { return $? } as_nop=as_fn_nop # as_fn_mkdir_p # ------------- # Create "$as_dir" as a directory, including parents if necessary. as_fn_mkdir_p () { case $as_dir in #( -*) as_dir=./$as_dir;; esac test -d "$as_dir" || eval $as_mkdir_p || { as_dirs= while :; do case $as_dir in #( *\'*) as_qdir=`printf "%s\n" "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( *) as_qdir=$as_dir;; esac as_dirs="'$as_qdir' $as_dirs" as_dir=`$as_dirname -- "$as_dir" || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || printf "%s\n" X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` test -d "$as_dir" && break done test -z "$as_dirs" || eval "mkdir $as_dirs" } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" } # as_fn_mkdir_p # as_fn_executable_p FILE # ----------------------- # Test if FILE is an executable regular file. as_fn_executable_p () { test -f "$1" && test -x "$1" } # as_fn_executable_p # as_fn_append VAR VALUE # ---------------------- # Append the text in VALUE to the end of the definition contained in VAR. Take # advantage of any shell optimizations that allow amortized linear growth over # repeated appends, instead of the typical quadratic growth present in naive # implementations. if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null then : eval 'as_fn_append () { eval $1+=\$2 }' else $as_nop as_fn_append () { eval $1=\$$1\$2 } fi # as_fn_append # as_fn_arith ARG... # ------------------ # Perform arithmetic evaluation on the ARGs, and store the result in the # global $as_val. Take advantage of shells that can avoid forks. The arguments # must be portable across $(()) and expr. if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null then : eval 'as_fn_arith () { as_val=$(( $* )) }' else $as_nop as_fn_arith () { as_val=`expr "$@" || test $? -eq 1` } fi # as_fn_arith # as_fn_nop # --------- # Do nothing but, unlike ":", preserve the value of $?. as_fn_nop () { return $? } as_nop=as_fn_nop # as_fn_error STATUS ERROR [LINENO LOG_FD] # ---------------------------------------- # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are # provided, also output the error to LOG_FD, referencing LINENO. Then exit the # script with STATUS, using 1 if that was 0. as_fn_error () { as_status=$1; test $as_status -eq 0 && as_status=1 if test "$4"; then as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 fi printf "%s\n" "$as_me: error: $2" >&2 as_fn_exit $as_status } # as_fn_error if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then as_basename=basename else as_basename=false fi if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then as_dirname=dirname else as_dirname=false fi as_me=`$as_basename -- "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || printf "%s\n" X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q } /^X\/\(\/\/\)$/{ s//\1/ q } /^X\/\(\/\).*/{ s//\1/ q } s/.*/./; q'` # Avoid depending upon Character Ranges. as_cr_letters='abcdefghijklmnopqrstuvwxyz' as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' as_cr_Letters=$as_cr_letters$as_cr_LETTERS as_cr_digits='0123456789' as_cr_alnum=$as_cr_Letters$as_cr_digits as_lineno_1=$LINENO as_lineno_1a=$LINENO as_lineno_2=$LINENO as_lineno_2a=$LINENO eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) sed -n ' p /[$]LINENO/= ' <$as_myself | sed ' s/[$]LINENO.*/&-/ t lineno b :lineno N :loop s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ t loop s/-\n.*// ' >$as_me.lineno && chmod +x "$as_me.lineno" || { printf "%s\n" "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } # If we had to re-execute with $CONFIG_SHELL, we're ensured to have # already done that, so ensure we don't try to do so again and fall # in an infinite loop. This has already happened in practice. _as_can_reexec=no; export _as_can_reexec # Don't try to exec as it changes $[0], causing all sort of problems # (the dirname of $[0] is not the place where we might find the # original and so on. Autoconf is especially sensitive to this). . "./$as_me.lineno" # Exit status is that of the last command. exit } # Determine whether it's possible to make 'echo' print without a newline. # These variables are no longer used directly by Autoconf, but are AC_SUBSTed # for compatibility with existing Makefiles. ECHO_C= ECHO_N= ECHO_T= case `echo -n x` in #((((( -n*) case `echo 'xy\c'` in *c*) ECHO_T=' ';; # ECHO_T is single tab character. xy) ECHO_C='\c';; *) echo `echo ksh88 bug on AIX 6.1` > /dev/null ECHO_T=' ';; esac;; *) ECHO_N='-n';; esac # For backward compatibility with old third-party macros, we provide # the shell variables $as_echo and $as_echo_n. New code should use # AS_ECHO(["message"]) and AS_ECHO_N(["message"]), respectively. as_echo='printf %s\n' as_echo_n='printf %s' rm -f conf$$ conf$$.exe conf$$.file if test -d conf$$.dir; then rm -f conf$$.dir/conf$$.file else rm -f conf$$.dir mkdir conf$$.dir 2>/dev/null fi if (echo >conf$$.file) 2>/dev/null; then if ln -s conf$$.file conf$$ 2>/dev/null; then as_ln_s='ln -s' # ... but there are two gotchas: # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. # In both cases, we have to default to `cp -pR'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || as_ln_s='cp -pR' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else as_ln_s='cp -pR' fi else as_ln_s='cp -pR' fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null if mkdir -p . 2>/dev/null; then as_mkdir_p='mkdir -p "$as_dir"' else test -d ./-p && rmdir ./-p as_mkdir_p=false fi as_test_x='test -x' as_executable_p=as_fn_executable_p # Sed expression to map a string onto a valid CPP name. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" # Sed expression to map a string onto a valid variable name. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" SHELL=${CONFIG_SHELL-/bin/sh} test -n "$DJDIR" || exec 7<&0 &1 # Name of the host. # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, # so uname gets run too. ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` # # Initializations. # ac_default_prefix=/usr/local ac_clean_files= ac_config_libobj_dir=. LIBOBJS= cross_compiling=no subdirs= MFLAGS= MAKEFLAGS= # Identity of this package. PACKAGE_NAME='httrack' PACKAGE_TARNAME='httrack' PACKAGE_VERSION='3.49.5' PACKAGE_STRING='httrack 3.49.5' PACKAGE_BUGREPORT='roche+packaging@httrack.com' PACKAGE_URL='http://www.httrack.com/' ac_unique_file="src/httrack.c" # Factoring default headers for most tests. ac_includes_default="\ #include #ifdef HAVE_STDIO_H # include #endif #ifdef HAVE_STDLIB_H # include #endif #ifdef HAVE_STRING_H # include #endif #ifdef HAVE_INTTYPES_H # include #endif #ifdef HAVE_STDINT_H # include #endif #ifdef HAVE_STRINGS_H # include #endif #ifdef HAVE_SYS_TYPES_H # include #endif #ifdef HAVE_SYS_STAT_H # include #endif #ifdef HAVE_UNISTD_H # include #endif" ac_header_c_list= ac_subst_vars='am__EXEEXT_FALSE am__EXEEXT_TRUE LTLIBOBJS ONLINE_UNIT_TESTS LIBOBJS DL_LIBS ICONV_LIBS SOCKET_LIBS THREADS_CFLAGS THREADS_LIBS LFS_FLAG V6_FLAG OPENSSL_LIBS HTTPS_SUPPORT AM_CFLAGS HAVE_VISIBILITY CFLAG_VISIBILITY LDFLAGS_PIE CFLAGS_PIE DEFAULT_LDFLAGS DEFAULT_CFLAGS VERSION_INFO LT_CV_OBJDIR SHLIBPATH_VAR LT_SYS_LIBRARY_PATH OTOOL64 OTOOL LIPO NMEDIT DSYMUTIL MANIFEST_TOOL RANLIB ac_ct_AR AR DLLTOOL OBJDUMP FILECMD LN_S NM ac_ct_DUMPBIN DUMPBIN LD FGREP SED host_os host_vendor host_cpu host build_os build_vendor build_cpu build LIBTOOL EGREP GREP am__fastdepCC_FALSE am__fastdepCC_TRUE CCDEPMODE am__nodep AMDEPBACKSLASH AMDEP_FALSE AMDEP_TRUE am__include DEPDIR OBJEXT EXEEXT ac_ct_CC CPPFLAGS LDFLAGS CFLAGS CC MAINT MAINTAINER_MODE_FALSE MAINTAINER_MODE_TRUE AM_BACKSLASH AM_DEFAULT_VERBOSITY AM_DEFAULT_V AM_V CSCOPE ETAGS CTAGS am__untar am__tar AMTAR am__leading_dot SET_MAKE AWK mkdir_p MKDIR_P INSTALL_STRIP_PROGRAM STRIP install_sh MAKEINFO AUTOHEADER AUTOMAKE AUTOCONF ACLOCAL VERSION PACKAGE CYGPATH_W am__isrc INSTALL_DATA INSTALL_SCRIPT INSTALL_PROGRAM target_alias host_alias build_alias LIBS ECHO_T ECHO_N ECHO_C DEFS mandir localedir libdir psdir pdfdir dvidir htmldir infodir docdir oldincludedir includedir runstatedir localstatedir sharedstatedir sysconfdir datadir datarootdir libexecdir sbindir bindir program_transform_name prefix exec_prefix PACKAGE_URL PACKAGE_BUGREPORT PACKAGE_STRING PACKAGE_VERSION PACKAGE_TARNAME PACKAGE_NAME PATH_SEPARATOR SHELL am__quote' ac_subst_files='' ac_user_opts=' enable_option_checking enable_silent_rules enable_maintainer_mode enable_dependency_tracking enable_shared enable_static with_pic enable_fast_install with_aix_soname with_gnu_ld with_sysroot enable_libtool_lock with_zlib enable_https enable_online_unit_tests ' ac_precious_vars='build_alias host_alias target_alias CC CFLAGS LDFLAGS LIBS CPPFLAGS LT_SYS_LIBRARY_PATH' # Initialize some variables set by options. ac_init_help= ac_init_version=false ac_unrecognized_opts= ac_unrecognized_sep= # The variables have the same names as the options, with # dashes changed to underlines. cache_file=/dev/null exec_prefix=NONE no_create= no_recursion= prefix=NONE program_prefix=NONE program_suffix=NONE program_transform_name=s,x,x, silent= site= srcdir= verbose= x_includes=NONE x_libraries=NONE # Installation directory options. # These are left unexpanded so users can "make install exec_prefix=/foo" # and all the variables that are supposed to be based on exec_prefix # by default will actually change. # Use braces instead of parens because sh, perl, etc. also accept them. # (The list follows the same order as the GNU Coding Standards.) bindir='${exec_prefix}/bin' sbindir='${exec_prefix}/sbin' libexecdir='${exec_prefix}/libexec' datarootdir='${prefix}/share' datadir='${datarootdir}' sysconfdir='${prefix}/etc' sharedstatedir='${prefix}/com' localstatedir='${prefix}/var' runstatedir='${localstatedir}/run' includedir='${prefix}/include' oldincludedir='/usr/include' docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' infodir='${datarootdir}/info' htmldir='${docdir}' dvidir='${docdir}' pdfdir='${docdir}' psdir='${docdir}' libdir='${exec_prefix}/lib' localedir='${datarootdir}/locale' mandir='${datarootdir}/man' ac_prev= ac_dashdash= for ac_option do # If the previous option needs an argument, assign it. if test -n "$ac_prev"; then eval $ac_prev=\$ac_option ac_prev= continue fi case $ac_option in *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; *=) ac_optarg= ;; *) ac_optarg=yes ;; esac case $ac_dashdash$ac_option in --) ac_dashdash=yes ;; -bindir | --bindir | --bindi | --bind | --bin | --bi) ac_prev=bindir ;; -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) bindir=$ac_optarg ;; -build | --build | --buil | --bui | --bu) ac_prev=build_alias ;; -build=* | --build=* | --buil=* | --bui=* | --bu=*) build_alias=$ac_optarg ;; -cache-file | --cache-file | --cache-fil | --cache-fi \ | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) ac_prev=cache_file ;; -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) cache_file=$ac_optarg ;; --config-cache | -C) cache_file=config.cache ;; -datadir | --datadir | --datadi | --datad) ac_prev=datadir ;; -datadir=* | --datadir=* | --datadi=* | --datad=*) datadir=$ac_optarg ;; -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ | --dataroo | --dataro | --datar) ac_prev=datarootdir ;; -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) datarootdir=$ac_optarg ;; -disable-* | --disable-*) ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error $? "invalid feature name: \`$ac_useropt'" ac_useropt_orig=$ac_useropt ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "enable_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval enable_$ac_useropt=no ;; -docdir | --docdir | --docdi | --doc | --do) ac_prev=docdir ;; -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) docdir=$ac_optarg ;; -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) ac_prev=dvidir ;; -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) dvidir=$ac_optarg ;; -enable-* | --enable-*) ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error $? "invalid feature name: \`$ac_useropt'" ac_useropt_orig=$ac_useropt ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "enable_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval enable_$ac_useropt=\$ac_optarg ;; -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | --exec | --exe | --ex) ac_prev=exec_prefix ;; -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | --exec=* | --exe=* | --ex=*) exec_prefix=$ac_optarg ;; -gas | --gas | --ga | --g) # Obsolete; use --with-gas. with_gas=yes ;; -help | --help | --hel | --he | -h) ac_init_help=long ;; -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) ac_init_help=recursive ;; -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) ac_init_help=short ;; -host | --host | --hos | --ho) ac_prev=host_alias ;; -host=* | --host=* | --hos=* | --ho=*) host_alias=$ac_optarg ;; -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) ac_prev=htmldir ;; -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ | --ht=*) htmldir=$ac_optarg ;; -includedir | --includedir | --includedi | --included | --include \ | --includ | --inclu | --incl | --inc) ac_prev=includedir ;; -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | --includ=* | --inclu=* | --incl=* | --inc=*) includedir=$ac_optarg ;; -infodir | --infodir | --infodi | --infod | --info | --inf) ac_prev=infodir ;; -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) infodir=$ac_optarg ;; -libdir | --libdir | --libdi | --libd) ac_prev=libdir ;; -libdir=* | --libdir=* | --libdi=* | --libd=*) libdir=$ac_optarg ;; -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | --libexe | --libex | --libe) ac_prev=libexecdir ;; -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | --libexe=* | --libex=* | --libe=*) libexecdir=$ac_optarg ;; -localedir | --localedir | --localedi | --localed | --locale) ac_prev=localedir ;; -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) localedir=$ac_optarg ;; -localstatedir | --localstatedir | --localstatedi | --localstated \ | --localstate | --localstat | --localsta | --localst | --locals) ac_prev=localstatedir ;; -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) localstatedir=$ac_optarg ;; -mandir | --mandir | --mandi | --mand | --man | --ma | --m) ac_prev=mandir ;; -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) mandir=$ac_optarg ;; -nfp | --nfp | --nf) # Obsolete; use --without-fp. with_fp=no ;; -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | --no-cr | --no-c | -n) no_create=yes ;; -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) no_recursion=yes ;; -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ | --oldin | --oldi | --old | --ol | --o) ac_prev=oldincludedir ;; -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) oldincludedir=$ac_optarg ;; -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) ac_prev=prefix ;; -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) prefix=$ac_optarg ;; -program-prefix | --program-prefix | --program-prefi | --program-pref \ | --program-pre | --program-pr | --program-p) ac_prev=program_prefix ;; -program-prefix=* | --program-prefix=* | --program-prefi=* \ | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) program_prefix=$ac_optarg ;; -program-suffix | --program-suffix | --program-suffi | --program-suff \ | --program-suf | --program-su | --program-s) ac_prev=program_suffix ;; -program-suffix=* | --program-suffix=* | --program-suffi=* \ | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) program_suffix=$ac_optarg ;; -program-transform-name | --program-transform-name \ | --program-transform-nam | --program-transform-na \ | --program-transform-n | --program-transform- \ | --program-transform | --program-transfor \ | --program-transfo | --program-transf \ | --program-trans | --program-tran \ | --progr-tra | --program-tr | --program-t) ac_prev=program_transform_name ;; -program-transform-name=* | --program-transform-name=* \ | --program-transform-nam=* | --program-transform-na=* \ | --program-transform-n=* | --program-transform-=* \ | --program-transform=* | --program-transfor=* \ | --program-transfo=* | --program-transf=* \ | --program-trans=* | --program-tran=* \ | --progr-tra=* | --program-tr=* | --program-t=*) program_transform_name=$ac_optarg ;; -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) ac_prev=pdfdir ;; -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) pdfdir=$ac_optarg ;; -psdir | --psdir | --psdi | --psd | --ps) ac_prev=psdir ;; -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) psdir=$ac_optarg ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) silent=yes ;; -runstatedir | --runstatedir | --runstatedi | --runstated \ | --runstate | --runstat | --runsta | --runst | --runs \ | --run | --ru | --r) ac_prev=runstatedir ;; -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \ | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \ | --run=* | --ru=* | --r=*) runstatedir=$ac_optarg ;; -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) ac_prev=sbindir ;; -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | --sbi=* | --sb=*) sbindir=$ac_optarg ;; -sharedstatedir | --sharedstatedir | --sharedstatedi \ | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ | --sharedst | --shareds | --shared | --share | --shar \ | --sha | --sh) ac_prev=sharedstatedir ;; -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | --sha=* | --sh=*) sharedstatedir=$ac_optarg ;; -site | --site | --sit) ac_prev=site ;; -site=* | --site=* | --sit=*) site=$ac_optarg ;; -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) ac_prev=srcdir ;; -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) srcdir=$ac_optarg ;; -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ | --syscon | --sysco | --sysc | --sys | --sy) ac_prev=sysconfdir ;; -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) sysconfdir=$ac_optarg ;; -target | --target | --targe | --targ | --tar | --ta | --t) ac_prev=target_alias ;; -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) target_alias=$ac_optarg ;; -v | -verbose | --verbose | --verbos | --verbo | --verb) verbose=yes ;; -version | --version | --versio | --versi | --vers | -V) ac_init_version=: ;; -with-* | --with-*) ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error $? "invalid package name: \`$ac_useropt'" ac_useropt_orig=$ac_useropt ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "with_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval with_$ac_useropt=\$ac_optarg ;; -without-* | --without-*) ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error $? "invalid package name: \`$ac_useropt'" ac_useropt_orig=$ac_useropt ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "with_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval with_$ac_useropt=no ;; --x) # Obsolete; use --with-x. with_x=yes ;; -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | --x-incl | --x-inc | --x-in | --x-i) ac_prev=x_includes ;; -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) x_includes=$ac_optarg ;; -x-libraries | --x-libraries | --x-librarie | --x-librari \ | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) ac_prev=x_libraries ;; -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) x_libraries=$ac_optarg ;; -*) as_fn_error $? "unrecognized option: \`$ac_option' Try \`$0 --help' for more information" ;; *=*) ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` # Reject names that are not valid shell variable names. case $ac_envvar in #( '' | [0-9]* | *[!_$as_cr_alnum]* ) as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; esac eval $ac_envvar=\$ac_optarg export $ac_envvar ;; *) # FIXME: should be removed in autoconf 3.0. printf "%s\n" "$as_me: WARNING: you should use --build, --host, --target" >&2 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && printf "%s\n" "$as_me: WARNING: invalid host type: $ac_option" >&2 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" ;; esac done if test -n "$ac_prev"; then ac_option=--`echo $ac_prev | sed 's/_/-/g'` as_fn_error $? "missing argument to $ac_option" fi if test -n "$ac_unrecognized_opts"; then case $enable_option_checking in no) ;; fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; *) printf "%s\n" "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; esac fi # Check all directory arguments for consistency. for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ datadir sysconfdir sharedstatedir localstatedir includedir \ oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ libdir localedir mandir runstatedir do eval ac_val=\$$ac_var # Remove trailing slashes. case $ac_val in */ ) ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` eval $ac_var=\$ac_val;; esac # Be sure to have absolute directory names. case $ac_val in [\\/$]* | ?:[\\/]* ) continue;; NONE | '' ) case $ac_var in *prefix ) continue;; esac;; esac as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" done # There might be people who depend on the old broken behavior: `$host' # used to hold the argument of --host etc. # FIXME: To remove some day. build=$build_alias host=$host_alias target=$target_alias # FIXME: To remove some day. if test "x$host_alias" != x; then if test "x$build_alias" = x; then cross_compiling=maybe elif test "x$build_alias" != "x$host_alias"; then cross_compiling=yes fi fi ac_tool_prefix= test -n "$host_alias" && ac_tool_prefix=$host_alias- test "$silent" = yes && exec 6>/dev/null ac_pwd=`pwd` && test -n "$ac_pwd" && ac_ls_di=`ls -di .` && ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || as_fn_error $? "working directory cannot be determined" test "X$ac_ls_di" = "X$ac_pwd_ls_di" || as_fn_error $? "pwd does not report name of working directory" # Find the source files, if location was not specified. if test -z "$srcdir"; then ac_srcdir_defaulted=yes # Try the directory containing this script, then the parent directory. ac_confdir=`$as_dirname -- "$as_myself" || $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_myself" : 'X\(//\)[^/]' \| \ X"$as_myself" : 'X\(//\)$' \| \ X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || printf "%s\n" X"$as_myself" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` srcdir=$ac_confdir if test ! -r "$srcdir/$ac_unique_file"; then srcdir=.. fi else ac_srcdir_defaulted=no fi if test ! -r "$srcdir/$ac_unique_file"; then test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" fi ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" ac_abs_confdir=`( cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" pwd)` # When building in place, set srcdir=. if test "$ac_abs_confdir" = "$ac_pwd"; then srcdir=. fi # Remove unnecessary trailing slashes from srcdir. # Double slashes in file names in object file debugging info # mess up M-x gdb in Emacs. case $srcdir in */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; esac for ac_var in $ac_precious_vars; do eval ac_env_${ac_var}_set=\${${ac_var}+set} eval ac_env_${ac_var}_value=\$${ac_var} eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} eval ac_cv_env_${ac_var}_value=\$${ac_var} done # # Report the --help message. # if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF \`configure' configures httrack 3.49.5 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... To assign environment variables (e.g., CC, CFLAGS...), specify them as VAR=VALUE. See below for descriptions of some of the useful variables. Defaults for the options are specified in brackets. Configuration: -h, --help display this help and exit --help=short display options specific to this package --help=recursive display the short help of all the included packages -V, --version display version information and exit -q, --quiet, --silent do not print \`checking ...' messages --cache-file=FILE cache test results in FILE [disabled] -C, --config-cache alias for \`--cache-file=config.cache' -n, --no-create do not create output files --srcdir=DIR find the sources in DIR [configure dir or \`..'] Installation directories: --prefix=PREFIX install architecture-independent files in PREFIX [$ac_default_prefix] --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX [PREFIX] By default, \`make install' will install all the files in \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify an installation prefix other than \`$ac_default_prefix' using \`--prefix', for instance \`--prefix=\$HOME'. For better control, use the options below. Fine tuning of the installation directories: --bindir=DIR user executables [EPREFIX/bin] --sbindir=DIR system admin executables [EPREFIX/sbin] --libexecdir=DIR program executables [EPREFIX/libexec] --sysconfdir=DIR read-only single-machine data [PREFIX/etc] --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] --localstatedir=DIR modifiable single-machine data [PREFIX/var] --runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run] --libdir=DIR object code libraries [EPREFIX/lib] --includedir=DIR C header files [PREFIX/include] --oldincludedir=DIR C header files for non-gcc [/usr/include] --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] --datadir=DIR read-only architecture-independent data [DATAROOTDIR] --infodir=DIR info documentation [DATAROOTDIR/info] --localedir=DIR locale-dependent data [DATAROOTDIR/locale] --mandir=DIR man documentation [DATAROOTDIR/man] --docdir=DIR documentation root [DATAROOTDIR/doc/httrack] --htmldir=DIR html documentation [DOCDIR] --dvidir=DIR dvi documentation [DOCDIR] --pdfdir=DIR pdf documentation [DOCDIR] --psdir=DIR ps documentation [DOCDIR] _ACEOF cat <<\_ACEOF Program names: --program-prefix=PREFIX prepend PREFIX to installed program names --program-suffix=SUFFIX append SUFFIX to installed program names --program-transform-name=PROGRAM run sed PROGRAM on installed program names System types: --build=BUILD configure for building on BUILD [guessed] --host=HOST cross-compile to build programs to run on HOST [BUILD] _ACEOF fi if test -n "$ac_init_help"; then case $ac_init_help in short | recursive ) echo "Configuration of httrack 3.49.5:";; esac cat <<\_ACEOF Optional Features: --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] --enable-silent-rules less verbose build output (undo: "make V=1") --disable-silent-rules verbose build output (undo: "make V=0") --enable-maintainer-mode enable make rules and dependencies not useful (and sometimes confusing) to the casual installer --enable-dependency-tracking do not reject slow dependency extractors --disable-dependency-tracking speeds up one-time build --enable-shared[=PKGS] build shared libraries [default=yes] --enable-static[=PKGS] build static libraries [default=yes] --enable-fast-install[=PKGS] optimize for fast installation [default=yes] --disable-libtool-lock avoid locking (might break parallel builds) --enable-https=[yes/no/auto] Enable https support [default=yes] --enable-online-unit-tests=[yes/no/auto] Enable online-unit-tests [default=yes] Optional Packages: --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) --with-pic[=PKGS] try to use only PIC/non-PIC objects [default=use both] --with-aix-soname=aix|svr4|both shared library versioning (aka "SONAME") variant to provide on AIX, [default=aix]. --with-gnu-ld assume the C compiler uses GNU ld [default=no] --with-sysroot[=DIR] Search for dependent libraries within DIR (or the compiler's sysroot if not specified). --with-zlib=DIR root directory path of zlib installation defaults to /usr/local or /usr if not found in /usr/local --without-zlib to disable zlib usage completely Some influential environment variables: CC C compiler command CFLAGS C compiler flags LDFLAGS linker flags, e.g. -L if you have libraries in a nonstandard directory LIBS libraries to pass to the linker, e.g. -l CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I if you have headers in a nonstandard directory LT_SYS_LIBRARY_PATH User-defined run-time library search path. Use these variables to override the choices made by `configure' or to help it to find libraries and programs with nonstandard names/locations. Report bugs to . httrack home page: . _ACEOF ac_status=$? fi if test "$ac_init_help" = "recursive"; then # If there are subdirs, report their specific --help. for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue test -d "$ac_dir" || { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || continue ac_builddir=. case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_dir_suffix=/`printf "%s\n" "$ac_dir" | sed 's|^\.[\\/]||'` # A ".." for each directory in $ac_dir_suffix. ac_top_builddir_sub=`printf "%s\n" "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` case $ac_top_builddir_sub in "") ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; esac ;; esac ac_abs_top_builddir=$ac_pwd ac_abs_builddir=$ac_pwd$ac_dir_suffix # for backward compatibility: ac_top_builddir=$ac_top_build_prefix case $srcdir in .) # We are building in place. ac_srcdir=. ac_top_srcdir=$ac_top_builddir_sub ac_abs_top_srcdir=$ac_pwd ;; [\\/]* | ?:[\\/]* ) # Absolute name. ac_srcdir=$srcdir$ac_dir_suffix; ac_top_srcdir=$srcdir ac_abs_top_srcdir=$srcdir ;; *) # Relative name. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix ac_top_srcdir=$ac_top_build_prefix$srcdir ac_abs_top_srcdir=$ac_pwd/$srcdir ;; esac ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix cd "$ac_dir" || { ac_status=$?; continue; } # Check for configure.gnu first; this name is used for a wrapper for # Metaconfig's "Configure" on case-insensitive file systems. if test -f "$ac_srcdir/configure.gnu"; then echo && $SHELL "$ac_srcdir/configure.gnu" --help=recursive elif test -f "$ac_srcdir/configure"; then echo && $SHELL "$ac_srcdir/configure" --help=recursive else printf "%s\n" "$as_me: WARNING: no configuration information is in $ac_dir" >&2 fi || ac_status=$? cd "$ac_pwd" || { ac_status=$?; break; } done fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF httrack configure 3.49.5 generated by GNU Autoconf 2.71 Copyright (C) 2021 Free Software Foundation, Inc. This configure script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it. HTTrack Website Copier, Offline Browser for Windows and Unix Copyright (C) 1998-2015 Xavier Roche and other contributors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Important notes: - We hereby ask people using this source NOT to use it in purpose of grabbing emails addresses, or collecting any other private information on persons. This would disgrace our work, and spoil the many hours we spent on it. Please visit our Website: http://www.httrack.com _ACEOF exit fi ## ------------------------ ## ## Autoconf initialization. ## ## ------------------------ ## # ac_fn_c_try_compile LINENO # -------------------------- # Try to compile conftest.$ac_ext, and return whether this succeeded. ac_fn_c_try_compile () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack rm -f conftest.$ac_objext conftest.beam if { { ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" printf "%s\n" "$ac_try_echo"; } >&5 (eval "$ac_compile") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext then : ac_retval=0 else $as_nop printf "%s\n" "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_compile # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES # ------------------------------------------------------- # Tests whether HEADER exists and can be compiled using the include files in # INCLUDES, setting the cache variable VAR accordingly. ac_fn_c_check_header_compile () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 printf %s "checking for $2... " >&6; } if eval test \${$3+y} then : printf %s "(cached) " >&6 else $as_nop cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 #include <$2> _ACEOF if ac_fn_c_try_compile "$LINENO" then : eval "$3=yes" else $as_nop eval "$3=no" fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext fi eval ac_res=\$$3 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 printf "%s\n" "$ac_res" >&6; } eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_header_compile # ac_fn_c_try_link LINENO # ----------------------- # Try to link conftest.$ac_ext, and return whether this succeeded. ac_fn_c_try_link () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack rm -f conftest.$ac_objext conftest.beam conftest$ac_exeext if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" printf "%s\n" "$ac_try_echo"; } >&5 (eval "$ac_link") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && { test "$cross_compiling" = yes || test -x conftest$ac_exeext } then : ac_retval=0 else $as_nop printf "%s\n" "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would # 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; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_link # ac_fn_c_check_func LINENO FUNC VAR # ---------------------------------- # Tests whether FUNC exists, setting the cache variable VAR accordingly ac_fn_c_check_func () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 printf %s "checking for $2... " >&6; } if eval test \${$3+y} then : printf %s "(cached) " >&6 else $as_nop cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Define $2 to an innocuous variant, in case declares $2. For example, HP-UX 11i declares gettimeofday. */ #define $2 innocuous_$2 /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $2 (); below. */ #include #undef $2 /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char $2 (); /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ #if defined __stub_$2 || defined __stub___$2 choke me #endif int main (void) { return $2 (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : eval "$3=yes" else $as_nop eval "$3=no" fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext fi eval ac_res=\$$3 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 printf "%s\n" "$ac_res" >&6; } eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_func # ac_fn_c_try_run LINENO # ---------------------- # Try to run conftest.$ac_ext, and return whether this succeeded. Assumes that # executables *can* be run. ac_fn_c_try_run () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" printf "%s\n" "$ac_try_echo"; } >&5 (eval "$ac_link") 2>&5 ac_status=$? printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' { { case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" printf "%s\n" "$ac_try_echo"; } >&5 (eval "$ac_try") 2>&5 ac_status=$? printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; } then : ac_retval=0 else $as_nop printf "%s\n" "$as_me: program exited with status $ac_status" >&5 printf "%s\n" "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=$ac_status fi rm -rf conftest.dSYM conftest_ipa8_conftest.oo eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_run # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES # -------------------------------------------- # Tries to find the compile-time value of EXPR in a program that includes # INCLUDES, setting VAR accordingly. Returns whether the value could be # computed ac_fn_c_compute_int () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack if test "$cross_compiling" = yes; then # Depending upon the size, compute the lo and hi bounds. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 int main (void) { static int test_array [1 - 2 * !(($2) >= 0)]; test_array [0] = 0; return test_array [0]; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ac_lo=0 ac_mid=0 while :; do cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 int main (void) { static int test_array [1 - 2 * !(($2) <= $ac_mid)]; test_array [0] = 0; return test_array [0]; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ac_hi=$ac_mid; break else $as_nop as_fn_arith $ac_mid + 1 && ac_lo=$as_val if test $ac_lo -le $ac_mid; then ac_lo= ac_hi= break fi as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext done else $as_nop cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 int main (void) { static int test_array [1 - 2 * !(($2) < 0)]; test_array [0] = 0; return test_array [0]; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ac_hi=-1 ac_mid=-1 while :; do cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 int main (void) { static int test_array [1 - 2 * !(($2) >= $ac_mid)]; test_array [0] = 0; return test_array [0]; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ac_lo=$ac_mid; break else $as_nop as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val if test $ac_mid -le $ac_hi; then ac_lo= ac_hi= break fi as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext done else $as_nop ac_lo= ac_hi= fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext # Binary search between lo and hi bounds. while test "x$ac_lo" != "x$ac_hi"; do as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 int main (void) { static int test_array [1 - 2 * !(($2) <= $ac_mid)]; test_array [0] = 0; return test_array [0]; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ac_hi=$ac_mid else $as_nop as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext done case $ac_lo in #(( ?*) eval "$3=\$ac_lo"; ac_retval=0 ;; '') ac_retval=1 ;; esac else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 static long int longval (void) { return $2; } static unsigned long int ulongval (void) { return $2; } #include #include int main (void) { FILE *f = fopen ("conftest.val", "w"); if (! f) return 1; if (($2) < 0) { long int i = longval (); if (i != ($2)) return 1; fprintf (f, "%ld", i); } else { unsigned long int i = ulongval (); if (i != ($2)) return 1; fprintf (f, "%lu", i); } /* Do not output a trailing newline, as this causes \r\n confusion on some platforms. */ return ferror (f) || fclose (f) != 0; ; return 0; } _ACEOF if ac_fn_c_try_run "$LINENO" then : echo >>conftest.val; read $3 &5 printf %s "checking for $2... " >&6; } if eval test \${$3+y} then : printf %s "(cached) " >&6 else $as_nop eval "$3=no" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 int main (void) { if (sizeof ($2)) return 0; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 int main (void) { if (sizeof (($2))) return 0; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : else $as_nop eval "$3=yes" fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext fi eval ac_res=\$$3 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 printf "%s\n" "$ac_res" >&6; } eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_type ac_configure_args_raw= for ac_arg do case $ac_arg in *\'*) ac_arg=`printf "%s\n" "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; esac as_fn_append ac_configure_args_raw " '$ac_arg'" done case $ac_configure_args_raw in *$as_nl*) ac_safe_unquote= ;; *) ac_unsafe_z='|&;<>()$`\\"*?[ '' ' # This string ends in space, tab. ac_unsafe_a="$ac_unsafe_z#~" ac_safe_unquote="s/ '\\([^$ac_unsafe_a][^$ac_unsafe_z]*\\)'/ \\1/g" ac_configure_args_raw=` printf "%s\n" "$ac_configure_args_raw" | sed "$ac_safe_unquote"`;; esac cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. It was created by httrack $as_me 3.49.5, which was generated by GNU Autoconf 2.71. Invocation command line was $ $0$ac_configure_args_raw _ACEOF exec 5>>config.log { cat <<_ASUNAME ## --------- ## ## Platform. ## ## --------- ## hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` uname -m = `(uname -m) 2>/dev/null || echo unknown` uname -r = `(uname -r) 2>/dev/null || echo unknown` uname -s = `(uname -s) 2>/dev/null || echo unknown` uname -v = `(uname -v) 2>/dev/null || echo unknown` /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` _ASUNAME as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac printf "%s\n" "PATH: $as_dir" done IFS=$as_save_IFS } >&5 cat >&5 <<_ACEOF ## ----------- ## ## Core tests. ## ## ----------- ## _ACEOF # Keep a trace of the command line. # Strip out --no-create and --no-recursion so they do not pile up. # Strip out --silent because we don't want to record it for future runs. # Also quote any args containing shell meta-characters. # Make two passes to allow for proper duplicate-argument suppression. ac_configure_args= ac_configure_args0= ac_configure_args1= ac_must_keep_next=false for ac_pass in 1 2 do for ac_arg do case $ac_arg in -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) continue ;; *\'*) ac_arg=`printf "%s\n" "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; esac case $ac_pass in 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; 2) as_fn_append ac_configure_args1 " '$ac_arg'" if test $ac_must_keep_next = true; then ac_must_keep_next=false # Got value, back to normal. else case $ac_arg in *=* | --config-cache | -C | -disable-* | --disable-* \ | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ | -with-* | --with-* | -without-* | --without-* | --x) case "$ac_configure_args0 " in "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; esac ;; -* ) ac_must_keep_next=true ;; esac fi as_fn_append ac_configure_args " '$ac_arg'" ;; esac done done { ac_configure_args0=; unset ac_configure_args0;} { ac_configure_args1=; unset ac_configure_args1;} # When interrupted or exit'd, cleanup temporary files, and complete # config.log. We remove comments because anyway the quotes in there # would cause problems or look ugly. # WARNING: Use '\'' to represent an apostrophe within the trap. # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. trap 'exit_status=$? # Sanitize IFS. IFS=" "" $as_nl" # Save into config.log some information that might help in debugging. { echo printf "%s\n" "## ---------------- ## ## Cache variables. ## ## ---------------- ##" echo # The following way of writing the cache mishandles newlines in values, ( for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do eval ac_val=\$$ac_var case $ac_val in #( *${as_nl}*) case $ac_var in #( *_cv_*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 printf "%s\n" "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; esac case $ac_var in #( _ | IFS | as_nl) ;; #( BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( *) { eval $ac_var=; unset $ac_var;} ;; esac ;; esac done (set) 2>&1 | case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( *${as_nl}ac_space=\ *) sed -n \ "s/'\''/'\''\\\\'\'''\''/g; s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" ;; #( *) sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" ;; esac | sort ) echo printf "%s\n" "## ----------------- ## ## Output variables. ## ## ----------------- ##" echo for ac_var in $ac_subst_vars do eval ac_val=\$$ac_var case $ac_val in *\'\''*) ac_val=`printf "%s\n" "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac printf "%s\n" "$ac_var='\''$ac_val'\''" done | sort echo if test -n "$ac_subst_files"; then printf "%s\n" "## ------------------- ## ## File substitutions. ## ## ------------------- ##" echo for ac_var in $ac_subst_files do eval ac_val=\$$ac_var case $ac_val in *\'\''*) ac_val=`printf "%s\n" "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac printf "%s\n" "$ac_var='\''$ac_val'\''" done | sort echo fi if test -s confdefs.h; then printf "%s\n" "## ----------- ## ## confdefs.h. ## ## ----------- ##" echo cat confdefs.h echo fi test "$ac_signal" != 0 && printf "%s\n" "$as_me: caught signal $ac_signal" printf "%s\n" "$as_me: exit $exit_status" } >&5 rm -f core *.core core.conftest.* && rm -f -r conftest* confdefs* conf$$* $ac_clean_files && exit $exit_status ' 0 for ac_signal in 1 2 13 15; do trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal done ac_signal=0 # confdefs.h avoids OS command line length limits that DEFS can exceed. rm -f -r conftest* confdefs.h printf "%s\n" "/* confdefs.h */" > confdefs.h # Predefined preprocessor variables. printf "%s\n" "#define PACKAGE_NAME \"$PACKAGE_NAME\"" >>confdefs.h printf "%s\n" "#define PACKAGE_TARNAME \"$PACKAGE_TARNAME\"" >>confdefs.h printf "%s\n" "#define PACKAGE_VERSION \"$PACKAGE_VERSION\"" >>confdefs.h printf "%s\n" "#define PACKAGE_STRING \"$PACKAGE_STRING\"" >>confdefs.h printf "%s\n" "#define PACKAGE_BUGREPORT \"$PACKAGE_BUGREPORT\"" >>confdefs.h printf "%s\n" "#define PACKAGE_URL \"$PACKAGE_URL\"" >>confdefs.h # Let the site file select an alternate cache file if it wants to. # Prefer an explicitly selected file to automatically selected ones. if test -n "$CONFIG_SITE"; then ac_site_files="$CONFIG_SITE" elif test "x$prefix" != xNONE; then ac_site_files="$prefix/share/config.site $prefix/etc/config.site" else ac_site_files="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" fi for ac_site_file in $ac_site_files do case $ac_site_file in #( */*) : ;; #( *) : ac_site_file=./$ac_site_file ;; esac if test -f "$ac_site_file" && test -r "$ac_site_file"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 printf "%s\n" "$as_me: loading site script $ac_site_file" >&6;} sed 's/^/| /' "$ac_site_file" >&5 . "$ac_site_file" \ || { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$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; } fi done if test -r "$cache_file"; then # Some versions of bash will fail to source /dev/null (special files # actually), so we avoid doing that. DJGPP emulates it as a regular file. if test /dev/null != "$cache_file" && test -f "$cache_file"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 printf "%s\n" "$as_me: loading cache $cache_file" >&6;} case $cache_file in [\\/]* | ?:[\\/]* ) . "$cache_file";; *) . "./$cache_file";; esac fi else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 printf "%s\n" "$as_me: creating cache $cache_file" >&6;} >$cache_file fi as_fn_append ac_header_c_list " stdio.h stdio_h HAVE_STDIO_H" # Test code for whether the C compiler supports C89 (global declarations) ac_c_conftest_c89_globals=' /* Does the compiler advertise C89 conformance? Do not test the value of __STDC__, because some compilers set it to 0 while being otherwise adequately conformant. */ #if !defined __STDC__ # error "Compiler does not advertise C89 conformance" #endif #include #include struct stat; /* Most of the following tests are stolen from RCS 5.7 src/conf.sh. */ struct buf { int x; }; struct buf * (*rcsopen) (struct buf *, struct stat *, int); static char *e (p, i) char **p; int i; { return p[i]; } static char *f (char * (*g) (char **, int), char **p, ...) { char *s; va_list v; va_start (v,p); s = g (p, va_arg (v,int)); va_end (v); return s; } /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has function prototypes and stuff, but not \xHH hex character constants. These do not provoke an error unfortunately, instead are silently treated as an "x". The following induces an error, until -std is added to get proper ANSI mode. Curiously \x00 != x always comes out true, for an array size at least. It is necessary to write \x00 == 0 to get something that is true only with -std. */ int osf4_cc_array ['\''\x00'\'' == 0 ? 1 : -1]; /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters inside strings and character constants. */ #define FOO(x) '\''x'\'' int xlc6_cc_array[FOO(a) == '\''x'\'' ? 1 : -1]; int test (int i, double x); struct s1 {int (*f) (int a);}; struct s2 {int (*f) (double a);}; int pairnames (int, char **, int *(*)(struct buf *, struct stat *, int), int, int);' # Test code for whether the C compiler supports C89 (body of main). ac_c_conftest_c89_main=' ok |= (argc == 0 || f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]); ' # Test code for whether the C compiler supports C99 (global declarations) ac_c_conftest_c99_globals=' // Does the compiler advertise C99 conformance? #if !defined __STDC_VERSION__ || __STDC_VERSION__ < 199901L # error "Compiler does not advertise C99 conformance" #endif #include extern int puts (const char *); extern int printf (const char *, ...); extern int dprintf (int, const char *, ...); extern void *malloc (size_t); // Check varargs macros. These examples are taken from C99 6.10.3.5. // dprintf is used instead of fprintf to avoid needing to declare // FILE and stderr. #define debug(...) dprintf (2, __VA_ARGS__) #define showlist(...) puts (#__VA_ARGS__) #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__)) static void test_varargs_macros (void) { int x = 1234; int y = 5678; debug ("Flag"); debug ("X = %d\n", x); showlist (The first, second, and third items.); report (x>y, "x is %d but y is %d", x, y); } // Check long long types. #define BIG64 18446744073709551615ull #define BIG32 4294967295ul #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0) #if !BIG_OK #error "your preprocessor is broken" #endif #if BIG_OK #else #error "your preprocessor is broken" #endif static long long int bignum = -9223372036854775807LL; static unsigned long long int ubignum = BIG64; struct incomplete_array { int datasize; double data[]; }; struct named_init { int number; const wchar_t *name; double average; }; typedef const char *ccp; static inline int test_restrict (ccp restrict text) { // See if C++-style comments work. // Iterate through items via the restricted pointer. // Also check for declarations in for loops. for (unsigned int i = 0; *(text+i) != '\''\0'\''; ++i) continue; return 0; } // Check varargs and va_copy. static bool test_varargs (const char *format, ...) { va_list args; va_start (args, format); va_list args_copy; va_copy (args_copy, args); const char *str = ""; int number = 0; float fnumber = 0; while (*format) { switch (*format++) { case '\''s'\'': // string str = va_arg (args_copy, const char *); break; case '\''d'\'': // int number = va_arg (args_copy, int); break; case '\''f'\'': // float fnumber = va_arg (args_copy, double); break; default: break; } } va_end (args_copy); va_end (args); return *str && number && fnumber; } ' # Test code for whether the C compiler supports C99 (body of main). ac_c_conftest_c99_main=' // Check bool. _Bool success = false; success |= (argc != 0); // Check restrict. if (test_restrict ("String literal") == 0) success = true; char *restrict newvar = "Another string"; // Check varargs. success &= test_varargs ("s, d'\'' f .", "string", 65, 34.234); test_varargs_macros (); // Check flexible array members. struct incomplete_array *ia = malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10)); ia->datasize = 10; for (int i = 0; i < ia->datasize; ++i) ia->data[i] = i * 1.234; // Check named initializers. struct named_init ni = { .number = 34, .name = L"Test wide string", .average = 543.34343, }; ni.number = 58; int dynamic_array[ni.number]; dynamic_array[0] = argv[0][0]; dynamic_array[ni.number - 1] = 543; // work around unused variable warnings ok |= (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == '\''x'\'' || dynamic_array[ni.number - 1] != 543); ' # Test code for whether the C compiler supports C11 (global declarations) ac_c_conftest_c11_globals=' // Does the compiler advertise C11 conformance? #if !defined __STDC_VERSION__ || __STDC_VERSION__ < 201112L # error "Compiler does not advertise C11 conformance" #endif // Check _Alignas. char _Alignas (double) aligned_as_double; char _Alignas (0) no_special_alignment; extern char aligned_as_int; char _Alignas (0) _Alignas (int) aligned_as_int; // Check _Alignof. enum { int_alignment = _Alignof (int), int_array_alignment = _Alignof (int[100]), char_alignment = _Alignof (char) }; _Static_assert (0 < -_Alignof (int), "_Alignof is signed"); // Check _Noreturn. int _Noreturn does_not_return (void) { for (;;) continue; } // Check _Static_assert. struct test_static_assert { int x; _Static_assert (sizeof (int) <= sizeof (long int), "_Static_assert does not work in struct"); long int y; }; // Check UTF-8 literals. #define u8 syntax error! char const utf8_literal[] = u8"happens to be ASCII" "another string"; // Check duplicate typedefs. typedef long *long_ptr; typedef long int *long_ptr; typedef long_ptr long_ptr; // Anonymous structures and unions -- taken from C11 6.7.2.1 Example 1. struct anonymous { union { struct { int i; int j; }; struct { int k; long int l; } w; }; int m; } v1; ' # Test code for whether the C compiler supports C11 (body of main). ac_c_conftest_c11_main=' _Static_assert ((offsetof (struct anonymous, i) == offsetof (struct anonymous, w.k)), "Anonymous union alignment botch"); v1.i = 2; v1.w.k = 5; ok |= v1.i != 5; ' # Test code for whether the C compiler supports C11 (complete). ac_c_conftest_c11_program="${ac_c_conftest_c89_globals} ${ac_c_conftest_c99_globals} ${ac_c_conftest_c11_globals} int main (int argc, char **argv) { int ok = 0; ${ac_c_conftest_c89_main} ${ac_c_conftest_c99_main} ${ac_c_conftest_c11_main} return ok; } " # Test code for whether the C compiler supports C99 (complete). ac_c_conftest_c99_program="${ac_c_conftest_c89_globals} ${ac_c_conftest_c99_globals} int main (int argc, char **argv) { int ok = 0; ${ac_c_conftest_c89_main} ${ac_c_conftest_c99_main} return ok; } " # Test code for whether the C compiler supports C89 (complete). ac_c_conftest_c89_program="${ac_c_conftest_c89_globals} int main (int argc, char **argv) { int ok = 0; ${ac_c_conftest_c89_main} return ok; } " as_fn_append ac_header_c_list " stdlib.h stdlib_h HAVE_STDLIB_H" as_fn_append ac_header_c_list " string.h string_h HAVE_STRING_H" as_fn_append ac_header_c_list " inttypes.h inttypes_h HAVE_INTTYPES_H" as_fn_append ac_header_c_list " stdint.h stdint_h HAVE_STDINT_H" as_fn_append ac_header_c_list " strings.h strings_h HAVE_STRINGS_H" as_fn_append ac_header_c_list " sys/stat.h sys_stat_h HAVE_SYS_STAT_H" as_fn_append ac_header_c_list " sys/types.h sys_types_h HAVE_SYS_TYPES_H" as_fn_append ac_header_c_list " unistd.h unistd_h HAVE_UNISTD_H" as_fn_append ac_header_c_list " wchar.h wchar_h HAVE_WCHAR_H" as_fn_append ac_header_c_list " minix/config.h minix_config_h HAVE_MINIX_CONFIG_H" # Auxiliary files required by this configure script. ac_aux_files="config.guess config.sub ltmain.sh compile missing install-sh" # Locations in which to look for auxiliary files. ac_aux_dir_candidates="${srcdir}${PATH_SEPARATOR}${srcdir}/..${PATH_SEPARATOR}${srcdir}/../.." # Search for a directory containing all of the required auxiliary files, # $ac_aux_files, from the $PATH-style list $ac_aux_dir_candidates. # If we don't find one directory that contains all the files we need, # we report the set of missing files from the *first* directory in # $ac_aux_dir_candidates and give up. ac_missing_aux_files="" ac_first_candidate=: printf "%s\n" "$as_me:${as_lineno-$LINENO}: looking for aux files: $ac_aux_files" >&5 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR as_found=false for as_dir in $ac_aux_dir_candidates do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac as_found=: printf "%s\n" "$as_me:${as_lineno-$LINENO}: trying $as_dir" >&5 ac_aux_dir_found=yes ac_install_sh= for ac_aux in $ac_aux_files do # As a special case, if "install-sh" is required, that requirement # can be satisfied by any of "install-sh", "install.sh", or "shtool", # and $ac_install_sh is set appropriately for whichever one is found. if test x"$ac_aux" = x"install-sh" then if test -f "${as_dir}install-sh"; then printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}install-sh found" >&5 ac_install_sh="${as_dir}install-sh -c" elif test -f "${as_dir}install.sh"; then printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}install.sh found" >&5 ac_install_sh="${as_dir}install.sh -c" elif test -f "${as_dir}shtool"; then printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}shtool found" >&5 ac_install_sh="${as_dir}shtool install -c" else ac_aux_dir_found=no if $ac_first_candidate; then ac_missing_aux_files="${ac_missing_aux_files} install-sh" else break fi fi else if test -f "${as_dir}${ac_aux}"; then printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}${ac_aux} found" >&5 else ac_aux_dir_found=no if $ac_first_candidate; then ac_missing_aux_files="${ac_missing_aux_files} ${ac_aux}" else break fi fi fi done if test "$ac_aux_dir_found" = yes; then ac_aux_dir="$as_dir" break fi ac_first_candidate=false as_found=false done IFS=$as_save_IFS if $as_found then : else $as_nop as_fn_error $? "cannot find required auxiliary files:$ac_missing_aux_files" "$LINENO" 5 fi # These three variables are undocumented and unsupported, # and are intended to be withdrawn in a future Autoconf release. # They can cause serious problems if a builder's source tree is in a directory # whose full name contains unusual characters. if test -f "${ac_aux_dir}config.guess"; then ac_config_guess="$SHELL ${ac_aux_dir}config.guess" fi if test -f "${ac_aux_dir}config.sub"; then ac_config_sub="$SHELL ${ac_aux_dir}config.sub" fi if test -f "$ac_aux_dir/configure"; then ac_configure="$SHELL ${ac_aux_dir}configure" fi # Check that the precious variables saved in the cache have kept the same # value. ac_cache_corrupted=false for ac_var in $ac_precious_vars; do eval ac_old_set=\$ac_cv_env_${ac_var}_set eval ac_new_set=\$ac_env_${ac_var}_set eval ac_old_val=\$ac_cv_env_${ac_var}_value eval ac_new_val=\$ac_env_${ac_var}_value case $ac_old_set,$ac_new_set in set,) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 printf "%s\n" "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} ac_cache_corrupted=: ;; ,set) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 printf "%s\n" "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} ac_cache_corrupted=: ;; ,);; *) if test "x$ac_old_val" != "x$ac_new_val"; then # differences in whitespace do not lead to failure. ac_old_val_w=`echo x $ac_old_val` ac_new_val_w=`echo x $ac_new_val` if test "$ac_old_val_w" != "$ac_new_val_w"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 printf "%s\n" "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} ac_cache_corrupted=: else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 printf "%s\n" "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} eval $ac_var=\$ac_old_val fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 printf "%s\n" "$as_me: former value: \`$ac_old_val'" >&2;} { printf "%s\n" "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 printf "%s\n" "$as_me: current value: \`$ac_new_val'" >&2;} fi;; esac # Pass precious variables to config.status. if test "$ac_new_set" = set; then case $ac_new_val in *\'*) ac_arg=$ac_var=`printf "%s\n" "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; *) ac_arg=$ac_var=$ac_new_val ;; esac case " $ac_configure_args " in *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. *) as_fn_append ac_configure_args " '$ac_arg'" ;; esac fi done if $ac_cache_corrupted; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 printf "%s\n" "$as_me: error: changes in the environment can compromise the build" >&2;} as_fn_error $? "run \`${MAKE-make} distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 fi ## -------------------- ## ## Main body of script. ## ## -------------------- ## ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu ac_config_headers="$ac_config_headers config.h" am__api_version='1.16' # Find a good install program. We prefer a C program (faster), # so one script is as good as another. But avoid the broken or # incompatible versions: # SysV /etc/install, /usr/sbin/install # SunOS /usr/etc/install # IRIX /sbin/install # AIX /bin/install # AmigaOS /C/install, which installs bootblocks on floppy discs # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag # AFS /usr/afsws/bin/install, which mishandles nonexistent args # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" # OS/2's system install, which has a completely different semantic # ./install, which can be erroneously created by make from ./install.sh. # Reject install programs that cannot install multiple files. { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 printf %s "checking for a BSD-compatible install... " >&6; } if test -z "$INSTALL"; then if test ${ac_cv_path_install+y} then : printf %s "(cached) " >&6 else $as_nop as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac # Account for fact that we put trailing slashes in our PATH walk. case $as_dir in #(( ./ | /[cC]/* | \ /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ /usr/ucb/* ) ;; *) # OSF1 and SCO ODT 3.0 have their own names for install. # Don't use installbsd from OSF since it installs stuff as root # by default. for ac_prog in ginstall scoinst install; do for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_prog$ac_exec_ext"; then if test $ac_prog = install && grep dspmsg "$as_dir$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # AIX install. It has an incompatible calling convention. : elif test $ac_prog = install && grep pwplus "$as_dir$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # program-specific install script used by HP pwplus--don't use. : else rm -rf conftest.one conftest.two conftest.dir echo one > conftest.one echo two > conftest.two mkdir conftest.dir if "$as_dir$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir/" && test -s conftest.one && test -s conftest.two && test -s conftest.dir/conftest.one && test -s conftest.dir/conftest.two then ac_cv_path_install="$as_dir$ac_prog$ac_exec_ext -c" break 3 fi fi fi done done ;; esac done IFS=$as_save_IFS rm -rf conftest.one conftest.two conftest.dir fi if test ${ac_cv_path_install+y}; then INSTALL=$ac_cv_path_install else # As a last resort, use the slow shell script. Don't cache a # value for INSTALL within a source directory, because that will # break other packages using the cache if that directory is # removed, or if the value is a relative name. INSTALL=$ac_install_sh fi fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 printf "%s\n" "$INSTALL" >&6; } # Use test -z because SunOS4 sh mishandles braces in ${var-val}. # It thinks the first close brace ends the variable substitution. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5 printf %s "checking whether build environment is sane... " >&6; } # Reject unsafe characters in $srcdir or the absolute working directory # name. Accept space and tab only in the latter. am_lf=' ' case `pwd` in *[\\\"\#\$\&\'\`$am_lf]*) as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;; esac case $srcdir in *[\\\"\#\$\&\'\`$am_lf\ \ ]*) as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;; esac # Do 'set' in a subshell so we don't clobber the current shell's # arguments. Must try -L first in case configure is actually a # symlink; some systems play weird games with the mod time of symlinks # (eg FreeBSD returns the mod time of the symlink's containing # directory). if ( am_has_slept=no for am_try in 1 2; do echo "timestamp, slept: $am_has_slept" > conftest.file set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` if test "$*" = "X"; then # -L didn't work. set X `ls -t "$srcdir/configure" conftest.file` fi if test "$*" != "X $srcdir/configure conftest.file" \ && test "$*" != "X conftest.file $srcdir/configure"; then # If neither matched, then we have a broken ls. This can happen # if, for instance, CONFIG_SHELL is bash and it inherits a # broken ls alias from the environment. This has actually # happened. Such a system could not be considered "sane". as_fn_error $? "ls -t appears to fail. Make sure there is not a broken alias in your environment" "$LINENO" 5 fi if test "$2" = conftest.file || test $am_try -eq 2; then break fi # Just in case. sleep 1 am_has_slept=yes done test "$2" = conftest.file ) then # Ok. : else as_fn_error $? "newly created file is older than distributed files! Check your system clock" "$LINENO" 5 fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 printf "%s\n" "yes" >&6; } # If we didn't sleep, we still need to ensure time stamps of config.status and # generated files are strictly newer. am_sleep_pid= if grep 'slept: no' conftest.file >/dev/null 2>&1; then ( sleep 1 ) & am_sleep_pid=$! fi rm -f conftest.file test "$program_prefix" != NONE && program_transform_name="s&^&$program_prefix&;$program_transform_name" # Use a double $ so make ignores it. test "$program_suffix" != NONE && program_transform_name="s&\$&$program_suffix&;$program_transform_name" # Double any \ or $. # By default was `s,x,x', remove it if useless. ac_script='s/[\\$]/&&/g;s/;s,x,x,$//' program_transform_name=`printf "%s\n" "$program_transform_name" | sed "$ac_script"` # Expand $ac_aux_dir to an absolute path. am_aux_dir=`cd "$ac_aux_dir" && pwd` if test x"${MISSING+set}" != xset; then MISSING="\${SHELL} '$am_aux_dir/missing'" fi # Use eval to expand $SHELL if eval "$MISSING --is-lightweight"; then am_missing_run="$MISSING " else am_missing_run= { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5 printf "%s\n" "$as_me: WARNING: 'missing' script is too old or missing" >&2;} fi if test x"${install_sh+set}" != xset; then case $am_aux_dir in *\ * | *\ *) install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; *) install_sh="\${SHELL} $am_aux_dir/install-sh" esac fi # Installed binaries are usually stripped using 'strip' when the user # run "make install-strip". However 'strip' might not be the right # tool to use in cross-compilation environments, therefore Automake # will honor the 'STRIP' environment variable to overrule this program. if test "$cross_compiling" != no; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. set dummy ${ac_tool_prefix}strip; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_STRIP+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$STRIP"; then ac_cv_prog_STRIP="$STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_STRIP="${ac_tool_prefix}strip" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi STRIP=$ac_cv_prog_STRIP if test -n "$STRIP"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 printf "%s\n" "$STRIP" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi fi if test -z "$ac_cv_prog_STRIP"; then ac_ct_STRIP=$STRIP # Extract the first word of "strip", so it can be a program name with args. set dummy strip; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_ac_ct_STRIP+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$ac_ct_STRIP"; then ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_STRIP="strip" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP if test -n "$ac_ct_STRIP"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 printf "%s\n" "$ac_ct_STRIP" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi if test "x$ac_ct_STRIP" = x; then STRIP=":" else case $cross_compiling:$ac_tool_warned in yes:) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac STRIP=$ac_ct_STRIP fi else STRIP="$ac_cv_prog_STRIP" fi fi INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a race-free mkdir -p" >&5 printf %s "checking for a race-free mkdir -p... " >&6; } if test -z "$MKDIR_P"; then if test ${ac_cv_path_mkdir+y} then : printf %s "(cached) " >&6 else $as_nop as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_prog in mkdir gmkdir; do for ac_exec_ext in '' $ac_executable_extensions; do as_fn_executable_p "$as_dir$ac_prog$ac_exec_ext" || continue case `"$as_dir$ac_prog$ac_exec_ext" --version 2>&1` in #( 'mkdir ('*'coreutils) '* | \ 'BusyBox '* | \ 'mkdir (fileutils) '4.1*) ac_cv_path_mkdir=$as_dir$ac_prog$ac_exec_ext break 3;; esac done done done IFS=$as_save_IFS fi test -d ./--version && rmdir ./--version if test ${ac_cv_path_mkdir+y}; then MKDIR_P="$ac_cv_path_mkdir -p" else # As a last resort, use the slow shell script. Don't cache a # value for MKDIR_P within a source directory, because that will # break other packages using the cache if that directory is # removed, or if the value is a relative name. MKDIR_P="$ac_install_sh -d" fi fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5 printf "%s\n" "$MKDIR_P" >&6; } for ac_prog in gawk mawk nawk awk do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_AWK+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$AWK"; then ac_cv_prog_AWK="$AWK" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_AWK="$ac_prog" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi AWK=$ac_cv_prog_AWK if test -n "$AWK"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 printf "%s\n" "$AWK" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi test -n "$AWK" && break done { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 printf %s "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } set x ${MAKE-make} ac_make=`printf "%s\n" "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` if eval test \${ac_cv_prog_make_${ac_make}_set+y} then : printf %s "(cached) " >&6 else $as_nop cat >conftest.make <<\_ACEOF SHELL = /bin/sh all: @echo '@@@%%%=$(MAKE)=@@@%%%' _ACEOF # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. case `${MAKE-make} -f conftest.make 2>/dev/null` in *@@@%%%=?*=@@@%%%*) eval ac_cv_prog_make_${ac_make}_set=yes;; *) eval ac_cv_prog_make_${ac_make}_set=no;; esac rm -f conftest.make fi if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 printf "%s\n" "yes" >&6; } SET_MAKE= else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } SET_MAKE="MAKE=${MAKE-make}" fi rm -rf .tst 2>/dev/null mkdir .tst 2>/dev/null if test -d .tst; then am__leading_dot=. else am__leading_dot=_ fi rmdir .tst 2>/dev/null # Check whether --enable-silent-rules was given. if test ${enable_silent_rules+y} then : enableval=$enable_silent_rules; fi case $enable_silent_rules in # ((( yes) AM_DEFAULT_VERBOSITY=0;; no) AM_DEFAULT_VERBOSITY=1;; *) AM_DEFAULT_VERBOSITY=1;; esac am_make=${MAKE-make} { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5 printf %s "checking whether $am_make supports nested variables... " >&6; } if test ${am_cv_make_support_nested_variables+y} then : printf %s "(cached) " >&6 else $as_nop if printf "%s\n" 'TRUE=$(BAR$(V)) BAR0=false BAR1=true V=1 am__doit: @$(TRUE) .PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then am_cv_make_support_nested_variables=yes else am_cv_make_support_nested_variables=no fi fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5 printf "%s\n" "$am_cv_make_support_nested_variables" >&6; } if test $am_cv_make_support_nested_variables = yes; then AM_V='$(V)' AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' else AM_V=$AM_DEFAULT_VERBOSITY AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY fi AM_BACKSLASH='\' if test "`cd $srcdir && pwd`" != "`pwd`"; then # Use -I$(srcdir) only when $(srcdir) != ., so that make's output # is not polluted with repeated "-I." am__isrc=' -I$(srcdir)' # test to see if srcdir already configured if test -f $srcdir/config.status; then as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5 fi fi # test whether we have cygpath if test -z "$CYGPATH_W"; then if (cygpath --version) >/dev/null 2>/dev/null; then CYGPATH_W='cygpath -w' else CYGPATH_W=echo fi fi # Define the identity of the package. PACKAGE='httrack' VERSION='3.49.5' printf "%s\n" "#define PACKAGE \"$PACKAGE\"" >>confdefs.h printf "%s\n" "#define VERSION \"$VERSION\"" >>confdefs.h # Some tools Automake needs. ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"} AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"} AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"} AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"} MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} # For better backward compatibility. To be removed once Automake 1.9.x # dies out for good. For more background, see: # # mkdir_p='$(MKDIR_P)' # We need awk for the "check" target (and possibly the TAP driver). The # system "awk" is bad on some platforms. # Always define AMTAR for backward compatibility. Yes, it's still used # in the wild :-( We should find a proper way to deprecate it ... AMTAR='$${TAR-tar}' # We'll loop over all known methods to create a tar archive until one works. _am_tools='gnutar pax cpio none' am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -' # Variables for tags utilities; see am/tags.am if test -z "$CTAGS"; then CTAGS=ctags fi if test -z "$ETAGS"; then ETAGS=etags fi if test -z "$CSCOPE"; then CSCOPE=cscope fi # POSIX will say in a future version that running "rm -f" with no argument # is OK; and we want to be able to make that assumption in our Makefile # recipes. So use an aggressive probe to check that the usage we want is # actually supported "in the wild" to an acceptable degree. # See automake bug#10828. # To make any issue more visible, cause the running configure to be aborted # by default if the 'rm' program in use doesn't match our expectations; the # user can still override this though. if rm -f && rm -fr && rm -rf; then : OK; else cat >&2 <<'END' Oops! Your 'rm' program seems unable to run without file operands specified on the command line, even when the '-f' option is present. This is contrary to the behaviour of most rm programs out there, and not conforming with the upcoming POSIX standard: Please tell bug-automake@gnu.org about your system, including the value of your $PATH and any error possibly output before this message. This can help us improve future automake versions. END if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then echo 'Configuration will proceed anyway, since you have set the' >&2 echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 echo >&2 else cat >&2 <<'END' Aborting the configuration process, to ensure you take notice of the issue. You can download and install GNU coreutils to get an 'rm' implementation that behaves properly: . If you want to complete the configuration process using your problematic 'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM to "yes", and re-run configure. END as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5 fi fi VERSION_INFO="2:49:0" { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5 printf %s "checking whether to enable maintainer-specific portions of Makefiles... " >&6; } # Check whether --enable-maintainer-mode was given. if test ${enable_maintainer_mode+y} then : enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval else $as_nop USE_MAINTAINER_MODE=no fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5 printf "%s\n" "$USE_MAINTAINER_MODE" >&6; } if test $USE_MAINTAINER_MODE = yes; then MAINTAINER_MODE_TRUE= MAINTAINER_MODE_FALSE='#' else MAINTAINER_MODE_TRUE='#' MAINTAINER_MODE_FALSE= fi MAINT=$MAINTAINER_MODE_TRUE DEPDIR="${am__leading_dot}deps" ac_config_commands="$ac_config_commands depfiles" { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} supports the include directive" >&5 printf %s "checking whether ${MAKE-make} supports the include directive... " >&6; } cat > confinc.mk << 'END' am__doit: @echo this is the am__doit target >confinc.out .PHONY: am__doit END am__include="#" am__quote= # BSD make does it like this. echo '.include "confinc.mk" # ignored' > confmf.BSD # Other make implementations (GNU, Solaris 10, AIX) do it like this. echo 'include confinc.mk # ignored' > confmf.GNU _am_result=no for s in GNU BSD; do { echo "$as_me:$LINENO: ${MAKE-make} -f confmf.$s && cat confinc.out" >&5 (${MAKE-make} -f confmf.$s && cat confinc.out) >&5 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } case $?:`cat confinc.out 2>/dev/null` in #( '0:this is the am__doit target') : case $s in #( BSD) : am__include='.include' am__quote='"' ;; #( *) : am__include='include' am__quote='' ;; esac ;; #( *) : ;; esac if test "$am__include" != "#"; then _am_result="yes ($s style)" break fi done rm -f confinc.* confmf.* { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${_am_result}" >&5 printf "%s\n" "${_am_result}" >&6; } # Check whether --enable-dependency-tracking was given. if test ${enable_dependency_tracking+y} then : enableval=$enable_dependency_tracking; fi if test "x$enable_dependency_tracking" != xno; then am_depcomp="$ac_aux_dir/depcomp" AMDEPBACKSLASH='\' am__nodep='_no' fi if test "x$enable_dependency_tracking" != xno; then AMDEP_TRUE= AMDEP_FALSE='#' else AMDEP_TRUE='#' AMDEP_FALSE= fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. set dummy ${ac_tool_prefix}gcc; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_CC+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}gcc" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 printf "%s\n" "$CC" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi fi if test -z "$ac_cv_prog_CC"; then ac_ct_CC=$CC # Extract the first word of "gcc", so it can be a program name with args. set dummy gcc; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_ac_ct_CC+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="gcc" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 printf "%s\n" "$ac_ct_CC" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi else CC="$ac_cv_prog_CC" fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. set dummy ${ac_tool_prefix}cc; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_CC+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}cc" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 printf "%s\n" "$CC" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi fi fi if test -z "$CC"; then # Extract the first word of "cc", so it can be a program name with args. set dummy cc; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_CC+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else ac_prog_rejected=no as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then if test "$as_dir$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then ac_prog_rejected=yes continue fi ac_cv_prog_CC="cc" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS if test $ac_prog_rejected = yes; then # We found a bogon in the path, so make sure we never use it. set dummy $ac_cv_prog_CC shift if test $# != 0; then # We chose a different compiler from the bogus one. # However, it has the same basename, so the bogon will be chosen # first if we set CC to just the basename; use the full file name. shift ac_cv_prog_CC="$as_dir$ac_word${1+' '}$@" fi fi fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 printf "%s\n" "$CC" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then for ac_prog in cl.exe do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_CC+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_CC="$ac_tool_prefix$ac_prog" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 printf "%s\n" "$CC" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi test -n "$CC" && break done fi if test -z "$CC"; then ac_ct_CC=$CC for ac_prog in cl.exe do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_ac_ct_CC+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="$ac_prog" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 printf "%s\n" "$ac_ct_CC" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi test -n "$ac_ct_CC" && break done if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi fi fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}clang", so it can be a program name with args. set dummy ${ac_tool_prefix}clang; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_CC+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}clang" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 printf "%s\n" "$CC" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi fi if test -z "$ac_cv_prog_CC"; then ac_ct_CC=$CC # Extract the first word of "clang", so it can be a program name with args. set dummy clang; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_ac_ct_CC+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="clang" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 printf "%s\n" "$ac_ct_CC" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi else CC="$ac_cv_prog_CC" fi fi test -z "$CC" && { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$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; } # Provide some information about the compiler. printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 set X $ac_compile ac_compiler=$2 for ac_option in --version -v -V -qversion -version; do { { ac_try="$ac_compiler $ac_option >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" printf "%s\n" "$ac_try_echo"; } >&5 (eval "$ac_compiler $ac_option >&5") 2>conftest.err ac_status=$? if test -s conftest.err; then sed '10a\ ... rest of stderr output deleted ... 10q' conftest.err >conftest.er1 cat conftest.er1 >&5 fi rm -f conftest.er1 conftest.err printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } done cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" # Try to create an executable without -o first, disregard a.out. # It will help us diagnose broken compilers, and finding out an intuition # of exeext. { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 printf %s "checking whether the C compiler works... " >&6; } ac_link_default=`printf "%s\n" "$ac_link" | sed 's/ -o *conftest[^ ]*//'` # The possible output files: ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" ac_rmfiles= for ac_file in $ac_files do case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; * ) ac_rmfiles="$ac_rmfiles $ac_file";; esac done rm -f $ac_rmfiles if { { ac_try="$ac_link_default" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" printf "%s\n" "$ac_try_echo"; } >&5 (eval "$ac_link_default") 2>&5 ac_status=$? printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } then : # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' # in a Makefile. We should not override ac_cv_exeext if it was cached, # so that the user can short-circuit this test for compilers unknown to # Autoconf. for ac_file in $ac_files '' do test -f "$ac_file" || continue case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; [ab].out ) # We found the default executable, but exeext='' is most # certainly right. break;; *.* ) if test ${ac_cv_exeext+y} && test "$ac_cv_exeext" != no; then :; else ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` fi # We set ac_cv_exeext here because the later test for it is not # safe: cross compilers may not add the suffix if given an `-o' # argument, so we may need to know it at that point already. # Even if this section looks crufty: it has the advantage of # actually working. break;; * ) break;; esac done test "$ac_cv_exeext" = no && ac_cv_exeext= else $as_nop ac_file='' fi if test -z "$ac_file" then : { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } printf "%s\n" "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error 77 "C compiler cannot create executables See \`config.log' for more details" "$LINENO" 5; } else $as_nop { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 printf "%s\n" "yes" >&6; } fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 printf %s "checking for C compiler default output file name... " >&6; } { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 printf "%s\n" "$ac_file" >&6; } ac_exeext=$ac_cv_exeext rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out ac_clean_files=$ac_clean_files_save { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 printf %s "checking for suffix of executables... " >&6; } if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" printf "%s\n" "$ac_try_echo"; } >&5 (eval "$ac_link") 2>&5 ac_status=$? printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } then : # If both `conftest.exe' and `conftest' are `present' (well, observable) # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will # work properly (i.e., refer to `conftest.exe'), while it won't with # `rm'. for ac_file in conftest.exe conftest conftest.*; do test -f "$ac_file" || continue case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` break;; * ) break;; esac done else $as_nop { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$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; } fi rm -f conftest conftest$ac_cv_exeext { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 printf "%s\n" "$ac_cv_exeext" >&6; } rm -f conftest.$ac_ext EXEEXT=$ac_cv_exeext ac_exeext=$EXEEXT cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main (void) { FILE *f = fopen ("conftest.out", "w"); return ferror (f) || fclose (f) != 0; ; return 0; } _ACEOF ac_clean_files="$ac_clean_files conftest.out" # Check that the compiler produces executables we can run. If not, either # the compiler is broken, or we cross compile. { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 printf %s "checking whether we are cross compiling... " >&6; } if test "$cross_compiling" != yes; then { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" printf "%s\n" "$ac_try_echo"; } >&5 (eval "$ac_link") 2>&5 ac_status=$? printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } if { ac_try='./conftest$ac_cv_exeext' { { case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" printf "%s\n" "$ac_try_echo"; } >&5 (eval "$ac_try") 2>&5 ac_status=$? printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; }; then cross_compiling=no else if test "$cross_compiling" = maybe; then cross_compiling=yes else { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error 77 "cannot run C compiled programs. If you meant to cross compile, use \`--host'. See \`config.log' for more details" "$LINENO" 5; } fi fi fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 printf "%s\n" "$cross_compiling" >&6; } rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out ac_clean_files=$ac_clean_files_save { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 printf %s "checking for suffix of object files... " >&6; } if test ${ac_cv_objext+y} then : printf %s "(cached) " >&6 else $as_nop cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF rm -f conftest.o conftest.obj if { { ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" printf "%s\n" "$ac_try_echo"; } >&5 (eval "$ac_compile") 2>&5 ac_status=$? printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } then : for ac_file in conftest.o conftest.obj conftest.*; do test -f "$ac_file" || continue; case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` break;; esac done else $as_nop printf "%s\n" "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$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; } fi rm -f conftest.$ac_cv_objext conftest.$ac_ext fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 printf "%s\n" "$ac_cv_objext" >&6; } OBJEXT=$ac_cv_objext ac_objext=$OBJEXT { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports GNU C" >&5 printf %s "checking whether the compiler supports GNU C... " >&6; } if test ${ac_cv_c_compiler_gnu+y} then : printf %s "(cached) " >&6 else $as_nop cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { #ifndef __GNUC__ choke me #endif ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ac_compiler_gnu=yes else $as_nop ac_compiler_gnu=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ac_cv_c_compiler_gnu=$ac_compiler_gnu fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 printf "%s\n" "$ac_cv_c_compiler_gnu" >&6; } ac_compiler_gnu=$ac_cv_c_compiler_gnu if test $ac_compiler_gnu = yes; then GCC=yes else GCC= fi ac_test_CFLAGS=${CFLAGS+y} ac_save_CFLAGS=$CFLAGS { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 printf %s "checking whether $CC accepts -g... " >&6; } if test ${ac_cv_prog_cc_g+y} then : printf %s "(cached) " >&6 else $as_nop ac_save_c_werror_flag=$ac_c_werror_flag ac_c_werror_flag=yes ac_cv_prog_cc_g=no CFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ac_cv_prog_cc_g=yes else $as_nop CFLAGS="" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : else $as_nop ac_c_werror_flag=$ac_save_c_werror_flag CFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ac_cv_prog_cc_g=yes fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ac_c_werror_flag=$ac_save_c_werror_flag fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 printf "%s\n" "$ac_cv_prog_cc_g" >&6; } if test $ac_test_CFLAGS; then CFLAGS=$ac_save_CFLAGS elif test $ac_cv_prog_cc_g = yes; then if test "$GCC" = yes; then CFLAGS="-g -O2" else CFLAGS="-g" fi else if test "$GCC" = yes; then CFLAGS="-O2" else CFLAGS= fi fi ac_prog_cc_stdc=no if test x$ac_prog_cc_stdc = xno then : { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C11 features" >&5 printf %s "checking for $CC option to enable C11 features... " >&6; } if test ${ac_cv_prog_cc_c11+y} then : printf %s "(cached) " >&6 else $as_nop ac_cv_prog_cc_c11=no ac_save_CC=$CC cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $ac_c_conftest_c11_program _ACEOF for ac_arg in '' -std=gnu11 do CC="$ac_save_CC $ac_arg" if ac_fn_c_try_compile "$LINENO" then : ac_cv_prog_cc_c11=$ac_arg fi rm -f core conftest.err conftest.$ac_objext conftest.beam test "x$ac_cv_prog_cc_c11" != "xno" && break done rm -f conftest.$ac_ext CC=$ac_save_CC fi if test "x$ac_cv_prog_cc_c11" = xno then : { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 printf "%s\n" "unsupported" >&6; } else $as_nop if test "x$ac_cv_prog_cc_c11" = x then : { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 printf "%s\n" "none needed" >&6; } else $as_nop { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c11" >&5 printf "%s\n" "$ac_cv_prog_cc_c11" >&6; } CC="$CC $ac_cv_prog_cc_c11" fi ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c11 ac_prog_cc_stdc=c11 fi fi if test x$ac_prog_cc_stdc = xno then : { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C99 features" >&5 printf %s "checking for $CC option to enable C99 features... " >&6; } if test ${ac_cv_prog_cc_c99+y} then : printf %s "(cached) " >&6 else $as_nop ac_cv_prog_cc_c99=no ac_save_CC=$CC cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $ac_c_conftest_c99_program _ACEOF for ac_arg in '' -std=gnu99 -std=c99 -c99 -qlanglvl=extc1x -qlanglvl=extc99 -AC99 -D_STDC_C99= do CC="$ac_save_CC $ac_arg" if ac_fn_c_try_compile "$LINENO" then : ac_cv_prog_cc_c99=$ac_arg fi rm -f core conftest.err conftest.$ac_objext conftest.beam test "x$ac_cv_prog_cc_c99" != "xno" && break done rm -f conftest.$ac_ext CC=$ac_save_CC fi if test "x$ac_cv_prog_cc_c99" = xno then : { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 printf "%s\n" "unsupported" >&6; } else $as_nop if test "x$ac_cv_prog_cc_c99" = x then : { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 printf "%s\n" "none needed" >&6; } else $as_nop { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5 printf "%s\n" "$ac_cv_prog_cc_c99" >&6; } CC="$CC $ac_cv_prog_cc_c99" fi ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99 ac_prog_cc_stdc=c99 fi fi if test x$ac_prog_cc_stdc = xno then : { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C89 features" >&5 printf %s "checking for $CC option to enable C89 features... " >&6; } if test ${ac_cv_prog_cc_c89+y} then : printf %s "(cached) " >&6 else $as_nop ac_cv_prog_cc_c89=no ac_save_CC=$CC cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $ac_c_conftest_c89_program _ACEOF for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" do CC="$ac_save_CC $ac_arg" if ac_fn_c_try_compile "$LINENO" then : ac_cv_prog_cc_c89=$ac_arg fi rm -f core conftest.err conftest.$ac_objext conftest.beam test "x$ac_cv_prog_cc_c89" != "xno" && break done rm -f conftest.$ac_ext CC=$ac_save_CC fi if test "x$ac_cv_prog_cc_c89" = xno then : { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 printf "%s\n" "unsupported" >&6; } else $as_nop if test "x$ac_cv_prog_cc_c89" = x then : { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 printf "%s\n" "none needed" >&6; } else $as_nop { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 printf "%s\n" "$ac_cv_prog_cc_c89" >&6; } CC="$CC $ac_cv_prog_cc_c89" fi ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89 ac_prog_cc_stdc=c89 fi fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5 printf %s "checking whether $CC understands -c and -o together... " >&6; } if test ${am_cv_prog_cc_c_o+y} then : printf %s "(cached) " >&6 else $as_nop cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF # Make sure it works both with $CC and with simple cc. # Following AC_PROG_CC_C_O, we do the test twice because some # compilers refuse to overwrite an existing .o file with -o, # though they will create one. am_cv_prog_cc_c_o=yes for am_i in 1 2; do if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5 ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } \ && test -f conftest2.$ac_objext; then : OK else am_cv_prog_cc_c_o=no break fi done rm -f core conftest* unset am_i fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5 printf "%s\n" "$am_cv_prog_cc_c_o" >&6; } if test "$am_cv_prog_cc_c_o" != yes; then # Losing compiler, so override with the script. # FIXME: It is wrong to rewrite CC. # But if we don't then we get into trouble of one sort or another. # A longer-term fix would be to have automake use am__CC in this case, # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" CC="$am_aux_dir/compile $CC" fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu depcc="$CC" am_compiler_list= { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 printf %s "checking dependency style of $depcc... " >&6; } if test ${am_cv_CC_dependencies_compiler_type+y} then : printf %s "(cached) " >&6 else $as_nop if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up # making a dummy file named 'D' -- because '-MD' means "put the output # in D". rm -rf conftest.dir mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. cp "$am_depcomp" conftest.dir cd conftest.dir # We will build objects and dependencies in a subdirectory because # it helps to detect inapplicable dependency modes. For instance # both Tru64's cc and ICC support -MD to output dependencies as a # side effect of compilation, but ICC will put the dependencies in # the current directory while Tru64 will put them in the object # directory. mkdir sub am_cv_CC_dependencies_compiler_type=none if test "$am_compiler_list" = ""; then am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` fi am__universal=false case " $depcc " in #( *\ -arch\ *\ -arch\ *) am__universal=true ;; esac for depmode in $am_compiler_list; do # Setup a source with many dependencies, because some compilers # like to wrap large dependency lists on column 80 (with \), and # we should not choose a depcomp mode which is confused by this. # # We need to recreate these files for each test, as the compiler may # overwrite some of them when testing with obscure command lines. # This happens at least with the AIX C compiler. : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with # Solaris 10 /bin/sh. echo '/* dummy */' > sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf # We check with '-c' and '-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly # handle '-M -o', and we need to detect this. Also, some Intel # versions had trouble with output in subdirs. am__obj=sub/conftest.${OBJEXT-o} am__minus_obj="-o $am__obj" case $depmode in gcc) # This depmode causes a compiler race in universal mode. test "$am__universal" = false || continue ;; nosideeffect) # After this tag, mechanisms are not by side-effect, so they'll # only be used when explicitly requested. if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; msvc7 | msvc7msys | msvisualcpp | msvcmsys) # This compiler won't grok '-c -o', but also, the minuso test has # not run yet. These depmodes are late enough in the game, and # so weak that their functioning should not be impacted. am__obj=conftest.${OBJEXT-o} am__minus_obj= ;; none) break ;; esac if depmode=$depmode \ source=sub/conftest.c object=$am__obj \ depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ >/dev/null 2>conftest.err && grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && grep $am__obj sub/conftest.Po > /dev/null 2>&1 && ${MAKE-make} -s -f confmf > /dev/null 2>&1; then # icc doesn't choke on unknown options, it will just issue warnings # or remarks (even with -Werror). So we grep stderr for any message # that says an option was ignored or not supported. # When given -MP, icc 7.0 and 7.1 complain thusly: # icc: Command line warning: ignoring option '-M'; no argument required # The diagnosis changed in icc 8.0: # icc: Command line remark: option '-MP' not supported if (grep 'ignoring option' conftest.err || grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else am_cv_CC_dependencies_compiler_type=$depmode break fi fi done cd .. rm -rf conftest.dir else am_cv_CC_dependencies_compiler_type=none fi fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 printf "%s\n" "$am_cv_CC_dependencies_compiler_type" >&6; } CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type if test "x$enable_dependency_tracking" != xno \ && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then am__fastdepCC_TRUE= am__fastdepCC_FALSE='#' else am__fastdepCC_TRUE='#' am__fastdepCC_FALSE= fi ac_header= ac_cache= for ac_item in $ac_header_c_list do if test $ac_cache; then ac_fn_c_check_header_compile "$LINENO" $ac_header ac_cv_header_$ac_cache "$ac_includes_default" if eval test \"x\$ac_cv_header_$ac_cache\" = xyes; then printf "%s\n" "#define $ac_item 1" >> confdefs.h fi ac_header= ac_cache= elif test $ac_header; then ac_cache=$ac_item else ac_header=$ac_item fi done if test $ac_cv_header_stdlib_h = yes && test $ac_cv_header_string_h = yes then : printf "%s\n" "#define STDC_HEADERS 1" >>confdefs.h fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5 printf %s "checking whether it is safe to define __EXTENSIONS__... " >&6; } if test ${ac_cv_safe_to_define___extensions__+y} then : printf %s "(cached) " >&6 else $as_nop cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ # define __EXTENSIONS__ 1 $ac_includes_default int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ac_cv_safe_to_define___extensions__=yes else $as_nop ac_cv_safe_to_define___extensions__=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5 printf "%s\n" "$ac_cv_safe_to_define___extensions__" >&6; } { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether _XOPEN_SOURCE should be defined" >&5 printf %s "checking whether _XOPEN_SOURCE should be defined... " >&6; } if test ${ac_cv_should_define__xopen_source+y} then : printf %s "(cached) " >&6 else $as_nop ac_cv_should_define__xopen_source=no if test $ac_cv_header_wchar_h = yes then : cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include mbstate_t x; int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : else $as_nop cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #define _XOPEN_SOURCE 500 #include mbstate_t x; int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ac_cv_should_define__xopen_source=yes fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext fi fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_should_define__xopen_source" >&5 printf "%s\n" "$ac_cv_should_define__xopen_source" >&6; } printf "%s\n" "#define _ALL_SOURCE 1" >>confdefs.h printf "%s\n" "#define _DARWIN_C_SOURCE 1" >>confdefs.h printf "%s\n" "#define _GNU_SOURCE 1" >>confdefs.h printf "%s\n" "#define _HPUX_ALT_XOPEN_SOCKET_API 1" >>confdefs.h printf "%s\n" "#define _NETBSD_SOURCE 1" >>confdefs.h printf "%s\n" "#define _OPENBSD_SOURCE 1" >>confdefs.h printf "%s\n" "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h printf "%s\n" "#define __STDC_WANT_IEC_60559_ATTRIBS_EXT__ 1" >>confdefs.h printf "%s\n" "#define __STDC_WANT_IEC_60559_BFP_EXT__ 1" >>confdefs.h printf "%s\n" "#define __STDC_WANT_IEC_60559_DFP_EXT__ 1" >>confdefs.h printf "%s\n" "#define __STDC_WANT_IEC_60559_FUNCS_EXT__ 1" >>confdefs.h printf "%s\n" "#define __STDC_WANT_IEC_60559_TYPES_EXT__ 1" >>confdefs.h printf "%s\n" "#define __STDC_WANT_LIB_EXT2__ 1" >>confdefs.h printf "%s\n" "#define __STDC_WANT_MATH_SPEC_FUNCS__ 1" >>confdefs.h printf "%s\n" "#define _TANDEM_SOURCE 1" >>confdefs.h if test $ac_cv_header_minix_config_h = yes then : MINIX=yes printf "%s\n" "#define _MINIX 1" >>confdefs.h printf "%s\n" "#define _POSIX_SOURCE 1" >>confdefs.h printf "%s\n" "#define _POSIX_1_SOURCE 2" >>confdefs.h else $as_nop MINIX= fi if test $ac_cv_safe_to_define___extensions__ = yes then : printf "%s\n" "#define __EXTENSIONS__ 1" >>confdefs.h fi if test $ac_cv_should_define__xopen_source = yes then : printf "%s\n" "#define _XOPEN_SOURCE 500" >>confdefs.h fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. set dummy ${ac_tool_prefix}gcc; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_CC+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}gcc" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 printf "%s\n" "$CC" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi fi if test -z "$ac_cv_prog_CC"; then ac_ct_CC=$CC # Extract the first word of "gcc", so it can be a program name with args. set dummy gcc; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_ac_ct_CC+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="gcc" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 printf "%s\n" "$ac_ct_CC" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi else CC="$ac_cv_prog_CC" fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. set dummy ${ac_tool_prefix}cc; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_CC+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}cc" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 printf "%s\n" "$CC" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi fi fi if test -z "$CC"; then # Extract the first word of "cc", so it can be a program name with args. set dummy cc; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_CC+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else ac_prog_rejected=no as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then if test "$as_dir$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then ac_prog_rejected=yes continue fi ac_cv_prog_CC="cc" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS if test $ac_prog_rejected = yes; then # We found a bogon in the path, so make sure we never use it. set dummy $ac_cv_prog_CC shift if test $# != 0; then # We chose a different compiler from the bogus one. # However, it has the same basename, so the bogon will be chosen # first if we set CC to just the basename; use the full file name. shift ac_cv_prog_CC="$as_dir$ac_word${1+' '}$@" fi fi fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 printf "%s\n" "$CC" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then for ac_prog in cl.exe do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_CC+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_CC="$ac_tool_prefix$ac_prog" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 printf "%s\n" "$CC" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi test -n "$CC" && break done fi if test -z "$CC"; then ac_ct_CC=$CC for ac_prog in cl.exe do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_ac_ct_CC+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="$ac_prog" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 printf "%s\n" "$ac_ct_CC" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi test -n "$ac_ct_CC" && break done if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi fi fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}clang", so it can be a program name with args. set dummy ${ac_tool_prefix}clang; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_CC+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}clang" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 printf "%s\n" "$CC" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi fi if test -z "$ac_cv_prog_CC"; then ac_ct_CC=$CC # Extract the first word of "clang", so it can be a program name with args. set dummy clang; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_ac_ct_CC+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="clang" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 printf "%s\n" "$ac_ct_CC" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi else CC="$ac_cv_prog_CC" fi fi test -z "$CC" && { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$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; } # Provide some information about the compiler. printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 set X $ac_compile ac_compiler=$2 for ac_option in --version -v -V -qversion -version; do { { ac_try="$ac_compiler $ac_option >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" printf "%s\n" "$ac_try_echo"; } >&5 (eval "$ac_compiler $ac_option >&5") 2>conftest.err ac_status=$? if test -s conftest.err; then sed '10a\ ... rest of stderr output deleted ... 10q' conftest.err >conftest.er1 cat conftest.er1 >&5 fi rm -f conftest.er1 conftest.err printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } done { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports GNU C" >&5 printf %s "checking whether the compiler supports GNU C... " >&6; } if test ${ac_cv_c_compiler_gnu+y} then : printf %s "(cached) " >&6 else $as_nop cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { #ifndef __GNUC__ choke me #endif ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ac_compiler_gnu=yes else $as_nop ac_compiler_gnu=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ac_cv_c_compiler_gnu=$ac_compiler_gnu fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 printf "%s\n" "$ac_cv_c_compiler_gnu" >&6; } ac_compiler_gnu=$ac_cv_c_compiler_gnu if test $ac_compiler_gnu = yes; then GCC=yes else GCC= fi ac_test_CFLAGS=${CFLAGS+y} ac_save_CFLAGS=$CFLAGS { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 printf %s "checking whether $CC accepts -g... " >&6; } if test ${ac_cv_prog_cc_g+y} then : printf %s "(cached) " >&6 else $as_nop ac_save_c_werror_flag=$ac_c_werror_flag ac_c_werror_flag=yes ac_cv_prog_cc_g=no CFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ac_cv_prog_cc_g=yes else $as_nop CFLAGS="" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : else $as_nop ac_c_werror_flag=$ac_save_c_werror_flag CFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ac_cv_prog_cc_g=yes fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ac_c_werror_flag=$ac_save_c_werror_flag fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 printf "%s\n" "$ac_cv_prog_cc_g" >&6; } if test $ac_test_CFLAGS; then CFLAGS=$ac_save_CFLAGS elif test $ac_cv_prog_cc_g = yes; then if test "$GCC" = yes; then CFLAGS="-g -O2" else CFLAGS="-g" fi else if test "$GCC" = yes; then CFLAGS="-O2" else CFLAGS= fi fi ac_prog_cc_stdc=no if test x$ac_prog_cc_stdc = xno then : { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C11 features" >&5 printf %s "checking for $CC option to enable C11 features... " >&6; } if test ${ac_cv_prog_cc_c11+y} then : printf %s "(cached) " >&6 else $as_nop ac_cv_prog_cc_c11=no ac_save_CC=$CC cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $ac_c_conftest_c11_program _ACEOF for ac_arg in '' -std=gnu11 do CC="$ac_save_CC $ac_arg" if ac_fn_c_try_compile "$LINENO" then : ac_cv_prog_cc_c11=$ac_arg fi rm -f core conftest.err conftest.$ac_objext conftest.beam test "x$ac_cv_prog_cc_c11" != "xno" && break done rm -f conftest.$ac_ext CC=$ac_save_CC fi if test "x$ac_cv_prog_cc_c11" = xno then : { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 printf "%s\n" "unsupported" >&6; } else $as_nop if test "x$ac_cv_prog_cc_c11" = x then : { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 printf "%s\n" "none needed" >&6; } else $as_nop { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c11" >&5 printf "%s\n" "$ac_cv_prog_cc_c11" >&6; } CC="$CC $ac_cv_prog_cc_c11" fi ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c11 ac_prog_cc_stdc=c11 fi fi if test x$ac_prog_cc_stdc = xno then : { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C99 features" >&5 printf %s "checking for $CC option to enable C99 features... " >&6; } if test ${ac_cv_prog_cc_c99+y} then : printf %s "(cached) " >&6 else $as_nop ac_cv_prog_cc_c99=no ac_save_CC=$CC cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $ac_c_conftest_c99_program _ACEOF for ac_arg in '' -std=gnu99 -std=c99 -c99 -qlanglvl=extc1x -qlanglvl=extc99 -AC99 -D_STDC_C99= do CC="$ac_save_CC $ac_arg" if ac_fn_c_try_compile "$LINENO" then : ac_cv_prog_cc_c99=$ac_arg fi rm -f core conftest.err conftest.$ac_objext conftest.beam test "x$ac_cv_prog_cc_c99" != "xno" && break done rm -f conftest.$ac_ext CC=$ac_save_CC fi if test "x$ac_cv_prog_cc_c99" = xno then : { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 printf "%s\n" "unsupported" >&6; } else $as_nop if test "x$ac_cv_prog_cc_c99" = x then : { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 printf "%s\n" "none needed" >&6; } else $as_nop { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5 printf "%s\n" "$ac_cv_prog_cc_c99" >&6; } CC="$CC $ac_cv_prog_cc_c99" fi ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99 ac_prog_cc_stdc=c99 fi fi if test x$ac_prog_cc_stdc = xno then : { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C89 features" >&5 printf %s "checking for $CC option to enable C89 features... " >&6; } if test ${ac_cv_prog_cc_c89+y} then : printf %s "(cached) " >&6 else $as_nop ac_cv_prog_cc_c89=no ac_save_CC=$CC cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $ac_c_conftest_c89_program _ACEOF for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" do CC="$ac_save_CC $ac_arg" if ac_fn_c_try_compile "$LINENO" then : ac_cv_prog_cc_c89=$ac_arg fi rm -f core conftest.err conftest.$ac_objext conftest.beam test "x$ac_cv_prog_cc_c89" != "xno" && break done rm -f conftest.$ac_ext CC=$ac_save_CC fi if test "x$ac_cv_prog_cc_c89" = xno then : { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 printf "%s\n" "unsupported" >&6; } else $as_nop if test "x$ac_cv_prog_cc_c89" = x then : { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 printf "%s\n" "none needed" >&6; } else $as_nop { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 printf "%s\n" "$ac_cv_prog_cc_c89" >&6; } CC="$CC $ac_cv_prog_cc_c89" fi ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89 ac_prog_cc_stdc=c89 fi fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5 printf %s "checking whether $CC understands -c and -o together... " >&6; } if test ${am_cv_prog_cc_c_o+y} then : printf %s "(cached) " >&6 else $as_nop cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF # Make sure it works both with $CC and with simple cc. # Following AC_PROG_CC_C_O, we do the test twice because some # compilers refuse to overwrite an existing .o file with -o, # though they will create one. am_cv_prog_cc_c_o=yes for am_i in 1 2; do if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5 ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } \ && test -f conftest2.$ac_objext; then : OK else am_cv_prog_cc_c_o=no break fi done rm -f core conftest* unset am_i fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5 printf "%s\n" "$am_cv_prog_cc_c_o" >&6; } if test "$am_cv_prog_cc_c_o" != yes; then # Losing compiler, so override with the script. # FIXME: It is wrong to rewrite CC. # But if we don't then we get into trouble of one sort or another. # A longer-term fix would be to have automake use am__CC in this case, # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" CC="$am_aux_dir/compile $CC" fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu depcc="$CC" am_compiler_list= { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 printf %s "checking dependency style of $depcc... " >&6; } if test ${am_cv_CC_dependencies_compiler_type+y} then : printf %s "(cached) " >&6 else $as_nop if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up # making a dummy file named 'D' -- because '-MD' means "put the output # in D". rm -rf conftest.dir mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. cp "$am_depcomp" conftest.dir cd conftest.dir # We will build objects and dependencies in a subdirectory because # it helps to detect inapplicable dependency modes. For instance # both Tru64's cc and ICC support -MD to output dependencies as a # side effect of compilation, but ICC will put the dependencies in # the current directory while Tru64 will put them in the object # directory. mkdir sub am_cv_CC_dependencies_compiler_type=none if test "$am_compiler_list" = ""; then am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` fi am__universal=false case " $depcc " in #( *\ -arch\ *\ -arch\ *) am__universal=true ;; esac for depmode in $am_compiler_list; do # Setup a source with many dependencies, because some compilers # like to wrap large dependency lists on column 80 (with \), and # we should not choose a depcomp mode which is confused by this. # # We need to recreate these files for each test, as the compiler may # overwrite some of them when testing with obscure command lines. # This happens at least with the AIX C compiler. : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with # Solaris 10 /bin/sh. echo '/* dummy */' > sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf # We check with '-c' and '-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly # handle '-M -o', and we need to detect this. Also, some Intel # versions had trouble with output in subdirs. am__obj=sub/conftest.${OBJEXT-o} am__minus_obj="-o $am__obj" case $depmode in gcc) # This depmode causes a compiler race in universal mode. test "$am__universal" = false || continue ;; nosideeffect) # After this tag, mechanisms are not by side-effect, so they'll # only be used when explicitly requested. if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; msvc7 | msvc7msys | msvisualcpp | msvcmsys) # This compiler won't grok '-c -o', but also, the minuso test has # not run yet. These depmodes are late enough in the game, and # so weak that their functioning should not be impacted. am__obj=conftest.${OBJEXT-o} am__minus_obj= ;; none) break ;; esac if depmode=$depmode \ source=sub/conftest.c object=$am__obj \ depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ >/dev/null 2>conftest.err && grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && grep $am__obj sub/conftest.Po > /dev/null 2>&1 && ${MAKE-make} -s -f confmf > /dev/null 2>&1; then # icc doesn't choke on unknown options, it will just issue warnings # or remarks (even with -Werror). So we grep stderr for any message # that says an option was ignored or not supported. # When given -MP, icc 7.0 and 7.1 complain thusly: # icc: Command line warning: ignoring option '-M'; no argument required # The diagnosis changed in icc 8.0: # icc: Command line remark: option '-MP' not supported if (grep 'ignoring option' conftest.err || grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else am_cv_CC_dependencies_compiler_type=$depmode break fi fi done cd .. rm -rf conftest.dir else am_cv_CC_dependencies_compiler_type=none fi fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 printf "%s\n" "$am_cv_CC_dependencies_compiler_type" >&6; } CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type if test "x$enable_dependency_tracking" != xno \ && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then am__fastdepCC_TRUE= am__fastdepCC_FALSE='#' else am__fastdepCC_TRUE='#' am__fastdepCC_FALSE= fi # Autoupdate added the next two lines to ensure that your configure # script's behavior did not change. They are probably safe to remove. { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 printf %s "checking for grep that handles long lines and -e... " >&6; } if test ${ac_cv_path_GREP+y} then : printf %s "(cached) " >&6 else $as_nop if test -z "$GREP"; then ac_path_GREP_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_prog in grep ggrep do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_GREP="$as_dir$ac_prog$ac_exec_ext" as_fn_executable_p "$ac_path_GREP" || continue # Check for GNU ac_path_GREP and select it if it is found. # Check for GNU $ac_path_GREP case `"$ac_path_GREP" --version 2>&1` in *GNU*) ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; *) ac_count=0 printf %s 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" printf "%s\n" 'GREP' >> "conftest.nl" "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break as_fn_arith $ac_count + 1 && ac_count=$as_val if test $ac_count -gt ${ac_path_GREP_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_GREP_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_GREP"; then as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 fi else ac_cv_path_GREP=$GREP fi fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 printf "%s\n" "$ac_cv_path_GREP" >&6; } GREP="$ac_cv_path_GREP" { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 printf %s "checking for egrep... " >&6; } if test ${ac_cv_path_EGREP+y} then : printf %s "(cached) " >&6 else $as_nop if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 then ac_cv_path_EGREP="$GREP -E" else if test -z "$EGREP"; then ac_path_EGREP_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_prog in egrep do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_EGREP="$as_dir$ac_prog$ac_exec_ext" as_fn_executable_p "$ac_path_EGREP" || continue # Check for GNU ac_path_EGREP and select it if it is found. # Check for GNU $ac_path_EGREP case `"$ac_path_EGREP" --version 2>&1` in *GNU*) ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; *) ac_count=0 printf %s 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" printf "%s\n" 'EGREP' >> "conftest.nl" "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break as_fn_arith $ac_count + 1 && ac_count=$as_val if test $ac_count -gt ${ac_path_EGREP_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_EGREP_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_EGREP"; then as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 fi else ac_cv_path_EGREP=$EGREP fi fi fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 printf "%s\n" "$ac_cv_path_EGREP" >&6; } EGREP="$ac_cv_path_EGREP" case `pwd` in *\ * | *\ *) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5 printf "%s\n" "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;; esac macro_version='2.4.7' macro_revision='2.4.7' ltmain=$ac_aux_dir/ltmain.sh # Make sure we can run config.sub. $SHELL "${ac_aux_dir}config.sub" sun4 >/dev/null 2>&1 || as_fn_error $? "cannot run $SHELL ${ac_aux_dir}config.sub" "$LINENO" 5 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 printf %s "checking build system type... " >&6; } if test ${ac_cv_build+y} then : printf %s "(cached) " >&6 else $as_nop ac_build_alias=$build_alias test "x$ac_build_alias" = x && ac_build_alias=`$SHELL "${ac_aux_dir}config.guess"` test "x$ac_build_alias" = x && as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 ac_cv_build=`$SHELL "${ac_aux_dir}config.sub" $ac_build_alias` || as_fn_error $? "$SHELL ${ac_aux_dir}config.sub $ac_build_alias failed" "$LINENO" 5 fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 printf "%s\n" "$ac_cv_build" >&6; } case $ac_cv_build in *-*-*) ;; *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; esac build=$ac_cv_build ac_save_IFS=$IFS; IFS='-' set x $ac_cv_build shift build_cpu=$1 build_vendor=$2 shift; shift # Remember, the first character of IFS is used to create $*, # except with old shells: build_os=$* IFS=$ac_save_IFS case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 printf %s "checking host system type... " >&6; } if test ${ac_cv_host+y} then : printf %s "(cached) " >&6 else $as_nop if test "x$host_alias" = x; then ac_cv_host=$ac_cv_build else ac_cv_host=`$SHELL "${ac_aux_dir}config.sub" $host_alias` || as_fn_error $? "$SHELL ${ac_aux_dir}config.sub $host_alias failed" "$LINENO" 5 fi fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 printf "%s\n" "$ac_cv_host" >&6; } case $ac_cv_host in *-*-*) ;; *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; esac host=$ac_cv_host ac_save_IFS=$IFS; IFS='-' set x $ac_cv_host shift host_cpu=$1 host_vendor=$2 shift; shift # Remember, the first character of IFS is used to create $*, # except with old shells: host_os=$* IFS=$ac_save_IFS case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac # Backslashify metacharacters that are still active within # double-quoted strings. sed_quote_subst='s/\(["`$\\]\)/\\\1/g' # Same as above, but do not quote variable references. double_quote_subst='s/\(["`\\]\)/\\\1/g' # Sed substitution to delay expansion of an escaped shell variable in a # double_quote_subst'ed string. delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' # Sed substitution to delay expansion of an escaped single quote. delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' # Sed substitution to avoid accidental globbing in evaled expressions no_glob_subst='s/\*/\\\*/g' ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5 printf %s "checking how to print strings... " >&6; } # Test print first, because it will be a builtin if present. if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then ECHO='print -r --' elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then ECHO='printf %s\n' else # Use this function as a fallback that always works. func_fallback_echo () { eval 'cat <<_LTECHO_EOF $1 _LTECHO_EOF' } ECHO='func_fallback_echo' fi # func_echo_all arg... # Invoke $ECHO with all args, space-separated. func_echo_all () { $ECHO "" } case $ECHO in printf*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: printf" >&5 printf "%s\n" "printf" >&6; } ;; print*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: print -r" >&5 printf "%s\n" "print -r" >&6; } ;; *) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: cat" >&5 printf "%s\n" "cat" >&6; } ;; esac { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 printf %s "checking for a sed that does not truncate output... " >&6; } if test ${ac_cv_path_SED+y} then : printf %s "(cached) " >&6 else $as_nop ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ for ac_i in 1 2 3 4 5 6 7; do ac_script="$ac_script$as_nl$ac_script" done echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed { ac_script=; unset ac_script;} if test -z "$SED"; then ac_path_SED_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_prog in sed gsed do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_SED="$as_dir$ac_prog$ac_exec_ext" as_fn_executable_p "$ac_path_SED" || continue # Check for GNU ac_path_SED and select it if it is found. # Check for GNU $ac_path_SED case `"$ac_path_SED" --version 2>&1` in *GNU*) ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; *) ac_count=0 printf %s 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" printf "%s\n" '' >> "conftest.nl" "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break as_fn_arith $ac_count + 1 && ac_count=$as_val if test $ac_count -gt ${ac_path_SED_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_SED="$ac_path_SED" ac_path_SED_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_SED_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_SED"; then as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 fi else ac_cv_path_SED=$SED fi fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 printf "%s\n" "$ac_cv_path_SED" >&6; } SED="$ac_cv_path_SED" rm -f conftest.sed test -z "$SED" && SED=sed Xsed="$SED -e 1s/^X//" { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 printf %s "checking for fgrep... " >&6; } if test ${ac_cv_path_FGREP+y} then : printf %s "(cached) " >&6 else $as_nop if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 then ac_cv_path_FGREP="$GREP -F" else if test -z "$FGREP"; then ac_path_FGREP_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_prog in fgrep do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_FGREP="$as_dir$ac_prog$ac_exec_ext" as_fn_executable_p "$ac_path_FGREP" || continue # Check for GNU ac_path_FGREP and select it if it is found. # Check for GNU $ac_path_FGREP case `"$ac_path_FGREP" --version 2>&1` in *GNU*) ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; *) ac_count=0 printf %s 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" printf "%s\n" 'FGREP' >> "conftest.nl" "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break as_fn_arith $ac_count + 1 && ac_count=$as_val if test $ac_count -gt ${ac_path_FGREP_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_FGREP_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_FGREP"; then as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 fi else ac_cv_path_FGREP=$FGREP fi fi fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 printf "%s\n" "$ac_cv_path_FGREP" >&6; } FGREP="$ac_cv_path_FGREP" test -z "$GREP" && GREP=grep # Check whether --with-gnu-ld was given. if test ${with_gnu_ld+y} then : withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes else $as_nop with_gnu_ld=no fi ac_prog=ld if test yes = "$GCC"; then # Check if gcc -print-prog-name=ld gives a path. { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 printf %s "checking for ld used by $CC... " >&6; } case $host in *-*-mingw*) # gcc leaves a trailing carriage return, which upsets mingw ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; *) ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; esac case $ac_prog in # Accept absolute paths. [\\/]* | ?:[\\/]*) re_direlt='/[^/][^/]*/\.\./' # Canonicalize the pathname of ld ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` done test -z "$LD" && LD=$ac_prog ;; "") # If it fails, then pretend we aren't using GCC. ac_prog=ld ;; *) # If it is relative, then search for the first ld in PATH. with_gnu_ld=unknown ;; esac elif test yes = "$with_gnu_ld"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 printf %s "checking for GNU ld... " >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 printf %s "checking for non-GNU ld... " >&6; } fi if test ${lt_cv_path_LD+y} then : printf %s "(cached) " >&6 else $as_nop if test -z "$LD"; then lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR for ac_dir in $PATH; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then lt_cv_path_LD=$ac_dir/$ac_prog # Check to see if the program is GNU ld. I'd rather use --version, # but apparently some variants of GNU ld only accept -v. # Break only if it was the GNU/non-GNU ld that we prefer. case `"$lt_cv_path_LD" -v 2>&1 &5 printf "%s\n" "$LD" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 printf %s "checking if the linker ($LD) is GNU ld... " >&6; } if test ${lt_cv_prog_gnu_ld+y} then : printf %s "(cached) " >&6 else $as_nop # I'd rather use --version here, but apparently some GNU lds only accept -v. case `$LD -v 2>&1 &5 printf "%s\n" "$lt_cv_prog_gnu_ld" >&6; } with_gnu_ld=$lt_cv_prog_gnu_ld { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5 printf %s "checking for BSD- or MS-compatible name lister (nm)... " >&6; } if test ${lt_cv_path_NM+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$NM"; then # Let the user override the test. lt_cv_path_NM=$NM else lt_nm_to_check=${ac_tool_prefix}nm if test -n "$ac_tool_prefix" && test "$build" = "$host"; then lt_nm_to_check="$lt_nm_to_check nm" fi for lt_tmp_nm in $lt_nm_to_check; do lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. tmp_nm=$ac_dir/$lt_tmp_nm if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then # Check to see if the nm accepts a BSD-compat flag. # Adding the 'sed 1q' prevents false positives on HP-UX, which says: # nm: unknown option "B" ignored # Tru64's nm complains that /dev/null is an invalid object file # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty case $build_os in mingw*) lt_bad_file=conftest.nm/nofile ;; *) lt_bad_file=/dev/null ;; esac case `"$tmp_nm" -B $lt_bad_file 2>&1 | $SED '1q'` in *$lt_bad_file* | *'Invalid file or object type'*) lt_cv_path_NM="$tmp_nm -B" break 2 ;; *) case `"$tmp_nm" -p /dev/null 2>&1 | $SED '1q'` in */dev/null*) lt_cv_path_NM="$tmp_nm -p" break 2 ;; *) lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but continue # so that we can try to find one that supports BSD flags ;; esac ;; esac fi done IFS=$lt_save_ifs done : ${lt_cv_path_NM=no} fi fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5 printf "%s\n" "$lt_cv_path_NM" >&6; } if test no != "$lt_cv_path_NM"; then NM=$lt_cv_path_NM else # Didn't find any BSD compatible name lister, look for dumpbin. if test -n "$DUMPBIN"; then : # Let the user override the test. else if test -n "$ac_tool_prefix"; then for ac_prog in dumpbin "link -dump" do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_DUMPBIN+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$DUMPBIN"; then ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi DUMPBIN=$ac_cv_prog_DUMPBIN if test -n "$DUMPBIN"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 printf "%s\n" "$DUMPBIN" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi test -n "$DUMPBIN" && break done fi if test -z "$DUMPBIN"; then ac_ct_DUMPBIN=$DUMPBIN for ac_prog in dumpbin "link -dump" do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_ac_ct_DUMPBIN+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$ac_ct_DUMPBIN"; then ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_DUMPBIN="$ac_prog" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN if test -n "$ac_ct_DUMPBIN"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5 printf "%s\n" "$ac_ct_DUMPBIN" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi test -n "$ac_ct_DUMPBIN" && break done if test "x$ac_ct_DUMPBIN" = x; then DUMPBIN=":" else case $cross_compiling:$ac_tool_warned in yes:) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac DUMPBIN=$ac_ct_DUMPBIN fi fi case `$DUMPBIN -symbols -headers /dev/null 2>&1 | $SED '1q'` in *COFF*) DUMPBIN="$DUMPBIN -symbols -headers" ;; *) DUMPBIN=: ;; esac fi if test : != "$DUMPBIN"; then NM=$DUMPBIN fi fi test -z "$NM" && NM=nm { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5 printf %s "checking the name lister ($NM) interface... " >&6; } if test ${lt_cv_nm_interface+y} then : printf %s "(cached) " >&6 else $as_nop lt_cv_nm_interface="BSD nm" echo "int some_variable = 0;" > conftest.$ac_ext (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5) (eval "$ac_compile" 2>conftest.err) cat conftest.err >&5 (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5) (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) cat conftest.err >&5 (eval echo "\"\$as_me:$LINENO: output\"" >&5) cat conftest.out >&5 if $GREP 'External.*some_variable' conftest.out > /dev/null; then lt_cv_nm_interface="MS dumpbin" fi rm -f conftest* fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5 printf "%s\n" "$lt_cv_nm_interface" >&6; } { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 printf %s "checking whether ln -s works... " >&6; } LN_S=$as_ln_s if test "$LN_S" = "ln -s"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 printf "%s\n" "yes" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 printf "%s\n" "no, using $LN_S" >&6; } fi # find the maximum length of command line arguments { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5 printf %s "checking the maximum length of command line arguments... " >&6; } if test ${lt_cv_sys_max_cmd_len+y} then : printf %s "(cached) " >&6 else $as_nop i=0 teststring=ABCD case $build_os in msdosdjgpp*) # On DJGPP, this test can blow up pretty badly due to problems in libc # (any single argument exceeding 2000 bytes causes a buffer overrun # during glob expansion). Even if it were fixed, the result of this # check would be larger than it should be. lt_cv_sys_max_cmd_len=12288; # 12K is about right ;; gnu*) # Under GNU Hurd, this test is not required because there is # no limit to the length of command line arguments. # Libtool will interpret -1 as no limit whatsoever lt_cv_sys_max_cmd_len=-1; ;; cygwin* | mingw* | cegcc*) # On Win9x/ME, this test blows up -- it succeeds, but takes # about 5 minutes as the teststring grows exponentially. # Worse, since 9x/ME are not pre-emptively multitasking, # you end up with a "frozen" computer, even though with patience # the test eventually succeeds (with a max line length of 256k). # Instead, let's just punt: use the minimum linelength reported by # all of the supported platforms: 8192 (on NT/2K/XP). lt_cv_sys_max_cmd_len=8192; ;; mint*) # On MiNT this can take a long time and run out of memory. lt_cv_sys_max_cmd_len=8192; ;; amigaos*) # On AmigaOS with pdksh, this test takes hours, literally. # So we just punt and use a minimum line length of 8192. lt_cv_sys_max_cmd_len=8192; ;; bitrig* | darwin* | dragonfly* | freebsd* | midnightbsd* | netbsd* | openbsd*) # This has been around since 386BSD, at least. Likely further. if test -x /sbin/sysctl; then lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` elif test -x /usr/sbin/sysctl; then lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` else lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs fi # And add a safety zone lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` ;; interix*) # We know the value 262144 and hardcode it with a safety zone (like BSD) lt_cv_sys_max_cmd_len=196608 ;; os2*) # The test takes a long time on OS/2. lt_cv_sys_max_cmd_len=8192 ;; osf*) # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not # nice to cause kernel panics so lets avoid the loop below. # First set a reasonable default. lt_cv_sys_max_cmd_len=16384 # if test -x /sbin/sysconfig; then case `/sbin/sysconfig -q proc exec_disable_arg_limit` in *1*) lt_cv_sys_max_cmd_len=-1 ;; esac fi ;; sco3.2v5*) lt_cv_sys_max_cmd_len=102400 ;; sysv5* | sco5v6* | sysv4.2uw2*) kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` if test -n "$kargmax"; then lt_cv_sys_max_cmd_len=`echo $kargmax | $SED 's/.*[ ]//'` else lt_cv_sys_max_cmd_len=32768 fi ;; *) lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` if test -n "$lt_cv_sys_max_cmd_len" && \ test undefined != "$lt_cv_sys_max_cmd_len"; then lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` else # Make teststring a little bigger before we do anything with it. # a 1K string should be a reasonable start. for i in 1 2 3 4 5 6 7 8; do teststring=$teststring$teststring done SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} # If test is not a shell built-in, we'll probably end up computing a # maximum length that is only half of the actual maximum length, but # we can't tell. while { test X`env echo "$teststring$teststring" 2>/dev/null` \ = "X$teststring$teststring"; } >/dev/null 2>&1 && test 17 != "$i" # 1/2 MB should be enough do i=`expr $i + 1` teststring=$teststring$teststring done # Only check the string length outside the loop. lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` teststring= # Add a significant safety factor because C++ compilers can tack on # massive amounts of additional arguments before passing them to the # linker. It appears as though 1/2 is a usable value. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` fi ;; esac fi if test -n "$lt_cv_sys_max_cmd_len"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5 printf "%s\n" "$lt_cv_sys_max_cmd_len" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none" >&5 printf "%s\n" "none" >&6; } fi max_cmd_len=$lt_cv_sys_max_cmd_len : ${CP="cp -f"} : ${MV="mv -f"} : ${RM="rm -f"} if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then lt_unset=unset else lt_unset=false fi # test EBCDIC or ASCII case `echo X|tr X '\101'` in A) # ASCII based system # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr lt_SP2NL='tr \040 \012' lt_NL2SP='tr \015\012 \040\040' ;; *) # EBCDIC based system lt_SP2NL='tr \100 \n' lt_NL2SP='tr \r\n \100\100' ;; esac { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5 printf %s "checking how to convert $build file names to $host format... " >&6; } if test ${lt_cv_to_host_file_cmd+y} then : printf %s "(cached) " >&6 else $as_nop case $host in *-*-mingw* ) case $build in *-*-mingw* ) # actually msys lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 ;; *-*-cygwin* ) lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 ;; * ) # otherwise, assume *nix lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 ;; esac ;; *-*-cygwin* ) case $build in *-*-mingw* ) # actually msys lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin ;; *-*-cygwin* ) lt_cv_to_host_file_cmd=func_convert_file_noop ;; * ) # otherwise, assume *nix lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin ;; esac ;; * ) # unhandled hosts (and "normal" native builds) lt_cv_to_host_file_cmd=func_convert_file_noop ;; esac fi to_host_file_cmd=$lt_cv_to_host_file_cmd { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5 printf "%s\n" "$lt_cv_to_host_file_cmd" >&6; } { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5 printf %s "checking how to convert $build file names to toolchain format... " >&6; } if test ${lt_cv_to_tool_file_cmd+y} then : printf %s "(cached) " >&6 else $as_nop #assume ordinary cross tools, or native build. lt_cv_to_tool_file_cmd=func_convert_file_noop case $host in *-*-mingw* ) case $build in *-*-mingw* ) # actually msys lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 ;; esac ;; esac fi to_tool_file_cmd=$lt_cv_to_tool_file_cmd { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5 printf "%s\n" "$lt_cv_to_tool_file_cmd" >&6; } { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5 printf %s "checking for $LD option to reload object files... " >&6; } if test ${lt_cv_ld_reload_flag+y} then : printf %s "(cached) " >&6 else $as_nop lt_cv_ld_reload_flag='-r' fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5 printf "%s\n" "$lt_cv_ld_reload_flag" >&6; } reload_flag=$lt_cv_ld_reload_flag case $reload_flag in "" | " "*) ;; *) reload_flag=" $reload_flag" ;; esac reload_cmds='$LD$reload_flag -o $output$reload_objs' case $host_os in cygwin* | mingw* | pw32* | cegcc*) if test yes != "$GCC"; then reload_cmds=false fi ;; darwin*) if test yes = "$GCC"; then reload_cmds='$LTCC $LTCFLAGS -nostdlib $wl-r -o $output$reload_objs' else reload_cmds='$LD$reload_flag -o $output$reload_objs' fi ;; esac if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}file", so it can be a program name with args. set dummy ${ac_tool_prefix}file; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_FILECMD+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$FILECMD"; then ac_cv_prog_FILECMD="$FILECMD" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_FILECMD="${ac_tool_prefix}file" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi FILECMD=$ac_cv_prog_FILECMD if test -n "$FILECMD"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $FILECMD" >&5 printf "%s\n" "$FILECMD" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi fi if test -z "$ac_cv_prog_FILECMD"; then ac_ct_FILECMD=$FILECMD # Extract the first word of "file", so it can be a program name with args. set dummy file; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_ac_ct_FILECMD+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$ac_ct_FILECMD"; then ac_cv_prog_ac_ct_FILECMD="$ac_ct_FILECMD" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_FILECMD="file" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_FILECMD=$ac_cv_prog_ac_ct_FILECMD if test -n "$ac_ct_FILECMD"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_FILECMD" >&5 printf "%s\n" "$ac_ct_FILECMD" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi if test "x$ac_ct_FILECMD" = x; then FILECMD=":" else case $cross_compiling:$ac_tool_warned in yes:) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac FILECMD=$ac_ct_FILECMD fi else FILECMD="$ac_cv_prog_FILECMD" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args. set dummy ${ac_tool_prefix}objdump; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_OBJDUMP+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$OBJDUMP"; then ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi OBJDUMP=$ac_cv_prog_OBJDUMP if test -n "$OBJDUMP"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 printf "%s\n" "$OBJDUMP" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi fi if test -z "$ac_cv_prog_OBJDUMP"; then ac_ct_OBJDUMP=$OBJDUMP # Extract the first word of "objdump", so it can be a program name with args. set dummy objdump; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_ac_ct_OBJDUMP+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$ac_ct_OBJDUMP"; then ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_OBJDUMP="objdump" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP if test -n "$ac_ct_OBJDUMP"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 printf "%s\n" "$ac_ct_OBJDUMP" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi if test "x$ac_ct_OBJDUMP" = x; then OBJDUMP="false" else case $cross_compiling:$ac_tool_warned in yes:) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac OBJDUMP=$ac_ct_OBJDUMP fi else OBJDUMP="$ac_cv_prog_OBJDUMP" fi test -z "$OBJDUMP" && OBJDUMP=objdump { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5 printf %s "checking how to recognize dependent libraries... " >&6; } if test ${lt_cv_deplibs_check_method+y} then : printf %s "(cached) " >&6 else $as_nop lt_cv_file_magic_cmd='$MAGIC_CMD' lt_cv_file_magic_test_file= lt_cv_deplibs_check_method='unknown' # Need to set the preceding variable on all platforms that support # interlibrary dependencies. # 'none' -- dependencies not supported. # 'unknown' -- same as none, but documents that we really don't know. # 'pass_all' -- all dependencies passed with no checks. # 'test_compile' -- check by making test program. # 'file_magic [[regex]]' -- check by looking for files in library path # that responds to the $file_magic_cmd with a given extended regex. # If you have 'file' or equivalent on your system and you're not sure # whether 'pass_all' will *always* work, you probably want this one. case $host_os in aix[4-9]*) lt_cv_deplibs_check_method=pass_all ;; beos*) lt_cv_deplibs_check_method=pass_all ;; bsdi[45]*) lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' lt_cv_file_magic_cmd='$FILECMD -L' lt_cv_file_magic_test_file=/shlib/libc.so ;; cygwin*) # func_win32_libid is a shell function defined in ltmain.sh lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' lt_cv_file_magic_cmd='func_win32_libid' ;; mingw* | pw32*) # Base MSYS/MinGW do not provide the 'file' command needed by # func_win32_libid shell function, so use a weaker test based on 'objdump', # unless we find 'file', for example because we are cross-compiling. if ( file / ) >/dev/null 2>&1; then lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' lt_cv_file_magic_cmd='func_win32_libid' else # Keep this pattern in sync with the one in func_win32_libid. lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' lt_cv_file_magic_cmd='$OBJDUMP -f' fi ;; cegcc*) # use the weaker test based on 'objdump'. See mingw*. lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' lt_cv_file_magic_cmd='$OBJDUMP -f' ;; darwin* | rhapsody*) lt_cv_deplibs_check_method=pass_all ;; freebsd* | dragonfly* | midnightbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then case $host_cpu in i*86 ) # Not sure whether the presence of OpenBSD here was a mistake. # Let's accept both of them until this is cleared up. lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library' lt_cv_file_magic_cmd=$FILECMD lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` ;; esac else lt_cv_deplibs_check_method=pass_all fi ;; haiku*) lt_cv_deplibs_check_method=pass_all ;; hpux10.20* | hpux11*) lt_cv_file_magic_cmd=$FILECMD case $host_cpu in ia64*) lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64' lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so ;; hppa*64*) lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]' lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl ;; *) lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library' lt_cv_file_magic_test_file=/usr/lib/libc.sl ;; esac ;; interix[3-9]*) # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$' ;; irix5* | irix6* | nonstopux*) case $LD in *-32|*"-32 ") libmagic=32-bit;; *-n32|*"-n32 ") libmagic=N32;; *-64|*"-64 ") libmagic=64-bit;; *) libmagic=never-match;; esac lt_cv_deplibs_check_method=pass_all ;; # This must be glibc/ELF. linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) lt_cv_deplibs_check_method=pass_all ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$' fi ;; newos6*) lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)' lt_cv_file_magic_cmd=$FILECMD lt_cv_file_magic_test_file=/usr/lib/libnls.so ;; *nto* | *qnx*) lt_cv_deplibs_check_method=pass_all ;; openbsd* | bitrig*) if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' fi ;; osf3* | osf4* | osf5*) lt_cv_deplibs_check_method=pass_all ;; rdos*) lt_cv_deplibs_check_method=pass_all ;; solaris*) lt_cv_deplibs_check_method=pass_all ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) lt_cv_deplibs_check_method=pass_all ;; sysv4 | sysv4.3*) case $host_vendor in motorola) lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]' lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` ;; ncr) lt_cv_deplibs_check_method=pass_all ;; sequent) lt_cv_file_magic_cmd='/bin/file' lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' ;; sni) lt_cv_file_magic_cmd='/bin/file' lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib" lt_cv_file_magic_test_file=/lib/libc.so ;; siemens) lt_cv_deplibs_check_method=pass_all ;; pc) lt_cv_deplibs_check_method=pass_all ;; esac ;; tpf*) lt_cv_deplibs_check_method=pass_all ;; os2*) lt_cv_deplibs_check_method=pass_all ;; esac fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5 printf "%s\n" "$lt_cv_deplibs_check_method" >&6; } file_magic_glob= want_nocaseglob=no if test "$build" = "$host"; then case $host_os in mingw* | pw32*) if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then want_nocaseglob=yes else file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"` fi ;; esac fi file_magic_cmd=$lt_cv_file_magic_cmd deplibs_check_method=$lt_cv_deplibs_check_method test -z "$deplibs_check_method" && deplibs_check_method=unknown if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args. set dummy ${ac_tool_prefix}dlltool; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_DLLTOOL+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$DLLTOOL"; then ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi DLLTOOL=$ac_cv_prog_DLLTOOL if test -n "$DLLTOOL"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5 printf "%s\n" "$DLLTOOL" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi fi if test -z "$ac_cv_prog_DLLTOOL"; then ac_ct_DLLTOOL=$DLLTOOL # Extract the first word of "dlltool", so it can be a program name with args. set dummy dlltool; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_ac_ct_DLLTOOL+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$ac_ct_DLLTOOL"; then ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_DLLTOOL="dlltool" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL if test -n "$ac_ct_DLLTOOL"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5 printf "%s\n" "$ac_ct_DLLTOOL" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi if test "x$ac_ct_DLLTOOL" = x; then DLLTOOL="false" else case $cross_compiling:$ac_tool_warned in yes:) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac DLLTOOL=$ac_ct_DLLTOOL fi else DLLTOOL="$ac_cv_prog_DLLTOOL" fi test -z "$DLLTOOL" && DLLTOOL=dlltool { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5 printf %s "checking how to associate runtime and link libraries... " >&6; } if test ${lt_cv_sharedlib_from_linklib_cmd+y} then : printf %s "(cached) " >&6 else $as_nop lt_cv_sharedlib_from_linklib_cmd='unknown' case $host_os in cygwin* | mingw* | pw32* | cegcc*) # two different shell functions defined in ltmain.sh; # decide which one to use based on capabilities of $DLLTOOL case `$DLLTOOL --help 2>&1` in *--identify-strict*) lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib ;; *) lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback ;; esac ;; *) # fallback: assume linklib IS sharedlib lt_cv_sharedlib_from_linklib_cmd=$ECHO ;; esac fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5 printf "%s\n" "$lt_cv_sharedlib_from_linklib_cmd" >&6; } sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO if test -n "$ac_tool_prefix"; then for ac_prog in ar do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_AR+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$AR"; then ac_cv_prog_AR="$AR" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_AR="$ac_tool_prefix$ac_prog" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi AR=$ac_cv_prog_AR if test -n "$AR"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 printf "%s\n" "$AR" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi test -n "$AR" && break done fi if test -z "$AR"; then ac_ct_AR=$AR for ac_prog in ar do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_ac_ct_AR+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$ac_ct_AR"; then ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_AR="$ac_prog" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_AR=$ac_cv_prog_ac_ct_AR if test -n "$ac_ct_AR"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 printf "%s\n" "$ac_ct_AR" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi test -n "$ac_ct_AR" && break done if test "x$ac_ct_AR" = x; then AR="false" else case $cross_compiling:$ac_tool_warned in yes:) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac AR=$ac_ct_AR fi fi : ${AR=ar} # Use ARFLAGS variable as AR's operation code to sync the variable naming with # Automake. If both AR_FLAGS and ARFLAGS are specified, AR_FLAGS should have # higher priority because thats what people were doing historically (setting # ARFLAGS for automake and AR_FLAGS for libtool). FIXME: Make the AR_FLAGS # variable obsoleted/removed. test ${AR_FLAGS+y} || AR_FLAGS=${ARFLAGS-cr} lt_ar_flags=$AR_FLAGS # Make AR_FLAGS overridable by 'make ARFLAGS='. Don't try to run-time override # by AR_FLAGS because that was never working and AR_FLAGS is about to die. { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5 printf %s "checking for archiver @FILE support... " >&6; } if test ${lt_cv_ar_at_file+y} then : printf %s "(cached) " >&6 else $as_nop lt_cv_ar_at_file=no cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : echo conftest.$ac_objext > conftest.lst lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5' { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 (eval $lt_ar_try) 2>&5 ac_status=$? printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } if test 0 -eq "$ac_status"; then # Ensure the archiver fails upon bogus file names. rm -f conftest.$ac_objext libconftest.a { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 (eval $lt_ar_try) 2>&5 ac_status=$? printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } if test 0 -ne "$ac_status"; then lt_cv_ar_at_file=@ fi fi rm -f conftest.* libconftest.a fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5 printf "%s\n" "$lt_cv_ar_at_file" >&6; } if test no = "$lt_cv_ar_at_file"; then archiver_list_spec= else archiver_list_spec=$lt_cv_ar_at_file fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. set dummy ${ac_tool_prefix}strip; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_STRIP+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$STRIP"; then ac_cv_prog_STRIP="$STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_STRIP="${ac_tool_prefix}strip" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi STRIP=$ac_cv_prog_STRIP if test -n "$STRIP"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 printf "%s\n" "$STRIP" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi fi if test -z "$ac_cv_prog_STRIP"; then ac_ct_STRIP=$STRIP # Extract the first word of "strip", so it can be a program name with args. set dummy strip; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_ac_ct_STRIP+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$ac_ct_STRIP"; then ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_STRIP="strip" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP if test -n "$ac_ct_STRIP"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 printf "%s\n" "$ac_ct_STRIP" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi if test "x$ac_ct_STRIP" = x; then STRIP=":" else case $cross_compiling:$ac_tool_warned in yes:) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac STRIP=$ac_ct_STRIP fi else STRIP="$ac_cv_prog_STRIP" fi test -z "$STRIP" && STRIP=: if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. set dummy ${ac_tool_prefix}ranlib; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_RANLIB+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$RANLIB"; then ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi RANLIB=$ac_cv_prog_RANLIB if test -n "$RANLIB"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 printf "%s\n" "$RANLIB" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi fi if test -z "$ac_cv_prog_RANLIB"; then ac_ct_RANLIB=$RANLIB # Extract the first word of "ranlib", so it can be a program name with args. set dummy ranlib; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_ac_ct_RANLIB+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$ac_ct_RANLIB"; then ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_RANLIB="ranlib" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB if test -n "$ac_ct_RANLIB"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 printf "%s\n" "$ac_ct_RANLIB" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi if test "x$ac_ct_RANLIB" = x; then RANLIB=":" else case $cross_compiling:$ac_tool_warned in yes:) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac RANLIB=$ac_ct_RANLIB fi else RANLIB="$ac_cv_prog_RANLIB" fi test -z "$RANLIB" && RANLIB=: # Determine commands to create old-style static archives. old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' old_postinstall_cmds='chmod 644 $oldlib' old_postuninstall_cmds= if test -n "$RANLIB"; then case $host_os in bitrig* | openbsd*) old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" ;; *) old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" ;; esac old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" fi case $host_os in darwin*) lock_old_archive_extraction=yes ;; *) lock_old_archive_extraction=no ;; esac # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC # Check for command to grab the raw symbol name followed by C symbol from nm. { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5 printf %s "checking command to parse $NM output from $compiler object... " >&6; } if test ${lt_cv_sys_global_symbol_pipe+y} then : printf %s "(cached) " >&6 else $as_nop # These are sane defaults that work on at least a few old systems. # [They come from Ultrix. What could be older than Ultrix?!! ;)] # Character class describing NM global symbol codes. symcode='[BCDEGRST]' # Regexp to match symbols that can be accessed directly from C. sympat='\([_A-Za-z][_A-Za-z0-9]*\)' # Define system-specific variables. case $host_os in aix*) symcode='[BCDT]' ;; cygwin* | mingw* | pw32* | cegcc*) symcode='[ABCDGISTW]' ;; hpux*) if test ia64 = "$host_cpu"; then symcode='[ABCDEGRST]' fi ;; irix* | nonstopux*) symcode='[BCDEGRST]' ;; osf*) symcode='[BCDEGQRST]' ;; solaris*) symcode='[BDRT]' ;; sco3.2v5*) symcode='[DT]' ;; sysv4.2uw2*) symcode='[DT]' ;; sysv5* | sco5v6* | unixware* | OpenUNIX*) symcode='[ABDT]' ;; sysv4) symcode='[DFNSTU]' ;; esac # If we're using GNU nm, then use its standard symbol codes. case `$NM -V 2>&1` in *GNU* | *'with BFD'*) symcode='[ABCDGIRSTW]' ;; esac if test "$lt_cv_nm_interface" = "MS dumpbin"; then # Gets list of data symbols to import. lt_cv_sys_global_symbol_to_import="$SED -n -e 's/^I .* \(.*\)$/\1/p'" # Adjust the below global symbol transforms to fixup imported variables. lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'" lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'" lt_c_name_lib_hook="\ -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\ -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'" else # Disable hooks by default. lt_cv_sys_global_symbol_to_import= lt_cdecl_hook= lt_c_name_hook= lt_c_name_lib_hook= fi # Transform an extracted symbol line into a proper C declaration. # Some systems (esp. on ia64) link data and code symbols differently, # so use this general approach. lt_cv_sys_global_symbol_to_cdecl="$SED -n"\ $lt_cdecl_hook\ " -e 's/^T .* \(.*\)$/extern int \1();/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'" # Transform an extracted symbol line into symbol name and symbol address lt_cv_sys_global_symbol_to_c_name_address="$SED -n"\ $lt_c_name_hook\ " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'" # Transform an extracted symbol line into symbol name with lib prefix and # symbol address. lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="$SED -n"\ $lt_c_name_lib_hook\ " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ " -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'" # Handle CRLF in mingw tool chain opt_cr= case $build_os in mingw*) opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp ;; esac # Try without a prefix underscore, then with it. for ac_symprfx in "" "_"; do # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. symxfrm="\\1 $ac_symprfx\\2 \\2" # Write the raw and C identifiers. if test "$lt_cv_nm_interface" = "MS dumpbin"; then # Fake it for dumpbin and say T for any non-static function, # D for any global variable and I for any imported variable. # Also find C++ and __fastcall symbols from MSVC++ or ICC, # which start with @ or ?. lt_cv_sys_global_symbol_pipe="$AWK '"\ " {last_section=section; section=\$ 3};"\ " /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ " /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\ " /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\ " /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\ " \$ 0!~/External *\|/{next};"\ " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ " {if(hide[section]) next};"\ " {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\ " {split(\$ 0,a,/\||\r/); split(a[2],s)};"\ " s[1]~/^[@?]/{print f,s[1],s[1]; next};"\ " s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\ " ' prfx=^$ac_symprfx" else lt_cv_sys_global_symbol_pipe="$SED -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" fi lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | $SED '/ __gnu_lto/d'" # Check to see that the pipe works correctly. pipe_works=no rm -f conftest* cat > conftest.$ac_ext <<_LT_EOF #ifdef __cplusplus extern "C" { #endif char nm_test_var; void nm_test_func(void); void nm_test_func(void){} #ifdef __cplusplus } #endif int main(){nm_test_var='a';nm_test_func();return(0);} _LT_EOF if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then # Now try to grab the symbols. nlist=conftest.nm $ECHO "$as_me:$LINENO: $NM conftest.$ac_objext | $lt_cv_sys_global_symbol_pipe > $nlist" >&5 if eval "$NM" conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist 2>&5 && test -s "$nlist"; then # Try sorting and uniquifying the output. if sort "$nlist" | uniq > "$nlist"T; then mv -f "$nlist"T "$nlist" else rm -f "$nlist"T fi # Make sure that we snagged all the symbols we need. if $GREP ' nm_test_var$' "$nlist" >/dev/null; then if $GREP ' nm_test_func$' "$nlist" >/dev/null; then cat <<_LT_EOF > conftest.$ac_ext /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ #if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE /* DATA imports from DLLs on WIN32 can't be const, because runtime relocations are performed -- see ld's documentation on pseudo-relocs. */ # define LT_DLSYM_CONST #elif defined __osf__ /* This system does not cope well with relocations in const data. */ # define LT_DLSYM_CONST #else # define LT_DLSYM_CONST const #endif #ifdef __cplusplus extern "C" { #endif _LT_EOF # Now generate the symbol file. eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' cat <<_LT_EOF >> conftest.$ac_ext /* The mapping between symbol names and symbols. */ LT_DLSYM_CONST struct { const char *name; void *address; } lt__PROGRAM__LTX_preloaded_symbols[] = { { "@PROGRAM@", (void *) 0 }, _LT_EOF $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext cat <<\_LT_EOF >> conftest.$ac_ext {0, (void *) 0} }; /* This works around a problem in FreeBSD linker */ #ifdef FREEBSD_WORKAROUND static const void *lt_preloaded_setup() { return lt__PROGRAM__LTX_preloaded_symbols; } #endif #ifdef __cplusplus } #endif _LT_EOF # Now try linking the two files. mv conftest.$ac_objext conftstm.$ac_objext lt_globsym_save_LIBS=$LIBS lt_globsym_save_CFLAGS=$CFLAGS LIBS=conftstm.$ac_objext CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag" if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 (eval $ac_link) 2>&5 ac_status=$? printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && test -s conftest$ac_exeext; then pipe_works=yes fi LIBS=$lt_globsym_save_LIBS CFLAGS=$lt_globsym_save_CFLAGS else echo "cannot find nm_test_func in $nlist" >&5 fi else echo "cannot find nm_test_var in $nlist" >&5 fi else echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5 fi else echo "$progname: failed program was:" >&5 cat conftest.$ac_ext >&5 fi rm -rf conftest* conftst* # Do not use the global_symbol_pipe unless it works. if test yes = "$pipe_works"; then break else lt_cv_sys_global_symbol_pipe= fi done fi if test -z "$lt_cv_sys_global_symbol_pipe"; then lt_cv_sys_global_symbol_to_cdecl= fi if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: failed" >&5 printf "%s\n" "failed" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ok" >&5 printf "%s\n" "ok" >&6; } fi # Response file support. if test "$lt_cv_nm_interface" = "MS dumpbin"; then nm_file_list_spec='@' elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then nm_file_list_spec='@' fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 printf %s "checking for sysroot... " >&6; } # Check whether --with-sysroot was given. if test ${with_sysroot+y} then : withval=$with_sysroot; else $as_nop with_sysroot=no fi lt_sysroot= case $with_sysroot in #( yes) if test yes = "$GCC"; then lt_sysroot=`$CC --print-sysroot 2>/dev/null` fi ;; #( /*) lt_sysroot=`echo "$with_sysroot" | $SED -e "$sed_quote_subst"` ;; #( no|'') ;; #( *) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $with_sysroot" >&5 printf "%s\n" "$with_sysroot" >&6; } as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5 ;; esac { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5 printf "%s\n" "${lt_sysroot:-no}" >&6; } { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a working dd" >&5 printf %s "checking for a working dd... " >&6; } if test ${ac_cv_path_lt_DD+y} then : printf %s "(cached) " >&6 else $as_nop printf 0123456789abcdef0123456789abcdef >conftest.i cat conftest.i conftest.i >conftest2.i : ${lt_DD:=$DD} if test -z "$lt_DD"; then ac_path_lt_DD_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_prog in dd do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_lt_DD="$as_dir$ac_prog$ac_exec_ext" as_fn_executable_p "$ac_path_lt_DD" || continue if "$ac_path_lt_DD" bs=32 count=1 conftest.out 2>/dev/null; then cmp -s conftest.i conftest.out \ && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=: fi $ac_path_lt_DD_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_lt_DD"; then : fi else ac_cv_path_lt_DD=$lt_DD fi rm -f conftest.i conftest2.i conftest.out fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_lt_DD" >&5 printf "%s\n" "$ac_cv_path_lt_DD" >&6; } { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to truncate binary pipes" >&5 printf %s "checking how to truncate binary pipes... " >&6; } if test ${lt_cv_truncate_bin+y} then : printf %s "(cached) " >&6 else $as_nop printf 0123456789abcdef0123456789abcdef >conftest.i cat conftest.i conftest.i >conftest2.i lt_cv_truncate_bin= if "$ac_cv_path_lt_DD" bs=32 count=1 conftest.out 2>/dev/null; then cmp -s conftest.i conftest.out \ && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1" fi rm -f conftest.i conftest2.i conftest.out test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q" fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_truncate_bin" >&5 printf "%s\n" "$lt_cv_truncate_bin" >&6; } # Calculate cc_basename. Skip known compiler wrappers and cross-prefix. func_cc_basename () { for cc_temp in $*""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; \-*) ;; *) break;; esac done func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` } # Check whether --enable-libtool-lock was given. if test ${enable_libtool_lock+y} then : enableval=$enable_libtool_lock; fi test no = "$enable_libtool_lock" || enable_libtool_lock=yes # Some flags need to be propagated to the compiler or linker for good # libtool support. case $host in ia64-*-hpux*) # Find out what ABI is being produced by ac_compile, and set mode # options accordingly. echo 'int i;' > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then case `$FILECMD conftest.$ac_objext` in *ELF-32*) HPUX_IA64_MODE=32 ;; *ELF-64*) HPUX_IA64_MODE=64 ;; esac fi rm -rf conftest* ;; *-*-irix6*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. echo '#line '$LINENO' "configure"' > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then if test yes = "$lt_cv_prog_gnu_ld"; then case `$FILECMD conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -melf32bsmip" ;; *N32*) LD="${LD-ld} -melf32bmipn32" ;; *64-bit*) LD="${LD-ld} -melf64bmip" ;; esac else case `$FILECMD conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -32" ;; *N32*) LD="${LD-ld} -n32" ;; *64-bit*) LD="${LD-ld} -64" ;; esac fi fi rm -rf conftest* ;; mips64*-*linux*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. echo '#line '$LINENO' "configure"' > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then emul=elf case `$FILECMD conftest.$ac_objext` in *32-bit*) emul="${emul}32" ;; *64-bit*) emul="${emul}64" ;; esac case `$FILECMD conftest.$ac_objext` in *MSB*) emul="${emul}btsmip" ;; *LSB*) emul="${emul}ltsmip" ;; esac case `$FILECMD conftest.$ac_objext` in *N32*) emul="${emul}n32" ;; esac LD="${LD-ld} -m $emul" fi rm -rf conftest* ;; x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. Note that the listed cases only cover the # situations where additional linker options are needed (such as when # doing 32-bit compilation for a host where ld defaults to 64-bit, or # vice versa); the common cases where no linker options are needed do # not appear in the list. echo 'int i;' > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then case `$FILECMD conftest.o` in *32-bit*) case $host in x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_i386_fbsd" ;; x86_64-*linux*) case `$FILECMD conftest.o` in *x86-64*) LD="${LD-ld} -m elf32_x86_64" ;; *) LD="${LD-ld} -m elf_i386" ;; esac ;; powerpc64le-*linux*) LD="${LD-ld} -m elf32lppclinux" ;; powerpc64-*linux*) LD="${LD-ld} -m elf32ppclinux" ;; s390x-*linux*) LD="${LD-ld} -m elf_s390" ;; sparc64-*linux*) LD="${LD-ld} -m elf32_sparc" ;; esac ;; *64-bit*) case $host in x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_x86_64_fbsd" ;; x86_64-*linux*) LD="${LD-ld} -m elf_x86_64" ;; powerpcle-*linux*) LD="${LD-ld} -m elf64lppc" ;; powerpc-*linux*) LD="${LD-ld} -m elf64ppc" ;; s390*-*linux*|s390*-*tpf*) LD="${LD-ld} -m elf64_s390" ;; sparc*-*linux*) LD="${LD-ld} -m elf64_sparc" ;; esac ;; esac fi rm -rf conftest* ;; *-*-sco3.2v5*) # On SCO OpenServer 5, we need -belf to get full-featured binaries. SAVE_CFLAGS=$CFLAGS CFLAGS="$CFLAGS -belf" { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5 printf %s "checking whether the C compiler needs -belf... " >&6; } if test ${lt_cv_cc_needs_belf+y} then : printf %s "(cached) " >&6 else $as_nop ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : lt_cv_cc_needs_belf=yes else $as_nop lt_cv_cc_needs_belf=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5 printf "%s\n" "$lt_cv_cc_needs_belf" >&6; } if test yes != "$lt_cv_cc_needs_belf"; then # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf CFLAGS=$SAVE_CFLAGS fi ;; *-*solaris*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. echo 'int i;' > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then case `$FILECMD conftest.o` in *64-bit*) case $lt_cv_prog_gnu_ld in yes*) case $host in i?86-*-solaris*|x86_64-*-solaris*) LD="${LD-ld} -m elf_x86_64" ;; sparc*-*-solaris*) LD="${LD-ld} -m elf64_sparc" ;; esac # GNU ld 2.21 introduced _sol2 emulations. Use them if available. if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then LD=${LD-ld}_sol2 fi ;; *) if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then LD="${LD-ld} -64" fi ;; esac ;; esac fi rm -rf conftest* ;; esac need_locks=$enable_libtool_lock if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args. set dummy ${ac_tool_prefix}mt; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_MANIFEST_TOOL+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$MANIFEST_TOOL"; then ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL if test -n "$MANIFEST_TOOL"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5 printf "%s\n" "$MANIFEST_TOOL" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi fi if test -z "$ac_cv_prog_MANIFEST_TOOL"; then ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL # Extract the first word of "mt", so it can be a program name with args. set dummy mt; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_ac_ct_MANIFEST_TOOL+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$ac_ct_MANIFEST_TOOL"; then ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_MANIFEST_TOOL="mt" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL if test -n "$ac_ct_MANIFEST_TOOL"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5 printf "%s\n" "$ac_ct_MANIFEST_TOOL" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi if test "x$ac_ct_MANIFEST_TOOL" = x; then MANIFEST_TOOL=":" else case $cross_compiling:$ac_tool_warned in yes:) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL fi else MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL" fi test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5 printf %s "checking if $MANIFEST_TOOL is a manifest tool... " >&6; } if test ${lt_cv_path_mainfest_tool+y} then : printf %s "(cached) " >&6 else $as_nop lt_cv_path_mainfest_tool=no echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5 $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out cat conftest.err >&5 if $GREP 'Manifest Tool' conftest.out > /dev/null; then lt_cv_path_mainfest_tool=yes fi rm -f conftest* fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5 printf "%s\n" "$lt_cv_path_mainfest_tool" >&6; } if test yes != "$lt_cv_path_mainfest_tool"; then MANIFEST_TOOL=: fi case $host_os in rhapsody* | darwin*) if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args. set dummy ${ac_tool_prefix}dsymutil; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_DSYMUTIL+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$DSYMUTIL"; then ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi DSYMUTIL=$ac_cv_prog_DSYMUTIL if test -n "$DSYMUTIL"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 printf "%s\n" "$DSYMUTIL" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi fi if test -z "$ac_cv_prog_DSYMUTIL"; then ac_ct_DSYMUTIL=$DSYMUTIL # Extract the first word of "dsymutil", so it can be a program name with args. set dummy dsymutil; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_ac_ct_DSYMUTIL+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$ac_ct_DSYMUTIL"; then ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_DSYMUTIL="dsymutil" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL if test -n "$ac_ct_DSYMUTIL"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5 printf "%s\n" "$ac_ct_DSYMUTIL" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi if test "x$ac_ct_DSYMUTIL" = x; then DSYMUTIL=":" else case $cross_compiling:$ac_tool_warned in yes:) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac DSYMUTIL=$ac_ct_DSYMUTIL fi else DSYMUTIL="$ac_cv_prog_DSYMUTIL" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args. set dummy ${ac_tool_prefix}nmedit; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_NMEDIT+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$NMEDIT"; then ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi NMEDIT=$ac_cv_prog_NMEDIT if test -n "$NMEDIT"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5 printf "%s\n" "$NMEDIT" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi fi if test -z "$ac_cv_prog_NMEDIT"; then ac_ct_NMEDIT=$NMEDIT # Extract the first word of "nmedit", so it can be a program name with args. set dummy nmedit; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_ac_ct_NMEDIT+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$ac_ct_NMEDIT"; then ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_NMEDIT="nmedit" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT if test -n "$ac_ct_NMEDIT"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5 printf "%s\n" "$ac_ct_NMEDIT" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi if test "x$ac_ct_NMEDIT" = x; then NMEDIT=":" else case $cross_compiling:$ac_tool_warned in yes:) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac NMEDIT=$ac_ct_NMEDIT fi else NMEDIT="$ac_cv_prog_NMEDIT" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args. set dummy ${ac_tool_prefix}lipo; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_LIPO+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$LIPO"; then ac_cv_prog_LIPO="$LIPO" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_LIPO="${ac_tool_prefix}lipo" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi LIPO=$ac_cv_prog_LIPO if test -n "$LIPO"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 printf "%s\n" "$LIPO" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi fi if test -z "$ac_cv_prog_LIPO"; then ac_ct_LIPO=$LIPO # Extract the first word of "lipo", so it can be a program name with args. set dummy lipo; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_ac_ct_LIPO+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$ac_ct_LIPO"; then ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_LIPO="lipo" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO if test -n "$ac_ct_LIPO"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5 printf "%s\n" "$ac_ct_LIPO" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi if test "x$ac_ct_LIPO" = x; then LIPO=":" else case $cross_compiling:$ac_tool_warned in yes:) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac LIPO=$ac_ct_LIPO fi else LIPO="$ac_cv_prog_LIPO" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args. set dummy ${ac_tool_prefix}otool; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_OTOOL+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$OTOOL"; then ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_OTOOL="${ac_tool_prefix}otool" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi OTOOL=$ac_cv_prog_OTOOL if test -n "$OTOOL"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 printf "%s\n" "$OTOOL" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi fi if test -z "$ac_cv_prog_OTOOL"; then ac_ct_OTOOL=$OTOOL # Extract the first word of "otool", so it can be a program name with args. set dummy otool; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_ac_ct_OTOOL+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$ac_ct_OTOOL"; then ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_OTOOL="otool" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL if test -n "$ac_ct_OTOOL"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5 printf "%s\n" "$ac_ct_OTOOL" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi if test "x$ac_ct_OTOOL" = x; then OTOOL=":" else case $cross_compiling:$ac_tool_warned in yes:) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac OTOOL=$ac_ct_OTOOL fi else OTOOL="$ac_cv_prog_OTOOL" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args. set dummy ${ac_tool_prefix}otool64; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_OTOOL64+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$OTOOL64"; then ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi OTOOL64=$ac_cv_prog_OTOOL64 if test -n "$OTOOL64"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5 printf "%s\n" "$OTOOL64" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi fi if test -z "$ac_cv_prog_OTOOL64"; then ac_ct_OTOOL64=$OTOOL64 # Extract the first word of "otool64", so it can be a program name with args. set dummy otool64; ac_word=$2 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 printf %s "checking for $ac_word... " >&6; } if test ${ac_cv_prog_ac_ct_OTOOL64+y} then : printf %s "(cached) " >&6 else $as_nop if test -n "$ac_ct_OTOOL64"; then ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_OTOOL64="otool64" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64 if test -n "$ac_ct_OTOOL64"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5 printf "%s\n" "$ac_ct_OTOOL64" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi if test "x$ac_ct_OTOOL64" = x; then OTOOL64=":" else case $cross_compiling:$ac_tool_warned in yes:) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac OTOOL64=$ac_ct_OTOOL64 fi else OTOOL64="$ac_cv_prog_OTOOL64" fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5 printf %s "checking for -single_module linker flag... " >&6; } if test ${lt_cv_apple_cc_single_mod+y} then : printf %s "(cached) " >&6 else $as_nop lt_cv_apple_cc_single_mod=no if test -z "$LT_MULTI_MODULE"; then # By default we will add the -single_module flag. You can override # by either setting the environment variable LT_MULTI_MODULE # non-empty at configure time, or by adding -multi_module to the # link flags. rm -rf libconftest.dylib* echo "int foo(void){return 1;}" > conftest.c echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ -dynamiclib -Wl,-single_module conftest.c" >&5 $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ -dynamiclib -Wl,-single_module conftest.c 2>conftest.err _lt_result=$? # If there is a non-empty error log, and "single_module" # appears in it, assume the flag caused a linker warning if test -s conftest.err && $GREP single_module conftest.err; then cat conftest.err >&5 # Otherwise, if the output was created with a 0 exit code from # the compiler, it worked. elif test -f libconftest.dylib && test 0 = "$_lt_result"; then lt_cv_apple_cc_single_mod=yes else cat conftest.err >&5 fi rm -rf libconftest.dylib* rm -f conftest.* fi fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5 printf "%s\n" "$lt_cv_apple_cc_single_mod" >&6; } { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5 printf %s "checking for -exported_symbols_list linker flag... " >&6; } if test ${lt_cv_ld_exported_symbols_list+y} then : printf %s "(cached) " >&6 else $as_nop lt_cv_ld_exported_symbols_list=no save_LDFLAGS=$LDFLAGS echo "_main" > conftest.sym LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : lt_cv_ld_exported_symbols_list=yes else $as_nop lt_cv_ld_exported_symbols_list=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LDFLAGS=$save_LDFLAGS fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5 printf "%s\n" "$lt_cv_ld_exported_symbols_list" >&6; } { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5 printf %s "checking for -force_load linker flag... " >&6; } if test ${lt_cv_ld_force_load+y} then : printf %s "(cached) " >&6 else $as_nop lt_cv_ld_force_load=no cat > conftest.c << _LT_EOF int forced_loaded() { return 2;} _LT_EOF echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5 echo "$AR $AR_FLAGS libconftest.a conftest.o" >&5 $AR $AR_FLAGS libconftest.a conftest.o 2>&5 echo "$RANLIB libconftest.a" >&5 $RANLIB libconftest.a 2>&5 cat > conftest.c << _LT_EOF int main() { return 0;} _LT_EOF echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5 $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err _lt_result=$? if test -s conftest.err && $GREP force_load conftest.err; then cat conftest.err >&5 elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then lt_cv_ld_force_load=yes else cat conftest.err >&5 fi rm -f conftest.err libconftest.a conftest conftest.c rm -rf conftest.dSYM fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5 printf "%s\n" "$lt_cv_ld_force_load" >&6; } case $host_os in rhapsody* | darwin1.[012]) _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;; darwin1.*) _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; darwin*) case $MACOSX_DEPLOYMENT_TARGET,$host in 10.[012],*|,*powerpc*-darwin[5-8]*) _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; *) _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; esac ;; esac if test yes = "$lt_cv_apple_cc_single_mod"; then _lt_dar_single_mod='$single_module' fi if test yes = "$lt_cv_ld_exported_symbols_list"; then _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym' else _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib' fi if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then _lt_dsymutil='~$DSYMUTIL $lib || :' else _lt_dsymutil= fi ;; esac # func_munge_path_list VARIABLE PATH # ----------------------------------- # VARIABLE is name of variable containing _space_ separated list of # directories to be munged by the contents of PATH, which is string # having a format: # "DIR[:DIR]:" # string "DIR[ DIR]" will be prepended to VARIABLE # ":DIR[:DIR]" # string "DIR[ DIR]" will be appended to VARIABLE # "DIRP[:DIRP]::[DIRA:]DIRA" # string "DIRP[ DIRP]" will be prepended to VARIABLE and string # "DIRA[ DIRA]" will be appended to VARIABLE # "DIR[:DIR]" # VARIABLE will be replaced by "DIR[ DIR]" func_munge_path_list () { case x$2 in x) ;; *:) eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\" ;; x:*) eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\" ;; *::*) eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\" eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\" ;; *) eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\" ;; esac } ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default " if test "x$ac_cv_header_dlfcn_h" = xyes then : printf "%s\n" "#define HAVE_DLFCN_H 1" >>confdefs.h fi # Set options enable_dlopen=no enable_win32_dll=no # Check whether --enable-shared was given. if test ${enable_shared+y} then : enableval=$enable_shared; p=${PACKAGE-default} case $enableval in yes) enable_shared=yes ;; no) enable_shared=no ;; *) enable_shared=no # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_shared=yes fi done IFS=$lt_save_ifs ;; esac else $as_nop enable_shared=yes fi # Check whether --enable-static was given. if test ${enable_static+y} then : enableval=$enable_static; p=${PACKAGE-default} case $enableval in yes) enable_static=yes ;; no) enable_static=no ;; *) enable_static=no # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_static=yes fi done IFS=$lt_save_ifs ;; esac else $as_nop enable_static=yes fi # Check whether --with-pic was given. if test ${with_pic+y} then : withval=$with_pic; lt_p=${PACKAGE-default} case $withval in yes|no) pic_mode=$withval ;; *) pic_mode=default # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for lt_pkg in $withval; do IFS=$lt_save_ifs if test "X$lt_pkg" = "X$lt_p"; then pic_mode=yes fi done IFS=$lt_save_ifs ;; esac else $as_nop pic_mode=default fi # Check whether --enable-fast-install was given. if test ${enable_fast_install+y} then : enableval=$enable_fast_install; p=${PACKAGE-default} case $enableval in yes) enable_fast_install=yes ;; no) enable_fast_install=no ;; *) enable_fast_install=no # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_fast_install=yes fi done IFS=$lt_save_ifs ;; esac else $as_nop enable_fast_install=yes fi shared_archive_member_spec= case $host,$enable_shared in power*-*-aix[5-9]*,yes) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking which variant of shared library versioning to provide" >&5 printf %s "checking which variant of shared library versioning to provide... " >&6; } # Check whether --with-aix-soname was given. if test ${with_aix_soname+y} then : withval=$with_aix_soname; case $withval in aix|svr4|both) ;; *) as_fn_error $? "Unknown argument to --with-aix-soname" "$LINENO" 5 ;; esac lt_cv_with_aix_soname=$with_aix_soname else $as_nop if test ${lt_cv_with_aix_soname+y} then : printf %s "(cached) " >&6 else $as_nop lt_cv_with_aix_soname=aix fi with_aix_soname=$lt_cv_with_aix_soname fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $with_aix_soname" >&5 printf "%s\n" "$with_aix_soname" >&6; } if test aix != "$with_aix_soname"; then # For the AIX way of multilib, we name the shared archive member # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o', # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File. # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag, # the AIX toolchain works better with OBJECT_MODE set (default 32). if test 64 = "${OBJECT_MODE-32}"; then shared_archive_member_spec=shr_64 else shared_archive_member_spec=shr fi fi ;; *) with_aix_soname=aix ;; esac # This can be used to rebuild libtool when needed LIBTOOL_DEPS=$ltmain # Always use our own libtool. LIBTOOL='$(SHELL) $(top_builddir)/libtool' test -z "$LN_S" && LN_S="ln -s" if test -n "${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5 printf %s "checking for objdir... " >&6; } if test ${lt_cv_objdir+y} then : printf %s "(cached) " >&6 else $as_nop rm -f .libs 2>/dev/null mkdir .libs 2>/dev/null if test -d .libs; then lt_cv_objdir=.libs else # MS-DOS does not allow filenames that begin with a dot. lt_cv_objdir=_libs fi rmdir .libs 2>/dev/null fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5 printf "%s\n" "$lt_cv_objdir" >&6; } objdir=$lt_cv_objdir printf "%s\n" "#define LT_OBJDIR \"$lt_cv_objdir/\"" >>confdefs.h case $host_os in aix3*) # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. if test set != "${COLLECT_NAMES+set}"; then COLLECT_NAMES= export COLLECT_NAMES fi ;; esac # Global variables: ofile=libtool can_build_shared=yes # All known linkers require a '.a' archive for static linking (except MSVC and # ICC, which need '.lib'). libext=a with_gnu_ld=$lt_cv_prog_gnu_ld old_CC=$CC old_CFLAGS=$CFLAGS # Set sane defaults for various variables test -z "$CC" && CC=cc test -z "$LTCC" && LTCC=$CC test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS test -z "$LD" && LD=ld test -z "$ac_objext" && ac_objext=o func_cc_basename $compiler cc_basename=$func_cc_basename_result # Only perform the check for file, if the check method requires it test -z "$MAGIC_CMD" && MAGIC_CMD=file case $deplibs_check_method in file_magic*) if test "$file_magic_cmd" = '$MAGIC_CMD'; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5 printf %s "checking for ${ac_tool_prefix}file... " >&6; } if test ${lt_cv_path_MAGIC_CMD+y} then : printf %s "(cached) " >&6 else $as_nop case $MAGIC_CMD in [\\/*] | ?:[\\/]*) lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. ;; *) lt_save_MAGIC_CMD=$MAGIC_CMD lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" for ac_dir in $ac_dummy; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/${ac_tool_prefix}file"; then lt_cv_path_MAGIC_CMD=$ac_dir/"${ac_tool_prefix}file" if test -n "$file_magic_test_file"; then case $deplibs_check_method in "file_magic "*) file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` MAGIC_CMD=$lt_cv_path_MAGIC_CMD if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | $EGREP "$file_magic_regex" > /dev/null; then : else cat <<_LT_EOF 1>&2 *** Warning: the command libtool uses to detect shared libraries, *** $file_magic_cmd, produces output that libtool cannot recognize. *** The result is that libtool may fail to recognize shared libraries *** as such. This will affect the creation of libtool libraries that *** depend on shared libraries, but programs linked with such libtool *** libraries will work regardless of this problem. Nevertheless, you *** may want to report the problem to your system manager and/or to *** bug-libtool@gnu.org _LT_EOF fi ;; esac fi break fi done IFS=$lt_save_ifs MAGIC_CMD=$lt_save_MAGIC_CMD ;; esac fi MAGIC_CMD=$lt_cv_path_MAGIC_CMD if test -n "$MAGIC_CMD"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 printf "%s\n" "$MAGIC_CMD" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi if test -z "$lt_cv_path_MAGIC_CMD"; then if test -n "$ac_tool_prefix"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for file" >&5 printf %s "checking for file... " >&6; } if test ${lt_cv_path_MAGIC_CMD+y} then : printf %s "(cached) " >&6 else $as_nop case $MAGIC_CMD in [\\/*] | ?:[\\/]*) lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. ;; *) lt_save_MAGIC_CMD=$MAGIC_CMD lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" for ac_dir in $ac_dummy; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/file"; then lt_cv_path_MAGIC_CMD=$ac_dir/"file" if test -n "$file_magic_test_file"; then case $deplibs_check_method in "file_magic "*) file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` MAGIC_CMD=$lt_cv_path_MAGIC_CMD if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | $EGREP "$file_magic_regex" > /dev/null; then : else cat <<_LT_EOF 1>&2 *** Warning: the command libtool uses to detect shared libraries, *** $file_magic_cmd, produces output that libtool cannot recognize. *** The result is that libtool may fail to recognize shared libraries *** as such. This will affect the creation of libtool libraries that *** depend on shared libraries, but programs linked with such libtool *** libraries will work regardless of this problem. Nevertheless, you *** may want to report the problem to your system manager and/or to *** bug-libtool@gnu.org _LT_EOF fi ;; esac fi break fi done IFS=$lt_save_ifs MAGIC_CMD=$lt_save_MAGIC_CMD ;; esac fi MAGIC_CMD=$lt_cv_path_MAGIC_CMD if test -n "$MAGIC_CMD"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 printf "%s\n" "$MAGIC_CMD" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi else MAGIC_CMD=: fi fi fi ;; esac # Use C for the default configuration in the libtool script lt_save_CC=$CC ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu # Source file extension for C test sources. ac_ext=c # Object file extension for compiled C test sources. objext=o objext=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="int some_variable = 0;" # Code to be used in simple link tests lt_simple_link_test_code='int main(){return(0);}' # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC # Save the default compiler, since it gets overwritten when the other # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. compiler_DEFAULT=$CC # save warnings/boilerplate of simple test code ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" >conftest.$ac_ext eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_compiler_boilerplate=`cat conftest.err` $RM conftest* ac_outfile=conftest.$ac_objext echo "$lt_simple_link_test_code" >conftest.$ac_ext eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_linker_boilerplate=`cat conftest.err` $RM -r conftest* ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change ## the running order or otherwise move them around unless you know exactly ## what you are doing... if test -n "$compiler"; then lt_prog_compiler_no_builtin_flag= if test yes = "$GCC"; then case $cc_basename in nvcc*) lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;; *) lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;; esac { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 printf %s "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } if test ${lt_cv_prog_compiler_rtti_exceptions+y} then : printf %s "(cached) " >&6 else $as_nop lt_cv_prog_compiler_rtti_exceptions=no ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-fno-rtti -fno-exceptions" ## exclude from sc_useless_quotes_in_assignment # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_rtti_exceptions=yes fi fi $RM conftest* fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 printf "%s\n" "$lt_cv_prog_compiler_rtti_exceptions" >&6; } if test yes = "$lt_cv_prog_compiler_rtti_exceptions"; then lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions" else : fi fi lt_prog_compiler_wl= lt_prog_compiler_pic= lt_prog_compiler_static= if test yes = "$GCC"; then lt_prog_compiler_wl='-Wl,' lt_prog_compiler_static='-static' case $host_os in aix*) # All AIX code is PIC. if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor lt_prog_compiler_static='-Bstatic' fi lt_prog_compiler_pic='-fPIC' ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support lt_prog_compiler_pic='-fPIC' ;; m68k) # FIXME: we need at least 68020 code to build shared libraries, but # adding the '-m68020' flag to GCC prevents building anything better, # like '-m68040'. lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4' ;; esac ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | cygwin* | pw32* | os2* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style # (--disable-auto-import) libraries lt_prog_compiler_pic='-DDLL_EXPORT' case $host_os in os2*) lt_prog_compiler_static='$wl-static' ;; esac ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files lt_prog_compiler_pic='-fno-common' ;; haiku*) # PIC is the default for Haiku. # The "-static" flag exists, but is broken. lt_prog_compiler_static= ;; hpux*) # PIC is the default for 64-bit PA HP-UX, but not for 32-bit # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag # sets the default TLS model and affects inlining. case $host_cpu in hppa*64*) # +Z the default ;; *) lt_prog_compiler_pic='-fPIC' ;; esac ;; interix[3-9]*) # Interix 3.x gcc -fpic/-fPIC options generate broken code. # Instead, we relocate shared libraries at runtime. ;; msdosdjgpp*) # Just because we use GCC doesn't mean we suddenly get shared libraries # on systems that don't support them. lt_prog_compiler_can_build_shared=no enable_shared=no ;; *nto* | *qnx*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. lt_prog_compiler_pic='-fPIC -shared' ;; sysv4*MP*) if test -d /usr/nec; then lt_prog_compiler_pic=-Kconform_pic fi ;; *) lt_prog_compiler_pic='-fPIC' ;; esac case $cc_basename in nvcc*) # Cuda Compiler Driver 2.2 lt_prog_compiler_wl='-Xlinker ' if test -n "$lt_prog_compiler_pic"; then lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic" fi ;; esac else # PORTME Check for flag to pass linker flags through the system compiler. case $host_os in aix*) lt_prog_compiler_wl='-Wl,' if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor lt_prog_compiler_static='-Bstatic' else lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp' fi ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files lt_prog_compiler_pic='-fno-common' case $cc_basename in nagfor*) # NAG Fortran compiler lt_prog_compiler_wl='-Wl,-Wl,,' lt_prog_compiler_pic='-PIC' lt_prog_compiler_static='-Bstatic' ;; esac ;; mingw* | cygwin* | pw32* | os2* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). lt_prog_compiler_pic='-DDLL_EXPORT' case $host_os in os2*) lt_prog_compiler_static='$wl-static' ;; esac ;; hpux9* | hpux10* | hpux11*) lt_prog_compiler_wl='-Wl,' # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but # not for PA HP-UX. case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) lt_prog_compiler_pic='+Z' ;; esac # Is there a better lt_prog_compiler_static that works with the bundled CC? lt_prog_compiler_static='$wl-a ${wl}archive' ;; irix5* | irix6* | nonstopux*) lt_prog_compiler_wl='-Wl,' # PIC (with -KPIC) is the default. lt_prog_compiler_static='-non_shared' ;; linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in # old Intel for x86_64, which still supported -KPIC. ecc*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-static' ;; # flang / f18. f95 an alias for gfortran or flang on Debian flang* | f18* | f95*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-fPIC' lt_prog_compiler_static='-static' ;; # icc used to be incompatible with GCC. # ICC 10 doesn't accept -KPIC any more. icc* | ifort*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-fPIC' lt_prog_compiler_static='-static' ;; # Lahey Fortran 8.1. lf95*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='--shared' lt_prog_compiler_static='--static' ;; nagfor*) # NAG Fortran compiler lt_prog_compiler_wl='-Wl,-Wl,,' lt_prog_compiler_pic='-PIC' lt_prog_compiler_static='-Bstatic' ;; tcc*) # Fabrice Bellard et al's Tiny C Compiler lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-fPIC' lt_prog_compiler_static='-static' ;; pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) # Portland Group compilers (*not* the Pentium gcc compiler, # which looks to be a dead project) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-fpic' lt_prog_compiler_static='-Bstatic' ;; ccc*) lt_prog_compiler_wl='-Wl,' # All Alpha code is PIC. lt_prog_compiler_static='-non_shared' ;; xl* | bgxl* | bgf* | mpixl*) # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-qpic' lt_prog_compiler_static='-qstaticlink' ;; *) case `$CC -V 2>&1 | $SED 5q` in *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*) # Sun Fortran 8.3 passes all unrecognized flags to the linker lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' lt_prog_compiler_wl='' ;; *Sun\ F* | *Sun*Fortran*) lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' lt_prog_compiler_wl='-Qoption ld ' ;; *Sun\ C*) # Sun C 5.9 lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' lt_prog_compiler_wl='-Wl,' ;; *Intel*\ [CF]*Compiler*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-fPIC' lt_prog_compiler_static='-static' ;; *Portland\ Group*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-fpic' lt_prog_compiler_static='-Bstatic' ;; esac ;; esac ;; newsos6) lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' ;; *nto* | *qnx*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. lt_prog_compiler_pic='-fPIC -shared' ;; osf3* | osf4* | osf5*) lt_prog_compiler_wl='-Wl,' # All OSF/1 code is PIC. lt_prog_compiler_static='-non_shared' ;; rdos*) lt_prog_compiler_static='-non_shared' ;; solaris*) lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' case $cc_basename in f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) lt_prog_compiler_wl='-Qoption ld ';; *) lt_prog_compiler_wl='-Wl,';; esac ;; sunos4*) lt_prog_compiler_wl='-Qoption ld ' lt_prog_compiler_pic='-PIC' lt_prog_compiler_static='-Bstatic' ;; sysv4 | sysv4.2uw2* | sysv4.3*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' ;; sysv4*MP*) if test -d /usr/nec; then lt_prog_compiler_pic='-Kconform_pic' lt_prog_compiler_static='-Bstatic' fi ;; sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' ;; unicos*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_can_build_shared=no ;; uts4*) lt_prog_compiler_pic='-pic' lt_prog_compiler_static='-Bstatic' ;; *) lt_prog_compiler_can_build_shared=no ;; esac fi case $host_os in # For platforms that do not support PIC, -DPIC is meaningless: *djgpp*) lt_prog_compiler_pic= ;; *) lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" ;; esac { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 printf %s "checking for $compiler option to produce PIC... " >&6; } if test ${lt_cv_prog_compiler_pic+y} then : printf %s "(cached) " >&6 else $as_nop lt_cv_prog_compiler_pic=$lt_prog_compiler_pic fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5 printf "%s\n" "$lt_cv_prog_compiler_pic" >&6; } lt_prog_compiler_pic=$lt_cv_prog_compiler_pic # # Check to make sure the PIC flag actually works. # if test -n "$lt_prog_compiler_pic"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 printf %s "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; } if test ${lt_cv_prog_compiler_pic_works+y} then : printf %s "(cached) " >&6 else $as_nop lt_cv_prog_compiler_pic_works=no ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="$lt_prog_compiler_pic -DPIC" ## exclude from sc_useless_quotes_in_assignment # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_pic_works=yes fi fi $RM conftest* fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5 printf "%s\n" "$lt_cv_prog_compiler_pic_works" >&6; } if test yes = "$lt_cv_prog_compiler_pic_works"; then case $lt_prog_compiler_pic in "" | " "*) ;; *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;; esac else lt_prog_compiler_pic= lt_prog_compiler_can_build_shared=no fi fi # # Check to make sure the static flag actually works. # wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\" { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 printf %s "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } if test ${lt_cv_prog_compiler_static_works+y} then : printf %s "(cached) " >&6 else $as_nop lt_cv_prog_compiler_static_works=no save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS $lt_tmp_static_flag" echo "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then # The linker can only warn and ignore the option if not recognized # So say no if there are warnings if test -s conftest.err; then # Append any errors to the config.log. cat conftest.err 1>&5 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_static_works=yes fi else lt_cv_prog_compiler_static_works=yes fi fi $RM -r conftest* LDFLAGS=$save_LDFLAGS fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5 printf "%s\n" "$lt_cv_prog_compiler_static_works" >&6; } if test yes = "$lt_cv_prog_compiler_static_works"; then : else lt_prog_compiler_static= fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 printf %s "checking if $compiler supports -c -o file.$ac_objext... " >&6; } if test ${lt_cv_prog_compiler_c_o+y} then : printf %s "(cached) " >&6 else $as_nop lt_cv_prog_compiler_c_o=no $RM -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-o out/conftest2.$ac_objext" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then lt_cv_prog_compiler_c_o=yes fi fi chmod u+w . 2>&5 $RM conftest* # SGI C++ compiler will create directory out/ii_files/ for # template instantiation test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files $RM out/* && rmdir out cd .. $RM -r conftest $RM conftest* fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 printf "%s\n" "$lt_cv_prog_compiler_c_o" >&6; } { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 printf %s "checking if $compiler supports -c -o file.$ac_objext... " >&6; } if test ${lt_cv_prog_compiler_c_o+y} then : printf %s "(cached) " >&6 else $as_nop lt_cv_prog_compiler_c_o=no $RM -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-o out/conftest2.$ac_objext" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then lt_cv_prog_compiler_c_o=yes fi fi chmod u+w . 2>&5 $RM conftest* # SGI C++ compiler will create directory out/ii_files/ for # template instantiation test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files $RM out/* && rmdir out cd .. $RM -r conftest $RM conftest* fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 printf "%s\n" "$lt_cv_prog_compiler_c_o" >&6; } hard_links=nottested if test no = "$lt_cv_prog_compiler_c_o" && test no != "$need_locks"; then # do not overwrite the value of need_locks provided by the user { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 printf %s "checking if we can lock with hard links... " >&6; } hard_links=yes $RM conftest* ln conftest.a conftest.b 2>/dev/null && hard_links=no touch conftest.a ln conftest.a conftest.b 2>&5 || hard_links=no ln conftest.a conftest.b 2>/dev/null && hard_links=no { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 printf "%s\n" "$hard_links" >&6; } if test no = "$hard_links"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5 printf "%s\n" "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;} need_locks=warn fi else need_locks=no fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 printf %s "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } runpath_var= allow_undefined_flag= always_export_symbols=no archive_cmds= archive_expsym_cmds= compiler_needs_object=no enable_shared_with_static_runtimes=no export_dynamic_flag_spec= export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' hardcode_automatic=no hardcode_direct=no hardcode_direct_absolute=no hardcode_libdir_flag_spec= hardcode_libdir_separator= hardcode_minus_L=no hardcode_shlibpath_var=unsupported inherit_rpath=no link_all_deplibs=unknown module_cmds= module_expsym_cmds= old_archive_from_new_cmds= old_archive_from_expsyms_cmds= thread_safe_flag_spec= whole_archive_flag_spec= # include_expsyms should be a list of space-separated symbols to be *always* # included in the symbol list include_expsyms= # exclude_expsyms can be an extended regexp of symbols to exclude # it will be wrapped by ' (' and ')$', so one must not match beginning or # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc', # as well as any symbol that contains 'd'. exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out # platforms (ab)use it in PIC code, but their linkers get confused if # the symbol is explicitly referenced. Since portable code cannot # rely on this symbol name, it's probably fine to never include it in # preloaded symbol tables. # Exclude shared library initialization/finalization symbols. extract_expsyms_cmds= case $host_os in cygwin* | mingw* | pw32* | cegcc*) # FIXME: the MSVC++ and ICC port hasn't been tested in a loooong time # When not using gcc, we currently assume that we are using # Microsoft Visual C++ or Intel C++ Compiler. if test yes != "$GCC"; then with_gnu_ld=no fi ;; interix*) # we just hope/assume this is gcc and not c89 (= MSVC++ or ICC) with_gnu_ld=yes ;; openbsd* | bitrig*) with_gnu_ld=no ;; linux* | k*bsd*-gnu | gnu*) link_all_deplibs=no ;; esac ld_shlibs=yes # On some targets, GNU ld is compatible enough with the native linker # that we're better off using the native interface for both. lt_use_gnu_ld_interface=no if test yes = "$with_gnu_ld"; then case $host_os in aix*) # The AIX port of GNU ld has always aspired to compatibility # with the native linker. However, as the warning in the GNU ld # block says, versions before 2.19.5* couldn't really create working # shared libraries, regardless of the interface used. case `$LD -v 2>&1` in *\ \(GNU\ Binutils\)\ 2.19.5*) ;; *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;; *\ \(GNU\ Binutils\)\ [3-9]*) ;; *) lt_use_gnu_ld_interface=yes ;; esac ;; *) lt_use_gnu_ld_interface=yes ;; esac fi if test yes = "$lt_use_gnu_ld_interface"; then # If archive_cmds runs LD, not CC, wlarc should be empty wlarc='$wl' # Set some defaults for GNU ld with shared library support. These # are reset later if shared libraries are not supported. Putting them # here allows them to be overridden if necessary. runpath_var=LD_RUN_PATH hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' export_dynamic_flag_spec='$wl--export-dynamic' # ancient GNU ld didn't support --whole-archive et. al. if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then whole_archive_flag_spec=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' else whole_archive_flag_spec= fi supports_anon_versioning=no case `$LD -v | $SED -e 's/([^)]\+)\s\+//' 2>&1` in *GNU\ gold*) supports_anon_versioning=yes ;; *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... *\ 2.11.*) ;; # other 2.11 versions *) supports_anon_versioning=yes ;; esac # See if GNU ld supports shared libraries. case $host_os in aix[3-9]*) # On AIX/PPC, the GNU linker is very broken if test ia64 != "$host_cpu"; then ld_shlibs=no cat <<_LT_EOF 1>&2 *** Warning: the GNU linker, at least up to release 2.19, is reported *** to be unable to reliably create shared libraries on AIX. *** Therefore, libtool is disabling shared libraries support. If you *** really care for shared libraries, you may want to install binutils *** 2.20 or above, or modify your PATH so that a non-GNU linker is found. *** You will then need to restart the configuration process. _LT_EOF fi ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds='' ;; m68k) archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' hardcode_libdir_flag_spec='-L$libdir' hardcode_minus_L=yes ;; esac ;; beos*) if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then allow_undefined_flag=unsupported # Joseph Beckenbach says some releases of gcc # support --undefined. This deserves some investigation. FIXME archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' else ld_shlibs=no fi ;; cygwin* | mingw* | pw32* | cegcc*) # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless, # as there is no search path for DLLs. hardcode_libdir_flag_spec='-L$libdir' export_dynamic_flag_spec='$wl--export-all-symbols' allow_undefined_flag=unsupported always_export_symbols=no enable_shared_with_static_runtimes=yes export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols' exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' # If the export-symbols file already is a .def file, use it as # is; otherwise, prepend EXPORTS... archive_expsym_cmds='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then cp $export_symbols $output_objdir/$soname.def; else echo EXPORTS > $output_objdir/$soname.def; cat $export_symbols >> $output_objdir/$soname.def; fi~ $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else ld_shlibs=no fi ;; haiku*) archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' link_all_deplibs=yes ;; os2*) hardcode_libdir_flag_spec='-L$libdir' hardcode_minus_L=yes allow_undefined_flag=unsupported shrext_cmds=.dll archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ prefix_cmds="$SED"~ if test EXPORTS = "`$SED 1q $export_symbols`"; then prefix_cmds="$prefix_cmds -e 1d"; fi~ prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' enable_shared_with_static_runtimes=yes file_list_spec='@' ;; interix[3-9]*) hardcode_direct=no hardcode_shlibpath_var=no hardcode_libdir_flag_spec='$wl-rpath,$libdir' export_dynamic_flag_spec='$wl-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' archive_expsym_cmds='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) tmp_diet=no if test linux-dietlibc = "$host_os"; then case $cc_basename in diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) esac fi if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ && test no = "$tmp_diet" then tmp_addflag=' $pic_flag' tmp_sharedflag='-shared' case $cc_basename,$host_cpu in pgcc*) # Portland Group C compiler whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' tmp_addflag=' $pic_flag' ;; pgf77* | pgf90* | pgf95* | pgfortran*) # Portland Group f77 and f90 compilers whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' tmp_addflag=' $pic_flag -Mnomain' ;; ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 tmp_addflag=' -i_dynamic' ;; efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 tmp_addflag=' -i_dynamic -nofor_main' ;; ifc* | ifort*) # Intel Fortran compiler tmp_addflag=' -nofor_main' ;; lf95*) # Lahey Fortran 8.1 whole_archive_flag_spec= tmp_sharedflag='--shared' ;; nagfor*) # NAGFOR 5.3 tmp_sharedflag='-Wl,-shared' ;; xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below) tmp_sharedflag='-qmkshrobj' tmp_addflag= ;; nvcc*) # Cuda Compiler Driver 2.2 whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' compiler_needs_object=yes ;; esac case `$CC -V 2>&1 | $SED 5q` in *Sun\ C*) # Sun C 5.9 whole_archive_flag_spec='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' compiler_needs_object=yes tmp_sharedflag='-G' ;; *Sun\ F*) # Sun Fortran 8.3 tmp_sharedflag='-G' ;; esac archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' if test yes = "$supports_anon_versioning"; then archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' fi case $cc_basename in tcc*) hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' export_dynamic_flag_spec='-rdynamic' ;; xlf* | bgf* | bgxlf* | mpixlf*) # IBM XL Fortran 10.1 on PPC cannot create shared libs itself whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive' hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' if test yes = "$supports_anon_versioning"; then archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' fi ;; esac else ld_shlibs=no fi ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' wlarc= else archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' fi ;; solaris*) if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then ld_shlibs=no cat <<_LT_EOF 1>&2 *** Warning: The releases 2.8.* of the GNU linker cannot reliably *** create shared libraries on Solaris systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.9.1 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. _LT_EOF elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs=no fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) case `$LD -v 2>&1` in *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) ld_shlibs=no cat <<_LT_EOF 1>&2 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot *** reliably create shared libraries on SCO systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.16.91.0.3 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. _LT_EOF ;; *) # For security reasons, it is highly recommended that you always # use absolute paths for naming shared libraries, and exclude the # DT_RUNPATH tag from executables and libraries. But doing so # requires that you compile everything twice, which is a pain. if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs=no fi ;; esac ;; sunos4*) archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' wlarc= hardcode_direct=yes hardcode_shlibpath_var=no ;; *) if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs=no fi ;; esac if test no = "$ld_shlibs"; then runpath_var= hardcode_libdir_flag_spec= export_dynamic_flag_spec= whole_archive_flag_spec= fi else # PORTME fill in a description of your system's linker (not GNU ld) case $host_os in aix3*) allow_undefined_flag=unsupported always_export_symbols=yes archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' # Note: this linker hardcodes the directories in LIBPATH if there # are no directories specified by -L. hardcode_minus_L=yes if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then # Neither direct hardcoding nor static linking is supported with a # broken collect2. hardcode_direct=unsupported fi ;; aix[4-9]*) if test ia64 = "$host_cpu"; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' no_entry_flag= else # If we're using GNU nm, then we don't want the "-C" option. # -C means demangle to GNU nm, but means don't demangle to AIX nm. # Without the "-l" option, or with the "-B" option, AIX nm treats # weak defined symbols like other global defined symbols, whereas # GNU nm marks them as "W". # While the 'weak' keyword is ignored in the Export File, we need # it in the Import File for the 'aix-soname' feature, so we have # to replace the "-B" option with "-P" for AIX nm. if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' else export_symbols_cmds='`func_echo_all $NM | $SED -e '\''s/B\([^B]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && (substr(\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' fi aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we # have runtime linking enabled, and use it for executables. # For shared libraries, we enable/disable runtime linking # depending on the kind of the shared library created - # when "with_aix_soname,aix_use_runtimelinking" is: # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables # "aix,yes" lib.so shared, rtl:yes, for executables # lib.a static archive # "both,no" lib.so.V(shr.o) shared, rtl:yes # lib.a(lib.so.V) shared, rtl:no, for executables # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a(lib.so.V) shared, rtl:no # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a static archive case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) for ld_flag in $LDFLAGS; do if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then aix_use_runtimelinking=yes break fi done if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then # With aix-soname=svr4, we create the lib.so.V shared archives only, # so we don't have lib.a shared libs to link our executables. # We have to force runtime linking in this case. aix_use_runtimelinking=yes LDFLAGS="$LDFLAGS -Wl,-brtl" fi ;; esac exp_sym_flag='-bexport' no_entry_flag='-bnoentry' fi # When large executables or shared objects are built, AIX ld can # have problems creating the table of contents. If linking a library # or program results in "error TOC overflow" add -mminimal-toc to # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. archive_cmds='' hardcode_direct=yes hardcode_direct_absolute=yes hardcode_libdir_separator=':' link_all_deplibs=yes file_list_spec='$wl-f,' case $with_aix_soname,$aix_use_runtimelinking in aix,*) ;; # traditional, no import file svr4,* | *,yes) # use import file # The Import File defines what to hardcode. hardcode_direct=no hardcode_direct_absolute=no ;; esac if test yes = "$GCC"; then case $host_os in aix4.[012]|aix4.[012].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ collect2name=`$CC -print-prog-name=collect2` if test -f "$collect2name" && strings "$collect2name" | $GREP resolve_lib_name >/dev/null then # We have reworked collect2 : else # We have old collect2 hardcode_direct=unsupported # It fails to find uninstalled libraries when the uninstalled # path is not listed in the libpath. Setting hardcode_minus_L # to unsupported forces relinking hardcode_minus_L=yes hardcode_libdir_flag_spec='-L$libdir' hardcode_libdir_separator= fi ;; esac shared_flag='-shared' if test yes = "$aix_use_runtimelinking"; then shared_flag="$shared_flag "'$wl-G' fi # Need to ensure runtime linking is disabled for the traditional # shared library, or the linker may eventually find shared libraries # /with/ Import File - we do not want to mix them. shared_flag_aix='-shared' shared_flag_svr4='-shared $wl-G' else # not using gcc if test ia64 = "$host_cpu"; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else if test yes = "$aix_use_runtimelinking"; then shared_flag='$wl-G' else shared_flag='$wl-bM:SRE' fi shared_flag_aix='$wl-bM:SRE' shared_flag_svr4='$wl-G' fi fi export_dynamic_flag_spec='$wl-bexpall' # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to export. always_export_symbols=yes if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. allow_undefined_flag='-berok' # Determine the default libpath from the value encoded in an # empty executable. if test set = "${lt_cv_aix_libpath+set}"; then aix_libpath=$lt_cv_aix_libpath else if test ${lt_cv_aix_libpath_+y} then : printf %s "(cached) " >&6 else $as_nop cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\([^ ]*\) *$/\1/ p } }' lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$lt_cv_aix_libpath_"; then lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext if test -z "$lt_cv_aix_libpath_"; then lt_cv_aix_libpath_=/usr/lib:/lib fi fi aix_libpath=$lt_cv_aix_libpath_ fi hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath" archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag else if test ia64 = "$host_cpu"; then hardcode_libdir_flag_spec='$wl-R $libdir:/usr/lib:/lib' allow_undefined_flag="-z nodefs" archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an # empty executable. if test set = "${lt_cv_aix_libpath+set}"; then aix_libpath=$lt_cv_aix_libpath else if test ${lt_cv_aix_libpath_+y} then : printf %s "(cached) " >&6 else $as_nop cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\([^ ]*\) *$/\1/ p } }' lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$lt_cv_aix_libpath_"; then lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext if test -z "$lt_cv_aix_libpath_"; then lt_cv_aix_libpath_=/usr/lib:/lib fi fi aix_libpath=$lt_cv_aix_libpath_ fi hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. no_undefined_flag=' $wl-bernotok' allow_undefined_flag=' $wl-berok' if test yes = "$with_gnu_ld"; then # We only use this code for GNU lds that support --whole-archive. whole_archive_flag_spec='$wl--whole-archive$convenience $wl--no-whole-archive' else # Exported symbols can be pulled into shared objects from archives whole_archive_flag_spec='$convenience' fi archive_cmds_need_lc=yes archive_expsym_cmds='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' # -brtl affects multiple linker settings, -berok does not and is overridden later compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([, ]\\)%-berok\\1%g"`' if test svr4 != "$with_aix_soname"; then # This is similar to how AIX traditionally builds its shared libraries. archive_expsym_cmds="$archive_expsym_cmds"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' fi if test aix != "$with_aix_soname"; then archive_expsym_cmds="$archive_expsym_cmds"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' else # used by -dlpreopen to get the symbols archive_expsym_cmds="$archive_expsym_cmds"'~$MV $output_objdir/$realname.d/$soname $output_objdir' fi archive_expsym_cmds="$archive_expsym_cmds"'~$RM -r $output_objdir/$realname.d' fi fi ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds='' ;; m68k) archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' hardcode_libdir_flag_spec='-L$libdir' hardcode_minus_L=yes ;; esac ;; bsdi[45]*) export_dynamic_flag_spec=-rdynamic ;; cygwin* | mingw* | pw32* | cegcc*) # When not using gcc, we currently assume that we are using # Microsoft Visual C++ or Intel C++ Compiler. # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. case $cc_basename in cl* | icl*) # Native MSVC or ICC hardcode_libdir_flag_spec=' ' allow_undefined_flag=unsupported always_export_symbols=yes file_list_spec='@' # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' archive_expsym_cmds='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then cp "$export_symbols" "$output_objdir/$soname.def"; echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; else $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; fi~ $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ linknames=' # The linker will not automatically build a static lib if we build a DLL. # _LT_TAGVAR(old_archive_from_new_cmds, )='true' enable_shared_with_static_runtimes=yes exclude_expsyms='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' # Don't use ranlib old_postinstall_cmds='chmod 644 $oldlib' postlink_cmds='lt_outputfile="@OUTPUT@"~ lt_tool_outputfile="@TOOL_OUTPUT@"~ case $lt_outputfile in *.exe|*.EXE) ;; *) lt_outputfile=$lt_outputfile.exe lt_tool_outputfile=$lt_tool_outputfile.exe ;; esac~ if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; $RM "$lt_outputfile.manifest"; fi' ;; *) # Assume MSVC and ICC wrapper hardcode_libdir_flag_spec=' ' allow_undefined_flag=unsupported # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' # The linker will automatically build a .lib file if we build a DLL. old_archive_from_new_cmds='true' # FIXME: Should let the user specify the lib program. old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs' enable_shared_with_static_runtimes=yes ;; esac ;; darwin* | rhapsody*) archive_cmds_need_lc=no hardcode_direct=no hardcode_automatic=yes hardcode_shlibpath_var=unsupported if test yes = "$lt_cv_ld_force_load"; then whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' else whole_archive_flag_spec='' fi link_all_deplibs=yes allow_undefined_flag=$_lt_dar_allow_undefined case $cc_basename in ifort*|nagfor*) _lt_dar_can_shared=yes ;; *) _lt_dar_can_shared=$GCC ;; esac if test yes = "$_lt_dar_can_shared"; then output_verbose_link_cmd=func_echo_all archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil" module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" archive_expsym_cmds="$SED 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" module_expsym_cmds="$SED -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" else ld_shlibs=no fi ;; dgux*) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec='-L$libdir' hardcode_shlibpath_var=no ;; # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor # support. Future versions do this automatically, but an explicit c++rt0.o # does not break anything, and helps significantly (at the cost of a little # extra space). freebsd2.2*) archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' hardcode_libdir_flag_spec='-R$libdir' hardcode_direct=yes hardcode_shlibpath_var=no ;; # Unfortunately, older versions of FreeBSD 2 do not have this feature. freebsd2.*) archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' hardcode_direct=yes hardcode_minus_L=yes hardcode_shlibpath_var=no ;; # FreeBSD 3 and greater uses gcc -shared to do shared libraries. freebsd* | dragonfly* | midnightbsd*) archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' hardcode_libdir_flag_spec='-R$libdir' hardcode_direct=yes hardcode_shlibpath_var=no ;; hpux9*) if test yes = "$GCC"; then archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' else archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' fi hardcode_libdir_flag_spec='$wl+b $wl$libdir' hardcode_libdir_separator=: hardcode_direct=yes # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L=yes export_dynamic_flag_spec='$wl-E' ;; hpux10*) if test yes,no = "$GCC,$with_gnu_ld"; then archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' fi if test no = "$with_gnu_ld"; then hardcode_libdir_flag_spec='$wl+b $wl$libdir' hardcode_libdir_separator=: hardcode_direct=yes hardcode_direct_absolute=yes export_dynamic_flag_spec='$wl-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L=yes fi ;; hpux11*) if test yes,no = "$GCC,$with_gnu_ld"; then case $host_cpu in hppa*64*) archive_cmds='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac else case $host_cpu in hppa*64*) archive_cmds='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) archive_cmds='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) # Older versions of the 11.00 compiler do not understand -b yet # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5 printf %s "checking if $CC understands -b... " >&6; } if test ${lt_cv_prog_compiler__b+y} then : printf %s "(cached) " >&6 else $as_nop lt_cv_prog_compiler__b=no save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS -b" echo "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then # The linker can only warn and ignore the option if not recognized # So say no if there are warnings if test -s conftest.err; then # Append any errors to the config.log. cat conftest.err 1>&5 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler__b=yes fi else lt_cv_prog_compiler__b=yes fi fi $RM -r conftest* LDFLAGS=$save_LDFLAGS fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5 printf "%s\n" "$lt_cv_prog_compiler__b" >&6; } if test yes = "$lt_cv_prog_compiler__b"; then archive_cmds='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' fi ;; esac fi if test no = "$with_gnu_ld"; then hardcode_libdir_flag_spec='$wl+b $wl$libdir' hardcode_libdir_separator=: case $host_cpu in hppa*64*|ia64*) hardcode_direct=no hardcode_shlibpath_var=no ;; *) hardcode_direct=yes hardcode_direct_absolute=yes export_dynamic_flag_spec='$wl-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L=yes ;; esac fi ;; irix5* | irix6* | nonstopux*) if test yes = "$GCC"; then archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' # Try to use the -exported_symbol ld option, if it does not # work, assume that -exports_file does not work either and # implicitly export all symbols. # This should be the same for all languages, so no per-tag cache variable. { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5 printf %s "checking whether the $host_os linker accepts -exported_symbol... " >&6; } if test ${lt_cv_irix_exported_symbol+y} then : printf %s "(cached) " >&6 else $as_nop save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int foo (void) { return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : lt_cv_irix_exported_symbol=yes else $as_nop lt_cv_irix_exported_symbol=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LDFLAGS=$save_LDFLAGS fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5 printf "%s\n" "$lt_cv_irix_exported_symbol" >&6; } if test yes = "$lt_cv_irix_exported_symbol"; then archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib' fi link_all_deplibs=no else archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib' fi archive_cmds_need_lc='no' hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' hardcode_libdir_separator=: inherit_rpath=yes link_all_deplibs=yes ;; linux*) case $cc_basename in tcc*) # Fabrice Bellard et al's Tiny C Compiler ld_shlibs=yes archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' ;; esac ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out else archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF fi hardcode_libdir_flag_spec='-R$libdir' hardcode_direct=yes hardcode_shlibpath_var=no ;; newsos6) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct=yes hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' hardcode_libdir_separator=: hardcode_shlibpath_var=no ;; *nto* | *qnx*) ;; openbsd* | bitrig*) if test -f /usr/libexec/ld.so; then hardcode_direct=yes hardcode_shlibpath_var=no hardcode_direct_absolute=yes if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols' hardcode_libdir_flag_spec='$wl-rpath,$libdir' export_dynamic_flag_spec='$wl-E' else archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' hardcode_libdir_flag_spec='$wl-rpath,$libdir' fi else ld_shlibs=no fi ;; os2*) hardcode_libdir_flag_spec='-L$libdir' hardcode_minus_L=yes allow_undefined_flag=unsupported shrext_cmds=.dll archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ prefix_cmds="$SED"~ if test EXPORTS = "`$SED 1q $export_symbols`"; then prefix_cmds="$prefix_cmds -e 1d"; fi~ prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' enable_shared_with_static_runtimes=yes file_list_spec='@' ;; osf3*) if test yes = "$GCC"; then allow_undefined_flag=' $wl-expect_unresolved $wl\*' archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' else allow_undefined_flag=' -expect_unresolved \*' archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' fi archive_cmds_need_lc='no' hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' hardcode_libdir_separator=: ;; osf4* | osf5*) # as osf3* with the addition of -msym flag if test yes = "$GCC"; then allow_undefined_flag=' $wl-expect_unresolved $wl\*' archive_cmds='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' else allow_undefined_flag=' -expect_unresolved \*' archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ $CC -shared$allow_undefined_flag $wl-input $wl$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~$RM $lib.exp' # Both c and cxx compiler support -rpath directly hardcode_libdir_flag_spec='-rpath $libdir' fi archive_cmds_need_lc='no' hardcode_libdir_separator=: ;; solaris*) no_undefined_flag=' -z defs' if test yes = "$GCC"; then wlarc='$wl' archive_cmds='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -shared $pic_flag $wl-z ${wl}text $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' else case `$CC -V 2>&1` in *"Compilers 5.0"*) wlarc='' archive_cmds='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags' archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' ;; *) wlarc='$wl' archive_cmds='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' ;; esac fi hardcode_libdir_flag_spec='-R$libdir' hardcode_shlibpath_var=no case $host_os in solaris2.[0-5] | solaris2.[0-5].*) ;; *) # The compiler driver will combine and reorder linker options, # but understands '-z linker_flag'. GCC discards it without '$wl', # but is careful enough not to reorder. # Supported since Solaris 2.6 (maybe 2.5.1?) if test yes = "$GCC"; then whole_archive_flag_spec='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' else whole_archive_flag_spec='-z allextract$convenience -z defaultextract' fi ;; esac link_all_deplibs=yes ;; sunos4*) if test sequent = "$host_vendor"; then # Use $CC to link under sequent, because it throws in some extra .o # files that make .init and .fini sections work. archive_cmds='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' fi hardcode_libdir_flag_spec='-L$libdir' hardcode_direct=yes hardcode_minus_L=yes hardcode_shlibpath_var=no ;; sysv4) case $host_vendor in sni) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct=yes # is this really true??? ;; siemens) ## LD is ld it makes a PLAMLIB ## CC just makes a GrossModule. archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' reload_cmds='$CC -r -o $output$reload_objs' hardcode_direct=no ;; motorola) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct=no #Motorola manual says yes, but my tests say they lie ;; esac runpath_var='LD_RUN_PATH' hardcode_shlibpath_var=no ;; sysv4.3*) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_shlibpath_var=no export_dynamic_flag_spec='-Bexport' ;; sysv4*MP*) if test -d /usr/nec; then archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_shlibpath_var=no runpath_var=LD_RUN_PATH hardcode_runpath_var=yes ld_shlibs=yes fi ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) no_undefined_flag='$wl-z,text' archive_cmds_need_lc=no hardcode_shlibpath_var=no runpath_var='LD_RUN_PATH' if test yes = "$GCC"; then archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; sysv5* | sco3.2v5* | sco5v6*) # Note: We CANNOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. no_undefined_flag='$wl-z,text' allow_undefined_flag='$wl-z,nodefs' archive_cmds_need_lc=no hardcode_shlibpath_var=no hardcode_libdir_flag_spec='$wl-R,$libdir' hardcode_libdir_separator=':' link_all_deplibs=yes export_dynamic_flag_spec='$wl-Bexport' runpath_var='LD_RUN_PATH' if test yes = "$GCC"; then archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; uts4*) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec='-L$libdir' hardcode_shlibpath_var=no ;; *) ld_shlibs=no ;; esac if test sni = "$host_vendor"; then case $host in sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) export_dynamic_flag_spec='$wl-Blargedynsym' ;; esac fi fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5 printf "%s\n" "$ld_shlibs" >&6; } test no = "$ld_shlibs" && can_build_shared=no with_gnu_ld=$with_gnu_ld # # Do we need to explicitly link libc? # case "x$archive_cmds_need_lc" in x|xyes) # Assume -lc should be added archive_cmds_need_lc=yes if test yes,yes = "$GCC,$enable_shared"; then case $archive_cmds in *'~'*) # FIXME: we may have to deal with multi-command sequences. ;; '$CC '*) # Test whether the compiler implicitly links with -lc since on some # systems, -lgcc has to come before -lc. If gcc already passes -lc # to ld, don't add -lc before -lgcc. { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 printf %s "checking whether -lc should be explicitly linked in... " >&6; } if test ${lt_cv_archive_cmds_need_lc+y} then : printf %s "(cached) " >&6 else $as_nop $RM conftest* echo "$lt_simple_compile_test_code" > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } 2>conftest.err; then soname=conftest lib=conftest libobjs=conftest.$ac_objext deplibs= wl=$lt_prog_compiler_wl pic_flag=$lt_prog_compiler_pic compiler_flags=-v linker_flags=-v verstring= output_objdir=. libname=conftest lt_save_allow_undefined_flag=$allow_undefined_flag allow_undefined_flag= if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 ac_status=$? printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } then lt_cv_archive_cmds_need_lc=no else lt_cv_archive_cmds_need_lc=yes fi allow_undefined_flag=$lt_save_allow_undefined_flag else cat conftest.err 1>&5 fi $RM conftest* fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5 printf "%s\n" "$lt_cv_archive_cmds_need_lc" >&6; } archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc ;; esac fi ;; esac { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 printf %s "checking dynamic linker characteristics... " >&6; } if test yes = "$GCC"; then case $host_os in darwin*) lt_awk_arg='/^libraries:/,/LR/' ;; *) lt_awk_arg='/^libraries:/' ;; esac case $host_os in mingw* | cegcc*) lt_sed_strip_eq='s|=\([A-Za-z]:\)|\1|g' ;; *) lt_sed_strip_eq='s|=/|/|g' ;; esac lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` case $lt_search_path_spec in *\;*) # if the path contains ";" then we assume it to be the separator # otherwise default to the standard path separator (i.e. ":") - it is # assumed that no part of a normal pathname contains ";" but that should # okay in the real world where ";" in dirpaths is itself problematic. lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` ;; *) lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` ;; esac # Ok, now we have the path, separated by spaces, we can step through it # and add multilib dir if necessary... lt_tmp_lt_search_path_spec= lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` # ...but if some path component already ends with the multilib dir we assume # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer). case "$lt_multi_os_dir; $lt_search_path_spec " in "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*) lt_multi_os_dir= ;; esac for lt_sys_path in $lt_search_path_spec; do if test -d "$lt_sys_path$lt_multi_os_dir"; then lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir" elif test -n "$lt_multi_os_dir"; then test -d "$lt_sys_path" && \ lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" fi done lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' BEGIN {RS = " "; FS = "/|\n";} { lt_foo = ""; lt_count = 0; for (lt_i = NF; lt_i > 0; lt_i--) { if ($lt_i != "" && $lt_i != ".") { if ($lt_i == "..") { lt_count++; } else { if (lt_count == 0) { lt_foo = "/" $lt_i lt_foo; } else { lt_count--; } } } } if (lt_foo != "") { lt_freq[lt_foo]++; } if (lt_freq[lt_foo] == 1) { print lt_foo; } }'` # AWK program above erroneously prepends '/' to C:/dos/paths # for these hosts. case $host_os in mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ $SED 's|/\([A-Za-z]:\)|\1|g'` ;; esac sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` else sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" fi library_names_spec= libname_spec='lib$name' soname_spec= shrext_cmds=.so postinstall_cmds= postuninstall_cmds= finish_cmds= finish_eval= shlibpath_var= shlibpath_overrides_runpath=unknown version_type=none dynamic_linker="$host_os ld.so" sys_lib_dlsearch_path_spec="/lib /usr/lib" need_lib_prefix=unknown hardcode_into_libs=no # when you set need_version to no, make sure it does not cause -set_version # flags to be left without arguments need_version=unknown case $host_os in aix3*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname.a' shlibpath_var=LIBPATH # AIX 3 has no versioning support, so we append a major version to the name. soname_spec='$libname$release$shared_ext$major' ;; aix[4-9]*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no hardcode_into_libs=yes if test ia64 = "$host_cpu"; then # AIX 5 supports IA64 library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH else # With GCC up to 2.95.x, collect2 would create an import file # for dependence libraries. The import file would start with # the line '#! .'. This would cause the generated library to # depend on '.', always an invalid library. This was fixed in # development snapshots of GCC prior to 3.0. case $host_os in aix4 | aix4.[01] | aix4.[01].*) if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' echo ' yes ' echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then : else can_build_shared=no fi ;; esac # Using Import Files as archive members, it is possible to support # filename-based versioning of shared library archives on AIX. While # this would work for both with and without runtime linking, it will # prevent static linking of such archives. So we do filename-based # shared library versioning with .so extension only, which is used # when both runtime linking and shared linking is enabled. # Unfortunately, runtime linking may impact performance, so we do # not want this to be the default eventually. Also, we use the # versioned .so libs for executables only if there is the -brtl # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only. # To allow for filename-based versioning support, we need to create # libNAME.so.V as an archive file, containing: # *) an Import File, referring to the versioned filename of the # archive as well as the shared archive member, telling the # bitwidth (32 or 64) of that shared object, and providing the # list of exported symbols of that shared object, eventually # decorated with the 'weak' keyword # *) the shared object with the F_LOADONLY flag set, to really avoid # it being seen by the linker. # At run time we better use the real file rather than another symlink, # but for link time we create the symlink libNAME.so -> libNAME.so.V case $with_aix_soname,$aix_use_runtimelinking in # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct # soname into executable. Probably we can add versioning support to # collect2, so additional links can be useful in future. aix,yes) # traditional libtool dynamic_linker='AIX unversionable lib.so' # If using run time linking (on AIX 4.2 or later) use lib.so # instead of lib.a to let people know that these are not # typical AIX shared libraries. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' ;; aix,no) # traditional AIX only dynamic_linker='AIX lib.a(lib.so.V)' # We preserve .a as extension for shared libraries through AIX4.2 # and later when we are not doing run time linking. library_names_spec='$libname$release.a $libname.a' soname_spec='$libname$release$shared_ext$major' ;; svr4,*) # full svr4 only dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o)" library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' # We do not specify a path in Import Files, so LIBPATH fires. shlibpath_overrides_runpath=yes ;; *,yes) # both, prefer svr4 dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o), lib.a(lib.so.V)" library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' # unpreferred sharedlib libNAME.a needs extra handling postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"' postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"' # We do not specify a path in Import Files, so LIBPATH fires. shlibpath_overrides_runpath=yes ;; *,no) # both, prefer aix dynamic_linker="AIX lib.a(lib.so.V), lib.so.V($shared_archive_member_spec.o)" library_names_spec='$libname$release.a $libname.a' soname_spec='$libname$release$shared_ext$major' # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)' postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"' ;; esac shlibpath_var=LIBPATH fi ;; amigaos*) case $host_cpu in powerpc) # Since July 2007 AmigaOS4 officially supports .so libraries. # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' ;; m68k) library_names_spec='$libname.ixlibrary $libname.a' # Create ${libname}_ixlibrary.a entries in /sys/libs. finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' ;; esac ;; beos*) library_names_spec='$libname$shared_ext' dynamic_linker="$host_os ld.so" shlibpath_var=LIBRARY_PATH ;; bsdi[45]*) version_type=linux # correct to gnu/linux during the next big refactor need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" # the default ld.so.conf also contains /usr/contrib/lib and # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow # libtool to hard-code these into programs ;; cygwin* | mingw* | pw32* | cegcc*) version_type=windows shrext_cmds=.dll need_version=no need_lib_prefix=no case $GCC,$cc_basename in yes,*) # gcc library_names_spec='$libname.dll.a' # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname~ if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; fi' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' shlibpath_overrides_runpath=yes case $host_os in cygwin*) # Cygwin DLLs use 'cyg' prefix rather than 'lib' soname_spec='`echo $libname | $SED -e 's/^lib/cyg/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api" ;; mingw* | cegcc*) # MinGW DLLs use traditional 'lib' prefix soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' ;; pw32*) # pw32 DLLs use 'pw' prefix rather than 'lib' library_names_spec='`echo $libname | $SED -e 's/^lib/pw/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' ;; esac dynamic_linker='Win32 ld.exe' ;; *,cl* | *,icl*) # Native MSVC or ICC libname_spec='$name' soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' library_names_spec='$libname.dll.lib' case $build_os in mingw*) sys_lib_search_path_spec= lt_save_ifs=$IFS IFS=';' for lt_path in $LIB do IFS=$lt_save_ifs # Let DOS variable expansion print the short 8.3 style file name. lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" done IFS=$lt_save_ifs # Convert to MSYS style. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` ;; cygwin*) # Convert to unix form, then to dos form, then back to unix form # but this time dos style (no spaces!) so that the unix form looks # like /cygdrive/c/PROGRA~1:/cygdr... sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` ;; *) sys_lib_search_path_spec=$LIB if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then # It is most probably a Windows format PATH. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` else sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` fi # FIXME: find the short name or the path components, as spaces are # common. (e.g. "Program Files" -> "PROGRA~1") ;; esac # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' shlibpath_overrides_runpath=yes dynamic_linker='Win32 link.exe' ;; *) # Assume MSVC and ICC wrapper library_names_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext $libname.lib' dynamic_linker='Win32 ld.exe' ;; esac # FIXME: first we should search . and the directory the executable is in shlibpath_var=PATH ;; darwin* | rhapsody*) dynamic_linker="$host_os dyld" version_type=darwin need_lib_prefix=no need_version=no library_names_spec='$libname$release$major$shared_ext $libname$shared_ext' soname_spec='$libname$release$major$shared_ext' shlibpath_overrides_runpath=yes shlibpath_var=DYLD_LIBRARY_PATH shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib" sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' ;; dgux*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH ;; freebsd* | dragonfly* | midnightbsd*) # DragonFly does not have aout. When/if they implement a new # versioning mechanism, adjust this. if test -x /usr/bin/objformat; then objformat=`/usr/bin/objformat` else case $host_os in freebsd[23].*) objformat=aout ;; *) objformat=elf ;; esac fi version_type=freebsd-$objformat case $version_type in freebsd-elf*) library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' need_version=no need_lib_prefix=no ;; freebsd-*) library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' need_version=yes ;; esac shlibpath_var=LD_LIBRARY_PATH case $host_os in freebsd2.*) shlibpath_overrides_runpath=yes ;; freebsd3.[01]* | freebsdelf3.[01]*) shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; *) # from 4.6 on, and DragonFly shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; esac ;; haiku*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no dynamic_linker="$host_os runtime_loader" library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LIBRARY_PATH shlibpath_overrides_runpath=no sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' hardcode_into_libs=yes ;; hpux9* | hpux10* | hpux11*) # Give a soname corresponding to the major version so that dld.sl refuses to # link against other versions. version_type=sunos need_lib_prefix=no need_version=no case $host_cpu in ia64*) shrext_cmds='.so' hardcode_into_libs=yes dynamic_linker="$host_os dld.so" shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' if test 32 = "$HPUX_IA64_MODE"; then sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" sys_lib_dlsearch_path_spec=/usr/lib/hpux32 else sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" sys_lib_dlsearch_path_spec=/usr/lib/hpux64 fi ;; hppa*64*) shrext_cmds='.sl' hardcode_into_libs=yes dynamic_linker="$host_os dld.sl" shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; *) shrext_cmds='.sl' dynamic_linker="$host_os dld.sl" shlibpath_var=SHLIB_PATH shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' ;; esac # HP-UX runs *really* slowly unless shared libraries are mode 555, ... postinstall_cmds='chmod 555 $lib' # or fails outright, so override atomically: install_override_mode=555 ;; interix[3-9]*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; irix5* | irix6* | nonstopux*) case $host_os in nonstopux*) version_type=nonstopux ;; *) if test yes = "$lt_cv_prog_gnu_ld"; then version_type=linux # correct to gnu/linux during the next big refactor else version_type=irix fi ;; esac need_lib_prefix=no need_version=no soname_spec='$libname$release$shared_ext$major' library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext' case $host_os in irix5* | nonstopux*) libsuff= shlibsuff= ;; *) case $LD in # libtool.m4 will add one of these switches to LD *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") libsuff= shlibsuff= libmagic=32-bit;; *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") libsuff=32 shlibsuff=N32 libmagic=N32;; *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") libsuff=64 shlibsuff=64 libmagic=64-bit;; *) libsuff= shlibsuff= libmagic=never-match;; esac ;; esac shlibpath_var=LD_LIBRARY${shlibsuff}_PATH shlibpath_overrides_runpath=no sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff" sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff" hardcode_into_libs=yes ;; # No shared lib support for Linux oldld, aout, or coff. linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; linux*android*) version_type=none # Android doesn't support versioned libraries. need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext' soname_spec='$libname$release$shared_ext' finish_cmds= shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes dynamic_linker='Android linker' # Don't embed -rpath directories since the linker doesn't support them. hardcode_libdir_flag_spec='-L$libdir' ;; # This must be glibc/ELF. linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no # Some binutils ld are patched to set DT_RUNPATH if test ${lt_cv_shlibpath_overrides_runpath+y} then : printf %s "(cached) " >&6 else $as_nop lt_cv_shlibpath_overrides_runpath=no save_LDFLAGS=$LDFLAGS save_libdir=$libdir eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \ LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\"" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null then : lt_cv_shlibpath_overrides_runpath=yes fi fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LDFLAGS=$save_LDFLAGS libdir=$save_libdir fi shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes # Ideally, we could use ldconfig to report *all* directores which are # searched for libraries, however this is still not possible. Aside from not # being certain /sbin/ldconfig is available, command # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64, # even though it is searched at run-time. Try to do the best guess by # appending ld.so.conf contents (and includes) to the search path. if test -f /etc/ld.so.conf; then lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on # powerpc, because MkLinux only supported shared libraries with the # GNU dynamic linker. Since this was broken with cross compilers, # most powerpc-linux boxes support dynamic linking these days and # people can always --disable-shared, the test was removed, and we # assume the GNU/Linux dynamic linker is in use. dynamic_linker='GNU/Linux ld.so' ;; netbsdelf*-gnu) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='NetBSD ld.elf_so' ;; netbsd*) version_type=sunos need_lib_prefix=no need_version=no if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' dynamic_linker='NetBSD (a.out) ld.so' else library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' dynamic_linker='NetBSD ld.elf_so' fi shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; newsos6) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; *nto* | *qnx*) version_type=qnx need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='ldqnx.so' ;; openbsd* | bitrig*) version_type=sunos sys_lib_dlsearch_path_spec=/usr/lib need_lib_prefix=no if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then need_version=no else need_version=yes fi library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; os2*) libname_spec='$name' version_type=windows shrext_cmds=.dll need_version=no need_lib_prefix=no # OS/2 can only load a DLL with a base name of 8 characters or less. soname_spec='`test -n "$os2dllname" && libname="$os2dllname"; v=$($ECHO $release$versuffix | tr -d .-); n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _); $ECHO $n$v`$shared_ext' library_names_spec='${libname}_dll.$libext' dynamic_linker='OS/2 ld.exe' shlibpath_var=BEGINLIBPATH sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname~ if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; fi' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' ;; osf3* | osf4* | osf5*) version_type=osf need_lib_prefix=no need_version=no soname_spec='$libname$release$shared_ext$major' library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; rdos*) dynamic_linker=no ;; solaris*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes # ldd complains unless libraries are executable postinstall_cmds='chmod +x $lib' ;; sunos4*) version_type=sunos library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes if test yes = "$with_gnu_ld"; then need_lib_prefix=no fi need_version=yes ;; sysv4 | sysv4.3*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH case $host_vendor in sni) shlibpath_overrides_runpath=no need_lib_prefix=no runpath_var=LD_RUN_PATH ;; siemens) need_lib_prefix=no ;; motorola) need_lib_prefix=no need_version=no shlibpath_overrides_runpath=no sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' ;; esac ;; sysv4*MP*) if test -d /usr/nec; then version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext' soname_spec='$libname$shared_ext.$major' shlibpath_var=LD_LIBRARY_PATH fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) version_type=sco need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes if test yes = "$with_gnu_ld"; then sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' else sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' case $host_os in sco3.2v5*) sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" ;; esac fi sys_lib_dlsearch_path_spec='/usr/lib' ;; tpf*) # TPF is a cross-target only. Preferred cross-host = GNU/Linux. version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; uts4*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH ;; *) dynamic_linker=no ;; esac { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 printf "%s\n" "$dynamic_linker" >&6; } test no = "$dynamic_linker" && can_build_shared=no variables_saved_for_relink="PATH $shlibpath_var $runpath_var" if test yes = "$GCC"; then variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" fi if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec fi if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec fi # remember unaugmented sys_lib_dlsearch_path content for libtool script decls... configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec # ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH" # to be used as default LT_SYS_LIBRARY_PATH value in generated libtool configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 printf %s "checking how to hardcode library paths into programs... " >&6; } hardcode_action= if test -n "$hardcode_libdir_flag_spec" || test -n "$runpath_var" || test yes = "$hardcode_automatic"; then # We can hardcode non-existent directories. if test no != "$hardcode_direct" && # If the only mechanism to avoid hardcoding is shlibpath_var, we # have to relink, otherwise we might link with an installed library # when we should be linking with a yet-to-be-installed one ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, )" && test no != "$hardcode_minus_L"; then # Linking always hardcodes the temporary library directory. hardcode_action=relink else # We can link without hardcoding, and we can hardcode nonexisting dirs. hardcode_action=immediate fi else # We cannot hardcode anything, or else we can only hardcode existing # directories. hardcode_action=unsupported fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5 printf "%s\n" "$hardcode_action" >&6; } if test relink = "$hardcode_action" || test yes = "$inherit_rpath"; then # Fast installation is not supported enable_fast_install=no elif test yes = "$shlibpath_overrides_runpath" || test no = "$enable_shared"; then # Fast installation is not necessary enable_fast_install=needless fi if test yes != "$enable_dlopen"; then enable_dlopen=unknown enable_dlopen_self=unknown enable_dlopen_self_static=unknown else lt_cv_dlopen=no lt_cv_dlopen_libs= case $host_os in beos*) lt_cv_dlopen=load_add_on lt_cv_dlopen_libs= lt_cv_dlopen_self=yes ;; mingw* | pw32* | cegcc*) lt_cv_dlopen=LoadLibrary lt_cv_dlopen_libs= ;; cygwin*) lt_cv_dlopen=dlopen lt_cv_dlopen_libs= ;; darwin*) # if libdl is installed we need to link against it { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 printf %s "checking for dlopen in -ldl... " >&6; } if test ${ac_cv_lib_dl_dlopen+y} then : printf %s "(cached) " >&6 else $as_nop ac_check_lib_save_LIBS=$LIBS LIBS="-ldl $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ char dlopen (); int main (void) { return dlopen (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : ac_cv_lib_dl_dlopen=yes else $as_nop ac_cv_lib_dl_dlopen=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 printf "%s\n" "$ac_cv_lib_dl_dlopen" >&6; } if test "x$ac_cv_lib_dl_dlopen" = xyes then : lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl else $as_nop lt_cv_dlopen=dyld lt_cv_dlopen_libs= lt_cv_dlopen_self=yes fi ;; tpf*) # Don't try to run any link tests for TPF. We know it's impossible # because TPF is a cross-compiler, and we know how we open DSOs. lt_cv_dlopen=dlopen lt_cv_dlopen_libs= lt_cv_dlopen_self=no ;; *) ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load" if test "x$ac_cv_func_shl_load" = xyes then : lt_cv_dlopen=shl_load else $as_nop { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 printf %s "checking for shl_load in -ldld... " >&6; } if test ${ac_cv_lib_dld_shl_load+y} then : printf %s "(cached) " >&6 else $as_nop ac_check_lib_save_LIBS=$LIBS LIBS="-ldld $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ char shl_load (); int main (void) { return shl_load (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : ac_cv_lib_dld_shl_load=yes else $as_nop ac_cv_lib_dld_shl_load=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 printf "%s\n" "$ac_cv_lib_dld_shl_load" >&6; } if test "x$ac_cv_lib_dld_shl_load" = xyes then : lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld else $as_nop ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" if test "x$ac_cv_func_dlopen" = xyes then : lt_cv_dlopen=dlopen else $as_nop { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 printf %s "checking for dlopen in -ldl... " >&6; } if test ${ac_cv_lib_dl_dlopen+y} then : printf %s "(cached) " >&6 else $as_nop ac_check_lib_save_LIBS=$LIBS LIBS="-ldl $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ char dlopen (); int main (void) { return dlopen (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : ac_cv_lib_dl_dlopen=yes else $as_nop ac_cv_lib_dl_dlopen=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 printf "%s\n" "$ac_cv_lib_dl_dlopen" >&6; } if test "x$ac_cv_lib_dl_dlopen" = xyes then : lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl else $as_nop { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 printf %s "checking for dlopen in -lsvld... " >&6; } if test ${ac_cv_lib_svld_dlopen+y} then : printf %s "(cached) " >&6 else $as_nop ac_check_lib_save_LIBS=$LIBS LIBS="-lsvld $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ char dlopen (); int main (void) { return dlopen (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : ac_cv_lib_svld_dlopen=yes else $as_nop ac_cv_lib_svld_dlopen=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 printf "%s\n" "$ac_cv_lib_svld_dlopen" >&6; } if test "x$ac_cv_lib_svld_dlopen" = xyes then : lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld else $as_nop { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 printf %s "checking for dld_link in -ldld... " >&6; } if test ${ac_cv_lib_dld_dld_link+y} then : printf %s "(cached) " >&6 else $as_nop ac_check_lib_save_LIBS=$LIBS LIBS="-ldld $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ char dld_link (); int main (void) { return dld_link (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : ac_cv_lib_dld_dld_link=yes else $as_nop ac_cv_lib_dld_dld_link=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5 printf "%s\n" "$ac_cv_lib_dld_dld_link" >&6; } if test "x$ac_cv_lib_dld_dld_link" = xyes then : lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld fi fi fi fi fi fi ;; esac if test no = "$lt_cv_dlopen"; then enable_dlopen=no else enable_dlopen=yes fi case $lt_cv_dlopen in dlopen) save_CPPFLAGS=$CPPFLAGS test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" save_LDFLAGS=$LDFLAGS wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" save_LIBS=$LIBS LIBS="$lt_cv_dlopen_libs $LIBS" { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 printf %s "checking whether a program can dlopen itself... " >&6; } if test ${lt_cv_dlopen_self+y} then : printf %s "(cached) " >&6 else $as_nop if test yes = "$cross_compiling"; then : lt_cv_dlopen_self=cross else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF #line $LINENO "configure" #include "confdefs.h" #if HAVE_DLFCN_H #include #endif #include #ifdef RTLD_GLOBAL # define LT_DLGLOBAL RTLD_GLOBAL #else # ifdef DL_GLOBAL # define LT_DLGLOBAL DL_GLOBAL # else # define LT_DLGLOBAL 0 # endif #endif /* We may have to define LT_DLLAZY_OR_NOW in the command line if we find out it does not work in some platform. */ #ifndef LT_DLLAZY_OR_NOW # ifdef RTLD_LAZY # define LT_DLLAZY_OR_NOW RTLD_LAZY # else # ifdef DL_LAZY # define LT_DLLAZY_OR_NOW DL_LAZY # else # ifdef RTLD_NOW # define LT_DLLAZY_OR_NOW RTLD_NOW # else # ifdef DL_NOW # define LT_DLLAZY_OR_NOW DL_NOW # else # define LT_DLLAZY_OR_NOW 0 # endif # endif # endif # endif #endif /* When -fvisibility=hidden is used, assume the code has been annotated correspondingly for the symbols needed. */ #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) int fnord () __attribute__((visibility("default"))); #endif int fnord () { return 42; } int main () { void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); int status = $lt_dlunknown; if (self) { if (dlsym (self,"fnord")) status = $lt_dlno_uscore; else { if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; else puts (dlerror ()); } /* dlclose (self); */ } else puts (dlerror ()); return status; } _LT_EOF if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 (eval $ac_link) 2>&5 ac_status=$? printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then (./conftest; exit; ) >&5 2>/dev/null lt_status=$? case x$lt_status in x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;; esac else : # compilation failed lt_cv_dlopen_self=no fi fi rm -fr conftest* fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5 printf "%s\n" "$lt_cv_dlopen_self" >&6; } if test yes = "$lt_cv_dlopen_self"; then wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5 printf %s "checking whether a statically linked program can dlopen itself... " >&6; } if test ${lt_cv_dlopen_self_static+y} then : printf %s "(cached) " >&6 else $as_nop if test yes = "$cross_compiling"; then : lt_cv_dlopen_self_static=cross else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF #line $LINENO "configure" #include "confdefs.h" #if HAVE_DLFCN_H #include #endif #include #ifdef RTLD_GLOBAL # define LT_DLGLOBAL RTLD_GLOBAL #else # ifdef DL_GLOBAL # define LT_DLGLOBAL DL_GLOBAL # else # define LT_DLGLOBAL 0 # endif #endif /* We may have to define LT_DLLAZY_OR_NOW in the command line if we find out it does not work in some platform. */ #ifndef LT_DLLAZY_OR_NOW # ifdef RTLD_LAZY # define LT_DLLAZY_OR_NOW RTLD_LAZY # else # ifdef DL_LAZY # define LT_DLLAZY_OR_NOW DL_LAZY # else # ifdef RTLD_NOW # define LT_DLLAZY_OR_NOW RTLD_NOW # else # ifdef DL_NOW # define LT_DLLAZY_OR_NOW DL_NOW # else # define LT_DLLAZY_OR_NOW 0 # endif # endif # endif # endif #endif /* When -fvisibility=hidden is used, assume the code has been annotated correspondingly for the symbols needed. */ #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) int fnord () __attribute__((visibility("default"))); #endif int fnord () { return 42; } int main () { void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); int status = $lt_dlunknown; if (self) { if (dlsym (self,"fnord")) status = $lt_dlno_uscore; else { if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; else puts (dlerror ()); } /* dlclose (self); */ } else puts (dlerror ()); return status; } _LT_EOF if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 (eval $ac_link) 2>&5 ac_status=$? printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then (./conftest; exit; ) >&5 2>/dev/null lt_status=$? case x$lt_status in x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;; esac else : # compilation failed lt_cv_dlopen_self_static=no fi fi rm -fr conftest* fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5 printf "%s\n" "$lt_cv_dlopen_self_static" >&6; } fi CPPFLAGS=$save_CPPFLAGS LDFLAGS=$save_LDFLAGS LIBS=$save_LIBS ;; esac case $lt_cv_dlopen_self in yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; *) enable_dlopen_self=unknown ;; esac case $lt_cv_dlopen_self_static in yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; *) enable_dlopen_self_static=unknown ;; esac fi striplib= old_striplib= { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 printf %s "checking whether stripping libraries is possible... " >&6; } if test -z "$STRIP"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } else if $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then old_striplib="$STRIP --strip-debug" striplib="$STRIP --strip-unneeded" { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 printf "%s\n" "yes" >&6; } else case $host_os in darwin*) # FIXME - insert some real tests, host_os isn't really good enough striplib="$STRIP -x" old_striplib="$STRIP -S" { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 printf "%s\n" "yes" >&6; } ;; freebsd*) if $STRIP -V 2>&1 | $GREP "elftoolchain" >/dev/null; then old_striplib="$STRIP --strip-debug" striplib="$STRIP --strip-unneeded" { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 printf "%s\n" "yes" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi ;; *) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } ;; esac fi fi # Report what library types will actually be built { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5 printf %s "checking if libtool supports shared libraries... " >&6; } { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5 printf "%s\n" "$can_build_shared" >&6; } { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5 printf %s "checking whether to build shared libraries... " >&6; } test no = "$can_build_shared" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) test yes = "$enable_shared" && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[4-9]*) if test ia64 != "$host_cpu"; then case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in yes,aix,yes) ;; # shared object as lib.so file only yes,svr4,*) ;; # shared object as lib.so archive member only yes,*) enable_static=no ;; # shared object in lib.a archive as well esac fi ;; esac { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 printf "%s\n" "$enable_shared" >&6; } { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5 printf %s "checking whether to build static libraries... " >&6; } # Make sure either enable_shared or enable_static is yes. test yes = "$enable_shared" || enable_static=yes { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5 printf "%s\n" "$enable_static" >&6; } fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu CC=$lt_save_CC ac_config_commands="$ac_config_commands libtool" # Only expand once: { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 printf %s "checking whether ln -s works... " >&6; } LN_S=$as_ln_s if test "$LN_S" = "ln -s"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 printf "%s\n" "yes" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 printf "%s\n" "no, using $LN_S" >&6; } fi # Export LD_LIBRARY_PATH name or equivalent. SHLIBPATH_VAR=$shlibpath_var # Export .libs or equivalent. LT_CV_OBJDIR=$lt_cv_objdir # Export version info ### Default CFLAGS DEFAULT_CFLAGS="-Wall -Wformat -Wformat-security \ -Wmultichar -Wwrite-strings -Wcast-qual -Wcast-align \ -Wstrict-prototypes -Wmissing-prototypes \ -Wmissing-declarations -Wdeclaration-after-statement \ -Wpointer-arith -Wsequence-point -Wnested-externs \ -D_REENTRANT" DEFAULT_LDFLAGS="" ### Additional flags (if supported) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -Wparentheses" >&5 printf %s "checking whether C compiler accepts -Wparentheses... " >&6; } if test ${ax_cv_check_cflags___Wparentheses+y} then : printf %s "(cached) " >&6 else $as_nop ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -Wparentheses" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ax_cv_check_cflags___Wparentheses=yes else $as_nop ax_cv_check_cflags___Wparentheses=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext CFLAGS=$ax_check_save_flags fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___Wparentheses" >&5 printf "%s\n" "$ax_cv_check_cflags___Wparentheses" >&6; } if test "x$ax_cv_check_cflags___Wparentheses" = xyes then : DEFAULT_CFLAGS="$DEFAULT_CFLAGS -Wparentheses" else $as_nop : fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -Winit-self" >&5 printf %s "checking whether C compiler accepts -Winit-self... " >&6; } if test ${ax_cv_check_cflags___Winit_self+y} then : printf %s "(cached) " >&6 else $as_nop ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -Winit-self" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ax_cv_check_cflags___Winit_self=yes else $as_nop ax_cv_check_cflags___Winit_self=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext CFLAGS=$ax_check_save_flags fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___Winit_self" >&5 printf "%s\n" "$ax_cv_check_cflags___Winit_self" >&6; } if test "x$ax_cv_check_cflags___Winit_self" = xyes then : DEFAULT_CFLAGS="$DEFAULT_CFLAGS -Winit-self" else $as_nop : fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -Wunused-but-set-parameter" >&5 printf %s "checking whether C compiler accepts -Wunused-but-set-parameter... " >&6; } if test ${ax_cv_check_cflags___Wunused_but_set_parameter+y} then : printf %s "(cached) " >&6 else $as_nop ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -Wunused-but-set-parameter" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ax_cv_check_cflags___Wunused_but_set_parameter=yes else $as_nop ax_cv_check_cflags___Wunused_but_set_parameter=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext CFLAGS=$ax_check_save_flags fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___Wunused_but_set_parameter" >&5 printf "%s\n" "$ax_cv_check_cflags___Wunused_but_set_parameter" >&6; } if test "x$ax_cv_check_cflags___Wunused_but_set_parameter" = xyes then : DEFAULT_CFLAGS="$DEFAULT_CFLAGS -Wunused-but-set-parameter" else $as_nop : fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -Waddress" >&5 printf %s "checking whether C compiler accepts -Waddress... " >&6; } if test ${ax_cv_check_cflags___Waddress+y} then : printf %s "(cached) " >&6 else $as_nop ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -Waddress" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ax_cv_check_cflags___Waddress=yes else $as_nop ax_cv_check_cflags___Waddress=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext CFLAGS=$ax_check_save_flags fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___Waddress" >&5 printf "%s\n" "$ax_cv_check_cflags___Waddress" >&6; } if test "x$ax_cv_check_cflags___Waddress" = xyes then : DEFAULT_CFLAGS="$DEFAULT_CFLAGS -Waddress" else $as_nop : fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -Wuninitialized" >&5 printf %s "checking whether C compiler accepts -Wuninitialized... " >&6; } if test ${ax_cv_check_cflags___Wuninitialized+y} then : printf %s "(cached) " >&6 else $as_nop ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -Wuninitialized" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ax_cv_check_cflags___Wuninitialized=yes else $as_nop ax_cv_check_cflags___Wuninitialized=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext CFLAGS=$ax_check_save_flags fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___Wuninitialized" >&5 printf "%s\n" "$ax_cv_check_cflags___Wuninitialized" >&6; } if test "x$ax_cv_check_cflags___Wuninitialized" = xyes then : DEFAULT_CFLAGS="$DEFAULT_CFLAGS -Wuninitialized" else $as_nop : fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -Wformat=2" >&5 printf %s "checking whether C compiler accepts -Wformat=2... " >&6; } if test ${ax_cv_check_cflags___Wformat_2+y} then : printf %s "(cached) " >&6 else $as_nop ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -Wformat=2" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ax_cv_check_cflags___Wformat_2=yes else $as_nop ax_cv_check_cflags___Wformat_2=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext CFLAGS=$ax_check_save_flags fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___Wformat_2" >&5 printf "%s\n" "$ax_cv_check_cflags___Wformat_2" >&6; } if test "x$ax_cv_check_cflags___Wformat_2" = xyes then : DEFAULT_CFLAGS="$DEFAULT_CFLAGS -Wformat=2" else $as_nop : fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -Wformat-nonliteral" >&5 printf %s "checking whether C compiler accepts -Wformat-nonliteral... " >&6; } if test ${ax_cv_check_cflags___Wformat_nonliteral+y} then : printf %s "(cached) " >&6 else $as_nop ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -Wformat-nonliteral" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ax_cv_check_cflags___Wformat_nonliteral=yes else $as_nop ax_cv_check_cflags___Wformat_nonliteral=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext CFLAGS=$ax_check_save_flags fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___Wformat_nonliteral" >&5 printf "%s\n" "$ax_cv_check_cflags___Wformat_nonliteral" >&6; } if test "x$ax_cv_check_cflags___Wformat_nonliteral" = xyes then : DEFAULT_CFLAGS="$DEFAULT_CFLAGS -Wformat-nonliteral" else $as_nop : fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -Wmissing-parameter-type" >&5 printf %s "checking whether C compiler accepts -Wmissing-parameter-type... " >&6; } if test ${ax_cv_check_cflags___Wmissing_parameter_type+y} then : printf %s "(cached) " >&6 else $as_nop ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -Wmissing-parameter-type" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ax_cv_check_cflags___Wmissing_parameter_type=yes else $as_nop ax_cv_check_cflags___Wmissing_parameter_type=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext CFLAGS=$ax_check_save_flags fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___Wmissing_parameter_type" >&5 printf "%s\n" "$ax_cv_check_cflags___Wmissing_parameter_type" >&6; } if test "x$ax_cv_check_cflags___Wmissing_parameter_type" = xyes then : DEFAULT_CFLAGS="$DEFAULT_CFLAGS -Wmissing-parameter-type" else $as_nop : fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -Wold-style-definition" >&5 printf %s "checking whether C compiler accepts -Wold-style-definition... " >&6; } if test ${ax_cv_check_cflags___Wold_style_definition+y} then : printf %s "(cached) " >&6 else $as_nop ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -Wold-style-definition" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ax_cv_check_cflags___Wold_style_definition=yes else $as_nop ax_cv_check_cflags___Wold_style_definition=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext CFLAGS=$ax_check_save_flags fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___Wold_style_definition" >&5 printf "%s\n" "$ax_cv_check_cflags___Wold_style_definition" >&6; } if test "x$ax_cv_check_cflags___Wold_style_definition" = xyes then : DEFAULT_CFLAGS="$DEFAULT_CFLAGS -Wold-style-definition" else $as_nop : fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -Wignored-qualifiers" >&5 printf %s "checking whether C compiler accepts -Wignored-qualifiers... " >&6; } if test ${ax_cv_check_cflags___Wignored_qualifiers+y} then : printf %s "(cached) " >&6 else $as_nop ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -Wignored-qualifiers" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ax_cv_check_cflags___Wignored_qualifiers=yes else $as_nop ax_cv_check_cflags___Wignored_qualifiers=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext CFLAGS=$ax_check_save_flags fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___Wignored_qualifiers" >&5 printf "%s\n" "$ax_cv_check_cflags___Wignored_qualifiers" >&6; } if test "x$ax_cv_check_cflags___Wignored_qualifiers" = xyes then : DEFAULT_CFLAGS="$DEFAULT_CFLAGS -Wignored-qualifiers" else $as_nop : fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fstrict-aliasing -Wstrict-aliasing" >&5 printf %s "checking whether C compiler accepts -fstrict-aliasing -Wstrict-aliasing... " >&6; } if test ${ax_cv_check_cflags___fstrict_aliasing__Wstrict_aliasing+y} then : printf %s "(cached) " >&6 else $as_nop ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -fstrict-aliasing -Wstrict-aliasing" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ax_cv_check_cflags___fstrict_aliasing__Wstrict_aliasing=yes else $as_nop ax_cv_check_cflags___fstrict_aliasing__Wstrict_aliasing=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext CFLAGS=$ax_check_save_flags fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fstrict_aliasing__Wstrict_aliasing" >&5 printf "%s\n" "$ax_cv_check_cflags___fstrict_aliasing__Wstrict_aliasing" >&6; } if test "x$ax_cv_check_cflags___fstrict_aliasing__Wstrict_aliasing" = xyes then : DEFAULT_CFLAGS="$DEFAULT_CFLAGS -fstrict-aliasing -Wstrict-aliasing" else $as_nop : fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fstack-protector" >&5 printf %s "checking whether C compiler accepts -fstack-protector... " >&6; } if test ${ax_cv_check_cflags___fstack_protector+y} then : printf %s "(cached) " >&6 else $as_nop ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -fstack-protector" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ax_cv_check_cflags___fstack_protector=yes else $as_nop ax_cv_check_cflags___fstack_protector=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext CFLAGS=$ax_check_save_flags fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fstack_protector" >&5 printf "%s\n" "$ax_cv_check_cflags___fstack_protector" >&6; } if test "x$ax_cv_check_cflags___fstack_protector" = xyes then : DEFAULT_CFLAGS="$DEFAULT_CFLAGS -fstack-protector" else $as_nop : fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fstack-clash-protection" >&5 printf %s "checking whether C compiler accepts -fstack-clash-protection... " >&6; } if test ${ax_cv_check_cflags___fstack_clash_protection+y} then : printf %s "(cached) " >&6 else $as_nop ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -fstack-clash-protection" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ax_cv_check_cflags___fstack_clash_protection=yes else $as_nop ax_cv_check_cflags___fstack_clash_protection=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext CFLAGS=$ax_check_save_flags fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fstack_clash_protection" >&5 printf "%s\n" "$ax_cv_check_cflags___fstack_clash_protection" >&6; } if test "x$ax_cv_check_cflags___fstack_clash_protection" = xyes then : DEFAULT_CFLAGS="$DEFAULT_CFLAGS -fstack-clash-protection" else $as_nop : fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fcf-protection" >&5 printf %s "checking whether C compiler accepts -fcf-protection... " >&6; } if test ${ax_cv_check_cflags___fcf_protection+y} then : printf %s "(cached) " >&6 else $as_nop ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -fcf-protection" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ax_cv_check_cflags___fcf_protection=yes else $as_nop ax_cv_check_cflags___fcf_protection=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext CFLAGS=$ax_check_save_flags fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fcf_protection" >&5 printf "%s\n" "$ax_cv_check_cflags___fcf_protection" >&6; } if test "x$ax_cv_check_cflags___fcf_protection" = xyes then : DEFAULT_CFLAGS="$DEFAULT_CFLAGS -fcf-protection" else $as_nop : fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the linker accepts -Wl,--discard-all" >&5 printf %s "checking whether the linker accepts -Wl,--discard-all... " >&6; } if test ${ax_cv_check_ldflags___Wl___discard_all+y} then : printf %s "(cached) " >&6 else $as_nop ax_check_save_flags=$LDFLAGS LDFLAGS="$LDFLAGS -Wl,--discard-all" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : ax_cv_check_ldflags___Wl___discard_all=yes else $as_nop ax_cv_check_ldflags___Wl___discard_all=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LDFLAGS=$ax_check_save_flags fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_ldflags___Wl___discard_all" >&5 printf "%s\n" "$ax_cv_check_ldflags___Wl___discard_all" >&6; } if test "x$ax_cv_check_ldflags___Wl___discard_all" = xyes then : DEFAULT_LDFLAGS="$DEFAULT_LDFLAGS -Wl,--discard-all" else $as_nop : fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the linker accepts -Wl,--no-undefined" >&5 printf %s "checking whether the linker accepts -Wl,--no-undefined... " >&6; } if test ${ax_cv_check_ldflags___Wl___no_undefined+y} then : printf %s "(cached) " >&6 else $as_nop ax_check_save_flags=$LDFLAGS LDFLAGS="$LDFLAGS -Wl,--no-undefined" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : ax_cv_check_ldflags___Wl___no_undefined=yes else $as_nop ax_cv_check_ldflags___Wl___no_undefined=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LDFLAGS=$ax_check_save_flags fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_ldflags___Wl___no_undefined" >&5 printf "%s\n" "$ax_cv_check_ldflags___Wl___no_undefined" >&6; } if test "x$ax_cv_check_ldflags___Wl___no_undefined" = xyes then : DEFAULT_LDFLAGS="$DEFAULT_LDFLAGS -Wl,--no-undefined" else $as_nop : fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the linker accepts -Wl,-z,relro,-z,now" >&5 printf %s "checking whether the linker accepts -Wl,-z,relro,-z,now... " >&6; } if test ${ax_cv_check_ldflags___Wl__z_relro__z_now+y} then : printf %s "(cached) " >&6 else $as_nop ax_check_save_flags=$LDFLAGS LDFLAGS="$LDFLAGS -Wl,-z,relro,-z,now" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : ax_cv_check_ldflags___Wl__z_relro__z_now=yes else $as_nop ax_cv_check_ldflags___Wl__z_relro__z_now=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LDFLAGS=$ax_check_save_flags fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_ldflags___Wl__z_relro__z_now" >&5 printf "%s\n" "$ax_cv_check_ldflags___Wl__z_relro__z_now" >&6; } if test "x$ax_cv_check_ldflags___Wl__z_relro__z_now" = xyes then : DEFAULT_LDFLAGS="$DEFAULT_LDFLAGS -Wl,-z,relro,-z,now" else $as_nop : fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the linker accepts -Wl,-z,noexecstack" >&5 printf %s "checking whether the linker accepts -Wl,-z,noexecstack... " >&6; } if test ${ax_cv_check_ldflags___Wl__z_noexecstack+y} then : printf %s "(cached) " >&6 else $as_nop ax_check_save_flags=$LDFLAGS LDFLAGS="$LDFLAGS -Wl,-z,noexecstack" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : ax_cv_check_ldflags___Wl__z_noexecstack=yes else $as_nop ax_cv_check_ldflags___Wl__z_noexecstack=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LDFLAGS=$ax_check_save_flags fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_ldflags___Wl__z_noexecstack" >&5 printf "%s\n" "$ax_cv_check_ldflags___Wl__z_noexecstack" >&6; } if test "x$ax_cv_check_ldflags___Wl__z_noexecstack" = xyes then : DEFAULT_LDFLAGS="$DEFAULT_LDFLAGS -Wl,-z,noexecstack" else $as_nop : fi ### PIE CFLAGS_PIE="" LDFLAGS_PIE="" { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fpie -pie" >&5 printf %s "checking whether C compiler accepts -fpie -pie... " >&6; } if test ${ax_cv_check_cflags___fpie__pie+y} then : printf %s "(cached) " >&6 else $as_nop ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -fpie -pie" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ax_cv_check_cflags___fpie__pie=yes else $as_nop ax_cv_check_cflags___fpie__pie=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext CFLAGS=$ax_check_save_flags fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fpie__pie" >&5 printf "%s\n" "$ax_cv_check_cflags___fpie__pie" >&6; } if test "x$ax_cv_check_cflags___fpie__pie" = xyes then : CFLAGS_PIE="-fpie -pie" else $as_nop : fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the linker accepts -pie" >&5 printf %s "checking whether the linker accepts -pie... " >&6; } if test ${ax_cv_check_ldflags___pie+y} then : printf %s "(cached) " >&6 else $as_nop ax_check_save_flags=$LDFLAGS LDFLAGS="$LDFLAGS -pie" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : ax_cv_check_ldflags___pie=yes else $as_nop ax_cv_check_ldflags___pie=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LDFLAGS=$ax_check_save_flags fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_ldflags___pie" >&5 printf "%s\n" "$ax_cv_check_ldflags___pie" >&6; } if test "x$ax_cv_check_ldflags___pie" = xyes then : LDFLAGS_PIE="-pie" else $as_nop : fi ## Export all symbols for backtraces { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -rdynamic" >&5 printf %s "checking whether C compiler accepts -rdynamic... " >&6; } if test ${ax_cv_check_cflags___rdynamic+y} then : printf %s "(cached) " >&6 else $as_nop ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -rdynamic" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : ax_cv_check_cflags___rdynamic=yes else $as_nop ax_cv_check_cflags___rdynamic=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext CFLAGS=$ax_check_save_flags fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___rdynamic" >&5 printf "%s\n" "$ax_cv_check_cflags___rdynamic" >&6; } if test "x$ax_cv_check_cflags___rdynamic" = xyes then : DEFAULT_CFLAGS="$DEFAULT_CFLAGS -rdynamic" else $as_nop : fi ### Check for -fvisibility=hidden support CFLAG_VISIBILITY= HAVE_VISIBILITY=0 if test -n "$GCC"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the -Werror option is usable" >&5 printf %s "checking whether the -Werror option is usable... " >&6; } if test ${gl_cv_cc_vis_werror+y} then : printf %s "(cached) " >&6 else $as_nop gl_save_CFLAGS="$CFLAGS" CFLAGS="$CFLAGS -Werror" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : gl_cv_cc_vis_werror=yes else $as_nop gl_cv_cc_vis_werror=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext CFLAGS="$gl_save_CFLAGS" fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_vis_werror" >&5 printf "%s\n" "$gl_cv_cc_vis_werror" >&6; } { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for simple visibility declarations" >&5 printf %s "checking for simple visibility declarations... " >&6; } if test ${gl_cv_cc_visibility+y} then : printf %s "(cached) " >&6 else $as_nop gl_save_CFLAGS="$CFLAGS" CFLAGS="$CFLAGS -fvisibility=hidden" if test $gl_cv_cc_vis_werror = yes; then CFLAGS="$CFLAGS -Werror" fi cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ extern __attribute__((__visibility__("hidden"))) int hiddenvar; extern __attribute__((__visibility__("default"))) int exportedvar; extern __attribute__((__visibility__("hidden"))) int hiddenfunc (void); extern __attribute__((__visibility__("default"))) int exportedfunc (void); void dummyfunc (void); int hiddenvar; int exportedvar; int hiddenfunc (void) { return 51; } int exportedfunc (void) { return 1225736919; } void dummyfunc (void) {} int main (void) { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO" then : gl_cv_cc_visibility=yes else $as_nop gl_cv_cc_visibility=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext CFLAGS="$gl_save_CFLAGS" fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_visibility" >&5 printf "%s\n" "$gl_cv_cc_visibility" >&6; } if test $gl_cv_cc_visibility = yes; then CFLAG_VISIBILITY="-fvisibility=hidden" HAVE_VISIBILITY=1 fi fi printf "%s\n" "#define HAVE_VISIBILITY $HAVE_VISIBILITY" >>confdefs.h AM_CFLAGS="$AM_CFLAGS $CFLAG_VISIBILITY" ### Check for platform #case $host in #AIX) AC_DEFINE(HTS_PLATFORM, 1, [Defined to build under AIX]);; #*-solaris*) AC_DEFINE(HTS_PLATFORM, 2, [Defined to build under solaris]);; #*-linux-gnu | *-irix6*) AC_DEFINE(HTS_PLATFORM, 3, [Defined to build under Linux]);; #*) AC_DEFINE(HTS_PLATFORM, 3, [Default value used]);; #esac ### Check size of long and long long. # The cast to long int works around a bug in the HP C Compiler # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. # This bug is HP SR number 8606223364. { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 printf %s "checking size of long... " >&6; } if test ${ac_cv_sizeof_long+y} then : printf %s "(cached) " >&6 else $as_nop if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default" then : else $as_nop if test "$ac_cv_type_long" = yes; then { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error 77 "cannot compute sizeof (long) See \`config.log' for more details" "$LINENO" 5; } else ac_cv_sizeof_long=0 fi fi fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 printf "%s\n" "$ac_cv_sizeof_long" >&6; } printf "%s\n" "#define SIZEOF_LONG $ac_cv_sizeof_long" >>confdefs.h # The cast to long int works around a bug in the HP C Compiler # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. # This bug is HP SR number 8606223364. { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5 printf %s "checking size of long long... " >&6; } if test ${ac_cv_sizeof_long_long+y} then : printf %s "(cached) " >&6 else $as_nop if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default" then : else $as_nop if test "$ac_cv_type_long_long" = yes; then { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error 77 "cannot compute sizeof (long long) See \`config.log' for more details" "$LINENO" 5; } else ac_cv_sizeof_long_long=0 fi fi fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5 printf "%s\n" "$ac_cv_sizeof_long_long" >&6; } printf "%s\n" "#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long" >>confdefs.h ### check for in_addr_t ac_fn_c_check_type "$LINENO" "in_addr_t" "ac_cv_type_in_addr_t" "#include #include #include " if test "x$ac_cv_type_in_addr_t" = xyes then : printf "%s\n" "#define HTS_DO_NOT_REDEFINE_in_addr_t /**/" >>confdefs.h else $as_nop { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: *** in_addr_t not found" >&5 printf "%s\n" "$as_me: WARNING: *** in_addr_t not found" >&2;} fi # check for in_port_ ac_fn_c_check_type "$LINENO" "in_port_t" "ac_cv_type_in_port_t" " #include #include " if test "x$ac_cv_type_in_port_t" = xyes then : else $as_nop printf "%s\n" "#define in_port_t uint16_t" >>confdefs.h fi # check for sa_family_t ac_fn_c_check_type "$LINENO" "sa_family_t" "ac_cv_type_sa_family_t" " #include #include " if test "x$ac_cv_type_sa_family_t" = xyes then : else $as_nop printf "%s\n" "#define sa_family_t uint16_t" >>confdefs.h fi # check wether misaligned access is possible or not { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if pointers to integers require aligned access" >&5 printf %s "checking if pointers to integers require aligned access... " >&6; } if test ${ax_cv_have_aligned_access_required+y} then : printf %s "(cached) " >&6 else $as_nop if test "$cross_compiling" = yes then : ax_cv_have_aligned_access_required=maybe else $as_nop cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main (void) { int i; int *p; int *q; char *str; str = (char *) malloc(40); for (i = 0; i < 40; i++) { *(str + i) = i; } p = (int *) (str + 1); q = (int *) (str + 2); return (*p == *q); ; return 0; } _ACEOF if ac_fn_c_try_run "$LINENO" then : ax_cv_have_aligned_access_required=no else $as_nop ax_cv_have_aligned_access_required=yes fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_have_aligned_access_required" >&5 printf "%s\n" "$ax_cv_have_aligned_access_required" >&6; } if test "x$ax_cv_have_aligned_access_required" = "xmaybe"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Assuming aligned access is required when cross-compiling" >&5 printf "%s\n" "$as_me: WARNING: Assuming aligned access is required when cross-compiling" >&2;} ax_cv_have_aligned_access_required=yes fi if test "x$ax_cv_have_aligned_access_required" = "xyes"; then printf "%s\n" "#define HAVE_ALIGNED_ACCESS_REQUIRED 1" >>confdefs.h fi # check for various headers ac_fn_c_check_header_compile "$LINENO" "execinfo.h" "ac_cv_header_execinfo_h" "$ac_includes_default" if test "x$ac_cv_header_execinfo_h" = xyes then : printf "%s\n" "#define HAVE_EXECINFO_H 1" >>confdefs.h fi ### zlib # # Handle user hints # { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if zlib is wanted" >&5 printf %s "checking if zlib is wanted... " >&6; } # Check whether --with-zlib was given. if test ${with_zlib+y} then : withval=$with_zlib; if test "$withval" != no ; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 printf "%s\n" "yes" >&6; } ZLIB_HOME="$withval" else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi else $as_nop { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 printf "%s\n" "yes" >&6; } ZLIB_HOME=/usr/local if test ! -f "${ZLIB_HOME}/include/zlib.h" then ZLIB_HOME=/usr fi fi # # Locate zlib, if wanted # if test -n "${ZLIB_HOME}" then ZLIB_OLD_LDFLAGS=$LDFLAGS ZLIB_OLD_CPPFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS -L${ZLIB_HOME}/lib" CPPFLAGS="$CPPFLAGS -I${ZLIB_HOME}/include" ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inflateEnd in -lz" >&5 printf %s "checking for inflateEnd in -lz... " >&6; } if test ${ac_cv_lib_z_inflateEnd+y} then : printf %s "(cached) " >&6 else $as_nop ac_check_lib_save_LIBS=$LIBS LIBS="-lz $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ char inflateEnd (); int main (void) { return inflateEnd (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : ac_cv_lib_z_inflateEnd=yes else $as_nop ac_cv_lib_z_inflateEnd=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_inflateEnd" >&5 printf "%s\n" "$ac_cv_lib_z_inflateEnd" >&6; } if test "x$ac_cv_lib_z_inflateEnd" = xyes then : zlib_cv_libz=yes else $as_nop zlib_cv_libz=no fi ac_fn_c_check_header_compile "$LINENO" "zlib.h" "ac_cv_header_zlib_h" "$ac_includes_default" if test "x$ac_cv_header_zlib_h" = xyes then : zlib_cv_zlib_h=yes else $as_nop zlib_cv_zlib_h=no fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu if test "$zlib_cv_libz" = "yes" -a "$zlib_cv_zlib_h" = "yes" then # # If both library and header were found, use them # { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inflateEnd in -lz" >&5 printf %s "checking for inflateEnd in -lz... " >&6; } if test ${ac_cv_lib_z_inflateEnd+y} then : printf %s "(cached) " >&6 else $as_nop ac_check_lib_save_LIBS=$LIBS LIBS="-lz $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ char inflateEnd (); int main (void) { return inflateEnd (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : ac_cv_lib_z_inflateEnd=yes else $as_nop ac_cv_lib_z_inflateEnd=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_inflateEnd" >&5 printf "%s\n" "$ac_cv_lib_z_inflateEnd" >&6; } if test "x$ac_cv_lib_z_inflateEnd" = xyes then : printf "%s\n" "#define HAVE_LIBZ 1" >>confdefs.h LIBS="-lz $LIBS" fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking zlib in ${ZLIB_HOME}" >&5 printf %s "checking zlib in ${ZLIB_HOME}... " >&6; } { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ok" >&5 printf "%s\n" "ok" >&6; } else # # If either header or library was not found, revert and bomb # { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking zlib in ${ZLIB_HOME}" >&5 printf %s "checking zlib in ${ZLIB_HOME}... " >&6; } LDFLAGS="$ZLIB_OLD_LDFLAGS" CPPFLAGS="$ZLIB_OLD_CPPFLAGS" { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: failed" >&5 printf "%s\n" "failed" >&6; } as_fn_error $? "either specify a valid zlib installation with --with-zlib=DIR or disable zlib usage with --without-zlib" "$LINENO" 5 fi fi ### OpenSSL is explicitly enabled/disabled ? { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable https support" >&5 printf %s "checking whether to enable https support... " >&6; } # Check whether --enable-https was given. if test ${enable_https+y} then : enableval=$enable_https; case "${enableval}" in no|yes|auto) https_support=$enableval { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $https_support" >&5 printf "%s\n" "$https_support" >&6; } ;; *) as_fn_error expected yes/no/auto "bad value for https" "$LINENO" 5 ;; esac else $as_nop https_support=yes { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $https_support" >&5 printf "%s\n" "$https_support" >&6; } fi HTTPS_SUPPORT=$https_support # Probe OpenSSL ? if test x"$https_support" = x"no"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: disabling https support" >&5 printf "%s\n" "$as_me: disabling https support" >&6;} printf "%s\n" "#define HTS_USEOPENSSL 0" >>confdefs.h else SAVE_LIBS=$LIBS { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for EVP_get_digestbyname in -lcrypto" >&5 printf %s "checking for EVP_get_digestbyname in -lcrypto... " >&6; } if test ${ac_cv_lib_crypto_EVP_get_digestbyname+y} then : printf %s "(cached) " >&6 else $as_nop ac_check_lib_save_LIBS=$LIBS LIBS="-lcrypto $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ char EVP_get_digestbyname (); int main (void) { return EVP_get_digestbyname (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : ac_cv_lib_crypto_EVP_get_digestbyname=yes else $as_nop ac_cv_lib_crypto_EVP_get_digestbyname=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_EVP_get_digestbyname" >&5 printf "%s\n" "$ac_cv_lib_crypto_EVP_get_digestbyname" >&6; } if test "x$ac_cv_lib_crypto_EVP_get_digestbyname" = xyes then : OPENSSL_LIBS="-lcrypto" fi LIBS="$LIBS $OPENSSL_LIBS" { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for SSL_CTX_new in -lssl" >&5 printf %s "checking for SSL_CTX_new in -lssl... " >&6; } if test ${ac_cv_lib_ssl_SSL_CTX_new+y} then : printf %s "(cached) " >&6 else $as_nop ac_check_lib_save_LIBS=$LIBS LIBS="-lssl $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ char SSL_CTX_new (); int main (void) { return SSL_CTX_new (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : ac_cv_lib_ssl_SSL_CTX_new=yes else $as_nop ac_cv_lib_ssl_SSL_CTX_new=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ssl_SSL_CTX_new" >&5 printf "%s\n" "$ac_cv_lib_ssl_SSL_CTX_new" >&6; } if test "x$ac_cv_lib_ssl_SSL_CTX_new" = xyes then : OPENSSL_LIBS="$OPENSSL_LIBS -lssl" printf "%s\n" "#define HTS_USEOPENSSL 1" >>confdefs.h else $as_nop if test x"$https_support" = x"yes"; then as_fn_error $? "not available" "$LINENO" 5 else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not available" >&5 printf "%s\n" "not available" >&6; } fi fi LIBS=$SAVE_LIBS fi ### Support IPv6 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for getaddrinfo in -lc" >&5 printf %s "checking for getaddrinfo in -lc... " >&6; } if test ${ac_cv_lib_c_getaddrinfo+y} then : printf %s "(cached) " >&6 else $as_nop ac_check_lib_save_LIBS=$LIBS LIBS="-lc $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ char getaddrinfo (); int main (void) { return getaddrinfo (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : ac_cv_lib_c_getaddrinfo=yes else $as_nop ac_cv_lib_c_getaddrinfo=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_getaddrinfo" >&5 printf "%s\n" "$ac_cv_lib_c_getaddrinfo" >&6; } if test "x$ac_cv_lib_c_getaddrinfo" = xyes then : V6_FLAG="-DINET6" printf "%s\n" "#define HTS_INET6 1" >>confdefs.h else $as_nop { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: *** IPv6 not found IPv6 compatibility disabled" >&5 printf "%s\n" "$as_me: WARNING: *** IPv6 not found IPv6 compatibility disabled" >&2;} fi ### Check for LFS { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for fopen64 in -lc" >&5 printf %s "checking for fopen64 in -lc... " >&6; } if test ${ac_cv_lib_c_fopen64+y} then : printf %s "(cached) " >&6 else $as_nop ac_check_lib_save_LIBS=$LIBS LIBS="-lc $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ char fopen64 (); int main (void) { return fopen64 (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : ac_cv_lib_c_fopen64=yes else $as_nop ac_cv_lib_c_fopen64=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_fopen64" >&5 printf "%s\n" "$ac_cv_lib_c_fopen64" >&6; } if test "x$ac_cv_lib_c_fopen64" = xyes then : LFS_FLAG="-D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE" printf "%s\n" "#define HTS_LFS 1" >>confdefs.h else $as_nop { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not found" >&5 printf "%s\n" "not found" >&6; } fi ### Check for pthread { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lpthread" >&5 printf %s "checking for pthread_create in -lpthread... " >&6; } if test ${ac_cv_lib_pthread_pthread_create+y} then : printf %s "(cached) " >&6 else $as_nop ac_check_lib_save_LIBS=$LIBS LIBS="-lpthread $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ char pthread_create (); int main (void) { return pthread_create (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : ac_cv_lib_pthread_pthread_create=yes else $as_nop ac_cv_lib_pthread_pthread_create=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_create" >&5 printf "%s\n" "$ac_cv_lib_pthread_pthread_create" >&6; } if test "x$ac_cv_lib_pthread_pthread_create" = xyes then : THREADS_LIBS=-lpthread printf "%s\n" "#define THREADS 1" >>confdefs.h else $as_nop { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not found" >&5 printf "%s\n" "not found" >&6; } fi if test x$THREADS_LIBS = x then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lc" >&5 printf %s "checking for pthread_create in -lc... " >&6; } if test ${ac_cv_lib_c_pthread_create+y} then : printf %s "(cached) " >&6 else $as_nop ac_check_lib_save_LIBS=$LIBS LIBS="-lc $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ char pthread_create (); int main (void) { return pthread_create (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : ac_cv_lib_c_pthread_create=yes else $as_nop ac_cv_lib_c_pthread_create=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_pthread_create" >&5 printf "%s\n" "$ac_cv_lib_c_pthread_create" >&6; } if test "x$ac_cv_lib_c_pthread_create" = xyes then : THREADS_LIBS= printf "%s\n" "#define THREADS 1" >>confdefs.h else $as_nop { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not found" >&5 printf "%s\n" "not found" >&6; } fi if test x$THREADS_LIBS = x then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lpthreads" >&5 printf %s "checking for pthread_create in -lpthreads... " >&6; } if test ${ac_cv_lib_pthreads_pthread_create+y} then : printf %s "(cached) " >&6 else $as_nop ac_check_lib_save_LIBS=$LIBS LIBS="-lpthreads $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ char pthread_create (); int main (void) { return pthread_create (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : ac_cv_lib_pthreads_pthread_create=yes else $as_nop ac_cv_lib_pthreads_pthread_create=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_pthread_create" >&5 printf "%s\n" "$ac_cv_lib_pthreads_pthread_create" >&6; } if test "x$ac_cv_lib_pthreads_pthread_create" = xyes then : THREADS_LIBS= printf "%s\n" "#define THREADS 1" >>confdefs.h else $as_nop { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: *** not found" >&5 printf "%s\n" "$as_me: WARNING: *** not found" >&2;} fi fi fi THREADS_CFLAGS= ### Check for socket/nsl (solaris) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for socket in -lsocket" >&5 printf %s "checking for socket in -lsocket... " >&6; } if test ${ac_cv_lib_socket_socket+y} then : printf %s "(cached) " >&6 else $as_nop ac_check_lib_save_LIBS=$LIBS LIBS="-lsocket $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ char socket (); int main (void) { return socket (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : ac_cv_lib_socket_socket=yes else $as_nop ac_cv_lib_socket_socket=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_socket" >&5 printf "%s\n" "$ac_cv_lib_socket_socket" >&6; } if test "x$ac_cv_lib_socket_socket" = xyes then : SOCKET_LIBS="-lnsl -lsocket" printf "%s\n" "#define LIBSOCKET 1" >>confdefs.h else $as_nop { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not necessary" >&5 printf "%s\n" "not necessary" >&6; } fi ### Check for iconv { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for iconv in -liconv" >&5 printf %s "checking for iconv in -liconv... " >&6; } if test ${ac_cv_lib_iconv_iconv+y} then : printf %s "(cached) " >&6 else $as_nop ac_check_lib_save_LIBS=$LIBS LIBS="-liconv $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ char iconv (); int main (void) { return iconv (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : ac_cv_lib_iconv_iconv=yes else $as_nop ac_cv_lib_iconv_iconv=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_iconv_iconv" >&5 printf "%s\n" "$ac_cv_lib_iconv_iconv" >&6; } if test "x$ac_cv_lib_iconv_iconv" = xyes then : ICONV_LIBS="-liconv" printf "%s\n" "#define LIBICONV 1" >>confdefs.h else $as_nop { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not necessary" >&5 printf "%s\n" "not necessary" >&6; } fi ### Check for dlsym { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 printf %s "checking for dlopen in -ldl... " >&6; } if test ${ac_cv_lib_dl_dlopen+y} then : printf %s "(cached) " >&6 else $as_nop ac_check_lib_save_LIBS=$LIBS LIBS="-ldl $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ char dlopen (); int main (void) { return dlopen (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : ac_cv_lib_dl_dlopen=yes else $as_nop ac_cv_lib_dl_dlopen=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 printf "%s\n" "$ac_cv_lib_dl_dlopen" >&6; } if test "x$ac_cv_lib_dl_dlopen" = xyes then : DL_LIBS=-ldl printf "%s\n" "#define DLLIB 1" >>confdefs.h else $as_nop { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not found" >&5 printf "%s\n" "not found" >&6; } fi if test x$DL_LIBS = x then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lc" >&5 printf %s "checking for dlopen in -lc... " >&6; } if test ${ac_cv_lib_c_dlopen+y} then : printf %s "(cached) " >&6 else $as_nop ac_check_lib_save_LIBS=$LIBS LIBS="-lc $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ char dlopen (); int main (void) { return dlopen (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : ac_cv_lib_c_dlopen=yes else $as_nop ac_cv_lib_c_dlopen=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_dlopen" >&5 printf "%s\n" "$ac_cv_lib_c_dlopen" >&6; } if test "x$ac_cv_lib_c_dlopen" = xyes then : DL_LIBS= printf "%s\n" "#define DLLIB 1" >>confdefs.h else $as_nop { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: *** not found * this is bad" >&5 printf "%s\n" "$as_me: WARNING: *** not found * this is bad" >&2;} fi fi ### Check for setuid { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for setuid in -lc" >&5 printf %s "checking for setuid in -lc... " >&6; } if test ${ac_cv_lib_c_setuid+y} then : printf %s "(cached) " >&6 else $as_nop ac_check_lib_save_LIBS=$LIBS LIBS="-lc $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ char setuid (); int main (void) { return setuid (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : ac_cv_lib_c_setuid=yes else $as_nop ac_cv_lib_c_setuid=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_setuid" >&5 printf "%s\n" "$ac_cv_lib_c_setuid" >&6; } if test "x$ac_cv_lib_c_setuid" = xyes then : printf "%s\n" "#define SETUID 1" >>confdefs.h else $as_nop { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not found" >&5 printf "%s\n" "not found" >&6; } fi ### Check for snprintf ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf" if test "x$ac_cv_func_snprintf" = xyes then : printf "%s\n" "#define HAVE_SNPRINTF 1" >>confdefs.h fi ac_fn_c_check_func "$LINENO" "vsnprintf" "ac_cv_func_vsnprintf" if test "x$ac_cv_func_vsnprintf" = xyes then : printf "%s\n" "#define HAVE_VSNPRINTF 1" >>confdefs.h fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working snprintf" >&5 printf %s "checking for working snprintf... " >&6; } if test ${ac_cv_have_working_snprintf+y} then : printf %s "(cached) " >&6 else $as_nop if test "$cross_compiling" = yes then : ac_cv_have_working_snprintf=cross else $as_nop cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #include int main(void) { char bufs[5] = { 'x', 'x', 'x', '\0', '\0' }; char bufd[5] = { 'x', 'x', 'x', '\0', '\0' }; int i; i = snprintf (bufs, 2, "%s", "111"); if (strcmp (bufs, "1")) exit (1); if (i != 3) exit (1); i = snprintf (bufd, 2, "%d", 111); if (strcmp (bufd, "1")) exit (1); if (i != 3) exit (1); exit(0); } _ACEOF if ac_fn_c_try_run "$LINENO" then : ac_cv_have_working_snprintf=yes else $as_nop ac_cv_have_working_snprintf=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_working_snprintf" >&5 printf "%s\n" "$ac_cv_have_working_snprintf" >&6; } { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working vsnprintf" >&5 printf %s "checking for working vsnprintf... " >&6; } if test ${ac_cv_have_working_vsnprintf+y} then : printf %s "(cached) " >&6 else $as_nop if test "$cross_compiling" = yes then : ac_cv_have_working_vsnprintf=cross else $as_nop cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #include #include int my_vsnprintf (char *buf, const char *tmpl, ...) { int i; va_list args; va_start (args, tmpl); i = vsnprintf (buf, 2, tmpl, args); va_end (args); return i; } int main(void) { char bufs[5] = { 'x', 'x', 'x', '\0', '\0' }; char bufd[5] = { 'x', 'x', 'x', '\0', '\0' }; int i; i = my_vsnprintf (bufs, "%s", "111"); if (strcmp (bufs, "1")) exit (1); if (i != 3) exit (1); i = my_vsnprintf (bufd, "%d", 111); if (strcmp (bufd, "1")) exit (1); if (i != 3) exit (1); exit(0); } _ACEOF if ac_fn_c_try_run "$LINENO" then : ac_cv_have_working_vsnprintf=yes else $as_nop ac_cv_have_working_vsnprintf=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_working_vsnprintf" >&5 printf "%s\n" "$ac_cv_have_working_vsnprintf" >&6; } if test x$ac_cv_have_working_snprintf$ac_cv_have_working_vsnprintf != "xyesyes"; then case " $LIBOBJS " in *" snprintf.$ac_objext "* ) ;; *) LIBOBJS="$LIBOBJS snprintf.$ac_objext" ;; esac { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Replacing missing/broken (v)snprintf() with version from http://www.ijs.si/software/snprintf/." >&5 printf "%s\n" "$as_me: WARNING: Replacing missing/broken (v)snprintf() with version from http://www.ijs.si/software/snprintf/." >&2;} printf "%s\n" "#define PREFER_PORTABLE_SNPRINTF 1" >>confdefs.h fi ### Check for strnlen { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for strnlen in -lc" >&5 printf %s "checking for strnlen in -lc... " >&6; } if test ${ac_cv_lib_c_strnlen+y} then : printf %s "(cached) " >&6 else $as_nop ac_check_lib_save_LIBS=$LIBS LIBS="-lc $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ char strnlen (); int main (void) { return strnlen (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : ac_cv_lib_c_strnlen=yes else $as_nop ac_cv_lib_c_strnlen=no fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_strnlen" >&5 printf "%s\n" "$ac_cv_lib_c_strnlen" >&6; } if test "x$ac_cv_lib_c_strnlen" = xyes then : printf "%s\n" "#define HAVE_STRNLEN 1" >>confdefs.h else $as_nop { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not found" >&5 printf "%s\n" "not found" >&6; } fi ## Online unit tests { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable online unit tests" >&5 printf %s "checking whether to enable online unit tests... " >&6; } # Check whether --enable-online-unit-tests was given. if test ${enable_online_unit_tests+y} then : enableval=$enable_online_unit_tests; case "${enableval}" in no|yes|auto) online_unit_tests=$enableval { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $enableval" >&5 printf "%s\n" "$enableval" >&6; } ;; *) as_fn_error expected yes/no/auto "bad value for online-unit-tests" "$LINENO" 5 ;; esac else $as_nop online_unit_tests=no { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } fi ONLINE_UNIT_TESTS=$online_unit_tests # Final output ac_config_files="$ac_config_files Makefile src/Makefile man/Makefile m4/Makefile templates/Makefile lang/Makefile html/Makefile libtest/Makefile tests/Makefile" cat >confcache <<\_ACEOF # This file is a shell script that caches the results of configure # tests run on this system so they can be shared between configure # scripts and configure runs, see configure's option --config-cache. # It is not useful on other systems. If it contains results you don't # want to keep, you may remove or edit it. # # config.status only pays attention to the cache file if you give it # the --recheck option to rerun configure. # # `ac_cv_env_foo' variables (set or unset) will be overridden when # loading this file, other *unset* `ac_cv_foo' will be assigned the # following values. _ACEOF # The following way of writing the cache mishandles newlines in values, # but we know of no workaround that is simple, portable, and efficient. # So, we kill variables containing newlines. # Ultrix sh set writes to stderr and can't be redirected directly, # and sets the high bit in the cache file unless we assign to the vars. ( for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do eval ac_val=\$$ac_var case $ac_val in #( *${as_nl}*) case $ac_var in #( *_cv_*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 printf "%s\n" "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; esac case $ac_var in #( _ | IFS | as_nl) ;; #( BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( *) { eval $ac_var=; unset $ac_var;} ;; esac ;; esac done (set) 2>&1 | case $as_nl`(ac_space=' '; set) 2>&1` in #( *${as_nl}ac_space=\ *) # `set' does not quote correctly, so add quotes: double-quote # substitution turns \\\\ into \\, and sed turns \\ into \. sed -n \ "s/'/'\\\\''/g; s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" ;; #( *) # `set' quotes correctly as required by POSIX, so do not add quotes. sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" ;; esac | sort ) | sed ' /^ac_cv_env_/b end t clear :clear s/^\([^=]*\)=\(.*[{}].*\)$/test ${\1+y} || &/ t end s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ :end' >>confcache if diff "$cache_file" confcache >/dev/null 2>&1; then :; else if test -w "$cache_file"; then if test "x$cache_file" != "x/dev/null"; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 printf "%s\n" "$as_me: updating cache $cache_file" >&6;} 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 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 printf "%s\n" "$as_me: not updating unwritable cache $cache_file" >&6;} fi fi rm -f confcache test "x$prefix" = xNONE && prefix=$ac_default_prefix # Let make expand exec_prefix. test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' DEFS=-DHAVE_CONFIG_H ac_libobjs= ac_ltlibobjs= U= for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue # 1. Remove the extension, and $U if already installed. ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' ac_i=`printf "%s\n" "$ac_i" | sed "$ac_script"` # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR # will be set to the directory where LIBOBJS objects are built. as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' done LIBOBJS=$ac_libobjs LTLIBOBJS=$ac_ltlibobjs { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5 printf %s "checking that generated files are newer than configure... " >&6; } if test -n "$am_sleep_pid"; then # Hide warnings about reused PIDs. wait $am_sleep_pid 2>/dev/null fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: done" >&5 printf "%s\n" "done" >&6; } if test -n "$EXEEXT"; then am__EXEEXT_TRUE= am__EXEEXT_FALSE='#' else am__EXEEXT_TRUE='#' am__EXEEXT_FALSE= fi if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then as_fn_error $? "conditional \"MAINTAINER_MODE\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then as_fn_error $? "conditional \"AMDEP\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then as_fn_error $? "conditional \"am__fastdepCC\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then as_fn_error $? "conditional \"am__fastdepCC\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi : "${CONFIG_STATUS=./config.status}" ac_write_fail=0 ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files $CONFIG_STATUS" { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 printf "%s\n" "$as_me: creating $CONFIG_STATUS" >&6;} as_write_fail=0 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 #! $SHELL # Generated by $as_me. # Run this file to recreate the current configuration. # Compiler output produced by configure, useful for debugging # configure, is in config.log if it exists. debug=false ac_cs_recheck=false ac_cs_silent=false SHELL=\${CONFIG_SHELL-$SHELL} export SHELL _ASEOF cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 ## -------------------- ## ## M4sh Initialization. ## ## -------------------- ## # Be more Bourne compatible DUALCASE=1; export DUALCASE # for MKS sh as_nop=: if test ${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1 then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else $as_nop case `(set -o) 2>/dev/null` in #( *posix*) : set -o posix ;; #( *) : ;; esac fi # Reset variables that may have inherited troublesome values from # the environment. # IFS needs to be set, to space, tab, and newline, in precisely that order. # (If _AS_PATH_WALK were called with IFS unset, it would have the # side effect of setting IFS to empty, thus disabling word splitting.) # Quoting is to prevent editors from complaining about space-tab. as_nl=' ' export as_nl IFS=" "" $as_nl" PS1='$ ' PS2='> ' PS4='+ ' # Ensure predictable behavior from utilities with locale-dependent output. LC_ALL=C export LC_ALL LANGUAGE=C export LANGUAGE # We cannot yet rely on "unset" to work, but we need these variables # to be unset--not just set to an empty or harmless value--now, to # avoid bugs in old shells (e.g. pre-3.0 UWIN ksh). This construct # also avoids known problems related to "unset" and subshell syntax # in other old shells (e.g. bash 2.01 and pdksh 5.2.14). for as_var in BASH_ENV ENV MAIL MAILPATH CDPATH do eval test \${$as_var+y} \ && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : done # Ensure that fds 0, 1, and 2 are open. if (exec 3>&0) 2>/dev/null; then :; else exec 0&1) 2>/dev/null; then :; else exec 1>/dev/null; fi if (exec 3>&2) ; then :; else exec 2>/dev/null; fi # The user is always right. if ${PATH_SEPARATOR+false} :; then PATH_SEPARATOR=: (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || PATH_SEPARATOR=';' } fi # 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 for as_dir in $PATH do IFS=$as_save_IFS case $as_dir in #((( '') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac test -r "$as_dir$0" && as_myself=$as_dir$0 && break done IFS=$as_save_IFS ;; esac # We did not find ourselves, most probably we were run as `sh COMMAND' # in which case we are not to be found in the path. if test "x$as_myself" = x; then as_myself=$0 fi if test ! -f "$as_myself"; then printf "%s\n" "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 exit 1 fi # as_fn_error STATUS ERROR [LINENO LOG_FD] # ---------------------------------------- # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are # provided, also output the error to LOG_FD, referencing LINENO. Then exit the # script with STATUS, using 1 if that was 0. as_fn_error () { as_status=$1; test $as_status -eq 0 && as_status=1 if test "$4"; then as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 fi printf "%s\n" "$as_me: error: $2" >&2 as_fn_exit $as_status } # as_fn_error # as_fn_set_status STATUS # ----------------------- # Set $? to STATUS, without forking. as_fn_set_status () { return $1 } # as_fn_set_status # as_fn_exit STATUS # ----------------- # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. as_fn_exit () { set +e as_fn_set_status $1 exit $1 } # as_fn_exit # as_fn_unset VAR # --------------- # Portably unset VAR. as_fn_unset () { { eval $1=; unset $1;} } as_unset=as_fn_unset # as_fn_append VAR VALUE # ---------------------- # Append the text in VALUE to the end of the definition contained in VAR. Take # advantage of any shell optimizations that allow amortized linear growth over # repeated appends, instead of the typical quadratic growth present in naive # implementations. if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null then : eval 'as_fn_append () { eval $1+=\$2 }' else $as_nop as_fn_append () { eval $1=\$$1\$2 } fi # as_fn_append # as_fn_arith ARG... # ------------------ # Perform arithmetic evaluation on the ARGs, and store the result in the # global $as_val. Take advantage of shells that can avoid forks. The arguments # must be portable across $(()) and expr. if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null then : eval 'as_fn_arith () { as_val=$(( $* )) }' else $as_nop as_fn_arith () { as_val=`expr "$@" || test $? -eq 1` } fi # as_fn_arith if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then as_basename=basename else as_basename=false fi if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then as_dirname=dirname else as_dirname=false fi as_me=`$as_basename -- "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || printf "%s\n" X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q } /^X\/\(\/\/\)$/{ s//\1/ q } /^X\/\(\/\).*/{ s//\1/ q } s/.*/./; q'` # Avoid depending upon Character Ranges. as_cr_letters='abcdefghijklmnopqrstuvwxyz' as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' as_cr_Letters=$as_cr_letters$as_cr_LETTERS as_cr_digits='0123456789' as_cr_alnum=$as_cr_Letters$as_cr_digits # Determine whether it's possible to make 'echo' print without a newline. # These variables are no longer used directly by Autoconf, but are AC_SUBSTed # for compatibility with existing Makefiles. ECHO_C= ECHO_N= ECHO_T= case `echo -n x` in #((((( -n*) case `echo 'xy\c'` in *c*) ECHO_T=' ';; # ECHO_T is single tab character. xy) ECHO_C='\c';; *) echo `echo ksh88 bug on AIX 6.1` > /dev/null ECHO_T=' ';; esac;; *) ECHO_N='-n';; esac # For backward compatibility with old third-party macros, we provide # the shell variables $as_echo and $as_echo_n. New code should use # AS_ECHO(["message"]) and AS_ECHO_N(["message"]), respectively. as_echo='printf %s\n' as_echo_n='printf %s' rm -f conf$$ conf$$.exe conf$$.file if test -d conf$$.dir; then rm -f conf$$.dir/conf$$.file else rm -f conf$$.dir mkdir conf$$.dir 2>/dev/null fi if (echo >conf$$.file) 2>/dev/null; then if ln -s conf$$.file conf$$ 2>/dev/null; then as_ln_s='ln -s' # ... but there are two gotchas: # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. # In both cases, we have to default to `cp -pR'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || as_ln_s='cp -pR' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else as_ln_s='cp -pR' fi else as_ln_s='cp -pR' fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null # as_fn_mkdir_p # ------------- # Create "$as_dir" as a directory, including parents if necessary. as_fn_mkdir_p () { case $as_dir in #( -*) as_dir=./$as_dir;; esac test -d "$as_dir" || eval $as_mkdir_p || { as_dirs= while :; do case $as_dir in #( *\'*) as_qdir=`printf "%s\n" "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( *) as_qdir=$as_dir;; esac as_dirs="'$as_qdir' $as_dirs" as_dir=`$as_dirname -- "$as_dir" || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || printf "%s\n" X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` test -d "$as_dir" && break done test -z "$as_dirs" || eval "mkdir $as_dirs" } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" } # as_fn_mkdir_p if mkdir -p . 2>/dev/null; then as_mkdir_p='mkdir -p "$as_dir"' else test -d ./-p && rmdir ./-p as_mkdir_p=false fi # as_fn_executable_p FILE # ----------------------- # Test if FILE is an executable regular file. as_fn_executable_p () { test -f "$1" && test -x "$1" } # as_fn_executable_p as_test_x='test -x' as_executable_p=as_fn_executable_p # Sed expression to map a string onto a valid CPP name. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" # Sed expression to map a string onto a valid variable name. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" exec 6>&1 ## ----------------------------------- ## ## Main body of $CONFIG_STATUS script. ## ## ----------------------------------- ## _ASEOF test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # Save the log message, to keep $0 and so on meaningful, and to # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" This file was extended by httrack $as_me 3.49.5, which was generated by GNU Autoconf 2.71. Invocation command line was CONFIG_FILES = $CONFIG_FILES CONFIG_HEADERS = $CONFIG_HEADERS CONFIG_LINKS = $CONFIG_LINKS CONFIG_COMMANDS = $CONFIG_COMMANDS $ $0 $@ on `(hostname || uname -n) 2>/dev/null | sed 1q` " _ACEOF case $ac_config_files in *" "*) set x $ac_config_files; shift; ac_config_files=$*;; esac case $ac_config_headers in *" "*) set x $ac_config_headers; shift; ac_config_headers=$*;; esac cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 # Files that config.status was made for. config_files="$ac_config_files" config_headers="$ac_config_headers" config_commands="$ac_config_commands" _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 ac_cs_usage="\ \`$as_me' instantiates files and other configuration actions from templates according to the current configuration. Unless the files and actions are specified as TAGs, all are instantiated by default. Usage: $0 [OPTION]... [TAG]... -h, --help print this help, then exit -V, --version print version number and configuration settings, then exit --config print configuration, then exit -q, --quiet, --silent do not print progress messages -d, --debug don't remove temporary files --recheck update $as_me by reconfiguring in the same conditions --file=FILE[:TEMPLATE] instantiate the configuration file FILE --header=FILE[:TEMPLATE] instantiate the configuration header FILE Configuration files: $config_files Configuration headers: $config_headers Configuration commands: $config_commands Report bugs to . httrack home page: ." _ACEOF ac_cs_config=`printf "%s\n" "$ac_configure_args" | sed "$ac_safe_unquote"` ac_cs_config_escaped=`printf "%s\n" "$ac_cs_config" | sed "s/^ //; s/'/'\\\\\\\\''/g"` cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config='$ac_cs_config_escaped' ac_cs_version="\\ httrack config.status 3.49.5 configured by $0, generated by GNU Autoconf 2.71, with options \\"\$ac_cs_config\\" Copyright (C) 2021 Free Software Foundation, Inc. This config.status script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it." ac_pwd='$ac_pwd' srcdir='$srcdir' INSTALL='$INSTALL' MKDIR_P='$MKDIR_P' AWK='$AWK' test -n "\$AWK" || AWK=awk _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # The default lists apply if the user does not specify any file. ac_need_defaults=: while test $# != 0 do case $1 in --*=?*) ac_option=`expr "X$1" : 'X\([^=]*\)='` ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` ac_shift=: ;; --*=) ac_option=`expr "X$1" : 'X\([^=]*\)='` ac_optarg= ac_shift=: ;; *) ac_option=$1 ac_optarg=$2 ac_shift=shift ;; esac case $ac_option in # Handling of the options. -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) ac_cs_recheck=: ;; --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) printf "%s\n" "$ac_cs_version"; exit ;; --config | --confi | --conf | --con | --co | --c ) printf "%s\n" "$ac_cs_config"; exit ;; --debug | --debu | --deb | --de | --d | -d ) debug=: ;; --file | --fil | --fi | --f ) $ac_shift case $ac_optarg in *\'*) ac_optarg=`printf "%s\n" "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; '') as_fn_error $? "missing file argument" ;; esac as_fn_append CONFIG_FILES " '$ac_optarg'" ac_need_defaults=false;; --header | --heade | --head | --hea ) $ac_shift case $ac_optarg in *\'*) ac_optarg=`printf "%s\n" "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; esac as_fn_append CONFIG_HEADERS " '$ac_optarg'" ac_need_defaults=false;; --he | --h) # Conflict between --help and --header as_fn_error $? "ambiguous option: \`$1' Try \`$0 --help' for more information.";; --help | --hel | -h ) printf "%s\n" "$ac_cs_usage"; exit ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil | --si | --s) ac_cs_silent=: ;; # This is an error. -*) as_fn_error $? "unrecognized option: \`$1' Try \`$0 --help' for more information." ;; *) as_fn_append ac_config_targets " $1" ac_need_defaults=false ;; esac shift done ac_configure_extra_args= if $ac_cs_silent; then exec 6>/dev/null ac_configure_extra_args="$ac_configure_extra_args --silent" fi _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 if \$ac_cs_recheck; then set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion shift \printf "%s\n" "running CONFIG_SHELL=$SHELL \$*" >&6 CONFIG_SHELL='$SHELL' export CONFIG_SHELL exec "\$@" fi _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 exec 5>>config.log { echo sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX ## Running $as_me. ## _ASBOX printf "%s\n" "$ac_log" } >&5 _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 # # INIT-COMMANDS # AMDEP_TRUE="$AMDEP_TRUE" MAKE="${MAKE-make}" # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH sed_quote_subst='$sed_quote_subst' double_quote_subst='$double_quote_subst' delay_variable_subst='$delay_variable_subst' macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`' macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`' enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`' enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`' pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`' enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`' shared_archive_member_spec='`$ECHO "$shared_archive_member_spec" | $SED "$delay_single_quote_subst"`' SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`' ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`' PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`' host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`' host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`' host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`' build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`' build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`' build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`' SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`' Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`' GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`' EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`' FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`' LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`' NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`' LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`' max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`' ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`' exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`' lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`' lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`' lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`' lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`' lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`' reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`' reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`' FILECMD='`$ECHO "$FILECMD" | $SED "$delay_single_quote_subst"`' OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`' deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`' file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`' file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`' want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`' DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`' sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`' AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`' lt_ar_flags='`$ECHO "$lt_ar_flags" | $SED "$delay_single_quote_subst"`' AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`' archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`' STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`' RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`' old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`' old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`' old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`' lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`' CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`' CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`' compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`' GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`' lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`' lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`' lt_cv_sys_global_symbol_to_import='`$ECHO "$lt_cv_sys_global_symbol_to_import" | $SED "$delay_single_quote_subst"`' lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`' lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`' lt_cv_nm_interface='`$ECHO "$lt_cv_nm_interface" | $SED "$delay_single_quote_subst"`' nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`' lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`' lt_cv_truncate_bin='`$ECHO "$lt_cv_truncate_bin" | $SED "$delay_single_quote_subst"`' objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`' MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`' lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`' lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`' lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`' lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`' lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`' need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`' MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`' DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`' NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`' LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`' OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`' OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`' libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`' shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`' extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`' archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`' enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`' export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`' whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`' compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`' old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`' old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`' archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`' archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`' module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`' module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`' with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`' allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`' no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`' hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`' hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`' hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`' hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`' hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`' hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`' hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`' inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`' link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`' always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`' export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`' exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`' include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`' prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`' postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`' file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`' variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`' need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`' need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`' version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`' runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`' shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`' shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`' libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`' library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`' soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`' install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`' postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`' postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`' finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`' finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`' hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`' sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`' configure_time_dlsearch_path='`$ECHO "$configure_time_dlsearch_path" | $SED "$delay_single_quote_subst"`' configure_time_lt_sys_library_path='`$ECHO "$configure_time_lt_sys_library_path" | $SED "$delay_single_quote_subst"`' hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`' enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`' enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`' enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`' old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`' striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`' LTCC='$LTCC' LTCFLAGS='$LTCFLAGS' compiler='$compiler_DEFAULT' # A function that is used when there is no print builtin or printf. func_fallback_echo () { eval 'cat <<_LTECHO_EOF \$1 _LTECHO_EOF' } # Quote evaled strings. for var in SHELL \ ECHO \ PATH_SEPARATOR \ SED \ GREP \ EGREP \ FGREP \ LD \ NM \ LN_S \ lt_SP2NL \ lt_NL2SP \ reload_flag \ FILECMD \ OBJDUMP \ deplibs_check_method \ file_magic_cmd \ file_magic_glob \ want_nocaseglob \ DLLTOOL \ sharedlib_from_linklib_cmd \ AR \ archiver_list_spec \ STRIP \ RANLIB \ CC \ CFLAGS \ compiler \ lt_cv_sys_global_symbol_pipe \ lt_cv_sys_global_symbol_to_cdecl \ lt_cv_sys_global_symbol_to_import \ lt_cv_sys_global_symbol_to_c_name_address \ lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \ lt_cv_nm_interface \ nm_file_list_spec \ lt_cv_truncate_bin \ lt_prog_compiler_no_builtin_flag \ lt_prog_compiler_pic \ lt_prog_compiler_wl \ lt_prog_compiler_static \ lt_cv_prog_compiler_c_o \ need_locks \ MANIFEST_TOOL \ DSYMUTIL \ NMEDIT \ LIPO \ OTOOL \ OTOOL64 \ shrext_cmds \ export_dynamic_flag_spec \ whole_archive_flag_spec \ compiler_needs_object \ with_gnu_ld \ allow_undefined_flag \ no_undefined_flag \ hardcode_libdir_flag_spec \ hardcode_libdir_separator \ exclude_expsyms \ include_expsyms \ file_list_spec \ variables_saved_for_relink \ libname_spec \ library_names_spec \ soname_spec \ install_override_mode \ finish_eval \ old_striplib \ striplib; do case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in *[\\\\\\\`\\"\\\$]*) eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes ;; *) eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" ;; esac done # Double-quote double-evaled strings. for var in reload_cmds \ old_postinstall_cmds \ old_postuninstall_cmds \ old_archive_cmds \ extract_expsyms_cmds \ old_archive_from_new_cmds \ old_archive_from_expsyms_cmds \ archive_cmds \ archive_expsym_cmds \ module_cmds \ module_expsym_cmds \ export_symbols_cmds \ prelink_cmds \ postlink_cmds \ postinstall_cmds \ postuninstall_cmds \ finish_cmds \ sys_lib_search_path_spec \ configure_time_dlsearch_path \ configure_time_lt_sys_library_path; do case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in *[\\\\\\\`\\"\\\$]*) eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes ;; *) eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" ;; esac done ac_aux_dir='$ac_aux_dir' # See if we are running on zsh, and set the options that allow our # commands through without removal of \ escapes INIT. if test -n "\${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi PACKAGE='$PACKAGE' VERSION='$VERSION' RM='$RM' ofile='$ofile' _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # Handling of arguments. for ac_config_target in $ac_config_targets do case $ac_config_target in "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;; "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;; "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;; "man/Makefile") CONFIG_FILES="$CONFIG_FILES man/Makefile" ;; "m4/Makefile") CONFIG_FILES="$CONFIG_FILES m4/Makefile" ;; "templates/Makefile") CONFIG_FILES="$CONFIG_FILES templates/Makefile" ;; "lang/Makefile") CONFIG_FILES="$CONFIG_FILES lang/Makefile" ;; "html/Makefile") CONFIG_FILES="$CONFIG_FILES html/Makefile" ;; "libtest/Makefile") CONFIG_FILES="$CONFIG_FILES libtest/Makefile" ;; "tests/Makefile") CONFIG_FILES="$CONFIG_FILES tests/Makefile" ;; *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; esac done # If the user did not use the arguments to specify the items to instantiate, # then the envvar interface is used. Set only those that are not. # We use the long form for the default assignment because of an extremely # bizarre bug on SunOS 4.1.3. if $ac_need_defaults; then test ${CONFIG_FILES+y} || CONFIG_FILES=$config_files test ${CONFIG_HEADERS+y} || CONFIG_HEADERS=$config_headers test ${CONFIG_COMMANDS+y} || CONFIG_COMMANDS=$config_commands fi # Have a temporary directory for convenience. Make it in the build tree # simply because there is no reason against having it here, and in addition, # creating and moving files from /tmp can sometimes cause problems. # Hook for its removal unless debugging. # Note that there is a small window in which the directory will not be cleaned: # after its creation but before its name has been assigned to `$tmp'. $debug || { tmp= ac_tmp= trap '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 } # Create a (secure) tmp directory for tmp files. { tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && 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. # This happens for instance with `./config.status config.h'. if test -n "$CONFIG_FILES"; then ac_cr=`echo X | tr X '\015'` # On cygwin, bash can eat \r inside `` if the user requested igncr. # But we know of no other shell where ac_cr would be empty at this # point, so we can use a bashism as a fallback. if test "x$ac_cr" = x; then eval ac_cr=\$\'\\r\' fi ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' /dev/null` if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then ac_cs_awk_cr='\\r' else ac_cs_awk_cr=$ac_cr fi echo 'BEGIN {' >"$ac_tmp/subs1.awk" && _ACEOF { echo "cat >conf$$subs.awk <<_ACEOF" && echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && echo "_ACEOF" } >conf$$subs.sh || as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` ac_delim='%!_!# ' for ac_last_try in false false false false false :; do . ./conf$$subs.sh || as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` if test $ac_delim_n = $ac_delim_num; then break elif $ac_last_try; then as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 else ac_delim="$ac_delim!$ac_delim _$ac_delim!! " fi done rm -f conf$$subs.sh cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && _ACEOF sed -n ' h s/^/S["/; s/!.*/"]=/ p g s/^[^!]*!// :repl t repl s/'"$ac_delim"'$// t delim :nl h s/\(.\{148\}\)..*/\1/ t more1 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ p n b repl :more1 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ p g s/.\{148\}// t nl :delim h s/\(.\{148\}\)..*/\1/ t more2 s/["\\]/\\&/g; s/^/"/; s/$/"/ p b :more2 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ p g s/.\{148\}// t delim ' >$CONFIG_STATUS || ac_write_fail=1 rm -f conf$$subs.awk cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 _ACAWK cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && for (key in S) S_is_set[key] = 1 FS = "" } { line = $ 0 nfields = split(line, field, "@") substed = 0 len = length(field[1]) for (i = 2; i < nfields; i++) { key = field[i] keylen = length(key) if (S_is_set[key]) { value = S[key] line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) len += length(value) + length(field[++i]) substed = 1 } else len += 1 + keylen } print line } _ACAWK _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" else cat fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 _ACEOF # VPATH may cause trouble with some makes, so we remove sole $(srcdir), # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and # trailing colons and then remove the whole line if VPATH becomes empty # (actually we leave an empty line to preserve line numbers). if test "x$srcdir" = x.; then ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ h s/// s/^/:/ s/[ ]*$/:/ s/:\$(srcdir):/:/g s/:\${srcdir}:/:/g s/:@srcdir@:/:/g s/^:*// s/:*$// x s/\(=[ ]*\).*/\1/ G s/\n// s/^[^=]*=[ ]*$// }' fi cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 fi # test -n "$CONFIG_FILES" # Set up the scripts for CONFIG_HEADERS section. # 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 >"$ac_tmp/defines.awk" <<\_ACAWK || BEGIN { _ACEOF # Transform confdefs.h into an awk script `defines.awk', embedded as # here-document in config.status, that substitutes the proper values into # config.h.in to produce config.h. # Create a delimiter string that does not exist in confdefs.h, to ease # handling of long lines. ac_delim='%!_!# ' for ac_last_try in false false :; do 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 else ac_delim="$ac_delim!$ac_delim _$ac_delim!! " fi done # For the awk script, D is an array of macro values keyed by name, # likewise P contains macro parameters if any. Preserve backslash # newline sequences. ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* sed -n ' s/.\{148\}/&'"$ac_delim"'/g t rset :rset s/^[ ]*#[ ]*define[ ][ ]*/ / t def d :def s/\\$// t bsnl s/["\\]/\\&/g s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ D["\1"]=" \3"/p s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p d :bsnl s/["\\]/\\&/g s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ D["\1"]=" \3\\\\\\n"\\/p t cont s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p t cont d :cont n s/.\{148\}/&'"$ac_delim"'/g t clear :clear s/\\$// t bsnlc s/["\\]/\\&/g; s/^/"/; s/$/"/p d :bsnlc s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p b cont ' >$CONFIG_STATUS || ac_write_fail=1 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 for (key in D) D_is_set[key] = 1 FS = "" } /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { line = \$ 0 split(line, arg, " ") if (arg[1] == "#") { defundef = arg[2] mac1 = arg[3] } else { defundef = substr(arg[1], 2) mac1 = arg[2] } split(mac1, mac2, "(") #) macro = mac2[1] prefix = substr(line, 1, index(line, defundef) - 1) if (D_is_set[macro]) { # Preserve the white space surrounding the "#". print prefix "define", macro P[macro] D[macro] next } else { # Replace #undef with comments. This is necessary, for example, # in the case of _POSIX_SOURCE, which is predefined and required # on some systems where configure will not decide to define it. if (defundef == "undef") { print "/*", prefix defundef, macro, "*/" next } } } { print } _ACAWK _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 fi # test -n "$CONFIG_HEADERS" eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" shift for ac_tag do case $ac_tag in :[FHLC]) ac_mode=$ac_tag; continue;; esac case $ac_mode$ac_tag in :[FHL]*:*);; :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; :[FH]-) ac_tag=-:-;; :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; esac ac_save_IFS=$IFS IFS=: set x $ac_tag IFS=$ac_save_IFS shift ac_file=$1 shift case $ac_mode in :L) ac_source=$1;; :[FH]) ac_file_inputs= for ac_f do case $ac_f in -) 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 `:'. test -f "$ac_f" || case $ac_f in [\\/$]*) false;; *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; esac || as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; esac case $ac_f in *\'*) ac_f=`printf "%s\n" "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac as_fn_append ac_file_inputs " '$ac_f'" done # Let's still pretend it is `configure' which instantiates (i.e., don't # use $as_me), people would be surprised to read: # /* config.h. Generated by config.status. */ configure_input='Generated from '` printf "%s\n" "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' `' by configure.' if test x"$ac_file" != x-; then configure_input="$ac_file. $configure_input" { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 printf "%s\n" "$as_me: creating $ac_file" >&6;} fi # Neutralize special characters interpreted by sed in replacement strings. case $configure_input in #( *\&* | *\|* | *\\* ) ac_sed_conf_input=`printf "%s\n" "$configure_input" | sed 's/[\\\\&|]/\\\\&/g'`;; #( *) ac_sed_conf_input=$configure_input;; esac case $ac_tag in *:-:* | *:-) cat >"$ac_tmp/stdin" \ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; esac ;; esac ac_dir=`$as_dirname -- "$ac_file" || $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$ac_file" : 'X\(//\)[^/]' \| \ X"$ac_file" : 'X\(//\)$' \| \ X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || printf "%s\n" X"$ac_file" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` as_dir="$ac_dir"; as_fn_mkdir_p ac_builddir=. case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_dir_suffix=/`printf "%s\n" "$ac_dir" | sed 's|^\.[\\/]||'` # A ".." for each directory in $ac_dir_suffix. ac_top_builddir_sub=`printf "%s\n" "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` case $ac_top_builddir_sub in "") ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; esac ;; esac ac_abs_top_builddir=$ac_pwd ac_abs_builddir=$ac_pwd$ac_dir_suffix # for backward compatibility: ac_top_builddir=$ac_top_build_prefix case $srcdir in .) # We are building in place. ac_srcdir=. ac_top_srcdir=$ac_top_builddir_sub ac_abs_top_srcdir=$ac_pwd ;; [\\/]* | ?:[\\/]* ) # Absolute name. ac_srcdir=$srcdir$ac_dir_suffix; ac_top_srcdir=$srcdir ac_abs_top_srcdir=$srcdir ;; *) # Relative name. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix ac_top_srcdir=$ac_top_build_prefix$srcdir ac_abs_top_srcdir=$ac_pwd/$srcdir ;; esac ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix case $ac_mode in :F) # # CONFIG_FILE # case $INSTALL in [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; esac ac_MKDIR_P=$MKDIR_P case $MKDIR_P in [\\/$]* | ?:[\\/]* ) ;; */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;; esac _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # If the template does not know about datarootdir, expand it. # FIXME: This hack should be removed a few years after 2.60. ac_datarootdir_hack=; ac_datarootdir_seen= ac_sed_dataroot=' /datarootdir/ { p q } /@datadir@/p /@docdir@/p /@infodir@/p /@localedir@/p /@mandir@/p' case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in *datarootdir*) ac_datarootdir_seen=yes;; *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 printf "%s\n" "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_datarootdir_hack=' s&@datadir@&$datadir&g s&@docdir@&$docdir&g s&@infodir@&$infodir&g s&@localedir@&$localedir&g s&@mandir@&$mandir&g s&\\\${datarootdir}&$datarootdir&g' ;; esac _ACEOF # Neutralize VPATH when `$srcdir' = `.'. # Shell code in configure.ac might set extrasub. # FIXME: do we really want to maintain this feature? cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_sed_extra="$ac_vpsub $extrasub _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 :t /@[a-zA-Z_][a-zA-Z_0-9]*@/!b s|@configure_input@|$ac_sed_conf_input|;t t s&@top_builddir@&$ac_top_builddir_sub&;t t s&@top_build_prefix@&$ac_top_build_prefix&;t t s&@srcdir@&$ac_srcdir&;t t s&@abs_srcdir@&$ac_abs_srcdir&;t t s&@top_srcdir@&$ac_top_srcdir&;t t s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t s&@builddir@&$ac_builddir&;t t s&@abs_builddir@&$ac_abs_builddir&;t t s&@abs_top_builddir@&$ac_abs_top_builddir&;t t s&@INSTALL@&$ac_INSTALL&;t t s&@MKDIR_P@&$ac_MKDIR_P&;t t $ac_datarootdir_hack " 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' "$ac_tmp/out"`; test -n "$ac_out"; } && { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ "$ac_tmp/out"`; test -z "$ac_out"; } && { printf "%s\n" "$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 printf "%s\n" "$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 "$ac_tmp/stdin" case $ac_file in -) 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 ;; :H) # # CONFIG_HEADER # if test x"$ac_file" != x-; then { printf "%s\n" "/* $configure_input */" >&1 \ && 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" "$ac_tmp/config.h" >/dev/null 2>&1; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 printf "%s\n" "$as_me: $ac_file is unchanged" >&6;} else rm -f "$ac_file" mv "$ac_tmp/config.h" "$ac_file" \ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 fi else printf "%s\n" "/* $configure_input */" >&1 \ && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ || as_fn_error $? "could not create -" "$LINENO" 5 fi # Compute "$ac_file"'s index in $config_headers. _am_arg="$ac_file" _am_stamp_count=1 for _am_header in $config_headers :; do case $_am_header in $_am_arg | $_am_arg:* ) break ;; * ) _am_stamp_count=`expr $_am_stamp_count + 1` ;; esac done echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" || $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$_am_arg" : 'X\(//\)[^/]' \| \ X"$_am_arg" : 'X\(//\)$' \| \ X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null || printf "%s\n" X"$_am_arg" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'`/stamp-h$_am_stamp_count ;; :C) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 printf "%s\n" "$as_me: executing $ac_file commands" >&6;} ;; esac case $ac_file$ac_mode in "depfiles":C) test x"$AMDEP_TRUE" != x"" || { # Older Autoconf quotes --file arguments for eval, but not when files # are listed without --file. Let's play safe and only enable the eval # if we detect the quoting. # TODO: see whether this extra hack can be removed once we start # requiring Autoconf 2.70 or later. case $CONFIG_FILES in #( *\'*) : eval set x "$CONFIG_FILES" ;; #( *) : set x $CONFIG_FILES ;; #( *) : ;; esac shift # Used to flag and report bootstrapping failures. am_rc=0 for am_mf do # Strip MF so we end up with the name of the file. am_mf=`printf "%s\n" "$am_mf" | sed -e 's/:.*$//'` # Check whether this is an Automake generated Makefile which includes # dependency-tracking related rules and includes. # Grep'ing the whole file directly is not great: AIX grep has a line # limit of 2048, but all sed's we know have understand at least 4000. sed -n 's,^am--depfiles:.*,X,p' "$am_mf" | grep X >/dev/null 2>&1 \ || continue am_dirpart=`$as_dirname -- "$am_mf" || $as_expr X"$am_mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$am_mf" : 'X\(//\)[^/]' \| \ X"$am_mf" : 'X\(//\)$' \| \ X"$am_mf" : 'X\(/\)' \| . 2>/dev/null || printf "%s\n" X"$am_mf" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` am_filepart=`$as_basename -- "$am_mf" || $as_expr X/"$am_mf" : '.*/\([^/][^/]*\)/*$' \| \ X"$am_mf" : 'X\(//\)$' \| \ X"$am_mf" : 'X\(/\)' \| . 2>/dev/null || printf "%s\n" X/"$am_mf" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q } /^X\/\(\/\/\)$/{ s//\1/ q } /^X\/\(\/\).*/{ s//\1/ q } s/.*/./; q'` { echo "$as_me:$LINENO: cd "$am_dirpart" \ && sed -e '/# am--include-marker/d' "$am_filepart" \ | $MAKE -f - am--depfiles" >&5 (cd "$am_dirpart" \ && sed -e '/# am--include-marker/d' "$am_filepart" \ | $MAKE -f - am--depfiles) >&5 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } || am_rc=$? done if test $am_rc -ne 0; then { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "Something went wrong bootstrapping makefile fragments for automatic dependency tracking. If GNU make was not used, consider re-running the configure script with MAKE=\"gmake\" (or whatever is necessary). You can also try re-running configure with the '--disable-dependency-tracking' option to at least be able to build the package (albeit without support for automatic dependency tracking). See \`config.log' for more details" "$LINENO" 5; } fi { am_dirpart=; unset am_dirpart;} { am_filepart=; unset am_filepart;} { am_mf=; unset am_mf;} { am_rc=; unset am_rc;} rm -f conftest-deps.mk } ;; "libtool":C) # See if we are running on zsh, and set the options that allow our # commands through without removal of \ escapes. if test -n "${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi cfgfile=${ofile}T trap "$RM \"$cfgfile\"; exit 1" 1 2 15 $RM "$cfgfile" cat <<_LT_EOF >> "$cfgfile" #! $SHELL # Generated automatically by $as_me ($PACKAGE) $VERSION # NOTE: Changes made to this file will be lost: look at ltmain.sh. # Provide generalized library-building support services. # Written by Gordon Matzigkeit, 1996 # Copyright (C) 2014 Free Software Foundation, Inc. # This is free software; see the source for copying conditions. There is NO # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. # GNU Libtool is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of of the License, or # (at your option) any later version. # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program or library that is built # using GNU Libtool, you may include this file under the same # distribution terms that you use for the rest of that program. # # GNU Libtool is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see . # The names of the tagged configurations supported by this script. available_tags='' # Configured defaults for sys_lib_dlsearch_path munging. : \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"} # ### BEGIN LIBTOOL CONFIG # Which release of libtool.m4 was used? macro_version=$macro_version macro_revision=$macro_revision # Whether or not to build shared libraries. build_libtool_libs=$enable_shared # Whether or not to build static libraries. build_old_libs=$enable_static # What type of objects to build. pic_mode=$pic_mode # Whether or not to optimize for fast installation. fast_install=$enable_fast_install # Shared archive member basename,for filename based shared library versioning on AIX. shared_archive_member_spec=$shared_archive_member_spec # Shell to use when invoking shell scripts. SHELL=$lt_SHELL # An echo program that protects backslashes. ECHO=$lt_ECHO # The PATH separator for the build system. PATH_SEPARATOR=$lt_PATH_SEPARATOR # The host system. host_alias=$host_alias host=$host host_os=$host_os # The build system. build_alias=$build_alias build=$build build_os=$build_os # A sed program that does not truncate output. SED=$lt_SED # Sed that helps us avoid accidentally triggering echo(1) options like -n. Xsed="\$SED -e 1s/^X//" # A grep program that handles long lines. GREP=$lt_GREP # An ERE matcher. EGREP=$lt_EGREP # A literal string matcher. FGREP=$lt_FGREP # A BSD- or MS-compatible name lister. NM=$lt_NM # Whether we need soft or hard links. LN_S=$lt_LN_S # What is the maximum length of a command? max_cmd_len=$max_cmd_len # Object file suffix (normally "o"). objext=$ac_objext # Executable file suffix (normally ""). exeext=$exeext # whether the shell understands "unset". lt_unset=$lt_unset # turn spaces into newlines. SP2NL=$lt_lt_SP2NL # turn newlines into spaces. NL2SP=$lt_lt_NL2SP # convert \$build file names to \$host format. to_host_file_cmd=$lt_cv_to_host_file_cmd # convert \$build files to toolchain format. to_tool_file_cmd=$lt_cv_to_tool_file_cmd # A file(cmd) program that detects file types. FILECMD=$lt_FILECMD # An object symbol dumper. OBJDUMP=$lt_OBJDUMP # Method to check whether dependent libraries are shared objects. deplibs_check_method=$lt_deplibs_check_method # Command to use when deplibs_check_method = "file_magic". file_magic_cmd=$lt_file_magic_cmd # How to find potential files when deplibs_check_method = "file_magic". file_magic_glob=$lt_file_magic_glob # Find potential files using nocaseglob when deplibs_check_method = "file_magic". want_nocaseglob=$lt_want_nocaseglob # DLL creation program. DLLTOOL=$lt_DLLTOOL # Command to associate shared and link libraries. sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd # The archiver. AR=$lt_AR # Flags to create an archive (by configure). lt_ar_flags=$lt_ar_flags # Flags to create an archive. AR_FLAGS=\${ARFLAGS-"\$lt_ar_flags"} # How to feed a file listing to the archiver. archiver_list_spec=$lt_archiver_list_spec # A symbol stripping program. STRIP=$lt_STRIP # Commands used to install an old-style archive. RANLIB=$lt_RANLIB old_postinstall_cmds=$lt_old_postinstall_cmds old_postuninstall_cmds=$lt_old_postuninstall_cmds # Whether to use a lock for old archive extraction. lock_old_archive_extraction=$lock_old_archive_extraction # A C compiler. LTCC=$lt_CC # LTCC compiler flags. LTCFLAGS=$lt_CFLAGS # Take the output of nm and produce a listing of raw symbols and C names. global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe # Transform the output of nm in a proper C declaration. global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl # Transform the output of nm into a list of symbols to manually relocate. global_symbol_to_import=$lt_lt_cv_sys_global_symbol_to_import # Transform the output of nm in a C name address pair. global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address # Transform the output of nm in a C name address pair when lib prefix is needed. global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix # The name lister interface. nm_interface=$lt_lt_cv_nm_interface # Specify filename containing input files for \$NM. nm_file_list_spec=$lt_nm_file_list_spec # The root where to search for dependent libraries,and where our libraries should be installed. lt_sysroot=$lt_sysroot # Command to truncate a binary pipe. lt_truncate_bin=$lt_lt_cv_truncate_bin # The name of the directory that contains temporary libtool files. objdir=$objdir # Used to examine libraries when file_magic_cmd begins with "file". MAGIC_CMD=$MAGIC_CMD # Must we lock files when doing compilation? need_locks=$lt_need_locks # Manifest tool. MANIFEST_TOOL=$lt_MANIFEST_TOOL # Tool to manipulate archived DWARF debug symbol files on Mac OS X. DSYMUTIL=$lt_DSYMUTIL # Tool to change global to local symbols on Mac OS X. NMEDIT=$lt_NMEDIT # Tool to manipulate fat objects and archives on Mac OS X. LIPO=$lt_LIPO # ldd/readelf like tool for Mach-O binaries on Mac OS X. OTOOL=$lt_OTOOL # ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4. OTOOL64=$lt_OTOOL64 # Old archive suffix (normally "a"). libext=$libext # Shared library suffix (normally ".so"). shrext_cmds=$lt_shrext_cmds # The commands to extract the exported symbol list from a shared archive. extract_expsyms_cmds=$lt_extract_expsyms_cmds # Variables whose values should be saved in libtool wrapper scripts and # restored at link time. variables_saved_for_relink=$lt_variables_saved_for_relink # Do we need the "lib" prefix for modules? need_lib_prefix=$need_lib_prefix # Do we need a version for libraries? need_version=$need_version # Library versioning type. version_type=$version_type # Shared library runtime path variable. runpath_var=$runpath_var # Shared library path variable. shlibpath_var=$shlibpath_var # Is shlibpath searched before the hard-coded library search path? shlibpath_overrides_runpath=$shlibpath_overrides_runpath # Format of library name prefix. libname_spec=$lt_libname_spec # List of archive names. First name is the real one, the rest are links. # The last name is the one that the linker finds with -lNAME library_names_spec=$lt_library_names_spec # The coded name of the library, if different from the real name. soname_spec=$lt_soname_spec # Permission mode override for installation of shared libraries. install_override_mode=$lt_install_override_mode # Command to use after installation of a shared archive. postinstall_cmds=$lt_postinstall_cmds # Command to use after uninstallation of a shared archive. postuninstall_cmds=$lt_postuninstall_cmds # Commands used to finish a libtool library installation in a directory. finish_cmds=$lt_finish_cmds # As "finish_cmds", except a single script fragment to be evaled but # not shown. finish_eval=$lt_finish_eval # Whether we should hardcode library paths into libraries. hardcode_into_libs=$hardcode_into_libs # Compile-time system search path for libraries. sys_lib_search_path_spec=$lt_sys_lib_search_path_spec # Detected run-time system search path for libraries. sys_lib_dlsearch_path_spec=$lt_configure_time_dlsearch_path # Explicit LT_SYS_LIBRARY_PATH set during ./configure time. configure_time_lt_sys_library_path=$lt_configure_time_lt_sys_library_path # Whether dlopen is supported. dlopen_support=$enable_dlopen # Whether dlopen of programs is supported. dlopen_self=$enable_dlopen_self # Whether dlopen of statically linked programs is supported. dlopen_self_static=$enable_dlopen_self_static # Commands to strip libraries. old_striplib=$lt_old_striplib striplib=$lt_striplib # The linker used to build libraries. LD=$lt_LD # How to create reloadable object files. reload_flag=$lt_reload_flag reload_cmds=$lt_reload_cmds # Commands used to build an old-style archive. old_archive_cmds=$lt_old_archive_cmds # A language specific compiler. CC=$lt_compiler # Is the compiler the GNU compiler? with_gcc=$GCC # Compiler flag to turn off builtin functions. no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag # Additional compiler flags for building library objects. pic_flag=$lt_lt_prog_compiler_pic # How to pass a linker flag through the compiler. wl=$lt_lt_prog_compiler_wl # Compiler flag to prevent dynamic linking. link_static_flag=$lt_lt_prog_compiler_static # Does compiler simultaneously support -c and -o options? compiler_c_o=$lt_lt_cv_prog_compiler_c_o # Whether or not to add -lc for building shared libraries. build_libtool_need_lc=$archive_cmds_need_lc # Whether or not to disallow shared libs when runtime libs are static. allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes # Compiler flag to allow reflexive dlopens. export_dynamic_flag_spec=$lt_export_dynamic_flag_spec # Compiler flag to generate shared objects directly from archives. whole_archive_flag_spec=$lt_whole_archive_flag_spec # Whether the compiler copes with passing no objects directly. compiler_needs_object=$lt_compiler_needs_object # Create an old-style archive from a shared archive. old_archive_from_new_cmds=$lt_old_archive_from_new_cmds # Create a temporary old-style archive to link instead of a shared archive. old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds # Commands used to build a shared archive. archive_cmds=$lt_archive_cmds archive_expsym_cmds=$lt_archive_expsym_cmds # Commands used to build a loadable module if different from building # a shared archive. module_cmds=$lt_module_cmds module_expsym_cmds=$lt_module_expsym_cmds # Whether we are building with GNU ld or not. with_gnu_ld=$lt_with_gnu_ld # Flag that allows shared libraries with undefined symbols to be built. allow_undefined_flag=$lt_allow_undefined_flag # Flag that enforces no undefined symbols. no_undefined_flag=$lt_no_undefined_flag # Flag to hardcode \$libdir into a binary during linking. # This must work even if \$libdir does not exist hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec # Whether we need a single "-rpath" flag with a separated argument. hardcode_libdir_separator=$lt_hardcode_libdir_separator # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes # DIR into the resulting binary. hardcode_direct=$hardcode_direct # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes # DIR into the resulting binary and the resulting library dependency is # "absolute",i.e impossible to change by setting \$shlibpath_var if the # library is relocated. hardcode_direct_absolute=$hardcode_direct_absolute # Set to "yes" if using the -LDIR flag during linking hardcodes DIR # into the resulting binary. hardcode_minus_L=$hardcode_minus_L # Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR # into the resulting binary. hardcode_shlibpath_var=$hardcode_shlibpath_var # Set to "yes" if building a shared library automatically hardcodes DIR # into the library and all subsequent libraries and executables linked # against it. hardcode_automatic=$hardcode_automatic # Set to yes if linker adds runtime paths of dependent libraries # to runtime path list. inherit_rpath=$inherit_rpath # Whether libtool must link a program against all its dependency libraries. link_all_deplibs=$link_all_deplibs # Set to "yes" if exported symbols are required. always_export_symbols=$always_export_symbols # The commands to list exported symbols. export_symbols_cmds=$lt_export_symbols_cmds # Symbols that should not be listed in the preloaded symbols. exclude_expsyms=$lt_exclude_expsyms # Symbols that must always be exported. include_expsyms=$lt_include_expsyms # Commands necessary for linking programs (against libraries) with templates. prelink_cmds=$lt_prelink_cmds # Commands necessary for finishing linking programs. postlink_cmds=$lt_postlink_cmds # Specify filename containing input files. file_list_spec=$lt_file_list_spec # How to hardcode a shared library path into an executable. hardcode_action=$hardcode_action # ### END LIBTOOL CONFIG _LT_EOF cat <<'_LT_EOF' >> "$cfgfile" # ### BEGIN FUNCTIONS SHARED WITH CONFIGURE # func_munge_path_list VARIABLE PATH # ----------------------------------- # VARIABLE is name of variable containing _space_ separated list of # directories to be munged by the contents of PATH, which is string # having a format: # "DIR[:DIR]:" # string "DIR[ DIR]" will be prepended to VARIABLE # ":DIR[:DIR]" # string "DIR[ DIR]" will be appended to VARIABLE # "DIRP[:DIRP]::[DIRA:]DIRA" # string "DIRP[ DIRP]" will be prepended to VARIABLE and string # "DIRA[ DIRA]" will be appended to VARIABLE # "DIR[:DIR]" # VARIABLE will be replaced by "DIR[ DIR]" func_munge_path_list () { case x$2 in x) ;; *:) eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\" ;; x:*) eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\" ;; *::*) eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\" eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\" ;; *) eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\" ;; esac } # Calculate cc_basename. Skip known compiler wrappers and cross-prefix. func_cc_basename () { for cc_temp in $*""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; \-*) ;; *) break;; esac done func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` } # ### END FUNCTIONS SHARED WITH CONFIGURE _LT_EOF case $host_os in aix3*) cat <<\_LT_EOF >> "$cfgfile" # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. if test set != "${COLLECT_NAMES+set}"; then COLLECT_NAMES= export COLLECT_NAMES fi _LT_EOF ;; esac ltmain=$ac_aux_dir/ltmain.sh # We use sed instead of cat because bash on DJGPP gets confused if # if finds mixed CR/LF and LF-only lines. Since sed operates in # text mode, it properly converts lines to CR/LF. This bash problem # is reportedly fixed, but why not run on old versions too? $SED '$q' "$ltmain" >> "$cfgfile" \ || (rm -f "$cfgfile"; exit 1) mv -f "$cfgfile" "$ofile" || (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") chmod +x "$ofile" ;; esac done # for ac_tag as_fn_exit 0 _ACEOF ac_clean_files=$ac_clean_files_save test $ac_write_fail = 0 || as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 # configure is writing to config.log, and then calls config.status. # config.status does its own redirection, appending to config.log. # Unfortunately, on DOS this fails, as config.log is still kept open # by configure, so config.status won't be able to write to it; its # output is simply discarded. So we exec the FD to /dev/null, # effectively closing config.log, so it can be properly (re)opened and # appended to by config.status. When coming back to configure, we # need to make the FD available again. if test "$no_create" != yes; then ac_cs_success=: ac_config_status_args= test "$silent" = yes && ac_config_status_args="$ac_config_status_args --quiet" exec 5>/dev/null $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false exec 5>>config.log # Use ||, not &&, to avoid exiting from the if with $? = 1, which # would make configure fail if this is the last instruction. $ac_cs_success || as_fn_exit 1 fi if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 printf "%s\n" "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} fi httrack-3.49.5/Makefile.am0000644000175000017500000000031214336470674012243 00000000000000 SUBDIRS = src man m4 libtest templates lang html tests ACLOCAL_AMFLAGS = -I m4 EXTRA_DIST = INSTALL.Linux \ gpl-fr.txt license.txt greetings.txt history.txt \ httrack-doc.html lang.def README.md httrack-3.49.5/m4/0000755000175000017500000000000014555203177010606 500000000000000httrack-3.49.5/m4/Makefile.in0000644000175000017500000003103414555203173012570 00000000000000# Makefile.in generated by automake 1.16.5 from Makefile.am. # @configure_input@ # Copyright (C) 1994-2021 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ VPATH = @srcdir@ am__is_gnu_make = { \ if test -z '$(MAKELEVEL)'; then \ false; \ elif test -n '$(MAKE_HOST)'; then \ true; \ elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ true; \ else \ false; \ fi; \ } am__make_running_with_option = \ case $${target_option-} in \ ?) ;; \ *) echo "am__make_running_with_option: internal error: invalid" \ "target option '$${target_option-}' specified" >&2; \ exit 1;; \ esac; \ has_opt=no; \ sane_makeflags=$$MAKEFLAGS; \ if $(am__is_gnu_make); then \ sane_makeflags=$$MFLAGS; \ else \ case $$MAKEFLAGS in \ *\\[\ \ ]*) \ bs=\\; \ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ esac; \ fi; \ skip_next=no; \ strip_trailopt () \ { \ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ }; \ for flg in $$sane_makeflags; do \ test $$skip_next = yes && { skip_next=no; continue; }; \ case $$flg in \ *=*|--*) continue;; \ -*I) strip_trailopt 'I'; skip_next=yes;; \ -*I?*) strip_trailopt 'I';; \ -*O) strip_trailopt 'O'; skip_next=yes;; \ -*O?*) strip_trailopt 'O';; \ -*l) strip_trailopt 'l'; skip_next=yes;; \ -*l?*) strip_trailopt 'l';; \ -[dEDm]) skip_next=yes;; \ -[JT]) skip_next=yes;; \ esac; \ case $$flg in \ *$$target_option*) has_opt=yes; break;; \ esac; \ done; \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkglibexecdir = $(libexecdir)/@PACKAGE@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ subdir = m4 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/check_zlib.m4 \ $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/snprintf.m4 \ $(top_srcdir)/m4/visibility.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = AM_V_P = $(am__v_P_@AM_V@) am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) am__v_P_0 = false am__v_P_1 = : AM_V_GEN = $(am__v_GEN_@AM_V@) am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) am__v_GEN_0 = @echo " GEN " $@; am__v_GEN_1 = AM_V_at = $(am__v_at_@AM_V@) am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) am__v_at_0 = @ am__v_at_1 = SOURCES = DIST_SOURCES = am__can_run_installinfo = \ case $$AM_UPDATE_INFO_DIR in \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) am__DIST_COMMON = $(srcdir)/Makefile.in DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AM_CFLAGS = @AM_CFLAGS@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CFLAGS_PIE = @CFLAGS_PIE@ CFLAG_VISIBILITY = @CFLAG_VISIBILITY@ CPPFLAGS = @CPPFLAGS@ CSCOPE = @CSCOPE@ CTAGS = @CTAGS@ CYGPATH_W = @CYGPATH_W@ DEFAULT_CFLAGS = @DEFAULT_CFLAGS@ DEFAULT_LDFLAGS = @DEFAULT_LDFLAGS@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DLLTOOL = @DLLTOOL@ DL_LIBS = @DL_LIBS@ DSYMUTIL = @DSYMUTIL@ DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ ETAGS = @ETAGS@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ FILECMD = @FILECMD@ GREP = @GREP@ HAVE_VISIBILITY = @HAVE_VISIBILITY@ HTTPS_SUPPORT = @HTTPS_SUPPORT@ ICONV_LIBS = @ICONV_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LD = @LD@ LDFLAGS = @LDFLAGS@ LDFLAGS_PIE = @LDFLAGS_PIE@ LFS_FLAG = @LFS_FLAG@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ LIPO = @LIPO@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ LT_CV_OBJDIR = @LT_CV_OBJDIR@ LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ MAINT = @MAINT@ MAKEINFO = @MAKEINFO@ MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ NM = @NM@ NMEDIT = @NMEDIT@ OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ ONLINE_UNIT_TESTS = @ONLINE_UNIT_TESTS@ OPENSSL_LIBS = @OPENSSL_LIBS@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ RANLIB = @RANLIB@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ SHLIBPATH_VAR = @SHLIBPATH_VAR@ SOCKET_LIBS = @SOCKET_LIBS@ STRIP = @STRIP@ THREADS_CFLAGS = @THREADS_CFLAGS@ THREADS_LIBS = @THREADS_LIBS@ V6_FLAG = @V6_FLAG@ VERSION = @VERSION@ VERSION_INFO = @VERSION_INFO@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ builddir = @builddir@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ runstatedir = @runstatedir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ EXTRA_DIST = *.m4 all: all-am .SUFFIXES: $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ && { if test -f $@; then exit 0; else break; fi; }; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu m4/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --gnu m4/Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(am__aclocal_m4_deps): mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs tags TAGS: ctags CTAGS: cscope cscopelist: distdir: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) distdir-am distdir-am: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ dist_files=`for file in $$list; do echo $$file; done | \ sed -e "s|^$$srcdirstrip/||;t" \ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ case $$dist_files in \ */*) $(MKDIR_P) `echo "$$dist_files" | \ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ sort -u` ;; \ esac; \ for file in $$dist_files; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ if test -d $$d/$$file; then \ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ if test -d "$(distdir)/$$file"; then \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ else \ test -f "$(distdir)/$$file" \ || cp -p $$d/$$file "$(distdir)/$$file" \ || exit 1; \ fi; \ done check-am: all-am check: check-am all-am: Makefile installdirs: install: install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-am install-strip: if test -z '$(STRIP)'; then \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ install; \ else \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ fi mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-generic clean-libtool mostlyclean-am distclean: distclean-am -rm -f Makefile distclean-am: clean-am distclean-generic dvi: dvi-am dvi-am: html: html-am html-am: info: info-am info-am: install-data-am: install-dvi: install-dvi-am install-dvi-am: install-exec-am: install-html: install-html-am install-html-am: install-info: install-info-am install-info-am: install-man: install-pdf: install-pdf-am install-pdf-am: install-ps: install-ps-am install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-am -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-generic mostlyclean-libtool pdf: pdf-am pdf-am: ps: ps-am ps-am: uninstall-am: .MAKE: install-am install-strip .PHONY: all all-am check check-am clean clean-generic clean-libtool \ cscopelist-am ctags-am distclean distclean-generic \ distclean-libtool distdir dvi dvi-am html html-am info info-am \ install install-am install-data install-data-am install-dvi \ install-dvi-am install-exec install-exec-am install-html \ install-html-am install-info install-info-am install-man \ install-pdf install-pdf-am install-ps install-ps-am \ install-strip installcheck installcheck-am installdirs \ maintainer-clean maintainer-clean-generic mostlyclean \ mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ tags-am uninstall uninstall-am .PRECIOUS: Makefile # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: httrack-3.49.5/m4/Makefile.am0000644000175000017500000000002214336470674012561 00000000000000EXTRA_DIST = *.m4 httrack-3.49.5/m4/visibility.m40000644000175000017500000000662214360750617013165 00000000000000# visibility.m4 serial 8 dnl Copyright (C) 2005, 2008, 2010-2023 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, dnl with or without modifications, as long as this notice is preserved. dnl From Bruno Haible. dnl Tests whether the compiler supports the command-line option dnl -fvisibility=hidden and the function and variable attributes dnl __attribute__((__visibility__("hidden"))) and dnl __attribute__((__visibility__("default"))). dnl Does *not* test for __visibility__("protected") - which has tricky dnl semantics (see the 'vismain' test in glibc) and does not exist e.g. on dnl Mac OS X. dnl Does *not* test for __visibility__("internal") - which has processor dnl dependent semantics. dnl Does *not* test for #pragma GCC visibility push(hidden) - which is dnl "really only recommended for legacy code". dnl Set the variable CFLAG_VISIBILITY. dnl Defines and sets the variable HAVE_VISIBILITY. AC_DEFUN([gl_VISIBILITY], [ AC_REQUIRE([AC_PROG_CC]) CFLAG_VISIBILITY= HAVE_VISIBILITY=0 if test -n "$GCC"; then dnl First, check whether -Werror can be added to the command line, or dnl whether it leads to an error because of some other option that the dnl user has put into $CC $CFLAGS $CPPFLAGS. AC_CACHE_CHECK([whether the -Werror option is usable], [gl_cv_cc_vis_werror], [gl_save_CFLAGS="$CFLAGS" CFLAGS="$CFLAGS -Werror" AC_COMPILE_IFELSE( [AC_LANG_PROGRAM([[]], [[]])], [gl_cv_cc_vis_werror=yes], [gl_cv_cc_vis_werror=no]) CFLAGS="$gl_save_CFLAGS" ]) dnl Now check whether visibility declarations are supported. AC_CACHE_CHECK([for simple visibility declarations], [gl_cv_cc_visibility], [gl_save_CFLAGS="$CFLAGS" CFLAGS="$CFLAGS -fvisibility=hidden" dnl We use the option -Werror and a function dummyfunc, because on some dnl platforms (Cygwin 1.7) the use of -fvisibility triggers a warning dnl "visibility attribute not supported in this configuration; ignored" dnl at the first function definition in every compilation unit, and we dnl don't want to use the option in this case. if test $gl_cv_cc_vis_werror = yes; then CFLAGS="$CFLAGS -Werror" fi AC_COMPILE_IFELSE( [AC_LANG_PROGRAM( [[extern __attribute__((__visibility__("hidden"))) int hiddenvar; extern __attribute__((__visibility__("default"))) int exportedvar; extern __attribute__((__visibility__("hidden"))) int hiddenfunc (void); extern __attribute__((__visibility__("default"))) int exportedfunc (void); void dummyfunc (void); int hiddenvar; int exportedvar; int hiddenfunc (void) { return 51; } int exportedfunc (void) { return 1225736919; } void dummyfunc (void) {} ]], [[]])], [gl_cv_cc_visibility=yes], [gl_cv_cc_visibility=no]) CFLAGS="$gl_save_CFLAGS" ]) if test $gl_cv_cc_visibility = yes; then CFLAG_VISIBILITY="-fvisibility=hidden" HAVE_VISIBILITY=1 fi fi AC_SUBST([CFLAG_VISIBILITY]) AC_SUBST([HAVE_VISIBILITY]) AC_DEFINE_UNQUOTED([HAVE_VISIBILITY], [$HAVE_VISIBILITY], [Define to 1 or 0, depending whether the compiler supports simple visibility declarations.]) ]) httrack-3.49.5/m4/snprintf.m40000644000175000017500000000360114526163071012627 00000000000000AC_DEFUN([AC_FUNC_SNPRINTF], [AC_CHECK_FUNCS(snprintf vsnprintf) AC_MSG_CHECKING(for working snprintf) AC_CACHE_VAL(ac_cv_have_working_snprintf, [AC_TRY_RUN( [#include #include #include int main(void) { char bufs[5] = { 'x', 'x', 'x', '\0', '\0' }; char bufd[5] = { 'x', 'x', 'x', '\0', '\0' }; int i; i = snprintf (bufs, 2, "%s", "111"); if (strcmp (bufs, "1")) exit (1); if (i != 3) exit (1); i = snprintf (bufd, 2, "%d", 111); if (strcmp (bufd, "1")) exit (1); if (i != 3) exit (1); exit(0); }], ac_cv_have_working_snprintf=yes, ac_cv_have_working_snprintf=no, ac_cv_have_working_snprintf=cross)]) AC_MSG_RESULT([$ac_cv_have_working_snprintf]) AC_MSG_CHECKING(for working vsnprintf) AC_CACHE_VAL(ac_cv_have_working_vsnprintf, [AC_TRY_RUN( [#include #include #include #include int my_vsnprintf (char *buf, const char *tmpl, ...) { int i; va_list args; va_start (args, tmpl); i = vsnprintf (buf, 2, tmpl, args); va_end (args); return i; } int main(void) { char bufs[5] = { 'x', 'x', 'x', '\0', '\0' }; char bufd[5] = { 'x', 'x', 'x', '\0', '\0' }; int i; i = my_vsnprintf (bufs, "%s", "111"); if (strcmp (bufs, "1")) exit (1); if (i != 3) exit (1); i = my_vsnprintf (bufd, "%d", 111); if (strcmp (bufd, "1")) exit (1); if (i != 3) exit (1); exit(0); }], ac_cv_have_working_vsnprintf=yes, ac_cv_have_working_vsnprintf=no, ac_cv_have_working_vsnprintf=cross)]) AC_MSG_RESULT([$ac_cv_have_working_vsnprintf]) if test x$ac_cv_have_working_snprintf$ac_cv_have_working_vsnprintf != "xyesyes"; then AC_LIBOBJ(snprintf) AC_MSG_WARN([Replacing missing/broken (v)snprintf() with version from http://www.ijs.si/software/snprintf/.]) AC_DEFINE(PREFER_PORTABLE_SNPRINTF, 1, "enable replacement (v)snprintf if system (v)snprintf is broken") fi]) httrack-3.49.5/m4/lt~obsolete.m40000644000175000017500000001400714555203162013336 00000000000000# lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*- # # Copyright (C) 2004-2005, 2007, 2009, 2011-2019, 2021-2022 Free # Software Foundation, Inc. # Written by Scott James Remnant, 2004. # # This file is free software; the Free Software Foundation gives # unlimited permission to copy and/or distribute it, with or without # modifications, as long as this notice is preserved. # serial 5 lt~obsolete.m4 # These exist entirely to fool aclocal when bootstrapping libtool. # # In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN), # which have later been changed to m4_define as they aren't part of the # exported API, or moved to Autoconf or Automake where they belong. # # The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN # in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us # using a macro with the same name in our local m4/libtool.m4 it'll # pull the old libtool.m4 in (it doesn't see our shiny new m4_define # and doesn't know about Autoconf macros at all.) # # So we provide this file, which has a silly filename so it's always # included after everything else. This provides aclocal with the # AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything # because those macros already exist, or will be overwritten later. # We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6. # # Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here. # Yes, that means every name once taken will need to remain here until # we give up compatibility with versions before 1.7, at which point # we need to keep only those names which we still refer to. # This is to help aclocal find these macros, as it can't see m4_define. AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])]) m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])]) m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])]) m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])]) m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])]) m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])]) m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])]) m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])]) m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])]) m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])]) m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])]) m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])]) m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])]) m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])]) m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])]) m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])]) m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])]) m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])]) m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])]) m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])]) m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])]) m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])]) m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])]) m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])]) m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])]) m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])]) m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])]) m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])]) m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])]) m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])]) m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])]) m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])]) m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])]) m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])]) m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])]) m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])]) m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])]) m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])]) m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])]) m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])]) m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])]) m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])]) m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])]) m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])]) m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])]) m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])]) m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])]) m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])]) m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])]) m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])]) m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])]) m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])]) m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])]) m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])]) m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])]) m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])]) m4_ifndef([_LT_AC_PROG_CXXCPP], [AC_DEFUN([_LT_AC_PROG_CXXCPP])]) m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])]) m4_ifndef([_LT_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])]) m4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])]) m4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])]) m4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])]) httrack-3.49.5/m4/ltversion.m40000644000175000017500000000131214555203162013004 00000000000000# ltversion.m4 -- version numbers -*- Autoconf -*- # # Copyright (C) 2004, 2011-2019, 2021-2022 Free Software Foundation, # Inc. # Written by Scott James Remnant, 2004 # # This file is free software; the Free Software Foundation gives # unlimited permission to copy and/or distribute it, with or without # modifications, as long as this notice is preserved. # @configure_input@ # serial 4245 ltversion.m4 # This file is part of GNU Libtool m4_define([LT_PACKAGE_VERSION], [2.4.7]) m4_define([LT_PACKAGE_REVISION], [2.4.7]) AC_DEFUN([LTVERSION_VERSION], [macro_version='2.4.7' macro_revision='2.4.7' _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) _LT_DECL(, macro_revision, 0) ]) httrack-3.49.5/m4/ltsugar.m40000644000175000017500000001045314555203162012446 00000000000000# ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*- # # Copyright (C) 2004-2005, 2007-2008, 2011-2019, 2021-2022 Free Software # Foundation, Inc. # Written by Gary V. Vaughan, 2004 # # This file is free software; the Free Software Foundation gives # unlimited permission to copy and/or distribute it, with or without # modifications, as long as this notice is preserved. # serial 6 ltsugar.m4 # This is to help aclocal find these macros, as it can't see m4_define. AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])]) # lt_join(SEP, ARG1, [ARG2...]) # ----------------------------- # Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their # associated separator. # Needed until we can rely on m4_join from Autoconf 2.62, since all earlier # versions in m4sugar had bugs. m4_define([lt_join], [m4_if([$#], [1], [], [$#], [2], [[$2]], [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])]) m4_define([_lt_join], [m4_if([$#$2], [2], [], [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])]) # lt_car(LIST) # lt_cdr(LIST) # ------------ # Manipulate m4 lists. # These macros are necessary as long as will still need to support # Autoconf-2.59, which quotes differently. m4_define([lt_car], [[$1]]) m4_define([lt_cdr], [m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])], [$#], 1, [], [m4_dquote(m4_shift($@))])]) m4_define([lt_unquote], $1) # lt_append(MACRO-NAME, STRING, [SEPARATOR]) # ------------------------------------------ # Redefine MACRO-NAME to hold its former content plus 'SEPARATOR''STRING'. # Note that neither SEPARATOR nor STRING are expanded; they are appended # to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked). # No SEPARATOR is output if MACRO-NAME was previously undefined (different # than defined and empty). # # This macro is needed until we can rely on Autoconf 2.62, since earlier # versions of m4sugar mistakenly expanded SEPARATOR but not STRING. m4_define([lt_append], [m4_define([$1], m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])]) # lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...]) # ---------------------------------------------------------- # Produce a SEP delimited list of all paired combinations of elements of # PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list # has the form PREFIXmINFIXSUFFIXn. # Needed until we can rely on m4_combine added in Autoconf 2.62. m4_define([lt_combine], [m4_if(m4_eval([$# > 3]), [1], [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl [[m4_foreach([_Lt_prefix], [$2], [m4_foreach([_Lt_suffix], ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[, [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])]) # lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ]) # ----------------------------------------------------------------------- # Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited # by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ. m4_define([lt_if_append_uniq], [m4_ifdef([$1], [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1], [lt_append([$1], [$2], [$3])$4], [$5])], [lt_append([$1], [$2], [$3])$4])]) # lt_dict_add(DICT, KEY, VALUE) # ----------------------------- m4_define([lt_dict_add], [m4_define([$1($2)], [$3])]) # lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE) # -------------------------------------------- m4_define([lt_dict_add_subkey], [m4_define([$1($2:$3)], [$4])]) # lt_dict_fetch(DICT, KEY, [SUBKEY]) # ---------------------------------- m4_define([lt_dict_fetch], [m4_ifval([$3], m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]), m4_ifdef([$1($2)], [m4_defn([$1($2)])]))]) # lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE]) # ----------------------------------------------------------------- m4_define([lt_if_dict_fetch], [m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4], [$5], [$6])]) # lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...]) # -------------------------------------------------------------- m4_define([lt_dict_filter], [m4_if([$5], [], [], [lt_join(m4_quote(m4_default([$4], [[, ]])), lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]), [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl ]) httrack-3.49.5/m4/ltoptions.m40000644000175000017500000003427514555203162013030 00000000000000# Helper functions for option handling. -*- Autoconf -*- # # Copyright (C) 2004-2005, 2007-2009, 2011-2019, 2021-2022 Free # Software Foundation, Inc. # Written by Gary V. Vaughan, 2004 # # This file is free software; the Free Software Foundation gives # unlimited permission to copy and/or distribute it, with or without # modifications, as long as this notice is preserved. # serial 8 ltoptions.m4 # This is to help aclocal find these macros, as it can't see m4_define. AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])]) # _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME) # ------------------------------------------ m4_define([_LT_MANGLE_OPTION], [[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])]) # _LT_SET_OPTION(MACRO-NAME, OPTION-NAME) # --------------------------------------- # Set option OPTION-NAME for macro MACRO-NAME, and if there is a # matching handler defined, dispatch to it. Other OPTION-NAMEs are # saved as a flag. m4_define([_LT_SET_OPTION], [m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]), _LT_MANGLE_DEFUN([$1], [$2]), [m4_warning([Unknown $1 option '$2'])])[]dnl ]) # _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET]) # ------------------------------------------------------------ # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. m4_define([_LT_IF_OPTION], [m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])]) # _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET) # ------------------------------------------------------- # Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME # are set. m4_define([_LT_UNLESS_OPTIONS], [m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option), [m4_define([$0_found])])])[]dnl m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3 ])[]dnl ]) # _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST) # ---------------------------------------- # OPTION-LIST is a space-separated list of Libtool options associated # with MACRO-NAME. If any OPTION has a matching handler declared with # LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about # the unknown option and exit. m4_defun([_LT_SET_OPTIONS], [# Set options m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), [_LT_SET_OPTION([$1], _LT_Option)]) m4_if([$1],[LT_INIT],[ dnl dnl Simply set some default values (i.e off) if boolean options were not dnl specified: _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no ]) _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no ]) dnl dnl If no reference was made to various pairs of opposing options, then dnl we run the default mode handler for the pair. For example, if neither dnl 'shared' nor 'disable-shared' was passed, we enable building of shared dnl archives by default: _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED]) _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC]) _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC]) _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install], [_LT_ENABLE_FAST_INSTALL]) _LT_UNLESS_OPTIONS([LT_INIT], [aix-soname=aix aix-soname=both aix-soname=svr4], [_LT_WITH_AIX_SONAME([aix])]) ]) ])# _LT_SET_OPTIONS ## --------------------------------- ## ## Macros to handle LT_INIT options. ## ## --------------------------------- ## # _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME) # ----------------------------------------- m4_define([_LT_MANGLE_DEFUN], [[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])]) # LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE) # ----------------------------------------------- m4_define([LT_OPTION_DEFINE], [m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl ])# LT_OPTION_DEFINE # dlopen # ------ LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes ]) AU_DEFUN([AC_LIBTOOL_DLOPEN], [_LT_SET_OPTION([LT_INIT], [dlopen]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you put the 'dlopen' option into LT_INIT's first parameter.]) ]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], []) # win32-dll # --------- # Declare package support for building win32 dll's. LT_OPTION_DEFINE([LT_INIT], [win32-dll], [enable_win32_dll=yes case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*) AC_CHECK_TOOL(AS, as, false) AC_CHECK_TOOL(DLLTOOL, dlltool, false) AC_CHECK_TOOL(OBJDUMP, objdump, false) ;; esac test -z "$AS" && AS=as _LT_DECL([], [AS], [1], [Assembler program])dnl test -z "$DLLTOOL" && DLLTOOL=dlltool _LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl test -z "$OBJDUMP" && OBJDUMP=objdump _LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl ])# win32-dll AU_DEFUN([AC_LIBTOOL_WIN32_DLL], [AC_REQUIRE([AC_CANONICAL_HOST])dnl _LT_SET_OPTION([LT_INIT], [win32-dll]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you put the 'win32-dll' option into LT_INIT's first parameter.]) ]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], []) # _LT_ENABLE_SHARED([DEFAULT]) # ---------------------------- # implement the --enable-shared flag, and supports the 'shared' and # 'disable-shared' LT_INIT options. # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. m4_define([_LT_ENABLE_SHARED], [m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl AC_ARG_ENABLE([shared], [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@], [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])], [p=${PACKAGE-default} case $enableval in yes) enable_shared=yes ;; no) enable_shared=no ;; *) enable_shared=no # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_shared=yes fi done IFS=$lt_save_ifs ;; esac], [enable_shared=]_LT_ENABLE_SHARED_DEFAULT) _LT_DECL([build_libtool_libs], [enable_shared], [0], [Whether or not to build shared libraries]) ])# _LT_ENABLE_SHARED LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])]) LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])]) # Old names: AC_DEFUN([AC_ENABLE_SHARED], [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared]) ]) AC_DEFUN([AC_DISABLE_SHARED], [_LT_SET_OPTION([LT_INIT], [disable-shared]) ]) AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AM_ENABLE_SHARED], []) dnl AC_DEFUN([AM_DISABLE_SHARED], []) # _LT_ENABLE_STATIC([DEFAULT]) # ---------------------------- # implement the --enable-static flag, and support the 'static' and # 'disable-static' LT_INIT options. # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. m4_define([_LT_ENABLE_STATIC], [m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl AC_ARG_ENABLE([static], [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@], [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])], [p=${PACKAGE-default} case $enableval in yes) enable_static=yes ;; no) enable_static=no ;; *) enable_static=no # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_static=yes fi done IFS=$lt_save_ifs ;; esac], [enable_static=]_LT_ENABLE_STATIC_DEFAULT) _LT_DECL([build_old_libs], [enable_static], [0], [Whether or not to build static libraries]) ])# _LT_ENABLE_STATIC LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])]) LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])]) # Old names: AC_DEFUN([AC_ENABLE_STATIC], [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static]) ]) AC_DEFUN([AC_DISABLE_STATIC], [_LT_SET_OPTION([LT_INIT], [disable-static]) ]) AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AM_ENABLE_STATIC], []) dnl AC_DEFUN([AM_DISABLE_STATIC], []) # _LT_ENABLE_FAST_INSTALL([DEFAULT]) # ---------------------------------- # implement the --enable-fast-install flag, and support the 'fast-install' # and 'disable-fast-install' LT_INIT options. # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. m4_define([_LT_ENABLE_FAST_INSTALL], [m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl AC_ARG_ENABLE([fast-install], [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], [p=${PACKAGE-default} case $enableval in yes) enable_fast_install=yes ;; no) enable_fast_install=no ;; *) enable_fast_install=no # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_fast_install=yes fi done IFS=$lt_save_ifs ;; esac], [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT) _LT_DECL([fast_install], [enable_fast_install], [0], [Whether or not to optimize for fast installation])dnl ])# _LT_ENABLE_FAST_INSTALL LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])]) LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])]) # Old names: AU_DEFUN([AC_ENABLE_FAST_INSTALL], [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you put the 'fast-install' option into LT_INIT's first parameter.]) ]) AU_DEFUN([AC_DISABLE_FAST_INSTALL], [_LT_SET_OPTION([LT_INIT], [disable-fast-install]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you put the 'disable-fast-install' option into LT_INIT's first parameter.]) ]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], []) dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], []) # _LT_WITH_AIX_SONAME([DEFAULT]) # ---------------------------------- # implement the --with-aix-soname flag, and support the `aix-soname=aix' # and `aix-soname=both' and `aix-soname=svr4' LT_INIT options. DEFAULT # is either `aix', `both' or `svr4'. If omitted, it defaults to `aix'. m4_define([_LT_WITH_AIX_SONAME], [m4_define([_LT_WITH_AIX_SONAME_DEFAULT], [m4_if($1, svr4, svr4, m4_if($1, both, both, aix))])dnl shared_archive_member_spec= case $host,$enable_shared in power*-*-aix[[5-9]]*,yes) AC_MSG_CHECKING([which variant of shared library versioning to provide]) AC_ARG_WITH([aix-soname], [AS_HELP_STRING([--with-aix-soname=aix|svr4|both], [shared library versioning (aka "SONAME") variant to provide on AIX, @<:@default=]_LT_WITH_AIX_SONAME_DEFAULT[@:>@.])], [case $withval in aix|svr4|both) ;; *) AC_MSG_ERROR([Unknown argument to --with-aix-soname]) ;; esac lt_cv_with_aix_soname=$with_aix_soname], [AC_CACHE_VAL([lt_cv_with_aix_soname], [lt_cv_with_aix_soname=]_LT_WITH_AIX_SONAME_DEFAULT) with_aix_soname=$lt_cv_with_aix_soname]) AC_MSG_RESULT([$with_aix_soname]) if test aix != "$with_aix_soname"; then # For the AIX way of multilib, we name the shared archive member # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o', # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File. # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag, # the AIX toolchain works better with OBJECT_MODE set (default 32). if test 64 = "${OBJECT_MODE-32}"; then shared_archive_member_spec=shr_64 else shared_archive_member_spec=shr fi fi ;; *) with_aix_soname=aix ;; esac _LT_DECL([], [shared_archive_member_spec], [0], [Shared archive member basename, for filename based shared library versioning on AIX])dnl ])# _LT_WITH_AIX_SONAME LT_OPTION_DEFINE([LT_INIT], [aix-soname=aix], [_LT_WITH_AIX_SONAME([aix])]) LT_OPTION_DEFINE([LT_INIT], [aix-soname=both], [_LT_WITH_AIX_SONAME([both])]) LT_OPTION_DEFINE([LT_INIT], [aix-soname=svr4], [_LT_WITH_AIX_SONAME([svr4])]) # _LT_WITH_PIC([MODE]) # -------------------- # implement the --with-pic flag, and support the 'pic-only' and 'no-pic' # LT_INIT options. # MODE is either 'yes' or 'no'. If omitted, it defaults to 'both'. m4_define([_LT_WITH_PIC], [AC_ARG_WITH([pic], [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@], [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], [lt_p=${PACKAGE-default} case $withval in yes|no) pic_mode=$withval ;; *) pic_mode=default # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for lt_pkg in $withval; do IFS=$lt_save_ifs if test "X$lt_pkg" = "X$lt_p"; then pic_mode=yes fi done IFS=$lt_save_ifs ;; esac], [pic_mode=m4_default([$1], [default])]) _LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl ])# _LT_WITH_PIC LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])]) LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])]) # Old name: AU_DEFUN([AC_LIBTOOL_PICMODE], [_LT_SET_OPTION([LT_INIT], [pic-only]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you put the 'pic-only' option into LT_INIT's first parameter.]) ]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_PICMODE], []) ## ----------------- ## ## LTDL_INIT Options ## ## ----------------- ## m4_define([_LTDL_MODE], []) LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive], [m4_define([_LTDL_MODE], [nonrecursive])]) LT_OPTION_DEFINE([LTDL_INIT], [recursive], [m4_define([_LTDL_MODE], [recursive])]) LT_OPTION_DEFINE([LTDL_INIT], [subproject], [m4_define([_LTDL_MODE], [subproject])]) m4_define([_LTDL_TYPE], []) LT_OPTION_DEFINE([LTDL_INIT], [installable], [m4_define([_LTDL_TYPE], [installable])]) LT_OPTION_DEFINE([LTDL_INIT], [convenience], [m4_define([_LTDL_TYPE], [convenience])]) httrack-3.49.5/m4/libtool.m40000644000175000017500000113165214555203162012437 00000000000000# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- # # Copyright (C) 1996-2001, 2003-2019, 2021-2022 Free Software # Foundation, Inc. # Written by Gordon Matzigkeit, 1996 # # This file is free software; the Free Software Foundation gives # unlimited permission to copy and/or distribute it, with or without # modifications, as long as this notice is preserved. m4_define([_LT_COPYING], [dnl # Copyright (C) 2014 Free Software Foundation, Inc. # This is free software; see the source for copying conditions. There is NO # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. # GNU Libtool is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of of the License, or # (at your option) any later version. # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program or library that is built # using GNU Libtool, you may include this file under the same # distribution terms that you use for the rest of that program. # # GNU Libtool is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see . ]) # serial 59 LT_INIT # LT_PREREQ(VERSION) # ------------------ # Complain and exit if this libtool version is less that VERSION. m4_defun([LT_PREREQ], [m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1, [m4_default([$3], [m4_fatal([Libtool version $1 or higher is required], 63)])], [$2])]) # _LT_CHECK_BUILDDIR # ------------------ # Complain if the absolute build directory name contains unusual characters m4_defun([_LT_CHECK_BUILDDIR], [case `pwd` in *\ * | *\ *) AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;; esac ]) # LT_INIT([OPTIONS]) # ------------------ AC_DEFUN([LT_INIT], [AC_PREREQ([2.62])dnl We use AC_PATH_PROGS_FEATURE_CHECK AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl AC_BEFORE([$0], [LT_LANG])dnl AC_BEFORE([$0], [LT_OUTPUT])dnl AC_BEFORE([$0], [LTDL_INIT])dnl m4_require([_LT_CHECK_BUILDDIR])dnl dnl Autoconf doesn't catch unexpanded LT_ macros by default: m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4 dnl unless we require an AC_DEFUNed macro: AC_REQUIRE([LTOPTIONS_VERSION])dnl AC_REQUIRE([LTSUGAR_VERSION])dnl AC_REQUIRE([LTVERSION_VERSION])dnl AC_REQUIRE([LTOBSOLETE_VERSION])dnl m4_require([_LT_PROG_LTMAIN])dnl _LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}]) dnl Parse OPTIONS _LT_SET_OPTIONS([$0], [$1]) # This can be used to rebuild libtool when needed LIBTOOL_DEPS=$ltmain # Always use our own libtool. LIBTOOL='$(SHELL) $(top_builddir)/libtool' AC_SUBST(LIBTOOL)dnl _LT_SETUP # Only expand once: m4_define([LT_INIT]) ])# LT_INIT # Old names: AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT]) AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_PROG_LIBTOOL], []) dnl AC_DEFUN([AM_PROG_LIBTOOL], []) # _LT_PREPARE_CC_BASENAME # ----------------------- m4_defun([_LT_PREPARE_CC_BASENAME], [ # Calculate cc_basename. Skip known compiler wrappers and cross-prefix. func_cc_basename () { for cc_temp in @S|@*""; do case $cc_temp in compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; \-*) ;; *) break;; esac done func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` } ])# _LT_PREPARE_CC_BASENAME # _LT_CC_BASENAME(CC) # ------------------- # It would be clearer to call AC_REQUIREs from _LT_PREPARE_CC_BASENAME, # but that macro is also expanded into generated libtool script, which # arranges for $SED and $ECHO to be set by different means. m4_defun([_LT_CC_BASENAME], [m4_require([_LT_PREPARE_CC_BASENAME])dnl AC_REQUIRE([_LT_DECL_SED])dnl AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl func_cc_basename $1 cc_basename=$func_cc_basename_result ]) # _LT_FILEUTILS_DEFAULTS # ---------------------- # It is okay to use these file commands and assume they have been set # sensibly after 'm4_require([_LT_FILEUTILS_DEFAULTS])'. m4_defun([_LT_FILEUTILS_DEFAULTS], [: ${CP="cp -f"} : ${MV="mv -f"} : ${RM="rm -f"} ])# _LT_FILEUTILS_DEFAULTS # _LT_SETUP # --------- m4_defun([_LT_SETUP], [AC_REQUIRE([AC_CANONICAL_HOST])dnl AC_REQUIRE([AC_CANONICAL_BUILD])dnl AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl _LT_DECL([], [PATH_SEPARATOR], [1], [The PATH separator for the build system])dnl dnl _LT_DECL([], [host_alias], [0], [The host system])dnl _LT_DECL([], [host], [0])dnl _LT_DECL([], [host_os], [0])dnl dnl _LT_DECL([], [build_alias], [0], [The build system])dnl _LT_DECL([], [build], [0])dnl _LT_DECL([], [build_os], [0])dnl dnl AC_REQUIRE([AC_PROG_CC])dnl AC_REQUIRE([LT_PATH_LD])dnl AC_REQUIRE([LT_PATH_NM])dnl dnl AC_REQUIRE([AC_PROG_LN_S])dnl test -z "$LN_S" && LN_S="ln -s" _LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl dnl AC_REQUIRE([LT_CMD_MAX_LEN])dnl _LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl _LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl dnl m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_CHECK_SHELL_FEATURES])dnl m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl m4_require([_LT_CMD_RELOAD])dnl m4_require([_LT_DECL_FILECMD])dnl m4_require([_LT_CHECK_MAGIC_METHOD])dnl m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl m4_require([_LT_CMD_OLD_ARCHIVE])dnl m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl m4_require([_LT_WITH_SYSROOT])dnl m4_require([_LT_CMD_TRUNCATE])dnl _LT_CONFIG_LIBTOOL_INIT([ # See if we are running on zsh, and set the options that allow our # commands through without removal of \ escapes INIT. if test -n "\${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi ]) if test -n "${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi _LT_CHECK_OBJDIR m4_require([_LT_TAG_COMPILER])dnl case $host_os in aix3*) # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. if test set != "${COLLECT_NAMES+set}"; then COLLECT_NAMES= export COLLECT_NAMES fi ;; esac # Global variables: ofile=libtool can_build_shared=yes # All known linkers require a '.a' archive for static linking (except MSVC and # ICC, which need '.lib'). libext=a with_gnu_ld=$lt_cv_prog_gnu_ld old_CC=$CC old_CFLAGS=$CFLAGS # Set sane defaults for various variables test -z "$CC" && CC=cc test -z "$LTCC" && LTCC=$CC test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS test -z "$LD" && LD=ld test -z "$ac_objext" && ac_objext=o _LT_CC_BASENAME([$compiler]) # Only perform the check for file, if the check method requires it test -z "$MAGIC_CMD" && MAGIC_CMD=file case $deplibs_check_method in file_magic*) if test "$file_magic_cmd" = '$MAGIC_CMD'; then _LT_PATH_MAGIC fi ;; esac # Use C for the default configuration in the libtool script LT_SUPPORTED_TAG([CC]) _LT_LANG_C_CONFIG _LT_LANG_DEFAULT_CONFIG _LT_CONFIG_COMMANDS ])# _LT_SETUP # _LT_PREPARE_SED_QUOTE_VARS # -------------------------- # Define a few sed substitution that help us do robust quoting. m4_defun([_LT_PREPARE_SED_QUOTE_VARS], [# Backslashify metacharacters that are still active within # double-quoted strings. sed_quote_subst='s/\([["`$\\]]\)/\\\1/g' # Same as above, but do not quote variable references. double_quote_subst='s/\([["`\\]]\)/\\\1/g' # Sed substitution to delay expansion of an escaped shell variable in a # double_quote_subst'ed string. delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' # Sed substitution to delay expansion of an escaped single quote. delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' # Sed substitution to avoid accidental globbing in evaled expressions no_glob_subst='s/\*/\\\*/g' ]) # _LT_PROG_LTMAIN # --------------- # Note that this code is called both from 'configure', and 'config.status' # now that we use AC_CONFIG_COMMANDS to generate libtool. Notably, # 'config.status' has no value for ac_aux_dir unless we are using Automake, # so we pass a copy along to make sure it has a sensible value anyway. m4_defun([_LT_PROG_LTMAIN], [m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl _LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir']) ltmain=$ac_aux_dir/ltmain.sh ])# _LT_PROG_LTMAIN ## ------------------------------------- ## ## Accumulate code for creating libtool. ## ## ------------------------------------- ## # So that we can recreate a full libtool script including additional # tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS # in macros and then make a single call at the end using the 'libtool' # label. # _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS]) # ---------------------------------------- # Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later. m4_define([_LT_CONFIG_LIBTOOL_INIT], [m4_ifval([$1], [m4_append([_LT_OUTPUT_LIBTOOL_INIT], [$1 ])])]) # Initialize. m4_define([_LT_OUTPUT_LIBTOOL_INIT]) # _LT_CONFIG_LIBTOOL([COMMANDS]) # ------------------------------ # Register COMMANDS to be passed to AC_CONFIG_COMMANDS later. m4_define([_LT_CONFIG_LIBTOOL], [m4_ifval([$1], [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS], [$1 ])])]) # Initialize. m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS]) # _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS]) # ----------------------------------------------------- m4_defun([_LT_CONFIG_SAVE_COMMANDS], [_LT_CONFIG_LIBTOOL([$1]) _LT_CONFIG_LIBTOOL_INIT([$2]) ]) # _LT_FORMAT_COMMENT([COMMENT]) # ----------------------------- # Add leading comment marks to the start of each line, and a trailing # full-stop to the whole comment if one is not present already. m4_define([_LT_FORMAT_COMMENT], [m4_ifval([$1], [ m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])], [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.]) )]) ## ------------------------ ## ## FIXME: Eliminate VARNAME ## ## ------------------------ ## # _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?]) # ------------------------------------------------------------------- # CONFIGNAME is the name given to the value in the libtool script. # VARNAME is the (base) name used in the configure script. # VALUE may be 0, 1 or 2 for a computed quote escaped value based on # VARNAME. Any other value will be used directly. m4_define([_LT_DECL], [lt_if_append_uniq([lt_decl_varnames], [$2], [, ], [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name], [m4_ifval([$1], [$1], [$2])]) lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3]) m4_ifval([$4], [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])]) lt_dict_add_subkey([lt_decl_dict], [$2], [tagged?], [m4_ifval([$5], [yes], [no])])]) ]) # _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION]) # -------------------------------------------------------- m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])]) # lt_decl_tag_varnames([SEPARATOR], [VARNAME1...]) # ------------------------------------------------ m4_define([lt_decl_tag_varnames], [_lt_decl_filter([tagged?], [yes], $@)]) # _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..]) # --------------------------------------------------------- m4_define([_lt_decl_filter], [m4_case([$#], [0], [m4_fatal([$0: too few arguments: $#])], [1], [m4_fatal([$0: too few arguments: $#: $1])], [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)], [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)], [lt_dict_filter([lt_decl_dict], $@)])[]dnl ]) # lt_decl_quote_varnames([SEPARATOR], [VARNAME1...]) # -------------------------------------------------- m4_define([lt_decl_quote_varnames], [_lt_decl_filter([value], [1], $@)]) # lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...]) # --------------------------------------------------- m4_define([lt_decl_dquote_varnames], [_lt_decl_filter([value], [2], $@)]) # lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...]) # --------------------------------------------------- m4_define([lt_decl_varnames_tagged], [m4_assert([$# <= 2])dnl _$0(m4_quote(m4_default([$1], [[, ]])), m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]), m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))]) m4_define([_lt_decl_varnames_tagged], [m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])]) # lt_decl_all_varnames([SEPARATOR], [VARNAME1...]) # ------------------------------------------------ m4_define([lt_decl_all_varnames], [_$0(m4_quote(m4_default([$1], [[, ]])), m4_if([$2], [], m4_quote(lt_decl_varnames), m4_quote(m4_shift($@))))[]dnl ]) m4_define([_lt_decl_all_varnames], [lt_join($@, lt_decl_varnames_tagged([$1], lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl ]) # _LT_CONFIG_STATUS_DECLARE([VARNAME]) # ------------------------------------ # Quote a variable value, and forward it to 'config.status' so that its # declaration there will have the same value as in 'configure'. VARNAME # must have a single quote delimited value for this to work. m4_define([_LT_CONFIG_STATUS_DECLARE], [$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`']) # _LT_CONFIG_STATUS_DECLARATIONS # ------------------------------ # We delimit libtool config variables with single quotes, so when # we write them to config.status, we have to be sure to quote all # embedded single quotes properly. In configure, this macro expands # each variable declared with _LT_DECL (and _LT_TAGDECL) into: # # ='`$ECHO "$" | $SED "$delay_single_quote_subst"`' m4_defun([_LT_CONFIG_STATUS_DECLARATIONS], [m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames), [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])]) # _LT_LIBTOOL_TAGS # ---------------- # Output comment and list of tags supported by the script m4_defun([_LT_LIBTOOL_TAGS], [_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl available_tags='_LT_TAGS'dnl ]) # _LT_LIBTOOL_DECLARE(VARNAME, [TAG]) # ----------------------------------- # Extract the dictionary values for VARNAME (optionally with TAG) and # expand to a commented shell variable setting: # # # Some comment about what VAR is for. # visible_name=$lt_internal_name m4_define([_LT_LIBTOOL_DECLARE], [_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [description])))[]dnl m4_pushdef([_libtool_name], m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])), [0], [_libtool_name=[$]$1], [1], [_libtool_name=$lt_[]$1], [2], [_libtool_name=$lt_[]$1], [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl ]) # _LT_LIBTOOL_CONFIG_VARS # ----------------------- # Produce commented declarations of non-tagged libtool config variables # suitable for insertion in the LIBTOOL CONFIG section of the 'libtool' # script. Tagged libtool config variables (even for the LIBTOOL CONFIG # section) are produced by _LT_LIBTOOL_TAG_VARS. m4_defun([_LT_LIBTOOL_CONFIG_VARS], [m4_foreach([_lt_var], m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)), [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])]) # _LT_LIBTOOL_TAG_VARS(TAG) # ------------------------- m4_define([_LT_LIBTOOL_TAG_VARS], [m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames), [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])]) # _LT_TAGVAR(VARNAME, [TAGNAME]) # ------------------------------ m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])]) # _LT_CONFIG_COMMANDS # ------------------- # Send accumulated output to $CONFIG_STATUS. Thanks to the lists of # variables for single and double quote escaping we saved from calls # to _LT_DECL, we can put quote escaped variables declarations # into 'config.status', and then the shell code to quote escape them in # for loops in 'config.status'. Finally, any additional code accumulated # from calls to _LT_CONFIG_LIBTOOL_INIT is expanded. m4_defun([_LT_CONFIG_COMMANDS], [AC_PROVIDE_IFELSE([LT_OUTPUT], dnl If the libtool generation code has been placed in $CONFIG_LT, dnl instead of duplicating it all over again into config.status, dnl then we will have config.status run $CONFIG_LT later, so it dnl needs to know what name is stored there: [AC_CONFIG_COMMANDS([libtool], [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])], dnl If the libtool generation code is destined for config.status, dnl expand the accumulated commands and init code now: [AC_CONFIG_COMMANDS([libtool], [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])]) ])#_LT_CONFIG_COMMANDS # Initialize. m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT], [ # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH sed_quote_subst='$sed_quote_subst' double_quote_subst='$double_quote_subst' delay_variable_subst='$delay_variable_subst' _LT_CONFIG_STATUS_DECLARATIONS LTCC='$LTCC' LTCFLAGS='$LTCFLAGS' compiler='$compiler_DEFAULT' # A function that is used when there is no print builtin or printf. func_fallback_echo () { eval 'cat <<_LTECHO_EOF \$[]1 _LTECHO_EOF' } # Quote evaled strings. for var in lt_decl_all_varnames([[ \ ]], lt_decl_quote_varnames); do case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in *[[\\\\\\\`\\"\\\$]]*) eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes ;; *) eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" ;; esac done # Double-quote double-evaled strings. for var in lt_decl_all_varnames([[ \ ]], lt_decl_dquote_varnames); do case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in *[[\\\\\\\`\\"\\\$]]*) eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes ;; *) eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" ;; esac done _LT_OUTPUT_LIBTOOL_INIT ]) # _LT_GENERATED_FILE_INIT(FILE, [COMMENT]) # ------------------------------------ # Generate a child script FILE with all initialization necessary to # reuse the environment learned by the parent script, and make the # file executable. If COMMENT is supplied, it is inserted after the # '#!' sequence but before initialization text begins. After this # macro, additional text can be appended to FILE to form the body of # the child script. The macro ends with non-zero status if the # file could not be fully written (such as if the disk is full). m4_ifdef([AS_INIT_GENERATED], [m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])], [m4_defun([_LT_GENERATED_FILE_INIT], [m4_require([AS_PREPARE])]dnl [m4_pushdef([AS_MESSAGE_LOG_FD])]dnl [lt_write_fail=0 cat >$1 <<_ASEOF || lt_write_fail=1 #! $SHELL # Generated by $as_me. $2 SHELL=\${CONFIG_SHELL-$SHELL} export SHELL _ASEOF cat >>$1 <<\_ASEOF || lt_write_fail=1 AS_SHELL_SANITIZE _AS_PREPARE exec AS_MESSAGE_FD>&1 _ASEOF test 0 = "$lt_write_fail" && chmod +x $1[]dnl m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT # LT_OUTPUT # --------- # This macro allows early generation of the libtool script (before # AC_OUTPUT is called), incase it is used in configure for compilation # tests. AC_DEFUN([LT_OUTPUT], [: ${CONFIG_LT=./config.lt} AC_MSG_NOTICE([creating $CONFIG_LT]) _LT_GENERATED_FILE_INIT(["$CONFIG_LT"], [# Run this file to recreate a libtool stub with the current configuration.]) cat >>"$CONFIG_LT" <<\_LTEOF lt_cl_silent=false exec AS_MESSAGE_LOG_FD>>config.log { echo AS_BOX([Running $as_me.]) } >&AS_MESSAGE_LOG_FD lt_cl_help="\ '$as_me' creates a local libtool stub from the current configuration, for use in further configure time tests before the real libtool is generated. Usage: $[0] [[OPTIONS]] -h, --help print this help, then exit -V, --version print version number, then exit -q, --quiet do not print progress messages -d, --debug don't remove temporary files Report bugs to ." lt_cl_version="\ m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION]) configured by $[0], generated by m4_PACKAGE_STRING. Copyright (C) 2011 Free Software Foundation, Inc. This config.lt script is free software; the Free Software Foundation gives unlimited permision to copy, distribute and modify it." while test 0 != $[#] do case $[1] in --version | --v* | -V ) echo "$lt_cl_version"; exit 0 ;; --help | --h* | -h ) echo "$lt_cl_help"; exit 0 ;; --debug | --d* | -d ) debug=: ;; --quiet | --q* | --silent | --s* | -q ) lt_cl_silent=: ;; -*) AC_MSG_ERROR([unrecognized option: $[1] Try '$[0] --help' for more information.]) ;; *) AC_MSG_ERROR([unrecognized argument: $[1] Try '$[0] --help' for more information.]) ;; esac shift done if $lt_cl_silent; then exec AS_MESSAGE_FD>/dev/null fi _LTEOF cat >>"$CONFIG_LT" <<_LTEOF _LT_OUTPUT_LIBTOOL_COMMANDS_INIT _LTEOF cat >>"$CONFIG_LT" <<\_LTEOF AC_MSG_NOTICE([creating $ofile]) _LT_OUTPUT_LIBTOOL_COMMANDS AS_EXIT(0) _LTEOF chmod +x "$CONFIG_LT" # configure is writing to config.log, but config.lt does its own redirection, # appending to config.log, which fails on DOS, as config.log is still kept # open by configure. Here we exec the FD to /dev/null, effectively closing # config.log, so it can be properly (re)opened and appended to by config.lt. lt_cl_success=: test yes = "$silent" && lt_config_lt_args="$lt_config_lt_args --quiet" exec AS_MESSAGE_LOG_FD>/dev/null $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false exec AS_MESSAGE_LOG_FD>>config.log $lt_cl_success || AS_EXIT(1) ])# LT_OUTPUT # _LT_CONFIG(TAG) # --------------- # If TAG is the built-in tag, create an initial libtool script with a # default configuration from the untagged config vars. Otherwise add code # to config.status for appending the configuration named by TAG from the # matching tagged config vars. m4_defun([_LT_CONFIG], [m4_require([_LT_FILEUTILS_DEFAULTS])dnl _LT_CONFIG_SAVE_COMMANDS([ m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl m4_if(_LT_TAG, [C], [ # See if we are running on zsh, and set the options that allow our # commands through without removal of \ escapes. if test -n "${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi cfgfile=${ofile}T trap "$RM \"$cfgfile\"; exit 1" 1 2 15 $RM "$cfgfile" cat <<_LT_EOF >> "$cfgfile" #! $SHELL # Generated automatically by $as_me ($PACKAGE) $VERSION # NOTE: Changes made to this file will be lost: look at ltmain.sh. # Provide generalized library-building support services. # Written by Gordon Matzigkeit, 1996 _LT_COPYING _LT_LIBTOOL_TAGS # Configured defaults for sys_lib_dlsearch_path munging. : \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"} # ### BEGIN LIBTOOL CONFIG _LT_LIBTOOL_CONFIG_VARS _LT_LIBTOOL_TAG_VARS # ### END LIBTOOL CONFIG _LT_EOF cat <<'_LT_EOF' >> "$cfgfile" # ### BEGIN FUNCTIONS SHARED WITH CONFIGURE _LT_PREPARE_MUNGE_PATH_LIST _LT_PREPARE_CC_BASENAME # ### END FUNCTIONS SHARED WITH CONFIGURE _LT_EOF case $host_os in aix3*) cat <<\_LT_EOF >> "$cfgfile" # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. if test set != "${COLLECT_NAMES+set}"; then COLLECT_NAMES= export COLLECT_NAMES fi _LT_EOF ;; esac _LT_PROG_LTMAIN # We use sed instead of cat because bash on DJGPP gets confused if # if finds mixed CR/LF and LF-only lines. Since sed operates in # text mode, it properly converts lines to CR/LF. This bash problem # is reportedly fixed, but why not run on old versions too? $SED '$q' "$ltmain" >> "$cfgfile" \ || (rm -f "$cfgfile"; exit 1) mv -f "$cfgfile" "$ofile" || (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") chmod +x "$ofile" ], [cat <<_LT_EOF >> "$ofile" dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded dnl in a comment (ie after a #). # ### BEGIN LIBTOOL TAG CONFIG: $1 _LT_LIBTOOL_TAG_VARS(_LT_TAG) # ### END LIBTOOL TAG CONFIG: $1 _LT_EOF ])dnl /m4_if ], [m4_if([$1], [], [ PACKAGE='$PACKAGE' VERSION='$VERSION' RM='$RM' ofile='$ofile'], []) ])dnl /_LT_CONFIG_SAVE_COMMANDS ])# _LT_CONFIG # LT_SUPPORTED_TAG(TAG) # --------------------- # Trace this macro to discover what tags are supported by the libtool # --tag option, using: # autoconf --trace 'LT_SUPPORTED_TAG:$1' AC_DEFUN([LT_SUPPORTED_TAG], []) # C support is built-in for now m4_define([_LT_LANG_C_enabled], []) m4_define([_LT_TAGS], []) # LT_LANG(LANG) # ------------- # Enable libtool support for the given language if not already enabled. AC_DEFUN([LT_LANG], [AC_BEFORE([$0], [LT_OUTPUT])dnl m4_case([$1], [C], [_LT_LANG(C)], [C++], [_LT_LANG(CXX)], [Go], [_LT_LANG(GO)], [Java], [_LT_LANG(GCJ)], [Fortran 77], [_LT_LANG(F77)], [Fortran], [_LT_LANG(FC)], [Windows Resource], [_LT_LANG(RC)], [m4_ifdef([_LT_LANG_]$1[_CONFIG], [_LT_LANG($1)], [m4_fatal([$0: unsupported language: "$1"])])])dnl ])# LT_LANG # _LT_LANG(LANGNAME) # ------------------ m4_defun([_LT_LANG], [m4_ifdef([_LT_LANG_]$1[_enabled], [], [LT_SUPPORTED_TAG([$1])dnl m4_append([_LT_TAGS], [$1 ])dnl m4_define([_LT_LANG_]$1[_enabled], [])dnl _LT_LANG_$1_CONFIG($1)])dnl ])# _LT_LANG m4_ifndef([AC_PROG_GO], [ ############################################################ # NOTE: This macro has been submitted for inclusion into # # GNU Autoconf as AC_PROG_GO. When it is available in # # a released version of Autoconf we should remove this # # macro and use it instead. # ############################################################ m4_defun([AC_PROG_GO], [AC_LANG_PUSH(Go)dnl AC_ARG_VAR([GOC], [Go compiler command])dnl AC_ARG_VAR([GOFLAGS], [Go compiler flags])dnl _AC_ARG_VAR_LDFLAGS()dnl AC_CHECK_TOOL(GOC, gccgo) if test -z "$GOC"; then if test -n "$ac_tool_prefix"; then AC_CHECK_PROG(GOC, [${ac_tool_prefix}gccgo], [${ac_tool_prefix}gccgo]) fi fi if test -z "$GOC"; then AC_CHECK_PROG(GOC, gccgo, gccgo, false) fi ])#m4_defun ])#m4_ifndef # _LT_LANG_DEFAULT_CONFIG # ----------------------- m4_defun([_LT_LANG_DEFAULT_CONFIG], [AC_PROVIDE_IFELSE([AC_PROG_CXX], [LT_LANG(CXX)], [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])]) AC_PROVIDE_IFELSE([AC_PROG_F77], [LT_LANG(F77)], [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])]) AC_PROVIDE_IFELSE([AC_PROG_FC], [LT_LANG(FC)], [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])]) dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal dnl pulling things in needlessly. AC_PROVIDE_IFELSE([AC_PROG_GCJ], [LT_LANG(GCJ)], [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], [LT_LANG(GCJ)], [AC_PROVIDE_IFELSE([LT_PROG_GCJ], [LT_LANG(GCJ)], [m4_ifdef([AC_PROG_GCJ], [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])]) m4_ifdef([A][M_PROG_GCJ], [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])]) m4_ifdef([LT_PROG_GCJ], [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])]) AC_PROVIDE_IFELSE([AC_PROG_GO], [LT_LANG(GO)], [m4_define([AC_PROG_GO], defn([AC_PROG_GO])[LT_LANG(GO)])]) AC_PROVIDE_IFELSE([LT_PROG_RC], [LT_LANG(RC)], [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])]) ])# _LT_LANG_DEFAULT_CONFIG # Obsolete macros: AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)]) AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)]) AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)]) AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)]) AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_CXX], []) dnl AC_DEFUN([AC_LIBTOOL_F77], []) dnl AC_DEFUN([AC_LIBTOOL_FC], []) dnl AC_DEFUN([AC_LIBTOOL_GCJ], []) dnl AC_DEFUN([AC_LIBTOOL_RC], []) # _LT_TAG_COMPILER # ---------------- m4_defun([_LT_TAG_COMPILER], [AC_REQUIRE([AC_PROG_CC])dnl _LT_DECL([LTCC], [CC], [1], [A C compiler])dnl _LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl _LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl _LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC ])# _LT_TAG_COMPILER # _LT_COMPILER_BOILERPLATE # ------------------------ # Check for compiler boilerplate output or warnings with # the simple compiler test code. m4_defun([_LT_COMPILER_BOILERPLATE], [m4_require([_LT_DECL_SED])dnl ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" >conftest.$ac_ext eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_compiler_boilerplate=`cat conftest.err` $RM conftest* ])# _LT_COMPILER_BOILERPLATE # _LT_LINKER_BOILERPLATE # ---------------------- # Check for linker boilerplate output or warnings with # the simple link test code. m4_defun([_LT_LINKER_BOILERPLATE], [m4_require([_LT_DECL_SED])dnl ac_outfile=conftest.$ac_objext echo "$lt_simple_link_test_code" >conftest.$ac_ext eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_linker_boilerplate=`cat conftest.err` $RM -r conftest* ])# _LT_LINKER_BOILERPLATE # _LT_REQUIRED_DARWIN_CHECKS # ------------------------- m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ case $host_os in rhapsody* | darwin*) AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:]) AC_CHECK_TOOL([NMEDIT], [nmedit], [:]) AC_CHECK_TOOL([LIPO], [lipo], [:]) AC_CHECK_TOOL([OTOOL], [otool], [:]) AC_CHECK_TOOL([OTOOL64], [otool64], [:]) _LT_DECL([], [DSYMUTIL], [1], [Tool to manipulate archived DWARF debug symbol files on Mac OS X]) _LT_DECL([], [NMEDIT], [1], [Tool to change global to local symbols on Mac OS X]) _LT_DECL([], [LIPO], [1], [Tool to manipulate fat objects and archives on Mac OS X]) _LT_DECL([], [OTOOL], [1], [ldd/readelf like tool for Mach-O binaries on Mac OS X]) _LT_DECL([], [OTOOL64], [1], [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4]) AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], [lt_cv_apple_cc_single_mod=no if test -z "$LT_MULTI_MODULE"; then # By default we will add the -single_module flag. You can override # by either setting the environment variable LT_MULTI_MODULE # non-empty at configure time, or by adding -multi_module to the # link flags. rm -rf libconftest.dylib* echo "int foo(void){return 1;}" > conftest.c echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ -dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ -dynamiclib -Wl,-single_module conftest.c 2>conftest.err _lt_result=$? # If there is a non-empty error log, and "single_module" # appears in it, assume the flag caused a linker warning if test -s conftest.err && $GREP single_module conftest.err; then cat conftest.err >&AS_MESSAGE_LOG_FD # Otherwise, if the output was created with a 0 exit code from # the compiler, it worked. elif test -f libconftest.dylib && test 0 = "$_lt_result"; then lt_cv_apple_cc_single_mod=yes else cat conftest.err >&AS_MESSAGE_LOG_FD fi rm -rf libconftest.dylib* rm -f conftest.* fi]) AC_CACHE_CHECK([for -exported_symbols_list linker flag], [lt_cv_ld_exported_symbols_list], [lt_cv_ld_exported_symbols_list=no save_LDFLAGS=$LDFLAGS echo "_main" > conftest.sym LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], [lt_cv_ld_exported_symbols_list=yes], [lt_cv_ld_exported_symbols_list=no]) LDFLAGS=$save_LDFLAGS ]) AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load], [lt_cv_ld_force_load=no cat > conftest.c << _LT_EOF int forced_loaded() { return 2;} _LT_EOF echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD echo "$AR $AR_FLAGS libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD $AR $AR_FLAGS libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD cat > conftest.c << _LT_EOF int main() { return 0;} _LT_EOF echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err _lt_result=$? if test -s conftest.err && $GREP force_load conftest.err; then cat conftest.err >&AS_MESSAGE_LOG_FD elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then lt_cv_ld_force_load=yes else cat conftest.err >&AS_MESSAGE_LOG_FD fi rm -f conftest.err libconftest.a conftest conftest.c rm -rf conftest.dSYM ]) case $host_os in rhapsody* | darwin1.[[012]]) _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;; darwin1.*) _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; darwin*) case $MACOSX_DEPLOYMENT_TARGET,$host in 10.[[012]],*|,*powerpc*-darwin[[5-8]]*) _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; *) _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; esac ;; esac if test yes = "$lt_cv_apple_cc_single_mod"; then _lt_dar_single_mod='$single_module' fi if test yes = "$lt_cv_ld_exported_symbols_list"; then _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym' else _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib' fi if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then _lt_dsymutil='~$DSYMUTIL $lib || :' else _lt_dsymutil= fi ;; esac ]) # _LT_DARWIN_LINKER_FEATURES([TAG]) # --------------------------------- # Checks for linker and compiler features on darwin m4_defun([_LT_DARWIN_LINKER_FEATURES], [ m4_require([_LT_REQUIRED_DARWIN_CHECKS]) _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_automatic, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported if test yes = "$lt_cv_ld_force_load"; then _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes], [FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes]) else _LT_TAGVAR(whole_archive_flag_spec, $1)='' fi _LT_TAGVAR(link_all_deplibs, $1)=yes _LT_TAGVAR(allow_undefined_flag, $1)=$_lt_dar_allow_undefined case $cc_basename in ifort*|nagfor*) _lt_dar_can_shared=yes ;; *) _lt_dar_can_shared=$GCC ;; esac if test yes = "$_lt_dar_can_shared"; then output_verbose_link_cmd=func_echo_all _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil" _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" _LT_TAGVAR(archive_expsym_cmds, $1)="$SED 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" _LT_TAGVAR(module_expsym_cmds, $1)="$SED -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" m4_if([$1], [CXX], [ if test yes != "$lt_cv_apple_cc_single_mod"; then _LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dsymutil" _LT_TAGVAR(archive_expsym_cmds, $1)="$SED 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dar_export_syms$_lt_dsymutil" fi ],[]) else _LT_TAGVAR(ld_shlibs, $1)=no fi ]) # _LT_SYS_MODULE_PATH_AIX([TAGNAME]) # ---------------------------------- # Links a minimal program and checks the executable # for the system default hardcoded library path. In most cases, # this is /usr/lib:/lib, but when the MPI compilers are used # the location of the communication and MPI libs are included too. # If we don't find anything, use the default library path according # to the aix ld manual. # Store the results from the different compilers for each TAGNAME. # Allow to override them for all tags through lt_cv_aix_libpath. m4_defun([_LT_SYS_MODULE_PATH_AIX], [m4_require([_LT_DECL_SED])dnl if test set = "${lt_cv_aix_libpath+set}"; then aix_libpath=$lt_cv_aix_libpath else AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])], [AC_LINK_IFELSE([AC_LANG_PROGRAM],[ lt_aix_libpath_sed='[ /Import File Strings/,/^$/ { /^0/ { s/^0 *\([^ ]*\) *$/\1/ p } }]' _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi],[]) if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=/usr/lib:/lib fi ]) aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1]) fi ])# _LT_SYS_MODULE_PATH_AIX # _LT_SHELL_INIT(ARG) # ------------------- m4_define([_LT_SHELL_INIT], [m4_divert_text([M4SH-INIT], [$1 ])])# _LT_SHELL_INIT # _LT_PROG_ECHO_BACKSLASH # ----------------------- # Find how we can fake an echo command that does not interpret backslash. # In particular, with Autoconf 2.60 or later we add some code to the start # of the generated configure script that will find a shell with a builtin # printf (that we can use as an echo command). m4_defun([_LT_PROG_ECHO_BACKSLASH], [ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO AC_MSG_CHECKING([how to print strings]) # Test print first, because it will be a builtin if present. if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then ECHO='print -r --' elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then ECHO='printf %s\n' else # Use this function as a fallback that always works. func_fallback_echo () { eval 'cat <<_LTECHO_EOF $[]1 _LTECHO_EOF' } ECHO='func_fallback_echo' fi # func_echo_all arg... # Invoke $ECHO with all args, space-separated. func_echo_all () { $ECHO "$*" } case $ECHO in printf*) AC_MSG_RESULT([printf]) ;; print*) AC_MSG_RESULT([print -r]) ;; *) AC_MSG_RESULT([cat]) ;; esac m4_ifdef([_AS_DETECT_SUGGESTED], [_AS_DETECT_SUGGESTED([ test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || ( ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO PATH=/empty FPATH=/empty; export PATH FPATH test "X`printf %s $ECHO`" = "X$ECHO" \ || test "X`print -r -- $ECHO`" = "X$ECHO" )])]) _LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts]) _LT_DECL([], [ECHO], [1], [An echo program that protects backslashes]) ])# _LT_PROG_ECHO_BACKSLASH # _LT_WITH_SYSROOT # ---------------- AC_DEFUN([_LT_WITH_SYSROOT], [m4_require([_LT_DECL_SED])dnl AC_MSG_CHECKING([for sysroot]) AC_ARG_WITH([sysroot], [AS_HELP_STRING([--with-sysroot@<:@=DIR@:>@], [Search for dependent libraries within DIR (or the compiler's sysroot if not specified).])], [], [with_sysroot=no]) dnl lt_sysroot will always be passed unquoted. We quote it here dnl in case the user passed a directory name. lt_sysroot= case $with_sysroot in #( yes) if test yes = "$GCC"; then lt_sysroot=`$CC --print-sysroot 2>/dev/null` fi ;; #( /*) lt_sysroot=`echo "$with_sysroot" | $SED -e "$sed_quote_subst"` ;; #( no|'') ;; #( *) AC_MSG_RESULT([$with_sysroot]) AC_MSG_ERROR([The sysroot must be an absolute path.]) ;; esac AC_MSG_RESULT([${lt_sysroot:-no}]) _LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl [dependent libraries, and where our libraries should be installed.])]) # _LT_ENABLE_LOCK # --------------- m4_defun([_LT_ENABLE_LOCK], [AC_ARG_ENABLE([libtool-lock], [AS_HELP_STRING([--disable-libtool-lock], [avoid locking (might break parallel builds)])]) test no = "$enable_libtool_lock" || enable_libtool_lock=yes # Some flags need to be propagated to the compiler or linker for good # libtool support. case $host in ia64-*-hpux*) # Find out what ABI is being produced by ac_compile, and set mode # options accordingly. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then case `$FILECMD conftest.$ac_objext` in *ELF-32*) HPUX_IA64_MODE=32 ;; *ELF-64*) HPUX_IA64_MODE=64 ;; esac fi rm -rf conftest* ;; *-*-irix6*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then if test yes = "$lt_cv_prog_gnu_ld"; then case `$FILECMD conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -melf32bsmip" ;; *N32*) LD="${LD-ld} -melf32bmipn32" ;; *64-bit*) LD="${LD-ld} -melf64bmip" ;; esac else case `$FILECMD conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -32" ;; *N32*) LD="${LD-ld} -n32" ;; *64-bit*) LD="${LD-ld} -64" ;; esac fi fi rm -rf conftest* ;; mips64*-*linux*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then emul=elf case `$FILECMD conftest.$ac_objext` in *32-bit*) emul="${emul}32" ;; *64-bit*) emul="${emul}64" ;; esac case `$FILECMD conftest.$ac_objext` in *MSB*) emul="${emul}btsmip" ;; *LSB*) emul="${emul}ltsmip" ;; esac case `$FILECMD conftest.$ac_objext` in *N32*) emul="${emul}n32" ;; esac LD="${LD-ld} -m $emul" fi rm -rf conftest* ;; x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. Note that the listed cases only cover the # situations where additional linker options are needed (such as when # doing 32-bit compilation for a host where ld defaults to 64-bit, or # vice versa); the common cases where no linker options are needed do # not appear in the list. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then case `$FILECMD conftest.o` in *32-bit*) case $host in x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_i386_fbsd" ;; x86_64-*linux*) case `$FILECMD conftest.o` in *x86-64*) LD="${LD-ld} -m elf32_x86_64" ;; *) LD="${LD-ld} -m elf_i386" ;; esac ;; powerpc64le-*linux*) LD="${LD-ld} -m elf32lppclinux" ;; powerpc64-*linux*) LD="${LD-ld} -m elf32ppclinux" ;; s390x-*linux*) LD="${LD-ld} -m elf_s390" ;; sparc64-*linux*) LD="${LD-ld} -m elf32_sparc" ;; esac ;; *64-bit*) case $host in x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_x86_64_fbsd" ;; x86_64-*linux*) LD="${LD-ld} -m elf_x86_64" ;; powerpcle-*linux*) LD="${LD-ld} -m elf64lppc" ;; powerpc-*linux*) LD="${LD-ld} -m elf64ppc" ;; s390*-*linux*|s390*-*tpf*) LD="${LD-ld} -m elf64_s390" ;; sparc*-*linux*) LD="${LD-ld} -m elf64_sparc" ;; esac ;; esac fi rm -rf conftest* ;; *-*-sco3.2v5*) # On SCO OpenServer 5, we need -belf to get full-featured binaries. SAVE_CFLAGS=$CFLAGS CFLAGS="$CFLAGS -belf" AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, [AC_LANG_PUSH(C) AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) AC_LANG_POP]) if test yes != "$lt_cv_cc_needs_belf"; then # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf CFLAGS=$SAVE_CFLAGS fi ;; *-*solaris*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then case `$FILECMD conftest.o` in *64-bit*) case $lt_cv_prog_gnu_ld in yes*) case $host in i?86-*-solaris*|x86_64-*-solaris*) LD="${LD-ld} -m elf_x86_64" ;; sparc*-*-solaris*) LD="${LD-ld} -m elf64_sparc" ;; esac # GNU ld 2.21 introduced _sol2 emulations. Use them if available. if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then LD=${LD-ld}_sol2 fi ;; *) if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then LD="${LD-ld} -64" fi ;; esac ;; esac fi rm -rf conftest* ;; esac need_locks=$enable_libtool_lock ])# _LT_ENABLE_LOCK # _LT_PROG_AR # ----------- m4_defun([_LT_PROG_AR], [AC_CHECK_TOOLS(AR, [ar], false) : ${AR=ar} _LT_DECL([], [AR], [1], [The archiver]) # Use ARFLAGS variable as AR's operation code to sync the variable naming with # Automake. If both AR_FLAGS and ARFLAGS are specified, AR_FLAGS should have # higher priority because thats what people were doing historically (setting # ARFLAGS for automake and AR_FLAGS for libtool). FIXME: Make the AR_FLAGS # variable obsoleted/removed. test ${AR_FLAGS+y} || AR_FLAGS=${ARFLAGS-cr} lt_ar_flags=$AR_FLAGS _LT_DECL([], [lt_ar_flags], [0], [Flags to create an archive (by configure)]) # Make AR_FLAGS overridable by 'make ARFLAGS='. Don't try to run-time override # by AR_FLAGS because that was never working and AR_FLAGS is about to die. _LT_DECL([], [AR_FLAGS], [\@S|@{ARFLAGS-"\@S|@lt_ar_flags"}], [Flags to create an archive]) AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file], [lt_cv_ar_at_file=no AC_COMPILE_IFELSE([AC_LANG_PROGRAM], [echo conftest.$ac_objext > conftest.lst lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD' AC_TRY_EVAL([lt_ar_try]) if test 0 -eq "$ac_status"; then # Ensure the archiver fails upon bogus file names. rm -f conftest.$ac_objext libconftest.a AC_TRY_EVAL([lt_ar_try]) if test 0 -ne "$ac_status"; then lt_cv_ar_at_file=@ fi fi rm -f conftest.* libconftest.a ]) ]) if test no = "$lt_cv_ar_at_file"; then archiver_list_spec= else archiver_list_spec=$lt_cv_ar_at_file fi _LT_DECL([], [archiver_list_spec], [1], [How to feed a file listing to the archiver]) ])# _LT_PROG_AR # _LT_CMD_OLD_ARCHIVE # ------------------- m4_defun([_LT_CMD_OLD_ARCHIVE], [_LT_PROG_AR AC_CHECK_TOOL(STRIP, strip, :) test -z "$STRIP" && STRIP=: _LT_DECL([], [STRIP], [1], [A symbol stripping program]) AC_CHECK_TOOL(RANLIB, ranlib, :) test -z "$RANLIB" && RANLIB=: _LT_DECL([], [RANLIB], [1], [Commands used to install an old-style archive]) # Determine commands to create old-style static archives. old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' old_postinstall_cmds='chmod 644 $oldlib' old_postuninstall_cmds= if test -n "$RANLIB"; then case $host_os in bitrig* | openbsd*) old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" ;; *) old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" ;; esac old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" fi case $host_os in darwin*) lock_old_archive_extraction=yes ;; *) lock_old_archive_extraction=no ;; esac _LT_DECL([], [old_postinstall_cmds], [2]) _LT_DECL([], [old_postuninstall_cmds], [2]) _LT_TAGDECL([], [old_archive_cmds], [2], [Commands used to build an old-style archive]) _LT_DECL([], [lock_old_archive_extraction], [0], [Whether to use a lock for old archive extraction]) ])# _LT_CMD_OLD_ARCHIVE # _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, # [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) # ---------------------------------------------------------------- # Check whether the given compiler option works AC_DEFUN([_LT_COMPILER_OPTION], [m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_SED])dnl AC_CACHE_CHECK([$1], [$2], [$2=no m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="$3" ## exclude from sc_useless_quotes_in_assignment # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&AS_MESSAGE_LOG_FD echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then $2=yes fi fi $RM conftest* ]) if test yes = "[$]$2"; then m4_if([$5], , :, [$5]) else m4_if([$6], , :, [$6]) fi ])# _LT_COMPILER_OPTION # Old name: AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], []) # _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, # [ACTION-SUCCESS], [ACTION-FAILURE]) # ---------------------------------------------------- # Check whether the given linker option works AC_DEFUN([_LT_LINKER_OPTION], [m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_SED])dnl AC_CACHE_CHECK([$1], [$2], [$2=no save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS $3" echo "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then # The linker can only warn and ignore the option if not recognized # So say no if there are warnings if test -s conftest.err; then # Append any errors to the config.log. cat conftest.err 1>&AS_MESSAGE_LOG_FD $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if diff conftest.exp conftest.er2 >/dev/null; then $2=yes fi else $2=yes fi fi $RM -r conftest* LDFLAGS=$save_LDFLAGS ]) if test yes = "[$]$2"; then m4_if([$4], , :, [$4]) else m4_if([$5], , :, [$5]) fi ])# _LT_LINKER_OPTION # Old name: AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], []) # LT_CMD_MAX_LEN #--------------- AC_DEFUN([LT_CMD_MAX_LEN], [AC_REQUIRE([AC_CANONICAL_HOST])dnl # find the maximum length of command line arguments AC_MSG_CHECKING([the maximum length of command line arguments]) AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl i=0 teststring=ABCD case $build_os in msdosdjgpp*) # On DJGPP, this test can blow up pretty badly due to problems in libc # (any single argument exceeding 2000 bytes causes a buffer overrun # during glob expansion). Even if it were fixed, the result of this # check would be larger than it should be. lt_cv_sys_max_cmd_len=12288; # 12K is about right ;; gnu*) # Under GNU Hurd, this test is not required because there is # no limit to the length of command line arguments. # Libtool will interpret -1 as no limit whatsoever lt_cv_sys_max_cmd_len=-1; ;; cygwin* | mingw* | cegcc*) # On Win9x/ME, this test blows up -- it succeeds, but takes # about 5 minutes as the teststring grows exponentially. # Worse, since 9x/ME are not pre-emptively multitasking, # you end up with a "frozen" computer, even though with patience # the test eventually succeeds (with a max line length of 256k). # Instead, let's just punt: use the minimum linelength reported by # all of the supported platforms: 8192 (on NT/2K/XP). lt_cv_sys_max_cmd_len=8192; ;; mint*) # On MiNT this can take a long time and run out of memory. lt_cv_sys_max_cmd_len=8192; ;; amigaos*) # On AmigaOS with pdksh, this test takes hours, literally. # So we just punt and use a minimum line length of 8192. lt_cv_sys_max_cmd_len=8192; ;; bitrig* | darwin* | dragonfly* | freebsd* | midnightbsd* | netbsd* | openbsd*) # This has been around since 386BSD, at least. Likely further. if test -x /sbin/sysctl; then lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` elif test -x /usr/sbin/sysctl; then lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` else lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs fi # And add a safety zone lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` ;; interix*) # We know the value 262144 and hardcode it with a safety zone (like BSD) lt_cv_sys_max_cmd_len=196608 ;; os2*) # The test takes a long time on OS/2. lt_cv_sys_max_cmd_len=8192 ;; osf*) # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not # nice to cause kernel panics so lets avoid the loop below. # First set a reasonable default. lt_cv_sys_max_cmd_len=16384 # if test -x /sbin/sysconfig; then case `/sbin/sysconfig -q proc exec_disable_arg_limit` in *1*) lt_cv_sys_max_cmd_len=-1 ;; esac fi ;; sco3.2v5*) lt_cv_sys_max_cmd_len=102400 ;; sysv5* | sco5v6* | sysv4.2uw2*) kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` if test -n "$kargmax"; then lt_cv_sys_max_cmd_len=`echo $kargmax | $SED 's/.*[[ ]]//'` else lt_cv_sys_max_cmd_len=32768 fi ;; *) lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` if test -n "$lt_cv_sys_max_cmd_len" && \ test undefined != "$lt_cv_sys_max_cmd_len"; then lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` else # Make teststring a little bigger before we do anything with it. # a 1K string should be a reasonable start. for i in 1 2 3 4 5 6 7 8; do teststring=$teststring$teststring done SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} # If test is not a shell built-in, we'll probably end up computing a # maximum length that is only half of the actual maximum length, but # we can't tell. while { test X`env echo "$teststring$teststring" 2>/dev/null` \ = "X$teststring$teststring"; } >/dev/null 2>&1 && test 17 != "$i" # 1/2 MB should be enough do i=`expr $i + 1` teststring=$teststring$teststring done # Only check the string length outside the loop. lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` teststring= # Add a significant safety factor because C++ compilers can tack on # massive amounts of additional arguments before passing them to the # linker. It appears as though 1/2 is a usable value. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` fi ;; esac ]) if test -n "$lt_cv_sys_max_cmd_len"; then AC_MSG_RESULT($lt_cv_sys_max_cmd_len) else AC_MSG_RESULT(none) fi max_cmd_len=$lt_cv_sys_max_cmd_len _LT_DECL([], [max_cmd_len], [0], [What is the maximum length of a command?]) ])# LT_CMD_MAX_LEN # Old name: AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], []) # _LT_HEADER_DLFCN # ---------------- m4_defun([_LT_HEADER_DLFCN], [AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl ])# _LT_HEADER_DLFCN # _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, # ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) # ---------------------------------------------------------------- m4_defun([_LT_TRY_DLOPEN_SELF], [m4_require([_LT_HEADER_DLFCN])dnl if test yes = "$cross_compiling"; then : [$4] else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF [#line $LINENO "configure" #include "confdefs.h" #if HAVE_DLFCN_H #include #endif #include #ifdef RTLD_GLOBAL # define LT_DLGLOBAL RTLD_GLOBAL #else # ifdef DL_GLOBAL # define LT_DLGLOBAL DL_GLOBAL # else # define LT_DLGLOBAL 0 # endif #endif /* We may have to define LT_DLLAZY_OR_NOW in the command line if we find out it does not work in some platform. */ #ifndef LT_DLLAZY_OR_NOW # ifdef RTLD_LAZY # define LT_DLLAZY_OR_NOW RTLD_LAZY # else # ifdef DL_LAZY # define LT_DLLAZY_OR_NOW DL_LAZY # else # ifdef RTLD_NOW # define LT_DLLAZY_OR_NOW RTLD_NOW # else # ifdef DL_NOW # define LT_DLLAZY_OR_NOW DL_NOW # else # define LT_DLLAZY_OR_NOW 0 # endif # endif # endif # endif #endif /* When -fvisibility=hidden is used, assume the code has been annotated correspondingly for the symbols needed. */ #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) int fnord () __attribute__((visibility("default"))); #endif int fnord () { return 42; } int main () { void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); int status = $lt_dlunknown; if (self) { if (dlsym (self,"fnord")) status = $lt_dlno_uscore; else { if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; else puts (dlerror ()); } /* dlclose (self); */ } else puts (dlerror ()); return status; }] _LT_EOF if AC_TRY_EVAL(ac_link) && test -s "conftest$ac_exeext" 2>/dev/null; then (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null lt_status=$? case x$lt_status in x$lt_dlno_uscore) $1 ;; x$lt_dlneed_uscore) $2 ;; x$lt_dlunknown|x*) $3 ;; esac else : # compilation failed $3 fi fi rm -fr conftest* ])# _LT_TRY_DLOPEN_SELF # LT_SYS_DLOPEN_SELF # ------------------ AC_DEFUN([LT_SYS_DLOPEN_SELF], [m4_require([_LT_HEADER_DLFCN])dnl if test yes != "$enable_dlopen"; then enable_dlopen=unknown enable_dlopen_self=unknown enable_dlopen_self_static=unknown else lt_cv_dlopen=no lt_cv_dlopen_libs= case $host_os in beos*) lt_cv_dlopen=load_add_on lt_cv_dlopen_libs= lt_cv_dlopen_self=yes ;; mingw* | pw32* | cegcc*) lt_cv_dlopen=LoadLibrary lt_cv_dlopen_libs= ;; cygwin*) lt_cv_dlopen=dlopen lt_cv_dlopen_libs= ;; darwin*) # if libdl is installed we need to link against it AC_CHECK_LIB([dl], [dlopen], [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl],[ lt_cv_dlopen=dyld lt_cv_dlopen_libs= lt_cv_dlopen_self=yes ]) ;; tpf*) # Don't try to run any link tests for TPF. We know it's impossible # because TPF is a cross-compiler, and we know how we open DSOs. lt_cv_dlopen=dlopen lt_cv_dlopen_libs= lt_cv_dlopen_self=no ;; *) AC_CHECK_FUNC([shl_load], [lt_cv_dlopen=shl_load], [AC_CHECK_LIB([dld], [shl_load], [lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld], [AC_CHECK_FUNC([dlopen], [lt_cv_dlopen=dlopen], [AC_CHECK_LIB([dl], [dlopen], [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl], [AC_CHECK_LIB([svld], [dlopen], [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld], [AC_CHECK_LIB([dld], [dld_link], [lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld]) ]) ]) ]) ]) ]) ;; esac if test no = "$lt_cv_dlopen"; then enable_dlopen=no else enable_dlopen=yes fi case $lt_cv_dlopen in dlopen) save_CPPFLAGS=$CPPFLAGS test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" save_LDFLAGS=$LDFLAGS wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" save_LIBS=$LIBS LIBS="$lt_cv_dlopen_libs $LIBS" AC_CACHE_CHECK([whether a program can dlopen itself], lt_cv_dlopen_self, [dnl _LT_TRY_DLOPEN_SELF( lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) ]) if test yes = "$lt_cv_dlopen_self"; then wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" AC_CACHE_CHECK([whether a statically linked program can dlopen itself], lt_cv_dlopen_self_static, [dnl _LT_TRY_DLOPEN_SELF( lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) ]) fi CPPFLAGS=$save_CPPFLAGS LDFLAGS=$save_LDFLAGS LIBS=$save_LIBS ;; esac case $lt_cv_dlopen_self in yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; *) enable_dlopen_self=unknown ;; esac case $lt_cv_dlopen_self_static in yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; *) enable_dlopen_self_static=unknown ;; esac fi _LT_DECL([dlopen_support], [enable_dlopen], [0], [Whether dlopen is supported]) _LT_DECL([dlopen_self], [enable_dlopen_self], [0], [Whether dlopen of programs is supported]) _LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0], [Whether dlopen of statically linked programs is supported]) ])# LT_SYS_DLOPEN_SELF # Old name: AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], []) # _LT_COMPILER_C_O([TAGNAME]) # --------------------------- # Check to see if options -c and -o are simultaneously supported by compiler. # This macro does not hard code the compiler like AC_PROG_CC_C_O. m4_defun([_LT_COMPILER_C_O], [m4_require([_LT_DECL_SED])dnl m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_TAG_COMPILER])dnl AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)], [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no $RM -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-o out/conftest2.$ac_objext" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&AS_MESSAGE_LOG_FD echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes fi fi chmod u+w . 2>&AS_MESSAGE_LOG_FD $RM conftest* # SGI C++ compiler will create directory out/ii_files/ for # template instantiation test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files $RM out/* && rmdir out cd .. $RM -r conftest $RM conftest* ]) _LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1], [Does compiler simultaneously support -c and -o options?]) ])# _LT_COMPILER_C_O # _LT_COMPILER_FILE_LOCKS([TAGNAME]) # ---------------------------------- # Check to see if we can do hard links to lock some files if needed m4_defun([_LT_COMPILER_FILE_LOCKS], [m4_require([_LT_ENABLE_LOCK])dnl m4_require([_LT_FILEUTILS_DEFAULTS])dnl _LT_COMPILER_C_O([$1]) hard_links=nottested if test no = "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" && test no != "$need_locks"; then # do not overwrite the value of need_locks provided by the user AC_MSG_CHECKING([if we can lock with hard links]) hard_links=yes $RM conftest* ln conftest.a conftest.b 2>/dev/null && hard_links=no touch conftest.a ln conftest.a conftest.b 2>&5 || hard_links=no ln conftest.a conftest.b 2>/dev/null && hard_links=no AC_MSG_RESULT([$hard_links]) if test no = "$hard_links"; then AC_MSG_WARN(['$CC' does not support '-c -o', so 'make -j' may be unsafe]) need_locks=warn fi else need_locks=no fi _LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?]) ])# _LT_COMPILER_FILE_LOCKS # _LT_CHECK_OBJDIR # ---------------- m4_defun([_LT_CHECK_OBJDIR], [AC_CACHE_CHECK([for objdir], [lt_cv_objdir], [rm -f .libs 2>/dev/null mkdir .libs 2>/dev/null if test -d .libs; then lt_cv_objdir=.libs else # MS-DOS does not allow filenames that begin with a dot. lt_cv_objdir=_libs fi rmdir .libs 2>/dev/null]) objdir=$lt_cv_objdir _LT_DECL([], [objdir], [0], [The name of the directory that contains temporary libtool files])dnl m4_pattern_allow([LT_OBJDIR])dnl AC_DEFINE_UNQUOTED([LT_OBJDIR], "$lt_cv_objdir/", [Define to the sub-directory where libtool stores uninstalled libraries.]) ])# _LT_CHECK_OBJDIR # _LT_LINKER_HARDCODE_LIBPATH([TAGNAME]) # -------------------------------------- # Check hardcoding attributes. m4_defun([_LT_LINKER_HARDCODE_LIBPATH], [AC_MSG_CHECKING([how to hardcode library paths into programs]) _LT_TAGVAR(hardcode_action, $1)= if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" || test -n "$_LT_TAGVAR(runpath_var, $1)" || test yes = "$_LT_TAGVAR(hardcode_automatic, $1)"; then # We can hardcode non-existent directories. if test no != "$_LT_TAGVAR(hardcode_direct, $1)" && # If the only mechanism to avoid hardcoding is shlibpath_var, we # have to relink, otherwise we might link with an installed library # when we should be linking with a yet-to-be-installed one ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" && test no != "$_LT_TAGVAR(hardcode_minus_L, $1)"; then # Linking always hardcodes the temporary library directory. _LT_TAGVAR(hardcode_action, $1)=relink else # We can link without hardcoding, and we can hardcode nonexisting dirs. _LT_TAGVAR(hardcode_action, $1)=immediate fi else # We cannot hardcode anything, or else we can only hardcode existing # directories. _LT_TAGVAR(hardcode_action, $1)=unsupported fi AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)]) if test relink = "$_LT_TAGVAR(hardcode_action, $1)" || test yes = "$_LT_TAGVAR(inherit_rpath, $1)"; then # Fast installation is not supported enable_fast_install=no elif test yes = "$shlibpath_overrides_runpath" || test no = "$enable_shared"; then # Fast installation is not necessary enable_fast_install=needless fi _LT_TAGDECL([], [hardcode_action], [0], [How to hardcode a shared library path into an executable]) ])# _LT_LINKER_HARDCODE_LIBPATH # _LT_CMD_STRIPLIB # ---------------- m4_defun([_LT_CMD_STRIPLIB], [m4_require([_LT_DECL_EGREP]) striplib= old_striplib= AC_MSG_CHECKING([whether stripping libraries is possible]) if test -z "$STRIP"; then AC_MSG_RESULT([no]) else if $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then old_striplib="$STRIP --strip-debug" striplib="$STRIP --strip-unneeded" AC_MSG_RESULT([yes]) else case $host_os in darwin*) # FIXME - insert some real tests, host_os isn't really good enough striplib="$STRIP -x" old_striplib="$STRIP -S" AC_MSG_RESULT([yes]) ;; freebsd*) if $STRIP -V 2>&1 | $GREP "elftoolchain" >/dev/null; then old_striplib="$STRIP --strip-debug" striplib="$STRIP --strip-unneeded" AC_MSG_RESULT([yes]) else AC_MSG_RESULT([no]) fi ;; *) AC_MSG_RESULT([no]) ;; esac fi fi _LT_DECL([], [old_striplib], [1], [Commands to strip libraries]) _LT_DECL([], [striplib], [1]) ])# _LT_CMD_STRIPLIB # _LT_PREPARE_MUNGE_PATH_LIST # --------------------------- # Make sure func_munge_path_list() is defined correctly. m4_defun([_LT_PREPARE_MUNGE_PATH_LIST], [[# func_munge_path_list VARIABLE PATH # ----------------------------------- # VARIABLE is name of variable containing _space_ separated list of # directories to be munged by the contents of PATH, which is string # having a format: # "DIR[:DIR]:" # string "DIR[ DIR]" will be prepended to VARIABLE # ":DIR[:DIR]" # string "DIR[ DIR]" will be appended to VARIABLE # "DIRP[:DIRP]::[DIRA:]DIRA" # string "DIRP[ DIRP]" will be prepended to VARIABLE and string # "DIRA[ DIRA]" will be appended to VARIABLE # "DIR[:DIR]" # VARIABLE will be replaced by "DIR[ DIR]" func_munge_path_list () { case x@S|@2 in x) ;; *:) eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'` \@S|@@S|@1\" ;; x:*) eval @S|@1=\"\@S|@@S|@1 `$ECHO @S|@2 | $SED 's/:/ /g'`\" ;; *::*) eval @S|@1=\"\@S|@@S|@1\ `$ECHO @S|@2 | $SED -e 's/.*:://' -e 's/:/ /g'`\" eval @S|@1=\"`$ECHO @S|@2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \@S|@@S|@1\" ;; *) eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'`\" ;; esac } ]])# _LT_PREPARE_PATH_LIST # _LT_SYS_DYNAMIC_LINKER([TAG]) # ----------------------------- # PORTME Fill in your ld.so characteristics m4_defun([_LT_SYS_DYNAMIC_LINKER], [AC_REQUIRE([AC_CANONICAL_HOST])dnl m4_require([_LT_DECL_EGREP])dnl m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_OBJDUMP])dnl m4_require([_LT_DECL_SED])dnl m4_require([_LT_CHECK_SHELL_FEATURES])dnl m4_require([_LT_PREPARE_MUNGE_PATH_LIST])dnl AC_MSG_CHECKING([dynamic linker characteristics]) m4_if([$1], [], [ if test yes = "$GCC"; then case $host_os in darwin*) lt_awk_arg='/^libraries:/,/LR/' ;; *) lt_awk_arg='/^libraries:/' ;; esac case $host_os in mingw* | cegcc*) lt_sed_strip_eq='s|=\([[A-Za-z]]:\)|\1|g' ;; *) lt_sed_strip_eq='s|=/|/|g' ;; esac lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` case $lt_search_path_spec in *\;*) # if the path contains ";" then we assume it to be the separator # otherwise default to the standard path separator (i.e. ":") - it is # assumed that no part of a normal pathname contains ";" but that should # okay in the real world where ";" in dirpaths is itself problematic. lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` ;; *) lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` ;; esac # Ok, now we have the path, separated by spaces, we can step through it # and add multilib dir if necessary... lt_tmp_lt_search_path_spec= lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` # ...but if some path component already ends with the multilib dir we assume # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer). case "$lt_multi_os_dir; $lt_search_path_spec " in "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*) lt_multi_os_dir= ;; esac for lt_sys_path in $lt_search_path_spec; do if test -d "$lt_sys_path$lt_multi_os_dir"; then lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir" elif test -n "$lt_multi_os_dir"; then test -d "$lt_sys_path" && \ lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" fi done lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' BEGIN {RS = " "; FS = "/|\n";} { lt_foo = ""; lt_count = 0; for (lt_i = NF; lt_i > 0; lt_i--) { if ($lt_i != "" && $lt_i != ".") { if ($lt_i == "..") { lt_count++; } else { if (lt_count == 0) { lt_foo = "/" $lt_i lt_foo; } else { lt_count--; } } } } if (lt_foo != "") { lt_freq[[lt_foo]]++; } if (lt_freq[[lt_foo]] == 1) { print lt_foo; } }'` # AWK program above erroneously prepends '/' to C:/dos/paths # for these hosts. case $host_os in mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ $SED 's|/\([[A-Za-z]]:\)|\1|g'` ;; esac sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` else sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" fi]) library_names_spec= libname_spec='lib$name' soname_spec= shrext_cmds=.so postinstall_cmds= postuninstall_cmds= finish_cmds= finish_eval= shlibpath_var= shlibpath_overrides_runpath=unknown version_type=none dynamic_linker="$host_os ld.so" sys_lib_dlsearch_path_spec="/lib /usr/lib" need_lib_prefix=unknown hardcode_into_libs=no # when you set need_version to no, make sure it does not cause -set_version # flags to be left without arguments need_version=unknown AC_ARG_VAR([LT_SYS_LIBRARY_PATH], [User-defined run-time library search path.]) case $host_os in aix3*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname.a' shlibpath_var=LIBPATH # AIX 3 has no versioning support, so we append a major version to the name. soname_spec='$libname$release$shared_ext$major' ;; aix[[4-9]]*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no hardcode_into_libs=yes if test ia64 = "$host_cpu"; then # AIX 5 supports IA64 library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH else # With GCC up to 2.95.x, collect2 would create an import file # for dependence libraries. The import file would start with # the line '#! .'. This would cause the generated library to # depend on '.', always an invalid library. This was fixed in # development snapshots of GCC prior to 3.0. case $host_os in aix4 | aix4.[[01]] | aix4.[[01]].*) if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' echo ' yes ' echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then : else can_build_shared=no fi ;; esac # Using Import Files as archive members, it is possible to support # filename-based versioning of shared library archives on AIX. While # this would work for both with and without runtime linking, it will # prevent static linking of such archives. So we do filename-based # shared library versioning with .so extension only, which is used # when both runtime linking and shared linking is enabled. # Unfortunately, runtime linking may impact performance, so we do # not want this to be the default eventually. Also, we use the # versioned .so libs for executables only if there is the -brtl # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only. # To allow for filename-based versioning support, we need to create # libNAME.so.V as an archive file, containing: # *) an Import File, referring to the versioned filename of the # archive as well as the shared archive member, telling the # bitwidth (32 or 64) of that shared object, and providing the # list of exported symbols of that shared object, eventually # decorated with the 'weak' keyword # *) the shared object with the F_LOADONLY flag set, to really avoid # it being seen by the linker. # At run time we better use the real file rather than another symlink, # but for link time we create the symlink libNAME.so -> libNAME.so.V case $with_aix_soname,$aix_use_runtimelinking in # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct # soname into executable. Probably we can add versioning support to # collect2, so additional links can be useful in future. aix,yes) # traditional libtool dynamic_linker='AIX unversionable lib.so' # If using run time linking (on AIX 4.2 or later) use lib.so # instead of lib.a to let people know that these are not # typical AIX shared libraries. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' ;; aix,no) # traditional AIX only dynamic_linker='AIX lib.a[(]lib.so.V[)]' # We preserve .a as extension for shared libraries through AIX4.2 # and later when we are not doing run time linking. library_names_spec='$libname$release.a $libname.a' soname_spec='$libname$release$shared_ext$major' ;; svr4,*) # full svr4 only dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)]" library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' # We do not specify a path in Import Files, so LIBPATH fires. shlibpath_overrides_runpath=yes ;; *,yes) # both, prefer svr4 dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)], lib.a[(]lib.so.V[)]" library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' # unpreferred sharedlib libNAME.a needs extra handling postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"' postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"' # We do not specify a path in Import Files, so LIBPATH fires. shlibpath_overrides_runpath=yes ;; *,no) # both, prefer aix dynamic_linker="AIX lib.a[(]lib.so.V[)], lib.so.V[(]$shared_archive_member_spec.o[)]" library_names_spec='$libname$release.a $libname.a' soname_spec='$libname$release$shared_ext$major' # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)' postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"' ;; esac shlibpath_var=LIBPATH fi ;; amigaos*) case $host_cpu in powerpc) # Since July 2007 AmigaOS4 officially supports .so libraries. # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' ;; m68k) library_names_spec='$libname.ixlibrary $libname.a' # Create ${libname}_ixlibrary.a entries in /sys/libs. finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' ;; esac ;; beos*) library_names_spec='$libname$shared_ext' dynamic_linker="$host_os ld.so" shlibpath_var=LIBRARY_PATH ;; bsdi[[45]]*) version_type=linux # correct to gnu/linux during the next big refactor need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" # the default ld.so.conf also contains /usr/contrib/lib and # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow # libtool to hard-code these into programs ;; cygwin* | mingw* | pw32* | cegcc*) version_type=windows shrext_cmds=.dll need_version=no need_lib_prefix=no case $GCC,$cc_basename in yes,*) # gcc library_names_spec='$libname.dll.a' # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname~ if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; fi' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' shlibpath_overrides_runpath=yes case $host_os in cygwin*) # Cygwin DLLs use 'cyg' prefix rather than 'lib' soname_spec='`echo $libname | $SED -e 's/^lib/cyg/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' m4_if([$1], [],[ sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"]) ;; mingw* | cegcc*) # MinGW DLLs use traditional 'lib' prefix soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' ;; pw32*) # pw32 DLLs use 'pw' prefix rather than 'lib' library_names_spec='`echo $libname | $SED -e 's/^lib/pw/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' ;; esac dynamic_linker='Win32 ld.exe' ;; *,cl* | *,icl*) # Native MSVC or ICC libname_spec='$name' soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' library_names_spec='$libname.dll.lib' case $build_os in mingw*) sys_lib_search_path_spec= lt_save_ifs=$IFS IFS=';' for lt_path in $LIB do IFS=$lt_save_ifs # Let DOS variable expansion print the short 8.3 style file name. lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" done IFS=$lt_save_ifs # Convert to MSYS style. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'` ;; cygwin*) # Convert to unix form, then to dos form, then back to unix form # but this time dos style (no spaces!) so that the unix form looks # like /cygdrive/c/PROGRA~1:/cygdr... sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` ;; *) sys_lib_search_path_spec=$LIB if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then # It is most probably a Windows format PATH. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` else sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` fi # FIXME: find the short name or the path components, as spaces are # common. (e.g. "Program Files" -> "PROGRA~1") ;; esac # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' shlibpath_overrides_runpath=yes dynamic_linker='Win32 link.exe' ;; *) # Assume MSVC and ICC wrapper library_names_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext $libname.lib' dynamic_linker='Win32 ld.exe' ;; esac # FIXME: first we should search . and the directory the executable is in shlibpath_var=PATH ;; darwin* | rhapsody*) dynamic_linker="$host_os dyld" version_type=darwin need_lib_prefix=no need_version=no library_names_spec='$libname$release$major$shared_ext $libname$shared_ext' soname_spec='$libname$release$major$shared_ext' shlibpath_overrides_runpath=yes shlibpath_var=DYLD_LIBRARY_PATH shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' m4_if([$1], [],[ sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' ;; dgux*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH ;; freebsd* | dragonfly* | midnightbsd*) # DragonFly does not have aout. When/if they implement a new # versioning mechanism, adjust this. if test -x /usr/bin/objformat; then objformat=`/usr/bin/objformat` else case $host_os in freebsd[[23]].*) objformat=aout ;; *) objformat=elf ;; esac fi version_type=freebsd-$objformat case $version_type in freebsd-elf*) library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' need_version=no need_lib_prefix=no ;; freebsd-*) library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' need_version=yes ;; esac shlibpath_var=LD_LIBRARY_PATH case $host_os in freebsd2.*) shlibpath_overrides_runpath=yes ;; freebsd3.[[01]]* | freebsdelf3.[[01]]*) shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \ freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1) shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; *) # from 4.6 on, and DragonFly shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; esac ;; haiku*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no dynamic_linker="$host_os runtime_loader" library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LIBRARY_PATH shlibpath_overrides_runpath=no sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' hardcode_into_libs=yes ;; hpux9* | hpux10* | hpux11*) # Give a soname corresponding to the major version so that dld.sl refuses to # link against other versions. version_type=sunos need_lib_prefix=no need_version=no case $host_cpu in ia64*) shrext_cmds='.so' hardcode_into_libs=yes dynamic_linker="$host_os dld.so" shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' if test 32 = "$HPUX_IA64_MODE"; then sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" sys_lib_dlsearch_path_spec=/usr/lib/hpux32 else sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" sys_lib_dlsearch_path_spec=/usr/lib/hpux64 fi ;; hppa*64*) shrext_cmds='.sl' hardcode_into_libs=yes dynamic_linker="$host_os dld.sl" shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; *) shrext_cmds='.sl' dynamic_linker="$host_os dld.sl" shlibpath_var=SHLIB_PATH shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' ;; esac # HP-UX runs *really* slowly unless shared libraries are mode 555, ... postinstall_cmds='chmod 555 $lib' # or fails outright, so override atomically: install_override_mode=555 ;; interix[[3-9]]*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; irix5* | irix6* | nonstopux*) case $host_os in nonstopux*) version_type=nonstopux ;; *) if test yes = "$lt_cv_prog_gnu_ld"; then version_type=linux # correct to gnu/linux during the next big refactor else version_type=irix fi ;; esac need_lib_prefix=no need_version=no soname_spec='$libname$release$shared_ext$major' library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext' case $host_os in irix5* | nonstopux*) libsuff= shlibsuff= ;; *) case $LD in # libtool.m4 will add one of these switches to LD *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") libsuff= shlibsuff= libmagic=32-bit;; *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") libsuff=32 shlibsuff=N32 libmagic=N32;; *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") libsuff=64 shlibsuff=64 libmagic=64-bit;; *) libsuff= shlibsuff= libmagic=never-match;; esac ;; esac shlibpath_var=LD_LIBRARY${shlibsuff}_PATH shlibpath_overrides_runpath=no sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff" sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff" hardcode_into_libs=yes ;; # No shared lib support for Linux oldld, aout, or coff. linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; linux*android*) version_type=none # Android doesn't support versioned libraries. need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext' soname_spec='$libname$release$shared_ext' finish_cmds= shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes dynamic_linker='Android linker' # Don't embed -rpath directories since the linker doesn't support them. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' ;; # This must be glibc/ELF. linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no # Some binutils ld are patched to set DT_RUNPATH AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath], [lt_cv_shlibpath_overrides_runpath=no save_LDFLAGS=$LDFLAGS save_libdir=$libdir eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \ LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\"" AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null], [lt_cv_shlibpath_overrides_runpath=yes])]) LDFLAGS=$save_LDFLAGS libdir=$save_libdir ]) shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes # Ideally, we could use ldconfig to report *all* directores which are # searched for libraries, however this is still not possible. Aside from not # being certain /sbin/ldconfig is available, command # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64, # even though it is searched at run-time. Try to do the best guess by # appending ld.so.conf contents (and includes) to the search path. if test -f /etc/ld.so.conf; then lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on # powerpc, because MkLinux only supported shared libraries with the # GNU dynamic linker. Since this was broken with cross compilers, # most powerpc-linux boxes support dynamic linking these days and # people can always --disable-shared, the test was removed, and we # assume the GNU/Linux dynamic linker is in use. dynamic_linker='GNU/Linux ld.so' ;; netbsdelf*-gnu) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='NetBSD ld.elf_so' ;; netbsd*) version_type=sunos need_lib_prefix=no need_version=no if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' dynamic_linker='NetBSD (a.out) ld.so' else library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' dynamic_linker='NetBSD ld.elf_so' fi shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; newsos6) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; *nto* | *qnx*) version_type=qnx need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='ldqnx.so' ;; openbsd* | bitrig*) version_type=sunos sys_lib_dlsearch_path_spec=/usr/lib need_lib_prefix=no if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then need_version=no else need_version=yes fi library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; os2*) libname_spec='$name' version_type=windows shrext_cmds=.dll need_version=no need_lib_prefix=no # OS/2 can only load a DLL with a base name of 8 characters or less. soname_spec='`test -n "$os2dllname" && libname="$os2dllname"; v=$($ECHO $release$versuffix | tr -d .-); n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _); $ECHO $n$v`$shared_ext' library_names_spec='${libname}_dll.$libext' dynamic_linker='OS/2 ld.exe' shlibpath_var=BEGINLIBPATH sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname~ if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; fi' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' ;; osf3* | osf4* | osf5*) version_type=osf need_lib_prefix=no need_version=no soname_spec='$libname$release$shared_ext$major' library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; rdos*) dynamic_linker=no ;; solaris*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes # ldd complains unless libraries are executable postinstall_cmds='chmod +x $lib' ;; sunos4*) version_type=sunos library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes if test yes = "$with_gnu_ld"; then need_lib_prefix=no fi need_version=yes ;; sysv4 | sysv4.3*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH case $host_vendor in sni) shlibpath_overrides_runpath=no need_lib_prefix=no runpath_var=LD_RUN_PATH ;; siemens) need_lib_prefix=no ;; motorola) need_lib_prefix=no need_version=no shlibpath_overrides_runpath=no sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' ;; esac ;; sysv4*MP*) if test -d /usr/nec; then version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext' soname_spec='$libname$shared_ext.$major' shlibpath_var=LD_LIBRARY_PATH fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) version_type=sco need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes if test yes = "$with_gnu_ld"; then sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' else sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' case $host_os in sco3.2v5*) sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" ;; esac fi sys_lib_dlsearch_path_spec='/usr/lib' ;; tpf*) # TPF is a cross-target only. Preferred cross-host = GNU/Linux. version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; uts4*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH ;; *) dynamic_linker=no ;; esac AC_MSG_RESULT([$dynamic_linker]) test no = "$dynamic_linker" && can_build_shared=no variables_saved_for_relink="PATH $shlibpath_var $runpath_var" if test yes = "$GCC"; then variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" fi if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec fi if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec fi # remember unaugmented sys_lib_dlsearch_path content for libtool script decls... configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec # ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH" # to be used as default LT_SYS_LIBRARY_PATH value in generated libtool configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH _LT_DECL([], [variables_saved_for_relink], [1], [Variables whose values should be saved in libtool wrapper scripts and restored at link time]) _LT_DECL([], [need_lib_prefix], [0], [Do we need the "lib" prefix for modules?]) _LT_DECL([], [need_version], [0], [Do we need a version for libraries?]) _LT_DECL([], [version_type], [0], [Library versioning type]) _LT_DECL([], [runpath_var], [0], [Shared library runtime path variable]) _LT_DECL([], [shlibpath_var], [0],[Shared library path variable]) _LT_DECL([], [shlibpath_overrides_runpath], [0], [Is shlibpath searched before the hard-coded library search path?]) _LT_DECL([], [libname_spec], [1], [Format of library name prefix]) _LT_DECL([], [library_names_spec], [1], [[List of archive names. First name is the real one, the rest are links. The last name is the one that the linker finds with -lNAME]]) _LT_DECL([], [soname_spec], [1], [[The coded name of the library, if different from the real name]]) _LT_DECL([], [install_override_mode], [1], [Permission mode override for installation of shared libraries]) _LT_DECL([], [postinstall_cmds], [2], [Command to use after installation of a shared archive]) _LT_DECL([], [postuninstall_cmds], [2], [Command to use after uninstallation of a shared archive]) _LT_DECL([], [finish_cmds], [2], [Commands used to finish a libtool library installation in a directory]) _LT_DECL([], [finish_eval], [1], [[As "finish_cmds", except a single script fragment to be evaled but not shown]]) _LT_DECL([], [hardcode_into_libs], [0], [Whether we should hardcode library paths into libraries]) _LT_DECL([], [sys_lib_search_path_spec], [2], [Compile-time system search path for libraries]) _LT_DECL([sys_lib_dlsearch_path_spec], [configure_time_dlsearch_path], [2], [Detected run-time system search path for libraries]) _LT_DECL([], [configure_time_lt_sys_library_path], [2], [Explicit LT_SYS_LIBRARY_PATH set during ./configure time]) ])# _LT_SYS_DYNAMIC_LINKER # _LT_PATH_TOOL_PREFIX(TOOL) # -------------------------- # find a file program that can recognize shared library AC_DEFUN([_LT_PATH_TOOL_PREFIX], [m4_require([_LT_DECL_EGREP])dnl AC_MSG_CHECKING([for $1]) AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, [case $MAGIC_CMD in [[\\/*] | ?:[\\/]*]) lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. ;; *) lt_save_MAGIC_CMD=$MAGIC_CMD lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR dnl $ac_dummy forces splitting on constant user-supplied paths. dnl POSIX.2 word splitting is done only on the output of word expansions, dnl not every word. This closes a longstanding sh security hole. ac_dummy="m4_if([$2], , $PATH, [$2])" for ac_dir in $ac_dummy; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/$1"; then lt_cv_path_MAGIC_CMD=$ac_dir/"$1" if test -n "$file_magic_test_file"; then case $deplibs_check_method in "file_magic "*) file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` MAGIC_CMD=$lt_cv_path_MAGIC_CMD if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | $EGREP "$file_magic_regex" > /dev/null; then : else cat <<_LT_EOF 1>&2 *** Warning: the command libtool uses to detect shared libraries, *** $file_magic_cmd, produces output that libtool cannot recognize. *** The result is that libtool may fail to recognize shared libraries *** as such. This will affect the creation of libtool libraries that *** depend on shared libraries, but programs linked with such libtool *** libraries will work regardless of this problem. Nevertheless, you *** may want to report the problem to your system manager and/or to *** bug-libtool@gnu.org _LT_EOF fi ;; esac fi break fi done IFS=$lt_save_ifs MAGIC_CMD=$lt_save_MAGIC_CMD ;; esac]) MAGIC_CMD=$lt_cv_path_MAGIC_CMD if test -n "$MAGIC_CMD"; then AC_MSG_RESULT($MAGIC_CMD) else AC_MSG_RESULT(no) fi _LT_DECL([], [MAGIC_CMD], [0], [Used to examine libraries when file_magic_cmd begins with "file"])dnl ])# _LT_PATH_TOOL_PREFIX # Old name: AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], []) # _LT_PATH_MAGIC # -------------- # find a file program that can recognize a shared library m4_defun([_LT_PATH_MAGIC], [_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) if test -z "$lt_cv_path_MAGIC_CMD"; then if test -n "$ac_tool_prefix"; then _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) else MAGIC_CMD=: fi fi ])# _LT_PATH_MAGIC # LT_PATH_LD # ---------- # find the pathname to the GNU or non-GNU linker AC_DEFUN([LT_PATH_LD], [AC_REQUIRE([AC_PROG_CC])dnl AC_REQUIRE([AC_CANONICAL_HOST])dnl AC_REQUIRE([AC_CANONICAL_BUILD])dnl m4_require([_LT_DECL_SED])dnl m4_require([_LT_DECL_EGREP])dnl m4_require([_LT_PROG_ECHO_BACKSLASH])dnl AC_ARG_WITH([gnu-ld], [AS_HELP_STRING([--with-gnu-ld], [assume the C compiler uses GNU ld @<:@default=no@:>@])], [test no = "$withval" || with_gnu_ld=yes], [with_gnu_ld=no])dnl ac_prog=ld if test yes = "$GCC"; then # Check if gcc -print-prog-name=ld gives a path. AC_MSG_CHECKING([for ld used by $CC]) case $host in *-*-mingw*) # gcc leaves a trailing carriage return, which upsets mingw ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; *) ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; esac case $ac_prog in # Accept absolute paths. [[\\/]]* | ?:[[\\/]]*) re_direlt='/[[^/]][[^/]]*/\.\./' # Canonicalize the pathname of ld ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` done test -z "$LD" && LD=$ac_prog ;; "") # If it fails, then pretend we aren't using GCC. ac_prog=ld ;; *) # If it is relative, then search for the first ld in PATH. with_gnu_ld=unknown ;; esac elif test yes = "$with_gnu_ld"; then AC_MSG_CHECKING([for GNU ld]) else AC_MSG_CHECKING([for non-GNU ld]) fi AC_CACHE_VAL(lt_cv_path_LD, [if test -z "$LD"; then lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR for ac_dir in $PATH; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then lt_cv_path_LD=$ac_dir/$ac_prog # Check to see if the program is GNU ld. I'd rather use --version, # but apparently some variants of GNU ld only accept -v. # Break only if it was the GNU/non-GNU ld that we prefer. case `"$lt_cv_path_LD" -v 2>&1 &1 conftest.i cat conftest.i conftest.i >conftest2.i : ${lt_DD:=$DD} AC_PATH_PROGS_FEATURE_CHECK([lt_DD], [dd], [if "$ac_path_lt_DD" bs=32 count=1 conftest.out 2>/dev/null; then cmp -s conftest.i conftest.out \ && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=: fi]) rm -f conftest.i conftest2.i conftest.out]) ])# _LT_PATH_DD # _LT_CMD_TRUNCATE # ---------------- # find command to truncate a binary pipe m4_defun([_LT_CMD_TRUNCATE], [m4_require([_LT_PATH_DD]) AC_CACHE_CHECK([how to truncate binary pipes], [lt_cv_truncate_bin], [printf 0123456789abcdef0123456789abcdef >conftest.i cat conftest.i conftest.i >conftest2.i lt_cv_truncate_bin= if "$ac_cv_path_lt_DD" bs=32 count=1 conftest.out 2>/dev/null; then cmp -s conftest.i conftest.out \ && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1" fi rm -f conftest.i conftest2.i conftest.out test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q"]) _LT_DECL([lt_truncate_bin], [lt_cv_truncate_bin], [1], [Command to truncate a binary pipe]) ])# _LT_CMD_TRUNCATE # _LT_CHECK_MAGIC_METHOD # ---------------------- # how to check for library dependencies # -- PORTME fill in with the dynamic library characteristics m4_defun([_LT_CHECK_MAGIC_METHOD], [m4_require([_LT_DECL_EGREP]) m4_require([_LT_DECL_OBJDUMP]) AC_CACHE_CHECK([how to recognize dependent libraries], lt_cv_deplibs_check_method, [lt_cv_file_magic_cmd='$MAGIC_CMD' lt_cv_file_magic_test_file= lt_cv_deplibs_check_method='unknown' # Need to set the preceding variable on all platforms that support # interlibrary dependencies. # 'none' -- dependencies not supported. # 'unknown' -- same as none, but documents that we really don't know. # 'pass_all' -- all dependencies passed with no checks. # 'test_compile' -- check by making test program. # 'file_magic [[regex]]' -- check by looking for files in library path # that responds to the $file_magic_cmd with a given extended regex. # If you have 'file' or equivalent on your system and you're not sure # whether 'pass_all' will *always* work, you probably want this one. case $host_os in aix[[4-9]]*) lt_cv_deplibs_check_method=pass_all ;; beos*) lt_cv_deplibs_check_method=pass_all ;; bsdi[[45]]*) lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)' lt_cv_file_magic_cmd='$FILECMD -L' lt_cv_file_magic_test_file=/shlib/libc.so ;; cygwin*) # func_win32_libid is a shell function defined in ltmain.sh lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' lt_cv_file_magic_cmd='func_win32_libid' ;; mingw* | pw32*) # Base MSYS/MinGW do not provide the 'file' command needed by # func_win32_libid shell function, so use a weaker test based on 'objdump', # unless we find 'file', for example because we are cross-compiling. if ( file / ) >/dev/null 2>&1; then lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' lt_cv_file_magic_cmd='func_win32_libid' else # Keep this pattern in sync with the one in func_win32_libid. lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' lt_cv_file_magic_cmd='$OBJDUMP -f' fi ;; cegcc*) # use the weaker test based on 'objdump'. See mingw*. lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' lt_cv_file_magic_cmd='$OBJDUMP -f' ;; darwin* | rhapsody*) lt_cv_deplibs_check_method=pass_all ;; freebsd* | dragonfly* | midnightbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then case $host_cpu in i*86 ) # Not sure whether the presence of OpenBSD here was a mistake. # Let's accept both of them until this is cleared up. lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' lt_cv_file_magic_cmd=$FILECMD lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` ;; esac else lt_cv_deplibs_check_method=pass_all fi ;; haiku*) lt_cv_deplibs_check_method=pass_all ;; hpux10.20* | hpux11*) lt_cv_file_magic_cmd=$FILECMD case $host_cpu in ia64*) lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so ;; hppa*64*) [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]'] lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl ;; *) lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library' lt_cv_file_magic_test_file=/usr/lib/libc.sl ;; esac ;; interix[[3-9]]*) # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$' ;; irix5* | irix6* | nonstopux*) case $LD in *-32|*"-32 ") libmagic=32-bit;; *-n32|*"-n32 ") libmagic=N32;; *-64|*"-64 ") libmagic=64-bit;; *) libmagic=never-match;; esac lt_cv_deplibs_check_method=pass_all ;; # This must be glibc/ELF. linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) lt_cv_deplibs_check_method=pass_all ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' fi ;; newos6*) lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' lt_cv_file_magic_cmd=$FILECMD lt_cv_file_magic_test_file=/usr/lib/libnls.so ;; *nto* | *qnx*) lt_cv_deplibs_check_method=pass_all ;; openbsd* | bitrig*) if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' fi ;; osf3* | osf4* | osf5*) lt_cv_deplibs_check_method=pass_all ;; rdos*) lt_cv_deplibs_check_method=pass_all ;; solaris*) lt_cv_deplibs_check_method=pass_all ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) lt_cv_deplibs_check_method=pass_all ;; sysv4 | sysv4.3*) case $host_vendor in motorola) lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]' lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` ;; ncr) lt_cv_deplibs_check_method=pass_all ;; sequent) lt_cv_file_magic_cmd='/bin/file' lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' ;; sni) lt_cv_file_magic_cmd='/bin/file' lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" lt_cv_file_magic_test_file=/lib/libc.so ;; siemens) lt_cv_deplibs_check_method=pass_all ;; pc) lt_cv_deplibs_check_method=pass_all ;; esac ;; tpf*) lt_cv_deplibs_check_method=pass_all ;; os2*) lt_cv_deplibs_check_method=pass_all ;; esac ]) file_magic_glob= want_nocaseglob=no if test "$build" = "$host"; then case $host_os in mingw* | pw32*) if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then want_nocaseglob=yes else file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"` fi ;; esac fi file_magic_cmd=$lt_cv_file_magic_cmd deplibs_check_method=$lt_cv_deplibs_check_method test -z "$deplibs_check_method" && deplibs_check_method=unknown _LT_DECL([], [deplibs_check_method], [1], [Method to check whether dependent libraries are shared objects]) _LT_DECL([], [file_magic_cmd], [1], [Command to use when deplibs_check_method = "file_magic"]) _LT_DECL([], [file_magic_glob], [1], [How to find potential files when deplibs_check_method = "file_magic"]) _LT_DECL([], [want_nocaseglob], [1], [Find potential files using nocaseglob when deplibs_check_method = "file_magic"]) ])# _LT_CHECK_MAGIC_METHOD # LT_PATH_NM # ---------- # find the pathname to a BSD- or MS-compatible name lister AC_DEFUN([LT_PATH_NM], [AC_REQUIRE([AC_PROG_CC])dnl AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM, [if test -n "$NM"; then # Let the user override the test. lt_cv_path_NM=$NM else lt_nm_to_check=${ac_tool_prefix}nm if test -n "$ac_tool_prefix" && test "$build" = "$host"; then lt_nm_to_check="$lt_nm_to_check nm" fi for lt_tmp_nm in $lt_nm_to_check; do lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. tmp_nm=$ac_dir/$lt_tmp_nm if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then # Check to see if the nm accepts a BSD-compat flag. # Adding the 'sed 1q' prevents false positives on HP-UX, which says: # nm: unknown option "B" ignored # Tru64's nm complains that /dev/null is an invalid object file # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty case $build_os in mingw*) lt_bad_file=conftest.nm/nofile ;; *) lt_bad_file=/dev/null ;; esac case `"$tmp_nm" -B $lt_bad_file 2>&1 | $SED '1q'` in *$lt_bad_file* | *'Invalid file or object type'*) lt_cv_path_NM="$tmp_nm -B" break 2 ;; *) case `"$tmp_nm" -p /dev/null 2>&1 | $SED '1q'` in */dev/null*) lt_cv_path_NM="$tmp_nm -p" break 2 ;; *) lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but continue # so that we can try to find one that supports BSD flags ;; esac ;; esac fi done IFS=$lt_save_ifs done : ${lt_cv_path_NM=no} fi]) if test no != "$lt_cv_path_NM"; then NM=$lt_cv_path_NM else # Didn't find any BSD compatible name lister, look for dumpbin. if test -n "$DUMPBIN"; then : # Let the user override the test. else AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :) case `$DUMPBIN -symbols -headers /dev/null 2>&1 | $SED '1q'` in *COFF*) DUMPBIN="$DUMPBIN -symbols -headers" ;; *) DUMPBIN=: ;; esac fi AC_SUBST([DUMPBIN]) if test : != "$DUMPBIN"; then NM=$DUMPBIN fi fi test -z "$NM" && NM=nm AC_SUBST([NM]) _LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface], [lt_cv_nm_interface="BSD nm" echo "int some_variable = 0;" > conftest.$ac_ext (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD) (eval "$ac_compile" 2>conftest.err) cat conftest.err >&AS_MESSAGE_LOG_FD (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD) (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) cat conftest.err >&AS_MESSAGE_LOG_FD (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD) cat conftest.out >&AS_MESSAGE_LOG_FD if $GREP 'External.*some_variable' conftest.out > /dev/null; then lt_cv_nm_interface="MS dumpbin" fi rm -f conftest*]) ])# LT_PATH_NM # Old names: AU_ALIAS([AM_PROG_NM], [LT_PATH_NM]) AU_ALIAS([AC_PROG_NM], [LT_PATH_NM]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AM_PROG_NM], []) dnl AC_DEFUN([AC_PROG_NM], []) # _LT_CHECK_SHAREDLIB_FROM_LINKLIB # -------------------------------- # how to determine the name of the shared library # associated with a specific link library. # -- PORTME fill in with the dynamic library characteristics m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB], [m4_require([_LT_DECL_EGREP]) m4_require([_LT_DECL_OBJDUMP]) m4_require([_LT_DECL_DLLTOOL]) AC_CACHE_CHECK([how to associate runtime and link libraries], lt_cv_sharedlib_from_linklib_cmd, [lt_cv_sharedlib_from_linklib_cmd='unknown' case $host_os in cygwin* | mingw* | pw32* | cegcc*) # two different shell functions defined in ltmain.sh; # decide which one to use based on capabilities of $DLLTOOL case `$DLLTOOL --help 2>&1` in *--identify-strict*) lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib ;; *) lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback ;; esac ;; *) # fallback: assume linklib IS sharedlib lt_cv_sharedlib_from_linklib_cmd=$ECHO ;; esac ]) sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO _LT_DECL([], [sharedlib_from_linklib_cmd], [1], [Command to associate shared and link libraries]) ])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB # _LT_PATH_MANIFEST_TOOL # ---------------------- # locate the manifest tool m4_defun([_LT_PATH_MANIFEST_TOOL], [AC_CHECK_TOOL(MANIFEST_TOOL, mt, :) test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool], [lt_cv_path_mainfest_tool=no echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out cat conftest.err >&AS_MESSAGE_LOG_FD if $GREP 'Manifest Tool' conftest.out > /dev/null; then lt_cv_path_mainfest_tool=yes fi rm -f conftest*]) if test yes != "$lt_cv_path_mainfest_tool"; then MANIFEST_TOOL=: fi _LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl ])# _LT_PATH_MANIFEST_TOOL # _LT_DLL_DEF_P([FILE]) # --------------------- # True iff FILE is a Windows DLL '.def' file. # Keep in sync with func_dll_def_p in the libtool script AC_DEFUN([_LT_DLL_DEF_P], [dnl test DEF = "`$SED -n dnl -e '\''s/^[[ ]]*//'\'' dnl Strip leading whitespace -e '\''/^\(;.*\)*$/d'\'' dnl Delete empty lines and comments -e '\''s/^\(EXPORTS\|LIBRARY\)\([[ ]].*\)*$/DEF/p'\'' dnl -e q dnl Only consider the first "real" line $1`" dnl ])# _LT_DLL_DEF_P # LT_LIB_M # -------- # check for math library AC_DEFUN([LT_LIB_M], [AC_REQUIRE([AC_CANONICAL_HOST])dnl LIBM= case $host in *-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*) # These system don't have libm, or don't need it ;; *-ncr-sysv4.3*) AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM=-lmw) AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") ;; *) AC_CHECK_LIB(m, cos, LIBM=-lm) ;; esac AC_SUBST([LIBM]) ])# LT_LIB_M # Old name: AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_CHECK_LIBM], []) # _LT_COMPILER_NO_RTTI([TAGNAME]) # ------------------------------- m4_defun([_LT_COMPILER_NO_RTTI], [m4_require([_LT_TAG_COMPILER])dnl _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= if test yes = "$GCC"; then case $cc_basename in nvcc*) _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;; *) _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;; esac _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], lt_cv_prog_compiler_rtti_exceptions, [-fno-rtti -fno-exceptions], [], [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) fi _LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1], [Compiler flag to turn off builtin functions]) ])# _LT_COMPILER_NO_RTTI # _LT_CMD_GLOBAL_SYMBOLS # ---------------------- m4_defun([_LT_CMD_GLOBAL_SYMBOLS], [AC_REQUIRE([AC_CANONICAL_HOST])dnl AC_REQUIRE([AC_PROG_CC])dnl AC_REQUIRE([AC_PROG_AWK])dnl AC_REQUIRE([LT_PATH_NM])dnl AC_REQUIRE([LT_PATH_LD])dnl m4_require([_LT_DECL_SED])dnl m4_require([_LT_DECL_EGREP])dnl m4_require([_LT_TAG_COMPILER])dnl # Check for command to grab the raw symbol name followed by C symbol from nm. AC_MSG_CHECKING([command to parse $NM output from $compiler object]) AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], [ # These are sane defaults that work on at least a few old systems. # [They come from Ultrix. What could be older than Ultrix?!! ;)] # Character class describing NM global symbol codes. symcode='[[BCDEGRST]]' # Regexp to match symbols that can be accessed directly from C. sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' # Define system-specific variables. case $host_os in aix*) symcode='[[BCDT]]' ;; cygwin* | mingw* | pw32* | cegcc*) symcode='[[ABCDGISTW]]' ;; hpux*) if test ia64 = "$host_cpu"; then symcode='[[ABCDEGRST]]' fi ;; irix* | nonstopux*) symcode='[[BCDEGRST]]' ;; osf*) symcode='[[BCDEGQRST]]' ;; solaris*) symcode='[[BDRT]]' ;; sco3.2v5*) symcode='[[DT]]' ;; sysv4.2uw2*) symcode='[[DT]]' ;; sysv5* | sco5v6* | unixware* | OpenUNIX*) symcode='[[ABDT]]' ;; sysv4) symcode='[[DFNSTU]]' ;; esac # If we're using GNU nm, then use its standard symbol codes. case `$NM -V 2>&1` in *GNU* | *'with BFD'*) symcode='[[ABCDGIRSTW]]' ;; esac if test "$lt_cv_nm_interface" = "MS dumpbin"; then # Gets list of data symbols to import. lt_cv_sys_global_symbol_to_import="$SED -n -e 's/^I .* \(.*\)$/\1/p'" # Adjust the below global symbol transforms to fixup imported variables. lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'" lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'" lt_c_name_lib_hook="\ -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\ -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'" else # Disable hooks by default. lt_cv_sys_global_symbol_to_import= lt_cdecl_hook= lt_c_name_hook= lt_c_name_lib_hook= fi # Transform an extracted symbol line into a proper C declaration. # Some systems (esp. on ia64) link data and code symbols differently, # so use this general approach. lt_cv_sys_global_symbol_to_cdecl="$SED -n"\ $lt_cdecl_hook\ " -e 's/^T .* \(.*\)$/extern int \1();/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'" # Transform an extracted symbol line into symbol name and symbol address lt_cv_sys_global_symbol_to_c_name_address="$SED -n"\ $lt_c_name_hook\ " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'" # Transform an extracted symbol line into symbol name with lib prefix and # symbol address. lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="$SED -n"\ $lt_c_name_lib_hook\ " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ " -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'" # Handle CRLF in mingw tool chain opt_cr= case $build_os in mingw*) opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp ;; esac # Try without a prefix underscore, then with it. for ac_symprfx in "" "_"; do # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. symxfrm="\\1 $ac_symprfx\\2 \\2" # Write the raw and C identifiers. if test "$lt_cv_nm_interface" = "MS dumpbin"; then # Fake it for dumpbin and say T for any non-static function, # D for any global variable and I for any imported variable. # Also find C++ and __fastcall symbols from MSVC++ or ICC, # which start with @ or ?. lt_cv_sys_global_symbol_pipe="$AWK ['"\ " {last_section=section; section=\$ 3};"\ " /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ " /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\ " /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\ " /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\ " \$ 0!~/External *\|/{next};"\ " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ " {if(hide[section]) next};"\ " {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\ " {split(\$ 0,a,/\||\r/); split(a[2],s)};"\ " s[1]~/^[@?]/{print f,s[1],s[1]; next};"\ " s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\ " ' prfx=^$ac_symprfx]" else lt_cv_sys_global_symbol_pipe="$SED -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" fi lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | $SED '/ __gnu_lto/d'" # Check to see that the pipe works correctly. pipe_works=no rm -f conftest* cat > conftest.$ac_ext <<_LT_EOF #ifdef __cplusplus extern "C" { #endif char nm_test_var; void nm_test_func(void); void nm_test_func(void){} #ifdef __cplusplus } #endif int main(){nm_test_var='a';nm_test_func();return(0);} _LT_EOF if AC_TRY_EVAL(ac_compile); then # Now try to grab the symbols. nlist=conftest.nm $ECHO "$as_me:$LINENO: $NM conftest.$ac_objext | $lt_cv_sys_global_symbol_pipe > $nlist" >&AS_MESSAGE_LOG_FD if eval "$NM" conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist 2>&AS_MESSAGE_LOG_FD && test -s "$nlist"; then # Try sorting and uniquifying the output. if sort "$nlist" | uniq > "$nlist"T; then mv -f "$nlist"T "$nlist" else rm -f "$nlist"T fi # Make sure that we snagged all the symbols we need. if $GREP ' nm_test_var$' "$nlist" >/dev/null; then if $GREP ' nm_test_func$' "$nlist" >/dev/null; then cat <<_LT_EOF > conftest.$ac_ext /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ #if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE /* DATA imports from DLLs on WIN32 can't be const, because runtime relocations are performed -- see ld's documentation on pseudo-relocs. */ # define LT@&t@_DLSYM_CONST #elif defined __osf__ /* This system does not cope well with relocations in const data. */ # define LT@&t@_DLSYM_CONST #else # define LT@&t@_DLSYM_CONST const #endif #ifdef __cplusplus extern "C" { #endif _LT_EOF # Now generate the symbol file. eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' cat <<_LT_EOF >> conftest.$ac_ext /* The mapping between symbol names and symbols. */ LT@&t@_DLSYM_CONST struct { const char *name; void *address; } lt__PROGRAM__LTX_preloaded_symbols[[]] = { { "@PROGRAM@", (void *) 0 }, _LT_EOF $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext cat <<\_LT_EOF >> conftest.$ac_ext {0, (void *) 0} }; /* This works around a problem in FreeBSD linker */ #ifdef FREEBSD_WORKAROUND static const void *lt_preloaded_setup() { return lt__PROGRAM__LTX_preloaded_symbols; } #endif #ifdef __cplusplus } #endif _LT_EOF # Now try linking the two files. mv conftest.$ac_objext conftstm.$ac_objext lt_globsym_save_LIBS=$LIBS lt_globsym_save_CFLAGS=$CFLAGS LIBS=conftstm.$ac_objext CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" if AC_TRY_EVAL(ac_link) && test -s conftest$ac_exeext; then pipe_works=yes fi LIBS=$lt_globsym_save_LIBS CFLAGS=$lt_globsym_save_CFLAGS else echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD fi else echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD fi else echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD fi else echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD cat conftest.$ac_ext >&5 fi rm -rf conftest* conftst* # Do not use the global_symbol_pipe unless it works. if test yes = "$pipe_works"; then break else lt_cv_sys_global_symbol_pipe= fi done ]) if test -z "$lt_cv_sys_global_symbol_pipe"; then lt_cv_sys_global_symbol_to_cdecl= fi if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then AC_MSG_RESULT(failed) else AC_MSG_RESULT(ok) fi # Response file support. if test "$lt_cv_nm_interface" = "MS dumpbin"; then nm_file_list_spec='@' elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then nm_file_list_spec='@' fi _LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1], [Take the output of nm and produce a listing of raw symbols and C names]) _LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1], [Transform the output of nm in a proper C declaration]) _LT_DECL([global_symbol_to_import], [lt_cv_sys_global_symbol_to_import], [1], [Transform the output of nm into a list of symbols to manually relocate]) _LT_DECL([global_symbol_to_c_name_address], [lt_cv_sys_global_symbol_to_c_name_address], [1], [Transform the output of nm in a C name address pair]) _LT_DECL([global_symbol_to_c_name_address_lib_prefix], [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1], [Transform the output of nm in a C name address pair when lib prefix is needed]) _LT_DECL([nm_interface], [lt_cv_nm_interface], [1], [The name lister interface]) _LT_DECL([], [nm_file_list_spec], [1], [Specify filename containing input files for $NM]) ]) # _LT_CMD_GLOBAL_SYMBOLS # _LT_COMPILER_PIC([TAGNAME]) # --------------------------- m4_defun([_LT_COMPILER_PIC], [m4_require([_LT_TAG_COMPILER])dnl _LT_TAGVAR(lt_prog_compiler_wl, $1)= _LT_TAGVAR(lt_prog_compiler_pic, $1)= _LT_TAGVAR(lt_prog_compiler_static, $1)= m4_if([$1], [CXX], [ # C++ specific cases for pic, static, wl, etc. if test yes = "$GXX"; then _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' case $host_os in aix*) # All AIX code is PIC. if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' fi _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; m68k) # FIXME: we need at least 68020 code to build shared libraries, but # adding the '-m68020' flag to GCC prevents building anything better, # like '-m68040'. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' ;; esac ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | cygwin* | os2* | pw32* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style # (--disable-auto-import) libraries m4_if([$1], [GCJ], [], [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) case $host_os in os2*) _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' ;; esac ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' ;; *djgpp*) # DJGPP does not support shared libraries at all _LT_TAGVAR(lt_prog_compiler_pic, $1)= ;; haiku*) # PIC is the default for Haiku. # The "-static" flag exists, but is broken. _LT_TAGVAR(lt_prog_compiler_static, $1)= ;; interix[[3-9]]*) # Interix 3.x gcc -fpic/-fPIC options generate broken code. # Instead, we relocate shared libraries at runtime. ;; sysv4*MP*) if test -d /usr/nec; then _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic fi ;; hpux*) # PIC is the default for 64-bit PA HP-UX, but not for 32-bit # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag # sets the default TLS model and affects inlining. case $host_cpu in hppa*64*) ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; esac ;; *qnx* | *nto*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; esac else case $host_os in aix[[4-9]]*) # All AIX code is PIC. if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' else _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' fi ;; chorus*) case $cc_basename in cxch68*) # Green Hills C++ Compiler # _LT_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" ;; esac ;; mingw* | cygwin* | os2* | pw32* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). m4_if([$1], [GCJ], [], [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) ;; dgux*) case $cc_basename in ec++*) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' ;; ghcx*) # Green Hills C++ Compiler _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' ;; *) ;; esac ;; freebsd* | dragonfly* | midnightbsd*) # FreeBSD uses GNU C++ ;; hpux9* | hpux10* | hpux11*) case $cc_basename in CC*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' if test ia64 != "$host_cpu"; then _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' fi ;; aCC*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' ;; esac ;; *) ;; esac ;; interix*) # This is c89, which is MS Visual C++ (no shared libs) # Anyone wants to do a port? ;; irix5* | irix6* | nonstopux*) case $cc_basename in CC*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' # CC pic flag -KPIC is the default. ;; *) ;; esac ;; linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in KCC*) # KAI C++ Compiler _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; ecpc* ) # old Intel C++ for x86_64, which still supported -KPIC. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; icpc* ) # Intel C++, used to be incompatible with GCC. # ICC 10 doesn't accept -KPIC any more. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; pgCC* | pgcpp*) # Portland Group C++ compiler _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; cxx*) # Compaq C++ # Make sure the PIC flag is empty. It appears that all Alpha # Linux and Compaq Tru64 Unix objects are PIC. _LT_TAGVAR(lt_prog_compiler_pic, $1)= _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL 8.0, 9.0 on PPC and BlueGene _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' ;; *) case `$CC -V 2>&1 | $SED 5q` in *Sun\ C*) # Sun C++ 5.9 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' ;; esac ;; esac ;; lynxos*) ;; m88k*) ;; mvs*) case $cc_basename in cxx*) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' ;; *) ;; esac ;; netbsd* | netbsdelf*-gnu) ;; *qnx* | *nto*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' ;; osf3* | osf4* | osf5*) case $cc_basename in KCC*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' ;; RCC*) # Rational C++ 2.4.1 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' ;; cxx*) # Digital/Compaq C++ _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' # Make sure the PIC flag is empty. It appears that all Alpha # Linux and Compaq Tru64 Unix objects are PIC. _LT_TAGVAR(lt_prog_compiler_pic, $1)= _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; *) ;; esac ;; psos*) ;; solaris*) case $cc_basename in CC* | sunCC*) # Sun C++ 4.2, 5.x and Centerline C++ _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' ;; gcx*) # Green Hills C++ Compiler _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' ;; *) ;; esac ;; sunos4*) case $cc_basename in CC*) # Sun C++ 4.x _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; lcc*) # Lucid _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' ;; *) ;; esac ;; sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) case $cc_basename in CC*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; esac ;; tandem*) case $cc_basename in NCC*) # NonStop-UX NCC 3.20 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' ;; *) ;; esac ;; vxworks*) ;; *) _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no ;; esac fi ], [ if test yes = "$GCC"; then _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' case $host_os in aix*) # All AIX code is PIC. if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' fi _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; m68k) # FIXME: we need at least 68020 code to build shared libraries, but # adding the '-m68020' flag to GCC prevents building anything better, # like '-m68040'. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' ;; esac ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | cygwin* | pw32* | os2* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style # (--disable-auto-import) libraries m4_if([$1], [GCJ], [], [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) case $host_os in os2*) _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' ;; esac ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' ;; haiku*) # PIC is the default for Haiku. # The "-static" flag exists, but is broken. _LT_TAGVAR(lt_prog_compiler_static, $1)= ;; hpux*) # PIC is the default for 64-bit PA HP-UX, but not for 32-bit # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag # sets the default TLS model and affects inlining. case $host_cpu in hppa*64*) # +Z the default ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; esac ;; interix[[3-9]]*) # Interix 3.x gcc -fpic/-fPIC options generate broken code. # Instead, we relocate shared libraries at runtime. ;; msdosdjgpp*) # Just because we use GCC doesn't mean we suddenly get shared libraries # on systems that don't support them. _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no enable_shared=no ;; *nto* | *qnx*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' ;; sysv4*MP*) if test -d /usr/nec; then _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic fi ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; esac case $cc_basename in nvcc*) # Cuda Compiler Driver 2.2 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker ' if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then _LT_TAGVAR(lt_prog_compiler_pic, $1)="-Xcompiler $_LT_TAGVAR(lt_prog_compiler_pic, $1)" fi ;; esac else # PORTME Check for flag to pass linker flags through the system compiler. case $host_os in aix*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' else _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' fi ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' case $cc_basename in nagfor*) # NAG Fortran compiler _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; esac ;; mingw* | cygwin* | pw32* | os2* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). m4_if([$1], [GCJ], [], [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) case $host_os in os2*) _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' ;; esac ;; hpux9* | hpux10* | hpux11*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but # not for PA HP-UX. case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' ;; esac # Is there a better lt_prog_compiler_static that works with the bundled CC? _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' ;; irix5* | irix6* | nonstopux*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' # PIC (with -KPIC) is the default. _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in # old Intel for x86_64, which still supported -KPIC. ecc*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; # flang / f18. f95 an alias for gfortran or flang on Debian flang* | f18* | f95*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; # icc used to be incompatible with GCC. # ICC 10 doesn't accept -KPIC any more. icc* | ifort*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; # Lahey Fortran 8.1. lf95*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared' _LT_TAGVAR(lt_prog_compiler_static, $1)='--static' ;; nagfor*) # NAG Fortran compiler _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; tcc*) # Fabrice Bellard et al's Tiny C Compiler _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) # Portland Group compilers (*not* the Pentium gcc compiler, # which looks to be a dead project) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; ccc*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' # All Alpha code is PIC. _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; xl* | bgxl* | bgf* | mpixl*) # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' ;; *) case `$CC -V 2>&1 | $SED 5q` in *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*) # Sun Fortran 8.3 passes all unrecognized flags to the linker _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' _LT_TAGVAR(lt_prog_compiler_wl, $1)='' ;; *Sun\ F* | *Sun*Fortran*) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' ;; *Sun\ C*) # Sun C 5.9 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' ;; *Intel*\ [[CF]]*Compiler*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; *Portland\ Group*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; esac ;; esac ;; newsos6) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; *nto* | *qnx*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' ;; osf3* | osf4* | osf5*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' # All OSF/1 code is PIC. _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; rdos*) _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; solaris*) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' case $cc_basename in f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; *) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; esac ;; sunos4*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; sysv4 | sysv4.2uw2* | sysv4.3*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; sysv4*MP*) if test -d /usr/nec; then _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' fi ;; sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; unicos*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no ;; uts4*) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; *) _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no ;; esac fi ]) case $host_os in # For platforms that do not support PIC, -DPIC is meaningless: *djgpp*) _LT_TAGVAR(lt_prog_compiler_pic, $1)= ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])" ;; esac AC_CACHE_CHECK([for $compiler option to produce PIC], [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)], [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)]) _LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1) # # Check to make sure the PIC flag actually works. # if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works], [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)], [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [], [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in "" | " "*) ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;; esac], [_LT_TAGVAR(lt_prog_compiler_pic, $1)= _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) fi _LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1], [Additional compiler flags for building library objects]) _LT_TAGDECL([wl], [lt_prog_compiler_wl], [1], [How to pass a linker flag through the compiler]) # # Check to make sure the static flag actually works. # wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\" _LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1), $lt_tmp_static_flag, [], [_LT_TAGVAR(lt_prog_compiler_static, $1)=]) _LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1], [Compiler flag to prevent dynamic linking]) ])# _LT_COMPILER_PIC # _LT_LINKER_SHLIBS([TAGNAME]) # ---------------------------- # See if the linker supports building shared libraries. m4_defun([_LT_LINKER_SHLIBS], [AC_REQUIRE([LT_PATH_LD])dnl AC_REQUIRE([LT_PATH_NM])dnl m4_require([_LT_PATH_MANIFEST_TOOL])dnl m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_EGREP])dnl m4_require([_LT_DECL_SED])dnl m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl m4_require([_LT_TAG_COMPILER])dnl AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) m4_if([$1], [CXX], [ _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] case $host_os in aix[[4-9]]*) # If we're using GNU nm, then we don't want the "-C" option. # -C means demangle to GNU nm, but means don't demangle to AIX nm. # Without the "-l" option, or with the "-B" option, AIX nm treats # weak defined symbols like other global defined symbols, whereas # GNU nm marks them as "W". # While the 'weak' keyword is ignored in the Export File, we need # it in the Import File for the 'aix-soname' feature, so we have # to replace the "-B" option with "-P" for AIX nm. if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' else _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' fi ;; pw32*) _LT_TAGVAR(export_symbols_cmds, $1)=$ltdll_cmds ;; cygwin* | mingw* | cegcc*) case $cc_basename in cl* | icl*) _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' ;; *) _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] ;; esac ;; linux* | k*bsd*-gnu | gnu*) _LT_TAGVAR(link_all_deplibs, $1)=no ;; *) _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' ;; esac ], [ runpath_var= _LT_TAGVAR(allow_undefined_flag, $1)= _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(archive_cmds, $1)= _LT_TAGVAR(archive_expsym_cmds, $1)= _LT_TAGVAR(compiler_needs_object, $1)=no _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no _LT_TAGVAR(export_dynamic_flag_spec, $1)= _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' _LT_TAGVAR(hardcode_automatic, $1)=no _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_TAGVAR(hardcode_libdir_separator, $1)= _LT_TAGVAR(hardcode_minus_L, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported _LT_TAGVAR(inherit_rpath, $1)=no _LT_TAGVAR(link_all_deplibs, $1)=unknown _LT_TAGVAR(module_cmds, $1)= _LT_TAGVAR(module_expsym_cmds, $1)= _LT_TAGVAR(old_archive_from_new_cmds, $1)= _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)= _LT_TAGVAR(thread_safe_flag_spec, $1)= _LT_TAGVAR(whole_archive_flag_spec, $1)= # include_expsyms should be a list of space-separated symbols to be *always* # included in the symbol list _LT_TAGVAR(include_expsyms, $1)= # exclude_expsyms can be an extended regexp of symbols to exclude # it will be wrapped by ' (' and ')$', so one must not match beginning or # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc', # as well as any symbol that contains 'd'. _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out # platforms (ab)use it in PIC code, but their linkers get confused if # the symbol is explicitly referenced. Since portable code cannot # rely on this symbol name, it's probably fine to never include it in # preloaded symbol tables. # Exclude shared library initialization/finalization symbols. dnl Note also adjust exclude_expsyms for C++ above. extract_expsyms_cmds= case $host_os in cygwin* | mingw* | pw32* | cegcc*) # FIXME: the MSVC++ and ICC port hasn't been tested in a loooong time # When not using gcc, we currently assume that we are using # Microsoft Visual C++ or Intel C++ Compiler. if test yes != "$GCC"; then with_gnu_ld=no fi ;; interix*) # we just hope/assume this is gcc and not c89 (= MSVC++ or ICC) with_gnu_ld=yes ;; openbsd* | bitrig*) with_gnu_ld=no ;; linux* | k*bsd*-gnu | gnu*) _LT_TAGVAR(link_all_deplibs, $1)=no ;; esac _LT_TAGVAR(ld_shlibs, $1)=yes # On some targets, GNU ld is compatible enough with the native linker # that we're better off using the native interface for both. lt_use_gnu_ld_interface=no if test yes = "$with_gnu_ld"; then case $host_os in aix*) # The AIX port of GNU ld has always aspired to compatibility # with the native linker. However, as the warning in the GNU ld # block says, versions before 2.19.5* couldn't really create working # shared libraries, regardless of the interface used. case `$LD -v 2>&1` in *\ \(GNU\ Binutils\)\ 2.19.5*) ;; *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;; *\ \(GNU\ Binutils\)\ [[3-9]]*) ;; *) lt_use_gnu_ld_interface=yes ;; esac ;; *) lt_use_gnu_ld_interface=yes ;; esac fi if test yes = "$lt_use_gnu_ld_interface"; then # If archive_cmds runs LD, not CC, wlarc should be empty wlarc='$wl' # Set some defaults for GNU ld with shared library support. These # are reset later if shared libraries are not supported. Putting them # here allows them to be overridden if necessary. runpath_var=LD_RUN_PATH _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' # ancient GNU ld didn't support --whole-archive et. al. if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' else _LT_TAGVAR(whole_archive_flag_spec, $1)= fi supports_anon_versioning=no case `$LD -v | $SED -e 's/([[^)]]\+)\s\+//' 2>&1` in *GNU\ gold*) supports_anon_versioning=yes ;; *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... *\ 2.11.*) ;; # other 2.11 versions *) supports_anon_versioning=yes ;; esac # See if GNU ld supports shared libraries. case $host_os in aix[[3-9]]*) # On AIX/PPC, the GNU linker is very broken if test ia64 != "$host_cpu"; then _LT_TAGVAR(ld_shlibs, $1)=no cat <<_LT_EOF 1>&2 *** Warning: the GNU linker, at least up to release 2.19, is reported *** to be unable to reliably create shared libraries on AIX. *** Therefore, libtool is disabling shared libraries support. If you *** really care for shared libraries, you may want to install binutils *** 2.20 or above, or modify your PATH so that a non-GNU linker is found. *** You will then need to restart the configuration process. _LT_EOF fi ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='' ;; m68k) _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_minus_L, $1)=yes ;; esac ;; beos*) if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then _LT_TAGVAR(allow_undefined_flag, $1)=unsupported # Joseph Beckenbach says some releases of gcc # support --undefined. This deserves some investigation. FIXME _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; cygwin* | mingw* | pw32* | cegcc*) # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, # as there is no search path for DLLs. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' # If the export-symbols file already is a .def file, use it as # is; otherwise, prepend EXPORTS... _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then cp $export_symbols $output_objdir/$soname.def; else echo EXPORTS > $output_objdir/$soname.def; cat $export_symbols >> $output_objdir/$soname.def; fi~ $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; haiku*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(link_all_deplibs, $1)=yes ;; os2*) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(allow_undefined_flag, $1)=unsupported shrext_cmds=.dll _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ prefix_cmds="$SED"~ if test EXPORTS = "`$SED 1q $export_symbols`"; then prefix_cmds="$prefix_cmds -e 1d"; fi~ prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes _LT_TAGVAR(file_list_spec, $1)='@' ;; interix[[3-9]]*) _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) tmp_diet=no if test linux-dietlibc = "$host_os"; then case $cc_basename in diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) esac fi if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ && test no = "$tmp_diet" then tmp_addflag=' $pic_flag' tmp_sharedflag='-shared' case $cc_basename,$host_cpu in pgcc*) # Portland Group C compiler _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' tmp_addflag=' $pic_flag' ;; pgf77* | pgf90* | pgf95* | pgfortran*) # Portland Group f77 and f90 compilers _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' tmp_addflag=' $pic_flag -Mnomain' ;; ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 tmp_addflag=' -i_dynamic' ;; efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 tmp_addflag=' -i_dynamic -nofor_main' ;; ifc* | ifort*) # Intel Fortran compiler tmp_addflag=' -nofor_main' ;; lf95*) # Lahey Fortran 8.1 _LT_TAGVAR(whole_archive_flag_spec, $1)= tmp_sharedflag='--shared' ;; nagfor*) # NAGFOR 5.3 tmp_sharedflag='-Wl,-shared' ;; xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below) tmp_sharedflag='-qmkshrobj' tmp_addflag= ;; nvcc*) # Cuda Compiler Driver 2.2 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' _LT_TAGVAR(compiler_needs_object, $1)=yes ;; esac case `$CC -V 2>&1 | $SED 5q` in *Sun\ C*) # Sun C 5.9 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' _LT_TAGVAR(compiler_needs_object, $1)=yes tmp_sharedflag='-G' ;; *Sun\ F*) # Sun Fortran 8.3 tmp_sharedflag='-G' ;; esac _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' if test yes = "$supports_anon_versioning"; then _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' fi case $cc_basename in tcc*) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='-rdynamic' ;; xlf* | bgf* | bgxlf* | mpixlf*) # IBM XL Fortran 10.1 on PPC cannot create shared libs itself _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' if test yes = "$supports_anon_versioning"; then _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' fi ;; esac else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' wlarc= else _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' fi ;; solaris*) if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then _LT_TAGVAR(ld_shlibs, $1)=no cat <<_LT_EOF 1>&2 *** Warning: The releases 2.8.* of the GNU linker cannot reliably *** create shared libraries on Solaris systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.9.1 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. _LT_EOF elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) case `$LD -v 2>&1` in *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*) _LT_TAGVAR(ld_shlibs, $1)=no cat <<_LT_EOF 1>&2 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot *** reliably create shared libraries on SCO systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.16.91.0.3 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. _LT_EOF ;; *) # For security reasons, it is highly recommended that you always # use absolute paths for naming shared libraries, and exclude the # DT_RUNPATH tag from executables and libraries. But doing so # requires that you compile everything twice, which is a pain. if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; sunos4*) _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' wlarc= _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; *) if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac if test no = "$_LT_TAGVAR(ld_shlibs, $1)"; then runpath_var= _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_TAGVAR(export_dynamic_flag_spec, $1)= _LT_TAGVAR(whole_archive_flag_spec, $1)= fi else # PORTME fill in a description of your system's linker (not GNU ld) case $host_os in aix3*) _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=yes _LT_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' # Note: this linker hardcodes the directories in LIBPATH if there # are no directories specified by -L. _LT_TAGVAR(hardcode_minus_L, $1)=yes if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then # Neither direct hardcoding nor static linking is supported with a # broken collect2. _LT_TAGVAR(hardcode_direct, $1)=unsupported fi ;; aix[[4-9]]*) if test ia64 = "$host_cpu"; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' no_entry_flag= else # If we're using GNU nm, then we don't want the "-C" option. # -C means demangle to GNU nm, but means don't demangle to AIX nm. # Without the "-l" option, or with the "-B" option, AIX nm treats # weak defined symbols like other global defined symbols, whereas # GNU nm marks them as "W". # While the 'weak' keyword is ignored in the Export File, we need # it in the Import File for the 'aix-soname' feature, so we have # to replace the "-B" option with "-P" for AIX nm. if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' else _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' fi aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we # have runtime linking enabled, and use it for executables. # For shared libraries, we enable/disable runtime linking # depending on the kind of the shared library created - # when "with_aix_soname,aix_use_runtimelinking" is: # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables # "aix,yes" lib.so shared, rtl:yes, for executables # lib.a static archive # "both,no" lib.so.V(shr.o) shared, rtl:yes # lib.a(lib.so.V) shared, rtl:no, for executables # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a(lib.so.V) shared, rtl:no # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a static archive case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) for ld_flag in $LDFLAGS; do if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then aix_use_runtimelinking=yes break fi done if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then # With aix-soname=svr4, we create the lib.so.V shared archives only, # so we don't have lib.a shared libs to link our executables. # We have to force runtime linking in this case. aix_use_runtimelinking=yes LDFLAGS="$LDFLAGS -Wl,-brtl" fi ;; esac exp_sym_flag='-bexport' no_entry_flag='-bnoentry' fi # When large executables or shared objects are built, AIX ld can # have problems creating the table of contents. If linking a library # or program results in "error TOC overflow" add -mminimal-toc to # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. _LT_TAGVAR(archive_cmds, $1)='' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_TAGVAR(link_all_deplibs, $1)=yes _LT_TAGVAR(file_list_spec, $1)='$wl-f,' case $with_aix_soname,$aix_use_runtimelinking in aix,*) ;; # traditional, no import file svr4,* | *,yes) # use import file # The Import File defines what to hardcode. _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=no ;; esac if test yes = "$GCC"; then case $host_os in aix4.[[012]]|aix4.[[012]].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ collect2name=`$CC -print-prog-name=collect2` if test -f "$collect2name" && strings "$collect2name" | $GREP resolve_lib_name >/dev/null then # We have reworked collect2 : else # We have old collect2 _LT_TAGVAR(hardcode_direct, $1)=unsupported # It fails to find uninstalled libraries when the uninstalled # path is not listed in the libpath. Setting hardcode_minus_L # to unsupported forces relinking _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)= fi ;; esac shared_flag='-shared' if test yes = "$aix_use_runtimelinking"; then shared_flag="$shared_flag "'$wl-G' fi # Need to ensure runtime linking is disabled for the traditional # shared library, or the linker may eventually find shared libraries # /with/ Import File - we do not want to mix them. shared_flag_aix='-shared' shared_flag_svr4='-shared $wl-G' else # not using gcc if test ia64 = "$host_cpu"; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else if test yes = "$aix_use_runtimelinking"; then shared_flag='$wl-G' else shared_flag='$wl-bM:SRE' fi shared_flag_aix='$wl-bM:SRE' shared_flag_svr4='$wl-G' fi fi _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall' # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to export. _LT_TAGVAR(always_export_symbols, $1)=yes if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. _LT_TAGVAR(allow_undefined_flag, $1)='-berok' # Determine the default libpath from the value encoded in an # empty executable. _LT_SYS_MODULE_PATH_AIX([$1]) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag else if test ia64 = "$host_cpu"; then _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib' _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an # empty executable. _LT_SYS_MODULE_PATH_AIX([$1]) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok' _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok' if test yes = "$with_gnu_ld"; then # We only use this code for GNU lds that support --whole-archive. _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' else # Exported symbols can be pulled into shared objects from archives _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' fi _LT_TAGVAR(archive_cmds_need_lc, $1)=yes _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' # -brtl affects multiple linker settings, -berok does not and is overridden later compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`' if test svr4 != "$with_aix_soname"; then # This is similar to how AIX traditionally builds its shared libraries. _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' fi if test aix != "$with_aix_soname"; then _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' else # used by -dlpreopen to get the symbols _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir' fi _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d' fi fi ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='' ;; m68k) _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_minus_L, $1)=yes ;; esac ;; bsdi[[45]]*) _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic ;; cygwin* | mingw* | pw32* | cegcc*) # When not using gcc, we currently assume that we are using # Microsoft Visual C++ or Intel C++ Compiler. # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. case $cc_basename in cl* | icl*) # Native MSVC or ICC _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=yes _LT_TAGVAR(file_list_spec, $1)='@' # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then cp "$export_symbols" "$output_objdir/$soname.def"; echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; else $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; fi~ $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ linknames=' # The linker will not automatically build a static lib if we build a DLL. # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1,DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols' # Don't use ranlib _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ lt_tool_outputfile="@TOOL_OUTPUT@"~ case $lt_outputfile in *.exe|*.EXE) ;; *) lt_outputfile=$lt_outputfile.exe lt_tool_outputfile=$lt_tool_outputfile.exe ;; esac~ if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; $RM "$lt_outputfile.manifest"; fi' ;; *) # Assume MSVC and ICC wrapper _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' # The linker will automatically build a .lib file if we build a DLL. _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' # FIXME: Should let the user specify the lib program. _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes ;; esac ;; darwin* | rhapsody*) _LT_DARWIN_LINKER_FEATURES($1) ;; dgux*) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor # support. Future versions do this automatically, but an explicit c++rt0.o # does not break anything, and helps significantly (at the cost of a little # extra space). freebsd2.2*) _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; # Unfortunately, older versions of FreeBSD 2 do not have this feature. freebsd2.*) _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; # FreeBSD 3 and greater uses gcc -shared to do shared libraries. freebsd* | dragonfly* | midnightbsd*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; hpux9*) if test yes = "$GCC"; then _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' else _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' fi _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(hardcode_direct, $1)=yes # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' ;; hpux10*) if test yes,no = "$GCC,$with_gnu_ld"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' else _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' fi if test no = "$with_gnu_ld"; then _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. _LT_TAGVAR(hardcode_minus_L, $1)=yes fi ;; hpux11*) if test yes,no = "$GCC,$with_gnu_ld"; then case $host_cpu in hppa*64*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac else case $host_cpu in hppa*64*) _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) m4_if($1, [], [ # Older versions of the 11.00 compiler do not understand -b yet # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) _LT_LINKER_OPTION([if $CC understands -b], _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b], [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'], [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])], [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags']) ;; esac fi if test no = "$with_gnu_ld"; then _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: case $host_cpu in hppa*64*|ia64*) _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; *) _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. _LT_TAGVAR(hardcode_minus_L, $1)=yes ;; esac fi ;; irix5* | irix6* | nonstopux*) if test yes = "$GCC"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' # Try to use the -exported_symbol ld option, if it does not # work, assume that -exports_file does not work either and # implicitly export all symbols. # This should be the same for all languages, so no per-tag cache variable. AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol], [lt_cv_irix_exported_symbol], [save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null" AC_LINK_IFELSE( [AC_LANG_SOURCE( [AC_LANG_CASE([C], [[int foo (void) { return 0; }]], [C++], [[int foo (void) { return 0; }]], [Fortran 77], [[ subroutine foo end]], [Fortran], [[ subroutine foo end]])])], [lt_cv_irix_exported_symbol=yes], [lt_cv_irix_exported_symbol=no]) LDFLAGS=$save_LDFLAGS]) if test yes = "$lt_cv_irix_exported_symbol"; then _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib' fi _LT_TAGVAR(link_all_deplibs, $1)=no else _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib' fi _LT_TAGVAR(archive_cmds_need_lc, $1)='no' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(inherit_rpath, $1)=yes _LT_TAGVAR(link_all_deplibs, $1)=yes ;; linux*) case $cc_basename in tcc*) # Fabrice Bellard et al's Tiny C Compiler _LT_TAGVAR(ld_shlibs, $1)=yes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' ;; esac ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out else _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF fi _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; newsos6) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; *nto* | *qnx*) ;; openbsd* | bitrig*) if test -f /usr/libexec/ld.so; then _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=yes if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' else _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' fi else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; os2*) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(allow_undefined_flag, $1)=unsupported shrext_cmds=.dll _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ prefix_cmds="$SED"~ if test EXPORTS = "`$SED 1q $export_symbols`"; then prefix_cmds="$prefix_cmds -e 1d"; fi~ prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes _LT_TAGVAR(file_list_spec, $1)='@' ;; osf3*) if test yes = "$GCC"; then _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' else _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' fi _LT_TAGVAR(archive_cmds_need_lc, $1)='no' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: ;; osf4* | osf5*) # as osf3* with the addition of -msym flag if test yes = "$GCC"; then _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' else _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ $CC -shared$allow_undefined_flag $wl-input $wl$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~$RM $lib.exp' # Both c and cxx compiler support -rpath directly _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' fi _LT_TAGVAR(archive_cmds_need_lc, $1)='no' _LT_TAGVAR(hardcode_libdir_separator, $1)=: ;; solaris*) _LT_TAGVAR(no_undefined_flag, $1)=' -z defs' if test yes = "$GCC"; then wlarc='$wl' _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -shared $pic_flag $wl-z ${wl}text $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' else case `$CC -V 2>&1` in *"Compilers 5.0"*) wlarc='' _LT_TAGVAR(archive_cmds, $1)='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' ;; *) wlarc='$wl' _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' ;; esac fi _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no case $host_os in solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; *) # The compiler driver will combine and reorder linker options, # but understands '-z linker_flag'. GCC discards it without '$wl', # but is careful enough not to reorder. # Supported since Solaris 2.6 (maybe 2.5.1?) if test yes = "$GCC"; then _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' else _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' fi ;; esac _LT_TAGVAR(link_all_deplibs, $1)=yes ;; sunos4*) if test sequent = "$host_vendor"; then # Use $CC to link under sequent, because it throws in some extra .o # files that make .init and .fini sections work. _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags' else _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' fi _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; sysv4) case $host_vendor in sni) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true??? ;; siemens) ## LD is ld it makes a PLAMLIB ## CC just makes a GrossModule. _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' _LT_TAGVAR(hardcode_direct, $1)=no ;; motorola) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie ;; esac runpath_var='LD_RUN_PATH' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; sysv4.3*) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' ;; sysv4*MP*) if test -d /usr/nec; then _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no runpath_var=LD_RUN_PATH hardcode_runpath_var=yes _LT_TAGVAR(ld_shlibs, $1)=yes fi ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no runpath_var='LD_RUN_PATH' if test yes = "$GCC"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; sysv5* | sco3.2v5* | sco5v6*) # Note: We CANNOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs' _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_TAGVAR(link_all_deplibs, $1)=yes _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport' runpath_var='LD_RUN_PATH' if test yes = "$GCC"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; uts4*) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; *) _LT_TAGVAR(ld_shlibs, $1)=no ;; esac if test sni = "$host_vendor"; then case $host in sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Blargedynsym' ;; esac fi fi ]) AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no _LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld _LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl _LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl _LT_DECL([], [extract_expsyms_cmds], [2], [The commands to extract the exported symbol list from a shared archive]) # # Do we need to explicitly link libc? # case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in x|xyes) # Assume -lc should be added _LT_TAGVAR(archive_cmds_need_lc, $1)=yes if test yes,yes = "$GCC,$enable_shared"; then case $_LT_TAGVAR(archive_cmds, $1) in *'~'*) # FIXME: we may have to deal with multi-command sequences. ;; '$CC '*) # Test whether the compiler implicitly links with -lc since on some # systems, -lgcc has to come before -lc. If gcc already passes -lc # to ld, don't add -lc before -lgcc. AC_CACHE_CHECK([whether -lc should be explicitly linked in], [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1), [$RM conftest* echo "$lt_simple_compile_test_code" > conftest.$ac_ext if AC_TRY_EVAL(ac_compile) 2>conftest.err; then soname=conftest lib=conftest libobjs=conftest.$ac_objext deplibs= wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1) compiler_flags=-v linker_flags=-v verstring= output_objdir=. libname=conftest lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1) _LT_TAGVAR(allow_undefined_flag, $1)= if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) then lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no else lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes fi _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag else cat conftest.err 1>&5 fi $RM conftest* ]) _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1) ;; esac fi ;; esac _LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0], [Whether or not to add -lc for building shared libraries]) _LT_TAGDECL([allow_libtool_libs_with_static_runtimes], [enable_shared_with_static_runtimes], [0], [Whether or not to disallow shared libs when runtime libs are static]) _LT_TAGDECL([], [export_dynamic_flag_spec], [1], [Compiler flag to allow reflexive dlopens]) _LT_TAGDECL([], [whole_archive_flag_spec], [1], [Compiler flag to generate shared objects directly from archives]) _LT_TAGDECL([], [compiler_needs_object], [1], [Whether the compiler copes with passing no objects directly]) _LT_TAGDECL([], [old_archive_from_new_cmds], [2], [Create an old-style archive from a shared archive]) _LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2], [Create a temporary old-style archive to link instead of a shared archive]) _LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive]) _LT_TAGDECL([], [archive_expsym_cmds], [2]) _LT_TAGDECL([], [module_cmds], [2], [Commands used to build a loadable module if different from building a shared archive.]) _LT_TAGDECL([], [module_expsym_cmds], [2]) _LT_TAGDECL([], [with_gnu_ld], [1], [Whether we are building with GNU ld or not]) _LT_TAGDECL([], [allow_undefined_flag], [1], [Flag that allows shared libraries with undefined symbols to be built]) _LT_TAGDECL([], [no_undefined_flag], [1], [Flag that enforces no undefined symbols]) _LT_TAGDECL([], [hardcode_libdir_flag_spec], [1], [Flag to hardcode $libdir into a binary during linking. This must work even if $libdir does not exist]) _LT_TAGDECL([], [hardcode_libdir_separator], [1], [Whether we need a single "-rpath" flag with a separated argument]) _LT_TAGDECL([], [hardcode_direct], [0], [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes DIR into the resulting binary]) _LT_TAGDECL([], [hardcode_direct_absolute], [0], [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes DIR into the resulting binary and the resulting library dependency is "absolute", i.e impossible to change by setting $shlibpath_var if the library is relocated]) _LT_TAGDECL([], [hardcode_minus_L], [0], [Set to "yes" if using the -LDIR flag during linking hardcodes DIR into the resulting binary]) _LT_TAGDECL([], [hardcode_shlibpath_var], [0], [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into the resulting binary]) _LT_TAGDECL([], [hardcode_automatic], [0], [Set to "yes" if building a shared library automatically hardcodes DIR into the library and all subsequent libraries and executables linked against it]) _LT_TAGDECL([], [inherit_rpath], [0], [Set to yes if linker adds runtime paths of dependent libraries to runtime path list]) _LT_TAGDECL([], [link_all_deplibs], [0], [Whether libtool must link a program against all its dependency libraries]) _LT_TAGDECL([], [always_export_symbols], [0], [Set to "yes" if exported symbols are required]) _LT_TAGDECL([], [export_symbols_cmds], [2], [The commands to list exported symbols]) _LT_TAGDECL([], [exclude_expsyms], [1], [Symbols that should not be listed in the preloaded symbols]) _LT_TAGDECL([], [include_expsyms], [1], [Symbols that must always be exported]) _LT_TAGDECL([], [prelink_cmds], [2], [Commands necessary for linking programs (against libraries) with templates]) _LT_TAGDECL([], [postlink_cmds], [2], [Commands necessary for finishing linking programs]) _LT_TAGDECL([], [file_list_spec], [1], [Specify filename containing input files]) dnl FIXME: Not yet implemented dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1], dnl [Compiler flag to generate thread safe objects]) ])# _LT_LINKER_SHLIBS # _LT_LANG_C_CONFIG([TAG]) # ------------------------ # Ensure that the configuration variables for a C compiler are suitably # defined. These variables are subsequently used by _LT_CONFIG to write # the compiler configuration to 'libtool'. m4_defun([_LT_LANG_C_CONFIG], [m4_require([_LT_DECL_EGREP])dnl lt_save_CC=$CC AC_LANG_PUSH(C) # Source file extension for C test sources. ac_ext=c # Object file extension for compiled C test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="int some_variable = 0;" # Code to be used in simple link tests lt_simple_link_test_code='int main(){return(0);}' _LT_TAG_COMPILER # Save the default compiler, since it gets overwritten when the other # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. compiler_DEFAULT=$CC # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change ## the running order or otherwise move them around unless you know exactly ## what you are doing... if test -n "$compiler"; then _LT_COMPILER_NO_RTTI($1) _LT_COMPILER_PIC($1) _LT_COMPILER_C_O($1) _LT_COMPILER_FILE_LOCKS($1) _LT_LINKER_SHLIBS($1) _LT_SYS_DYNAMIC_LINKER($1) _LT_LINKER_HARDCODE_LIBPATH($1) LT_SYS_DLOPEN_SELF _LT_CMD_STRIPLIB # Report what library types will actually be built AC_MSG_CHECKING([if libtool supports shared libraries]) AC_MSG_RESULT([$can_build_shared]) AC_MSG_CHECKING([whether to build shared libraries]) test no = "$can_build_shared" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) test yes = "$enable_shared" && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[[4-9]]*) if test ia64 != "$host_cpu"; then case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in yes,aix,yes) ;; # shared object as lib.so file only yes,svr4,*) ;; # shared object as lib.so archive member only yes,*) enable_static=no ;; # shared object in lib.a archive as well esac fi ;; esac AC_MSG_RESULT([$enable_shared]) AC_MSG_CHECKING([whether to build static libraries]) # Make sure either enable_shared or enable_static is yes. test yes = "$enable_shared" || enable_static=yes AC_MSG_RESULT([$enable_static]) _LT_CONFIG($1) fi AC_LANG_POP CC=$lt_save_CC ])# _LT_LANG_C_CONFIG # _LT_LANG_CXX_CONFIG([TAG]) # -------------------------- # Ensure that the configuration variables for a C++ compiler are suitably # defined. These variables are subsequently used by _LT_CONFIG to write # the compiler configuration to 'libtool'. m4_defun([_LT_LANG_CXX_CONFIG], [m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_EGREP])dnl m4_require([_LT_PATH_MANIFEST_TOOL])dnl if test -n "$CXX" && ( test no != "$CXX" && ( (test g++ = "$CXX" && `g++ -v >/dev/null 2>&1` ) || (test g++ != "$CXX"))); then AC_PROG_CXXCPP else _lt_caught_CXX_error=yes fi AC_LANG_PUSH(C++) _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(allow_undefined_flag, $1)= _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(archive_expsym_cmds, $1)= _LT_TAGVAR(compiler_needs_object, $1)=no _LT_TAGVAR(export_dynamic_flag_spec, $1)= _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_TAGVAR(hardcode_libdir_separator, $1)= _LT_TAGVAR(hardcode_minus_L, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported _LT_TAGVAR(hardcode_automatic, $1)=no _LT_TAGVAR(inherit_rpath, $1)=no _LT_TAGVAR(module_cmds, $1)= _LT_TAGVAR(module_expsym_cmds, $1)= _LT_TAGVAR(link_all_deplibs, $1)=unknown _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds _LT_TAGVAR(reload_flag, $1)=$reload_flag _LT_TAGVAR(reload_cmds, $1)=$reload_cmds _LT_TAGVAR(no_undefined_flag, $1)= _LT_TAGVAR(whole_archive_flag_spec, $1)= _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no # Source file extension for C++ test sources. ac_ext=cpp # Object file extension for compiled C++ test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # No sense in running all these tests if we already determined that # the CXX compiler isn't working. Some variables (like enable_shared) # are currently assumed to apply to all compilers on this platform, # and will be corrupted by setting them based on a non-working compiler. if test yes != "$_lt_caught_CXX_error"; then # Code to be used in simple compile tests lt_simple_compile_test_code="int some_variable = 0;" # Code to be used in simple link tests lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }' # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_CFLAGS=$CFLAGS lt_save_LD=$LD lt_save_GCC=$GCC GCC=$GXX lt_save_with_gnu_ld=$with_gnu_ld lt_save_path_LD=$lt_cv_path_LD if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx else $as_unset lt_cv_prog_gnu_ld fi if test -n "${lt_cv_path_LDCXX+set}"; then lt_cv_path_LD=$lt_cv_path_LDCXX else $as_unset lt_cv_path_LD fi test -z "${LDCXX+set}" || LD=$LDCXX CC=${CXX-"c++"} CFLAGS=$CXXFLAGS compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) if test -n "$compiler"; then # We don't want -fno-exception when compiling C++ code, so set the # no_builtin_flag separately if test yes = "$GXX"; then _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' else _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= fi if test yes = "$GXX"; then # Set up default GNU C++ configuration LT_PATH_LD # Check if GNU C++ uses GNU ld as the underlying linker, since the # archiving commands below assume that GNU ld is being used. if test yes = "$with_gnu_ld"; then _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' # If archive_cmds runs LD, not CC, wlarc should be empty # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to # investigate it a little bit more. (MM) wlarc='$wl' # ancient GNU ld didn't support --whole-archive et. al. if eval "`$CC -print-prog-name=ld` --help 2>&1" | $GREP 'no-whole-archive' > /dev/null; then _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' else _LT_TAGVAR(whole_archive_flag_spec, $1)= fi else with_gnu_ld=no wlarc= # A generic and very simple default shared library creation # command for GNU C++ for the case where it uses the native # linker, instead of GNU ld. If possible, this setting should # overridden to take advantage of the native linker features on # the platform it is being used on. _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' fi # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"' else GXX=no with_gnu_ld=no wlarc= fi # PORTME: fill in a description of your system's C++ link characteristics AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) _LT_TAGVAR(ld_shlibs, $1)=yes case $host_os in aix3*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; aix[[4-9]]*) if test ia64 = "$host_cpu"; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' no_entry_flag= else aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we # have runtime linking enabled, and use it for executables. # For shared libraries, we enable/disable runtime linking # depending on the kind of the shared library created - # when "with_aix_soname,aix_use_runtimelinking" is: # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables # "aix,yes" lib.so shared, rtl:yes, for executables # lib.a static archive # "both,no" lib.so.V(shr.o) shared, rtl:yes # lib.a(lib.so.V) shared, rtl:no, for executables # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a(lib.so.V) shared, rtl:no # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a static archive case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) for ld_flag in $LDFLAGS; do case $ld_flag in *-brtl*) aix_use_runtimelinking=yes break ;; esac done if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then # With aix-soname=svr4, we create the lib.so.V shared archives only, # so we don't have lib.a shared libs to link our executables. # We have to force runtime linking in this case. aix_use_runtimelinking=yes LDFLAGS="$LDFLAGS -Wl,-brtl" fi ;; esac exp_sym_flag='-bexport' no_entry_flag='-bnoentry' fi # When large executables or shared objects are built, AIX ld can # have problems creating the table of contents. If linking a library # or program results in "error TOC overflow" add -mminimal-toc to # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. _LT_TAGVAR(archive_cmds, $1)='' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_TAGVAR(link_all_deplibs, $1)=yes _LT_TAGVAR(file_list_spec, $1)='$wl-f,' case $with_aix_soname,$aix_use_runtimelinking in aix,*) ;; # no import file svr4,* | *,yes) # use import file # The Import File defines what to hardcode. _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=no ;; esac if test yes = "$GXX"; then case $host_os in aix4.[[012]]|aix4.[[012]].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ collect2name=`$CC -print-prog-name=collect2` if test -f "$collect2name" && strings "$collect2name" | $GREP resolve_lib_name >/dev/null then # We have reworked collect2 : else # We have old collect2 _LT_TAGVAR(hardcode_direct, $1)=unsupported # It fails to find uninstalled libraries when the uninstalled # path is not listed in the libpath. Setting hardcode_minus_L # to unsupported forces relinking _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)= fi esac shared_flag='-shared' if test yes = "$aix_use_runtimelinking"; then shared_flag=$shared_flag' $wl-G' fi # Need to ensure runtime linking is disabled for the traditional # shared library, or the linker may eventually find shared libraries # /with/ Import File - we do not want to mix them. shared_flag_aix='-shared' shared_flag_svr4='-shared $wl-G' else # not using gcc if test ia64 = "$host_cpu"; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else if test yes = "$aix_use_runtimelinking"; then shared_flag='$wl-G' else shared_flag='$wl-bM:SRE' fi shared_flag_aix='$wl-bM:SRE' shared_flag_svr4='$wl-G' fi fi _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall' # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to # export. _LT_TAGVAR(always_export_symbols, $1)=yes if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. # The "-G" linker flag allows undefined symbols. _LT_TAGVAR(no_undefined_flag, $1)='-bernotok' # Determine the default libpath from the value encoded in an empty # executable. _LT_SYS_MODULE_PATH_AIX([$1]) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag else if test ia64 = "$host_cpu"; then _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib' _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an # empty executable. _LT_SYS_MODULE_PATH_AIX([$1]) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok' _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok' if test yes = "$with_gnu_ld"; then # We only use this code for GNU lds that support --whole-archive. _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' else # Exported symbols can be pulled into shared objects from archives _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' fi _LT_TAGVAR(archive_cmds_need_lc, $1)=yes _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' # -brtl affects multiple linker settings, -berok does not and is overridden later compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`' if test svr4 != "$with_aix_soname"; then # This is similar to how AIX traditionally builds its shared # libraries. Need -bnortl late, we may have -brtl in LDFLAGS. _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' fi if test aix != "$with_aix_soname"; then _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' else # used by -dlpreopen to get the symbols _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir' fi _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d' fi fi ;; beos*) if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then _LT_TAGVAR(allow_undefined_flag, $1)=unsupported # Joseph Beckenbach says some releases of gcc # support --undefined. This deserves some investigation. FIXME _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; chorus*) case $cc_basename in *) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; esac ;; cygwin* | mingw* | pw32* | cegcc*) case $GXX,$cc_basename in ,cl* | no,cl* | ,icl* | no,icl*) # Native MSVC or ICC # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=yes _LT_TAGVAR(file_list_spec, $1)='@' # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then cp "$export_symbols" "$output_objdir/$soname.def"; echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; else $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; fi~ $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ linknames=' # The linker will not automatically build a static lib if we build a DLL. # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes # Don't use ranlib _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ lt_tool_outputfile="@TOOL_OUTPUT@"~ case $lt_outputfile in *.exe|*.EXE) ;; *) lt_outputfile=$lt_outputfile.exe lt_tool_outputfile=$lt_tool_outputfile.exe ;; esac~ func_to_tool_file "$lt_outputfile"~ if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; $RM "$lt_outputfile.manifest"; fi' ;; *) # g++ # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, # as there is no search path for DLLs. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' # If the export-symbols file already is a .def file, use it as # is; otherwise, prepend EXPORTS... _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then cp $export_symbols $output_objdir/$soname.def; else echo EXPORTS > $output_objdir/$soname.def; cat $export_symbols >> $output_objdir/$soname.def; fi~ $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; darwin* | rhapsody*) _LT_DARWIN_LINKER_FEATURES($1) ;; os2*) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(allow_undefined_flag, $1)=unsupported shrext_cmds=.dll _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ prefix_cmds="$SED"~ if test EXPORTS = "`$SED 1q $export_symbols`"; then prefix_cmds="$prefix_cmds -e 1d"; fi~ prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes _LT_TAGVAR(file_list_spec, $1)='@' ;; dgux*) case $cc_basename in ec++*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; ghcx*) # Green Hills C++ Compiler # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; *) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; esac ;; freebsd2.*) # C++ shared libraries reported to be fairly broken before # switch to ELF _LT_TAGVAR(ld_shlibs, $1)=no ;; freebsd-elf*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; freebsd* | dragonfly* | midnightbsd*) # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF # conventions _LT_TAGVAR(ld_shlibs, $1)=yes ;; haiku*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(link_all_deplibs, $1)=yes ;; hpux9*) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, # but as the default # location of the library. case $cc_basename in CC*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; aCC*) _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP " \-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) if test yes = "$GXX"; then _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' else # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; hpux10*|hpux11*) if test no = "$with_gnu_ld"; then _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: case $host_cpu in hppa*64*|ia64*) ;; *) _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' ;; esac fi case $host_cpu in hppa*64*|ia64*) _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; *) _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, # but as the default # location of the library. ;; esac case $cc_basename in CC*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; aCC*) case $host_cpu in hppa*64*) _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; ia64*) _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; *) _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; esac # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP " \-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) if test yes = "$GXX"; then if test no = "$with_gnu_ld"; then case $host_cpu in hppa*64*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; ia64*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; *) _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; esac fi else # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; interix[[3-9]]*) _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; irix5* | irix6*) case $cc_basename in CC*) # SGI C++ _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' # Archives containing C++ object files must be created using # "CC -ar", where "CC" is the IRIX C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' ;; *) if test yes = "$GXX"; then if test no = "$with_gnu_ld"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' else _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` -o $lib' fi fi _LT_TAGVAR(link_all_deplibs, $1)=yes ;; esac _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(inherit_rpath, $1)=yes ;; linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in KCC*) # Kuck and Associates, Inc. (KAI) C++ Compiler # KCC will only create a shared library if the output file # ends with ".so" (or ".sl" for HP-UX), so rename the library # to its proper name (with version) after linking. _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib $wl-retain-symbols-file,$export_symbols; mv \$templib $lib' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' # Archives containing C++ object files must be created using # "CC -Bstatic", where "CC" is the KAI C++ compiler. _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; icpc* | ecpc* ) # Intel C++ with_gnu_ld=yes # version 8.0 and above of icpc choke on multiply defined symbols # if we add $predep_objects and $postdep_objects, however 7.1 and # earlier do not add the objects themselves. case `$CC -V 2>&1` in *"Version 7."*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; *) # Version 8.0 or newer tmp_idyn= case $host_cpu in ia64*) tmp_idyn=' -i_dynamic';; esac _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; esac _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' ;; pgCC* | pgcpp*) # Portland Group C++ compiler case `$CC -V` in *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*) _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~ rm -rf $tpldir~ $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~ rm -rf $tpldir~ $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ $RANLIB $oldlib' _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~ rm -rf $tpldir~ $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~ rm -rf $tpldir~ $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; *) # Version 6 and above use weak symbols _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; esac _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl--rpath $wl$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' ;; cxx*) # Compaq C++ _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib $wl-retain-symbols-file $wl$export_symbols' runpath_var=LD_RUN_PATH _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed' ;; xl* | mpixl* | bgxl*) # IBM XL 8.0 on PPC, with GNU ld _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' if test yes = "$supports_anon_versioning"; then _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' fi ;; *) case `$CC -V 2>&1 | $SED 5q` in *Sun\ C*) # Sun C++ 5.9 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file $wl$export_symbols' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' _LT_TAGVAR(compiler_needs_object, $1)=yes # Not sure whether something based on # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 # would be better. output_verbose_link_cmd='func_echo_all' # Archives containing C++ object files must be created using # "CC -xar", where "CC" is the Sun C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' ;; esac ;; esac ;; lynxos*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; m88k*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; mvs*) case $cc_basename in cxx*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; *) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; esac ;; netbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' wlarc= _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no fi # Workaround some broken pre-1.5 toolchains output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' ;; *nto* | *qnx*) _LT_TAGVAR(ld_shlibs, $1)=yes ;; openbsd* | bitrig*) if test -f /usr/libexec/ld.so; then _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`"; then _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file,$export_symbols -o $lib' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' fi output_verbose_link_cmd=func_echo_all else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; osf3* | osf4* | osf5*) case $cc_basename in KCC*) # Kuck and Associates, Inc. (KAI) C++ Compiler # KCC will only create a shared library if the output file # ends with ".so" (or ".sl" for HP-UX), so rename the library # to its proper name (with version) after linking. _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: # Archives containing C++ object files must be created using # the KAI C++ compiler. case $host in osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;; esac ;; RCC*) # Rational C++ 2.4.1 # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; cxx*) case $host in osf3*) _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $soname `test -n "$verstring" && func_echo_all "$wl-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' ;; *) _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ echo "-hidden">> $lib.exp~ $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname $wl-input $wl$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~ $RM $lib.exp' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' ;; esac _LT_TAGVAR(hardcode_libdir_separator, $1)=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) if test yes,no = "$GXX,$with_gnu_ld"; then _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' case $host in osf3*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' ;; *) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' ;; esac _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"' else # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; psos*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; sunos4*) case $cc_basename in CC*) # Sun C++ 4.x # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; lcc*) # Lucid # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; *) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; esac ;; solaris*) case $cc_basename in CC* | sunCC*) # Sun C++ 4.2, 5.x and Centerline C++ _LT_TAGVAR(archive_cmds_need_lc,$1)=yes _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -G$allow_undefined_flag $wl-M $wl$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no case $host_os in solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; *) # The compiler driver will combine and reorder linker options, # but understands '-z linker_flag'. # Supported since Solaris 2.6 (maybe 2.5.1?) _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' ;; esac _LT_TAGVAR(link_all_deplibs, $1)=yes output_verbose_link_cmd='func_echo_all' # Archives containing C++ object files must be created using # "CC -xar", where "CC" is the Sun C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' ;; gcx*) # Green Hills C++ Compiler _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' # The C++ compiler must be used to create the archive. _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' ;; *) # GNU C++ compiler with Solaris linker if test yes,no = "$GXX,$with_gnu_ld"; then _LT_TAGVAR(no_undefined_flag, $1)=' $wl-z ${wl}defs' if $CC --version | $GREP -v '^2\.7' > /dev/null; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -shared $pic_flag -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"' else # g++ 2.7 appears to require '-G' NOT '-shared' on this # platform. _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -G -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"' fi _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $wl$libdir' case $host_os in solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; *) _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' ;; esac fi ;; esac ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no runpath_var='LD_RUN_PATH' case $cc_basename in CC*) _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; *) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; sysv5* | sco3.2v5* | sco5v6*) # Note: We CANNOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs' _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_TAGVAR(link_all_deplibs, $1)=yes _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport' runpath_var='LD_RUN_PATH' case $cc_basename in CC*) _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~ '"$_LT_TAGVAR(old_archive_cmds, $1)" _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~ '"$_LT_TAGVAR(reload_cmds, $1)" ;; *) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; tandem*) case $cc_basename in NCC*) # NonStop-UX NCC 3.20 # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; *) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; esac ;; vxworks*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; *) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; esac AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no _LT_TAGVAR(GCC, $1)=$GXX _LT_TAGVAR(LD, $1)=$LD ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change ## the running order or otherwise move them around unless you know exactly ## what you are doing... _LT_SYS_HIDDEN_LIBDEPS($1) _LT_COMPILER_PIC($1) _LT_COMPILER_C_O($1) _LT_COMPILER_FILE_LOCKS($1) _LT_LINKER_SHLIBS($1) _LT_SYS_DYNAMIC_LINKER($1) _LT_LINKER_HARDCODE_LIBPATH($1) _LT_CONFIG($1) fi # test -n "$compiler" CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS LDCXX=$LD LD=$lt_save_LD GCC=$lt_save_GCC with_gnu_ld=$lt_save_with_gnu_ld lt_cv_path_LDCXX=$lt_cv_path_LD lt_cv_path_LD=$lt_save_path_LD lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld fi # test yes != "$_lt_caught_CXX_error" AC_LANG_POP ])# _LT_LANG_CXX_CONFIG # _LT_FUNC_STRIPNAME_CNF # ---------------------- # func_stripname_cnf prefix suffix name # strip PREFIX and SUFFIX off of NAME. # PREFIX and SUFFIX must not contain globbing or regex special # characters, hashes, percent signs, but SUFFIX may contain a leading # dot (in which case that matches only a dot). # # This function is identical to the (non-XSI) version of func_stripname, # except this one can be used by m4 code that may be executed by configure, # rather than the libtool script. m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl AC_REQUIRE([_LT_DECL_SED]) AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH]) func_stripname_cnf () { case @S|@2 in .*) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%\\\\@S|@2\$%%"`;; *) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%@S|@2\$%%"`;; esac } # func_stripname_cnf ])# _LT_FUNC_STRIPNAME_CNF # _LT_SYS_HIDDEN_LIBDEPS([TAGNAME]) # --------------------------------- # Figure out "hidden" library dependencies from verbose # compiler output when linking a shared library. # Parse the compiler output and extract the necessary # objects, libraries and library flags. m4_defun([_LT_SYS_HIDDEN_LIBDEPS], [m4_require([_LT_FILEUTILS_DEFAULTS])dnl AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl # Dependencies to place before and after the object being linked: _LT_TAGVAR(predep_objects, $1)= _LT_TAGVAR(postdep_objects, $1)= _LT_TAGVAR(predeps, $1)= _LT_TAGVAR(postdeps, $1)= _LT_TAGVAR(compiler_lib_search_path, $1)= dnl we can't use the lt_simple_compile_test_code here, dnl because it contains code intended for an executable, dnl not a library. It's possible we should let each dnl tag define a new lt_????_link_test_code variable, dnl but it's only used here... m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF int a; void foo (void) { a = 0; } _LT_EOF ], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF class Foo { public: Foo (void) { a = 0; } private: int a; }; _LT_EOF ], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF subroutine foo implicit none integer*4 a a=0 return end _LT_EOF ], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF subroutine foo implicit none integer a a=0 return end _LT_EOF ], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF public class foo { private int a; public void bar (void) { a = 0; } }; _LT_EOF ], [$1], [GO], [cat > conftest.$ac_ext <<_LT_EOF package foo func foo() { } _LT_EOF ]) _lt_libdeps_save_CFLAGS=$CFLAGS case "$CC $CFLAGS " in #( *\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; *\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; *\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;; esac dnl Parse the compiler output and extract the necessary dnl objects, libraries and library flags. if AC_TRY_EVAL(ac_compile); then # Parse the compiler output and extract the necessary # objects, libraries and library flags. # Sentinel used to keep track of whether or not we are before # the conftest object file. pre_test_object_deps_done=no for p in `eval "$output_verbose_link_cmd"`; do case $prev$p in -L* | -R* | -l*) # Some compilers place space between "-{L,R}" and the path. # Remove the space. if test x-L = "$p" || test x-R = "$p"; then prev=$p continue fi # Expand the sysroot to ease extracting the directories later. if test -z "$prev"; then case $p in -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; esac fi case $p in =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; esac if test no = "$pre_test_object_deps_done"; then case $prev in -L | -R) # Internal compiler library paths should come after those # provided the user. The postdeps already come after the # user supplied libs so there is no need to process them. if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then _LT_TAGVAR(compiler_lib_search_path, $1)=$prev$p else _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} $prev$p" fi ;; # The "-l" case would never come before the object being # linked, so don't bother handling this case. esac else if test -z "$_LT_TAGVAR(postdeps, $1)"; then _LT_TAGVAR(postdeps, $1)=$prev$p else _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} $prev$p" fi fi prev= ;; *.lto.$objext) ;; # Ignore GCC LTO objects *.$objext) # This assumes that the test object file only shows up # once in the compiler output. if test "$p" = "conftest.$objext"; then pre_test_object_deps_done=yes continue fi if test no = "$pre_test_object_deps_done"; then if test -z "$_LT_TAGVAR(predep_objects, $1)"; then _LT_TAGVAR(predep_objects, $1)=$p else _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p" fi else if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then _LT_TAGVAR(postdep_objects, $1)=$p else _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p" fi fi ;; *) ;; # Ignore the rest. esac done # Clean up. rm -f a.out a.exe else echo "libtool.m4: error: problem compiling $1 test program" fi $RM -f confest.$objext CFLAGS=$_lt_libdeps_save_CFLAGS # PORTME: override above test on systems where it is broken m4_if([$1], [CXX], [case $host_os in interix[[3-9]]*) # Interix 3.5 installs completely hosed .la files for C++, so rather than # hack all around it, let's just trust "g++" to DTRT. _LT_TAGVAR(predep_objects,$1)= _LT_TAGVAR(postdep_objects,$1)= _LT_TAGVAR(postdeps,$1)= ;; esac ]) case " $_LT_TAGVAR(postdeps, $1) " in *" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; esac _LT_TAGVAR(compiler_lib_search_dirs, $1)= if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | $SED -e 's! -L! !g' -e 's!^ !!'` fi _LT_TAGDECL([], [compiler_lib_search_dirs], [1], [The directories searched by this compiler when creating a shared library]) _LT_TAGDECL([], [predep_objects], [1], [Dependencies to place before and after the objects being linked to create a shared library]) _LT_TAGDECL([], [postdep_objects], [1]) _LT_TAGDECL([], [predeps], [1]) _LT_TAGDECL([], [postdeps], [1]) _LT_TAGDECL([], [compiler_lib_search_path], [1], [The library search path used internally by the compiler when linking a shared library]) ])# _LT_SYS_HIDDEN_LIBDEPS # _LT_LANG_F77_CONFIG([TAG]) # -------------------------- # Ensure that the configuration variables for a Fortran 77 compiler are # suitably defined. These variables are subsequently used by _LT_CONFIG # to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_F77_CONFIG], [AC_LANG_PUSH(Fortran 77) if test -z "$F77" || test no = "$F77"; then _lt_disable_F77=yes fi _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(allow_undefined_flag, $1)= _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(archive_expsym_cmds, $1)= _LT_TAGVAR(export_dynamic_flag_spec, $1)= _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_TAGVAR(hardcode_libdir_separator, $1)= _LT_TAGVAR(hardcode_minus_L, $1)=no _LT_TAGVAR(hardcode_automatic, $1)=no _LT_TAGVAR(inherit_rpath, $1)=no _LT_TAGVAR(module_cmds, $1)= _LT_TAGVAR(module_expsym_cmds, $1)= _LT_TAGVAR(link_all_deplibs, $1)=unknown _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds _LT_TAGVAR(reload_flag, $1)=$reload_flag _LT_TAGVAR(reload_cmds, $1)=$reload_cmds _LT_TAGVAR(no_undefined_flag, $1)= _LT_TAGVAR(whole_archive_flag_spec, $1)= _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no # Source file extension for f77 test sources. ac_ext=f # Object file extension for compiled f77 test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # No sense in running all these tests if we already determined that # the F77 compiler isn't working. Some variables (like enable_shared) # are currently assumed to apply to all compilers on this platform, # and will be corrupted by setting them based on a non-working compiler. if test yes != "$_lt_disable_F77"; then # Code to be used in simple compile tests lt_simple_compile_test_code="\ subroutine t return end " # Code to be used in simple link tests lt_simple_link_test_code="\ program t end " # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_GCC=$GCC lt_save_CFLAGS=$CFLAGS CC=${F77-"f77"} CFLAGS=$FFLAGS compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) GCC=$G77 if test -n "$compiler"; then AC_MSG_CHECKING([if libtool supports shared libraries]) AC_MSG_RESULT([$can_build_shared]) AC_MSG_CHECKING([whether to build shared libraries]) test no = "$can_build_shared" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) test yes = "$enable_shared" && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[[4-9]]*) if test ia64 != "$host_cpu"; then case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in yes,aix,yes) ;; # shared object as lib.so file only yes,svr4,*) ;; # shared object as lib.so archive member only yes,*) enable_static=no ;; # shared object in lib.a archive as well esac fi ;; esac AC_MSG_RESULT([$enable_shared]) AC_MSG_CHECKING([whether to build static libraries]) # Make sure either enable_shared or enable_static is yes. test yes = "$enable_shared" || enable_static=yes AC_MSG_RESULT([$enable_static]) _LT_TAGVAR(GCC, $1)=$G77 _LT_TAGVAR(LD, $1)=$LD ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change ## the running order or otherwise move them around unless you know exactly ## what you are doing... _LT_COMPILER_PIC($1) _LT_COMPILER_C_O($1) _LT_COMPILER_FILE_LOCKS($1) _LT_LINKER_SHLIBS($1) _LT_SYS_DYNAMIC_LINKER($1) _LT_LINKER_HARDCODE_LIBPATH($1) _LT_CONFIG($1) fi # test -n "$compiler" GCC=$lt_save_GCC CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS fi # test yes != "$_lt_disable_F77" AC_LANG_POP ])# _LT_LANG_F77_CONFIG # _LT_LANG_FC_CONFIG([TAG]) # ------------------------- # Ensure that the configuration variables for a Fortran compiler are # suitably defined. These variables are subsequently used by _LT_CONFIG # to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_FC_CONFIG], [AC_LANG_PUSH(Fortran) if test -z "$FC" || test no = "$FC"; then _lt_disable_FC=yes fi _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(allow_undefined_flag, $1)= _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(archive_expsym_cmds, $1)= _LT_TAGVAR(export_dynamic_flag_spec, $1)= _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_TAGVAR(hardcode_libdir_separator, $1)= _LT_TAGVAR(hardcode_minus_L, $1)=no _LT_TAGVAR(hardcode_automatic, $1)=no _LT_TAGVAR(inherit_rpath, $1)=no _LT_TAGVAR(module_cmds, $1)= _LT_TAGVAR(module_expsym_cmds, $1)= _LT_TAGVAR(link_all_deplibs, $1)=unknown _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds _LT_TAGVAR(reload_flag, $1)=$reload_flag _LT_TAGVAR(reload_cmds, $1)=$reload_cmds _LT_TAGVAR(no_undefined_flag, $1)= _LT_TAGVAR(whole_archive_flag_spec, $1)= _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no # Source file extension for fc test sources. ac_ext=${ac_fc_srcext-f} # Object file extension for compiled fc test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # No sense in running all these tests if we already determined that # the FC compiler isn't working. Some variables (like enable_shared) # are currently assumed to apply to all compilers on this platform, # and will be corrupted by setting them based on a non-working compiler. if test yes != "$_lt_disable_FC"; then # Code to be used in simple compile tests lt_simple_compile_test_code="\ subroutine t return end " # Code to be used in simple link tests lt_simple_link_test_code="\ program t end " # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_GCC=$GCC lt_save_CFLAGS=$CFLAGS CC=${FC-"f95"} CFLAGS=$FCFLAGS compiler=$CC GCC=$ac_cv_fc_compiler_gnu _LT_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) if test -n "$compiler"; then AC_MSG_CHECKING([if libtool supports shared libraries]) AC_MSG_RESULT([$can_build_shared]) AC_MSG_CHECKING([whether to build shared libraries]) test no = "$can_build_shared" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) test yes = "$enable_shared" && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[[4-9]]*) if test ia64 != "$host_cpu"; then case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in yes,aix,yes) ;; # shared object as lib.so file only yes,svr4,*) ;; # shared object as lib.so archive member only yes,*) enable_static=no ;; # shared object in lib.a archive as well esac fi ;; esac AC_MSG_RESULT([$enable_shared]) AC_MSG_CHECKING([whether to build static libraries]) # Make sure either enable_shared or enable_static is yes. test yes = "$enable_shared" || enable_static=yes AC_MSG_RESULT([$enable_static]) _LT_TAGVAR(GCC, $1)=$ac_cv_fc_compiler_gnu _LT_TAGVAR(LD, $1)=$LD ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change ## the running order or otherwise move them around unless you know exactly ## what you are doing... _LT_SYS_HIDDEN_LIBDEPS($1) _LT_COMPILER_PIC($1) _LT_COMPILER_C_O($1) _LT_COMPILER_FILE_LOCKS($1) _LT_LINKER_SHLIBS($1) _LT_SYS_DYNAMIC_LINKER($1) _LT_LINKER_HARDCODE_LIBPATH($1) _LT_CONFIG($1) fi # test -n "$compiler" GCC=$lt_save_GCC CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS fi # test yes != "$_lt_disable_FC" AC_LANG_POP ])# _LT_LANG_FC_CONFIG # _LT_LANG_GCJ_CONFIG([TAG]) # -------------------------- # Ensure that the configuration variables for the GNU Java Compiler compiler # are suitably defined. These variables are subsequently used by _LT_CONFIG # to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_GCJ_CONFIG], [AC_REQUIRE([LT_PROG_GCJ])dnl AC_LANG_SAVE # Source file extension for Java test sources. ac_ext=java # Object file extension for compiled Java test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="class foo {}" # Code to be used in simple link tests lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }' # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_CFLAGS=$CFLAGS lt_save_GCC=$GCC GCC=yes CC=${GCJ-"gcj"} CFLAGS=$GCJFLAGS compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_TAGVAR(LD, $1)=$LD _LT_CC_BASENAME([$compiler]) # GCJ did not exist at the time GCC didn't implicitly link libc in. _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds _LT_TAGVAR(reload_flag, $1)=$reload_flag _LT_TAGVAR(reload_cmds, $1)=$reload_cmds ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change ## the running order or otherwise move them around unless you know exactly ## what you are doing... if test -n "$compiler"; then _LT_COMPILER_NO_RTTI($1) _LT_COMPILER_PIC($1) _LT_COMPILER_C_O($1) _LT_COMPILER_FILE_LOCKS($1) _LT_LINKER_SHLIBS($1) _LT_LINKER_HARDCODE_LIBPATH($1) _LT_CONFIG($1) fi AC_LANG_RESTORE GCC=$lt_save_GCC CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS ])# _LT_LANG_GCJ_CONFIG # _LT_LANG_GO_CONFIG([TAG]) # -------------------------- # Ensure that the configuration variables for the GNU Go compiler # are suitably defined. These variables are subsequently used by _LT_CONFIG # to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_GO_CONFIG], [AC_REQUIRE([LT_PROG_GO])dnl AC_LANG_SAVE # Source file extension for Go test sources. ac_ext=go # Object file extension for compiled Go test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="package main; func main() { }" # Code to be used in simple link tests lt_simple_link_test_code='package main; func main() { }' # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_CFLAGS=$CFLAGS lt_save_GCC=$GCC GCC=yes CC=${GOC-"gccgo"} CFLAGS=$GOFLAGS compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_TAGVAR(LD, $1)=$LD _LT_CC_BASENAME([$compiler]) # Go did not exist at the time GCC didn't implicitly link libc in. _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds _LT_TAGVAR(reload_flag, $1)=$reload_flag _LT_TAGVAR(reload_cmds, $1)=$reload_cmds ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change ## the running order or otherwise move them around unless you know exactly ## what you are doing... if test -n "$compiler"; then _LT_COMPILER_NO_RTTI($1) _LT_COMPILER_PIC($1) _LT_COMPILER_C_O($1) _LT_COMPILER_FILE_LOCKS($1) _LT_LINKER_SHLIBS($1) _LT_LINKER_HARDCODE_LIBPATH($1) _LT_CONFIG($1) fi AC_LANG_RESTORE GCC=$lt_save_GCC CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS ])# _LT_LANG_GO_CONFIG # _LT_LANG_RC_CONFIG([TAG]) # ------------------------- # Ensure that the configuration variables for the Windows resource compiler # are suitably defined. These variables are subsequently used by _LT_CONFIG # to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_RC_CONFIG], [AC_REQUIRE([LT_PROG_RC])dnl AC_LANG_SAVE # Source file extension for RC test sources. ac_ext=rc # Object file extension for compiled RC test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # Code to be used in simple compile tests lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' # Code to be used in simple link tests lt_simple_link_test_code=$lt_simple_compile_test_code # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_CFLAGS=$CFLAGS lt_save_GCC=$GCC GCC= CC=${RC-"windres"} CFLAGS= compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes if test -n "$compiler"; then : _LT_CONFIG($1) fi GCC=$lt_save_GCC AC_LANG_RESTORE CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS ])# _LT_LANG_RC_CONFIG # LT_PROG_GCJ # ----------- AC_DEFUN([LT_PROG_GCJ], [m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ], [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ], [AC_CHECK_TOOL(GCJ, gcj,) test set = "${GCJFLAGS+set}" || GCJFLAGS="-g -O2" AC_SUBST(GCJFLAGS)])])[]dnl ]) # Old name: AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([LT_AC_PROG_GCJ], []) # LT_PROG_GO # ---------- AC_DEFUN([LT_PROG_GO], [AC_CHECK_TOOL(GOC, gccgo,) ]) # LT_PROG_RC # ---------- AC_DEFUN([LT_PROG_RC], [AC_CHECK_TOOL(RC, windres,) ]) # Old name: AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([LT_AC_PROG_RC], []) # _LT_DECL_EGREP # -------------- # If we don't have a new enough Autoconf to choose the best grep # available, choose the one first in the user's PATH. m4_defun([_LT_DECL_EGREP], [AC_REQUIRE([AC_PROG_EGREP])dnl AC_REQUIRE([AC_PROG_FGREP])dnl test -z "$GREP" && GREP=grep _LT_DECL([], [GREP], [1], [A grep program that handles long lines]) _LT_DECL([], [EGREP], [1], [An ERE matcher]) _LT_DECL([], [FGREP], [1], [A literal string matcher]) dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too AC_SUBST([GREP]) ]) # _LT_DECL_OBJDUMP # -------------- # If we don't have a new enough Autoconf to choose the best objdump # available, choose the one first in the user's PATH. m4_defun([_LT_DECL_OBJDUMP], [AC_CHECK_TOOL(OBJDUMP, objdump, false) test -z "$OBJDUMP" && OBJDUMP=objdump _LT_DECL([], [OBJDUMP], [1], [An object symbol dumper]) AC_SUBST([OBJDUMP]) ]) # _LT_DECL_DLLTOOL # ---------------- # Ensure DLLTOOL variable is set. m4_defun([_LT_DECL_DLLTOOL], [AC_CHECK_TOOL(DLLTOOL, dlltool, false) test -z "$DLLTOOL" && DLLTOOL=dlltool _LT_DECL([], [DLLTOOL], [1], [DLL creation program]) AC_SUBST([DLLTOOL]) ]) # _LT_DECL_FILECMD # ---------------- # Check for a file(cmd) program that can be used to detect file type and magic m4_defun([_LT_DECL_FILECMD], [AC_CHECK_TOOL([FILECMD], [file], [:]) _LT_DECL([], [FILECMD], [1], [A file(cmd) program that detects file types]) ])# _LD_DECL_FILECMD # _LT_DECL_SED # ------------ # Check for a fully-functional sed program, that truncates # as few characters as possible. Prefer GNU sed if found. m4_defun([_LT_DECL_SED], [AC_PROG_SED test -z "$SED" && SED=sed Xsed="$SED -e 1s/^X//" _LT_DECL([], [SED], [1], [A sed program that does not truncate output]) _LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"], [Sed that helps us avoid accidentally triggering echo(1) options like -n]) ])# _LT_DECL_SED m4_ifndef([AC_PROG_SED], [ ############################################################ # NOTE: This macro has been submitted for inclusion into # # GNU Autoconf as AC_PROG_SED. When it is available in # # a released version of Autoconf we should remove this # # macro and use it instead. # ############################################################ m4_defun([AC_PROG_SED], [AC_MSG_CHECKING([for a sed that does not truncate output]) AC_CACHE_VAL(lt_cv_path_SED, [# Loop through the user's path and test for sed and gsed. # Then use that list of sed's as ones to test for truncation. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for lt_ac_prog in sed gsed; do for ac_exec_ext in '' $ac_executable_extensions; do if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" fi done done done IFS=$as_save_IFS lt_ac_max=0 lt_ac_count=0 # Add /usr/xpg4/bin/sed as it is typically found on Solaris # along with /bin/sed that truncates output. for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do test ! -f "$lt_ac_sed" && continue cat /dev/null > conftest.in lt_ac_count=0 echo $ECHO_N "0123456789$ECHO_C" >conftest.in # Check for GNU sed and select it if it is found. if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then lt_cv_path_SED=$lt_ac_sed break fi while true; do cat conftest.in conftest.in >conftest.tmp mv conftest.tmp conftest.in cp conftest.in conftest.nl echo >>conftest.nl $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break cmp -s conftest.out conftest.nl || break # 10000 chars as input seems more than enough test 10 -lt "$lt_ac_count" && break lt_ac_count=`expr $lt_ac_count + 1` if test "$lt_ac_count" -gt "$lt_ac_max"; then lt_ac_max=$lt_ac_count lt_cv_path_SED=$lt_ac_sed fi done done ]) SED=$lt_cv_path_SED AC_SUBST([SED]) AC_MSG_RESULT([$SED]) ])#AC_PROG_SED ])#m4_ifndef # Old name: AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([LT_AC_PROG_SED], []) # _LT_CHECK_SHELL_FEATURES # ------------------------ # Find out whether the shell is Bourne or XSI compatible, # or has some other useful features. m4_defun([_LT_CHECK_SHELL_FEATURES], [if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then lt_unset=unset else lt_unset=false fi _LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl # test EBCDIC or ASCII case `echo X|tr X '\101'` in A) # ASCII based system # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr lt_SP2NL='tr \040 \012' lt_NL2SP='tr \015\012 \040\040' ;; *) # EBCDIC based system lt_SP2NL='tr \100 \n' lt_NL2SP='tr \r\n \100\100' ;; esac _LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl _LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl ])# _LT_CHECK_SHELL_FEATURES # _LT_PATH_CONVERSION_FUNCTIONS # ----------------------------- # Determine what file name conversion functions should be used by # func_to_host_file (and, implicitly, by func_to_host_path). These are needed # for certain cross-compile configurations and native mingw. m4_defun([_LT_PATH_CONVERSION_FUNCTIONS], [AC_REQUIRE([AC_CANONICAL_HOST])dnl AC_REQUIRE([AC_CANONICAL_BUILD])dnl AC_MSG_CHECKING([how to convert $build file names to $host format]) AC_CACHE_VAL(lt_cv_to_host_file_cmd, [case $host in *-*-mingw* ) case $build in *-*-mingw* ) # actually msys lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 ;; *-*-cygwin* ) lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 ;; * ) # otherwise, assume *nix lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 ;; esac ;; *-*-cygwin* ) case $build in *-*-mingw* ) # actually msys lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin ;; *-*-cygwin* ) lt_cv_to_host_file_cmd=func_convert_file_noop ;; * ) # otherwise, assume *nix lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin ;; esac ;; * ) # unhandled hosts (and "normal" native builds) lt_cv_to_host_file_cmd=func_convert_file_noop ;; esac ]) to_host_file_cmd=$lt_cv_to_host_file_cmd AC_MSG_RESULT([$lt_cv_to_host_file_cmd]) _LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd], [0], [convert $build file names to $host format])dnl AC_MSG_CHECKING([how to convert $build file names to toolchain format]) AC_CACHE_VAL(lt_cv_to_tool_file_cmd, [#assume ordinary cross tools, or native build. lt_cv_to_tool_file_cmd=func_convert_file_noop case $host in *-*-mingw* ) case $build in *-*-mingw* ) # actually msys lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 ;; esac ;; esac ]) to_tool_file_cmd=$lt_cv_to_tool_file_cmd AC_MSG_RESULT([$lt_cv_to_tool_file_cmd]) _LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd], [0], [convert $build files to toolchain format])dnl ])# _LT_PATH_CONVERSION_FUNCTIONS httrack-3.49.5/m4/check_zlib.m40000644000175000017500000000513714336470674013100 00000000000000dnl @synopsis CHECK_ZLIB() dnl dnl This macro searches for an installed zlib library. If nothing dnl was specified when calling configure, it searches first in /usr/local dnl and then in /usr. If the --with-zlib=DIR is specified, it will try dnl to find it in DIR/include/zlib.h and DIR/lib/libz.a. If --without-zlib dnl is specified, the library is not searched at all. dnl dnl If either the header file (zlib.h) or the library (libz) is not dnl found, the configuration exits on error, asking for a valid dnl zlib installation directory or --without-zlib. dnl dnl The macro defines the symbol HAVE_LIBZ if the library is found. You should dnl use autoheader to include a definition for this symbol in a config.h dnl file. Sample usage in a C/C++ source is as follows: dnl dnl #ifdef HAVE_LIBZ dnl #include dnl #endif /* HAVE_LIBZ */ dnl dnl @version $Id$ dnl @author Loic Dachary dnl AC_DEFUN([CHECK_ZLIB], # # Handle user hints # [AC_MSG_CHECKING(if zlib is wanted) AC_ARG_WITH(zlib, [ --with-zlib=DIR root directory path of zlib installation [defaults to /usr/local or /usr if not found in /usr/local] --without-zlib to disable zlib usage completely], [if test "$withval" != no ; then AC_MSG_RESULT(yes) ZLIB_HOME="$withval" else AC_MSG_RESULT(no) fi], [ AC_MSG_RESULT(yes) ZLIB_HOME=/usr/local if test ! -f "${ZLIB_HOME}/include/zlib.h" then ZLIB_HOME=/usr fi ]) # # Locate zlib, if wanted # if test -n "${ZLIB_HOME}" then ZLIB_OLD_LDFLAGS=$LDFLAGS ZLIB_OLD_CPPFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS -L${ZLIB_HOME}/lib" CPPFLAGS="$CPPFLAGS -I${ZLIB_HOME}/include" AC_LANG_SAVE AC_LANG_C AC_CHECK_LIB(z, inflateEnd, [zlib_cv_libz=yes], [zlib_cv_libz=no]) AC_CHECK_HEADER(zlib.h, [zlib_cv_zlib_h=yes], [zlib_cv_zlib_h=no]) AC_LANG_RESTORE if test "$zlib_cv_libz" = "yes" -a "$zlib_cv_zlib_h" = "yes" then # # If both library and header were found, use them # AC_CHECK_LIB(z, inflateEnd) AC_MSG_CHECKING(zlib in ${ZLIB_HOME}) AC_MSG_RESULT(ok) else # # If either header or library was not found, revert and bomb # AC_MSG_CHECKING(zlib in ${ZLIB_HOME}) LDFLAGS="$ZLIB_OLD_LDFLAGS" CPPFLAGS="$ZLIB_OLD_CPPFLAGS" AC_MSG_RESULT(failed) AC_MSG_ERROR(either specify a valid zlib installation with --with-zlib=DIR or disable zlib usage with --without-zlib) fi fi ])