bar-1.11.1.orig/0000755000175000017500000000000012076307715013504 5ustar georgeskgeorgeskbar-1.11.1.orig/io.c0000644000175000017500000002107410631614143014252 0ustar georgeskgeorgesk#include "config.h" #include "headers.h" #include "error.h" #include "fd.h" #include "io.h" /** I/O state data. */ IO io; /** Initialize I/O state data. * \return 0 for success. (This function does not fail.) */ int ioInit(void) { /** Initlalize the input file path to null. */ io.in_path = 0; /** Initialize the input file descriptor to standard input. */ io.in = STDIN_FILENO; /** Initialize the output file descriptor to standard output. */ io.out = STDOUT_FILENO; /** Set the initial end-of-file flags to false (or zero). */ io.eof_in = 0; io.eof_out = 0; /** Initialize the ring buffer. */ io.buffer_used = 0; io.buffer_head = 0; io.buffer_size = DEFAULT_BUFFER_SIZE; io.buffer = 0; /** Initialize the byte-counters. */ io.last_read = 0; io.last_write = 0; io.total_size = 0; io.total_size_known = 0; io.total_read = 0; io.total_write = 0; io.continue_size = 0; /** Initialize the I/O timeout to 1 millisecond. */ io.timeout = 1; /* 1/1000000 second */ /** Initialize the current time and the throttle counts. */ io.current_time = time(0); io.throttle_count = 1; io.throttle = MAX_UINT64; /** Initialize the default block size to 512 bytes. */ io.block_size = 512; /* 0.5k default */ return(0); } #ifdef HAVE_SIGNAL_H /** A signal handler for control-C. * * \param signo The signal number. */ static void sig_int(int signo) { /** Return I/O streams to a default state before exiting. */ fdEnd(io.in); fdEnd(io.out); exit(1); } #endif #ifdef HAVE_SYSCONF # if HAVE_DECL__SC_PAGE_SIZE == 1 # define PAGESIZE _SC_PAGE_SIZE # else # if HAVE_DECL__SC_PAGESIZE == 1 # define PAGESIZE _SC_PAGESIZE # endif # endif # ifndef PAGESIZE # warning I dont know how to retrieve the size of a page using sysconf. # warning Assuming page size is DEFAULT_PAGE_SIZE bytes. # undef HAVE_SYSCONF # endif #endif /** Prepare I/O * * \return 0 for success, non-zero for failure. */ int ioBegin(void) { /** If memalign() or posix_memalign() is available, then allocate memory on * a page boundary. If sysconf() is available, find out what the page size * is for this machine, otherwise assume that a page is 8192 bytes. */ #if defined(USE_MEMALIGN) \ && (defined(HAVE_POSIX_MEMALIGN) || defined(HAVE_MEMALIGN)) long page_size = 0; # ifdef HAVE_SYSCONF page_size = sysconf(PAGESIZE); # else page_size = DEFAULT_PAGE_SIZE; # endif #endif /** Allocate memory for the ring buffer. */ #undef USED_MEMALIGN #ifdef USE_MEMALIGN # if defined(HAVE_POSIX_MEMALIGN) # define USED_MEMALIGN if ( /** Incorporating patch provided by Doncho N. Gunchev * Closes bug: [ 1158420 ] glibc detects invalid free on exit (Fedora Core 3) * */ posix_memalign((void*)&io.buffer, page_size, sizeof(char) * io.buffer_size) != 0 ) { print_error(stderr, "Memory allocation failed"); return(1); } /* # elif defined(HAVE_MEMALIGN) # if defined(USE_MEMALIGN_BOUNDARY_SIZE) # define USED_MEMALIGN io.buffer = (char *)memalign(page_size, sizeof(char) * io.buffer_size); # elif defined(USE_MEMALIGN_SIZE_BOUNDARY) # define USED_MEMALIGN io.buffer = (char *)memalign(sizeof(char) * io.buffer_size, page_size); # endif */ # endif #endif #ifndef USED_MEMALIGN io.buffer = (char *)malloc(sizeof(char) * io.buffer_size); #endif if (io.buffer == 0) { print_error(stderr, "Memory allocation failed"); return(1); } /** If we have signal(), then set up a signal handler to catch control-C's. */ #ifdef HAVE_SIGNAL_H if (signal(SIGINT, sig_int) == SIG_ERR) { print_error(stderr, "Could not install SIGINT signal handler"); print_error(stderr, "Control-C events will not reset non-blocking I/O"); } #endif /** Prepare the I/O file descriptors. */ fdBegin(io.in); fdBegin(io.out); return(0); } /** Shut down I/O * * \return 0 for success. (This function does not fail.) */ int ioEnd(void) { /** Free the I/O buffer. */ free(io.buffer); io.buffer = 0; io.buffer_used = 0; /** Return the file descriptors to their previous state. */ fdEnd(io.in); fdEnd(io.out); return(0); } /** Check to see if I/O is ready. */ void ioCheck(void) { static fd_set rset, wset; static struct timeval to; to.tv_sec = 0; /** Wait for up to io.timeout milliseconds for a change in I/O state. */ to.tv_usec = io.timeout; io.in_ready = 1; io.out_ready = 1; FD_ZERO(&rset); FD_ZERO(&wset); if (io.buffer_used != io.buffer_size) FD_SET(io.in, &rset); if (io.buffer_used) FD_SET(io.out, &wset); /** Check to see if I/O is ready. */ if (select( ((io.in= io.throttle)) { return(0); } if (io.current_time != time(0)) { io.throttle_count = 0; io.current_time = time(0); } /** If there is nothing to read yet, return. */ if (!io.in_ready) return(0); io.last_read = 0; /** If we've reached the end of input, return. */ if (io.eof_in) return(0); /** If the buffer is full, return. */ if (io.buffer_used == io.buffer_size) return(0); /** Calculate the location and size of the free space in the buffer. */ end = (io.buffer_used + io.buffer_head) % io.buffer_size; avail = io.buffer_size - io.buffer_used; /** If the free space in the buffer is greater than the number of bytes left * to be read in this second, throttle the input. */ if ((io.throttle - io.throttle_count) < avail) avail = io.throttle - io.throttle_count; #ifdef USE_IOVEC /** If using iovec I/O, set up vec[] with the proper information and then * read using iovec I/O. */ vec[num ].iov_base = io.buffer + end; if (end+avail <= io.buffer_size) vec[num++].iov_len = avail; else { vec[num++].iov_len = io.buffer_size - end; vec[num ].iov_base = io.buffer; vec[num++].iov_len = avail - (io.buffer_size - end); } num_read = readv(io.in, vec, num); #else /** If not using iovec, then read input into the next available chunk of * linear buffer space. */ if (end+avail <= io.buffer_size) { num_read = read(io.in, io.buffer + end, avail); } else { num_read = read(io.in, io.buffer + end, io.buffer_size - end); } #endif /** Check for end of file. */ if (num_read == 0) { io.eof_in = 1; return(0); } /** Check for an error. */ if ((num_read < 0) && (errno == EAGAIN)) num_read = 0; if (num_read < 0) return(num_read); /** Update I/O byte counters. */ io.buffer_used += num_read; io.last_read = num_read; io.total_read += num_read; io.throttle_count += num_read; return(0); } /** Write data * * \return 0 for success, non-zero for failure. */ int ioWrite(void) { int num_written = 0; #ifdef USE_IOVEC int num = 0; struct iovec vec[2] = { { 0 } }; #endif /** If output is not ready, return. */ if (!io.out_ready) return(0); io.last_write = 0; #ifdef USE_IOVEC /** If using iovec I/O, set up vec[] with the correct information and then * write. */ vec[num ].iov_base = io.buffer + io.buffer_head; if (io.buffer_head + io.buffer_used <= io.buffer_size) vec[num++].iov_len = io.buffer_used; else { vec[num++].iov_len = io.buffer_size - io.buffer_head; vec[num ].iov_base = io.buffer; vec[num++].iov_len = io.buffer_used - (io.buffer_size - io.buffer_head); } num_written = writev(io.out, vec, num); #else /** If not using iovec, then write the next chunk of linear data from the * buffer. */ if (io.buffer_head + io.buffer_used <= io.buffer_size) { num_written = write(io.out, io.buffer + io.buffer_head, io.buffer_used); } else { num_written = write(io.out, io.buffer + io.buffer_head, io.buffer_size - io.buffer_head); } #endif /** Check for end of file. */ if (num_written == 0) { io.eof_out = 1; return(0); } /** Check for an error. */ if ((num_written < 0) && (errno == EAGAIN)) num_written = 0; if (num_written < 0) return(num_written); /** Update the I/O byte counters. */ io.buffer_used -= num_written; io.buffer_head = (io.buffer_head + num_written) % io.buffer_size; io.last_write = num_written; io.total_write += num_written; return(0); } /** Check to see if we're done copying input to output * * \return 1 if done, 0 otherwise. */ int ioIsDone(void) { if ((io.eof_in && (io.buffer_used == 0)) || io.eof_out) return(1); return(0); } bar-1.11.1.orig/aclocal.m40000644000175000017500000010431711541656133015347 0ustar georgeskgeorgesk# generated automatically by aclocal 1.11 -*- Autoconf -*- # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, # 2005, 2006, 2007, 2008, 2009 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_AUTOCONF_VERSION], [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.64],, [m4_warning([this file was generated for autoconf 2.64. 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'.])]) # Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008 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.11' 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.11], [], [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.11])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, 2003, 2005 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], [dnl Rely on autoconf to set up CDPATH properly. AC_PREREQ([2.50])dnl # expand $ac_aux_dir to an absolute path am_aux_dir=`cd $ac_aux_dir && pwd` ]) # AM_CONDITIONAL -*- Autoconf -*- # Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006, 2008 # 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. # serial 9 # AM_CONDITIONAL(NAME, SHELL-CONDITION) # ------------------------------------- # Define a conditional. AC_DEFUN([AM_CONDITIONAL], [AC_PREREQ(2.52)dnl ifelse([$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, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2009 # 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. # serial 10 # 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", "GCJ", or "OBJC". # 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 ifelse([$1], CC, [depcc="$CC" am_compiler_list=], [$1], CXX, [depcc="$CXX" am_compiler_list=], [$1], OBJC, [depcc="$OBJC" 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'. 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 8's {/usr,}/bin/sh. touch 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 ;; 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, [ --disable-dependency-tracking speeds up one-time build --enable-dependency-tracking do not reject slow dependency extractors]) if test "x$enable_dependency_tracking" != xno; then am_depcomp="$ac_aux_dir/depcomp" AMDEPBACKSLASH='\' fi AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) AC_SUBST([AMDEPBACKSLASH])dnl _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl ]) # Generate code to set up dependency tracking. -*- Autoconf -*- # Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2008 # 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. #serial 5 # _AM_OUTPUT_DEPENDENCY_COMMANDS # ------------------------------ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], [{ # Autoconf 2.62 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. case $CONFIG_FILES in *\'*) eval set x "$CONFIG_FILES" ;; *) set x $CONFIG_FILES ;; esac shift for mf do # Strip MF so we end up with the name of the file. mf=`echo "$mf" | sed -e 's/:.*$//'` # Check whether this is an Automake generated Makefile or not. # We used to match only the files named `Makefile.in', but # some people rename them; so instead we look at the file content. # Grep'ing the first line is not enough: some people post-process # each Makefile.in and add a new line on top of each file to say so. # Grep'ing the whole file is not good either: AIX grep has a line # limit of 2048, but all sed's we know have understand at least 4000. if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then dirpart=`AS_DIRNAME("$mf")` else continue fi # Extract the definition of DEPDIR, am__include, and am__quote # from the Makefile without running `make'. DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` test -z "$DEPDIR" && continue am__include=`sed -n 's/^am__include = //p' < "$mf"` test -z "am__include" && continue am__quote=`sed -n 's/^am__quote = //p' < "$mf"` # When using ansi2knr, U may be empty or an underscore; expand it U=`sed -n 's/^U = //p' < "$mf"` # Find all dependency output files, they are included files with # $(DEPDIR) in their names. We invoke sed twice because it is the # simplest approach to changing $(DEPDIR) to its actual value in the # expansion. for file in `sed -n " s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do # Make sure the directory exists. test -f "$dirpart/$file" && continue fdir=`AS_DIRNAME(["$file"])` AS_MKDIR_P([$dirpart/$fdir]) # echo "creating $dirpart/$file" echo '# dummy' > "$dirpart/$file" done done } ])# _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. FIXME. This creates each `.P' file that we will # 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" ac_aux_dir="$ac_aux_dir"]) ]) # Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005 # 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. # serial 8 # AM_CONFIG_HEADER is obsolete. It has been replaced by AC_CONFIG_HEADERS. AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)]) # Do all the work for Automake. -*- Autoconf -*- # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, # 2005, 2006, 2008, 2009 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. # serial 16 # 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. # 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.62])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], [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_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,, [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([AM_PROG_MKDIR_P])dnl # We need awk for the "check" target. 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)], [define([AC_PROG_CC], defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl AC_PROVIDE_IFELSE([AC_PROG_CXX], [_AM_DEPENDENCIES(CXX)], [define([AC_PROG_CXX], defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl AC_PROVIDE_IFELSE([AC_PROG_OBJC], [_AM_DEPENDENCIES(OBJC)], [define([AC_PROG_OBJC], defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl ]) _AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl dnl The `parallel-tests' driver may need to know about EXEEXT, so add the dnl `am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This macro dnl 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 ]) 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, 2003, 2005, 2008 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}" != 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, 2005 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. # serial 2 # 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])]) # Check to see how 'make' treats includes. -*- Autoconf -*- # Copyright (C) 2001, 2002, 2003, 2005, 2009 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. # serial 4 # AM_MAKE_INCLUDE() # ----------------- # Check to see how make treats includes. AC_DEFUN([AM_MAKE_INCLUDE], [am_make=${MAKE-make} cat > confinc << 'END' am__doit: @echo this is the am__doit target .PHONY: am__doit END # If we don't find an include directive, just comment out the code. AC_MSG_CHECKING([for style of include used by $am_make]) am__include="#" am__quote= _am_result=none # First try GNU make style include. echo "include confinc" > confmf # Ignore all kinds of additional output from `make'. case `$am_make -s -f confmf 2> /dev/null` in #( *the\ am__doit\ target*) am__include=include am__quote= _am_result=GNU ;; esac # Now try BSD make style include. if test "$am__include" = "#"; then echo '.include "confinc"' > confmf case `$am_make -s -f confmf 2> /dev/null` in #( *the\ am__doit\ target*) am__include=.include am__quote="\"" _am_result=BSD ;; esac fi AC_SUBST([am__include]) AC_SUBST([am__quote]) AC_MSG_RESULT([$_am_result]) rm -f confinc confmf ]) # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- # Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005, 2008 # 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. # serial 6 # 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 supports --run. # If it does, 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 case $am_aux_dir in *\ * | *\ *) MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; *) MISSING="\${SHELL} $am_aux_dir/missing" ;; esac fi # Use eval to expand $SHELL if eval "$MISSING --run true"; then am_missing_run="$MISSING --run " else am_missing_run= AC_MSG_WARN([`missing' script is too old or missing]) fi ]) # Copyright (C) 2003, 2004, 2005, 2006 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_MKDIR_P # --------------- # Check for `mkdir -p'. AC_DEFUN([AM_PROG_MKDIR_P], [AC_PREREQ([2.60])dnl AC_REQUIRE([AC_PROG_MKDIR_P])dnl dnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P, dnl while keeping a definition of mkdir_p for backward compatibility. dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile. dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of dnl Makefile.ins that do not define MKDIR_P, so we do our own dnl adjustment using top_builddir (which is defined more often than dnl MKDIR_P). AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl case $mkdir_p in [[\\/$]]* | ?:[[\\/]]*) ;; */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; esac ]) # Helper functions for option handling. -*- Autoconf -*- # Copyright (C) 2001, 2002, 2003, 2005, 2008 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. # serial 4 # _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])]) # Check to make sure that the build environment is sane. -*- Autoconf -*- # Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005, 2008 # 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. # serial 5 # AM_SANITY_CHECK # --------------- AC_DEFUN([AM_SANITY_CHECK], [AC_MSG_CHECKING([whether build environment is sane]) # Just in case sleep 1 echo timestamp > conftest.file # 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 ( 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 rm -f conftest.file 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 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)]) # Copyright (C) 2001, 2003, 2005 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, 2008 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. # serial 2 # _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, 2005 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. # serial 2 # _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. AM_MISSING_PROG([AMTAR], [tar]) m4_if([$1], [v7], [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'], [m4_case([$1], [ustar],, [pax],, [m4_fatal([Unknown tar format])]) AC_MSG_CHECKING([how to create a $1 tar archive]) # Loop over all known methods to create a tar archive until one works. _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' _am_tools=${am_cv_prog_tar_$1-$_am_tools} # Do not fold the above two line into one, because Tru64 sh and # Solaris sh will not grok spaces in the rhs of `-'. 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 bar-1.11.1.orig/TROUBLESHOOTING0000644000175000017500000001175410510504276015716 0ustar georgeskgeorgeskIn the event that bar does not operate propperly, then, if you are willing, the author is interested in hearing from you. The first thing the author will want from you, apart from a description of the problem you are experiencing, is information about bar as it is configured now, and when it is configured with I/O optimizations turned off. To make this process easier for you the user, first try running the shell script ./troubleshooter. It will assemble a file with all the output that the author will want regarding how bar configures, compiles, and runs on your system. However, if, by some chance, the ./troubleshooter script fails for you, then you can open this file in your favorite editor and follow the instructions below. *** NOTE: If ./troubleshooter worked for you, then you can skip the rest of this file. Simply email a description of your problem to michaelpeek@users.sourceforge.net and attach the log file that ./troubleshooter generated. The questions below are only for people wishing to report a problem with bar for whom the ./troubleshooter script failed to run. STEP 1: When you run ./configure, if the configuration process finishes successfully you should see text at the end that lists bar's configuration options. This text begins with the line "configure: Current configuration:", and should look something like this: configure: Current Configuration: configure: ---------------------- configure: Screen width -1 modifier: no configure: Display twiddle by default: no configure: Use aligned memory allocation: yes (default page size: 4096) configure: Use vectored I/O: yes configure: Default I/O buffer size: 52488 If you do not see lines like those listed above when you run ./configure, then the configuration process is ending prematurely with an error. Q1) Does the configuration process complete propperly on your system? (I.e. do you see the "Current Configuration" line?) If the configuration process is ending in error, back up your config.log file with the following command: $ mv config.log config.log.broken Then skip to step 4 below. STEP 2: After configuring bar, the next thing a user does is type "make" to build the program. In the event that make fails, an error message should be printed to the screen. Q2) Does bar compile on your system? Q3) If it does not, what is the error that make prints to the screen? (Try to cut-and-paste the exact text if possible.) If the compilation process is ending in error, back up your config.log file with the following command: $ mv config.log config.log.broken Then skip to step 4 below. STEP 3: After building bar, the next thing to do is test it by typing "make check". This will run tests on bar to see if it is at least capable of copying data correctly. If all tests pass, you should see text similar to the following: ================== All ? tests passed ================== Q4) Does bar pass all of it's tests? Q5) If not, which tests fail? STEP 4: Bar contains some optimizations that take advantage of features available in most modern unix-like operating systems, specifically aligned memory allocation and vectored I/O. Most of the time the configuration process is able to correctly determine whether or not these features are available and how to use them, but differences in one O/S to another, or even from one distribution to another of the same O/S, will cause changes in the way that these features are implemented. While the author has tried as many tricks as he can think of to propperly test these features before using them in bar, sometimes something new comes along that was unforseen. Therefore the next thing to do is to try building and testing bar without these optimizations. Try re-configuring bar, except this time specify --disable-use-memalign and --disable-use-iovec. Your command line should look similar to the following: $ ./configure --disable-use-memalign --disable-use-iovec Q6) Does the configuration process complete propperly? If the configuration process is ending in error, skip to step 5 below. If bar does configure propperly, try to compile bar. $ make Q7) Does the compilation process complete propperly? Q8) If it does not, what is the error that make prints to the screen? If the compilation process is ending in error, skip to step 5 below. If bar compiles propperly, try testing bar. $ make check Q9) Does bar pass it's tests? Q10) If not, which tests fail? STEP 5: Although the author has access to several flavors of unix-like operating systems, your system may be different. Q11) Are you willing, and do you have the time to assist the author by testing improvements to bar? Q12) If so, do you have access to the internet via: a) email? b) web browser? STEP 6: Email this file to michaelpeek@users.sourceforge.net. Attach your config.log file and, if you have a config.log.broken file, attach that as well. Even if bar works for you without aligned memory and vectored I/O, this information can be useful to the author to improve future versions of bar. bar-1.11.1.orig/error.c0000644000175000017500000000122110510504276014765 0ustar georgeskgeorgesk#include "config.h" #include "headers.h" #include "error.h" int get_errno(void) { return(errno); } void clear_errno(void) { errno = 0; } void print_error(FILE *ferr, char *fmt, ...) { va_list ap; char msg[256] = { 0 }; va_start(ap, fmt); (void)vsprintf(msg, fmt, ap); va_end(ap); fprintf(ferr, "*** ERROR: "); if (errno != 0) { fprintf(ferr, "[%d]: %s\n", errno, strerror(errno)); fprintf(ferr, " "); } fprintf(ferr, "%s\n", msg); } void print_esup(FILE *ferr, char *fmt, ...) { va_list ap; char msg[256] = { 0 }; va_start(ap, fmt); (void)vsprintf(msg, fmt, ap); va_end(ap); fprintf(ferr, " %s\n", msg); } bar-1.11.1.orig/args.h0000644000175000017500000000051611433262675014614 0ustar georgeskgeorgesk#ifndef __args_h__ #define __args_h__ #include "headers.h" #include "types.h" int parse_char(FILE *ferr, char *s, char *c); int parse_num(FILE *ferr, char *s, uint64 *n, uint64 min, uint64 max); int parse_rcfile(FILE *ferr, char *filename); int parse_rcfiles(FILE *ferr); int parse_args(FILE *ferr, int argc, char *argv[]); #endif bar-1.11.1.orig/autogen0000754000175000017500000000013010510504276015055 0ustar georgeskgeorgesk#!/bin/sh aclocal autoheader autoconf automake --add-missing --include-deps --foreign bar-1.11.1.orig/display.h0000644000175000017500000000365511433304216015320 0ustar georgeskgeorgesk/* * Display */ #ifndef __display_h__ #define __display_h__ #include "headers.h" #include "types.h" #include "io.h" struct _display { time_t start_time; time_t total_time; time_t current_time; time_t elapsed_time; float percent_complete; int display_interval; int overtime_flag; unsigned int k; char twiddle; int screen_width; int screen_width_minus_one; int manual_width; int screen_height; int screen_height_minus_one; int manual_height; int display_wait; int display_numeric; int display_twiddle; int display_title; int display_datacount; int display_throughput; int display_time; int display_elapsed_only; int display_percent; int display_bar; int display_summary; int display_ansi; int display_throughput_bits; int display_count_bits; char title[81]; char *space_bg_color; char *twiddle_fg_color; char *twiddle_bg_color; int twiddle_fg_bold; char *title_bg_color; char *title_fg_color; int title_fg_bold; char *datacount_fg_color; char *datacount_bg_color; int datacount_fg_bold; char *throughput_label_fg_color; char *throughput_label_bg_color; int throughput_label_fg_bold; char *throughput_fg_color; char *throughput_bg_color; int throughput_fg_bold; char *time_label_fg_color; char *time_label_bg_color; int time_label_fg_bold; char *time_fg_color; char *time_bg_color; int time_fg_bold; char *percent_fg_color; char *percent_bg_color; int percent_fg_bold; char *bar_fg_color; char *bar_bg_color; int bar_fg_bold; char *barbrace_fg_color; char *barbrace_bg_color; char bar_open_brace; char bar_close_brace; char bar_complete; char bar_incomplete; int barbrace_fg_bold; int total_display_percent; char *info_file; FILE *info_fin; int info_num; float info_percent_threshold; float info_percent_count; char info_line[256]; }; typedef struct _display display; extern display d; int displayInit(void); int displayBegin(void); int displayUpdate(void); int displayEnd(void); #endif bar-1.11.1.orig/test-0040000754000175000017500000000436310510504276014707 0ustar georgeskgeorgesk#!/bin/sh src_file="./test-file-004.bin" tmp_file="./test-file-004.incomplete.bin" dst_file_1="./test-file-004.1.bin" dst_file_2="./test-file-004.2.bin" echo echo "NOTICE: This test takes a very long time." echo if [ ! -f "${src_file}" ]; then echo "- Creating main test file (this may take a while...)" (cd / \ && tar -cf - \ ./usr/X* \ ./usr/bin \ ./usr/doc \ ./usr/include \ ./usr/info \ ./usr/lib \ ./usr/sbin \ ./usr/share \ ./usr/src \ ./bin \ ./etc \ ./lib \ ./opt \ ./sbin \ ./var \ 2> /dev/null ) | dd of=${tmp_file} 2> /dev/null if [ "$?" -ne 0 ]; then echo "*** ERROR: Failed to create test file" echo " Test inconclusive" exit 1 fi mv ${tmp_file} ${src_file} if [ "$?" -ne 0 ]; then echo "*** ERROR: Failed to create test file" echo " Test inconclusive" exit 1 rm -f ${tmp_file} exit 1 fi fi for buffer_size in 1k 2k 4k 8k 16k 32k 64k 128k 256k 512k 1m 2m; do for block_size in 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 30 31 32 33 34 63 \ 64 65 127 128 129 255 256 257 500 501 502 503 504 505 506 507 508 509 510 \ 511 512 513 514 515 516 517 518 519 520 1024 2048 3096;\ do for block_count in 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 30 31 32 33 34 63 \ 64 65 127 128 129 255 256 257 500 501 502 503 504 505 506 507 508 509 510 \ 511 512 513 514 515 516 517 518 519 520 1024 2048 3096;\ do rm -f ${dst_file_1} 2> /dev/null rm -f ${dst_file_2} 2> /dev/null dd \ if=${src_file} \ bs=${block_size} \ count=${block_count} \ of=${dst_file_1} \ 2> /dev/null if [ "$?" -ne 0 ]; then echo "*** ERROR: Could not create test subfile" echo " Test inconclusive" exit 1 fi dd \ if=${dst_file_1} \ 2> /dev/null \ | ./bar \ -s ${block_count}b \ -of ${dst_file_2} \ -bl ${block_size} \ -bs ${buffer_size} \ 2> /dev/null \ # if [ "$?" -ne 0 ]; then echo "ERROR: bar failed" exit 1 fi cmp ${dst_file_1} ${dst_file_2} if [ "$?" -ne 0 ]; then echo "ERROR: Files differ" echo " Buffer Size: ${buffer_size}" echo " Block Size: ${block_size}" echo " Block Count: ${block_count}" exit 1 fi done done done rm ${dst_file_1} ${dst_file_2} bar-1.11.1.orig/test-001-pre.c0000644000175000017500000000047310510504276015705 0ustar georgeskgeorgesk#include "config.h" #include "headers.h" int main(int argc, char *argv[]) { int out = 0; char *buffer = "Hello World\n"; #ifdef DEBUG int debug = 1; while (debug); #endif out = STDOUT_FILENO; write(out, buffer, strlen(buffer)); sleep(5); write(out, buffer, strlen(buffer)); close(out); return(0); } bar-1.11.1.orig/AUTHORS0000644000175000017500000000004210510504276014540 0ustar georgeskgeorgeskMichael Peek bar-1.11.1.orig/error.h0000644000175000017500000000031710510504276014777 0ustar georgeskgeorgesk#ifndef __error_h__ #define __error_h__ #include "headers.h" int get_errno(void); void clear_errno(void); void print_error(FILE *ferr, char *fmt, ...); void print_esup(FILE *ferr, char *fmt, ...); #endif bar-1.11.1.orig/COPYING0000644000175000017500000006131410510504276014534 0ustar georgeskgeorgesk GNU LIBRARY GENERAL PUBLIC LICENSE Version 2, June 1991 Copyright (C) 1991 Free Software Foundation, Inc. 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. [This is the first released version of the library GPL. It is numbered 2 because it goes with version 2 of the ordinary GPL.] Preamble The licenses for most software are designed to take away your freedom to share and change it. By contrast, the GNU General Public Licenses are intended to guarantee your freedom to share and change free software--to make sure the software is free for all its users. This license, the Library General Public License, applies to some specially designated Free Software Foundation software, and to any other libraries whose authors decide to use it. You can use it for your libraries, 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 this service 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 make restrictions that forbid anyone to deny you these rights or to ask you to surrender the rights. These restrictions translate to certain responsibilities for you if you distribute copies of the library, or if you modify it. For example, if you distribute copies of the library, whether gratis or for a fee, you must give the recipients all the rights that we gave you. You must make sure that they, too, receive or can get the source code. If you link a program with the library, you must provide complete object files to the recipients so that they can relink them with the library, after making changes to the library and recompiling it. And you must show them these terms so they know their rights. Our method of protecting your rights has two steps: (1) copyright the library, and (2) offer you this license which gives you legal permission to copy, distribute and/or modify the library. Also, for each distributor's protection, we want to make certain that everyone understands that there is no warranty for this free library. If the library is modified by someone else and passed on, we want its recipients to know that what they have is not the original version, so that any problems introduced by others will not reflect on the original authors' reputations. Finally, any free program is threatened constantly by software patents. We wish to avoid the danger that companies distributing free software will individually obtain patent licenses, thus in effect transforming the program into proprietary software. To prevent this, we have made it clear that any patent must be licensed for everyone's free use or not licensed at all. Most GNU software, including some libraries, is covered by the ordinary GNU General Public License, which was designed for utility programs. This license, the GNU Library General Public License, applies to certain designated libraries. This license is quite different from the ordinary one; be sure to read it in full, and don't assume that anything in it is the same as in the ordinary license. The reason we have a separate public license for some libraries is that they blur the distinction we usually make between modifying or adding to a program and simply using it. Linking a program with a library, without changing the library, is in some sense simply using the library, and is analogous to running a utility program or application program. However, in a textual and legal sense, the linked executable is a combined work, a derivative of the original library, and the ordinary General Public License treats it as such. Because of this blurred distinction, using the ordinary General Public License for libraries did not effectively promote software sharing, because most developers did not use the libraries. We concluded that weaker conditions might promote sharing better. However, unrestricted linking of non-free programs would deprive the users of those programs of all benefit from the free status of the libraries themselves. This Library General Public License is intended to permit developers of non-free programs to use free libraries, while preserving your freedom as a user of such programs to change the free libraries that are incorporated in them. (We have not seen how to achieve this as regards changes in header files, but we have achieved it as regards changes in the actual functions of the Library.) The hope is that this will lead to faster development of free libraries. The precise terms and conditions for copying, distribution and modification follow. Pay close attention to the difference between a "work based on the library" and a "work that uses the library". The former contains code derived from the library, while the latter only works together with the library. Note that it is possible for a library to be covered by the ordinary General Public License rather than by this special one. GNU LIBRARY GENERAL PUBLIC LICENSE TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 0. This License Agreement applies to any software library which contains a notice placed by the copyright holder or other authorized party saying it may be distributed under the terms of this Library General Public License (also called "this License"). Each licensee is addressed as "you". A "library" means a collection of software functions and/or data prepared so as to be conveniently linked with application programs (which use some of those functions and data) to form executables. The "Library", below, refers to any such software library or work which has been distributed under these terms. A "work based on the Library" means either the Library or any derivative work under copyright law: that is to say, a work containing the Library or a portion of it, either verbatim or with modifications and/or translated straightforwardly into another language. (Hereinafter, translation is included without limitation in the term "modification".) "Source code" for a work means the preferred form of the work for making modifications to it. For a library, complete source code means all the source code for all modules it contains, plus any associated interface definition files, plus the scripts used to control compilation and installation of the library. Activities other than copying, distribution and modification are not covered by this License; they are outside its scope. The act of running a program using the Library is not restricted, and output from such a program is covered only if its contents constitute a work based on the Library (independent of the use of the Library in a tool for writing it). Whether that is true depends on what the Library does and what the program that uses the Library does. 1. You may copy and distribute verbatim copies of the Library's complete source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice and disclaimer of warranty; keep intact all the notices that refer to this License and to the absence of any warranty; and distribute a copy of this License along with the Library. You may charge a fee for the physical act of transferring a copy, and you may at your option offer warranty protection in exchange for a fee. 2. You may modify your copy or copies of the Library or any portion of it, thus forming a work based on the Library, and copy and distribute such modifications or work under the terms of Section 1 above, provided that you also meet all of these conditions: a) The modified work must itself be a software library. b) You must cause the files modified to carry prominent notices stating that you changed the files and the date of any change. c) You must cause the whole of the work to be licensed at no charge to all third parties under the terms of this License. d) If a facility in the modified Library refers to a function or a table of data to be supplied by an application program that uses the facility, other than as an argument passed when the facility is invoked, then you must make a good faith effort to ensure that, in the event an application does not supply such function or table, the facility still operates, and performs whatever part of its purpose remains meaningful. (For example, a function in a library to compute square roots has a purpose that is entirely well-defined independent of the application. Therefore, Subsection 2d requires that any application-supplied function or table used by this function must be optional: if the application does not supply it, the square root function must still compute square roots.) These requirements apply to the modified work as a whole. If identifiable sections of that work are not derived from the Library, and can be reasonably considered independent and separate works in themselves, then this License, and its terms, do not apply to those sections when you distribute them as separate works. But when you distribute the same sections as part of a whole which is a work based on the Library, the distribution of the whole must be on the terms of this License, whose permissions for other licensees extend to the entire whole, and thus to each and every part regardless of who wrote it. Thus, it is not the intent of this section to claim rights or contest your rights to work written entirely by you; rather, the intent is to exercise the right to control the distribution of derivative or collective works based on the Library. In addition, mere aggregation of another work not based on the Library with the Library (or with a work based on the Library) on a volume of a storage or distribution medium does not bring the other work under the scope of this License. 3. You may opt to apply the terms of the ordinary GNU General Public License instead of this License to a given copy of the Library. To do this, you must alter all the notices that refer to this License, so that they refer to the ordinary GNU General Public License, version 2, instead of to this License. (If a newer version than version 2 of the ordinary GNU General Public License has appeared, then you can specify that version instead if you wish.) Do not make any other change in these notices. Once this change is made in a given copy, it is irreversible for that copy, so the ordinary GNU General Public License applies to all subsequent copies and derivative works made from that copy. This option is useful when you wish to copy part of the code of the Library into a program that is not a library. 4. You may copy and distribute the Library (or a portion or derivative of it, under Section 2) in object code or executable form under the terms of Sections 1 and 2 above provided that you accompany it with the complete corresponding machine-readable source code, which must be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange. If distribution of object code is made by offering access to copy from a designated place, then offering equivalent access to copy the source code from the same place satisfies the requirement to distribute the source code, even though third parties are not compelled to copy the source along with the object code. 5. A program that contains no derivative of any portion of the Library, but is designed to work with the Library by being compiled or linked with it, is called a "work that uses the Library". Such a work, in isolation, is not a derivative work of the Library, and therefore falls outside the scope of this License. However, linking a "work that uses the Library" with the Library creates an executable that is a derivative of the Library (because it contains portions of the Library), rather than a "work that uses the library". The executable is therefore covered by this License. Section 6 states terms for distribution of such executables. When a "work that uses the Library" uses material from a header file that is part of the Library, the object code for the work may be a derivative work of the Library even though the source code is not. Whether this is true is especially significant if the work can be linked without the Library, or if the work is itself a library. The threshold for this to be true is not precisely defined by law. If such an object file uses only numerical parameters, data structure layouts and accessors, and small macros and small inline functions (ten lines or less in length), then the use of the object file is unrestricted, regardless of whether it is legally a derivative work. (Executables containing this object code plus portions of the Library will still fall under Section 6.) Otherwise, if the work is a derivative of the Library, you may distribute the object code for the work under the terms of Section 6. Any executables containing that work also fall under Section 6, whether or not they are linked directly with the Library itself. 6. As an exception to the Sections above, you may also compile or link a "work that uses the Library" with the Library to produce a work containing portions of the Library, and distribute that work under terms of your choice, provided that the terms permit modification of the work for the customer's own use and reverse engineering for debugging such modifications. You must give prominent notice with each copy of the work that the Library is used in it and that the Library and its use are covered by this License. You must supply a copy of this License. If the work during execution displays copyright notices, you must include the copyright notice for the Library among them, as well as a reference directing the user to the copy of this License. Also, you must do one of these things: a) Accompany the work with the complete corresponding machine-readable source code for the Library including whatever changes were used in the work (which must be distributed under Sections 1 and 2 above); and, if the work is an executable linked with the Library, with the complete machine-readable "work that uses the Library", as object code and/or source code, so that the user can modify the Library and then relink to produce a modified executable containing the modified Library. (It is understood that the user who changes the contents of definitions files in the Library will not necessarily be able to recompile the application to use the modified definitions.) b) Accompany the work with a written offer, valid for at least three years, to give the same user the materials specified in Subsection 6a, above, for a charge no more than the cost of performing this distribution. c) If distribution of the work is made by offering access to copy from a designated place, offer equivalent access to copy the above specified materials from the same place. d) Verify that the user has already received a copy of these materials or that you have already sent this user a copy. For an executable, the required form of the "work that uses the Library" must include any data and utility programs needed for reproducing the executable from it. However, as a special exception, the source code distributed need not include anything that is normally distributed (in either source or binary form) with the major components (compiler, kernel, and so on) of the operating system on which the executable runs, unless that component itself accompanies the executable. It may happen that this requirement contradicts the license restrictions of other proprietary libraries that do not normally accompany the operating system. Such a contradiction means you cannot use both them and the Library together in an executable that you distribute. 7. You may place library facilities that are a work based on the Library side-by-side in a single library together with other library facilities not covered by this License, and distribute such a combined library, provided that the separate distribution of the work based on the Library and of the other library facilities is otherwise permitted, and provided that you do these two things: a) Accompany the combined library with a copy of the same work based on the Library, uncombined with any other library facilities. This must be distributed under the terms of the Sections above. b) Give prominent notice with the combined library of the fact that part of it is a work based on the Library, and explaining where to find the accompanying uncombined form of the same work. 8. You may not copy, modify, sublicense, link with, or distribute the Library except as expressly provided under this License. Any attempt otherwise to copy, modify, sublicense, link with, or distribute the Library is void, and will automatically terminate your rights under this License. However, parties who have received copies, or rights, from you under this License will not have their licenses terminated so long as such parties remain in full compliance. 9. You are not required to accept this License, since you have not signed it. However, nothing else grants you permission to modify or distribute the Library or its derivative works. These actions are prohibited by law if you do not accept this License. Therefore, by modifying or distributing the Library (or any work based on the Library), you indicate your acceptance of this License to do so, and all its terms and conditions for copying, distributing or modifying the Library or works based on it. 10. Each time you redistribute the Library (or any work based on the Library), the recipient automatically receives a license from the original licensor to copy, distribute, link with or modify the Library subject to these terms and conditions. You may not impose any further restrictions on the recipients' exercise of the rights granted herein. You are not responsible for enforcing compliance by third parties to this License. 11. If, as a consequence of a court judgment or allegation of patent infringement or for any other reason (not limited to patent issues), 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 distribute so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not distribute the Library at all. For example, if a patent license would not permit royalty-free redistribution of the Library by all those who receive copies directly or indirectly through you, then the only way you could satisfy both it and this License would be to refrain entirely from distribution of the Library. If any portion of this section is held invalid or unenforceable under any particular circumstance, the balance of the section is intended to apply, and the section as a whole is intended to apply in other circumstances. It is not the purpose of this section to induce you to infringe any patents or other property right claims or to contest validity of any such claims; this section has the sole purpose of protecting the integrity of the free software distribution system which is implemented by public license practices. Many people have made generous contributions to the wide range of software distributed through that system in reliance on consistent application of that system; it is up to the author/donor to decide if he or she is willing to distribute software through any other system and a licensee cannot impose that choice. This section is intended to make thoroughly clear what is believed to be a consequence of the rest of this License. 12. If the distribution and/or use of the Library is restricted in certain countries either by patents or by copyrighted interfaces, the original copyright holder who places the Library under this License may add an explicit geographical distribution limitation excluding those countries, so that distribution is permitted only in or among countries not thus excluded. In such case, this License incorporates the limitation as if written in the body of this License. 13. The Free Software Foundation may publish revised and/or new versions of the Library 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 Library specifies a version number of this License which applies to it and "any later version", you have the option of following the terms and conditions either of that version or of any later version published by the Free Software Foundation. If the Library does not specify a license version number, you may choose any version ever published by the Free Software Foundation. 14. If you wish to incorporate parts of the Library into other free programs whose distribution conditions are incompatible with these, write to the author to ask for permission. For software which is copyrighted by the Free Software Foundation, write to the Free Software Foundation; we sometimes make exceptions for this. Our decision will be guided by the two goals of preserving the free status of all derivatives of our free software and of promoting the sharing and reuse of software generally. NO WARRANTY 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE LIBRARY "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 LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR REDISTRIBUTE THE LIBRARY 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 LIBRARY (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 LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. END OF TERMS AND CONDITIONS How to Apply These Terms to Your New Libraries If you develop a new library, and you want it to be of the greatest possible use to the public, we recommend making it free software that everyone can redistribute and change. You can do so by permitting redistribution under these terms (or, alternatively, under the terms of the ordinary General Public License). To apply these terms, attach the following notices to the library. It is safest to attach them to the start of each source file to most effectively convey 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 library is free software; you can redistribute it and/or modify it under the terms of the GNU Library General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This library 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 Library General Public License for more details. You should have received a copy of the GNU Library General Public License along with this library; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307 USA. Also add information on how to contact you by electronic and paper mail. You should also get your employer (if you work as a programmer) or your school, if any, to sign a "copyright disclaimer" for the library, if necessary. Here is a sample; alter the names: Yoyodyne, Inc., hereby disclaims all copyright interest in the library `Frob' (a library for tweaking knobs) written by James Random Hacker. , 1 April 1990 Ty Coon, President of Vice That's all there is to it! bar-1.11.1.orig/Makefile.in0000644000175000017500000010570611541674220015554 0ustar georgeskgeorgesk# Makefile.in generated by automake 1.11 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, # 2003, 2004, 2005, 2006, 2007, 2008, 2009 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@ # # To override any of the following variables, you can set the veriable in your # environment before calling make. Be sure that make will honor environmental # overrides, usually by passing the -e flag to make or by setting MAKEFLAGS in # your environment. # # Ex: # # $ ./configure # $ CFLAGS="-g -Wall" make -e # $ make install # # CFLAGS = # CFLAGS = -O2 # CFLAGS = -g -Wall # LDFLAGS = -s # LDFLAGS = ############################################################################## # # A list of sourceforge compile-farm hosts # # Last update: Thu Mar 2 12:13:07 EST 2006 # VPATH = @srcdir@ 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@ target_triplet = @target@ bin_PROGRAMS = bar$(EXEEXT) noinst_PROGRAMS = test-types$(EXEEXT) test-001-pre$(EXEEXT) \ test-001-post$(EXEEXT) TESTS = test-types$(EXEEXT) test-001 test-002 DIST_COMMON = $(am__configure_deps) $(noinst_HEADERS) \ $(srcdir)/Makefile.am $(srcdir)/Makefile.in $(srcdir)/bar.1.in \ $(srcdir)/config.h.in $(srcdir)/doxygen.conf.in \ $(srcdir)/sourceforge.mk $(top_srcdir)/configure AUTHORS \ COPYING INSTALL TODO compile config.guess config.sub depcomp \ install-sh missing mkinstalldirs subdir = . ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/configure.in am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ configure.lineno config.status.lineno mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = config.h CONFIG_CLEAN_FILES = bar.1 doxygen.conf CONFIG_CLEAN_VPATH_FILES = am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man1dir)" PROGRAMS = $(bin_PROGRAMS) $(noinst_PROGRAMS) am_bar_OBJECTS = error.$(OBJEXT) fd.$(OBJEXT) io.$(OBJEXT) \ display.$(OBJEXT) args.$(OBJEXT) bar.$(OBJEXT) bar_OBJECTS = $(am_bar_OBJECTS) bar_LDADD = $(LDADD) am_test_001_post_OBJECTS = test-001-post.$(OBJEXT) test_001_post_OBJECTS = $(am_test_001_post_OBJECTS) test_001_post_LDADD = $(LDADD) am_test_001_pre_OBJECTS = test-001-pre.$(OBJEXT) test_001_pre_OBJECTS = $(am_test_001_pre_OBJECTS) test_001_pre_LDADD = $(LDADD) am_test_types_OBJECTS = test-types.$(OBJEXT) test_types_OBJECTS = $(am_test_types_OBJECTS) test_types_LDADD = $(LDADD) DEFAULT_INCLUDES = -I.@am__isrc@ depcomp = $(SHELL) $(top_srcdir)/depcomp am__depfiles_maybe = depfiles am__mv = mv -f COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) CCLD = $(CC) LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ SOURCES = $(bar_SOURCES) $(test_001_post_SOURCES) \ $(test_001_pre_SOURCES) $(test_types_SOURCES) DIST_SOURCES = $(bar_SOURCES) $(test_001_post_SOURCES) \ $(test_001_pre_SOURCES) $(test_types_SOURCES) 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' man1dir = $(mandir)/man1 NROFF = nroff MANS = $(man_MANS) HEADERS = $(noinst_HEADERS) ETAGS = etags CTAGS = ctags am__tty_colors = \ red=; grn=; lgn=; blu=; std= DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) distdir = $(PACKAGE)-$(VERSION) top_distdir = $(distdir) am__remove_distdir = \ { test ! -d "$(distdir)" \ || { find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \ && rm -fr "$(distdir)"; }; } DIST_ARCHIVES = $(distdir).tar.gz GZIP_ENV = --best distuninstallcheck_listfiles = find . -type f -print distcleancheck_listfiles = find . -type f -print ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AM_CFLAGS = @AM_CFLAGS@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFAULT_BUFFER_SIZE = @DEFAULT_BUFFER_SIZE@ DEFAULT_DISPLAY_TWIDDLE = @DEFAULT_DISPLAY_TWIDDLE@ DEFAULT_PAGE_SIZE = @DEFAULT_PAGE_SIZE@ DEFAULT_SH_MINUS_ONE = @DEFAULT_SH_MINUS_ONE@ DEFAULT_SW_MINUS_ONE = @DEFAULT_SW_MINUS_ONE@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ GREP = @GREP@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ MAX_SAFE_MULTIPLIER = @MAX_SAFE_MULTIPLIER@ MKDIR_P = @MKDIR_P@ OBJEXT = @OBJEXT@ 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@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ STRIP = @STRIP@ VERSION = @VERSION@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ 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@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target = @target@ target_alias = @target_alias@ target_cpu = @target_cpu@ target_os = @target_os@ target_vendor = @target_vendor@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ noinst_HEADERS = headers.h types.h error.h fd.h io.h display.h args.h nodist_TESTS = BUILT_SOURCES = CLEANFILES = *~ test-file-002.1.bin test-file-002.2.bin \ test-file-003.incomplete.bin test-file-003.1.bin \ test-file-003.2.bin test-pipe-003.1 test-pipe-003.2 \ test-pipe-003.3 test-file-004.incomplete.bin test-file-004.bin \ test-file-004.1.bin test-file-004.2.bin DISTCLEANFILES = ./deps/*.P ./log.test-* # TESTS += test-003 # TESTS += test-004 # EXTRA_DIST += PORTING EXTRA_DIST = test-001 test-002 test-003 test-004 itest itest2 \ $(man_MANS) autogen debian/changelog debian/control \ debian/copyright debian/dirs debian/install debian/rules \ sourceforge.mk TROUBLESHOOTING troubleshooter infofile man_MANS = bar.1 test_types_SOURCES = \ test-types.c \ # test_001_pre_SOURCES = \ test-001-pre.c \ # test_001_post_SOURCES = \ test-001-post.c \ # bar_SOURCES = \ error.c \ fd.c \ io.c \ display.c \ args.c \ bar.c \ # ########################## # # 32-bit x86 Architecture: # ########################## # * x86-linux2: Fedora Linux FC2 running Linux 2.6 kernel # * x86-openbsd1: OpenBSD 3.4 # * x86-solaris1: Sun Solaris 9 # * x86-linux1: Debian GNU/Linux 3.0 running Linux 2.4 kernel # * x86-freebsd1: FreeBSD 4.8 # * x86-netbsd1: NetBSD 1.6.1 #################################### # # AMD 64-bit (Opteron) Architecture: # #################################### # * amd64-linux1: Fedora Core release 3 running Linux 2.6 kernel # * amd64-linux2: Fedora Core release 3 running Linux 2.6 kernel ################################ # # DEC Alpha (ev67) Architecture: # ################################ # * alpha-linux1: Debian GNU/Linux 3.0 running Linux 2.2 kernel ####################### # # PowerPC Architecture: # ####################### # * ppc-osx1: Apple Mac OS X 10.1 Server with Fink running on an Apple Mac G4 # * ppc-osx2: Apple Mac OS X 10.2 Server with Fink running on an Apple Mac G4 ##################################### # # Sparc (UltraSPARC-II) Architecture: # ##################################### # * sparc-solaris1, sparc-solaris2: Sun Solaris 9, running on two Sun Enterprise 220R systems ########################## # # IBM Power5 Architecture: # ########################## # * openpower-linux1: SuSE Enterprise Linux 9, running on an IBM OpenPower 720 (e-Series) host. SOURCEFORGE_COMPILE_FARM_HOSTS = x86-linux2 x86-openbsd1 x86-solaris1 \ x86-linux1 x86-freebsd1 x86-netbsd1 amd64-linux1 amd64-linux2 \ alpha-linux1 ppc-osx1 ppc-osx2 sparc-solaris1 openpower-linux1 # #------------------------------------------------------------------------------ # FILE_DIR = ../dist WEB_DIR = ../www ARCH := $(shell uname -m) all: $(BUILT_SOURCES) config.h $(MAKE) $(AM_MAKEFLAGS) all-am .SUFFIXES: .SUFFIXES: .c .o .obj am--refresh: @: $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(srcdir)/sourceforge.mk $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ echo ' cd $(srcdir) && $(AUTOMAKE) --foreign'; \ $(am__cd) $(srcdir) && $(AUTOMAKE) --foreign \ && exit 0; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign Makefile .PRECIOUS: 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__depfiles_maybe)'; \ cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) $(SHELL) ./config.status --recheck $(top_srcdir)/configure: $(am__configure_deps) $(am__cd) $(srcdir) && $(AUTOCONF) $(ACLOCAL_M4): $(am__aclocal_m4_deps) $(am__cd) $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS) $(am__aclocal_m4_deps): config.h: stamp-h1 @if test ! -f $@; then \ rm -f stamp-h1; \ $(MAKE) $(AM_MAKEFLAGS) stamp-h1; \ else :; fi 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: $(am__configure_deps) ($(am__cd) $(top_srcdir) && $(AUTOHEADER)) rm -f stamp-h1 touch $@ distclean-hdr: -rm -f config.h stamp-h1 bar.1: $(top_builddir)/config.status $(srcdir)/bar.1.in cd $(top_builddir) && $(SHELL) ./config.status $@ doxygen.conf: $(top_builddir)/config.status $(srcdir)/doxygen.conf.in cd $(top_builddir) && $(SHELL) ./config.status $@ install-binPROGRAMS: $(bin_PROGRAMS) @$(NORMAL_INSTALL) test -z "$(bindir)" || $(MKDIR_P) "$(DESTDIR)$(bindir)" @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ for p in $$list; do echo "$$p $$p"; done | \ sed 's/$(EXEEXT)$$//' | \ while read p p1; do if test -f $$p; \ 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) $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(bindir)$$dir'"; \ $(INSTALL_PROGRAM_ENV) $(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: -test -z "$(bin_PROGRAMS)" || rm -f $(bin_PROGRAMS) clean-noinstPROGRAMS: -test -z "$(noinst_PROGRAMS)" || rm -f $(noinst_PROGRAMS) bar$(EXEEXT): $(bar_OBJECTS) $(bar_DEPENDENCIES) @rm -f bar$(EXEEXT) $(LINK) $(bar_OBJECTS) $(bar_LDADD) $(LIBS) test-001-post$(EXEEXT): $(test_001_post_OBJECTS) $(test_001_post_DEPENDENCIES) @rm -f test-001-post$(EXEEXT) $(LINK) $(test_001_post_OBJECTS) $(test_001_post_LDADD) $(LIBS) test-001-pre$(EXEEXT): $(test_001_pre_OBJECTS) $(test_001_pre_DEPENDENCIES) @rm -f test-001-pre$(EXEEXT) $(LINK) $(test_001_pre_OBJECTS) $(test_001_pre_LDADD) $(LIBS) test-types$(EXEEXT): $(test_types_OBJECTS) $(test_types_DEPENDENCIES) @rm -f test-types$(EXEEXT) $(LINK) $(test_types_OBJECTS) $(test_types_LDADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) distclean-compile: -rm -f *.tab.c @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/args.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/bar.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/display.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/error.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fd.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/io.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test-001-post.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test-001-pre.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test-types.Po@am__quote@ .c.o: @am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(COMPILE) -c $< .c.obj: @am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` @am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'` install-man1: $(man_MANS) @$(NORMAL_INSTALL) test -z "$(man1dir)" || $(MKDIR_P) "$(DESTDIR)$(man1dir)" @list=''; test -n "$(man1dir)" || exit 0; \ { 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'; \ } | 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,.,'`; \ test -z "$$files" || { \ echo " ( cd '$(DESTDIR)$(man1dir)' && rm -f" $$files ")"; \ cd "$(DESTDIR)$(man1dir)" && rm -f $$files; } ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ END { if (nonempty) { for (i in files) print i; }; }'`; \ mkid -fID $$unique tags: TAGS TAGS: $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) set x; \ here=`pwd`; \ list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ END { if (nonempty) { for (i in files) print i; }; }'`; \ 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 CTAGS: $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ END { if (nonempty) { for (i in files) print i; }; }'`; \ 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" distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags check-TESTS: $(TESTS) @failed=0; all=0; xfail=0; xpass=0; skip=0; \ srcdir=$(srcdir); export srcdir; \ list=' $(TESTS) '; \ $(am__tty_colors); \ if test -n "$$list"; then \ for tst in $$list; do \ if test -f ./$$tst; then dir=./; \ elif test -f $$tst; then dir=; \ else dir="$(srcdir)/"; fi; \ if $(TESTS_ENVIRONMENT) $${dir}$$tst; then \ all=`expr $$all + 1`; \ case " $(XFAIL_TESTS) " in \ *[\ \ ]$$tst[\ \ ]*) \ xpass=`expr $$xpass + 1`; \ failed=`expr $$failed + 1`; \ col=$$red; res=XPASS; \ ;; \ *) \ col=$$grn; res=PASS; \ ;; \ esac; \ elif test $$? -ne 77; then \ all=`expr $$all + 1`; \ case " $(XFAIL_TESTS) " in \ *[\ \ ]$$tst[\ \ ]*) \ xfail=`expr $$xfail + 1`; \ col=$$lgn; res=XFAIL; \ ;; \ *) \ failed=`expr $$failed + 1`; \ col=$$red; res=FAIL; \ ;; \ esac; \ else \ skip=`expr $$skip + 1`; \ col=$$blu; res=SKIP; \ fi; \ echo "$${col}$$res$${std}: $$tst"; \ done; \ if test "$$all" -eq 1; then \ tests="test"; \ All=""; \ else \ tests="tests"; \ All="All "; \ fi; \ if test "$$failed" -eq 0; then \ if test "$$xfail" -eq 0; then \ banner="$$All$$all $$tests passed"; \ else \ if test "$$xfail" -eq 1; then failures=failure; else failures=failures; fi; \ banner="$$All$$all $$tests behaved as expected ($$xfail expected $$failures)"; \ fi; \ else \ if test "$$xpass" -eq 0; then \ banner="$$failed of $$all $$tests failed"; \ else \ if test "$$xpass" -eq 1; then passes=pass; else passes=passes; fi; \ banner="$$failed of $$all $$tests did not behave as expected ($$xpass unexpected $$passes)"; \ fi; \ fi; \ dashes="$$banner"; \ skipped=""; \ if test "$$skip" -ne 0; then \ if test "$$skip" -eq 1; then \ skipped="($$skip test was not run)"; \ else \ skipped="($$skip tests were not run)"; \ fi; \ test `echo "$$skipped" | wc -c` -le `echo "$$banner" | wc -c` || \ dashes="$$skipped"; \ fi; \ report=""; \ if test "$$failed" -ne 0 && test -n "$(PACKAGE_BUGREPORT)"; then \ report="Please report to $(PACKAGE_BUGREPORT)"; \ test `echo "$$report" | wc -c` -le `echo "$$banner" | wc -c` || \ dashes="$$report"; \ fi; \ dashes=`echo "$$dashes" | sed s/./=/g`; \ if test "$$failed" -eq 0; then \ echo "$$grn$$dashes"; \ else \ echo "$$red$$dashes"; \ fi; \ echo "$$banner"; \ test -z "$$skipped" || echo "$$skipped"; \ test -z "$$report" || echo "$$report"; \ echo "$$dashes$$std"; \ test "$$failed" -eq 0; \ else :; fi distdir: $(DISTFILES) @list='$(MANS)'; if test -n "$$list"; then \ list=`for p in $$list; do \ if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ if test -f "$$d$$p"; then echo "$$d$$p"; else :; fi; done`; \ if test -n "$$list" && \ grep 'ab help2man is required to generate this page' $$list >/dev/null; then \ echo "error: found man pages containing the \`missing help2man' replacement text:" >&2; \ grep -l 'ab help2man is required to generate this page' $$list | sed 's/^/ /' >&2; \ echo " to fix them, install help2man, remove and regenerate the man pages;" >&2; \ echo " typically \`make maintainer-clean' will remove them" >&2; \ exit 1; \ else :; fi; \ else :; fi $(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 -test -n "$(am__skip_mode_fix)" \ || find "$(distdir)" -type d ! -perm -777 -exec chmod a+rwx {} \; -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) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz $(am__remove_distdir) dist-bzip2: distdir tardir=$(distdir) && $(am__tar) | bzip2 -9 -c >$(distdir).tar.bz2 $(am__remove_distdir) dist-lzma: distdir tardir=$(distdir) && $(am__tar) | lzma -9 -c >$(distdir).tar.lzma $(am__remove_distdir) dist-xz: distdir tardir=$(distdir) && $(am__tar) | xz -c >$(distdir).tar.xz $(am__remove_distdir) dist-tarZ: distdir tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z $(am__remove_distdir) dist-shar: distdir shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz $(am__remove_distdir) dist-zip: distdir -rm -f $(distdir).zip zip -rq $(distdir).zip $(distdir) $(am__remove_distdir) dist dist-all: distdir tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz $(am__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*) \ GZIP=$(GZIP_ENV) gunzip -c $(distdir).tar.gz | $(am__untar) ;;\ *.tar.bz2*) \ bunzip2 -c $(distdir).tar.bz2 | $(am__untar) ;;\ *.tar.lzma*) \ unlzma -c $(distdir).tar.lzma | $(am__untar) ;;\ *.tar.xz*) \ xz -dc $(distdir).tar.xz | $(am__untar) ;;\ *.tar.Z*) \ uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ *.shar.gz*) \ GZIP=$(GZIP_ENV) gunzip -c $(distdir).shar.gz | unshar ;;\ *.zip*) \ unzip $(distdir).zip ;;\ esac chmod -R a-w $(distdir); chmod a+w $(distdir) mkdir $(distdir)/_build mkdir $(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 \ && ../configure --srcdir=.. --prefix="$$dc_install_base" \ $(DISTCHECK_CONFIGURE_FLAGS) \ && $(MAKE) $(AM_MAKEFLAGS) \ && $(MAKE) $(AM_MAKEFLAGS) dvi \ && $(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__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: @$(am__cd) '$(distuninstallcheck_dir)' \ && test `$(distuninstallcheck_listfiles) | wc -l` -le 1 \ || { 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 $(MAKE) $(AM_MAKEFLAGS) check-TESTS check: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) check-am all-am: Makefile $(PROGRAMS) $(MANS) $(HEADERS) config.h installdirs: for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man1dir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) 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: $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ `test -z '$(STRIP)' || \ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install mostlyclean-generic: 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) -test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) clean: clean-am clean-am: clean-binPROGRAMS clean-generic clean-noinstPROGRAMS \ mostlyclean-am distclean: distclean-am -rm -f $(am__CONFIG_DISTCLEAN_FILES) -rm -rf ./$(DEPDIR) -rm -f Makefile distclean-am: clean-am distclean-compile distclean-generic \ distclean-hdr distclean-tags 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-binPROGRAMS 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 $(am__CONFIG_DISTCLEAN_FILES) -rm -rf $(top_srcdir)/autom4te.cache -rm -rf ./$(DEPDIR) -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-compile mostlyclean-generic pdf: pdf-am pdf-am: ps: ps-am ps-am: uninstall-am: uninstall-binPROGRAMS uninstall-man uninstall-man: uninstall-man1 .MAKE: all check check-am install install-am install-strip .PHONY: CTAGS GTAGS all all-am am--refresh check check-TESTS check-am \ clean clean-binPROGRAMS clean-generic clean-noinstPROGRAMS \ ctags dist dist-all dist-bzip2 dist-gzip dist-lzma dist-shar \ dist-tarZ dist-xz dist-zip distcheck distclean \ distclean-compile distclean-generic distclean-hdr \ distclean-tags distcleancheck distdir distuninstallcheck dvi \ dvi-am html html-am info info-am install 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-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-compile mostlyclean-generic pdf pdf-am \ ps ps-am tags uninstall uninstall-am uninstall-binPROGRAMS \ uninstall-man uninstall-man1 dch: cd ./debian && dch --check-dirname-level 0 dchi: cd ./debian && dch -i --check-dirname-level 0 update: update-dist update-www update-dist: dist [ -d $(FILE_DIR) ] || exit 1 [ -f $(distdir).tar.gz ] || exit 1 chmod 0755 $(FILE_DIR) -rm -fr $(FILE_DIR)/$(PACKAGE)* -rm -fr $(FILE_DIR)/$(distdir) gzip -dc $(distdir).tar.gz | (cd $(FILE_DIR) && tar -xvf -) [ -x /usr/bin/dpkg-buildpackage ] || exit 1 [ -x /usr/bin/fakeroot ] || exit 1 cd $(FILE_DIR)/$(distdir) && dpkg-buildpackage -us -uc -rfakeroot rm -fr $(FILE_DIR)/$(distdir) [ -x /usr/bin/alien ] || exit 1 cd $(FILE_DIR) && fakeroot alien --to-rpm $(PACKAGE)_$(VERSION)_*.deb [ -x /usr/bin/alien ] || exit 1 cd $(FILE_DIR) && fakeroot alien --to-tgz $(PACKAGE)_$(VERSION)_*.deb cd $(FILE_DIR) && mv $(PACKAGE)-$(VERSION).tgz $(PACKAGE)-$(VERSION)_$(ARCH).tgz -rm ./ChangeLog cp debian/changelog $(FILE_DIR)/$(PACKAGE)-$(VERSION)-ChangeLog [ ! -f README ] || cp README $(FILE_DIR)/$(PACKAGE)-$(VERSION)-README [ -x /usr/bin/groff ] || exit 1 for file in $(man_MANS); do \ cat $${file} \ | groff -man -Tascii \ | sed \ -e 's,_,,g' \ -e 's,.,,g' \ > $(FILE_DIR)/$(PACKAGE)-$(VERSION)-man.txt \ ; \ done update-www: [ -d $(WEB_DIR) ] || exit 1 -rm -fr $(WEB_DIR)/doxygen/$(VERSION) cat doxygen.conf.in \ | sed "s,{PACKAGE},$(PACKAGE),g" \ | sed "s,{VERSION},$(VERSION),g" \ | sed "s,{DOC_DIR},$(WEB_DIR)/doxygen/$(VERSION),g" \ > doxygen.conf doxygen ./doxygen.conf cd $(WEB_DIR) && $(MAKE) ############################################################################### # # Automated Sourceforge Compilefarm Testing # ############################################################################### # include sourceforge.mk # $(PACKAGE)-$(VERSION).tar.gz: $(DIST_COMMON) $(SOURCES) # $(MAKE) dist # # update-sourceforge-compilefarm: .update-sourceforge-compilefarm # .update-sourceforge-compilefarm: $(PACKAGE)-$(VERSION).tar.gz # tar -cvf - ./$(PACKAGE)-$(VERSION).tar.gz \ # | ssh -l michaelpeek shell.cf.sourceforge.net \ # "tar -xvf -" # touch $@ # # test-sourceforge-compilefarm-generic: .test-sourceforge-compilefarm-$(HOST) # .test-sourceforge-compilefarm-$(HOST): .update-sourceforge-compilefarm # -ssh -l michaelpeek shell.cf.sourceforge.net \ # "test-project \"$(HOST)\" \"$(PACKAGE)\" \"$(VERSION)\"" 2>&1 \ # | tee log.sourceforge.$(HOST).txt \ # | sed 's,^,[$(HOST)]: ,g' # # test-sourceforge-compilefarm: .update-sourceforge-compilefarm # for host in $(SOURCEFORGE_COMPILE_FARM_HOSTS); do \ # $(MAKE) test-sourceforge-compilefarm-generic HOST="$${host}" ; \ # done ; \ # # # # test-sourceforge: .update-sourceforge-compilefarm # -rm -f log.sourceforge.* # $(MAKE) test-sourceforge-compilefarm 2>&1 | tee log.sourceforge.txt ############################################################################### beep: @printf '' @sleep 1 @printf '' @sleep 1 @printf '' extract-deb: bin-pkgs for this_file in $(shell ls -1 $(PKG_DIR)/); do \ this_name=$$(dpkg-deb --field "$${this_file}" Package) ; \ this_vers=$$(dpkg-deb --field "$${this_file}" Version) ; \ this_arch=$$(dpkg-deb --field "$${this_file}" Architecture) ; \ this_dir="$(PKG_DIR)/$${this_name}_$${this_vers}_$${this_arch}" ; \ rm -fr "$${this_dir}" || true ; \ mkdir -p "$${this_dir}" || exit 1 ; \ dpkg-deb -x "$${this_file}" "$${this_dir}" || exit 1 ; \ dpkg-deb -e "$${this_file}" "$${this_dir}/DEBIAN" || exit 1 ; \ done ; \ # # 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: bar-1.11.1.orig/itest20000754000175000017500000000030110712352404014623 0ustar georgeskgeorgesk#!/bin/sh set -x dd if=/dev/zero bs=1024 count=1024 \ | ./bar \ -s 1024k \ --throttle 50k \ -of /dev/null \ --info-file infofile \ # # vim:ts=2:shiftwidth=2:filetype=sh:syntax=sh: bar-1.11.1.orig/depcomp0000754000175000017500000002752510510504276015063 0ustar georgeskgeorgesk#! /bin/sh # depcomp - compile a program generating dependencies as side-effects # Copyright 1999, 2000 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, write to the Free Software # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA # 02111-1307, USA. # 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 . 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 # `libtool' can also be set to `yes' or `no'. depfile=${depfile-`echo "$object" | sed 's,\([^/]*\)$,.deps/\1,;s/\.\([^.]*\)$/.P\1/'`} tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`} rm -f "$tmpdepfile" # Some modes work just like other modes, but use different flags. We # parameterize here, but still list the modes in the big case below, # to make depend.m4 easier to write. Note that we *cannot* use a case # here, because this file can only contain one case statement. 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 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. "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi mv "$tmpdepfile" "$depfile" ;; gcc) ## There are various ways to get dependency output from gcc. Here's ## why we pick this rather obscure method: ## - Don't want to use -MD because we'd like the dependencies to end ## up in a subdir. Having to rename by hand is ugly. ## (We might end up doing this anyway to support other compilers.) ## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like ## -MM, not -M (despite what the docs say). ## - Using -M directly means running the compiler twice (even worse ## than renaming). if test -z "$gccflag"; then gccflag=-MD, fi "$@" -Wp,"$gccflag$tmpdepfile" stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi rm -f "$depfile" echo "$object : \\" > "$depfile" alpha=ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz ## The second -e expression handles DOS-style file names with drive letters. sed -e 's/^[^:]*: / /' \ -e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile" ## This next piece of magic avoids the `deleted header file' problem. ## The problem is that when a header file which appears in a .P file ## is deleted, the dependency causes make to die (because there is ## typically no way to rebuild the header). We avoid this by adding ## dummy dependencies for each header file. Too bad gcc doesn't do ## this for us directly. tr ' ' ' ' < "$tmpdepfile" | ## Some versions of gcc put a space before the `:'. On the theory ## that the space means something, we add a space to the output as ## well. ## Some versions of the HPUX 10.20 sed can't process this invocation ## correctly. Breaking it into two sed invocations is a workaround. sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; 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 -eq 0; then : else 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 ' ' ' ' < "$tmpdepfile" \ | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' | \ tr ' ' ' ' >> $depfile echo >> $depfile # The second pass generates a dummy entry for each header file. tr ' ' ' ' < "$tmpdepfile" \ | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \ >> $depfile else # The sourcefile does not contain any dependencies, so just # store a dummy comment line, to avoid errors with the Makefile # "include basename.Plo" scheme. echo "#dummy" > "$depfile" fi rm -f "$tmpdepfile" ;; aix) # The C for AIX Compiler uses -M and outputs the dependencies # in a .u file. 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. stripped=`echo "$object" | sed -e 's,^.*/,,' -e 's/\(.*\)\..*$/\1/'` tmpdepfile="$stripped.u" outname="$stripped.o" if test "$libtool" = yes; then "$@" -Wc,-M else "$@" -M fi stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi if test -f "$tmpdepfile"; then # Each line is of the form `foo.o: dependent.h'. # Do two passes, one to just change these to # `$object: dependent.h' and one to simply `dependent.h:'. sed -e "s,^$outname:,$object :," < "$tmpdepfile" > "$depfile" sed -e "s,^$outname: \(.*\)$,\1:," < "$tmpdepfile" >> "$depfile" else # The sourcefile does not contain any dependencies, so just # store a dummy comment line, to avoid errors with the Makefile # "include basename.Plo" scheme. echo "#dummy" > "$depfile" fi rm -f "$tmpdepfile" ;; tru64) # The Tru64 AIX 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. tmpdepfile1="$object.d" tmpdepfile2=`echo "$object" | sed -e 's/.o$/.d/'` if test "$libtool" = yes; then "$@" -Wc,-MD else "$@" -MD fi stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile1" "$tmpdepfile2" exit $stat fi if test -f "$tmpdepfile1"; then tmpdepfile="$tmpdepfile1" else tmpdepfile="$tmpdepfile2" fi if test -f "$tmpdepfile"; then sed -e "s,^.*\.[a-z]*:,$object:," < "$tmpdepfile" > "$depfile" # That's a space and a tab in the []. sed -e 's,^.*\.[a-z]*:[ ]*,,' -e 's,$,:,' < "$tmpdepfile" >> "$depfile" else echo "#dummy" > "$depfile" fi rm -f "$tmpdepfile" ;; #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 proprocessed file to stdout, regardless of -o, # because we must use -o when running libtool. test -z "$dashmflag" && dashmflag=-M ( IFS=" " case " $* " in *" --mode=compile "*) # this is libtool, let us make it quiet for arg do # cycle over the arguments case "$arg" in "--mode=compile") # insert --quiet before "--mode=compile" set fnord "$@" --quiet shift # fnord ;; esac set fnord "$@" "$arg" shift # fnord shift # "$arg" done ;; esac "$@" $dashmflag | sed 's:^[^:]*\:[ ]*:'"$object"'\: :' > "$tmpdepfile" ) & proc=$! "$@" stat=$? wait "$proc" if test "$stat" != 0; then exit $stat; fi rm -f "$depfile" cat < "$tmpdepfile" > "$depfile" tr ' ' ' ' < "$tmpdepfile" | \ ## Some versions of the HPUX 10.20 sed can't process this invocation ## correctly. Breaking it into two sed invocations is a workaround. sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; 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) # X makedepend ( shift cleared=no for arg in "$@"; do case $cleared in no) set ""; shift cleared=yes esac case "$arg" in -D*|-I*) set fnord "$@" "$arg"; shift;; -*) ;; *) set fnord "$@" "$arg"; shift;; esac done obj_suffix="`echo $object | sed 's/^.*\././'`" touch "$tmpdepfile" ${MAKEDEPEND-makedepend} 2>/dev/null -o"$obj_suffix" -f"$tmpdepfile" "$@" ) & proc=$! "$@" stat=$? wait "$proc" if test "$stat" != 0; then exit $stat; fi rm -f "$depfile" cat < "$tmpdepfile" > "$depfile" tail +3 "$tmpdepfile" | tr ' ' ' ' | \ ## Some versions of the HPUX 10.20 sed can't process this invocation ## correctly. Breaking it into two sed invocations is a workaround. sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" "$tmpdepfile".bak ;; cpp) # Important note: in order to support this mode, a compiler *must* # always write the proprocessed file to stdout, regardless of -o, # because we must use -o when running libtool. ( IFS=" " case " $* " in *" --mode=compile "*) for arg do # cycle over the arguments case $arg in "--mode=compile") # insert --quiet before "--mode=compile" set fnord "$@" --quiet shift # fnord ;; esac set fnord "$@" "$arg" shift # fnord shift # "$arg" done ;; esac "$@" -E | sed -n '/^# [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' | sed '$ s: \\$::' > "$tmpdepfile" ) & proc=$! "$@" stat=$? wait "$proc" if test "$stat" != 0; then exit $stat; fi 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 proprocessed file to stdout, regardless of -o, # because we must use -o when running libtool. ( IFS=" " case " $* " in *" --mode=compile "*) for arg do # cycle over the arguments case $arg in "--mode=compile") # insert --quiet before "--mode=compile" set fnord "$@" --quiet shift # fnord ;; esac set fnord "$@" "$arg" shift # fnord shift # "$arg" done ;; esac "$@" -E | sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::echo "`cygpath -u \\"\1\\"`":p' | sort | uniq > "$tmpdepfile" ) & proc=$! "$@" stat=$? wait "$proc" if test "$stat" != 0; then exit $stat; fi rm -f "$depfile" echo "$object : \\" > "$depfile" . "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s:: \1 \\:p' >> "$depfile" echo " " >> "$depfile" . "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s::\1\::p' >> "$depfile" rm -f "$tmpdepfile" ;; none) exec "$@" ;; *) echo "Unknown depmode $depmode" 1>&2 exit 1 ;; esac exit 0 bar-1.11.1.orig/fd.c0000644000175000017500000000223310510504276014231 0ustar georgeskgeorgesk#include "config.h" #include "headers.h" #include "types.h" #include "error.h" #include "fd.h" int set_fl(int fd, int flags) { int val; if ((val = fcntl(fd, F_GETFL, 0)) < 0) { print_error(stderr, "fcntl() failed"); return(1); } val |= flags; if (fcntl(fd, F_SETFL, val) < 0) { print_error(stderr, "fcntl() failed"); return(1); } return(0); } int clr_fl(int fd, int flags) { int val; if ((val = fcntl(fd, F_GETFL, 0)) < 0) { print_error(stderr, "fcntl() failed"); return(1); } val &= ~flags; if (fcntl(fd, F_SETFL, val) < 0) { print_error(stderr, "fcntl() failed"); return(1); } return(0); } int fdBegin(int fd) { return(set_fl(fd, O_NONBLOCK)); } int fdEnd(int fd) { return(clr_fl(fd, O_NONBLOCK)); } int fdIsFile(int fd) { struct stat st; if (fstat(fd, &st) != 0) { print_error(stderr, "fstat() failed"); return(0); } if (S_ISREG(st.st_mode)) return(1); return(0); } int fdFileSize(int fd, uint64 *size) { struct stat st; if (size == 0) { print_error(stderr, "size == NULL"); return(1); } if (fstat(fd, &st) != 0) { print_error(stderr, "fstat() failed"); return(1); } *size = (uint64)st.st_size; return(0); } bar-1.11.1.orig/INSTALL0000644000175000017500000000320510510504276014525 0ustar georgeskgeorgeskPrerequisites ============= An ansi C compiler. Simple install procedure ======================== % gzip -cd bar-1.03.tar.gz | tar xvf - # unpack the sources % cd bar-1.03 # change to the toplevel directory % ./configure # run the `configure' script % make # build bar [ Become root if necessary ] % make install # install bar The Nitty-Gritty ================ The 'configure' script can be given a number of options to enable and disable various features. For a complete list, type: ./configure --help A few of the more important ones: * --prefix=PREFIX install architecture-independent files in PREFIX [ Defaults to /usr/local ] * --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX [ Defaults to the value given to --prefix ] Options can be given to the compiler and linker by setting environment variables before running configure. A few of the more important ones: CC : The C compiler to use CPPFLAGS : Flags for the C preprocesser such as -I and -D CFLAGS : C compiler flags The most important use of this is to set the optimization/debugging flags. For instance, to compile with no debugging information at all, run configure as: CFLAGS=-O2 ./configure # Bourne compatible shells (sh/bash/zsh) or, setenv CFLAGS -O2 ; ./configure # csh and variants Installation directories ======================== The location of the installed files is determined by the --prefix and --exec-prefix options given to configure. bar-1.11.1.orig/bar.1.in0000644000175000017500000010335711435544355014751 0ustar georgeskgeorgesk.TH BAR 1 "4 November 2003" .SH NAME bar \- show information about a data transfer .SH SYNOPSIS .RS 0 .TP 4 .B bar [ .I I/O-options ] [ .I display-options ] [ .I color-options ] .br [ .I input-file ] [ .I output-file ] .br [ .B -h | .B --help ] [ .B -v | .B --version ] .RE .SH DESCRIPTION .PP Bar is a simple tool to process a stream of data and print a display for the user on stderr showing (a) the amount of data passed, (b) the throughput of the data transfer, and, if the total size of the data stream is known, (c) estimated time remaining, percent complete, and a progress bar. .PP Bar was originally written for the purpose of estimating the amount of time needed to transfer large amounts (many, many gigabytes) of data across a network. (Usually in an SSH/tar pipe.) .SH I/O COMMAND LINE OPTIONS .B -if .I input-file .br .B --in-file .I input-file .br .RS 2 .PP Read input from .I input-file. Default: stdin .RE .B -of .I output-file .br .B --out-file .I output-file .br .RS 2 .PP Write output to .I output-file. If the output file is a directory, then bar will attempt to create a file in the output directory with the same name as the input file, and attempt to copy the input file mode as well as it's data. Default: stdout .RE .PP Please notice that if no .B -if, --in-file, -of, or .B --out-file options are specified on the command line, and an unknown command line option is encountered, then bar will assume that the first unknown command line option is a path to an input file, and the second (if found) is a path to an output file. .B -s .I size .br .B --size .I size .br .RS 2 .PP Expect an input stream of .I size bytes. .PP When reading a regular file or a link to a regular file, bar will extract the file size on it's own. However, this flag is useful for reading from a character- or block-special device file, or from a pipe. .I size may be followed by 'k', 'm', 'g', 't', 'p', or 'e' for kilobytes, megabytes, gigabytes, terabytes, petabytes, or exabytes, respectively (see also the -k option below). Alternatively, .I size may also be specified in terms of 'b' for blocks (see the .B -bl option below). See examples below. .RE .B -c .I size .br .B --completed .I size .br .RS 2 .PP Instruct bar that .I size bytes of the data stream have already been copied, and that this is a continuation of a previous data stream. Note that use of this option will throw off throughput and ETA calculations at first, but they should settle down as the transfer continues. .B -bs .I buffer-size .br .B --buffer-size .I buffer-size .br .RS 2 .PP Allocate an I/O buffer of .I buffer-size bytes. The same modifiers may apply here ('k', 'm', 'g', 't', 'p', 'e' and 'b') as for the .B -s flag above. Changing the buffer size can improve throughput, depending on your application of bar. For fast I/O operations, say from a ramdisk for instance, it might be worth your while to experiment with a large buffer (circa 1MB for instance). But for slow I/O operations, like from a tape drive, you could merely be wasting your memory. Default: 52488 (512KB) .RE .B -th .I rate .br .B --throttle .I rate .br .RS 2 .PP Restrict I/O throughput to .I rate bytes per second. The same modifiers apply here ('k', 'm', 'g', 't', 'p', 'e' and 'b') as for the .B -s flag above. .RE .B -i .I seconds .br .B --interval .I seconds .br .RS 2 .PP Update the display every .I seconds seconds. Default: 1 second .RE .B -t .I microseconds .br .B --timeout .I microseconds .br .RS 2 .PP The number of microseconds to wait for a change in I/O state before .I select() times out. Default: 250000 (1/4 second) .RE .B -k 1000|1024 .br .B --kilo 1000|1024 .br .RS 2 .PP Use either 1000 or 1024 as the definition of a kilobyte. Default: 1024 .RE .B -bl .I size .br .B --block-size .I size .br .RS 2 .PP When reading sizes from the command line that are specified in terms of blocks, assume a single block is .I size bytes. .I Size may be followed by 'k', 'm', 'g', 't', 'p', or 'e' for kilobytes, megabytes, gigabytes, terabytes, petabytes, or exabytes, respectively. Block size must be set before specifying any sizes in terms of blocks or the default value will be used instead. Specifying .I size in terms of 'b' for blocks is not allowed for this option. Default: 512 .RE .SH DISPLAY COMMAND LINE OPTIONS .B -sw .I width .br .B --screen-width .I width .br .RS 2 .PP Assume a screen width of .I width characters. Bar will attempt to retrieve the width of the terminal it is running on, and will adjust that width if the terminal is resized. If bar cannot determine the terminal width, then bar will assume a default width of 79 characters. Use the .B --screen-width command line option to override this behavior and specify a fixed width for bar to use. (When this option is used, bar will ignore terminal resized signals and continue to use the value provided by the user.) .RE .B -sw-1 | .B --screen-width-minus-one .br .B -sw-0 | .B --screen-width-minus-zero .RS 2 .PP Instruct bar to use either the entire column width reported by termio, or one less than reported by termio. I.e. If termio reports that you are running bar in a terminal that's 80 characters wide, using the command line option .B --screen-width-minus-one instructs bar to only use 79 characters to print the display. If you're using a terminal or shell that wraps the line whenever bar prints the last character then this should alleviate that problem. Default is to use the full terminal's width. .RE .B -sh .I height .br .B --screen-height .I height .br .RS 2 .PP Assume a screen height of .I height characters. Bar will attempt to retrieve the height of the terminal it is running on, and will adjust that height if the terminal is resized. If bar cannot determine the terminal height, then bar will assume a default height of 23 characters. Use the .B --screen-height command line option to override this behavior and specify a fixed height for bar to use. (When this option is used, bar will ignore terminal resized signals and continue to use the value provided by the user.) .PP Please note that this option is only useful when used in conjunction with the .B --info-file command line option. Otherwise bar has no need to know the screen height in order to perform it's function. .RE .B -sh-1 | .B --screen-height-minus-one .br .B -sh-0 | .B --screen-height-minus-zero .RS 2 .PP Instruct bar to use either the entire row height reported by termio, or one less than reported by termio. I.e. If termio reports that you are running bar in a terminal that's 24 rows characters high, using the command line option .B --screen-height-minus-one instructs bar to only use 23 rows to print the display. If you're using a terminal or shell that wraps the line whenever bar prints the last character then this should alleviate that problem. Default is to use the full terminal's height. .PP Please note that this option is only useful when used in conjunction with the .B --info-file command line option. Otherwise bar has no need to know the screen height in order to perform it's function. .RE .B -ti .I string | .B --title .I string .br .RS 2 Set the title to .IR string . .RE .B -dti | .B -nti .br .B --display-title | .B --no-title .br .RS 2 Turn on/off the title display. Even if on, if no title string is set then no title will be displayed. Default is on. .RE .B -dtw | .B --display-twiddle .br .B -ntw | .B --no-twiddle .br .RS 2 .PP Turn on/off the twiddle in the display. .RE .B -dc | .B --display-count .br .B -nc | .B --no-count .br .RS 2 .PP Turn on/off the data count in the display. Default is on. .RE .B -dcb | .B -ncb .br .B --display-count-bits | .B --no-count-bits .br .RS 2 Display the data count at bits instead of as bytes. Default is off. .PP By default bar will display the data count as bytes using the notation of "B". Using this option, bar will display the throughput as bits using the notation of "b". .RE .B -dth | .B --display-throughput .br .B -nth | .B --no-throughput .br .RS 2 .PP Turn on/off the data throughput in the display. Default is on. .RE .B -dthb | .B -nthb .br .B --display-throughput-bits | .B --no-throughput-bits .br .RS 2 Display throughput as bits/second instead of as bytes/second. Default is off. .PP By default bar will display the throughput as bytes/second using the notation of "B/s". Using this option, bar will display the throughput as bits/second using the notation of "b/s". .RE .B -dt | .B --display-time .br .B -nt | .B --no-time .br .RS 2 .PP Turn on/off the time elapsed or eta in the display. Default is on. .RE .B -de | .B --display-elapsed-only .br .B -ne | .B --no-elapsed-only .RS 2 .PP Force bar to display the elapsed time instead of the eta. Default is off. .RE .B -dp | .B --display-percent .br .B -np | .B --no-percent .br .RS 2 .PP Turn on/off percent complete in the display. Default is on. .RE .B -db | .B --display-bar .br .B -nb | .B --no-bar .br .RS 2 .PP Turn on/off the progress bar in the display. Default is on. .RE .B -ds | .B --display-summary .br .B -ns | .B --no-summary .br .RS 2 .PP Turn on/off the summary information displayed when the operation is complete. Default is on. .RE .B -da | .B --display-all .br .B -dn | .B --display-none .br .RS 2 .PP Turn on/off all displays. -dn is equivalent to -ntw -nc -nth -nt -np -nb. (Using -dn followed by -db would be equivalent to -ntw -nc -nth -nt -np.) -da is equivalent to -dtw -dc -dth -dt -dp -db. .RE .B -inf .I infofile | .B --info-file .I infofile .br .RS 2 .PP Display the information contained in .I infofile while copying data. The file .I infofile is a regular text file containing tidbits of information broken up into sections. Each section is separated by a line containing the string "@@@" by itself, with no other characters on the line, either preceeding or following. .PP When bar begins, it will count the number of sections within the file. Bar will then begin by displaying the first section of information to the display before it draws the status line. Then, periodically, each of the successive sections will be displayed as the progress indicator fills up. .PP The progress of the data transfer is the trigger for each successive display. For instance, if your information file has exactly four sections to it, then the first section will be printed as bar begins, the second section after the data transfer hits 25%, the third at 50%, and the fourth at 75%. .PP If bar is configured to use ANSI control codes, then the screen will be cleared before printing a section from the information file. Otherwise, the contents of the current screen are scolled up and off the screen. .RE .B -dnum | .B --display-numeric .br .RS 2 .PP Do not render the usual display, but instead display an integer representing the percent of the transfer that is complete, one integer per line. This output is suitable for piping to other programs such as .B dialog(1) or .BR zenity(1) . This implies that the total transfer size must be known by bar, either by finding the size of an input file directly or by using the .B --size command line option. .B -dw | .B --display-wait .br .RS 2 Wait for the first byte of data to come through before displaying anything. .RE .SH COLOR COMMAND LINE OPTIONS .PP For the following color-specific command line options, the following keywords are recognized as valid color names: normal, black, red, green, yellow, blue, magenta, cyan, and white .B -dan | .B --display-ansi .br .B -nan | .B --no-ansi .br .RS 2 .PP Turn on/off the use of ansi color codes in the display. .RE .B -spbg .I color | .B --space-background .I color .br .RS 2 .PP Use .I color as the background color for spacing between display objects. Default: normal .RE .B -twfg .I color | .B --twiddle-foreground .I color .br .B -twbg .I color | .B --twiddle-background .I color .br .RS 2 .PP Use .I color as the twiddle color in the display. Default: normal .RE .B -twb | .B --twiddle-bold .br .B -twn | .B --twiddle-normal .br .RS 2 .PP Turn on/off the use of bold font when displaying the twiddle. Default off .RE .B -tifg .I color | .B --title-foreground .I color .br .B -tibg .I color | .B --title-background .I color .br .RS 2 .PP Use .I color as the title color in the display. Default: normal .RE .B -tib | .B --title-bold .br .B -tin | .B --title-normal .br .RS 2 .PP Turn on/off the use of bold font when displaying the title. Default off .RE .B -cfg .I color | .B --count-foreground .I color .br .B -cbg .I color | .B --count-background .I color .br .RS 2 .PP Use .I color as the data count color in the display. Default: normal .RE .B -cb | .B --count-bold .br .B -cn | .B --count-normal .br .RS 2 .PP Turn on/off the use of bold font when displaying the data count. Default off .RE .B -thlfg .I color | .B --throughput-label-foreground .I color .br .B -thlbg .I color | .B --throughput-label-background .I color .br .RS 2 .PP Use .I color as the throughput label color in the display. Default: normal .RE .B -thlb | .B --throughput-label-bold .br .B -thln | .B --throughput-label-normal .br .RS 2 .PP Turn on/off the use of bold font when displaying the throughput label. Default off .RE .B -thfg .I color | .B --throughput-foreground .I color .br .B -thbg .I color | .B --throughput-background .I color .br .RS 2 .PP Use .I color as the throughput color in the display. Default: normal .RE .B -thb | .B --throughput-bold .br .B -thn | .B --throughput-normal .br .RS 2 .PP Turn on/off the use of bold font when displaying the throughput. Default off .RE .B -tlfg .I color | .B --time-label-foreground .I color .br .B -tlbg .I color | .B --time-label-background .I color .br .RS 2 .PP Use .I color as the time label color in the display. Default: normal .RE .B -tlb | .B --time-label-bold .br .B -tln | .B --time-label-normal .br .RS 2 .PP Turn on/off the use of bold font when displaying the time label. Default off .RE .B -tfg .I color | .B --time-foreground .I color .br .B -tbg .I color | .B --time-background .I color .br .RS 2 .PP Use .I color as the time color in the display. Default: normal .RE .B -tb | .B --time-bold .br .B -tn | .B --time-normal .br .RS 2 .PP Turn on/off the use of bold font when displaying the time. Default off .RE .B -pfg .I color | .B --percent-foreground .I color .br .B -pbg .I color | .B --percent-background .I color .br .RS 2 .PP Use .I color as the percent color in the display. Default: normal .RE .B -pb | .B --percent-bold .br .B -pn | .B --percent-normal .br .RS 2 .PP Turn on/off the use of bold font when displaying the percent. Default off .RE .B -bbfg .I color | .B --bar-brace-foreground .I color .br .B -bbbg .I color | .B --bar-brace-background .I color .br .RS 2 .PP Use .I color as the brace color around the progress bar in the display. Default: normal .RE .B -bbb | .B --bar-brace-bold .br .B -bbn | .B --bar-brace-normal .br .RS 2 .PP Turn on/off the use of bold font when displaying the bar braces. Default off .RE .B -bfg .I color | .B --bar-foreground .I color .br .B -bbg .I color | .B --bar-background .I color .br .RS 2 .PP Use .I color as the color of the progress bar in the display. Default: normal .RE .B -bb | .B --bar-bold .br .B -bn | .B --bar-normal .br .RS 2 .PP Turn on/off the use of bold font when displaying the progress bar. Default off .RE .B -bobc | .B --bar-openbrace-char .I char .br .RS 2 .PP Use .I char as the open brace character on the progress bar. .RE .B -bcbc | .B --bar-closebrace-char .I char .br .RS 2 .PP Use .I char as the close brace character on the progress bar. .RE .B -bcc | .B --bar-complete-char .I char .br .RS 2 .PP Use .I char as the completed character on the progress bar. .RE .B -bic | .B --bar-incomplete-char .I char .br .RS 2 .PP Use .I char as the incomplete character on the progress bar. .RE .B -h | .B --help .br .RS 2 .PP Display this text and exit. .RE .B -v | .B --version .br .RS 2 .PP Display the program version and exit. .RE .SH RESOURCE FILE OPTIONS .PP Some command line options may be specified in a resource file. Bar will search for a resource file by the name of .B /etc/clpbarrc and, if found, bar will use the values within by default. Next bar will search for .B ~/.barrc and, if found, bar will use these values to override any values set within .BR /etc/clpbarrc . Last, bar will search for a file in the current working directory named .BR ./.barrc . If this file exists, it's values will override the values found in .B ~/.barrc or .BR /etc/clpbarrc . Values in all files may be overridden by command line flags. Lines that begin with a # are ignored. .PP For resource options requiring a .I boolean value, the following values are recognized: on and off, yes and no, (and the single-character abbreviations y and n), true and false, (and the single-character abbreviations t and f), 0 and 1. .PP For resource options requiring a .I color value, the same keywords are recognized as for the color-specific command line options above: normal, black, red, green, yellow, blue, magenta, cyan, and white .BR buffer-size : .I buffer-size .RS 2 .PP Allocate an I/O buffer of .I buffer-size bytes. See the .B --buffer-size command line option above. .RE .BR throttle : .I rate .RS 2 .PP Restrict I/O throughput to .I rate bytes per second. See the .B --throttle command line option above. .RE .BR interval : .I seconds .RS 2 .PP Update the display every .I seconds seconds. See the .B --interval command line option above. .RE .BR timeout : .I microseconds .RS 2 .PP The number of microseconds to wait for a change in I/O state before .I select() times out. See the .B --timeout command line option above. .RE .BR kilobyte : 1000|1024 .RS 2 .PP Use either 1000 or 1024 as the definition of a kilobyte. See the .B --kilo command line option above. .RE .BR block-size : .I size .RS 2 When parsing sizes specified in terms of blocks, assume a single block is .I size bytes. See the .B --block-size command line option above. .RE .BR screen-width : .I width .RS 2 .PP Override termio and assume that the screen is .I width characters wide. See the .B --screen-width command line option above. .RE .BR screen-width-minus-one : .I boolean .br .RS 2 .PP Instruct bar to restrict the number of columns reported by termio by one. See the .B --screen-width-minus-one command line option above. .RE .BR display-twiddle : .I boolean .br .RS 2 .PP Instruct bar to turn on/off the twirling twiddle character in the display. See the .B --display-twiddle command line option above. .RE .BR display-title : .I boolean .br .RS 2 .PP Instruct bar to turn on/off the title in the display. See the .B --display-title command line option above. .RE .BR display-count : boolean .br .RS 2 .PP Instruct bar to turn on/off the data count in the display. See the .B --display-count command line option above. .RE .BR display-count-bits : .I boolean .br .RS 2 .PP Display the data count as bits instead of as bytes. See the .B --display-count-bits command line option above. .RE .BR display-throughput : .I boolean .br .RS 2 .PP Instruct bar to turn on/off the data throughput in the display. See the .B --display-throughput command line option above. .RE .BR display-throughput-bits : boolean .br .RS 2 .PP Display throughput as bits/sec instead of as bytes/sec. See the .B --display-throughput-bits command line option above. .RE .BR display-time : .I boolean .br .RS 2 .PP Instruct bar to turn on/off the time in the display. See the .B --display-time command line option above. .RE .BR display-elapsed-only : .I boolean .br .RS 2 .PP Force bar to display the elapsed time instead of the eta. See the .B --display-elapsed-only command line option above. .RE .BR display-percent : .I boolean .br .RS 2 .PP Instruct bar to turn on/off the percent complete in the display. See the .B --display-percent command line option above. .RE .BR display-bar : .I boolean .br .RS 2 .PP Instruct bar to turn on/off the progress bar in the display. See the .B --display-bar command line option above. .RE .BR display-summary : .I boolean .br .RS 2 .PP Instruct bar to turn on/off the summary information displayed when operation is complete. See the .B --display-summary command line option above. .RE .BR info-file : .I infofile .br .RS 2 Display the information contained in .I infofile while copying data. The file .I infofile is a regular text file containing tidbits of information broken up into sections. Each section is separated by a line containing the string "@@@" by itself, with no other characters on the line, either preceeding or following. .PP When bar begins, it will count the number of sections within the file. Bar will then begin by displaying the first section of information to the display before it draws the status line. Then, periodically, each of the successive sections will be displayed as the progress indicator fills up. .PP The progress of the data transfer is the trigger for each successive display. For instance, if your information file has exactly four sections to it, then the first section will be printed as bar begins, the second section after the data transfer hits 25%, the third at 50%, and the fourth at 75%. .PP If bar is configured to use ANSI control codes, then the screen will be cleared before printing a section from the information file. Otherwise, the contents of the current screen are scolled up and off the screen. .RE .BR display-numeric : .I boolean .br .RS 2 Do not render the usual display, but instead display an integer representing the percent of the transfer that is complete, one integer per line. This output is suitable for piping to other programs such as .B dialog(1) or .BR zenity(1) . This implies that the total transfer size must be known by bar, either by finding the size of an input file directly or by using the .B --size command line option. .RE .BR display-wait : .I boolean .br .RS 2 Wait for the first byte of data to come through before displaying anything. .RE .BR display-ansi : .I boolean .br .RS 2 .PP Instruct bar to turn on/off the use of ansi color codes in the display. See the .B --display-ansi command line option above. .RE .BR space-background : .I color .br .RS 2 .PP Use .I color as the background color for spacing between display objects. See the .B --space-background command line option above. .RE .BR twiddle-foreground : .I color .br .BR twiddle-background : .I color .br .BR twiddle-bold : .I boolean .br .RS 2 .PP Use the specified colors for the foreground and background of the twiddle, and use a bold font. See the .BR --twiddle-foreground , .BR --twiddle-background , and .B --twiddle-bold command line options above. .RE .BR title : .I string .br .RS 2 .PP Set the title string for the display. See the .B --title command line option above. .RE .BR title-foreground : .I color .br .BR title-background : .I color .br .BR title-bold : .I boolean .br .RS 2 .PP Use the specified colors for the foreground and background of the title, and use a bold font. See the .BR --title-foreground , .BR --title-background , and .B --title-bold command line options above. .RE .BR count-foreground : .I color .br .BR count-background : .I color .br .BR count-bold : .I boolean .br .RS 2 .PP Use the specified colors for the foreground and background of the data count, and use a bold font. See the .BR --count-foreground , .BR --count-background , and .B --count-bold command line options above. .RE .BR throughput-label-foreground : .I color .br .BR throughput-label-background : .I color .br .BR throughput-label-bold : .I boolean .br .RS 2 .PP Use the specified colors for the foreground and background of the throughput label, and use a bold font. See the .BR --throughput-label-foreground , .BR --throughput-label-background , and .B --throughput-label-bold command line options above. .RE .BR throughput-foreground : .I color .br .BR throughput-background : .I color .br .BR throughput-bold : .I boolean .br .RS 2 .PP Use the specified colors for the foreground and background of the throughput, and use a bold font. See the .BR --throughput-foreground , .BR --throughput-background , and .B --throughput-bold command line options above. .RE .BR time-label-foreground : .I color .br .BR time-label-background : .I color .br .BR time-label-bold : .I boolean .br .RS 2 .PP Use the specified colors for the foreground and background of the time label, and use a bold font. See the .BR --time-label-foreground , .BR --time-label-background , and .B --time-label-bold command line options above. .RE .BR time-foreground : .I color .br .BR time-background : .I color .br .BR time-bold : .I boolean .br .RS 2 .PP Use the specified colors for the foreground and background of the time, and use a bold font. See the .BR --time-foreground , .BR --time-background , and .B --time-bold command line options above. .RE .BR percent-foreground : .I color .br .BR percent-background : .I color .br .BR percent-bold : .I boolean .br .RS 2 .PP Use the specified colors for the foreground and background of the percent, and use a bold font. See the .BR --percent-foreground , .BR --percent-background , and .B --percent-bold command line options above. .RE .BR bar-brace-foreground : .I color .br .BR bar-brace-background : .I color .br .BR bar-brace-bold : .I boolean .br .RS 2 .PP Use the specified colors for the foreground and background of the brace surrounding the progress bar, and use a bold font. See the .BR --bar-brace-foreground , .BR --bar-brace-background , and .B --bar-brace-bold command line options above. .RE .BR bar-foreground : .I color .br .BR bar-background : .I color .br .BR bar-bold : .I boolean .br .RS 2 Use the specified colors for the foreground and background of the progress bar, and use a bold font. See the .BR --bar-foreground , .BR --bar-background , and .B --bar-bold command line options above. .RE .BR bar-openbrace-char : .I char .br .BR bar-closebrace-char : .I char .br .BR bar-complete-char : .I char .br .BR bar-incomplete-char : .br .RS 2 Use the specified custom characters .I char for the opening brace, closing brace, completed, and incomplete characters when rendering the progress bar. .RE .SH EXAMPLES .PP Example 1: Using bar to copy a 2.4gb file from a device (in this case a tape drive) to a file, using a 64k buffer. .RS 2 .PP prompt% bar --in-file /dev/rmt/1cbn --out-file \\ .br tape-restore.tar --size 2.4g --buffer-size 64k .RE .PP Example 2: Using bar to copy a 37tb file across the network using SSH. .RS 2 .PP prompt% ssh remote 'dd if=file' | bar --size 37t > file .RE .PP Example 3: Using bar inside a tar-pipe command: .RS 2 .PP Normal tar-pipe command might be: .RS 2 .PP prompt% (cd /some/dir/somewhere && tar -cf - *) \\ .br | (cd /some/other/dir && tar -xBpf -) .RE .PP 3a: Using bar within the tar-pipe: .RS 2 .PP prompt% (cd /some/dir/somewhere && tar -cf - *) \\ .br | bar \\ .br | (cd /some/other/dir && tar -xBpf -) .RE .PP 3b: Using bar with the --size option in a tar-pipe: .RS 2 .PP prompt% du -sk /some/dir/somewhere .br 6281954 /some/dir/somewhere .br .PP prompt% (cd /some/dir/somewhere && tar -cf - *) \\ .br | bar --size 6281954k \\ .br | (cd /some/other/dir && tar -xBpf -) .RE .RE .PP Example 4: Using bar on a regular file. (Note that the .B --size option is not needed here, as bar will retrieve the file size itself.) .RS 2 .PP prompt% bar --in-file ./file | ssh remote 'cd /some/dir && dd of=file' .RE .PP Example 5: Generating a 512k file of random data. .RS 2 .PP prompt% dd if=/dev/random bs=1024 count=512 \\ .br | bar -s 512k -of ./random .RE .PP Example 6: An example .barrc file. .RS 2 # .br # This is an example of what a ~/.barrc file .br # might look like. Note that lines beginning .br # with a # are ignored. .br # .br display-twiddle: no .br display-ansi: yes .br # space-background: black .br twiddle-foreground: green .br # twiddle-background: normal .br # twiddle-bold: no .br count-foreground: green .br # count-background: magenta .br count-bold: yes .br throughput-label-foreground: normal .br # throughput-label-background: red .br throughput-label-bold: no .br throughput-foreground: green .br # throughput-background: black .br throughput-bold: yes .br time-label-foreground: normal .br # time-label-background: red .br time-label-bold: no .br time-foreground: green .br # time-background: black .br time-bold: yes .br percent-foreground: green .br # percent-background: green .br percent-bold: yes .br bar-brace-foreground: red .br # bar-brace-background: blue .br bar-brace-bold: no .br bar-foreground: yellow .br # bar-background: blue .br bar-bold: yes .RE .SH NOTES .RS 0 .TP 2 - The .B --size option is only used by bar in calculating information about the data transfer. Bar will not cease copying data once it has reached the number of bytes specified with the .B --size option, but instead bar will continue to copy data until and end of input is reached. If this behavior is undesirable then bar may be used in conjunction with dd, where the count option is used with dd to specify when to cut off the input stream. (See examples above.) .RE .RS 0 .TP 2 - When using other commands such as .B du -k to calculate the expected size of a data transfer stream, the value returned may not be exactly the number of bytes counted by bar in the actual data transfer. Common causes for this discrepancy could be attributed to round-off error or the use of 1000 bytes as a kilobyte rather than 1024. (If the later is the case, then using the .B -k 1000 option to bar will help.) When such discrepancies occur, bar may report that the data stream contained only 98% or as much as 101% of it's expected size. (If you have doubts, you should definitely verify your data using md5sum, diff, or cmp.) .RE .RS 0 .TP 2 - When the value of a calculation exceeds the size alloted for the display, the value +99... will be substituted in it's place. The complete value will be displayed in a summary statement after bar has reached the end of input. .RE .RS 0 .TP 2 - Bar assumes a linear relationship between the speed of the data transfer and the amount of time remaining. Specifically the calculation is based on the following: elapsed time / eta = bytes written / total size However, it has been the author's experience that the throughput speed will change, particularly at the beginning of the transfer, and this will affect the estimated time remaining. The author does not believe this is a bug, but a side-effect of this method of calculation. .RE .RS 0 .TP 2 - Bar assumes that there are 8 bits in both a byte and a char. .RE .SH BUGS .TP 2 - Bar uses the .I open() and .I fstat() functions to open and retrieve the size of regular files when using either the .B --in-file or .B --out-file command line options. Some OS's do not support Large Files (file sizes up to (2**63)-1 bytes) natively. Some OS's support Large Files but require _FILE_OFFSET_BITS or _LARGE_FILES to be defined properly at compile time. Other OS's support neither, but still allow programs to open files in excess of (2**32)-1 through an O_LARGEFILE option that can be passed to the .I open() function. When trying to open files greater than 2gb on an OS without Large File support, bar will exit with the message: "File too large". When trying to write more than 2gb of data to a file, bar will write 2**32-1 bytes and then the OS may terminate bar with a message similar to: "File size limit exceeded". When trying to open files greater than 2gb on an OS without Large File support, but with the O_LARGEFILE option that can be passed to .IR open() , bar will receive an error when trying to retrieve the file's size, but bar will be able to open the file anyway. Under these circumstances, bar will print a "File too large" error message, but will then proceed to transfer the data. Since bar will not be able to retrieve the file's size on it's own, the .B --size command line option must be used after the .B --in-file option to tell bar the file size manually. On such OS's, bar should be able to write more than 2gb of data to a file without any problems. For OS's that support files greater than 2gb, either natively or through the Large File extension definitions mentioned above, bar should work as expected. .TP 2 - The author has noticed that when running bar over an SSH connection, sometimes window resize events are not captured until after the display has gone through one or two more updates, which can cause the line to wrap. .TP 2 - The author has noticed that on some systems the use of aligned memory allocation, through either memalign() or posix_memalign(), causes bar to commit a segmentation fault the first time read() or readv() is called and passed a pointer to the aligned memory as it's input buffer. Attempts were made to try to isolate systems in which this bug bites through tests in configure, but all tests devised passed with flying colors. Therefore aligned memory allocation is turned off by default, and may only be enabled by passing --enable-use-memalign to configure when building the executable. .TP 2 - On some 64-bit systems it has been found that the CC compiler will, by default, compile bar in 32-bit mode. This has been known to cause math errors which result in segmentation faults and infinite loops. Although multiple configure tests have been added to the compilation phase to try to properly detect such compilers and compensate for such bugs, without access to such systems for debugging purposes there may be other bugs waiting to rear their ugly heads. .PP Report all bugs to the author. .PP Bar was developed on a Sun workstation running Solaris 8. To the best of the author's knowledge bar should compile and run on other platforms without much trouble. Should other OS's require modifications to the code, the author welcomes all patch submissions, but requests that you include the file .I config.log and the output of .I "gcc -dumpspecs" (or a listing of predefined variables, if not using gcc). .SH DISTRIBUTION .PP The latest version of bar can always be found at: .RS 2 http://www.freshmeat.net/projects/commandlineprogressbar .br http://sourceforge.net/projects/clpbar/ .RE .SH AUTHOR .PP Bar was written by Michael Peek. See DISTRIBUTION above for contact information. .PP Occasionally, the author fancies that he knows what he's doing. It is at these times more than ever that his coworkers should cower in fear... bar-1.11.1.orig/io.h0000644000175000017500000000423510631614130014253 0ustar georgeskgeorgesk/* * I/O and buffering */ #ifndef __io_h__ #define __io_h__ #include "headers.h" #include "types.h" /** I/O */ struct _io { /** Input path, if given on the command line. This is used when copying a * file into a directory, the base filename of the input file is used as the * filename in the destination directory, so we need to keep it around. */ char *in_path; /** Input file descriptor. */ int in; /** Output file descriptor. */ int out; /** Flag: Input source is ready to be read. */ int in_ready; /** Flag: Output source is ready to be written to. */ int out_ready; /** Flag: End of input has been reached. */ int eof_in; /** Flag: End of output has been reached. */ int eof_out; /** The size of the I/O buffer. */ size_t buffer_size; /** A pointer to the I/O buffer. */ char *buffer; /** The location of the start of the ring buffer. */ size_t buffer_head; /** The length of the ring buffer. */ size_t buffer_used; /** The number of bytes read the last time I/O was performed. */ ssize_t last_read; /** The number of bytes written the last time I/O was performed. */ ssize_t last_write; /** The total number of bytes read. */ uint64 total_read; /** The total number of bytes written. */ uint64 total_write; /** The total size of the input stream, if known. */ uint64 total_size; /** If continuing from a previously interrupted stream, assume that this * many bytes have already been read and written. */ uint64 continue_size; /** Flag: Whether or not the total size of the input stream is known. */ int total_size_known; /** The number of microseconds to wait for a change in I/O state. */ uint32 timeout; /** The current time, used for throttling input. */ time_t current_time; /** The maximum number of bytes per second that we're allowed to read. */ uint64 throttle; /** The number if bytes read so far for this second. */ uint64 throttle_count; /** The size of a block in bytes, used for calculating total_size and * buffer_size. */ uint64 block_size; }; typedef struct _io IO; extern IO io; int ioInit(void); int ioBegin(void); int ioEnd(void); void ioCheck(void); int ioRead(void); int ioWrite(void); int ioIsDone(void); #endif bar-1.11.1.orig/configure0000754000175000017500000063023111541656133015414 0ustar georgeskgeorgesk#! /bin/sh # Guess values for system-dependent variables and create Makefiles. # Generated by GNU Autoconf 2.64. # # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software # Foundation, Inc. # # This configure script is free software; the Free Software Foundation # gives unlimited permission to copy, distribute and modify it. ## -------------------- ## ## M4sh Initialization. ## ## -------------------- ## # Be more Bourne compatible 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 as_nl=' ' export as_nl # Printing a long string crashes Solaris 7 /usr/bin/printf. as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo # Prefer a ksh shell builtin over an external printf program on Solaris, # but without wasting forks for bash or zsh. if test -z "$BASH_VERSION$ZSH_VERSION" \ && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='print -r --' as_echo_n='print -rn --' elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='printf %s\n' as_echo_n='printf %s' else if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' as_echo_n='/usr/ucb/echo -n' else as_echo_body='eval expr "X$1" : "X\\(.*\\)"' as_echo_n_body='eval arg=$1; case $arg in #( *"$as_nl"*) expr "X$arg" : "X\\(.*\\)$as_nl"; arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; esac; expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" ' export as_echo_n_body as_echo_n='sh -c $as_echo_n_body as_echo' fi export as_echo_body as_echo='sh -c $as_echo_body as_echo' fi # The user is always right. 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 # IFS # We need space, tab and new line, in precisely that order. Quoting is # there to prevent editors from complaining about space-tab. # (If _AS_PATH_WALK were called with IFS unset, it would disable word # splitting by setting IFS to empty value.) IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. case $0 in #(( *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. 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 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 exit 1 fi # Unset variables that we do not need and which cause bugs (e.g. in # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" # suppresses any "Segmentation fault" message there. '((' could # trigger a bug in pdksh 5.2.14. for as_var in BASH_ENV ENV MAIL MAILPATH do eval test x\${$as_var+set} = xset \ && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : done PS1='$ ' PS2='> ' PS4='+ ' # NLS nuisances. LC_ALL=C export LC_ALL LANGUAGE=C export LANGUAGE # CDPATH. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH if test "x$CONFIG_SHELL" = x; then as_bourne_compatible="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 " 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 exitcode=1; echo positional parameters were not saved. fi test x\$exitcode = x0 || 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" if (eval "$as_required") 2>/dev/null; then : as_have_required=yes else as_have_required=no fi if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : else 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 test -z "$as_dir" && as_dir=. 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_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : CONFIG_SHELL=$as_shell as_have_required=yes if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : break 2 fi fi done;; esac as_found=false done $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : CONFIG_SHELL=$SHELL as_have_required=yes fi; } IFS=$as_save_IFS if test "x$CONFIG_SHELL" != x; then : # 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. BASH_ENV=/dev/null ENV=/dev/null (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV export CONFIG_SHELL exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"} fi if test x$as_have_required = xno; then : $as_echo "$0: This script requires a shell more modern than all" $as_echo "$0: the shells that I found on your system." if test x${ZSH_VERSION+set} = xset ; then $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" $as_echo "$0: be upgraded to zsh 4.3.4 or later." else $as_echo "$0: Please tell bug-autoconf@gnu.org 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_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=`$as_echo "$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 || $as_echo 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_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_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_fn_arith () { as_val=`expr "$@" || test $? -eq 1` } fi # as_fn_arith # as_fn_error 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=$?; test $as_status -eq 0 && as_status=1 if test "$3"; then as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3 fi $as_echo "$as_me: error: $1" >&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 || $as_echo 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" || { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } # 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 } 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 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 -p'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || as_ln_s='cp -p' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else as_ln_s='cp -p' fi else as_ln_s='cp -p' 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 if test -x / >/dev/null 2>&1; then as_test_x='test -x' else if ls -dL / >/dev/null 2>&1; then as_ls_L_option=L else as_ls_L_option= fi as_test_x=' eval sh -c '\'' if test -d "$1"; then test -d "$1/."; else case $1 in #( -*)set "./$1";; esac; case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( ???[sx]*):;;*)false;;esac;fi '\'' sh ' fi as_executable_p=$as_test_x # 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 7<&0 &1 # Name of the host. # hostname on some systems (SVR3.2, 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= PACKAGE_TARNAME= PACKAGE_VERSION= PACKAGE_STRING= PACKAGE_BUGREPORT= PACKAGE_URL= ac_unique_file="bar.c" # Factoring default headers for most tests. ac_includes_default="\ #include #ifdef HAVE_SYS_TYPES_H # include #endif #ifdef HAVE_SYS_STAT_H # include #endif #ifdef STDC_HEADERS # include # include #else # ifdef HAVE_STDLIB_H # include # endif #endif #ifdef HAVE_STRING_H # if !defined STDC_HEADERS && defined HAVE_MEMORY_H # include # endif # include #endif #ifdef HAVE_STRINGS_H # include #endif #ifdef HAVE_INTTYPES_H # include #endif #ifdef HAVE_STDINT_H # include #endif #ifdef HAVE_UNISTD_H # include #endif" ac_subst_vars='am__EXEEXT_FALSE am__EXEEXT_TRUE LTLIBOBJS MAX_SAFE_MULTIPLIER AM_CFLAGS DEFAULT_PAGE_SIZE DEFAULT_BUFFER_SIZE DEFAULT_DISPLAY_TWIDDLE DEFAULT_SH_MINUS_ONE DEFAULT_SW_MINUS_ONE LIBOBJS EGREP GREP CPP LN_S am__fastdepCC_FALSE am__fastdepCC_TRUE CCDEPMODE AMDEPBACKSLASH AMDEP_FALSE AMDEP_TRUE am__quote am__include DEPDIR OBJEXT EXEEXT ac_ct_CC CPPFLAGS LDFLAGS CFLAGS CC 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_os target_vendor target_cpu target host_os host_vendor host_cpu host build_os build_vendor build_cpu build 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 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' ac_subst_files='' ac_user_opts=' enable_option_checking enable_dependency_tracking enable_sw_1 enable_sw_0 enable_sh_1 enable_sh_0 enable_display_twiddle with_buffer_size with_page_size enable_use_memalign enable_use_iovec enable_use_m64 ' ac_precious_vars='build_alias host_alias target_alias CC CFLAGS LDFLAGS LIBS CPPFLAGS CPP' # 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' includedir='${prefix}/include' oldincludedir='/usr/include' docdir='${datarootdir}/doc/${PACKAGE}' 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=yes ;; esac # Accept the important Cygnus configure options, so we can diagnose typos. 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=`$as_echo "$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=`$as_echo "$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 ;; -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=`$as_echo "$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=`$as_echo "$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. $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option} ;; 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" ;; *) $as_echo "$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 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 $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host. If a cross compiler is detected then cross compile mode will be used." >&2 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 || $as_echo 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 this package 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] --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/PACKAGE] --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] --target=TARGET configure for building compilers for TARGET [HOST] _ACEOF fi if test -n "$ac_init_help"; then 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] --disable-dependency-tracking speeds up one-time build --enable-dependency-tracking do not reject slow dependency extractors --enable-sw-1 Assume screen width - 1 --enable-sw-0 Assume full screen width --enable-sh-1 Assume screen height - 1 --enable-sh-0 Assume full screen height --enable-display-twiddle Enable twiddle display by default --disable-use-memalign Disable aligned memory allocation (save memory, less than 1% performance decrease) (default: enabled) --disable-use-iovec Disable vectored I/O (30-50% performance decrease) (default: enabled) --disable-use-m64 Disable the use of -m64 compiler flag (default: enabled) Optional Packages: --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) --with-buffer-size=SIZE Default buffer size = SIZE bytes (default: 52488 (or 512KB)) --with-page-size=SIZE Default page size = SIZE bytes (default: as reported by sysconf, or 8192 (or 8KB)) 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 C/C++/Objective C preprocessor flags, e.g. -I if you have headers in a nonstandard directory CPP C preprocessor 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 the package provider. _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=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` # A ".." for each directory in $ac_dir_suffix. ac_top_builddir_sub=`$as_echo "$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 guested configure. 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 $as_echo "$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 configure generated by GNU Autoconf 2.64 Copyright (C) 2009 Free Software Foundation, Inc. This configure script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it. _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 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\"" $as_echo "$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 $as_echo "$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_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} return $ac_retval } # ac_fn_c_try_compile # ac_fn_c_try_cpp LINENO # ---------------------- # Try to preprocess conftest.$ac_ext, and return whether this succeeded. ac_fn_c_try_cpp () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack if { { ac_try="$ac_cpp conftest.$ac_ext" 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\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_cpp conftest.$ac_ext") 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 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} return $ac_retval } # ac_fn_c_try_cpp # ac_fn_c_try_run LINENO # ---------------------- # Try to link 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\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>&5 ac_status=$? $as_echo "$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\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_try") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; }; then : ac_retval=0 else $as_echo "$as_me: program exited with status $ac_status" >&5 $as_echo "$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; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} return $ac_retval } # ac_fn_c_try_run # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES # ------------------------------------------------------- # Tests whether HEADER exists, giving a warning if it cannot be compiled using # the include files in INCLUDES and setting the cache variable VAR # accordingly. ac_fn_c_check_header_mongrel () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : $as_echo_n "(cached) " >&6 fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } else # Is the header compilable? { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 $as_echo_n "checking $2 usability... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 #include <$2> _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_header_compiler=yes else ac_header_compiler=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 $as_echo "$ac_header_compiler" >&6; } # Is the header present? { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 $as_echo_n "checking $2 presence... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$2> _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : ac_header_preproc=yes else ac_header_preproc=no fi rm -f conftest.err conftest.$ac_ext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 $as_echo "$ac_header_preproc" >&6; } # So? What about this header? case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( yes:no: ) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} ;; no:yes:* ) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : $as_echo_n "(cached) " >&6 else eval "$3=\$ac_header_compiler" fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } fi eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} } # ac_fn_c_check_header_mongrel # 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 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : $as_echo_n "(cached) " >&6 else 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 eval "$3=no" fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} } # 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$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\"" $as_echo "$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 $as_echo "$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 || $as_test_x conftest$ac_exeext }; then : ac_retval=0 else $as_echo "$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; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} return $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 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : $as_echo_n "(cached) " >&6 else 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. Prefer to if __STDC__ is defined, since exists even on freestanding compilers. */ #ifdef __STDC__ # include #else # include #endif #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 () { return $2 (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : eval "$3=yes" else eval "$3=no" fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} } # ac_fn_c_check_func # 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 () { static int test_array [1 - 2 * !(($2) >= 0)]; test_array [0] = 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 () { static int test_array [1 - 2 * !(($2) <= $ac_mid)]; test_array [0] = 0 ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_hi=$ac_mid; break else 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.$ac_ext done else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 int main () { static int test_array [1 - 2 * !(($2) < 0)]; test_array [0] = 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 () { static int test_array [1 - 2 * !(($2) >= $ac_mid)]; test_array [0] = 0 ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_lo=$ac_mid; break else 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.$ac_ext done else ac_lo= ac_hi= fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext 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 () { static int test_array [1 - 2 * !(($2) <= $ac_mid)]; test_array [0] = 0 ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_hi=$ac_mid else as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val fi rm -f core conftest.err conftest.$ac_objext 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 () { return $2; } static unsigned long int ulongval () { return $2; } #include #include int main () { 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 $as_echo_n "checking whether $2 is declared... " >&6; } if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 int main () { #ifndef $2 (void) $2; #endif ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : eval "$3=yes" else eval "$3=no" fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} } # ac_fn_c_check_decl 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 $as_me, which was generated by GNU Autoconf 2.64. Invocation command line was $ $0 $@ _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 test -z "$as_dir" && as_dir=. $as_echo "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=`$as_echo "$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=$? # Save into config.log some information that might help in debugging. { echo cat <<\_ASBOX ## ---------------- ## ## Cache variables. ## ## ---------------- ## _ASBOX 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_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 $as_echo "$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 cat <<\_ASBOX ## ----------------- ## ## Output variables. ## ## ----------------- ## _ASBOX echo for ac_var in $ac_subst_vars do eval ac_val=\$$ac_var case $ac_val in *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac $as_echo "$ac_var='\''$ac_val'\''" done | sort echo if test -n "$ac_subst_files"; then cat <<\_ASBOX ## ------------------- ## ## File substitutions. ## ## ------------------- ## _ASBOX echo for ac_var in $ac_subst_files do eval ac_val=\$$ac_var case $ac_val in *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac $as_echo "$ac_var='\''$ac_val'\''" done | sort echo fi if test -s confdefs.h; then cat <<\_ASBOX ## ----------- ## ## confdefs.h. ## ## ----------- ## _ASBOX echo cat confdefs.h echo fi test "$ac_signal" != 0 && $as_echo "$as_me: caught signal $ac_signal" $as_echo "$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 $as_echo "/* confdefs.h */" > confdefs.h # Predefined preprocessor variables. cat >>confdefs.h <<_ACEOF #define PACKAGE_NAME "$PACKAGE_NAME" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_TARNAME "$PACKAGE_TARNAME" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_VERSION "$PACKAGE_VERSION" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_STRING "$PACKAGE_STRING" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_URL "$PACKAGE_URL" _ACEOF # Let the site file select an alternate cache file if it wants to. # Prefer an explicitly selected file to automatically selected ones. ac_site_file1=NONE ac_site_file2=NONE if test -n "$CONFIG_SITE"; then ac_site_file1=$CONFIG_SITE elif test "x$prefix" != xNONE; then ac_site_file1=$prefix/share/config.site ac_site_file2=$prefix/etc/config.site else ac_site_file1=$ac_default_prefix/share/config.site ac_site_file2=$ac_default_prefix/etc/config.site fi for ac_site_file in "$ac_site_file1" "$ac_site_file2" do test "x$ac_site_file" = xNONE && continue if test -r "$ac_site_file"; then { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 $as_echo "$as_me: loading site script $ac_site_file" >&6;} sed 's/^/| /' "$ac_site_file" >&5 . "$ac_site_file" 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. if test -f "$cache_file"; then { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 $as_echo "$as_me: loading cache $cache_file" >&6;} case $cache_file in [\\/]* | ?:[\\/]* ) . "$cache_file";; *) . "./$cache_file";; esac fi else { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 $as_echo "$as_me: creating cache $cache_file" >&6;} >$cache_file 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,) { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} ac_cache_corrupted=: ;; ,set) { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 $as_echo "$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 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} ac_cache_corrupted=: else { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} eval $ac_var=\$ac_old_val fi { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 $as_echo "$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=`$as_echo "$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 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} as_fn_error "run \`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_aux_dir= for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do for ac_t in install-sh install.sh shtool; do if test -f "$ac_dir/$ac_t"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/$ac_t -c" break 2 fi done done if test -z "$ac_aux_dir"; then as_fn_error "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$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. ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. # 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 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 $as_echo_n "checking build system type... " >&6; } if test "${ac_cv_build+set}" = set; then : $as_echo_n "(cached) " >&6 else 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 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 $as_echo "$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 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 $as_echo_n "checking host system type... " >&6; } if test "${ac_cv_host+set}" = set; then : $as_echo_n "(cached) " >&6 else 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 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 $as_echo "$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 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5 $as_echo_n "checking target system type... " >&6; } if test "${ac_cv_target+set}" = set; then : $as_echo_n "(cached) " >&6 else if test "x$target_alias" = x; then ac_cv_target=$ac_cv_host else ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` || as_fn_error "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5 fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5 $as_echo "$ac_cv_target" >&6; } case $ac_cv_target in *-*-*) ;; *) as_fn_error "invalid value of canonical target" "$LINENO" 5;; esac target=$ac_cv_target ac_save_IFS=$IFS; IFS='-' set x $ac_cv_target shift target_cpu=$1 target_vendor=$2 shift; shift # Remember, the first character of IFS is used to create $*, # except with old shells: target_os=$* IFS=$ac_save_IFS case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac # The aliases save the names the user supplied, while $host etc. # will get canonicalized. test -n "$target_alias" && test "$program_prefix$program_suffix$program_transform_name" = \ NONENONEs,x,x, && program_prefix=${target_alias}- am__api_version='1.11' # 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. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 $as_echo_n "checking for a BSD-compatible install... " >&6; } if test -z "$INSTALL"; then if test "${ac_cv_path_install+set}" = set; then : $as_echo_n "(cached) " >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. # Account for people who put trailing slashes in PATH elements. 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 { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$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+set}" = set; 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 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 $as_echo "$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' { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5 $as_echo_n "checking whether build environment is sane... " >&6; } # Just in case sleep 1 echo timestamp > conftest.file # 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 ( 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 rm -f conftest.file 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 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 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } 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=`$as_echo "$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 case $am_aux_dir in *\ * | *\ *) MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; *) MISSING="\${SHELL} $am_aux_dir/missing" ;; esac fi # Use eval to expand $SHELL if eval "$MISSING --run true"; then am_missing_run="$MISSING --run " else am_missing_run= { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;} fi if test x"${install_sh}" != 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 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_prog_STRIP+set}" = set; then : $as_echo_n "(cached) " >&6 else 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 test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_STRIP="${ac_tool_prefix}strip" $as_echo "$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 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 $as_echo "$STRIP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "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 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then : $as_echo_n "(cached) " >&6 else 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 test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_STRIP="strip" $as_echo "$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 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 $as_echo "$ac_ct_STRIP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_STRIP" = x; then STRIP=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$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" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; } if test -z "$MKDIR_P"; then if test "${ac_cv_path_mkdir+set}" = set; then : $as_echo_n "(cached) " >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in mkdir gmkdir; do for ac_exec_ext in '' $ac_executable_extensions; do { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #( 'mkdir (GNU coreutils) '* | \ 'mkdir (coreutils) '* | \ '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 if test "${ac_cv_path_mkdir+set}" = set; 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. test -d ./--version && rmdir ./--version MKDIR_P="$ac_install_sh -d" fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5 $as_echo "$MKDIR_P" >&6; } mkdir_p="$MKDIR_P" case $mkdir_p in [\\/$]* | ?:[\\/]*) ;; */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; esac 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 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_prog_AWK+set}" = set; then : $as_echo_n "(cached) " >&6 else 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 test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_AWK="$ac_prog" $as_echo "$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 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 $as_echo "$AWK" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$AWK" && break done { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } set x ${MAKE-make} ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then : $as_echo_n "(cached) " >&6 else 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 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } SET_MAKE= else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "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 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=bar VERSION=1.11.1 cat >>confdefs.h <<_ACEOF #define PACKAGE "$PACKAGE" _ACEOF cat >>confdefs.h <<_ACEOF #define VERSION "$VERSION" _ACEOF # 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"} # We need awk for the "check" target. The system "awk" is bad on # some platforms. # Always define AMTAR for backward compatibility. AMTAR=${AMTAR-"${am_missing_run}tar"} am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -' ac_config_headers="$ac_config_headers config.h" 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 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_prog_CC+set}" = set; then : $as_echo_n "(cached) " >&6 else 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 test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_CC="${ac_tool_prefix}gcc" $as_echo "$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 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "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 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : $as_echo_n "(cached) " >&6 else 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 test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_CC="gcc" $as_echo "$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 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 $as_echo "$ac_ct_CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$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 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_prog_CC+set}" = set; then : $as_echo_n "(cached) " >&6 else 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 test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_CC="${ac_tool_prefix}cc" $as_echo "$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 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "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 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_prog_CC+set}" = set; then : $as_echo_n "(cached) " >&6 else 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 test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$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" $as_echo "$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 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "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 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_prog_CC+set}" = set; then : $as_echo_n "(cached) " >&6 else 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 test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_CC="$ac_tool_prefix$ac_prog" $as_echo "$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 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "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 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : $as_echo_n "(cached) " >&6 else 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 test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_CC="$ac_prog" $as_echo "$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 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 $as_echo "$ac_ct_CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "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:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi fi fi test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error "no acceptable C compiler found in \$PATH See \`config.log' for more details." "$LINENO" 5; } # Provide some information about the compiler. $as_echo "$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; 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\"" $as_echo "$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 rm -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } done cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { FILE *f = fopen ("conftest.out", "w"); return ferror (f) || fclose (f) != 0; ; 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 conftest.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. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 $as_echo_n "checking for C compiler default output file name... " >&6; } ac_link_default=`$as_echo "$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\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link_default") 2>&5 ac_status=$? $as_echo "$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+set}" = set && 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 ac_file='' fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 $as_echo "$ac_file" >&6; } if test -z "$ac_file"; then : $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} { as_fn_set_status 77 as_fn_error "C compiler cannot create executables See \`config.log' for more details." "$LINENO" 5; }; } fi ac_exeext=$ac_cv_exeext # Check that the compiler produces executables we can run. If not, either # the compiler is broken, or we cross compile. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 $as_echo_n "checking whether the C compiler works... " >&6; } # If not cross compiling, check that we can run a simple program. if test "$cross_compiling" != yes; then if { ac_try='./$ac_file' { { 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\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_try") 2>&5 ac_status=$? $as_echo "$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 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error "cannot run C compiled programs. If you meant to cross compile, use \`--host'. See \`config.log' for more details." "$LINENO" 5; } fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out conftest.out ac_clean_files=$ac_clean_files_save # Check that the compiler produces executables we can run. If not, either # the compiler is broken, or we cross compile. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 $as_echo_n "checking whether we are cross compiling... " >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 $as_echo "$cross_compiling" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 $as_echo_n "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\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>&5 ac_status=$? $as_echo "$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_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error "cannot compute suffix of executables: cannot compile and link See \`config.log' for more details." "$LINENO" 5; } fi rm -f conftest$ac_cv_exeext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 $as_echo "$ac_cv_exeext" >&6; } rm -f conftest.$ac_ext EXEEXT=$ac_cv_exeext ac_exeext=$EXEEXT { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 $as_echo_n "checking for suffix of object files... " >&6; } if test "${ac_cv_objext+set}" = set; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; 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\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_compile") 2>&5 ac_status=$? $as_echo "$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_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error "cannot compute suffix of object files: cannot compile See \`config.log' for more details." "$LINENO" 5; } fi rm -f conftest.$ac_cv_objext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 $as_echo "$ac_cv_objext" >&6; } OBJEXT=$ac_cv_objext ac_objext=$OBJEXT { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } if test "${ac_cv_c_compiler_gnu+set}" = set; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { #ifndef __GNUC__ choke me #endif ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_compiler_gnu=yes else ac_compiler_gnu=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_cv_c_compiler_gnu=$ac_compiler_gnu fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 $as_echo "$ac_cv_c_compiler_gnu" >&6; } if test $ac_compiler_gnu = yes; then GCC=yes else GCC= fi ac_test_CFLAGS=${CFLAGS+set} ac_save_CFLAGS=$CFLAGS { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 $as_echo_n "checking whether $CC accepts -g... " >&6; } if test "${ac_cv_prog_cc_g+set}" = set; then : $as_echo_n "(cached) " >&6 else 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 () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_prog_cc_g=yes else CFLAGS="" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : else ac_c_werror_flag=$ac_save_c_werror_flag CFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; 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.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_c_werror_flag=$ac_save_c_werror_flag fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 $as_echo "$ac_cv_prog_cc_g" >&6; } if test "$ac_test_CFLAGS" = set; 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 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } if test "${ac_cv_prog_cc_c89+set}" = set; then : $as_echo_n "(cached) " >&6 else ac_cv_prog_cc_c89=no ac_save_CC=$CC cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #include #include /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ struct buf { int x; }; FILE * (*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 don't provoke an error unfortunately, instead are silently treated as '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's necessary to write '\x00'==0 to get something that's 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 **, FILE *(*)(struct buf *, struct stat *, int), int, int); int argc; char **argv; int main () { return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; ; return 0; } _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 test "x$ac_cv_prog_cc_c89" != "xno" && break done rm -f conftest.$ac_ext CC=$ac_save_CC fi # AC_CACHE_VAL case "x$ac_cv_prog_cc_c89" in x) { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 $as_echo "none needed" >&6; } ;; xno) { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 $as_echo "unsupported" >&6; } ;; *) CC="$CC $ac_cv_prog_cc_c89" { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; esac if test "x$ac_cv_prog_cc_c89" != xno; then : 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 DEPDIR="${am__leading_dot}deps" ac_config_commands="$ac_config_commands depfiles" am_make=${MAKE-make} cat > confinc << 'END' am__doit: @echo this is the am__doit target .PHONY: am__doit END # If we don't find an include directive, just comment out the code. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5 $as_echo_n "checking for style of include used by $am_make... " >&6; } am__include="#" am__quote= _am_result=none # First try GNU make style include. echo "include confinc" > confmf # Ignore all kinds of additional output from `make'. case `$am_make -s -f confmf 2> /dev/null` in #( *the\ am__doit\ target*) am__include=include am__quote= _am_result=GNU ;; esac # Now try BSD make style include. if test "$am__include" = "#"; then echo '.include "confinc"' > confmf case `$am_make -s -f confmf 2> /dev/null` in #( *the\ am__doit\ target*) am__include=.include am__quote="\"" _am_result=BSD ;; esac fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5 $as_echo "$_am_result" >&6; } rm -f confinc confmf # Check whether --enable-dependency-tracking was given. if test "${enable_dependency_tracking+set}" = set; then : enableval=$enable_dependency_tracking; fi if test "x$enable_dependency_tracking" != xno; then am_depcomp="$ac_aux_dir/depcomp" AMDEPBACKSLASH='\' fi if test "x$enable_dependency_tracking" != xno; then AMDEP_TRUE= AMDEP_FALSE='#' else AMDEP_TRUE='#' AMDEP_FALSE= fi depcc="$CC" am_compiler_list= { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 $as_echo_n "checking dependency style of $depcc... " >&6; } if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then : $as_echo_n "(cached) " >&6 else 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'. 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 8's {/usr,}/bin/sh. touch 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 ;; 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 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 $as_echo "$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 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 $as_echo_n "checking whether ln -s works... " >&6; } LN_S=$as_ln_s if test "$LN_S" = "ln -s"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 $as_echo "no, using $LN_S" >&6; } fi 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 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_prog_AWK+set}" = set; then : $as_echo_n "(cached) " >&6 else 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 test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_AWK="$ac_prog" $as_echo "$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 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 $as_echo "$AWK" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$AWK" && break done 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 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 $as_echo_n "checking how to run the C preprocessor... " >&6; } # On Suns, sometimes $CPP names a directory. if test -n "$CPP" && test -d "$CPP"; then CPP= fi if test -z "$CPP"; then if test "${ac_cv_prog_CPP+set}" = set; then : $as_echo_n "(cached) " >&6 else # Double quotes because CPP needs to be expanded for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" do ac_preproc_ok=false for ac_c_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer to if __STDC__ is defined, since # exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef __STDC__ # include #else # include #endif Syntax error _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : else # Broken: fails on valid input. continue fi rm -f conftest.err conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : # Broken: success on invalid input. continue else # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.err conftest.$ac_ext if $ac_preproc_ok; then : break fi done ac_cv_prog_CPP=$CPP fi CPP=$ac_cv_prog_CPP else ac_cv_prog_CPP=$CPP fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 $as_echo "$CPP" >&6; } ac_preproc_ok=false for ac_c_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer to if __STDC__ is defined, since # exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef __STDC__ # include #else # include #endif Syntax error _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : else # Broken: fails on valid input. continue fi rm -f conftest.err conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : # Broken: success on invalid input. continue else # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.err conftest.$ac_ext if $ac_preproc_ok; then : else { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error "C preprocessor \"$CPP\" fails sanity check See \`config.log' for more details." "$LINENO" 5; } 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 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } if test "${ac_cv_path_GREP+set}" = set; then : $as_echo_n "(cached) " >&6 else 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 test -z "$as_dir" && as_dir=. 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" { test -f "$ac_path_GREP" && $as_test_x "$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 $as_echo_n 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" $as_echo '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 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 $as_echo "$ac_cv_path_GREP" >&6; } GREP="$ac_cv_path_GREP" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 $as_echo_n "checking for egrep... " >&6; } if test "${ac_cv_path_EGREP+set}" = set; then : $as_echo_n "(cached) " >&6 else 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 test -z "$as_dir" && as_dir=. 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" { test -f "$ac_path_EGREP" && $as_test_x "$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 $as_echo_n 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" $as_echo '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 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 $as_echo "$ac_cv_path_EGREP" >&6; } EGREP="$ac_cv_path_EGREP" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 $as_echo_n "checking for ANSI C header files... " >&6; } if test "${ac_cv_header_stdc+set}" = set; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #include #include int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_header_stdc=yes else ac_cv_header_stdc=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext if test $ac_cv_header_stdc = yes; then # SunOS 4.x string.h does not declare mem*, contrary to ANSI. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "memchr" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "free" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. if test "$cross_compiling" = yes; then : : else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #if ((' ' & 0x0FF) == 0x020) # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) #else # define ISLOWER(c) \ (('a' <= (c) && (c) <= 'i') \ || ('j' <= (c) && (c) <= 'r') \ || ('s' <= (c) && (c) <= 'z')) # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) #endif #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) int main () { int i; for (i = 0; i < 256; i++) if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) return 2; return 0; } _ACEOF if ac_fn_c_try_run "$LINENO"; then : else ac_cv_header_stdc=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 fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 $as_echo "$ac_cv_header_stdc" >&6; } if test $ac_cv_header_stdc = yes; then $as_echo "#define STDC_HEADERS 1" >>confdefs.h fi # On IRIX 5.3, sys/types and inttypes.h are conflicting. for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ inttypes.h stdint.h unistd.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default " eval as_val=\$$as_ac_Header if test "x$as_val" = x""yes; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done for ac_header in \ assert.h \ ctype.h \ errno.h \ fcntl.h \ malloc.h \ stdarg.h \ stdio.h \ stdlib.h \ string.h \ strings.h \ sys/ioctl.h \ sys/select.h \ sys/stat.h \ sys/time.h \ sys/uio.h \ unistd.h \ signal.h \ termios.h \ do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" eval as_val=\$$as_ac_Header if test "x$as_val" = x""yes; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done for ac_func in \ posix_memalign \ select \ strerror \ sysconf \ sprintf \ do : as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" eval as_val=\$$as_ac_var if test "x$as_val" = x""yes; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 _ACEOF fi done for ac_header in stdlib.h do : ac_fn_c_check_header_mongrel "$LINENO" "stdlib.h" "ac_cv_header_stdlib_h" "$ac_includes_default" if test "x$ac_cv_header_stdlib_h" = x""yes; then : cat >>confdefs.h <<_ACEOF #define HAVE_STDLIB_H 1 _ACEOF fi done { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU libc compatible malloc" >&5 $as_echo_n "checking for GNU libc compatible malloc... " >&6; } if test "${ac_cv_func_malloc_0_nonnull+set}" = set; then : $as_echo_n "(cached) " >&6 else if test "$cross_compiling" = yes; then : ac_cv_func_malloc_0_nonnull=no else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #if defined STDC_HEADERS || defined HAVE_STDLIB_H # include #else char *malloc (); #endif int main () { return ! malloc (0); ; return 0; } _ACEOF if ac_fn_c_try_run "$LINENO"; then : ac_cv_func_malloc_0_nonnull=yes else ac_cv_func_malloc_0_nonnull=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 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_malloc_0_nonnull" >&5 $as_echo "$ac_cv_func_malloc_0_nonnull" >&6; } if test $ac_cv_func_malloc_0_nonnull = yes; then : $as_echo "#define HAVE_MALLOC 1" >>confdefs.h else $as_echo "#define HAVE_MALLOC 0" >>confdefs.h case " $LIBOBJS " in *" malloc.$ac_objext "* ) ;; *) LIBOBJS="$LIBOBJS malloc.$ac_objext" ;; esac $as_echo "#define malloc rpl_malloc" >>confdefs.h fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5 $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; } if test "${ac_cv_header_time+set}" = set; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #include int main () { if ((struct tm *) 0) return 0; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_header_time=yes else ac_cv_header_time=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5 $as_echo "$ac_cv_header_time" >&6; } if test $ac_cv_header_time = yes; then $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking if filesystem supports Large Files natively" >&5 $as_echo_n "checking if filesystem supports Large Files natively... " >&6; } if test "${ac_cv_c_native_large_file_support+set}" = set; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: (cached) $ac_cv_c_native_large_file_support" >&5 $as_echo "(cached) $ac_cv_c_native_large_file_support" >&6; } else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) int main () { int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 && LARGE_OFF_T % 2147483647 == 1) ? 1 : -1]; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_c_native_large_file_support=yes else ac_cv_c_native_large_file_support=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_native_large_file_support" >&5 $as_echo "$ac_cv_c_native_large_file_support" >&6; } fi if test $ac_cv_c_native_large_file_support = no; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking if _FILE_OFFSET_BITS needed for Large Files" >&5 $as_echo_n "checking if _FILE_OFFSET_BITS needed for Large Files... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #define _FILE_OFFSET_BITS 64 #include #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) int main () { int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 && LARGE_OFF_T % 2147483647 == 1) ? 1 : -1]; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_c_need_file_offset_bits=yes $as_echo "#define _FILE_OFFSET_BITS 64" >>confdefs.h { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } else ac_cv_c_need_file_offset_bits=no { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi if test $ac_cv_c_native_large_file_support = no; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking if _LARGE_FILES needed for Large Files" >&5 $as_echo_n "checking if _LARGE_FILES needed for Large Files... " >&6; } if test $ac_cv_c_need_file_offset_bits = yes; then ac_cv_c_need_large_files=no { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #define _LARGE_FILES 1 #include #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) int main () { int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 && LARGE_OFF_T % 2147483647 == 1) ? 1 : -1]; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_c_need_large_files=yes $as_echo "#define _LARGE_FILES 1" >>confdefs.h { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } else ac_cv_c_need_large_files=no { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for vectored I/O support" >&5 $as_echo_n "checking for vectored I/O support... " >&6; } if test "${ac_cv_have_struct_iovec+set}" = set; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: (cached) $ac_cv_have_struct_iovec" >&5 $as_echo "(cached) $ac_cv_have_struct_iovec" >&6; } else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef HAVE_SYS_UIO_H #include #endif int main () { struct iovec vec[2]; vec[0].iov_base = 0; vec[0].iov_len = 0; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_have_struct_iovec=yes $as_echo "#define HAVE_STRUCT_IOVEC 1" >>confdefs.h else ac_cv_have_struct_iovec=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_struct_iovec" >&5 $as_echo "$ac_cv_have_struct_iovec" >&6; } fi # 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. { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of unsigned char" >&5 $as_echo_n "checking size of unsigned char... " >&6; } if test "${ac_cv_sizeof_unsigned_char+set}" = set; then : $as_echo_n "(cached) " >&6 else if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (unsigned char))" "ac_cv_sizeof_unsigned_char" "$ac_includes_default"; then : else if test "$ac_cv_type_unsigned_char" = yes; then { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} { as_fn_set_status 77 as_fn_error "cannot compute sizeof (unsigned char) See \`config.log' for more details." "$LINENO" 5; }; } else ac_cv_sizeof_unsigned_char=0 fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_unsigned_char" >&5 $as_echo "$ac_cv_sizeof_unsigned_char" >&6; } cat >>confdefs.h <<_ACEOF #define SIZEOF_UNSIGNED_CHAR $ac_cv_sizeof_unsigned_char _ACEOF # 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. { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of unsigned short" >&5 $as_echo_n "checking size of unsigned short... " >&6; } if test "${ac_cv_sizeof_unsigned_short+set}" = set; then : $as_echo_n "(cached) " >&6 else if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (unsigned short))" "ac_cv_sizeof_unsigned_short" "$ac_includes_default"; then : else if test "$ac_cv_type_unsigned_short" = yes; then { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} { as_fn_set_status 77 as_fn_error "cannot compute sizeof (unsigned short) See \`config.log' for more details." "$LINENO" 5; }; } else ac_cv_sizeof_unsigned_short=0 fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_unsigned_short" >&5 $as_echo "$ac_cv_sizeof_unsigned_short" >&6; } cat >>confdefs.h <<_ACEOF #define SIZEOF_UNSIGNED_SHORT $ac_cv_sizeof_unsigned_short _ACEOF # 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. { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of unsigned int" >&5 $as_echo_n "checking size of unsigned int... " >&6; } if test "${ac_cv_sizeof_unsigned_int+set}" = set; then : $as_echo_n "(cached) " >&6 else if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (unsigned int))" "ac_cv_sizeof_unsigned_int" "$ac_includes_default"; then : else if test "$ac_cv_type_unsigned_int" = yes; then { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} { as_fn_set_status 77 as_fn_error "cannot compute sizeof (unsigned int) See \`config.log' for more details." "$LINENO" 5; }; } else ac_cv_sizeof_unsigned_int=0 fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_unsigned_int" >&5 $as_echo "$ac_cv_sizeof_unsigned_int" >&6; } cat >>confdefs.h <<_ACEOF #define SIZEOF_UNSIGNED_INT $ac_cv_sizeof_unsigned_int _ACEOF # 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. { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of unsigned long" >&5 $as_echo_n "checking size of unsigned long... " >&6; } if test "${ac_cv_sizeof_unsigned_long+set}" = set; then : $as_echo_n "(cached) " >&6 else if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (unsigned long))" "ac_cv_sizeof_unsigned_long" "$ac_includes_default"; then : else if test "$ac_cv_type_unsigned_long" = yes; then { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} { as_fn_set_status 77 as_fn_error "cannot compute sizeof (unsigned long) See \`config.log' for more details." "$LINENO" 5; }; } else ac_cv_sizeof_unsigned_long=0 fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_unsigned_long" >&5 $as_echo "$ac_cv_sizeof_unsigned_long" >&6; } cat >>confdefs.h <<_ACEOF #define SIZEOF_UNSIGNED_LONG $ac_cv_sizeof_unsigned_long _ACEOF # 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. { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of unsigned long long" >&5 $as_echo_n "checking size of unsigned long long... " >&6; } if test "${ac_cv_sizeof_unsigned_long_long+set}" = set; then : $as_echo_n "(cached) " >&6 else if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (unsigned long long))" "ac_cv_sizeof_unsigned_long_long" "$ac_includes_default"; then : else if test "$ac_cv_type_unsigned_long_long" = yes; then { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} { as_fn_set_status 77 as_fn_error "cannot compute sizeof (unsigned long long) See \`config.log' for more details." "$LINENO" 5; }; } else ac_cv_sizeof_unsigned_long_long=0 fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_unsigned_long_long" >&5 $as_echo "$ac_cv_sizeof_unsigned_long_long" >&6; } cat >>confdefs.h <<_ACEOF #define SIZEOF_UNSIGNED_LONG_LONG $ac_cv_sizeof_unsigned_long_long _ACEOF # 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. { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of size_t" >&5 $as_echo_n "checking size of size_t... " >&6; } if test "${ac_cv_sizeof_size_t+set}" = set; then : $as_echo_n "(cached) " >&6 else if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (size_t))" "ac_cv_sizeof_size_t" "$ac_includes_default"; then : else if test "$ac_cv_type_size_t" = yes; then { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} { as_fn_set_status 77 as_fn_error "cannot compute sizeof (size_t) See \`config.log' for more details." "$LINENO" 5; }; } else ac_cv_sizeof_size_t=0 fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_size_t" >&5 $as_echo "$ac_cv_sizeof_size_t" >&6; } cat >>confdefs.h <<_ACEOF #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t _ACEOF ac_fn_c_check_decl "$LINENO" "_SC_PAGE_SIZE" "ac_cv_have_decl__SC_PAGE_SIZE" "$ac_includes_default" if test "x$ac_cv_have_decl__SC_PAGE_SIZE" = x""yes; then : ac_have_decl=1 else ac_have_decl=0 fi cat >>confdefs.h <<_ACEOF #define HAVE_DECL__SC_PAGE_SIZE $ac_have_decl _ACEOF ac_fn_c_check_decl "$LINENO" "_SC_PAGESIZE" "ac_cv_have_decl__SC_PAGESIZE" "$ac_includes_default" if test "x$ac_cv_have_decl__SC_PAGESIZE" = x""yes; then : ac_have_decl=1 else ac_have_decl=0 fi cat >>confdefs.h <<_ACEOF #define HAVE_DECL__SC_PAGESIZE $ac_have_decl _ACEOF ac_cv_default_sw_minus_one=0 case "$target" in *-pc-cygwin) ac_cv_default_sw_minus_one=1 ;; esac # Check whether --enable-sw-1 was given. if test "${enable_sw_1+set}" = set; then : enableval=$enable_sw_1; ac_cv_default_sw_minus_one=1 else ac_cv_default_sw_minus_one=0 fi # Check whether --enable-sw-0 was given. if test "${enable_sw_0+set}" = set; then : enableval=$enable_sw_0; ac_cv_default_sw_minus_one=0 fi # Check whether --enable-sh-1 was given. if test "${enable_sh_1+set}" = set; then : enableval=$enable_sh_1; ac_cv_default_sh_minus_one=1 else ac_cv_default_sh_minus_one=0 fi # Check whether --enable-sh-0 was given. if test "${enable_sh_0+set}" = set; then : enableval=$enable_sh_0; ac_cv_default_sh_minus_one=0 fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default screen width adjustment" >&5 $as_echo_n "checking for default screen width adjustment... " >&6; } if test "${ac_cv_default_sw_minus_one+set}" = set; then : $as_echo_n "(cached) " >&6 else ac_cv_default_sw_minus_one=0 fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_default_sw_minus_one" >&5 $as_echo "$ac_cv_default_sw_minus_one" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default screen height adjustment" >&5 $as_echo_n "checking for default screen height adjustment... " >&6; } if test "${ac_cv_default_sh_minus_one+set}" = set; then : $as_echo_n "(cached) " >&6 else ac_cv_default_sh_minus_one=0 fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_default_sh_minus_one" >&5 $as_echo "$ac_cv_default_sh_minus_one" >&6; } cat >>confdefs.h <<_ACEOF #define DEFAULT_SW_MINUS_ONE $ac_cv_default_sw_minus_one _ACEOF cat >>confdefs.h <<_ACEOF #define DEFAULT_SH_MINUS_ONE $ac_cv_default_sh_minus_one _ACEOF # Check whether --enable-display-twiddle was given. if test "${enable_display_twiddle+set}" = set; then : enableval=$enable_display_twiddle; ac_cv_default_display_twiddle=1 else ac_cv_default_display_twiddle=0 fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking if twiddle display should be enabled by default" >&5 $as_echo_n "checking if twiddle display should be enabled by default... " >&6; } if test "${ac_cv_default_display_twiddle+set}" = set; then : $as_echo_n "(cached) " >&6 else ac_cv_default_display_twiddle=0 fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_default_display_twiddle" >&5 $as_echo "$ac_cv_default_display_twiddle" >&6; } cat >>confdefs.h <<_ACEOF #define DEFAULT_DISPLAY_TWIDDLE $ac_cv_default_display_twiddle _ACEOF # Check whether --with-buffer-size was given. if test "${with_buffer_size+set}" = set; then : withval=$with_buffer_size; ac_cv_default_buffer_size=$withval else ac_cv_default_buffer_size=52488 fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking default buffer size" >&5 $as_echo_n "checking default buffer size... " >&6; } if test "${ac_cv_default_buffer_size+set}" = set; then : $as_echo_n "(cached) " >&6 else ac_cv_default_buffer_size=52488 fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_default_buffer_size" >&5 $as_echo "$ac_cv_default_buffer_size" >&6; } cat >>confdefs.h <<_ACEOF #define DEFAULT_BUFFER_SIZE $ac_cv_default_buffer_size _ACEOF if test "${ac_cv_func_sysconf}" = "yes"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking sysconf usability" >&5 $as_echo_n "checking sysconf usability... " >&6; } if test "${ac_cv_sysconf_works+set}" = set; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: (cached) $ac_cv_sysconf_works" >&5 $as_echo "(cached) $ac_cv_sysconf_works" >&6; } else if test "$cross_compiling" = yes; then : { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error "cannot run test program while cross compiling See \`config.log' for more details." "$LINENO" 5; } else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #include #include #include #ifdef HAVE_SYSCONF # if HAVE_DECL__SC_PAGE_SIZE == 1 # define PAGESIZE _SC_PAGE_SIZE # else # if HAVE_DECL__SC_PAGESIZE == 1 # define PAGESIZE _SC_PAGESIZE # endif # endif # ifndef PAGESIZE # error I dont know how to retrieve the size of a page using sysconf. # undef HAVE_SYSCONF # endif #endif int main(int argc, char *argv[]) { long page_size = 0; #ifdef HAVE_SYSCONF page_size = sysconf(PAGESIZE); #endif fprintf(stderr, "sysconf says the page size is: %ld\n", page_size); assert(page_size != 0); assert(page_size > 0); assert(page_size % sizeof(void *) == 0); return(0); } _ACEOF if ac_fn_c_try_run "$LINENO"; then : ac_cv_sysconf_works="yes" else ac_cv_sysconf_works="no" fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sysconf_works" >&5 $as_echo "$ac_cv_sysconf_works" >&6; } fi fi if test "${ac_cv_sysconf_works}" = "yes"; then ac_cv_default_page_size=`cat config.log | grep '^sysconf says the page size is: ' | awk -F: '{print $2}' | sed 's, ,,g'`; fi # Check whether --with-page-size was given. if test "${with_page_size+set}" = set; then : withval=$with_page_size; ac_cv_default_page_size=$withval fi if test "${ac_cv_default_page_size+set}" != set; then ac_cv_default_page_size=8192 fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking default page size" >&5 $as_echo_n "checking default page size... " >&6; } if test "${ac_cv_default_page_size+set}" = set; then : $as_echo_n "(cached) " >&6 else ac_cv_default_page_size=8192 fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_default_page_size" >&5 $as_echo "$ac_cv_default_page_size" >&6; } cat >>confdefs.h <<_ACEOF #define DEFAULT_PAGE_SIZE $ac_cv_default_page_size _ACEOF # Check whether --enable-use-memalign was given. if test "${enable_use_memalign+set}" = set; then : enableval=$enable_use_memalign; ac_cv_use_memalign=$enableval else ac_cv_use_memalign="yes" fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking if aligned memory allocation is enabled" >&5 $as_echo_n "checking if aligned memory allocation is enabled... " >&6; } if test "${ac_cv_use_memalign+set}" = set; then : $as_echo_n "(cached) " >&6 else ac_cv_use_memalign fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_use_memalign" >&5 $as_echo "$ac_cv_use_memalign" >&6; } if test "${ac_cv_use_memalign}" = "yes"; then if test "${ac_cv_func_posix_memalign}" = "no"; then ac_cv_use_memalign="no" else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for posix_memalign usability" >&5 $as_echo_n "checking for posix_memalign usability... " >&6; } if test "${ac_cv_posix_memalign_works+set}" = set; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: (cached) $ac_cv_posix_memalign_works" >&5 $as_echo "(cached) $ac_cv_posix_memalign_works" >&6; } else if test "$cross_compiling" = yes; then : { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error "cannot run test program while cross compiling See \`config.log' for more details." "$LINENO" 5; } else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #include #include #ifdef HAVE_SYSCONF # if HAVE_DECL__SC_PAGE_SIZE == 1 # define PAGESIZE _SC_PAGE_SIZE # else # if HAVE_DECL__SC_PAGESIZE == 1 # define PAGESIZE _SC_PAGESIZE # endif # endif # ifndef PAGESIZE # warning I dont know how to retrieve the size of a page using sysconf. # warning Assuming page size is DEFAULT_PAGE_SIZE bytes. # undef HAVE_SYSCONF # endif #endif int main(int argc, char *argv[]) { long page_size = DEFAULT_PAGE_SIZE; unsigned long long buffer_size = DEFAULT_PAGE_SIZE; unsigned long long count = 0; char * ptr = 0; int ret_val = 0; int einval = EINVAL; int enomem = ENOMEM; #ifdef HAVE_SYSCONF page_size = sysconf(PAGESIZE); #endif assert(page_size > 0); assert(page_size % sizeof(void *) == 0); if (page_size > buffer_size) { buffer_size = page_size; } buffer_size /= sizeof(void *); buffer_size *= 2*sizeof(void *); ret_val = posix_memalign((void *)&ptr,page_size,buffer_size); assert(!(ret_val == einval)); assert(!(ret_val == enomem)); assert(ret_val == 0); for (count = 0; count < buffer_size; count++) { ptr[count] = 0; } free(ptr); return(0); } _ACEOF if ac_fn_c_try_run "$LINENO"; then : ac_cv_posix_memalign_works=yes else ac_cv_posix_memalign_works=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_posix_memalign_works" >&5 $as_echo "$ac_cv_posix_memalign_works" >&6; } fi if test "${ac_cv_posix_memalign_works}" = "no"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking if posix_memalign requires _GNU_SOURCE to be defined" >&5 $as_echo_n "checking if posix_memalign requires _GNU_SOURCE to be defined... " >&6; } if test "${ac_cv_posix_memalign_gnu_source+set}" = set; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: (cached) $ac_cv_posix_memalign_gnu_source" >&5 $as_echo "(cached) $ac_cv_posix_memalign_gnu_source" >&6; } else if test "$cross_compiling" = yes; then : { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error "cannot run test program while cross compiling See \`config.log' for more details." "$LINENO" 5; } else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #include #include #ifdef HAVE_SYSCONF # if HAVE_DECL__SC_PAGE_SIZE == 1 # define PAGESIZE _SC_PAGE_SIZE # else # if HAVE_DECL__SC_PAGESIZE == 1 # define PAGESIZE _SC_PAGESIZE # endif # endif # ifndef PAGESIZE # warning I dont know how to retrieve the size of a page using sysconf. # warning Assuming page size is DEFAULT_PAGE_SIZE bytes. # undef HAVE_SYSCONF # endif #endif #define _GNU_SOURCE 1 int main(int argc, char *argv[]) { long page_size = DEFAULT_PAGE_SIZE; unsigned long long buffer_size = DEFAULT_PAGE_SIZE; unsigned long long count = 0; char * ptr = 0; int ret_val = 0; int einval = EINVAL; int enomem = ENOMEM; #ifdef HAVE_SYSCONF page_size = sysconf(PAGESIZE); #endif assert(page_size > 0); assert(page_size % sizeof(void *) == 0); if (page_size > buffer_size) { buffer_size = page_size; } buffer_size /= sizeof(void *); buffer_size *= 2*sizeof(void *); ret_val = posix_memalign((void *)&ptr,page_size,buffer_size); assert(!(ret_val == einval)); assert(!(ret_val == enomem)); assert(ret_val == 0); for (count = 0; count < buffer_size; count++) { ptr[count] = 0; } free(ptr); return(0); } _ACEOF if ac_fn_c_try_run "$LINENO"; then : ac_cv_posix_memalign_gnu_source=yes ac_cv_posix_memalign_works=yes $as_echo "#define _GNU_SOURCE 1" >>confdefs.h { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } else ac_cv_posix_memalign_gnu_source=no { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi fi fi if test "${ac_cv_posix_memalign_works}" = "no"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking if posix_memalign requires _XOPEN_SOURCE=600 to be defined" >&5 $as_echo_n "checking if posix_memalign requires _XOPEN_SOURCE=600 to be defined... " >&6; } if test "${ac_cv_posix_memalign_xopen_source+set}" = set; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: (cached) $ac_cv_posix_memalign_xopen_source" >&5 $as_echo "(cached) $ac_cv_posix_memalign_xopen_source" >&6; } else if test "$cross_compiling" = yes; then : { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error "cannot run test program while cross compiling See \`config.log' for more details." "$LINENO" 5; } else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #include #include #ifdef HAVE_SYSCONF # if HAVE_DECL__SC_PAGE_SIZE == 1 # define PAGESIZE _SC_PAGE_SIZE # else # if HAVE_DECL__SC_PAGESIZE == 1 # define PAGESIZE _SC_PAGESIZE # endif # endif # ifndef PAGESIZE # warning I dont know how to retrieve the size of a page using sysconf. # warning Assuming page size is DEFAULT_PAGE_SIZE bytes. # undef HAVE_SYSCONF # endif #endif #define _XOPEN_SOURCE 600 int main(int argc, char *argv[]) { long page_size = DEFAULT_PAGE_SIZE; unsigned long long buffer_size = DEFAULT_PAGE_SIZE; unsigned long long count = 0; char * ptr = 0; int ret_val = 0; int einval = EINVAL; int enomem = ENOMEM; #ifdef HAVE_SYSCONF page_size = sysconf(PAGESIZE); #endif assert(page_size > 0); assert(page_size % sizeof(void *) == 0); if (page_size > buffer_size) { buffer_size = page_size; } buffer_size /= sizeof(void *); buffer_size *= 2*sizeof(void *); ret_val = posix_memalign((void *)&ptr,page_size,buffer_size); assert(!(ret_val == einval)); assert(!(ret_val == enomem)); assert(ret_val == 0); for (count = 0; count < buffer_size; count++) { ptr[count] = 0; } free(ptr); return(0); } _ACEOF if ac_fn_c_try_run "$LINENO"; then : ac_cv_posix_memalign_xopen_source=yes ac_cv_posix_memalign_works=yes $as_echo "#define _XOPEN_SOURCE 600" >>confdefs.h { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } else ac_cv_posix_memalign_xopen_source=no { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi fi fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking if aligned memory allocation is available" >&5 $as_echo_n "checking if aligned memory allocation is available... " >&6; } if test "${ac_cv_use_memalign+set}" = set; then : $as_echo_n "(cached) " >&6 else ac_cv_use_memalign fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_use_memalign" >&5 $as_echo "$ac_cv_use_memalign" >&6; } if test "${ac_cv_use_memalign}" = "yes"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking if aligned memory allocation is usable" >&5 $as_echo_n "checking if aligned memory allocation is usable... " >&6; } if test "${ac_cv_posix_memalign_works}" = "yes"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } ac_cv_use_memalign="no" fi fi if test "${ac_cv_use_memalign}" = "yes"; then $as_echo "#define USE_MEMALIGN 1" >>confdefs.h fi # Check whether --enable-use-iovec was given. if test "${enable_use_iovec+set}" = set; then : enableval=$enable_use_iovec; ac_cv_use_iovec=$enableval else ac_cv_use_iovec="yes" fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking if vectored I/O is enabled" >&5 $as_echo_n "checking if vectored I/O is enabled... " >&6; } if test "${ac_cv_use_iovec+set}" = set; then : $as_echo_n "(cached) " >&6 else ac_cv_use_iovec fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_use_iovec" >&5 $as_echo "$ac_cv_use_iovec" >&6; } if test "${ac_cv_have_struct_iovec}" = "no"; then ac_cv_use_iovec="no" fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking if vectored I/O is available" >&5 $as_echo_n "checking if vectored I/O is available... " >&6; } if test "${ac_cv_use_iovec+set}" = set; then : $as_echo_n "(cached) " >&6 else ac_cv_use_iovec fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_use_iovec" >&5 $as_echo "$ac_cv_use_iovec" >&6; } if test "${ac_cv_use_iovec}" = "yes"; then $as_echo "#define USE_IOVEC 1" >>confdefs.h fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether CC supports -m64" >&5 $as_echo_n "checking whether CC supports -m64... " >&6; } if test "${ac_cv_m64_available+set}" = set; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: (cached) $ac_cv_m64_available" >&5 $as_echo "(cached) $ac_cv_m64_available" >&6; } else my_save_cflags="$CFLAGS" CFLAGS=-m64 cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { return(0); ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_m64_available=yes else ac_cv_m64_available=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext CFLAGS="$my_save_cflags" { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_m64_available" >&5 $as_echo "$ac_cv_m64_available" >&6; } fi # Check whether --enable-use-m64 was given. if test "${enable_use_m64+set}" = set; then : enableval=$enable_use_m64; ac_cv_use_m64=$enableval else ac_cv_use_m64="yes" fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the use of -m64 compiler flag is enabled" >&5 $as_echo_n "checking if the use of -m64 compiler flag is enabled... " >&6; } if test "${ac_cv_use_m64+set}" = set; then : $as_echo_n "(cached) " >&6 else ac_cv_use_m64 fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_use_m64" >&5 $as_echo "$ac_cv_use_m64" >&6; } if test "${ac_cv_m64_available}" = "yes"; then if test "${ac_cv_use_m64}" = "yes"; then AM_CFLAGS="${AM_CFLAGS} -m64" fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking if system supports counting to 1 exabyte" >&5 $as_echo_n "checking if system supports counting to 1 exabyte... " >&6; } if test "${ac_cv_c_exabyte_support+set}" = set; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: (cached) $ac_cv_c_exabyte_support" >&5 $as_echo "(cached) $ac_cv_c_exabyte_support" >&6; } else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { unsigned long long n = 1; n *= 1000; /* 1K */ n *= 1000; /* 1M */ n *= 1000; /* 1G */ n *= 1000; /* 1T */ n *= 1000; /* 1P */ n *= 1000; /* 1E */ n /= 1000; n /= 1000; n /= 1000; n /= 1000; n /= 1000; n /= 1000; assert(n == 1); ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_c_exabyte_support=yes $as_echo "#define HAVE_EXABYTE_SUPPORT 1" >>confdefs.h else ac_cv_c_exabyte_support=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_exabyte_support" >&5 $as_echo "$ac_cv_c_exabyte_support" >&6; } fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking if system supports counting to 1 petabyte" >&5 $as_echo_n "checking if system supports counting to 1 petabyte... " >&6; } if test "${ac_cv_c_petabyte_support+set}" = set; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: (cached) $ac_cv_c_petabyte_support" >&5 $as_echo "(cached) $ac_cv_c_petabyte_support" >&6; } else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { unsigned long long n = 1; n *= 1000; /* 1K */ n *= 1000; /* 1M */ n *= 1000; /* 1G */ n *= 1000; /* 1T */ n *= 1000; /* 1P */ n /= 1000; n /= 1000; n /= 1000; n /= 1000; n /= 1000; assert(n == 1); ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_c_petabyte_support=yes $as_echo "#define HAVE_PETABYTE_SUPPORT 1" >>confdefs.h else ac_cv_c_petabyte_support=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_petabyte_support" >&5 $as_echo "$ac_cv_c_petabyte_support" >&6; } fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking if system supports counting to 1 terabyte" >&5 $as_echo_n "checking if system supports counting to 1 terabyte... " >&6; } if test "${ac_cv_c_terabyte_support+set}" = set; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: (cached) $ac_cv_c_terabyte_support" >&5 $as_echo "(cached) $ac_cv_c_terabyte_support" >&6; } else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { unsigned long long n = 1; n *= 1000; /* 1K */ n *= 1000; /* 1M */ n *= 1000; /* 1G */ n *= 1000; /* 1T */ n /= 1000; n /= 1000; n /= 1000; n /= 1000; assert(n == 1); ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_c_terabyte_support=yes $as_echo "#define HAVE_TERABYTE_SUPPORT 1" >>confdefs.h else ac_cv_c_terabyte_support=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_terabyte_support" >&5 $as_echo "$ac_cv_c_terabyte_support" >&6; } fi if test "${ac_cv_c_exabyte_support}" = "no"; then if test "${ac_cv_c_petabyte_support}" = "no"; then if test "${ac_cv_c_terabyte_support}" = "no"; then ac_cv_c_max_safe_multiplier=1000000000 else ac_cv_c_max_safe_multiplier=1000000000000 fi else ac_cv_c_max_safe_multiplier=1000000000000000 fi else ac_cv_c_max_safe_multiplier=1000000000000000000 fi cat >>confdefs.h <<_ACEOF #define MAX_SAFE_MULTIPLIER $ac_cv_c_max_safe_multiplier _ACEOF ac_config_files="$ac_config_files Makefile bar.1 doxygen.conf" ac_config_commands="$ac_config_commands test-script-preparation" 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_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 $as_echo "$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+set}" = set || &/ 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 test "x$cache_file" != "x/dev/null" && { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 $as_echo "$as_me: updating cache $cache_file" >&6;} cat confcache >$cache_file else { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} 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= 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=`$as_echo "$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 if test -n "$EXEEXT"; then am__EXEEXT_TRUE= am__EXEEXT_FALSE='#' else am__EXEEXT_TRUE='#' am__EXEEXT_FALSE= 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 : ${CONFIG_STATUS=./config.status} ac_write_fail=0 ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files $CONFIG_STATUS" { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 $as_echo "$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 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 as_nl=' ' export as_nl # Printing a long string crashes Solaris 7 /usr/bin/printf. as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo # Prefer a ksh shell builtin over an external printf program on Solaris, # but without wasting forks for bash or zsh. if test -z "$BASH_VERSION$ZSH_VERSION" \ && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='print -r --' as_echo_n='print -rn --' elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='printf %s\n' as_echo_n='printf %s' else if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' as_echo_n='/usr/ucb/echo -n' else as_echo_body='eval expr "X$1" : "X\\(.*\\)"' as_echo_n_body='eval arg=$1; case $arg in #( *"$as_nl"*) expr "X$arg" : "X\\(.*\\)$as_nl"; arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; esac; expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" ' export as_echo_n_body as_echo_n='sh -c $as_echo_n_body as_echo' fi export as_echo_body as_echo='sh -c $as_echo_body as_echo' fi # The user is always right. 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 # IFS # We need space, tab and new line, in precisely that order. Quoting is # there to prevent editors from complaining about space-tab. # (If _AS_PATH_WALK were called with IFS unset, it would disable word # splitting by setting IFS to empty value.) IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. case $0 in #(( *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. 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 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 exit 1 fi # Unset variables that we do not need and which cause bugs (e.g. in # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" # suppresses any "Segmentation fault" message there. '((' could # trigger a bug in pdksh 5.2.14. for as_var in BASH_ENV ENV MAIL MAILPATH do eval test x\${$as_var+set} = xset \ && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : done PS1='$ ' PS2='> ' PS4='+ ' # NLS nuisances. LC_ALL=C export LC_ALL LANGUAGE=C export LANGUAGE # CDPATH. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH # as_fn_error 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=$?; test $as_status -eq 0 && as_status=1 if test "$3"; then as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3 fi $as_echo "$as_me: error: $1" >&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_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_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 || $as_echo 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 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 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 -p'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || as_ln_s='cp -p' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else as_ln_s='cp -p' fi else as_ln_s='cp -p' 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=`$as_echo "$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 || $as_echo 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 if test -x / >/dev/null 2>&1; then as_test_x='test -x' else if ls -dL / >/dev/null 2>&1; then as_ls_L_option=L else as_ls_L_option= fi as_test_x=' eval sh -c '\'' if test -d "$1"; then test -d "$1/."; else case $1 in #( -*)set "./$1";; esac; case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( ???[sx]*):;;*)false;;esac;fi '\'' sh ' fi as_executable_p=$as_test_x # 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 $as_me, which was generated by GNU Autoconf 2.64. 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 -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 the package provider." _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_version="\\ config.status configured by $0, generated by GNU Autoconf 2.64, with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\" Copyright (C) 2009 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=$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 ) $as_echo "$ac_cs_version"; exit ;; --debug | --debu | --deb | --de | --d | -d ) debug=: ;; --file | --fil | --fi | --f ) $ac_shift case $ac_optarg in *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; esac as_fn_append CONFIG_FILES " '$ac_optarg'" ac_need_defaults=false;; --header | --heade | --head | --hea ) $ac_shift case $ac_optarg in *\'*) ac_optarg=`$as_echo "$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 ) $as_echo "$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 \$as_echo "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 $as_echo "$ac_log" } >&5 _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 # # INIT-COMMANDS # AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" _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" ;; "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; "bar.1") CONFIG_FILES="$CONFIG_FILES bar.1" ;; "doxygen.conf") CONFIG_FILES="$CONFIG_FILES doxygen.conf" ;; "test-script-preparation") CONFIG_COMMANDS="$CONFIG_COMMANDS test-script-preparation" ;; *) 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+set}" = set || CONFIG_FILES=$config_files test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers test "${CONFIG_COMMANDS+set}" = set || 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= trap 'exit_status=$? { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$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 -n "$tmp" && test -d "$tmp" } || { tmp=./conf$$-$RANDOM (umask 077 && mkdir "$tmp") } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5 # 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 {' >"$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 >>"\$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 >>"\$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 < "$tmp/subs1.awk" > "$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 $(srcdir), # ${srcdir} and @srcdir@ 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[ ]*=/{ s/:*\$(srcdir):*/:/ s/:*\${srcdir}:*/:/ s/:*@srcdir@:*/:/ s/^\([^=]*=[ ]*\):*/\1/ s/:*$// 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 >"$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_t=`sed -n "/$ac_delim/p" confdefs.h` if test -z "$ac_t"; 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="$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 "cannot find input file: \`$ac_f'" "$LINENO" 5;; esac case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac as_fn_append ac_file_inputs " '$ac_f'" 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 '` $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' `' by configure.' if test x"$ac_file" != x-; then configure_input="$ac_file. $configure_input" { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 $as_echo "$as_me: creating $ac_file" >&6;} fi # Neutralize special characters interpreted by sed in replacement strings. case $configure_input in #( *\&* | *\|* | *\\* ) ac_sed_conf_input=`$as_echo "$configure_input" | sed 's/[\\\\&|]/\\\\&/g'`;; #( *) ac_sed_conf_input=$configure_input;; esac case $ac_tag in *:-:* | *:-) cat >"$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 || $as_echo 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=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` # A ".." for each directory in $ac_dir_suffix. ac_top_builddir_sub=`$as_echo "$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@*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 $as_echo "$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 "$tmp/subs.awk" >$tmp/out \ || as_fn_error "could not create $ac_file" "$LINENO" 5 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } && { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } && { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' which seems to be undefined. Please make sure it is defined." >&5 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' which seems to be undefined. Please make sure it is defined." >&2;} rm -f "$tmp/stdin" case $ac_file in -) cat "$tmp/out" && rm -f "$tmp/out";; *) rm -f "$ac_file" && mv "$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 { $as_echo "/* $configure_input */" \ && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" } >"$tmp/config.h" \ || as_fn_error "could not create $ac_file" "$LINENO" 5 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 $as_echo "$as_me: $ac_file is unchanged" >&6;} else rm -f "$ac_file" mv "$tmp/config.h" "$ac_file" \ || as_fn_error "could not create $ac_file" "$LINENO" 5 fi else $as_echo "/* $configure_input */" \ && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \ || 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 || $as_echo 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) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 $as_echo "$as_me: executing $ac_file commands" >&6;} ;; esac case $ac_file$ac_mode in "depfiles":C) test x"$AMDEP_TRUE" != x"" || { # Autoconf 2.62 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. case $CONFIG_FILES in *\'*) eval set x "$CONFIG_FILES" ;; *) set x $CONFIG_FILES ;; esac shift for mf do # Strip MF so we end up with the name of the file. mf=`echo "$mf" | sed -e 's/:.*$//'` # Check whether this is an Automake generated Makefile or not. # We used to match only the files named `Makefile.in', but # some people rename them; so instead we look at the file content. # Grep'ing the first line is not enough: some people post-process # each Makefile.in and add a new line on top of each file to say so. # Grep'ing the whole file is not good either: AIX grep has a line # limit of 2048, but all sed's we know have understand at least 4000. if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then dirpart=`$as_dirname -- "$mf" || $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$mf" : 'X\(//\)[^/]' \| \ X"$mf" : 'X\(//\)$' \| \ X"$mf" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$mf" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` else continue fi # Extract the definition of DEPDIR, am__include, and am__quote # from the Makefile without running `make'. DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` test -z "$DEPDIR" && continue am__include=`sed -n 's/^am__include = //p' < "$mf"` test -z "am__include" && continue am__quote=`sed -n 's/^am__quote = //p' < "$mf"` # When using ansi2knr, U may be empty or an underscore; expand it U=`sed -n 's/^U = //p' < "$mf"` # Find all dependency output files, they are included files with # $(DEPDIR) in their names. We invoke sed twice because it is the # simplest approach to changing $(DEPDIR) to its actual value in the # expansion. for file in `sed -n " s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do # Make sure the directory exists. test -f "$dirpart/$file" && continue fdir=`$as_dirname -- "$file" || $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$file" : 'X\(//\)[^/]' \| \ X"$file" : 'X\(//\)$' \| \ X"$file" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$file" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` as_dir=$dirpart/$fdir; as_fn_mkdir_p # echo "creating $dirpart/$file" echo '# dummy' > "$dirpart/$file" done done } ;; "test-script-preparation":C) chmod u+x test-00? ;; 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 $? fi if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} fi { $as_echo "$as_me:${as_lineno-$LINENO}: " >&5 $as_echo "$as_me: " >&6;} { $as_echo "$as_me:${as_lineno-$LINENO}: Current Configuration:" >&5 $as_echo "$as_me: Current Configuration:" >&6;} { $as_echo "$as_me:${as_lineno-$LINENO}: ----------------------" >&5 $as_echo "$as_me: ----------------------" >&6;} if test "${ac_cv_default_sw_minus_one}" -eq 1; then { $as_echo "$as_me:${as_lineno-$LINENO}: Screen width -1 modifier: yes" >&5 $as_echo "$as_me: Screen width -1 modifier: yes" >&6;} else { $as_echo "$as_me:${as_lineno-$LINENO}: Screen width -1 modifier: no" >&5 $as_echo "$as_me: Screen width -1 modifier: no" >&6;} fi if test "${ac_cv_default_sh_minus_one}" -eq 1; then { $as_echo "$as_me:${as_lineno-$LINENO}: Screen height -1 modifier: yes" >&5 $as_echo "$as_me: Screen height -1 modifier: yes" >&6;} else { $as_echo "$as_me:${as_lineno-$LINENO}: Screen height -1 modifier: no" >&5 $as_echo "$as_me: Screen height -1 modifier: no" >&6;} fi if test "${ac_cv_default_display_twiddle}" -eq 1; then { $as_echo "$as_me:${as_lineno-$LINENO}: Display twiddle by default: yes" >&5 $as_echo "$as_me: Display twiddle by default: yes" >&6;} else { $as_echo "$as_me:${as_lineno-$LINENO}: Display twiddle by default: no" >&5 $as_echo "$as_me: Display twiddle by default: no" >&6;} fi if test "${ac_cv_use_memalign}" = "yes"; then { $as_echo "$as_me:${as_lineno-$LINENO}: Use aligned memory allocation: $ac_cv_use_memalign (default page size: $ac_cv_default_page_size)" >&5 $as_echo "$as_me: Use aligned memory allocation: $ac_cv_use_memalign (default page size: $ac_cv_default_page_size)" >&6;} else { $as_echo "$as_me:${as_lineno-$LINENO}: Use aligned memory allocation: $ac_cv_use_memalign" >&5 $as_echo "$as_me: Use aligned memory allocation: $ac_cv_use_memalign" >&6;} fi { $as_echo "$as_me:${as_lineno-$LINENO}: Use vectored I/O: $ac_cv_use_iovec" >&5 $as_echo "$as_me: Use vectored I/O: $ac_cv_use_iovec" >&6;} { $as_echo "$as_me:${as_lineno-$LINENO}: Default I/O buffer size: $ac_cv_default_buffer_size" >&5 $as_echo "$as_me: Default I/O buffer size: $ac_cv_default_buffer_size" >&6;} { $as_echo "$as_me:${as_lineno-$LINENO}: Install Path: $prefix" >&5 $as_echo "$as_me: Install Path: $prefix" >&6;} { $as_echo "$as_me:${as_lineno-$LINENO}: " >&5 $as_echo "$as_me: " >&6;} bar-1.11.1.orig/itest0000754000175000017500000000021410510504276014546 0ustar georgeskgeorgesk#!/bin/sh dd if=/dev/zero bs=1024 count=102400 \ | ./bar -s 102400k \ | dd of=./test-file-i.bin ./bar -if ./test-file-i.bin -of /dev/null bar-1.11.1.orig/missing0000754000175000017500000002123110510504276015071 0ustar georgeskgeorgesk#! /bin/sh # Common stub for a few missing GNU programs while installing. # Copyright 1996, 1997, 1999, 2000 Free Software Foundation, Inc. # Originally 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, write to the Free Software # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA # 02111-1307, USA. # 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 run=: # In the cases where this matters, `missing' is being run in the # srcdir already. if test -f configure.ac; then configure_ac=configure.ac else configure_ac=configure.in fi case "$1" in --run) # Try to run requested program, and just exit if it succeeds. run= shift "$@" && exit 0 ;; esac # If it does not exist, or fails to run (possibly an outdated version), # try to emulate it. case "$1" in -h|--h|--he|--hel|--help) echo "\ $0 [OPTION]... PROGRAM [ARGUMENT]... Handle \`PROGRAM [ARGUMENT]...' for when PROGRAM is missing, or return an error status if there is no known handling for PROGRAM. Options: -h, --help display this help and exit -v, --version output version information and exit --run try to run the given command, and emulate it if it fails Supported PROGRAM values: aclocal touch file \`aclocal.m4' autoconf touch file \`configure' autoheader touch file \`config.h.in' automake touch all \`Makefile.in' files bison create \`y.tab.[ch]', if possible, from existing .[ch] flex create \`lex.yy.c', if possible, from existing .c help2man touch the output file lex create \`lex.yy.c', if possible, from existing .c makeinfo touch the output file tar try tar, gnutar, gtar, then tar without non-portable flags yacc create \`y.tab.[ch]', if possible, from existing .[ch]" ;; -v|--v|--ve|--ver|--vers|--versi|--versio|--version) echo "missing 0.3 - GNU automake" ;; -*) echo 1>&2 "$0: Unknown \`$1' option" echo 1>&2 "Try \`$0 --help' for more information" exit 1 ;; aclocal) echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if you modified \`acinclude.m4' or \`${configure_ac}'. You might want to install the \`Automake' and \`Perl' packages. Grab them from any GNU archive site." touch aclocal.m4 ;; autoconf) echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if you modified \`${configure_ac}'. You might want to install the \`Autoconf' and \`GNU m4' packages. Grab them from any GNU archive site." touch configure ;; autoheader) echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if you modified \`acconfig.h' or \`${configure_ac}'. You might want to install the \`Autoconf' and \`GNU m4' packages. Grab them from any GNU archive site." files=`sed -n 's/^[ ]*A[CM]_CONFIG_HEADER(\([^)]*\)).*/\1/p' ${configure_ac}` test -z "$files" && files="config.h" touch_files= for f in $files; do case "$f" in *:*) touch_files="$touch_files "`echo "$f" | sed -e 's/^[^:]*://' -e 's/:.*//'`;; *) touch_files="$touch_files $f.in";; esac done touch $touch_files ;; automake) echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if you modified \`Makefile.am', \`acinclude.m4' or \`${configure_ac}'. You might want to install the \`Automake' and \`Perl' packages. Grab them from any GNU archive site." find . -type f -name Makefile.am -print | sed 's/\.am$/.in/' | while read f; do touch "$f"; done ;; bison|yacc) echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if you modified a \`.y' file. You may need the \`Bison' package in order for those modifications to take effect. You can get \`Bison' from any GNU archive site." rm -f y.tab.c y.tab.h if [ $# -ne 1 ]; then eval LASTARG="\${$#}" case "$LASTARG" in *.y) SRCFILE=`echo "$LASTARG" | sed 's/y$/c/'` if [ -f "$SRCFILE" ]; then cp "$SRCFILE" y.tab.c fi SRCFILE=`echo "$LASTARG" | sed 's/y$/h/'` if [ -f "$SRCFILE" ]; then cp "$SRCFILE" y.tab.h fi ;; esac fi if [ ! -f y.tab.h ]; then echo >y.tab.h fi if [ ! -f y.tab.c ]; then echo 'main() { return 0; }' >y.tab.c fi ;; lex|flex) echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if you modified a \`.l' file. You may need the \`Flex' package in order for those modifications to take effect. You can get \`Flex' from any GNU archive site." rm -f lex.yy.c if [ $# -ne 1 ]; then eval LASTARG="\${$#}" case "$LASTARG" in *.l) SRCFILE=`echo "$LASTARG" | sed 's/l$/c/'` if [ -f "$SRCFILE" ]; then cp "$SRCFILE" lex.yy.c fi ;; esac fi if [ ! -f lex.yy.c ]; then echo 'main() { return 0; }' >lex.yy.c fi ;; help2man) echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if you modified a dependency of a manual page. You may need the \`Help2man' package in order for those modifications to take effect. You can get \`Help2man' from any GNU archive site." file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'` if test -z "$file"; then file=`echo "$*" | sed -n 's/.*--output=\([^ ]*\).*/\1/p'` fi if [ -f "$file" ]; then touch $file else test -z "$file" || exec >$file echo ".ab help2man is required to generate this page" exit 1 fi ;; makeinfo) if test -z "$run" && (makeinfo --version) > /dev/null 2>&1; then # We have makeinfo, but it failed. exit 1 fi echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if you modified a \`.texi' or \`.texinfo' file, or any other file indirectly affecting the aspect of the manual. The spurious call might also be the consequence of using a buggy \`make' (AIX, DU, IRIX). You might want to install the \`Texinfo' package or the \`GNU make' package. Grab either from any GNU archive site." file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'` if test -z "$file"; then file=`echo "$*" | sed 's/.* \([^ ]*\) *$/\1/'` file=`sed -n '/^@setfilename/ { s/.* \([^ ]*\) *$/\1/; p; q; }' $file` fi touch $file ;; tar) shift if test -n "$run"; then echo 1>&2 "ERROR: \`tar' requires --run" exit 1 fi # We have already tried tar in the generic part. # Look for gnutar/gtar before invocation to avoid ugly error # messages. if (gnutar --version > /dev/null 2>&1); then gnutar ${1+"$@"} && exit 0 fi if (gtar --version > /dev/null 2>&1); then gtar ${1+"$@"} && exit 0 fi firstarg="$1" if shift; then case "$firstarg" in *o*) firstarg=`echo "$firstarg" | sed s/o//` tar "$firstarg" ${1+"$@"} && exit 0 ;; esac case "$firstarg" in *h*) firstarg=`echo "$firstarg" | sed s/h//` tar "$firstarg" ${1+"$@"} && exit 0 ;; esac fi echo 1>&2 "\ WARNING: I can't seem to be able to run \`tar' with the given arguments. You may want to install GNU tar or Free paxutils, or check the command line arguments." exit 1 ;; *) echo 1>&2 "\ WARNING: \`$1' is needed, and you do not seem to have it handy on your system. You might have modified some files without having the proper tools for further handling them. Check the \`README' file, it often tells you about the needed prerequirements for installing this package. You may also peek at any GNU archive site, in case some other package would contain this missing \`$1' program." exit 1 ;; esac exit 0 bar-1.11.1.orig/test-0010000754000175000017500000000015311541660133014675 0ustar georgeskgeorgesk#!/bin/sh ./test-001-pre | ./bar 2> /dev/null | ./test-001-post if [ "$?" -ne 0 ]; then exit 1; fi exit 0 bar-1.11.1.orig/install-sh0000754000175000017500000001273610510504276015510 0ustar georgeskgeorgesk#!/bin/sh # # install - install a program, script, or datafile # This comes from X11R5 (mit/util/scripts/install.sh). # # Copyright 1991 by the Massachusetts Institute of Technology # # Permission to use, copy, modify, distribute, and sell this software and its # documentation for any purpose is hereby granted without fee, provided that # the above copyright notice appear in all copies and that both that # copyright notice and this permission notice appear in supporting # documentation, and that the name of M.I.T. not be used in advertising or # publicity pertaining to distribution of the software without specific, # written prior permission. M.I.T. makes no representations about the # suitability of this software for any purpose. It is provided "as is" # without express or implied warranty. # # 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. It can only install one file at a time, a restriction # shared with many OS's install programs. # set DOITPROG to echo to test this script # Don't use :- since 4.3BSD and earlier shells don't like it. doit="${DOITPROG-}" # put in absolute paths if you don't have them in your path; or use env. vars. mvprog="${MVPROG-mv}" cpprog="${CPPROG-cp}" chmodprog="${CHMODPROG-chmod}" chownprog="${CHOWNPROG-chown}" chgrpprog="${CHGRPPROG-chgrp}" stripprog="${STRIPPROG-strip}" rmprog="${RMPROG-rm}" mkdirprog="${MKDIRPROG-mkdir}" transformbasename="" transform_arg="" instcmd="$mvprog" chmodcmd="$chmodprog 0755" chowncmd="" chgrpcmd="" stripcmd="" rmcmd="$rmprog -f" mvcmd="$mvprog" src="" dst="" dir_arg="" while [ x"$1" != x ]; do case $1 in -c) instcmd="$cpprog" shift continue;; -d) dir_arg=true shift continue;; -m) chmodcmd="$chmodprog $2" shift shift continue;; -o) chowncmd="$chownprog $2" shift shift continue;; -g) chgrpcmd="$chgrpprog $2" shift shift continue;; -s) stripcmd="$stripprog" shift continue;; -t=*) transformarg=`echo $1 | sed 's/-t=//'` shift continue;; -b=*) transformbasename=`echo $1 | sed 's/-b=//'` shift continue;; *) if [ x"$src" = x ] then src=$1 else # this colon is to work around a 386BSD /bin/sh bug : dst=$1 fi shift continue;; esac done if [ x"$src" = x ] then echo "install: no input file specified" exit 1 else true fi if [ x"$dir_arg" != x ]; then dst=$src src="" if [ -d $dst ]; then instcmd=: chmodcmd="" else instcmd=mkdir fi else # Waiting for this to be detected by the "$instcmd $src $dsttmp" command # might cause directories to be created, which would be especially bad # if $src (and thus $dsttmp) contains '*'. if [ -f $src -o -d $src ] then true else echo "install: $src does not exist" exit 1 fi if [ x"$dst" = x ] then echo "install: no destination specified" exit 1 else true fi # If destination is a directory, append the input filename; if your system # does not like double slashes in filenames, you may need to add some logic if [ -d $dst ] then dst="$dst"/`basename $src` else true fi fi ## this sed command emulates the dirname command dstdir=`echo $dst | sed -e 's,[^/]*$,,;s,/$,,;s,^$,.,'` # Make sure that the destination directory exists. # this part is taken from Noah Friedman's mkinstalldirs script # Skip lots of stat calls in the usual case. if [ ! -d "$dstdir" ]; then defaultIFS=' ' IFS="${IFS-${defaultIFS}}" oIFS="${IFS}" # Some sh's can't handle IFS=/ for some reason. IFS='%' set - `echo ${dstdir} | sed -e 's@/@%@g' -e 's@^%@/@'` IFS="${oIFS}" pathcomp='' while [ $# -ne 0 ] ; do pathcomp="${pathcomp}${1}" shift if [ ! -d "${pathcomp}" ] ; then $mkdirprog "${pathcomp}" else true fi pathcomp="${pathcomp}/" done fi if [ x"$dir_arg" != x ] then $doit $instcmd $dst && if [ x"$chowncmd" != x ]; then $doit $chowncmd $dst; else true ; fi && if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dst; else true ; fi && if [ x"$stripcmd" != x ]; then $doit $stripcmd $dst; else true ; fi && if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dst; else true ; fi else # If we're going to rename the final executable, determine the name now. if [ x"$transformarg" = x ] then dstfile=`basename $dst` else dstfile=`basename $dst $transformbasename | sed $transformarg`$transformbasename fi # don't allow the sed command to completely eliminate the filename if [ x"$dstfile" = x ] then dstfile=`basename $dst` else true fi # Make a temp file name in the proper directory. dsttmp=$dstdir/#inst.$$# # Move or copy the file name to the temp name $doit $instcmd $src $dsttmp && trap "rm -f ${dsttmp}" 0 && # 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 $instcmd $src $dsttmp" command. if [ x"$chowncmd" != x ]; then $doit $chowncmd $dsttmp; else true;fi && if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dsttmp; else true;fi && if [ x"$stripcmd" != x ]; then $doit $stripcmd $dsttmp; else true;fi && if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dsttmp; else true;fi && # Now rename the file to the real destination. $doit $rmcmd -f $dstdir/$dstfile && $doit $mvcmd $dsttmp $dstdir/$dstfile fi && exit 0 bar-1.11.1.orig/infofile0000644000175000017500000000217710711651144015221 0ustar georgeskgeorgeskHello world! This is an information file used by bar to print useful stuff while your data is copied. This line should be the last line shown for now. @@@ Hello again! this is yet another entry in the info file. @@@ If you want to create your own information file, simply pass --info-file to bar on the command line. Inside your information file, have a few little tidbits of information separated by lines that contain only three '@' characters. (The "@@@" string, on a line by itself, with no leading or trailing characters, is a delimiter that bar looks for when printing information. It tells bar that the end of the current tidbit of information has been reached, and the text that follows is the begining of the next information tidbit.) @@@ And that's it! Well, not quite. Since now bar needs to know the height of the terminal we well as the width, there are some height-specific command line and rc-file options that have been added. In addition to -sw and --screen-width, there are now corresponding -sh and --screen-height command line and rc-file options. ...And now that's it. Enjoy the rest of your day. bar-1.11.1.orig/bar.c0000644000175000017500000000253611541656117014421 0ustar georgeskgeorgesk#include "config.h" #include "headers.h" #include "types.h" #include "error.h" #include "fd.h" #include "io.h" #include "display.h" #include "args.h" /** \mainpage Command Line Progress Bar Bar is a simple tool to copy a stream of data from input to output while displaying for the user: \li The amount of data passed \li The throughput of the data transfer and, if the total size of the data stream is known: \li The estimated time remaining \li What percent of the data stream has been copied \li A progress bar Bar was originally written for the purpose of estimating the amount of time needed to transfer large amounts (many, many gigabytes) of data across a network in a tar/ssh pipe. */ int main(int argc, char *argv[]) { int rval = 0; #ifdef DEBUG int debug = 1; fprintf(stderr, "Waiting for debugger to attach...\n"); while (debug); #endif if (ioInit() != 0) return(1); if (displayInit() != 0) return(1); if (parse_rcfiles(stderr) != 0) return(1); if (parse_args(stderr, argc, argv) != 0) return(1); if (ioBegin() != 0) return(1); if (displayBegin() != 0) return(1); while (!ioIsDone()) { ioCheck(); if (ioRead() < 0) { print_error(stderr, "read error"); rval = 1; break; } if (ioWrite() < 0) { print_error(stderr, "write error"); rval = 1; break; } displayUpdate(); } displayEnd(); ioEnd(); return(rval); } bar-1.11.1.orig/config.h.in0000644000175000017500000001176511541656163015541 0ustar georgeskgeorgesk/* config.h.in. Generated from configure.in by autoheader. */ /* Use this default buffer size */ #undef DEFAULT_BUFFER_SIZE /* Default twiddle display setting */ #undef DEFAULT_DISPLAY_TWIDDLE /* Use this default page size if cannot determine through sysconf */ #undef DEFAULT_PAGE_SIZE /* Use a screen height adjustment of -1 by default */ #undef DEFAULT_SH_MINUS_ONE /* Use a screen width adjustment of -1 by default */ #undef DEFAULT_SW_MINUS_ONE /* Define to 1 if you have the header file. */ #undef HAVE_ASSERT_H /* Define to 1 if you have the header file. */ #undef HAVE_CTYPE_H /* Define to 1 if you have the declaration of `_SC_PAGESIZE', and to 0 if you don't. */ #undef HAVE_DECL__SC_PAGESIZE /* Define to 1 if you have the declaration of `_SC_PAGE_SIZE', and to 0 if you don't. */ #undef HAVE_DECL__SC_PAGE_SIZE /* Define to 1 if you have the header file. */ #undef HAVE_ERRNO_H /* Define if we can count to 1E */ #undef HAVE_EXABYTE_SUPPORT /* Define to 1 if you have the header file. */ #undef HAVE_FCNTL_H /* Define to 1 if you have the header file. */ #undef HAVE_INTTYPES_H /* Define to 1 if your system has a GNU libc compatible `malloc' function, and to 0 otherwise. */ #undef HAVE_MALLOC /* Define to 1 if you have the header file. */ #undef HAVE_MALLOC_H /* Define to 1 if you have the header file. */ #undef HAVE_MEMORY_H /* Define if we can count to 1P */ #undef HAVE_PETABYTE_SUPPORT /* Define to 1 if you have the `posix_memalign' function. */ #undef HAVE_POSIX_MEMALIGN /* Define to 1 if you have the `select' function. */ #undef HAVE_SELECT /* Define to 1 if you have the header file. */ #undef HAVE_SIGNAL_H /* Define to 1 if you have the `sprintf' function. */ #undef HAVE_SPRINTF /* Define to 1 if you have the header file. */ #undef HAVE_STDARG_H /* 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 `strerror' function. */ #undef HAVE_STRERROR /* 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 /* Define if struct iovec found */ #undef HAVE_STRUCT_IOVEC /* Define to 1 if you have the `sysconf' function. */ #undef HAVE_SYSCONF /* Define to 1 if you have the header file. */ #undef HAVE_SYS_IOCTL_H /* Define to 1 if you have the header file. */ #undef HAVE_SYS_SELECT_H /* 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_TIME_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_SYS_UIO_H /* Define if we can count to 1T */ #undef HAVE_TERABYTE_SUPPORT /* Define to 1 if you have the header file. */ #undef HAVE_TERMIOS_H /* Define to 1 if you have the header file. */ #undef HAVE_UNISTD_H /* Use this as the maximum safe multiplier value for safe_mul() */ #undef MAX_SAFE_MULTIPLIER /* 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 /* The size of `size_t', as computed by sizeof. */ #undef SIZEOF_SIZE_T /* The size of `unsigned char', as computed by sizeof. */ #undef SIZEOF_UNSIGNED_CHAR /* The size of `unsigned int', as computed by sizeof. */ #undef SIZEOF_UNSIGNED_INT /* The size of `unsigned long', as computed by sizeof. */ #undef SIZEOF_UNSIGNED_LONG /* The size of `unsigned long long', as computed by sizeof. */ #undef SIZEOF_UNSIGNED_LONG_LONG /* The size of `unsigned short', as computed by sizeof. */ #undef SIZEOF_UNSIGNED_SHORT /* Define to 1 if you have the ANSI C header files. */ #undef STDC_HEADERS /* Define to 1 if you can safely include both and . */ #undef TIME_WITH_SYS_TIME /* Use vectored I/O (if available) */ #undef USE_IOVEC /* Use aligned memory allocation (if available) */ #undef USE_MEMALIGN /* Version number of package */ #undef VERSION /* Define if OS needs it for Large Files */ #undef _FILE_OFFSET_BITS /* Define if posix_memalign needs _GNU_SOURCE */ #undef _GNU_SOURCE /* Define if OS needs it for Large Files */ #undef _LARGE_FILES /* Define if posix_memalign needs _XOPEN_SOURCE >= 600 */ #undef _XOPEN_SOURCE /* Define to rpl_malloc if the replacement function should be used. */ #undef malloc bar-1.11.1.orig/config.guess0000754000175000017500000011302010510504276016010 0ustar georgeskgeorgesk#! /bin/sh # Attempt to guess a canonical system name. # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001 # Free Software Foundation, Inc. timestamp='2001-08-21' # 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 2 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, write to the Free Software # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. # # 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. # Written by Per Bothner . # Please send patches to . # # This script attempts to guess a canonical system name similar to # config.sub. If it succeeds, it prints the system name on stdout, and # exits with 0. Otherwise, it exits with 1. # # The plan is that this can be called by configure scripts if you # don't specify an explicit build system type. me=`echo "$0" | sed -e 's,.*/,,'` usage="\ Usage: $0 [OPTION] Output the configuration name of the system \`$me' is run on. Operation modes: -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 (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001 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 0 ;; --version | -v ) echo "$version" ; exit 0 ;; --help | --h* | -h ) echo "$usage"; exit 0 ;; -- ) # 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 dummy=dummy-$$ trap 'rm -f $dummy.c $dummy.o $dummy.rel $dummy; exit 1' 1 2 15 # CC_FOR_BUILD -- compiler used by this script. # Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still # use `HOST_CC' if defined, but it is deprecated. set_cc_for_build='case $CC_FOR_BUILD,$HOST_CC,$CC in ,,) echo "int dummy(){}" > $dummy.c ; for c in cc gcc c89 ; do ($c $dummy.c -c -o $dummy.o) >/dev/null 2>&1 ; if test $? = 0 ; then CC_FOR_BUILD="$c"; break ; fi ; done ; rm -f $dummy.c $dummy.o $dummy.rel ; 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) >/dev/null 2>&1 ; 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 # 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 tupples: *-*-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. # Determine the machine/vendor (is the vendor relevant). case "${UNAME_MACHINE}" in amiga) machine=m68k-unknown ;; arm32) machine=arm-unknown ;; atari*) machine=m68k-atari ;; sun3*) machine=m68k-sun ;; mac68k) machine=m68k-apple ;; macppc) machine=powerpc-apple ;; hp3[0-9][05]) machine=m68k-hp ;; ibmrt|romp-ibm) machine=romp-ibm ;; *) machine=${UNAME_MACHINE}-unknown ;; esac # The Operating System including object format, if it has switched # to ELF recently, or will in the future. case "${UNAME_MACHINE}" in i386|sparc|amiga|arm*|hp300|mvme68k|vax|atari|luna68k|mac68k|news68k|next68k|pc532|sun3*|x68k) eval $set_cc_for_build if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ | grep __ELF__ >/dev/null 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 # The OS release release=`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'` # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM: # contains redundant information, the shorter form: # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. echo "${machine}-${os}${release}" exit 0 ;; alpha:OSF1:*:*) if test $UNAME_RELEASE = "V4.0"; then UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` fi # 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. cat <$dummy.s .data \$Lformat: .byte 37,100,45,37,120,10,0 # "%d-%x\n" .text .globl main .align 4 .ent main main: .frame \$30,16,\$26,0 ldgp \$29,0(\$27) .prologue 1 .long 0x47e03d80 # implver \$0 lda \$2,-1 .long 0x47e20c21 # amask \$2,\$1 lda \$16,\$Lformat mov \$0,\$17 not \$1,\$18 jsr \$26,printf ldgp \$29,0(\$26) mov 0,\$16 jsr \$26,exit .end main EOF eval $set_cc_for_build $CC_FOR_BUILD $dummy.s -o $dummy 2>/dev/null if test "$?" = 0 ; then case `./$dummy` in 0-0) UNAME_MACHINE="alpha" ;; 1-0) UNAME_MACHINE="alphaev5" ;; 1-1) UNAME_MACHINE="alphaev56" ;; 1-101) UNAME_MACHINE="alphapca56" ;; 2-303) UNAME_MACHINE="alphaev6" ;; 2-307) UNAME_MACHINE="alphaev67" ;; 2-1307) UNAME_MACHINE="alphaev68" ;; esac fi rm -f $dummy.s $dummy echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[VTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` exit 0 ;; Alpha\ *:Windows_NT*:*) # How do we know it's Interix rather than the generic POSIX subsystem? # Should we change UNAME_MACHINE based on the output of uname instead # of the specific Alpha model? echo alpha-pc-interix exit 0 ;; 21064:Windows_NT:50:3) echo alpha-dec-winnt3.5 exit 0 ;; Amiga*:UNIX_System_V:4.0:*) echo m68k-unknown-sysv4 exit 0;; amiga:OpenBSD:*:*) echo m68k-unknown-openbsd${UNAME_RELEASE} exit 0 ;; *:[Aa]miga[Oo][Ss]:*:*) echo ${UNAME_MACHINE}-unknown-amigaos exit 0 ;; arc64:OpenBSD:*:*) echo mips64el-unknown-openbsd${UNAME_RELEASE} exit 0 ;; arc:OpenBSD:*:*) echo mipsel-unknown-openbsd${UNAME_RELEASE} exit 0 ;; hkmips:OpenBSD:*:*) echo mips-unknown-openbsd${UNAME_RELEASE} exit 0 ;; pmax:OpenBSD:*:*) echo mipsel-unknown-openbsd${UNAME_RELEASE} exit 0 ;; sgi:OpenBSD:*:*) echo mips-unknown-openbsd${UNAME_RELEASE} exit 0 ;; wgrisc:OpenBSD:*:*) echo mipsel-unknown-openbsd${UNAME_RELEASE} exit 0 ;; *:OS/390:*:*) echo i370-ibm-openedition exit 0 ;; arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) echo arm-acorn-riscix${UNAME_RELEASE} exit 0;; SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*) echo hppa1.1-hitachi-hiuxmpp exit 0;; Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*) # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE. if test "`(/bin/universe) 2>/dev/null`" = att ; then echo pyramid-pyramid-sysv3 else echo pyramid-pyramid-bsd fi exit 0 ;; NILE*:*:*:dcosx) echo pyramid-pyramid-svr4 exit 0 ;; sun4H:SunOS:5.*:*) echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit 0 ;; sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit 0 ;; i86pc:SunOS:5.*:*) echo i386-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit 0 ;; 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. echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit 0 ;; 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'. echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'` exit 0 ;; sun3*:SunOS:*:*) echo m68k-sun-sunos${UNAME_RELEASE} exit 0 ;; sun*:*:4.2BSD:*) UNAME_RELEASE=`(head -1 /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null` test "x${UNAME_RELEASE}" = "x" && UNAME_RELEASE=3 case "`/bin/arch`" in sun3) echo m68k-sun-sunos${UNAME_RELEASE} ;; sun4) echo sparc-sun-sunos${UNAME_RELEASE} ;; esac exit 0 ;; aushp:SunOS:*:*) echo sparc-auspex-sunos${UNAME_RELEASE} exit 0 ;; sparc*:NetBSD:*) echo `uname -p`-unknown-netbsd${UNAME_RELEASE} exit 0 ;; atari*:OpenBSD:*:*) echo m68k-unknown-openbsd${UNAME_RELEASE} exit 0 ;; # 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:*:*) echo m68k-atari-mint${UNAME_RELEASE} exit 0 ;; atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) echo m68k-atari-mint${UNAME_RELEASE} exit 0 ;; *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) echo m68k-atari-mint${UNAME_RELEASE} exit 0 ;; milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) echo m68k-milan-mint${UNAME_RELEASE} exit 0 ;; hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) echo m68k-hades-mint${UNAME_RELEASE} exit 0 ;; *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) echo m68k-unknown-mint${UNAME_RELEASE} exit 0 ;; sun3*:OpenBSD:*:*) echo m68k-unknown-openbsd${UNAME_RELEASE} exit 0 ;; mac68k:OpenBSD:*:*) echo m68k-unknown-openbsd${UNAME_RELEASE} exit 0 ;; mvme68k:OpenBSD:*:*) echo m68k-unknown-openbsd${UNAME_RELEASE} exit 0 ;; mvme88k:OpenBSD:*:*) echo m88k-unknown-openbsd${UNAME_RELEASE} exit 0 ;; powerpc:machten:*:*) echo powerpc-apple-machten${UNAME_RELEASE} exit 0 ;; RISC*:Mach:*:*) echo mips-dec-mach_bsd4.3 exit 0 ;; RISC*:ULTRIX:*:*) echo mips-dec-ultrix${UNAME_RELEASE} exit 0 ;; VAX*:ULTRIX*:*:*) echo vax-dec-ultrix${UNAME_RELEASE} exit 0 ;; 2020:CLIX:*:* | 2430:CLIX:*:*) echo clipper-intergraph-clix${UNAME_RELEASE} exit 0 ;; mips:*:*:UMIPS | mips:*:*:RISCos) 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 eval $set_cc_for_build $CC_FOR_BUILD $dummy.c -o $dummy \ && ./$dummy `echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` \ && rm -f $dummy.c $dummy && exit 0 rm -f $dummy.c $dummy echo mips-mips-riscos${UNAME_RELEASE} exit 0 ;; Motorola:PowerMAX_OS:*:*) echo powerpc-motorola-powermax exit 0 ;; Night_Hawk:Power_UNIX:*:*) echo powerpc-harris-powerunix exit 0 ;; m88k:CX/UX:7*:*) echo m88k-harris-cxux7 exit 0 ;; m88k:*:4*:R4*) echo m88k-motorola-sysv4 exit 0 ;; m88k:*:3*:R3*) echo m88k-motorola-sysv3 exit 0 ;; AViiON:dgux:*:*) # DG/UX returns AViiON for all architectures UNAME_PROCESSOR=`/usr/bin/uname -p` if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ] then if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \ [ ${TARGET_BINARY_INTERFACE}x = x ] then echo m88k-dg-dgux${UNAME_RELEASE} else echo m88k-dg-dguxbcs${UNAME_RELEASE} fi else echo i586-dg-dgux${UNAME_RELEASE} fi exit 0 ;; M88*:DolphinOS:*:*) # DolphinOS (SVR3) echo m88k-dolphin-sysv3 exit 0 ;; M88*:*:R3*:*) # Delta 88k system running SVR3 echo m88k-motorola-sysv3 exit 0 ;; XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3) echo m88k-tektronix-sysv3 exit 0 ;; Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD) echo m68k-tektronix-bsd exit 0 ;; *:IRIX*:*:*) echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'` exit 0 ;; ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id exit 0 ;; # Note that: echo "'`uname -s`'" gives 'AIX ' i*86:AIX:*:*) echo i386-ibm-aix exit 0 ;; ia64:AIX:*:*) if [ -x /usr/bin/oslevel ] ; then IBM_REV=`/usr/bin/oslevel` else IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} fi echo ${UNAME_MACHINE}-ibm-aix${IBM_REV} exit 0 ;; *:AIX:2:3) if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then sed 's/^ //' << EOF >$dummy.c #include main() { if (!__power_pc()) exit(1); puts("powerpc-ibm-aix3.2.5"); exit(0); } EOF eval $set_cc_for_build $CC_FOR_BUILD $dummy.c -o $dummy && ./$dummy && rm -f $dummy.c $dummy && exit 0 rm -f $dummy.c $dummy echo rs6000-ibm-aix3.2.5 elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then echo rs6000-ibm-aix3.2.4 else echo rs6000-ibm-aix3.2 fi exit 0 ;; *:AIX:*:[45]) IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | head -1 | 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 [ -x /usr/bin/oslevel ] ; then IBM_REV=`/usr/bin/oslevel` else IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} fi echo ${IBM_ARCH}-ibm-aix${IBM_REV} exit 0 ;; *:AIX:*:*) echo rs6000-ibm-aix exit 0 ;; ibmrt:4.4BSD:*|romp-ibm:BSD:*) echo romp-ibm-bsd4.4 exit 0 ;; ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to exit 0 ;; # report: romp-ibm BSD 4.3 *:BOSX:*:*) echo rs6000-bull-bosx exit 0 ;; DPX/2?00:B.O.S.:*:*) echo m68k-bull-sysv3 exit 0 ;; 9000/[34]??:4.3bsd:1.*:*) echo m68k-hp-bsd exit 0 ;; hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*) echo m68k-hp-bsd4.4 exit 0 ;; 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]) case "${HPUX_REV}" in 11.[0-9][0-9]) if [ -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" ;; esac ;; esac fi ;; esac if [ "${HP_ARCH}" = "" ]; then 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 eval $set_cc_for_build (CCOPTS= $CC_FOR_BUILD $dummy.c -o $dummy 2>/dev/null ) && HP_ARCH=`./$dummy` if test -z "$HP_ARCH"; then HP_ARCH=hppa; fi rm -f $dummy.c $dummy fi ;; esac echo ${HP_ARCH}-hp-hpux${HPUX_REV} exit 0 ;; ia64:HP-UX:*:*) HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` echo ia64-hp-hpux${HPUX_REV} exit 0 ;; 3050*:HI-UX:*:*) 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 eval $set_cc_for_build $CC_FOR_BUILD $dummy.c -o $dummy && ./$dummy && rm -f $dummy.c $dummy && exit 0 rm -f $dummy.c $dummy echo unknown-hitachi-hiuxwe2 exit 0 ;; 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* ) echo hppa1.1-hp-bsd exit 0 ;; 9000/8??:4.3bsd:*:*) echo hppa1.0-hp-bsd exit 0 ;; *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*) echo hppa1.0-hp-mpeix exit 0 ;; hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* ) echo hppa1.1-hp-osf exit 0 ;; hp8??:OSF1:*:*) echo hppa1.0-hp-osf exit 0 ;; i*86:OSF1:*:*) if [ -x /usr/sbin/sysversion ] ; then echo ${UNAME_MACHINE}-unknown-osf1mk else echo ${UNAME_MACHINE}-unknown-osf1 fi exit 0 ;; parisc*:Lites*:*:*) echo hppa1.1-hp-lites exit 0 ;; hppa*:OpenBSD:*:*) echo hppa-unknown-openbsd exit 0 ;; C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*) echo c1-convex-bsd exit 0 ;; C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*) if getsysinfo -f scalar_acc then echo c32-convex-bsd else echo c2-convex-bsd fi exit 0 ;; C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*) echo c34-convex-bsd exit 0 ;; C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*) echo c38-convex-bsd exit 0 ;; C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*) echo c4-convex-bsd exit 0 ;; CRAY*X-MP:*:*:*) echo xmp-cray-unicos exit 0 ;; CRAY*Y-MP:*:*:*) echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit 0 ;; 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 0 ;; CRAY*TS:*:*:*) echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit 0 ;; CRAY*T3D:*:*:*) echo alpha-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit 0 ;; CRAY*T3E:*:*:*) echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit 0 ;; CRAY*SV1:*:*:*) echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit 0 ;; CRAY-2:*:*:*) echo cray2-cray-unicos exit 0 ;; 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/ /_/'` echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" exit 0 ;; hp300:OpenBSD:*:*) echo m68k-unknown-openbsd${UNAME_RELEASE} exit 0 ;; i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} exit 0 ;; sparc*:BSD/OS:*:*) echo sparc-unknown-bsdi${UNAME_RELEASE} exit 0 ;; *:BSD/OS:*:*) echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} exit 0 ;; *:FreeBSD:*:*) echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` exit 0 ;; *:OpenBSD:*:*) echo ${UNAME_MACHINE}-unknown-openbsd`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'` exit 0 ;; i*:CYGWIN*:*) echo ${UNAME_MACHINE}-pc-cygwin exit 0 ;; i*:MINGW*:*) echo ${UNAME_MACHINE}-pc-mingw32 exit 0 ;; i*:PW*:*) echo ${UNAME_MACHINE}-pc-pw32 exit 0 ;; i*:Windows_NT*:* | Pentium*:Windows_NT*:*) # How do we know it's Interix rather than the generic POSIX subsystem? # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we # UNAME_MACHINE based on the output of uname instead of i386? echo i386-pc-interix exit 0 ;; i*:UWIN*:*) echo ${UNAME_MACHINE}-pc-uwin exit 0 ;; p*:CYGWIN*:*) echo powerpcle-unknown-cygwin exit 0 ;; prep*:SunOS:5.*:*) echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit 0 ;; *:GNU:*:*) echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'` exit 0 ;; i*86:Minix:*:*) echo ${UNAME_MACHINE}-pc-minix exit 0 ;; arm*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit 0 ;; ia64:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux exit 0 ;; m68*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit 0 ;; mips:Linux:*:*) case `sed -n '/^byte/s/^.*: \(.*\) endian/\1/p' < /proc/cpuinfo` in big) echo mips-unknown-linux-gnu && exit 0 ;; little) echo mipsel-unknown-linux-gnu && exit 0 ;; esac ;; ppc:Linux:*:*) echo powerpc-unknown-linux-gnu exit 0 ;; ppc64:Linux:*:*) echo powerpc64-unknown-linux-gnu exit 0 ;; alpha:Linux:*:*) case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` 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 ld.so.1 >/dev/null if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC} exit 0 ;; parisc:Linux:*:* | hppa:Linux:*:*) # Look for CPU level case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in PA7*) echo hppa1.1-unknown-linux-gnu ;; PA8*) echo hppa2.0-unknown-linux-gnu ;; *) echo hppa-unknown-linux-gnu ;; esac exit 0 ;; parisc64:Linux:*:* | hppa64:Linux:*:*) echo hppa64-unknown-linux-gnu exit 0 ;; s390:Linux:*:* | s390x:Linux:*:*) echo ${UNAME_MACHINE}-ibm-linux exit 0 ;; sh*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit 0 ;; sparc:Linux:*:* | sparc64:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit 0 ;; x86_64:Linux:*:*) echo x86_64-unknown-linux-gnu exit 0 ;; i*86:Linux:*:*) # The BFD linker knows what the default object file format is, so # first see if it will tell us. cd to the root directory to prevent # problems with other programs or directories called `ld' in the path. ld_supported_targets=`cd /; ld --help 2>&1 \ | sed -ne '/supported targets:/!d s/[ ][ ]*/ /g s/.*supported targets: *// s/ .*// p'` case "$ld_supported_targets" in elf32-i386) TENTATIVE="${UNAME_MACHINE}-pc-linux-gnu" ;; a.out-i386-linux) echo "${UNAME_MACHINE}-pc-linux-gnuaout" exit 0 ;; coff-i386) echo "${UNAME_MACHINE}-pc-linux-gnucoff" exit 0 ;; "") # Either a pre-BFD a.out linker (linux-gnuoldld) or # one that does not give us useful --help. echo "${UNAME_MACHINE}-pc-linux-gnuoldld" exit 0 ;; esac # Determine whether the default compiler is a.out or elf cat >$dummy.c < #ifdef __cplusplus #include /* for printf() prototype */ int main (int argc, char *argv[]) { #else int main (argc, argv) int argc; char *argv[]; { #endif #ifdef __ELF__ # ifdef __GLIBC__ # if __GLIBC__ >= 2 printf ("%s-pc-linux-gnu\n", argv[1]); # else printf ("%s-pc-linux-gnulibc1\n", argv[1]); # endif # else printf ("%s-pc-linux-gnulibc1\n", argv[1]); # endif #else printf ("%s-pc-linux-gnuaout\n", argv[1]); #endif return 0; } EOF eval $set_cc_for_build $CC_FOR_BUILD $dummy.c -o $dummy 2>/dev/null && ./$dummy "${UNAME_MACHINE}" && rm -f $dummy.c $dummy && exit 0 rm -f $dummy.c $dummy test x"${TENTATIVE}" != x && echo "${TENTATIVE}" && exit 0 ;; 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. echo i386-sequent-sysv4 exit 0 ;; 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. echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION} exit 0 ;; i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*) UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'` if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then echo ${UNAME_MACHINE}-univel-sysv${UNAME_REL} else echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL} fi exit 0 ;; i*86:*:5:[78]*) case `/bin/uname -X | grep "^Machine"` in *486*) UNAME_MACHINE=i486 ;; *Pentium) UNAME_MACHINE=i586 ;; *Pent*|*Celeron) UNAME_MACHINE=i686 ;; esac echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION} exit 0 ;; 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|egrep Release|sed -e 's/.*= //')` (/bin/uname -X|egrep i80486 >/dev/null) && UNAME_MACHINE=i486 (/bin/uname -X|egrep '^Machine.*Pentium' >/dev/null) \ && UNAME_MACHINE=i586 (/bin/uname -X|egrep '^Machine.*Pent ?II' >/dev/null) \ && UNAME_MACHINE=i686 (/bin/uname -X|egrep '^Machine.*Pentium Pro' >/dev/null) \ && UNAME_MACHINE=i686 echo ${UNAME_MACHINE}-pc-sco$UNAME_REL else echo ${UNAME_MACHINE}-pc-sysv32 fi exit 0 ;; i*86:*DOS:*:*) echo ${UNAME_MACHINE}-pc-msdosdjgpp exit 0 ;; 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 i386. echo i386-pc-msdosdjgpp exit 0 ;; Intel:Mach:3*:*) echo i386-pc-mach3 exit 0 ;; paragon:*:*:*) echo i860-intel-osf1 exit 0 ;; i860:*:4.*:*) # i860-SVR4 if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4 else # Add other i860-SVR4 vendors below as they are discovered. echo i860-unknown-sysv${UNAME_RELEASE} # Unknown i860-SVR4 fi exit 0 ;; mini*:CTIX:SYS*5:*) # "miniframe" echo m68010-convergent-sysv exit 0 ;; M68*:*:R3V[567]*:*) test -r /sysV68 && echo 'm68k-motorola-sysv' && exit 0 ;; 3[34]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 4850:*: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 0 /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ && echo i586-ncr-sysv4.3${OS_REL} && exit 0 ;; 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ && echo i486-ncr-sysv4 && exit 0 ;; m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) echo m68k-unknown-lynxos${UNAME_RELEASE} exit 0 ;; mc68030:UNIX_System_V:4.*:*) echo m68k-atari-sysv4 exit 0 ;; i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.0*:*) echo i386-unknown-lynxos${UNAME_RELEASE} exit 0 ;; TSUNAMI:LynxOS:2.*:*) echo sparc-unknown-lynxos${UNAME_RELEASE} exit 0 ;; rs6000:LynxOS:2.*:*) echo rs6000-unknown-lynxos${UNAME_RELEASE} exit 0 ;; PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.0*:*) echo powerpc-unknown-lynxos${UNAME_RELEASE} exit 0 ;; SM[BE]S:UNIX_SV:*:*) echo mips-dde-sysv${UNAME_RELEASE} exit 0 ;; RM*:ReliantUNIX-*:*:*) echo mips-sni-sysv4 exit 0 ;; RM*:SINIX-*:*:*) echo mips-sni-sysv4 exit 0 ;; *:SINIX-*:*:*) if uname -p 2>/dev/null >/dev/null ; then UNAME_MACHINE=`(uname -p) 2>/dev/null` echo ${UNAME_MACHINE}-sni-sysv4 else echo ns32k-sni-sysv fi exit 0 ;; PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort # says echo i586-unisys-sysv4 exit 0 ;; *:UNIX_System_V:4*:FTX*) # From Gerald Hewes . # How about differentiating between stratus architectures? -djm echo hppa1.1-stratus-sysv4 exit 0 ;; *:*:*:FTX*) # From seanf@swdc.stratus.com. echo i860-stratus-sysv4 exit 0 ;; *:VOS:*:*) # From Paul.Green@stratus.com. echo hppa1.1-stratus-vos exit 0 ;; mc68*:A/UX:*:*) echo m68k-apple-aux${UNAME_RELEASE} exit 0 ;; news*:NEWS-OS:6*:*) echo mips-sony-newsos6 exit 0 ;; R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) if [ -d /usr/nec ]; then echo mips-nec-sysv${UNAME_RELEASE} else echo mips-unknown-sysv${UNAME_RELEASE} fi exit 0 ;; BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. echo powerpc-be-beos exit 0 ;; BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only. echo powerpc-apple-beos exit 0 ;; BePC:BeOS:*:*) # BeOS running on Intel PC compatible. echo i586-pc-beos exit 0 ;; SX-4:SUPER-UX:*:*) echo sx4-nec-superux${UNAME_RELEASE} exit 0 ;; SX-5:SUPER-UX:*:*) echo sx5-nec-superux${UNAME_RELEASE} exit 0 ;; Power*:Rhapsody:*:*) echo powerpc-apple-rhapsody${UNAME_RELEASE} exit 0 ;; *:Rhapsody:*:*) echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE} exit 0 ;; *:Darwin:*:*) echo `uname -p`-apple-darwin${UNAME_RELEASE} exit 0 ;; *:procnto*:*:* | *:QNX:[0123456789]*:*) if test "${UNAME_MACHINE}" = "x86pc"; then UNAME_MACHINE=pc fi echo `uname -p`-${UNAME_MACHINE}-nto-qnx exit 0 ;; *:QNX:*:4*) echo i386-pc-qnx exit 0 ;; NSR-[KW]:NONSTOP_KERNEL:*:*) echo nsr-tandem-nsk${UNAME_RELEASE} exit 0 ;; *:NonStop-UX:*:*) echo mips-compaq-nonstopux exit 0 ;; BS2000:POSIX*:*:*) echo bs2000-siemens-sysv exit 0 ;; DS/*:UNIX_System_V:*:*) echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE} exit 0 ;; *: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 else UNAME_MACHINE="$cputype" fi echo ${UNAME_MACHINE}-unknown-plan9 exit 0 ;; i*86:OS/2:*:*) # If we were able to find `uname', then EMX Unix compatibility # is probably installed. echo ${UNAME_MACHINE}-pc-os2-emx exit 0 ;; *:TOPS-10:*:*) echo pdp10-unknown-tops10 exit 0 ;; *:TENEX:*:*) echo pdp10-unknown-tenex exit 0 ;; KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*) echo pdp10-dec-tops20 exit 0 ;; XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*) echo pdp10-xkl-tops20 exit 0 ;; *:TOPS-20:*:*) echo pdp10-unknown-tops20 exit 0 ;; *:ITS:*:*) echo pdp10-unknown-its exit 0 ;; i*86:XTS-300:*:STOP) echo ${UNAME_MACHINE}-unknown-stop exit 0 ;; esac #echo '(No uname command or uname output not recognized.)' 1>&2 #echo "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" 1>&2 cat >$dummy.c < # include #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 (__arm) && defined (__acorn) && defined (__unix) printf ("arm-acorn-riscix"); exit (0); #endif #if defined (hp300) && !defined (hpux) printf ("m68k-hp-bsd\n"); exit (0); #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 printf ("vax-dec-ultrix\n"); exit (0); # endif #endif #if defined (alliant) && defined (i860) printf ("i860-alliant-bsd\n"); exit (0); #endif exit (1); } EOF eval $set_cc_for_build $CC_FOR_BUILD $dummy.c -o $dummy 2>/dev/null && ./$dummy && rm -f $dummy.c $dummy && exit 0 rm -f $dummy.c $dummy # Apollos put the system type in the environment. test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit 0; } # Convex versions that predate uname can use getsysinfo(1) if [ -x /usr/convex/getsysinfo ] then case `getsysinfo -f cpu_type` in c1*) echo c1-convex-bsd exit 0 ;; c2*) if getsysinfo -f scalar_acc then echo c32-convex-bsd else echo c2-convex-bsd fi exit 0 ;; c34*) echo c34-convex-bsd exit 0 ;; c38*) echo c38-convex-bsd exit 0 ;; c4*) echo c4-convex-bsd exit 0 ;; esac fi cat >&2 < in order to provide the needed information to handle your system. config.guess timestamp = $timestamp 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` /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 exit 1 # Local variables: # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "timestamp='" # time-stamp-format: "%:y-%02m-%02d" # time-stamp-end: "'" # End: bar-1.11.1.orig/TODO0000644000175000017500000000067711520303732014172 0ustar georgeskgeorgesk[ ]: Optionally behave like cp if: (a) Multiple files are given, and (b) The destination is a directory [ ]: Offer an option to preserve ownership/permissions [ ]: Add an option to bar to use the filename as the title, whenever bar is given the -if command line option. [ ]: Add an option to give a printf format string to bar to use whenever generating the title. This way multiple lines of output can be made to line up. bar-1.11.1.orig/compile0000754000175000017500000000532610510504276015057 0ustar georgeskgeorgesk#! /bin/sh # Wrapper for compilers which do not understand `-c -o'. # Copyright 1999, 2000 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, write to the Free Software # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. # 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. # Usage: # compile PROGRAM [ARGS]... # `-o FOO.o' is removed from the args passed to the actual compile. prog=$1 shift ofile= cfile= args= while test $# -gt 0; do case "$1" in -o) # configure might choose to run compile as `compile cc -o foo foo.c'. # So we do something ugly here. ofile=$2 shift case "$ofile" in *.o | *.obj) ;; *) args="$args -o $ofile" ofile= ;; esac ;; *.c) cfile=$1 args="$args $1" ;; *) args="$args $1" ;; esac 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 "$prog" $args fi # Name of file we expect compiler to create. cofile=`echo $cfile | sed -e 's|^.*/||' -e '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. "$prog" $args status=$? if test -f "$cofile"; then mv "$cofile" "$ofile" fi rmdir $lockdir exit $status bar-1.11.1.orig/display.c0000644000175000017500000004355411433304343015316 0ustar georgeskgeorgesk#include "config.h" #include "headers.h" #include "types.h" #include "error.h" #include "io.h" #include "display.h" #ifdef HAVE_UNISTD_H # ifdef HAVE_SIGNAL_H # ifdef HAVE_TERMIOS_H # ifdef HAVE_SYS_IOCTL_H # define CAN_RESIZE # endif # endif # endif #endif display d; #ifdef CAN_RESIZE static void displayGetSize(void) { struct winsize size; if (d.manual_width && d.manual_height) return; if (ioctl(STDERR_FILENO, TIOCGWINSZ, (char *)&size) < 0) return; if (!d.manual_width) { d.screen_width = size.ws_col; if (d.screen_width_minus_one) d.screen_width--; } if (!d.manual_height) { d.screen_height = size.ws_row; if (d.screen_height_minus_one) d.screen_height--; } } int displaySetSigWinch(void); static void sig_winch(int signo) { displayGetSize(); displaySetSigWinch(); } int displaySetSigWinch(void) { if (isatty(STDERR_FILENO) != 0) { if (signal(SIGWINCH, sig_winch) == SIG_ERR) { return(1); } } return(0); } #endif int displayInit(void) { int c; d.start_time = 0; d.total_time = 0; d.current_time = 0; d.elapsed_time = 0; d.percent_complete = 0.0; d.display_interval = 1; d.overtime_flag = 0; d.k = 1024; d.twiddle = '-'; for (c = 0; c < 80; c++) d.title[c] = 0; d.screen_width = 79; d.manual_width = 0; d.screen_width_minus_one = DEFAULT_SW_MINUS_ONE; d.screen_height = 23; d.manual_height = 0; d.screen_height_minus_one = DEFAULT_SH_MINUS_ONE; d.display_wait = 0; d.display_numeric = 0; d.display_twiddle = DEFAULT_DISPLAY_TWIDDLE; d.display_title = 1; d.display_datacount = 1; d.display_throughput = 1; d.display_time = 1; d.display_elapsed_only = 0; d.display_percent = 1; d.display_bar = 1; d.display_summary = 1; d.display_ansi = 0; d.display_throughput_bits = 0; d.display_count_bits = 0; d.space_bg_color = 0; d.twiddle_fg_color = ""; /* green */ d.twiddle_bg_color = 0; d.twiddle_fg_bold = 0; d.title_fg_color = ""; /* yellow */ d.title_bg_color = 0; d.title_fg_bold = 0; d.datacount_fg_color = ""; /* green */ d.datacount_bg_color = 0; d.datacount_fg_bold = 1; /* bold */ d.throughput_label_fg_color = 0; d.throughput_label_bg_color = 0; d.throughput_label_fg_bold = 0; d.throughput_fg_color = ""; /* green */ d.throughput_bg_color = 0; d.throughput_fg_bold = 1; /* bold */ d.time_label_fg_color = 0; d.time_label_bg_color = 0; d.time_label_fg_bold = 0; d.time_fg_color = ""; /* green */ d.time_bg_color = 0; d.time_fg_bold = 1; /* bold */ d.percent_fg_color = ""; /* green */ d.percent_bg_color = 0; d.percent_fg_bold = 1; /* bold */ d.bar_fg_color = ""; /* yellow */ d.bar_bg_color = 0; d.bar_fg_bold = 1; /* bold */ d.barbrace_fg_color = ""; /* red */ d.barbrace_bg_color = 0; d.barbrace_fg_bold = 0; d.bar_open_brace = '['; d.bar_close_brace = ']'; d.bar_complete = '='; d.bar_incomplete = ' '; d.total_display_percent = 1; d.info_file = 0; d.info_fin = 0; d.info_num = 0; d.info_percent_threshold = 0.0; d.info_percent_count = 0.0; for (c = 0; c < 256; c++) d.info_line[c] = 0; return(0); } int readline_infofile(void) { int c = 0; for (c = 0; c < 256; c++) { d.info_line[c] = 0; } if (!feof(d.info_fin)) { fgets(d.info_line, (size_t)256, d.info_fin); } return(0); } int is_delimiter_infofile(void) { if (strcmp(d.info_line, "@@@") == 0) return(1); if (strcmp(d.info_line, "@@@\n") == 0) return(1); return(0); } int init_infofile(void) { d.info_fin = fopen(d.info_file, "r"); if (d.info_fin == 0) { print_error(stderr, "Cannot open infofile for reading: %s", d.info_file); return(1); } d.info_num = 1; while (!feof(d.info_fin)) { if (readline_infofile() != 0) { print_error(stderr, "Read error on infofile: %s", d.info_file); return(1); } if (is_delimiter_infofile()) { d.info_num++; } } fclose(d.info_fin); d.info_fin = 0; d.info_fin = fopen(d.info_file, "r"); if (d.info_fin == 0) { print_error(stderr, "Cannot reopen infofile for reading: %s", d.info_file); return(1); } d.info_percent_threshold = 100.0 / (float)(d.info_num); d.info_percent_count = d.info_percent_threshold; return(0); } int shutdown_infofile(void) { fclose(d.info_fin); return(0); } void displayAnsiNormal(void) { if (d.display_ansi) { fprintf(stderr, ""); } } void displayClearScreen(void) { if (d.display_ansi) { fprintf(stderr, ""); } else { int c = 0; for (c = 0; c < d.screen_height; c++) { fprintf(stderr, "\n"); } } } /* void displayAnsiMovetoXY(int x, int y) { if (d.display_ansi) { fprintf(stderr, "[%d;%dH", x, y); } } */ /* void displayAnsiClearEOL(void) { if (d.display_ansi) { fprintf(stderr, ""); } } */ int displayInfo(void) { int c = 0; if (d.info_fin == 0) return(0); displayAnsiNormal(); displayClearScreen(); readline_infofile(); while (!feof(d.info_fin) && !is_delimiter_infofile()) { fprintf(stderr, "%s", d.info_line); c++; readline_infofile(); } while (c < d.screen_height) { c++; fprintf(stderr, "\n"); } return(0); } int displayNextInfo(void) { if (d.display_numeric != 0) return(0); if (d.info_fin == 0) return(0); if (d.info_percent_count <= d.percent_complete) { displayInfo(); d.info_percent_count += d.info_percent_threshold; } return(0); } int displayBegin(void) { d.start_time = time(0); d.current_time = time(0); #ifdef CAN_RESIZE displayGetSize(); if (displaySetSigWinch() != 0) { print_error(stderr, "Could not install SIGWINCH signal handler"); print_esup(stderr, "Window resize events will be ignored"); } #endif if (d.info_file != 0) { if (init_infofile() != 0) { return(1); } displayInfo(); } return(0); } #define sec_per_hour 3600 #define sec_per_minute 60 int calculateCountDisplay( uint64 *total_count, char **total_count_units, float *short_count, char **short_count_units ) { uint64 num = 0; uint64 div = 1; *total_count = io.total_write; if (d.display_count_bits) *total_count_units = "b"; else *total_count_units = "B"; num = io.total_write; if (d.display_count_bits) { *short_count_units = "b "; num *= 8; } else { *short_count_units = "B "; } *short_count = 0.0; if (num >= d.k) { if (d.display_count_bits) *short_count_units = "Kb"; else *short_count_units = "KB"; div = d.k; } if (num >= (d.k * d.k)) { if (d.display_count_bits) *short_count_units = "Mb"; else *short_count_units = "MB"; num /= d.k; } if (num >= (d.k * d.k)) { if (d.display_count_bits) *short_count_units = "Gb"; else *short_count_units = "GB"; num /= d.k; } if (num >= (d.k * d.k)) { if (d.display_count_bits) *short_count_units = "Tb"; else *short_count_units = "TB"; num /= d.k; } if (num >= (d.k * d.k)) { if (d.display_count_bits) *short_count_units = "Pb"; else *short_count_units = "PB"; num /= d.k; } if (num >= (d.k * d.k)) { if (d.display_count_bits) *short_count_units = "Eb"; else *short_count_units = "EB"; num /= d.k; } *short_count = ((float)num / div); return(0); } int calculateThroughputDisplay( uint64 *total_throughput, char **total_throughput_units, float *short_throughput, char **short_throughput_units ) { uint64 num = 0; uint64 div = 1; if (d.elapsed_time > 0) { *total_throughput = io.total_write / d.elapsed_time; num = io.total_write / d.elapsed_time; } else { *total_throughput = 0; num = 0; } if (d.display_throughput_bits) { *total_throughput *= 8; *total_throughput_units = "b"; *short_throughput_units = "b/s "; num *= 8; } else { *total_throughput_units = "B"; *short_throughput_units = "B/s "; } *short_throughput = 0.0; if (num >= d.k) { if (d.display_throughput_bits) *short_throughput_units = "Kb/s"; else *short_throughput_units = "KB/s"; div = d.k; } if (num >= (d.k * d.k)) { if (d.display_throughput_bits) *short_throughput_units = "Mb/s"; else *short_throughput_units = "MB/s"; num /= d.k; } if (num >= (d.k * d.k)) { if (d.display_throughput_bits) *short_throughput_units = "Gb/s"; else *short_throughput_units = "GB/s"; num /= d.k; } if (num >= (d.k * d.k)) { if (d.display_throughput_bits) *short_throughput_units = "Tb/s"; else *short_throughput_units = "TB/s"; num /= d.k; } *short_throughput = ((float)num / div); return(0); } int calculateTimeDisplay(uint64 *sptr, uint64 *mptr, uint64 *hptr) { if (*sptr >= sec_per_hour) { *hptr = *sptr / sec_per_hour; *sptr -= *hptr * sec_per_hour; } if (*sptr >= sec_per_minute) { *mptr = *sptr / sec_per_minute; *sptr -= *mptr * sec_per_minute; } return(0); } int calculatePercentComplete(void) { if (io.total_size_known && (io.total_size > 0)) { d.percent_complete = (float)(io.total_write * 100.0 / io.total_size); if (d.percent_complete < 0) { d.percent_complete = 9999.9; } } return(0); } void displayAnsi(char *fg, char *bg, int b) { if (d.display_ansi) { if (fg != 0) { fprintf(stderr, "%s", fg); } if (bg != 0) { fprintf(stderr, "%s", bg); } if (b) { fprintf(stderr, ""); } } } void displayTwiddle(void) { static uint64 last_write = 0; static time_t last_time = 0; if (last_time == 0) last_time = time(0); if (last_time == time(0)) return; if (last_write == io.total_write) return; last_time = time(0); last_write = io.total_write; switch (d.twiddle) { case '\\': d.twiddle = '|'; break; case '|': d.twiddle = '/'; break; case '/': d.twiddle = '-'; break; case '-': d.twiddle = '\\'; break; } displayAnsi(d.twiddle_fg_color, d.twiddle_bg_color, d.twiddle_fg_bold); fprintf(stderr, "%c\r", d.twiddle); } int displayPrint(void) { uint64 eta = 0; uint64 total_throughput = 0; char *total_throughput_units = ""; float short_throughput = 0.0; char* short_throughput_units = ""; uint64 hours = 0; uint64 minutes = 0; uint64 seconds = 0; uint64 total_count = 0; char *total_count_units = ""; float short_count = 0.0; char *short_count_units = ""; char *time_title = "eta"; int screen_used = 0; int this_width = 0; if (d.display_wait && (io.total_write == 0)) { return(0); } displayNextInfo(); d.current_time = time(0); d.elapsed_time = d.current_time - d.start_time; if ( calculateThroughputDisplay( &total_throughput, &total_throughput_units, &short_throughput, &short_throughput_units ) != 0 ) { return(1); } if (calculatePercentComplete() != 0) { return(1); } if (d.display_numeric != 0) { fprintf(stderr, "%d\n", (int)d.percent_complete); return(0); } if ((io.total_size_known == 1) && (!d.display_elapsed_only)) { if (io.total_write > 0) { if (io.total_size >= io.total_write) { if (d.percent_complete > 0.0) { eta = (uint64)( 100 * d.elapsed_time / d.percent_complete ) - d.elapsed_time; } else { eta = (uint64)(-1); } } else { if (!d.overtime_flag) { d.overtime_flag = 1; d.total_time = d.elapsed_time; } eta = d.elapsed_time - d.total_time; time_title = "ovr"; } } else { eta = 0; } seconds = eta; } else { seconds = d.elapsed_time; time_title = "elapsed"; } if (calculateTimeDisplay(&seconds, &minutes, &hours) != 0) { return(1); } if ( calculateCountDisplay( &total_count, &total_count_units, &short_count, &short_count_units) != 0) { return(1); } /* * Display twiddle */ this_width = 1; if ((d.display_twiddle) && (screen_used+this_width < d.screen_width)) { displayAnsi( d.twiddle_fg_color, d.twiddle_bg_color, d.twiddle_fg_bold); fprintf(stderr, "%c", d.twiddle); screen_used += this_width; } /* * Display title, if set */ if ((d.display_title) && (d.title[0] != 0)) { this_width = strlen(d.title); if (screen_used > 0) { displayAnsiNormal(); displayAnsi(0,d.space_bg_color,0); fprintf(stderr, " "); this_width++; } displayAnsiNormal(); displayAnsi( d.title_fg_color, d.title_bg_color, d.title_fg_bold); fprintf(stderr, "%s", d.title); screen_used += this_width; } /* * Display data count */ this_width = 8; if (screen_used > 0) this_width++; if ((d.display_datacount) && (screen_used+this_width < d.screen_width)) { if (screen_used > 0) { displayAnsiNormal(); displayAnsi(0,d.space_bg_color,0); fprintf(stderr, " "); } displayAnsiNormal(); displayAnsi( d.datacount_fg_color, d.datacount_bg_color, d.datacount_fg_bold); if (short_count > 9999.9) { fprintf(stderr, "+999.9%2.2s", short_count_units); } else { fprintf(stderr, "%6.1f%2.2s", short_count, short_count_units); } screen_used += this_width; } /* * Display throughput */ this_width = 13; if (!d.display_datacount) this_width -= 3; if (screen_used > 0) this_width++; if ((d.display_throughput) && (screen_used+this_width < d.screen_width)) { if (screen_used > 0) { displayAnsiNormal(); displayAnsi(0,d.space_bg_color,0); fprintf(stderr, " "); } if (d.display_datacount) { displayAnsiNormal(); displayAnsi( d.throughput_label_fg_color, d.throughput_label_bg_color, d.throughput_label_fg_bold); fprintf(stderr, "at"); displayAnsiNormal(); displayAnsi(0,d.space_bg_color,0); fprintf(stderr, " "); } displayAnsiNormal(); displayAnsi( d.throughput_fg_color, d.throughput_bg_color, d.throughput_fg_bold); fprintf(stderr, "%6.1f%4.4s", short_throughput, short_throughput_units); screen_used += this_width; } /* * Display time */ this_width = 11+strlen(time_title); if (screen_used > 0) this_width += 2; if ((d.display_time) && (screen_used+this_width < d.screen_width)) { if (screen_used > 0) { displayAnsiNormal(); displayAnsi(0,d.space_bg_color,0); fprintf(stderr, " "); } displayAnsiNormal(); displayAnsi( d.time_label_fg_color, d.time_label_bg_color, d.time_label_fg_bold); fprintf(stderr, "%s:", time_title); displayAnsiNormal(); displayAnsi(0,d.space_bg_color,0); fprintf(stderr, " "); displayAnsiNormal(); displayAnsi( d.time_fg_color, d.time_bg_color, d.time_fg_bold); if (hours > 99) { fprintf(stderr, "+99:99:99"); } else fprintf(stderr, "%3u:%2.2u:%2.2u", (unsigned int)hours, (unsigned int)minutes, (unsigned int)seconds); screen_used += this_width; } /* * Display percent */ this_width = 5; if (screen_used > 0) this_width++; if ((d.display_percent) && (io.total_size_known) && (screen_used+this_width < d.screen_width)) { if (screen_used > 0) { displayAnsiNormal(); displayAnsi(0,d.space_bg_color,0); fprintf(stderr, " "); } displayAnsiNormal(); displayAnsi( d.percent_fg_color, d.percent_bg_color, d.percent_fg_bold); if (d.percent_complete > 999) { fprintf(stderr, "+999%%"); } else { fprintf(stderr, "%4d%%", (int)d.percent_complete); } screen_used += this_width; } /* * Display progress bar */ this_width = 5; if (screen_used > 0) this_width++; if ((d.display_bar) && (io.total_size_known) && (screen_used+this_width < d.screen_width)) { int c; int line_length; int completed_length = 0; if (screen_used > 0) { displayAnsiNormal(); displayAnsi(0,d.space_bg_color,0); fprintf(stderr, " "); screen_used++; } this_width = d.screen_width - screen_used + 1; line_length = this_width - 3; completed_length = line_length * d.percent_complete / 100; displayAnsiNormal(); displayAnsi( d.barbrace_fg_color, d.barbrace_bg_color, d.barbrace_fg_bold); fprintf(stderr, "%c", d.bar_open_brace); displayAnsiNormal(); displayAnsi( d.bar_fg_color, d.bar_bg_color, d.bar_fg_bold); for (c = 0; c < line_length; c++) { if (c <= completed_length) { fprintf(stderr, "%c", d.bar_complete); } else { fprintf(stderr, "%c", d.bar_incomplete); } } displayAnsiNormal(); displayAnsi( d.barbrace_fg_color, d.barbrace_bg_color, d.barbrace_fg_bold); fprintf(stderr, "%c", d.bar_close_brace); } displayAnsiNormal(); fprintf(stderr, "\r"); return(0); } int displayUpdate(void) { if (d.display_twiddle) displayTwiddle(); if (time(0) < d.current_time + d.display_interval) return(0); if (displayPrint() != 0) return(1); return(0); } int displayEnd(void) { uint64 total_throughput = 0; char *total_throughput_units = ""; float short_throughput = 0.0; char *short_throughput_units = ""; uint64 total_count = 0; char *total_count_units = ""; float short_count = 0.0; char *short_count_units = ""; uint64 hours = 0; uint64 minutes = 0; uint64 seconds = 0; displayPrint(); d.elapsed_time = d.current_time - d.start_time; if (calculatePercentComplete() != 0) { return(1); } if ( calculateCountDisplay( &total_count, &total_count_units, &short_count, &short_count_units ) != 0 ) { return(1); } if ( calculateThroughputDisplay( &total_throughput, &total_throughput_units, &short_throughput, &short_throughput_units ) != 0 ) { return(1); } seconds = d.elapsed_time; if (calculateTimeDisplay(&seconds, &minutes, &hours) != 0) { return(1); } fprintf(stderr, "\n"); if (d.display_summary) { fprintf(stderr, "Copied: %llu%s (%.1f%s)", (long long unsigned int)total_count, total_count_units, short_count, short_count_units ); if (io.total_size_known && d.total_display_percent) { fprintf(stderr, " (%d%% of expected input)", (int)d.percent_complete); } fprintf(stderr, "\n"); fprintf(stderr, "Time: "); if (hours > 0) { fprintf(stderr, "%3u:%2.2u:%2.2u", (unsigned int)hours, (unsigned int)minutes, (unsigned int)seconds); } else if (minutes > 0) { fprintf(stderr, "%2.2u:%2.2u", (unsigned int)minutes, (unsigned int)seconds); } else { fprintf(stderr, "%2u seconds", (unsigned int)seconds); } fprintf(stderr, "\n"); if ((hours != 0) || (minutes != 0) || (seconds != 0)) { fprintf(stderr, "Throughput: %llu%s (%.1f%s)\n\n", (long long unsigned int)total_throughput, total_throughput_units, short_throughput, short_throughput_units ); } else { fprintf(stderr, "Throughput: (infinite)\n\n"); } } d.start_time = 0; return(0); } bar-1.11.1.orig/types.h0000644000175000017500000000604010510504276015011 0ustar georgeskgeorgesk#include "config.h" /* * Types */ #ifndef __types_h__ #define __types_h__ #include "headers.h" /* * uint8 */ #if SIZEOF_UNSIGNED_CHAR == 1 typedef unsigned char uint8; # define UINT8_CTYPE(v) ((unsigned int)(unsigned char)(v)) #elif SIZEOF_UNSIGNED_SHORT == 1 typedef unsigned short uint8; # define UINT8_CTYPE(v) ((unsigned short)(v)) #elif SIZEOF_UNSIGNED_INT == 1 typedef unsigned int uint8; # define UINT8_CTYPE(v) ((unsigned int)(v)) #elif SIZEOF_UNSIGNED_LONG == 1 typedef unsigned long uint8; # define UINT8_CTYPE(v) ((unsigned long)(v)) #elif SIZEOF_UNSIGNED_LONG_LONG == 1 typedef unsigned long long uint8; # define UINT8_CTYPE(v) ((unsigned long long)(v)) #else # error *** ERROR: No 8-bit type found to use as uint8 #endif #define MAX_UINT8 ((uint8)-1) #if SIZEOF_SIZE_T == 1 #define MAX_SIZE_T MAX_UINT8 #endif /* * uint16 */ #if SIZEOF_UNSIGNED_CHAR == 2 typedef unsigned char uint16; # define UINT16_CTYPE(v) ((unsigned int)(unsigned char)(v)) #elif SIZEOF_UNSIGNED_SHORT == 2 typedef unsigned short uint16; # define UINT16_CTYPE(v) ((unsigned short)(v)) #elif SIZEOF_UNSIGNED_INT == 2 typedef unsigned int uint16; # define UINT16_CTYPE(v) ((unsigned int)(v)) #elif SIZEOF_UNSIGNED_LONG == 2 typedef unsigned long uint16; # define UINT16_CTYPE(v) ((unsigned long)(v)) #elif SIZEOF_UNSIGNED_LONG_LONG == 2 typedef unsigned long long uint16; # define UINT16_CTYPE(v) ((unsigned long long)(v)) #else # error *** ERROR: No 16-bit type found to use as uint16 #endif #define MAX_UINT16 ((uint16)-1) #if SIZEOF_SIZE_T == 2 #define MAX_SIZE_T MAX_UINT16 #endif /* * uint32 */ #if SIZEOF_UNSIGNED_CHAR == 4 typedef unsigned char uint32; # define UINT32_CTYPE(v) ((unsigned int)(unsigned char)(v)) #elif SIZEOF_UNSIGNED_SHORT == 4 typedef unsigned short uint32; # define UINT32_CTYPE(v) ((unsigned short)(v)) #elif SIZEOF_UNSIGNED_INT == 4 typedef unsigned int uint32; # define UINT32_CTYPE(v) ((unsigned int)(v)) #elif SIZEOF_UNSIGNED_LONG == 4 typedef unsigned long uint32; # define UINT32_CTYPE(v) ((unsigned long)(v)) #elif SIZEOF_UNSIGNED_LONG_LONG == 4 typedef unsigned long long uint32; # define UINT32_CTYPE(v) ((unsigned long long)(v)) #else # error *** ERROR: No 32-bit type found to use as uint32 #endif #define MAX_UINT32 ((uint32)-1) #if SIZEOF_SIZE_T == 4 #define MAX_SIZE_T MAX_UINT32 #endif /* * uint64 */ #if SIZEOF_UNSIGNED_CHAR == 8 typedef unsigned char uint64; # define UINT64_CTYPE(v) ((unsigned int)(unsigned char)(v)) #elif SIZEOF_UNSIGNED_SHORT == 8 typedef unsigned short uint64; # define UINT64_CTYPE(v) ((unsigned short)(v)) #elif SIZEOF_UNSIGNED_INT == 8 typedef unsigned int uint64; # define UINT64_CTYPE(v) ((unsigned int)(v)) #elif SIZEOF_UNSIGNED_LONG == 8 typedef unsigned long uint64; # define UINT64_CTYPE(v) ((unsigned long)(v)) #elif SIZEOF_UNSIGNED_LONG_LONG == 8 typedef unsigned long long uint64; # define UINT64_CTYPE(v) ((unsigned long long)(v)) #else # error *** ERROR: No 64-bit type found to use as uint64 #endif #define MAX_UINT64 ((uint64)-1) #if SIZEOF_SIZE_T == 8 #define MAX_SIZE_T MAX_UINT64 #endif #endif bar-1.11.1.orig/mkinstalldirs0000754000175000017500000000132210510504276016277 0ustar georgeskgeorgesk#! /bin/sh # mkinstalldirs --- make directory hierarchy # Author: Noah Friedman # Created: 1993-05-16 # Public domain # $Id: mkinstalldirs,v 1.13 1999/01/05 03:18:55 bje Exp $ errstatus=0 for file do set fnord `echo ":$file" | sed -ne 's/^:\//#/;s/^://;s/\// /g;s/^#/\//;p'` shift pathcomp= for d do pathcomp="$pathcomp$d" case "$pathcomp" in -* ) pathcomp=./$pathcomp ;; esac if test ! -d "$pathcomp"; then echo "mkdir $pathcomp" mkdir "$pathcomp" || lasterr=$? if test ! -d "$pathcomp"; then errstatus=$lasterr fi fi pathcomp="$pathcomp/" done done exit $errstatus # mkinstalldirs ends here bar-1.11.1.orig/test-001-post.c0000644000175000017500000000114110510504276016075 0ustar georgeskgeorgesk#include "config.h" #include "headers.h" int main(int argc, char *argv[]) { int in = 0; char buffer[1024] = { 0 }; char *expected = "Hello World\n"; int c = 0; in = STDIN_FILENO; for (c = 0; c < 1024; c++) buffer[c] = 0; read(in, buffer, strlen(expected)); if (strcmp(buffer, expected) != 0) { fprintf(stderr, "*** ERROR: Unexpected string read\n"); return(1); } sleep(5); for (c = 0; c < 1024; c++) buffer[c] = 0; read(in, buffer, strlen(expected)); if (strcmp(buffer, expected) != 0) { fprintf(stderr, "*** ERROR: Unexpected string read\n"); return(1); } close(in); return(0); } bar-1.11.1.orig/sourceforge.mk0000644000175000017500000000423010510504276016347 0ustar georgeskgeorgesk############################################################################## # # A list of sourceforge compile-farm hosts # # Last update: Thu Mar 2 12:13:07 EST 2006 # SOURCEFORGE_COMPILE_FARM_HOSTS = ########################## # # 32-bit x86 Architecture: # ########################## # * x86-linux2: Fedora Linux FC2 running Linux 2.6 kernel SOURCEFORGE_COMPILE_FARM_HOSTS += x86-linux2 # * x86-openbsd1: OpenBSD 3.4 SOURCEFORGE_COMPILE_FARM_HOSTS += x86-openbsd1 # * x86-solaris1: Sun Solaris 9 SOURCEFORGE_COMPILE_FARM_HOSTS += x86-solaris1 # * x86-linux1: Debian GNU/Linux 3.0 running Linux 2.4 kernel SOURCEFORGE_COMPILE_FARM_HOSTS += x86-linux1 # * x86-freebsd1: FreeBSD 4.8 SOURCEFORGE_COMPILE_FARM_HOSTS += x86-freebsd1 # * x86-netbsd1: NetBSD 1.6.1 SOURCEFORGE_COMPILE_FARM_HOSTS += x86-netbsd1 #################################### # # AMD 64-bit (Opteron) Architecture: # #################################### # * amd64-linux1: Fedora Core release 3 running Linux 2.6 kernel SOURCEFORGE_COMPILE_FARM_HOSTS += amd64-linux1 # * amd64-linux2: Fedora Core release 3 running Linux 2.6 kernel SOURCEFORGE_COMPILE_FARM_HOSTS += amd64-linux2 ################################ # # DEC Alpha (ev67) Architecture: # ################################ # * alpha-linux1: Debian GNU/Linux 3.0 running Linux 2.2 kernel SOURCEFORGE_COMPILE_FARM_HOSTS += alpha-linux1 ####################### # # PowerPC Architecture: # ####################### # * ppc-osx1: Apple Mac OS X 10.1 Server with Fink running on an Apple Mac G4 SOURCEFORGE_COMPILE_FARM_HOSTS += ppc-osx1 # * ppc-osx2: Apple Mac OS X 10.2 Server with Fink running on an Apple Mac G4 SOURCEFORGE_COMPILE_FARM_HOSTS += ppc-osx2 ##################################### # # Sparc (UltraSPARC-II) Architecture: # ##################################### # * sparc-solaris1, sparc-solaris2: Sun Solaris 9, running on two Sun Enterprise 220R systems SOURCEFORGE_COMPILE_FARM_HOSTS += sparc-solaris1 ########################## # # IBM Power5 Architecture: # ########################## # * openpower-linux1: SuSE Enterprise Linux 9, running on an IBM OpenPower 720 (e-Series) host. SOURCEFORGE_COMPILE_FARM_HOSTS += openpower-linux1 bar-1.11.1.orig/args.c0000644000175000017500000024560011435543716014614 0ustar georgeskgeorgesk#include "config.h" #include "headers.h" #include "error.h" #include "fd.h" #include "io.h" #include "display.h" #include "args.h" #ifndef HAVE_SPRINTF # error *** ERROR: This system does not have sprintf() #endif struct _options_list { char *short_option1; char *short_option2; char *long_option1; char *long_option2; char *rc_option; char *arg_description; char *description; int (*cl_func)(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int (*rc_func)(FILE *ferr, char *filename, int line, char *tag, char *value); }; typedef struct _options_list options_list; struct _colors_list { char *name; char *code; }; typedef struct _colors_list colors_list; /* Another global variable! And a shameless hack at that! */ char _parsing_blocks = 0; int parse_infile_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_outfile_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_size_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_completed_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_throttle_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_buffer_size_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_block_size_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_interval_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_timeout_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_kilo_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_width_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_width_minus_one_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_height_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_height_minus_one_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_twiddle_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_count_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_throughput_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_time_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_elapsed_only_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_percent_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_bar_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_summary_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_ansi_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_displays_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_help_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_version_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_throughput_bits_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_count_bits_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_title_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_display_title_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_total_percent_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_space_bg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_twiddle_fg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_twiddle_bg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_twiddle_fg_bold_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_title_fg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_title_bg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_title_fg_bold_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_count_fg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_count_bg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_count_fg_bold_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_throughput_label_fg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_throughput_label_bg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_throughput_label_fg_bold_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_throughput_fg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_throughput_bg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_throughput_fg_bold_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_time_label_fg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_time_label_bg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_time_label_fg_bold_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_time_fg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_time_bg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_time_fg_bold_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_percent_fg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_percent_bg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_percent_fg_bold_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_bar_openbrace_char_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_bar_closebrace_char_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_bar_complete_char_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_bar_incomplete_char_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_barbrace_fg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_barbrace_bg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_barbrace_fg_bold_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_bar_fg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_bar_bg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_bar_fg_bold_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_infofile_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_display_numeric_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_display_wait_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num); int parse_throttle_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_buffer_size_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_block_size_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_interval_rc(FILE *ferr, char* filename, int line, char *tag, char *value); int parse_timeout_rc(FILE *ferr, char* filename, int line, char *tag, char *value); int parse_kilo_rc(FILE *ferr, char* filename, int line, char *tag, char *value); int parse_width_rc(FILE *ferr, char* filename, int line, char *tag, char *value); int parse_width_minus_one_rc(FILE *ferr, char* filename, int line, char *tag, char *value); int parse_height_rc(FILE *ferr, char* filename, int line, char *tag, char *value); int parse_height_minus_one_rc(FILE *ferr, char* filename, int line, char *tag, char *value); int parse_twiddle_rc(FILE *ferr, char* filename, int line, char *tag, char *value); int parse_count_rc(FILE *ferr, char* filename, int line, char *tag, char *value); int parse_throughput_rc(FILE *ferr, char* filename, int line, char *tag, char *value); int parse_time_rc(FILE *ferr, char* filename, int line, char *tag, char *value); int parse_elapsed_only_rc(FILE *ferr, char* filename, int line, char *tag, char *value); int parse_percent_rc(FILE *ferr, char* filename, int line, char *tag, char *value); int parse_bar_rc(FILE *ferr, char* filename, int line, char *tag, char *value); int parse_summary_rc(FILE *ferr, char* filename, int line, char *tag, char *value); int parse_ansi_rc(FILE *ferr, char* filename, int line, char *tag, char *value); int parse_throughput_bits_rc(FILE *ferr, char* filename, int line, char *tag, char *value); int parse_count_bits_rc(FILE *ferr, char* filename, int line, char *tag, char *value); int parse_title_rc(FILE *ferr, char* filename, int line, char *tag, char *value); int parse_display_title_rc(FILE *ferr, char* filename, int line, char *tag, char *value); int parse_total_percent_rc(FILE *ferr, char* filename, int line, char *tag, char *value); int parse_space_bg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_twiddle_fg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_twiddle_bg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_twiddle_fg_bold_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_title_fg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_title_bg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_title_fg_bold_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_count_fg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_count_bg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_count_fg_bold_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_throughput_label_fg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_throughput_label_bg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_throughput_label_fg_bold_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_throughput_fg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_throughput_bg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_throughput_fg_bold_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_time_label_fg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_time_label_bg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_time_label_fg_bold_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_time_fg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_time_bg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_time_fg_bold_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_percent_fg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_percent_bg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_percent_fg_bold_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_bar_openbrace_char_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_bar_closebrace_char_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_bar_complete_char_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_bar_incomplete_char_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_barbrace_fg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_barbrace_bg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_barbrace_fg_bold_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_bar_fg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_bar_bg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_bar_fg_bold_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_infofile_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_display_numeric_rc(FILE *ferr, char *filename, int line, char *tag, char *value); int parse_display_wait_rc(FILE *ferr, char *filename, int line, char *tag, char *value); options_list options[] = { { "-if", 0, "--in-file", 0, 0, "", "Read input from . Default: stdin", parse_infile_commandline, 0 }, { "-of", 0, "--out-file", 0, 0, "", "Write output to . Default: stdout", parse_outfile_commandline, 0 }, { "-s", 0, "--size", 0, 0, "", "Expect an input stream of bytes.", parse_size_commandline, 0 }, { "-c", 0, "--completed", 0, 0, "", "Expect to continue an input stream at bytes.", parse_completed_commandline, 0 }, { "-th", 0, "--throttle", 0, "throttle", "", "Throttle I/O rate to bytes per second.", parse_throttle_commandline, parse_throttle_rc, }, { "-bs", 0, "--buffer-size", 0, "buffer-size", "", "Allocate an I/O buffer of bytes. Default: 1024", parse_buffer_size_commandline, parse_buffer_size_rc }, { "-bl", 0, "--block-size", 0, "block-size", "", "Assume blocks of bytes when parsing sizes in blocks. Default: 1024", parse_block_size_commandline, parse_block_size_rc }, { "-i", 0, "--interval", 0, "interval", "", "Update the display every seconds. Default: 1", parse_interval_commandline, parse_interval_rc }, { "-t", 0, "--timeout", 0, "timeout", "", "Wait microseconds for a change in I/O. Default: 250000", parse_timeout_commandline, parse_timeout_rc }, { "-k", 0, "--kilo", 0, "kilobyte", "1000|1024", "Use 1000 or 1024 as the size of a kilobyte. Default: 1024", parse_kilo_commandline, parse_kilo_rc }, { "-sw", 0, "--screen-width", 0, "screen-width", "", "Assume a screen width of characters. Default: 80", parse_width_commandline, parse_width_rc }, { "-sw-1", "-sw-0", "--screen-width-minus-one", "--screen-width-minus-zero", "screen-width-minus-one", 0, "Use one character less than the maximum screen width. Default: off", parse_width_minus_one_commandline, parse_width_minus_one_rc }, { "-sh", 0, "--screen-height", 0, "screen-height", "", "Assume a screen height of characters. Default: 24", parse_height_commandline, parse_height_rc }, { "-sh-1", "-sh-0", "--screen-height-minus-one", "--screen-height-minus-zero", "screen-width-minus-one", 0, "Use one character less than the maximum screen height. Default: off", parse_height_minus_one_commandline, parse_height_minus_one_rc }, { "-ti", 0, "--title", 0, "title", "", "Title string to be displayed in the status line.", parse_title_commandline, parse_title_rc }, { "-dti", "-nti", "--display-title", "--no-title", "display-title", 0, "Display title string. Default: on", parse_display_title_commandline, parse_display_title_rc }, { "-dtw", "-ntw", "--display-twiddle", "--no-twiddle", "display-twiddle", 0, "Turn on/off the twiddle in the display. Default: on", parse_twiddle_commandline, parse_twiddle_rc }, { "-dc", "-nc", "--display-count", "--no-count", "display-count", 0, "Turn on/off the data count in the display. Default: on", parse_count_commandline, parse_count_rc }, { "-dcb", "-ncb", "--display-count-bits", "--no-count-bits", "display-count-bits", 0, "Display the data count as bits instead of bytes. Default: off", parse_count_bits_commandline, parse_count_bits_rc, }, { "-dth", "-nth", "--display-throughput", "--no-throughput", "display-throughput", 0, "Turn on/off the data throughput in the display. Default: on", parse_throughput_commandline, parse_throughput_rc }, { "-dthb", "-nthb", "--display-throughput-bits", "--no-throughput-bits", "display-throughput-bits", 0, "Display throughput as bits/sec instead of bytes/sec. Default: off", parse_throughput_bits_commandline, parse_throughput_bits_rc, }, { "-dt", "-nt", "--display-time", "--no-time", "display-time", 0, "Turn on/off the time in the display. Default: on", parse_time_commandline, parse_time_rc }, { "-de", "-ne", "--display-elapsed-only", "--no-elapsed-only", "display-elapsed-only", 0, "Turn on/off displaying time as elapsed only (no eta). Default: off", parse_elapsed_only_commandline, parse_elapsed_only_rc }, { "-dp", "-np", "--display-percent", "--no-percent", "display-percent", 0, "Turn on/off the percent complete in the display. Default: on", parse_percent_commandline, parse_percent_rc }, { "-db", "-nb", "--display-bar", "--no-bar", "display-bar", 0, "Turn on/off the progress bar in the display. Default: on", parse_bar_commandline, parse_bar_rc }, { "-dtp", "-ntp", "--display-total-percent", "--no-total-percent", "display-total-percent", 0, "Turn on/off the percent of expected data in the summary. Default: on", parse_total_percent_commandline, parse_total_percent_rc }, { "-ds", "-ns", "--display-summary", "--no-summary", "display-summary", 0, "Turn on/off the summary information when complete. Default: on", parse_summary_commandline, parse_summary_rc }, { "-da", "-dn", "--display-all", "--display-none", 0, 0, "Turn on/off all displays. Default: all on", parse_displays_commandline, 0 }, { "-dan", "-nan", "--display-ansi", "--no-ansi", "display-ansi", 0, "Turn on/off the use of ansi color codes in the display. Default is: off", parse_ansi_commandline, parse_ansi_rc }, { "-spbg", 0, "--space-background", 0, "space-background", "", "Use as the background for spacing between display objects.", parse_space_bg_color_commandline, parse_space_bg_color_rc }, { "-twfg", 0, "--twiddle-foreground", 0, "twiddle-foreground", "", "Use as the twiddle foreground.", parse_twiddle_fg_color_commandline, parse_twiddle_fg_color_rc }, { "-twbg", 0, "--twiddle-background", 0, "twiddle-background", "", "Use as the twiddle background.", parse_twiddle_bg_color_commandline, parse_twiddle_bg_color_rc }, { "-twb", "-twn", "--twiddle-bold", "--twiddle-normal", "twiddle-bold", 0, "Display the twiddle ansi foreground color in bold or normal.", parse_twiddle_fg_bold_commandline, parse_twiddle_fg_bold_rc }, { "-tifg", 0, "--title-foreground", 0, "title-foreground", "", "Use as the title foreground.", parse_title_fg_color_commandline, parse_title_fg_color_rc }, { "-tibg", 0, "--title-background", 0, "title-background", "", "Use as the title background.", parse_title_bg_color_commandline, parse_title_bg_color_rc }, { "-tib", "-tin", "--title-bold", "--title-normal", "title-bold", 0, "Display the title ansi foreground color in bold or normal.", parse_title_fg_bold_commandline, parse_title_fg_bold_rc }, { "-cfg", 0, "--count-foreground", 0, "count-foreground", "", "Use as the count foreground.", parse_count_fg_color_commandline, parse_count_fg_color_rc }, { "-cbg", 0, "--count-background", 0, "count-background", "", "Use as the count background.", parse_count_bg_color_commandline, parse_count_bg_color_rc }, { "-cb", "-cn", "--count-bold", "--count-normal", "count-bold", 0, "Display the count ansi foreground color in bold or normal.", parse_count_fg_bold_commandline, parse_count_fg_bold_rc }, { "-thfg", 0, "--throughput-foreground", 0, "throughput-foreground", "", "Use as the throughput foreground.", parse_throughput_fg_color_commandline, parse_throughput_fg_color_rc }, { "-thbg", 0, "--throughput-background", 0, "throughput-background", "", "Use as the throughput background.", parse_throughput_bg_color_commandline, parse_throughput_bg_color_rc }, { "-thb", "-thn", "--throughput-bold", "--throughput-normal", "throughput-bold", 0, "Display the throughput ansi foreground color in bold or normal.", parse_throughput_fg_bold_commandline, parse_throughput_fg_bold_rc }, { "-thlfg", 0, "--throughput-label-foreground", 0, "throughput-label-foreground", "", "Use as the throughput label foreground.", parse_throughput_label_fg_color_commandline, parse_throughput_label_fg_color_rc }, { "-thlbg", 0, "--throughput-label-background", 0, "throughput-label-background", "", "Use as the throughput label background.", parse_throughput_label_bg_color_commandline, parse_throughput_label_bg_color_rc }, { "-thlb", "-thln", "--throughput-label-bold", "--throughput-label-normal", "throughput-label-bold", 0, "Display the throughput label ansi foreground color in bold or normal.", parse_throughput_label_fg_bold_commandline, parse_throughput_label_fg_bold_rc }, { "-tfg", 0, "--time-foreground", 0, "time-foreground", "", "Use as the time foreground.", parse_time_fg_color_commandline, parse_time_fg_color_rc }, { "-tbg", 0, "--time-background", 0, "time-background", "", "Use as the time background.", parse_time_bg_color_commandline, parse_time_bg_color_rc }, { "-tb", "-tn", "--time-bold", "--time-normal", "time-bold", 0, "Display the time ansi foreground color in bold or normal.", parse_time_fg_bold_commandline, parse_time_fg_bold_rc }, { "-tlfg", 0, "--time-label-foreground", 0, "time-label-foreground", "", "Use as the time label foreground.", parse_time_label_fg_color_commandline, parse_time_label_fg_color_rc }, { "-tlbg", 0, "--time-label-background", 0, "time-label-background", "", "Use as the time label background.", parse_time_label_bg_color_commandline, parse_time_label_bg_color_rc }, { "-tlb", "-tln", "--time-label-bold", "--time-label-normal", "time-label-bold", 0, "Display the time label ansi foreground color in bold or normal.", parse_time_label_fg_bold_commandline, parse_time_label_fg_bold_rc }, { "-pfg", 0, "--percent-foreground", 0, "percent-foreground", "", "Use as the percent foreground.", parse_percent_fg_color_commandline, parse_percent_fg_color_rc }, { "-pbg", 0, "--percent-background", 0, "percent-background", "", "Use as the percent background.", parse_percent_bg_color_commandline, parse_percent_bg_color_rc }, { "-pb", "-pn", "--percent-bold", "--percent-normal", "percent-bold", 0, "Display the percent ansi foreground color in bold or normal.", parse_percent_fg_bold_commandline, parse_percent_fg_bold_rc }, { "-bobc", 0, "--bar-openbrace-char", 0, "bar-openbrace-char", "", "Use as the open brace character on the progress bar.", parse_bar_openbrace_char_commandline, parse_bar_openbrace_char_rc }, { "-bcbc", 0, "--bar-closebrace-char", 0, "bar-closebrace-char", "", "Use as the close brace character on the progress bar.", parse_bar_closebrace_char_commandline, parse_bar_closebrace_char_rc }, { "-bcc", 0, "--bar-complete-char", 0, "bar-complete-char", "", "Use as the completed character on the progress bar.", parse_bar_complete_char_commandline, parse_bar_complete_char_rc }, { "-bic", 0, "--bar-incomplete-char", 0, "bar-incomplete-char", "", "Use as the completed character on the progress bar.", parse_bar_incomplete_char_commandline, parse_bar_incomplete_char_rc }, { "-bbfg", 0, "--bar-brace-foreground", 0, "bar-brace-foreground", "", "Use as the foreground color for the braces on the progress bar.", parse_barbrace_fg_color_commandline, parse_barbrace_fg_color_rc }, { "-bbbg", 0, "--bar-brace-background", 0, "bar-brace-background", "", "Use as the background color for the braces on the progress bar.", parse_barbrace_bg_color_commandline, parse_barbrace_bg_color_rc }, { "-bbb", "-bbn", "--bar-brace-bold", "--bar-brace-normal", "bar-brace-bold", 0, "Display the progress bar braces' ansi foreground color in bold or normal.", parse_barbrace_fg_bold_commandline, parse_barbrace_fg_bold_rc }, { "-bfg", 0, "--bar-foreground", 0, "bar-foreground", "", "Use as the foreground color for the progress bar.", parse_bar_fg_color_commandline, parse_bar_fg_color_rc }, { "-bbg", 0, "--bar-background", 0, "bar-background", "", "Use as the background color for the progress bar.", parse_bar_bg_color_commandline, parse_bar_bg_color_rc }, { "-bb", "-bn", "--bar-bold", "--bar-normal", "bar-bold", 0, "Display the progress bar ansi foreground color in bold or normal.", parse_bar_fg_bold_commandline, parse_bar_fg_bold_rc }, { "-inf", 0, "--info-file", 0, "info-file", 0, "Display the contents of an information file as data is copied.", parse_infofile_commandline, parse_infofile_rc }, { "-dnum", 0, "--display-numeric", 0, "display-numeric", 0, "Only display the percent complete, one integer per line.", parse_display_numeric_commandline, parse_display_numeric_rc }, { "-dw", 0, "--display-wait", 0, "display-wait", 0, "Wait for the fist byte of data before displaying anything.", parse_display_wait_commandline, parse_display_wait_rc }, { "-h", 0, "--help", 0, 0, 0, "Display this help text and exit.", parse_help_commandline, 0 }, { "-v", 0, "--version", 0, 0, 0, "Display version and exit.", parse_version_commandline, 0 }, { 0, 0, 0, 0, 0, 0, 0 } }; colors_list fg_colors[] = { { "black", "" }, { "red", "" }, { "green", "" }, { "yellow", "" }, { "blue", "" }, { "magenta", "" }, { "cyan", "" }, { "white", "" }, { 0, 0 } }; colors_list bg_colors[] = { { "black", "" }, { "red", "" }, { "green", "" }, { "yellow", "" }, { "blue", "" }, { "magenta", "" }, { "cyan", "" }, { "white", "" }, { 0, 0 } }; void version(FILE *out) { fprintf(out, "%s version %s\n", PACKAGE, VERSION); } void help(FILE *out) { int o = 0; int screen_used = 0; char option_buffer[256]; fprintf(out, "Usage:\n"); fprintf(out, "\n"); /* * Print out short option usage: */ fprintf(out, " bar "); screen_used = 7; for (o = 0; options[o].cl_func != 0; o++) { char *short_option1 = options[o].short_option1; char *short_option2 = options[o].short_option2; char *arg_description = options[o].arg_description; sprintf(option_buffer, "[ %s%s%s%s%s ]", short_option1, (short_option2 != 0) ? "|" : "", (short_option2 != 0) ? short_option2 : "", (arg_description != 0) ? " " : "", (arg_description != 0) ? arg_description : "" ); if (d.screen_width - screen_used < strlen(option_buffer)) { fprintf(out, "\n "); screen_used = 7; } fprintf(out, "%s", option_buffer); screen_used += strlen(option_buffer); } fprintf(out, "\n"); fprintf(out, "\n"); /* * Print out long option usage: */ fprintf(out, " bar "); screen_used = 7; for (o = 0; options[o].cl_func != 0; o++) { char *long_option1 = options[o].long_option1; char *long_option2 = options[o].long_option2; char *arg_description = options[o].arg_description; sprintf(option_buffer, "[ %s%s%s%s%s ]", long_option1, (long_option2 != 0) ? "|" : "", (long_option2 != 0) ? long_option2 : "", (arg_description != 0) ? " " : "", (arg_description != 0) ? arg_description : "" ); if (d.screen_width - screen_used < strlen(option_buffer)) { fprintf(out, "\n "); screen_used = 7; } fprintf(out, "%s", option_buffer); screen_used += strlen(option_buffer); } fprintf(out, "\n"); fprintf(out, "\n"); /* * Print out help text */ for (o = 0; options[o].cl_func != 0; o++) { char *short_option1 = options[o].short_option1; char *short_option2 = options[o].short_option2; char *long_option1 = options[o].long_option1; char *long_option2 = options[o].long_option2; char *arg_description = options[o].arg_description; char *description = options[o].description; fprintf(out, " %s %s\n", short_option1, (arg_description != 0) ? arg_description : "" ); if (short_option2 != 0) { fprintf(out, " %s %s\n", short_option2, (arg_description != 0) ? arg_description : "" ); } fprintf(out, " %s %s\n", long_option1, (arg_description != 0) ? arg_description : "" ); if (long_option2 != 0) { fprintf(out, " %s %s\n", long_option2, (arg_description != 0) ? arg_description : "" ); } fprintf(out, "\n"); fprintf(out, " %s\n", description); fprintf(out, "\n"); } } int isOpt(char *s) { int o = 0; while (options[o].cl_func != 0) { if (strcmp(s, options[o].short_option1) == 0) return(o); if ((options[o].short_option2 != 0) && (strcmp(s, options[o].short_option2) == 0)) return(o); if (strcmp(s, options[o].long_option1) == 0) return(o); if ((options[o].long_option2 != 0) && (strcmp(s, options[o].long_option2) == 0)) return(o); if ((options[o].rc_option != 0) && (strcasecmp(s, options[o].rc_option) == 0)) return(o); o++; } return(-1); } int safe_add(uint64 *n, uint64 a) { uint64 t = *n; if (MAX_UINT64 - t < a) return(1); t += a; /* Check for some weird overflow thing that happens sometimes when * mistakenly compiling 32bit on a 64bit machine */ if (t < *n) return(1); *n = t; return(0); } int safe_mul(uint64 *n, uint64 x) { uint64 a1, a2; uint64 t = 0; uint64 multiplier; if (x < *n) { a1 = *n; a2 = x; } else { a2 = *n; a1 = x; } /* multiplier = 1; multiplier *= 1000; multiplier *= 1000; multiplier *= 1000; multiplier *= 1000; multiplier *= 1000; multiplier *= 1000; */ multiplier = MAX_SAFE_MULTIPLIER; while (a2 > 0) { while (multiplier > a2) multiplier /= 10; if (safe_add(&t, a1*multiplier) != 0) return(1); a2 -= multiplier; } *n = t; return(0); } int parse_char(FILE *ferr, char *s, char *c) { char ch = s[0]; if (strlen(s) == 0) return(0); if (ch == '\0') return(0); if (!isgraph(ch) && !isspace(ch)) { print_error(ferr, "Could not parse character: 0x%x (hex), %d (decimal)", ch, ch); print_esup(ferr, "Character must be pritable"); return(1); } *c = ch; return(0); } int parse_num(FILE *ferr, char *s, uint64 *n, uint64 min, uint64 max) { char *ptr_decimal = 0; char *ptr_unit = 0; char *ptr_start = 0; char *ptr_end = 0; char *ptr = 0; uint64 w = 0; uint64 f = 0; uint64 unit_multiplier = 1; uint64 multiplier = 0; uint64 tmp = 0; uint64 new_n = 0; size_t num_whole_part = 0; size_t num_fractional_part = 0; *n = 0; if (strlen(s) == 0) return(0); ptr_decimal = s; while ((*ptr_decimal != '\0') && (*ptr_decimal != '.')) ptr_decimal++; ptr_unit = s; while ((*ptr_unit != '\0') && (isdigit((int)*ptr_unit) || (*ptr_unit == '.'))) ptr_unit++; if ((*ptr_unit != '\0') && (*(ptr_unit+1) != '\0')) { print_error(ferr, "Could not parse number: %s", s); print_esup(ferr, "Unit multiplier parse error at: \"%s\"", ptr_unit); print_esup(ferr, "Unit multiplier should be the last character"); return(1); } if (*ptr_decimal != '\0') { num_whole_part = (size_t)(ptr_decimal - s); num_fractional_part = (size_t)(ptr_unit - ptr_decimal - 1); } else if (*ptr_unit != '\0') { num_whole_part = (size_t)(ptr_unit - s); } else { num_whole_part = strlen(s); } if ((num_whole_part == 0) && (num_fractional_part == 0)) { print_error(ferr, "Could not parse number: %s", s); print_esup(ferr, "No digits found"); return(1); } switch (toupper(*ptr_unit)) { case '\0': break; case 'K': unit_multiplier *= (uint64)d.k; break; case 'M': unit_multiplier *= (uint64)d.k; unit_multiplier *= (uint64)d.k; break; case 'G': unit_multiplier *= (uint64)d.k; unit_multiplier *= (uint64)d.k; unit_multiplier *= (uint64)d.k; break; case 'T': unit_multiplier *= (uint64)d.k; unit_multiplier *= (uint64)d.k; unit_multiplier *= (uint64)d.k; unit_multiplier *= (uint64)d.k; break; case 'P': unit_multiplier *= (uint64)d.k; unit_multiplier *= (uint64)d.k; unit_multiplier *= (uint64)d.k; unit_multiplier *= (uint64)d.k; unit_multiplier *= (uint64)d.k; break; case 'E': unit_multiplier *= (uint64)d.k; unit_multiplier *= (uint64)d.k; unit_multiplier *= (uint64)d.k; unit_multiplier *= (uint64)d.k; unit_multiplier *= (uint64)d.k; unit_multiplier *= (uint64)d.k; break; case 'B': if (_parsing_blocks == 0) { unit_multiplier *= (uint64)io.block_size; } else { print_error(ferr, "Cannot specify block size in terms of blocks"); print_esup(ferr, "Expected: 'k', 'm', 'g', 't', 'p', or 'e'"); return(1); } break; default: print_error(ferr, "Cannot parse number: %s", s); print_esup(ferr, "Invalid unit multiplier: '%c'", *ptr_unit); print_esup(ferr, "Expected: 'b', 'k', 'm', 'g', 't', 'p', or 'e'"); return(1); break; } ptr_start = s; if (*ptr_decimal == '.') ptr_end = ptr_decimal; else ptr_end = ptr_unit; multiplier = 1; if (ptr_start != ptr_end) { for (ptr = ptr_start+1; ptr != ptr_end; ptr++) { if (safe_mul(&multiplier, 10) != 0) { print_error(ferr, "Whole number precision error at: %s", ptr); print_esup(ferr, "Whole number portion too large"); return(1); } } } for (ptr = ptr_start; ptr != ptr_end; ptr++) { tmp = (uint64)((*ptr) - '0'); if (tmp != 0) { if (safe_mul(&tmp, multiplier) != 0) { print_error(ferr, "Multiplication overflow error"); print_esup(ferr, "Could not parse number at: %s", ptr); return(1); } if (safe_add(&w, tmp) != 0) { print_error(ferr, "Addition overflow error"); print_esup(ferr, "Could not parse number at: %s", ptr); return(1); } } multiplier /= 10; } if (safe_mul(&w, unit_multiplier) != 0) { print_error(ferr, "Multiplication overflow error"); print_esup(ferr, "Number too large: %s", s); return(1); } if (*ptr_decimal == '.') { ptr_start = ptr_decimal+1; ptr_end = ptr_unit; multiplier = 1; for (ptr = ptr_start; ptr != ptr_end; ptr++) { tmp = (*ptr) - '0'; if (tmp != 0) { if (safe_mul(&tmp, unit_multiplier) != 0) { print_error(ferr, "Multiplication overflow error"); print_esup(ferr, "Could not parse fraction at: %s", ptr); return(1); } tmp /= multiplier; tmp += 5; tmp /= 10; if (safe_add(&f, tmp) != 0) { print_error(ferr, "Addition overflow error"); print_esup(ferr, "Could not parse fraction at: %s", ptr); } } if (safe_mul(&multiplier, 10) != 0) { print_error(ferr, "Multiplication overflow error"); print_esup(ferr, "Could not parse fraction at: %s", ptr); return(1); } if (multiplier > unit_multiplier) break; } } new_n = w; if (safe_add(&new_n, f) != 0) { print_error(ferr, "Addition overflow error"); print_esup(ferr, "Number too large: %s", s); return(1); } if (new_n < min) { print_error(ferr, "Number too small: %s", s); print_esup(ferr, "Value must be %llu or greater", UINT64_CTYPE(min)); return(1); } if (new_n > max) { print_error(ferr, "Number too large: %s", s); print_esup(ferr, "Value must be %llu or less", UINT64_CTYPE(max)); return(1); } *n = new_n; return(0); } int parse_infile_value(FILE *ferr, char *value) { if (strcmp(value, "-") != 0) { io.in = open(value, O_RDONLY #ifdef O_LARGEFILE |O_LARGEFILE #endif ); if (io.in < 0) { print_error(ferr, "Cannot open file for reading: %s", value); return(1); } if (fdIsFile(io.in) && fdFileSize(io.in, &io.total_size) == 0) { io.total_size_known = 1; } io.in_path = value; } return(0); } int parse_infile_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { if ((*arg_num)+1 == argc) { print_error(ferr, "Missing filename after %s", argv[(*arg_num)]); return(1); } if (parse_infile_value(ferr, argv[(*arg_num)+1]) != 0) return(1); (*arg_num)++; return(0); } int parse_outfile_value(FILE *ferr, char *value) { struct stat st; char str[4096] = { 0 }; char copy_flag = 0; char *basename = 0; if (stat(value, &st) == 0) { if (S_ISDIR(st.st_mode)) { if (io.in_path == 0) { print_error(ferr, "No input file specified"); return(1); } basename = io.in_path + strlen(io.in_path); while ((basename != io.in_path) && (*basename != '/')) { basename--; } if (*basename == '/') { basename++; } if (strcpy(str,value) == 0) { print_error(ferr, "strcpy() failed constructing output filename"); return(1); } if (strcat(str,"/") == 0) { print_error(ferr, "strcat() failed constructing output filename"); return(1); } if (strcat(str,basename) == 0) { print_error(ferr, "strcat() failed constructing output filename"); return(1); } value = str; copy_flag = 1; } } if (strcmp(value, "-") != 0) { io.out = open(value, O_WRONLY|O_CREAT #ifdef O_LARGEFILE |O_LARGEFILE #endif , S_IRUSR|S_IWUSR|S_IRGRP|S_IWGRP|S_IROTH|S_IWOTH); if (io.out < 0) { print_error(ferr, "Cannot open file for writing: %s", value); return(1); } } if (copy_flag == 1) { if (chmod(str,st.st_mode) != 0) { print_error(ferr, "Cannot set file modes on output file: %s", value); } } return(0); } int parse_outfile_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { if ((*arg_num)+1 == argc) { print_error(ferr, "Missing filename after %s", argv[(*arg_num)]); return(1); } if (parse_outfile_value(ferr, argv[(*arg_num)+1]) != 0) return(1); (*arg_num)++; return(0); } int parse_size_value(FILE *ferr, char *value) { uint64 n = 0; if (parse_num(ferr, value, &n, 0, MAX_UINT64) != 0) { return(1); } io.total_size = n; io.total_size_known = 1; return(0); } int parse_completed_value(FILE *ferr, char *value) { uint64 n = 0; if (parse_num(ferr, value, &n, 0, MAX_UINT64) != 0) { return(1); } io.total_read = n; io.total_write = n; io.continue_size = n; return(0); } int parse_throttle_value(FILE *ferr, char *value) { uint64 n = 0; if (parse_num(ferr, value, &n, 0, MAX_UINT64) != 0) { return(1); } io.throttle = n+1; return(0); } int parse_size_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { if ((*arg_num)+1 == argc) { print_error(ferr, "Missing size after %s", argv[(*arg_num)]); return(1); } parse_size_value(ferr, argv[(*arg_num)+1]); (*arg_num)++; return(0); } int parse_completed_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { if ((*arg_num)+1 == argc) { print_error(ferr, "Missing size after %s", argv[(*arg_num)]); return(1); } parse_completed_value(ferr, argv[(*arg_num)+1]); (*arg_num)++; return(0); } int parse_throttle_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { if ((*arg_num)+1 == argc) { print_error(ferr, "Missing rate after %s", argv[(*arg_num)]); return(1); } parse_throttle_value(ferr, argv[(*arg_num)+1]); (*arg_num)++; return(0); } int parse_throttle_rc(FILE *ferr, char* filename, int line, char *tag, char *value) { if (parse_throttle_value(ferr, value) != 0) { print_esup(ferr, "In file: %s[%d]", filename, line); return(1); } return(0); } int parse_buffer_size_value(FILE *ferr, char *value) { uint64 n = 0; if (parse_num(ferr, value, &n, 1, MAX_SIZE_T) != 0) { return(1); } io.buffer_size = (size_t)n; return(0); } int parse_buffer_size_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { if ((*arg_num)+1 == argc) { print_error(ferr, "Missing size after %s", argv[(*arg_num)]); return(1); } parse_buffer_size_value(ferr, argv[(*arg_num)+1]); (*arg_num)++; return(0); } int parse_buffer_size_rc(FILE *ferr, char* filename, int line, char *tag, char *value) { if (parse_buffer_size_value(ferr, value) != 0) { print_esup(ferr, "In file: %s[%d]", filename, line); return(1); } return(0); } int parse_block_size_value(FILE *ferr, char *value) { uint64 n = 0; int r; _parsing_blocks = 1; /* Shameless hack */ r = parse_num(ferr, value, &n, 1, MAX_SIZE_T); _parsing_blocks = 0; /* Shameless hack */ if (r != 0) { return(1); } io.block_size = (size_t)n; return(0); } int parse_block_size_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { if ((*arg_num)+1 == argc) { print_error(ferr, "Missing size after %s", argv[(*arg_num)]); return(1); } parse_block_size_value(ferr, argv[(*arg_num)+1]); (*arg_num)++; return(0); } int parse_block_size_rc(FILE *ferr, char* filename, int line, char *tag, char *value) { if (parse_block_size_value(ferr, value) != 0) { print_esup(ferr, "In file: %s[%d]", filename, line); return(1); } return(0); } int parse_interval_value(FILE *ferr, char *value) { int n = 0; char check[4096] = { 0 }; sscanf(value, "%d", &n); sprintf(check, "%d", n); if (strcmp(value, check) != 0) { print_error(ferr, "Type mismatch or number too large: %s", value); return(1); } if ((n < 1) || (n > 60*60*24)) { print_error(ferr, "Invalid display interval: %s", value); return(1); } d.display_interval = n; return(0); } int parse_interval_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { if ((*arg_num)+1 == argc) { print_error(ferr, "Missing seconds after %s", argv[(*arg_num)]); return(1); } if (parse_interval_value(ferr, argv[(*arg_num)+1]) != 0) print_esup(ferr, "Ignoring given interval"); (*arg_num)++; return(0); } int parse_interval_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { if (parse_interval_value(ferr, value) != 0) { print_esup(ferr, "In file: %s[%d]", filename, line); return(1); } return(0); } int parse_timeout_value(FILE *ferr, char *value) { unsigned long n = 0; char check[4096] = { 0 }; sscanf(value, "%lu", &n); sprintf(check, "%lu", n); if (strcmp(value, check) != 0) { print_error(ferr, "Type mismatch or number too large: %s", value); return(1); } if (n > 999999) { print_error(ferr, "Type mismatch or number too large: %s", value); return(1); } io.timeout = (uint32)n; return(0); } int parse_timeout_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { if ((*arg_num)+1 == argc) { print_error(ferr, "Missing microseconds after %s", argv[(*arg_num)]); return(1); } if (parse_timeout_value(ferr, argv[(*arg_num)+1]) != 0) print_esup(ferr, "Ignoring given timeout"); (*arg_num)++; return(0); } int parse_timeout_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { if (parse_timeout_value(ferr, value) != 0) { print_esup(ferr, "In file: %s[%d]", filename, line); return(1); } return(0); } int parse_kilo_value(FILE *ferr, char *value) { if (strcmp(value, "1000") == 0) { d.k = 1000; return(0); } if (strcmp(value, "1024") == 0) { d.k = 1024; return(0); } return(1); } int parse_kilo_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { if ((*arg_num)+1 == argc) { print_error(ferr, "Missing option after %s", argv[(*arg_num)]); return(1); } if (parse_kilo_value(ferr, argv[(*arg_num)+1]) != 0) { print_error(ferr, "Invalid option for %s: %s", argv[(*arg_num)], argv[(*arg_num)+1]); return(1); } (*arg_num)++; return(0); } int parse_kilo_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { if (parse_kilo_value(ferr, value) != 0) { print_esup(ferr, "In file: %s[%d]", filename, line); return(1); } return(0); } int parse_width_value(FILE *ferr, char *value) { int n = 0; sscanf(value, "%d", &n); if (n < 1) { print_error(ferr, "Invalid screen width: %s", value); return(1); } d.screen_width = n; d.manual_width = 1; return(0); } int parse_height_value(FILE *ferr, char *value) { int n = 0; sscanf(value, "%d", &n); if (n < 1) { print_error(ferr, "Invalid screen height: %s", value); return(1); } d.screen_height = n; d.manual_height = 1; return(0); } int parse_width_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { if ((*arg_num)+1 == argc) { print_error(ferr, "Missing width after %s", argv[(*arg_num)]); return(1); } if (parse_width_value(ferr, argv[(*arg_num)+1]) != 0) return(1); (*arg_num)++; return(0); } int parse_height_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { if ((*arg_num)+1 == argc) { print_error(ferr, "Missing height after %s", argv[(*arg_num)]); return(1); } if (parse_height_value(ferr, argv[(*arg_num)+1]) != 0) return(1); (*arg_num)++; return(0); } int parse_width_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { if (parse_width_value(ferr, value) != 0) { print_esup(ferr, "In file: %s[%d]", filename, line); return(1); } return(0); } int parse_height_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { if (parse_height_value(ferr, value) != 0) { print_esup(ferr, "In file: %s[%d]", filename, line); return(1); } return(0); } int parse_switch_commandline(char *arg, options_list *option, int *sw) { if ((option->short_option1 != 0) && (strcmp(arg, option->short_option1) == 0)) (*sw) = 1; if ((option->long_option1 != 0) && (strcmp(arg, option->long_option1) == 0)) (*sw) = 1; if ((option->short_option2 != 0) && (strcmp(arg, option->short_option2) == 0)) (*sw) = 0; if ((option->long_option2 != 0) && (strcmp(arg, option->long_option2) == 0)) (*sw) = 0; return(0); } int parse_switch_rc(FILE *ferr, char *filename, int line, char *value, int *sw) { if ((strcasecmp(value, "on") == 0) || (strcasecmp(value, "yes") == 0) || (strcasecmp(value, "y") == 0) || (strcasecmp(value, "true") == 0) || (strcasecmp(value, "t") == 0) || (strcasecmp(value, "1") == 0) ) { (*sw) = 1; } else if ((strcasecmp(value, "off") == 0) || (strcasecmp(value, "no") == 0) || (strcasecmp(value, "n") == 0) || (strcasecmp(value, "false") == 0) || (strcasecmp(value, "f") == 0) || (strcasecmp(value, "0") == 0) ) { (*sw) = 0; } else { print_error(ferr, "Parse error in rc file: %s[%d]", filename, line); print_esup(ferr, "Unknown switch value: %s", value); return(1); } return(0); } int parse_switch_all_commandline(char *arg, options_list *option) { if ((option->short_option1 != 0) && (strcmp(arg, option->short_option1) == 0)) { d.display_twiddle = 1; d.display_title = 1; d.display_datacount = 1; d.display_throughput = 1; d.display_time = 1; d.display_percent = 1; d.display_bar = 1; d.display_summary = 1; } if ((option->long_option1 != 0) && (strcmp(arg, option->long_option1) == 0)) { d.display_twiddle = 1; d.display_title = 1; d.display_datacount = 1; d.display_throughput = 1; d.display_time = 1; d.display_percent = 1; d.display_bar = 1; d.display_summary = 1; } if ((option->short_option2 != 0) && (strcmp(arg, option->short_option2) == 0)) { d.display_twiddle = 0; d.display_title = 0; d.display_datacount = 0; d.display_throughput = 0; d.display_time = 0; d.display_percent = 0; d.display_bar = 0; d.display_summary = 0; } if ((option->long_option2 != 0) && (strcmp(arg, option->long_option2) == 0)) { d.display_twiddle = 0; d.display_title = 0; d.display_datacount = 0; d.display_throughput = 0; d.display_time = 0; d.display_percent = 0; d.display_bar = 0; d.display_summary = 0; } return(0); } int parse_width_minus_one_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.screen_width_minus_one ); return(r); } int parse_width_minus_one_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.screen_width_minus_one ); return(r); } int parse_height_minus_one_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.screen_height_minus_one ); return(r); } int parse_height_minus_one_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.screen_height_minus_one ); return(r); } int parse_twiddle_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.display_twiddle ); return(r); } int parse_twiddle_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.display_twiddle ); return(r); } int parse_count_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.display_datacount ); return(r); } int parse_count_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.display_datacount ); return(r); } int parse_throughput_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.display_throughput ); return(r); } int parse_throughput_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.display_throughput ); return(r); } int parse_time_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.display_time ); return(r); } int parse_elapsed_only_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.display_elapsed_only ); return(r); } int parse_time_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.display_time ); return(r); } int parse_elapsed_only_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.display_elapsed_only ); return(r); } int parse_percent_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.display_percent ); return(r); } int parse_percent_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.display_percent ); return(r); } int parse_bar_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.display_bar ); return(r); } int parse_bar_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.display_bar ); return(r); } int parse_title_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { if ((*arg_num)+1 == argc) { print_error(ferr, "Missing title string after %s", argv[(*arg_num)]); return(1); } sprintf(d.title, "%.*s", 80, argv[(*arg_num)+1]); (*arg_num)++; return(0); } int parse_title_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { sprintf(d.title, "%.*s", 80, value); return(0); } int parse_total_percent_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.total_display_percent ); return(r); } int parse_total_percent_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.total_display_percent ); return(r); } int parse_summary_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.display_summary ); return(r); } int parse_summary_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.display_summary ); return(r); } int parse_display_title_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.display_title ); return(r); } int parse_display_title_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.display_title ); return(r); } int parse_ansi_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.display_ansi ); return(r); } int parse_ansi_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.display_ansi ); return(r); } int parse_throughput_bits_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.display_throughput_bits ); return(r); } int parse_count_bits_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.display_count_bits ); return(r); } int parse_displays_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_all_commandline( argv[(*arg_num)], &options[option_num] ); return(r); } int parse_help_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { help(ferr); return(1); } int parse_version_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { version(ferr); return(1); } int parse_throughput_bits_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.display_throughput_bits ); return(r); } int parse_count_bits_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.display_count_bits ); return(r); } int isColor(char *s, colors_list *list) { int c = 0; while (list[c].name != 0) { if (strcasecmp(s, list[c].name) == 0) return(c); c++; } return(-1); } int parse_color(FILE *ferr, char *value, colors_list *list, char **code_ptr) { int c; *code_ptr = 0; if (strcasecmp(value, "normal") == 0) return(0); c = isColor(value, list); if (c == -1) { print_error(ferr, "Invalid color: %s", value); return(1); } *code_ptr = list[c].code; return(0); } int parse_space_bg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { char *code = 0; if ((*arg_num)+1 == argc) { print_error(ferr, "Missing color name after %s", argv[(*arg_num)]); print_esup(ferr, "Ignoring color code"); return(0); } if (parse_color(ferr, argv[(*arg_num)+1], bg_colors, &code) != 0) print_esup(ferr, "Ignoring color code"); else { d.space_bg_color = code; } (*arg_num)++; return(0); } int parse_space_bg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { char *code = 0; if (parse_color(ferr, value, bg_colors, &code) != 0) { print_esup(ferr, "in file: %s[%d]", filename, line); return(1); } d.space_bg_color = code; return(0); } int parse_twiddle_fg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { char *code = 0; if ((*arg_num)+1 == argc) { print_error(ferr, "Missing color name after %s", argv[(*arg_num)]); print_esup(ferr, "Ignoring color code"); return(0); } if (parse_color(ferr, argv[(*arg_num)+1], fg_colors, &code) != 0) print_esup(ferr, "Ignoring color code"); else { d.twiddle_fg_color = code; } (*arg_num)++; return(0); } int parse_twiddle_fg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { char *code = 0; if (parse_color(ferr, value, fg_colors, &code) != 0) { print_esup(ferr, "In file: %s[%d]", filename, line); return(1); } d.twiddle_fg_color = code; return(0); } int parse_twiddle_bg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { char *code = 0; if ((*arg_num)+1 == argc) { print_error(ferr, "Missing color name after %s", argv[(*arg_num)]); print_esup(ferr, "Ignoring color code"); return(0); } if (parse_color(ferr, argv[(*arg_num)+1], bg_colors, &code) != 0) print_esup(ferr, "Ignoring color code"); else { d.twiddle_bg_color = code; } (*arg_num)++; return(0); } int parse_twiddle_bg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { char *code = 0; if (parse_color(ferr, value, bg_colors, &code) != 0) { print_esup(ferr, "in file: %s[%d]", filename, line); return(1); } d.twiddle_bg_color = code; return(0); } int parse_twiddle_fg_bold_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.twiddle_fg_bold ); return(r); } int parse_twiddle_fg_bold_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.twiddle_fg_bold ); return(r); } int parse_title_fg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { char *code = 0; if ((*arg_num)+1 == argc) { print_error(ferr, "Missing color name after %s", argv[(*arg_num)]); print_esup(ferr, "Ignoring color code"); return(0); } if (parse_color(ferr, argv[(*arg_num)+1], fg_colors, &code) != 0) print_esup(ferr, "Ignoring color code"); else { d.title_fg_color = code; } (*arg_num)++; return(0); } int parse_title_fg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { char *code = 0; if (parse_color(ferr, value, fg_colors, &code) != 0) { print_esup(ferr, "In file: %s[%d]", filename, line); return(1); } d.title_fg_color = code; return(0); } int parse_title_bg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { char *code = 0; if ((*arg_num)+1 == argc) { print_error(ferr, "Missing color name after %s", argv[(*arg_num)]); print_esup(ferr, "Ignoring color code"); return(0); } if (parse_color(ferr, argv[(*arg_num)+1], bg_colors, &code) != 0) print_esup(ferr, "Ignoring color code"); else { d.title_bg_color = code; } (*arg_num)++; return(0); } int parse_title_bg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { char *code = 0; if (parse_color(ferr, value, bg_colors, &code) != 0) { print_esup(ferr, "in file: %s[%d]", filename, line); return(1); } d.title_bg_color = code; return(0); } int parse_title_fg_bold_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.title_fg_bold ); return(r); } int parse_title_fg_bold_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.title_fg_bold ); return(r); } int parse_count_fg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { char *code = 0; if ((*arg_num)+1 == argc) { print_error(ferr, "Missing color name after %s", argv[(*arg_num)]); print_esup(ferr, "Ignoring color code"); return(0); } if (parse_color(ferr, argv[(*arg_num)+1], fg_colors, &code) != 0) print_esup(ferr, "Ignoring color code"); else { d.datacount_fg_color = code; } (*arg_num)++; return(0); } int parse_count_fg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { char *code = 0; if (parse_color(ferr, value, fg_colors, &code) != 0) { print_esup(ferr, "In file: %s[%d]", filename, line); return(1); } d.datacount_fg_color = code; return(0); } int parse_count_bg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { char *code = 0; if ((*arg_num)+1 == argc) { print_error(ferr, "Missing color name after %s", argv[(*arg_num)]); print_esup(ferr, "Ignoring color code"); return(0); } if (parse_color(ferr, argv[(*arg_num)+1], bg_colors, &code) != 0) print_esup(ferr, "Ignoring color code"); else { d.datacount_bg_color = code; } (*arg_num)++; return(0); } int parse_count_bg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { char *code = 0; if (parse_color(ferr, value, bg_colors, &code) != 0) { print_esup(ferr, "in file: %s[%d]", filename, line); return(1); } d.datacount_bg_color = code; return(0); } int parse_count_fg_bold_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.datacount_fg_bold ); return(r); } int parse_count_fg_bold_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.datacount_fg_bold ); return(r); } int parse_throughput_label_fg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { char *code = 0; if ((*arg_num)+1 == argc) { print_error(ferr, "Missing color name after %s", argv[(*arg_num)]); print_esup(ferr, "Ignoring color code"); return(0); } if (parse_color(ferr, argv[(*arg_num)+1], fg_colors, &code) != 0) print_esup(ferr, "Ignoring color code"); else { d.throughput_label_fg_color = code; } (*arg_num)++; return(0); } int parse_throughput_label_fg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { char *code = 0; if (parse_color(ferr, value, fg_colors, &code) != 0) { print_esup(ferr, "In file: %s[%d]", filename, line); return(1); } d.throughput_label_fg_color = code; return(0); } int parse_throughput_label_bg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { char *code = 0; if ((*arg_num)+1 == argc) { print_error(ferr, "Missing color name after %s", argv[(*arg_num)]); print_esup(ferr, "Ignoring color code"); return(0); } if (parse_color(ferr, argv[(*arg_num)+1], bg_colors, &code) != 0) print_esup(ferr, "Ignoring color code"); else { d.throughput_label_bg_color = code; } (*arg_num)++; return(0); } int parse_throughput_label_bg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { char *code = 0; if (parse_color(ferr, value, bg_colors, &code) != 0) { print_esup(ferr, "in file: %s[%d]", filename, line); return(1); } d.throughput_label_bg_color = code; return(0); } int parse_throughput_label_fg_bold_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.throughput_label_fg_bold ); return(r); } int parse_throughput_label_fg_bold_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.throughput_label_fg_bold ); return(r); } int parse_throughput_fg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { char *code = 0; if ((*arg_num)+1 == argc) { print_error(ferr, "Missing color name after %s", argv[(*arg_num)]); print_esup(ferr, "Ignoring color code"); return(0); } if (parse_color(ferr, argv[(*arg_num)+1], fg_colors, &code) != 0) print_esup(ferr, "Ignoring color code"); else { d.throughput_fg_color = code; } (*arg_num)++; return(0); } int parse_throughput_fg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { char *code = 0; if (parse_color(ferr, value, fg_colors, &code) != 0) { print_esup(ferr, "In file: %s[%d]", filename, line); return(1); } d.throughput_fg_color = code; return(0); } int parse_throughput_bg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { char *code = 0; if ((*arg_num)+1 == argc) { print_error(ferr, "Missing color name after %s", argv[(*arg_num)]); print_esup(ferr, "Ignoring color code"); return(0); } if (parse_color(ferr, argv[(*arg_num)+1], bg_colors, &code) != 0) print_esup(ferr, "Ignoring color code"); else { d.throughput_bg_color = code; } (*arg_num)++; return(0); } int parse_throughput_bg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { char *code = 0; if (parse_color(ferr, value, bg_colors, &code) != 0) { print_esup(ferr, "in file: %s[%d]", filename, line); return(1); } d.throughput_bg_color = code; return(0); } int parse_throughput_fg_bold_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.throughput_fg_bold ); return(r); } int parse_throughput_fg_bold_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.throughput_fg_bold ); return(r); } int parse_time_label_fg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { char *code = 0; if ((*arg_num)+1 == argc) { print_error(ferr, "Missing color name after %s", argv[(*arg_num)]); print_esup(ferr, "Ignoring color code"); return(0); } if (parse_color(ferr, argv[(*arg_num)+1], fg_colors, &code) != 0) print_esup(ferr, "Ignoring color code"); else { d.time_label_fg_color = code; } (*arg_num)++; return(0); } int parse_time_label_fg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { char *code = 0; if (parse_color(ferr, value, fg_colors, &code) != 0) { print_esup(ferr, "In file: %s[%d]", filename, line); return(1); } d.time_label_fg_color = code; return(0); } int parse_time_label_bg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { char *code = 0; if ((*arg_num)+1 == argc) { print_error(ferr, "Missing color name after %s", argv[(*arg_num)]); print_esup(ferr, "Ignoring color code"); return(0); } if (parse_color(ferr, argv[(*arg_num)+1], bg_colors, &code) != 0) print_esup(ferr, "Ignoring color code"); else { d.time_label_bg_color = code; } (*arg_num)++; return(0); } int parse_time_label_bg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { char *code = 0; if (parse_color(ferr, value, bg_colors, &code) != 0) { print_esup(ferr, "in file: %s[%d]", filename, line); return(1); } d.time_label_bg_color = code; return(0); } int parse_time_label_fg_bold_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.time_label_fg_bold ); return(r); } int parse_time_label_fg_bold_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.time_label_fg_bold ); return(r); } int parse_time_fg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { char *code = 0; if ((*arg_num)+1 == argc) { print_error(ferr, "Missing color name after %s", argv[(*arg_num)]); print_esup(ferr, "Ignoring color code"); return(0); } if (parse_color(ferr, argv[(*arg_num)+1], fg_colors, &code) != 0) print_esup(ferr, "Ignoring color code"); else { d.time_fg_color = code; } (*arg_num)++; return(0); } int parse_time_fg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { char *code = 0; if (parse_color(ferr, value, fg_colors, &code) != 0) { print_esup(ferr, "In file: %s[%d]", filename, line); return(1); } d.time_fg_color = code; return(0); } int parse_time_bg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { char *code = 0; if ((*arg_num)+1 == argc) { print_error(ferr, "Missing color name after %s", argv[(*arg_num)]); print_esup(ferr, "Ignoring color code"); return(0); } if (parse_color(ferr, argv[(*arg_num)+1], bg_colors, &code) != 0) print_esup(ferr, "Ignoring color code"); else { d.time_bg_color = code; } (*arg_num)++; return(0); } int parse_time_bg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { char *code = 0; if (parse_color(ferr, value, bg_colors, &code) != 0) { print_esup(ferr, "in file: %s[%d]", filename, line); return(1); } d.time_bg_color = code; return(0); } int parse_time_fg_bold_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.time_fg_bold ); return(r); } int parse_time_fg_bold_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.time_fg_bold ); return(r); } int parse_percent_fg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { char *code = 0; if ((*arg_num)+1 == argc) { print_error(ferr, "Missing color name after %s", argv[(*arg_num)]); print_esup(ferr, "Ignoring color code"); return(0); } if (parse_color(ferr, argv[(*arg_num)+1], fg_colors, &code) != 0) print_esup(ferr, "Ignoring color code"); else { d.percent_fg_color = code; } (*arg_num)++; return(0); } int parse_percent_fg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { char *code = 0; if (parse_color(ferr, value, fg_colors, &code) != 0) { print_esup(ferr, "In file: %s[%d]", filename, line); return(1); } d.percent_fg_color = code; return(0); } int parse_percent_bg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { char *code = 0; if ((*arg_num)+1 == argc) { print_error(ferr, "Missing color name after %s", argv[(*arg_num)]); print_esup(ferr, "Ignoring color code"); return(0); } if (parse_color(ferr, argv[(*arg_num)+1], bg_colors, &code) != 0) print_esup(ferr, "Ignoring color code"); else { d.percent_bg_color = code; } (*arg_num)++; return(0); } int parse_percent_bg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { char *code = 0; if (parse_color(ferr, value, bg_colors, &code) != 0) { print_esup(ferr, "in file: %s[%d]", filename, line); return(1); } d.percent_bg_color = code; return(0); } int parse_percent_fg_bold_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.percent_fg_bold ); return(r); } int parse_percent_fg_bold_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.percent_fg_bold ); return(r); } int parse_bar_openbrace_char_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { char ch = '\0'; if ((*arg_num)+1 == argc) { print_error(ferr, "Missing bar open brace character after %s", argv[(*arg_num)]); print_esup(ferr, "Ignoring bar open brace character"); return(0); } if (parse_char(ferr, argv[(*arg_num)+1], &ch) != 0) print_esup(ferr, "Ignoring bar open brace character"); else { d.bar_open_brace = ch; } (*arg_num)++; return(0); } int parse_bar_openbrace_char_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { if (parse_char(ferr, value, &d.bar_open_brace) != 0) { print_esup(ferr, "In file: %s[%d]", filename, line); return(1); } return(0); } int parse_bar_closebrace_char_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { char ch = '\0'; if ((*arg_num)+1 == argc) { print_error(ferr, "Missing bar close brace character after %s", argv[(*arg_num)]); print_esup(ferr, "Ignoring bar close brace character"); return(0); } if (parse_char(ferr, argv[(*arg_num)+1], &ch) != 0) print_esup(ferr, "Ignoring bar close brace character"); else { d.bar_close_brace = ch; } (*arg_num)++; return(0); } int parse_bar_closebrace_char_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { if (parse_char(ferr, value, &d.bar_close_brace) != 0) { print_esup(ferr, "In file: %s[%d]", filename, line); return(1); } return(0); } int parse_bar_complete_char_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { char ch = '\0'; if ((*arg_num)+1 == argc) { print_error(ferr, "Missing bar complete character after %s", argv[(*arg_num)]); print_esup(ferr, "Ignoring bar complete character"); return(0); } if (parse_char(ferr, argv[(*arg_num)+1], &ch) != 0) print_esup(ferr, "Ignoring bar complete character"); else { d.bar_complete = ch; } (*arg_num)++; return(0); } int parse_bar_complete_char_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { if (parse_char(ferr, value, &d.bar_complete) != 0) { print_esup(ferr, "In file: %s[%d]", filename, line); return(1); } return(0); } int parse_bar_incomplete_char_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { char ch = '\0'; if ((*arg_num)+1 == argc) { print_error(ferr, "Missing bar incomplete character after %s", argv[(*arg_num)]); print_esup(ferr, "Ignoring bar incomplete character"); return(0); } if (parse_char(ferr, argv[(*arg_num)+1], &ch) != 0) print_esup(ferr, "Ignoring bar incomplete character"); else { d.bar_incomplete = ch; } (*arg_num)++; return(0); } int parse_bar_incomplete_char_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { if (parse_char(ferr, value, &d.bar_incomplete) != 0) { print_esup(ferr, "In file: %s[%d]", filename, line); return(1); } return(0); } int parse_barbrace_fg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { char *code = 0; if ((*arg_num)+1 == argc) { print_error(ferr, "Missing color name after %s", argv[(*arg_num)]); print_esup(ferr, "Ignoring color code"); return(0); } if (parse_color(ferr, argv[(*arg_num)+1], fg_colors, &code) != 0) print_esup(ferr, "Ignoring color code"); else { d.barbrace_fg_color = code; } (*arg_num)++; return(0); } int parse_barbrace_fg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { char *code = 0; if (parse_color(ferr, value, fg_colors, &code) != 0) { print_esup(ferr, "In file: %s[%d]", filename, line); return(1); } d.barbrace_fg_color = code; return(0); } int parse_barbrace_bg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { char *code = 0; if ((*arg_num)+1 == argc) { print_error(ferr, "Missing color name after %s", argv[(*arg_num)]); print_esup(ferr, "Ignoring color code"); return(0); } if (parse_color(ferr, argv[(*arg_num)+1], bg_colors, &code) != 0) print_esup(ferr, "Ignoring color code"); else { d.barbrace_bg_color = code; } (*arg_num)++; return(0); } int parse_barbrace_bg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { char *code = 0; if (parse_color(ferr, value, bg_colors, &code) != 0) { print_esup(ferr, "in file: %s[%d]", filename, line); return(1); } d.barbrace_bg_color = code; return(0); } int parse_barbrace_fg_bold_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.barbrace_fg_bold ); return(r); } int parse_barbrace_fg_bold_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.barbrace_fg_bold ); return(r); } int parse_bar_fg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { char *code = 0; if ((*arg_num)+1 == argc) { print_error(ferr, "Missing color name after %s", argv[(*arg_num)]); print_esup(ferr, "Ignoring color code"); return(0); } if (parse_color(ferr, argv[(*arg_num)+1], fg_colors, &code) != 0) print_esup(ferr, "Ignoring color code"); else { d.bar_fg_color = code; } (*arg_num)++; return(0); } int parse_bar_fg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { char *code = 0; if (parse_color(ferr, value, fg_colors, &code) != 0) { print_esup(ferr, "In file: %s[%d]", filename, line); return(1); } d.bar_fg_color = code; return(0); } int parse_bar_bg_color_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { char *code = 0; if ((*arg_num)+1 == argc) { print_error(ferr, "Missing color name after %s", argv[(*arg_num)]); print_esup(ferr, "Ignoring color code"); return(0); } if (parse_color(ferr, argv[(*arg_num)+1], bg_colors, &code) != 0) print_esup(ferr, "Ignoring color code"); else { d.bar_bg_color = code; } (*arg_num)++; return(0); } int parse_bar_bg_color_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { char *code = 0; if (parse_color(ferr, value, bg_colors, &code) != 0) { print_esup(ferr, "in file: %s[%d]", filename, line); return(1); } d.bar_bg_color = code; return(0); } int parse_bar_fg_bold_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.bar_fg_bold ); return(r); } int parse_bar_fg_bold_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.bar_fg_bold ); return(r); } int parse_infofile_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { if ((*arg_num)+1 == argc) { print_error(ferr, "Missing pathname after %s", argv[(*arg_num)]); return(1); } d.info_file = argv[(*arg_num)+1]; (*arg_num)++; return(0); } int parse_infofile_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { d.info_file = value; return(0); } int parse_display_numeric_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.display_numeric ); return(r); } int parse_display_numeric_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.display_numeric ); return(r); } int parse_display_wait_commandline(FILE *ferr, int argc, char *argv[], int *arg_num, int option_num) { int r; r = parse_switch_commandline( argv[(*arg_num)], &options[option_num], &d.display_wait ); return(r); } int parse_display_wait_rc(FILE *ferr, char *filename, int line, char *tag, char *value) { int r; r = parse_switch_rc(ferr, filename, line, value, &d.display_wait ); return(r); } int parse_args(FILE *ferr, int argc, char *argv[]) { int c = 0; int o = 0; for (c = 1; c < argc; c++) { o = isOpt(argv[c]); if (o != -1) { if (options[o].cl_func == parse_kilo_commandline) { if (options[o].cl_func(ferr, argc, argv, &c, o) != 0) return(1); } else if (options[o].cl_func == parse_help_commandline) { if (options[o].cl_func(ferr, argc, argv, &c, o) != 0) return(1); } else if (options[o].cl_func == parse_version_commandline) { if (options[o].cl_func(ferr, argc, argv, &c, o) != 0) return(1); } else if (options[o].cl_func == parse_block_size_commandline) { if (options[o].cl_func(ferr, argc, argv, &c, 0) != 0) return(1); } else if (options[o].arg_description != 0) { c++; } } } for (c = 1; c < argc; c++) { o = isOpt(argv[c]); if (o == -1) { if (io.in == STDIN_FILENO) { if (parse_infile_value(ferr,argv[c]) != 0) { return(1); } } else if (io.out == STDOUT_FILENO) { if (parse_outfile_value(ferr,argv[c]) != 0) { return(1); } } else { print_error(ferr, "Unknown command line option: %s", argv[c]); return(1); } } else { if (options[o].cl_func(ferr, argc, argv, &c, o) != 0) return(1); } } return(0); } int parse_rc_by_tag(FILE *ferr, char* filename, int line, char *tag, char *value) { int o = 0; o = isOpt(tag); if (o == -1) { print_error(ferr, "Parse error in rc file: %s[%d]", filename, line); print_esup(ferr, "Unknown tag: %s", tag); return(1); } if (options[o].rc_func(ferr, filename, line, tag, value) != 0) return(1); return(0); } int parse_rcfile(FILE *ferr, char *filename) { FILE *rcfile = 0; char tag[80]; char value[80]; int c; int line = 0; char ch; if (access(filename, F_OK) != 0) return(0); rcfile = fopen(filename, "r"); if (rcfile == 0) { print_error(ferr, "Cannot open rc file for reading: %s", filename); return(1); } while (!feof(rcfile)) { line++; for (c = 0; c < 80; c++) { tag[c] = 0; value[c] = 0; } ch = fgetc(rcfile); if (feof(rcfile)) { return(0); } if (ch == '#') { while (!feof(rcfile) && (ch != '\n')) ch = fgetc(rcfile); continue; } c = 0; while (!feof(rcfile) && (isalnum((int)ch) || (ch == '-')) && (c < 80)) { tag[strlen(tag)] = ch; ch = fgetc(rcfile); c++; } if (c == 80) { print_error(ferr, "Parse error in rc file: %s[%d]", filename, line); print_esup(ferr, "Tag too long"); return(1); } if (feof(rcfile)) { print_error(ferr, "Parse error in rc file: %s[%d]", filename, line); print_esup(ferr, "Unexpected end of file reached"); return(1); } if (strlen(tag) == 0) { print_error(ferr, "Parse error in rc file: %s[%d]", filename, line); print_esup(ferr, "No tag"); return(1); } if (ch != ':') { print_error(ferr, "Parse error in rc file: %s[%d]", filename, line); print_esup(ferr, "':' delimiter expected between tag and value"); return(1); } ch = fgetc(rcfile); while (!feof(rcfile) && ((ch == ' ') || (ch == '\t'))) ch = fgetc(rcfile); if (ch == '\n') { print_error(ferr, "Parse error in rc file: %s[%d]", filename, line); print_esup(ferr, "No value found after tag: %s", tag); return(1); } c = 0; while (!feof(rcfile) && (ch != '\n') && (c < 80)) { value[strlen(value)] = ch; ch = fgetc(rcfile); c++; } if (c == 80) { print_error(ferr, "Parse error in rc file: %s[%d]", filename, line); print_esup(ferr, "Value too long"); return(1); } if (strlen(value) == 0) { print_error(ferr, "Parse error in rc file: %s[%d]", filename, line); print_esup(ferr, "No value for tag: %s", tag); return(1); } if (parse_rc_by_tag(ferr, filename, line, tag, value) != 0) return(1); } fclose(rcfile); return(0); } int parse_rcfiles(FILE *ferr) { char filename[4096] = { 0 }; char * home_dir = 0; if (access("/etc/clpbarrc", R_OK) == 0) { sprintf(filename, "/etc/clpbarrc"); } if (strlen(filename) > 0) if (parse_rcfile(ferr, filename) != 0) return(1); home_dir = getenv("HOME"); if (home_dir != 0) { sprintf(filename, "%.*s/.barrc", 4088, home_dir); if (parse_rcfile(ferr, filename) != 0) return(1); } sprintf(filename, "./.barrc"); if (parse_rcfile(ferr, filename) != 0) return(1); return(0); } bar-1.11.1.orig/test-0020000754000175000017500000000164110510504276014701 0ustar georgeskgeorgesk#!/bin/sh files=" * " src_file="test-file-002.1.tar" dst_file="test-file-002.2.tar" if [ -f ${src_file} ]; then rm -f ${src_file} fi tar -cf ${src_file} ${files} if [ "$?" -ne 0 ]; then echo "*** ERROR: Could not create test file" echo " Test inconclusive" exit 1 fi cp ${src_file} ${dst_file} if [ "$?" -ne 0 ]; then echo "*** ERROR: Unable to copy test file" echo " Test inconclusive" exit 1 fi ./bar -if ${src_file} -of ${dst_file} 2> /dev/null if [ "$?" -ne 0 ]; then echo "*** ERROR: ./bar failed" exit 1 fi cmp ${src_file} ${dst_file} > /dev/null 2>&1 if [ "$?" -ne 0 ]; then echo "*** ERROR: Files differ" exit 1 fi cat ${src_file} | ./bar 2> /dev/null > ${dst_file} if [ "$?" -ne 0 ]; then echo "*** ERROR: ./bar failed" exit 1 fi cmp ${src_file} ${dst_file} > /dev/null 2>&1 if [ "$?" -ne 0 ]; then echo "*** ERROR: Files differ" exit 1 fi rm -f ${src_file} ${dst_file} exit 0 bar-1.11.1.orig/config.sub0000754000175000017500000006700510510504276015466 0ustar georgeskgeorgesk#! /bin/sh # Configuration validation subroutine script. # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001 # Free Software Foundation, Inc. timestamp='2001-08-13' # This file is (in principle) common to ALL GNU software. # The presence of a machine in this file suggests that SOME GNU software # can handle that machine. It does not imply ALL GNU software can. # # 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 2 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, write to the Free Software # Foundation, Inc., 59 Temple Place - Suite 330, # Boston, MA 02111-1307, USA. # 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. # 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. # 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. me=`echo "$0" | sed -e 's,.*/,,'` usage="\ Usage: $0 [OPTION] CPU-MFR-OPSYS $0 [OPTION] ALIAS Canonicalize a configuration name. Operation modes: -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 (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001 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 0 ;; --version | -v ) echo "$version" ; exit 0 ;; --help | --h* | -h ) echo "$usage"; exit 0 ;; -- ) # Stop option processing shift; break ;; - ) # Use stdin as input. break ;; -* ) echo "$me: invalid option $1$help" exit 1 ;; *local*) # First pass through any local machine types. echo $1 exit 0;; * ) 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 # Separate what the user gave into CPU-COMPANY and OS or KERNEL-OS (if any). # Here we must recognize all the valid KERNEL-OS combinations. maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` case $maybe_os in nto-qnx* | linux-gnu* | storm-chaos* | os2-emx* | windows32-*) os=-$maybe_os basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` ;; *) basic_machine=`echo $1 | sed 's/-[^-]*$//'` if [ $basic_machine != $1 ] then os=`echo $1 | sed 's/.*-/-/'` else os=; fi ;; esac ### Let's recognize common machines as not being operating systems so ### that things like config.sub decstation-3100 work. We also ### recognize some manufacturers as not being operating systems, so we ### can provide default operating systems below. case $os in -sun*os*) # Prevent following clause from handling this invalid input. ;; -dec* | -mips* | -sequent* | -encore* | -pc532* | -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) os= basic_machine=$1 ;; -sim | -cisco | -oki | -wec | -winbond) os= basic_machine=$1 ;; -scout) ;; -wrs) os=-vxworks basic_machine=$1 ;; -chorusos*) os=-chorusos basic_machine=$1 ;; -chorusrdb) os=-chorusrdb basic_machine=$1 ;; -hiux*) os=-hiuxwe2 ;; -sco5) os=-sco3.2v5 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco4) os=-sco3.2v4 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco3.2.[4-9]*) os=`echo $os | sed -e 's/sco3.2./sco3.2v/'` basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco3.2v[4-9]*) # Don't forget version if it is 3.2v4 or newer. basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco*) os=-sco3.2v2 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -udk*) basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -isc) os=-isc2.2 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -clix*) basic_machine=clipper-intergraph ;; -isc*) basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -lynx*) os=-lynxos ;; -ptx*) basic_machine=`echo $1 | sed -e 's/86-.*/86-sequent/'` ;; -windowsnt*) os=`echo $os | sed -e 's/windowsnt/winnt/'` ;; -psos*) os=-psos ;; -mint | -mint[0-9]*) basic_machine=m68k-atari os=-mint ;; esac # Decode aliases for certain CPU-COMPANY combinations. case $basic_machine in # Recognize the basic CPU types without company name. # Some are omitted here because they have special meanings below. 1750a | 580 \ | a29k \ | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr \ | c4x | clipper \ | d10v | d30v | dsp16xx \ | fr30 \ | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ | i370 | i860 | i960 | ia64 \ | m32r | m68000 | m68k | m88k | mcore \ | mips16 | mips64 | mips64el | mips64orion | mips64orionel \ | mips64vr4100 | mips64vr4100el | mips64vr4300 \ | mips64vr4300el | mips64vr5000 | mips64vr5000el \ | mipsbe | mipsel | mipsle | mipstx39 | mipstx39el \ | mn10200 | mn10300 \ | ns16k | ns32k \ | openrisc \ | pdp10 | pdp11 | pj | pjl \ | powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \ | pyramid \ | s390 | s390x \ | sh | sh[34] | sh[34]eb | shbe | shle \ | sparc | sparc64 | sparclet | sparclite | sparcv9 | sparcv9b \ | strongarm \ | tahoe | thumb | tic80 | tron \ | v850 \ | we32k \ | x86 | xscale \ | z8k) basic_machine=$basic_machine-unknown ;; m6811 | m68hc11 | m6812 | m68hc12) # Motorola 68HC11/12. basic_machine=$basic_machine-unknown os=-none ;; m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k) ;; # We use `pc' rather than `unknown' # because (1) that's what they normally are, and # (2) the word "unknown" tends to confuse beginning users. i*86 | x86_64) basic_machine=$basic_machine-pc ;; # Object if more than one company name word. *-*-*) echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 exit 1 ;; # Recognize the basic CPU types with company name. 580-* \ | a29k-* \ | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ | alphapca5[67]-* | arc-* \ | arm-* | armbe-* | armle-* | armv*-* \ | bs2000-* \ | c[123]* | c30-* | [cjt]90-* | c54x-* \ | clipper-* | cray2-* | cydra-* \ | d10v-* | d30v-* \ | elxsi-* \ | f30[01]-* | f700-* | fr30-* | fx80-* \ | h8300-* | h8500-* \ | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \ | i*86-* | i860-* | i960-* | ia64-* \ | m32r-* \ | m68000-* | m680[01234]0-* | m68360-* | m683?2-* | m68k-* \ | m88110-* | m88k-* | mcore-* \ | mips-* | mips16-* | mips64-* | mips64el-* | mips64orion-* \ | mips64orionel-* | mips64vr4100-* | mips64vr4100el-* \ | mips64vr4300-* | mips64vr4300el-* | mipsbe-* | mipsel-* \ | mipsle-* | mipstx39-* | mipstx39el-* \ | none-* | np1-* | ns16k-* | ns32k-* \ | orion-* \ | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \ | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \ | pyramid-* \ | romp-* | rs6000-* \ | s390-* | s390x-* \ | sh-* | sh[34]-* | sh[34]eb-* | shbe-* | shle-* \ | sparc-* | sparc64-* | sparc86x-* | sparclite-* \ | sparcv9-* | sparcv9b-* | strongarm-* | sv1-* \ | t3e-* | tahoe-* | thumb-* | tic30-* | tic54x-* | tic80-* | tron-* \ | v850-* | vax-* \ | we32k-* \ | x86-* | x86_64-* | xmp-* | xps100-* | xscale-* \ | ymp-* \ | z8k-*) ;; # Recognize the various machine names and aliases which stand # for a CPU type and a company and sometimes even an OS. 386bsd) basic_machine=i386-unknown os=-bsd ;; 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc) basic_machine=m68000-att ;; 3b*) basic_machine=we32k-att ;; a29khif) basic_machine=a29k-amd os=-udi ;; adobe68k) basic_machine=m68010-adobe os=-scout ;; alliant | fx80) basic_machine=fx80-alliant ;; altos | altos3068) basic_machine=m68k-altos ;; am29k) basic_machine=a29k-none os=-bsd ;; amdahl) basic_machine=580-amdahl os=-sysv ;; amiga | amiga-*) basic_machine=m68k-unknown ;; amigaos | amigados) basic_machine=m68k-unknown os=-amigaos ;; amigaunix | amix) basic_machine=m68k-unknown os=-sysv4 ;; apollo68) basic_machine=m68k-apollo os=-sysv ;; apollo68bsd) basic_machine=m68k-apollo os=-bsd ;; aux) basic_machine=m68k-apple os=-aux ;; balance) basic_machine=ns32k-sequent os=-dynix ;; convex-c1) basic_machine=c1-convex os=-bsd ;; convex-c2) basic_machine=c2-convex os=-bsd ;; convex-c32) basic_machine=c32-convex os=-bsd ;; convex-c34) basic_machine=c34-convex os=-bsd ;; convex-c38) basic_machine=c38-convex os=-bsd ;; cray | ymp) basic_machine=ymp-cray os=-unicos ;; cray2) basic_machine=cray2-cray os=-unicos ;; [cjt]90) basic_machine=${basic_machine}-cray os=-unicos ;; crds | unos) basic_machine=m68k-crds ;; cris | cris-* | etrax*) basic_machine=cris-axis ;; da30 | da30-*) basic_machine=m68k-da30 ;; decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn) basic_machine=mips-dec ;; delta | 3300 | motorola-3300 | motorola-delta \ | 3300-motorola | delta-motorola) basic_machine=m68k-motorola ;; delta88) basic_machine=m88k-motorola os=-sysv3 ;; dpx20 | dpx20-*) basic_machine=rs6000-bull os=-bosx ;; dpx2* | dpx2*-bull) basic_machine=m68k-bull os=-sysv3 ;; ebmon29k) basic_machine=a29k-amd os=-ebmon ;; elxsi) basic_machine=elxsi-elxsi os=-bsd ;; encore | umax | mmax) basic_machine=ns32k-encore ;; es1800 | OSE68k | ose68k | ose | OSE) basic_machine=m68k-ericsson os=-ose ;; fx2800) basic_machine=i860-alliant ;; genix) basic_machine=ns32k-ns ;; gmicro) basic_machine=tron-gmicro os=-sysv ;; go32) basic_machine=i386-pc os=-go32 ;; h3050r* | hiux*) basic_machine=hppa1.1-hitachi os=-hiuxwe2 ;; h8300hms) basic_machine=h8300-hitachi os=-hms ;; h8300xray) basic_machine=h8300-hitachi os=-xray ;; h8500hms) basic_machine=h8500-hitachi os=-hms ;; harris) basic_machine=m88k-harris os=-sysv3 ;; hp300-*) basic_machine=m68k-hp ;; hp300bsd) basic_machine=m68k-hp os=-bsd ;; hp300hpux) basic_machine=m68k-hp os=-hpux ;; hp3k9[0-9][0-9] | hp9[0-9][0-9]) basic_machine=hppa1.0-hp ;; hp9k2[0-9][0-9] | hp9k31[0-9]) basic_machine=m68000-hp ;; hp9k3[2-9][0-9]) basic_machine=m68k-hp ;; hp9k6[0-9][0-9] | hp6[0-9][0-9]) basic_machine=hppa1.0-hp ;; hp9k7[0-79][0-9] | hp7[0-79][0-9]) basic_machine=hppa1.1-hp ;; hp9k78[0-9] | hp78[0-9]) # FIXME: really hppa2.0-hp basic_machine=hppa1.1-hp ;; hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893) # FIXME: really hppa2.0-hp basic_machine=hppa1.1-hp ;; hp9k8[0-9][13679] | hp8[0-9][13679]) basic_machine=hppa1.1-hp ;; hp9k8[0-9][0-9] | hp8[0-9][0-9]) basic_machine=hppa1.0-hp ;; hppa-next) os=-nextstep3 ;; hppaosf) basic_machine=hppa1.1-hp os=-osf ;; hppro) basic_machine=hppa1.1-hp os=-proelf ;; i370-ibm* | ibm*) basic_machine=i370-ibm ;; # I'm not sure what "Sysv32" means. Should this be sysv3.2? i*86v32) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-sysv32 ;; i*86v4*) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-sysv4 ;; i*86v) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-sysv ;; i*86sol2) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-solaris2 ;; i386mach) basic_machine=i386-mach os=-mach ;; i386-vsta | vsta) basic_machine=i386-unknown os=-vsta ;; iris | iris4d) basic_machine=mips-sgi case $os in -irix*) ;; *) os=-irix4 ;; esac ;; isi68 | isi) basic_machine=m68k-isi os=-sysv ;; m88k-omron*) basic_machine=m88k-omron ;; magnum | m3230) basic_machine=mips-mips os=-sysv ;; merlin) basic_machine=ns32k-utek os=-sysv ;; mingw32) basic_machine=i386-pc os=-mingw32 ;; miniframe) basic_machine=m68000-convergent ;; *mint | -mint[0-9]* | *MiNT | *MiNT[0-9]*) basic_machine=m68k-atari os=-mint ;; mipsel*-linux*) basic_machine=mipsel-unknown os=-linux-gnu ;; mips*-linux*) basic_machine=mips-unknown os=-linux-gnu ;; mips3*-*) basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'` ;; mips3*) basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown ;; mmix*) basic_machine=mmix-knuth os=-mmixware ;; monitor) basic_machine=m68k-rom68k os=-coff ;; msdos) basic_machine=i386-pc os=-msdos ;; mvs) basic_machine=i370-ibm os=-mvs ;; ncr3000) basic_machine=i486-ncr os=-sysv4 ;; netbsd386) basic_machine=i386-unknown os=-netbsd ;; netwinder) basic_machine=armv4l-rebel os=-linux ;; news | news700 | news800 | news900) basic_machine=m68k-sony os=-newsos ;; news1000) basic_machine=m68030-sony os=-newsos ;; news-3600 | risc-news) basic_machine=mips-sony os=-newsos ;; necv70) basic_machine=v70-nec os=-sysv ;; next | m*-next ) basic_machine=m68k-next case $os in -nextstep* ) ;; -ns2*) os=-nextstep2 ;; *) os=-nextstep3 ;; esac ;; nh3000) basic_machine=m68k-harris os=-cxux ;; nh[45]000) basic_machine=m88k-harris os=-cxux ;; nindy960) basic_machine=i960-intel os=-nindy ;; mon960) basic_machine=i960-intel os=-mon960 ;; nonstopux) basic_machine=mips-compaq os=-nonstopux ;; np1) basic_machine=np1-gould ;; nsr-tandem) basic_machine=nsr-tandem ;; op50n-* | op60c-*) basic_machine=hppa1.1-oki os=-proelf ;; OSE68000 | ose68000) basic_machine=m68000-ericsson os=-ose ;; os68k) basic_machine=m68k-none os=-os68k ;; pa-hitachi) basic_machine=hppa1.1-hitachi os=-hiuxwe2 ;; paragon) basic_machine=i860-intel os=-osf ;; pbd) basic_machine=sparc-tti ;; pbb) basic_machine=m68k-tti ;; pc532 | pc532-*) basic_machine=ns32k-pc532 ;; pentium | p5 | k5 | k6 | nexgen) basic_machine=i586-pc ;; pentiumpro | p6 | 6x86 | athlon) basic_machine=i686-pc ;; pentiumii | pentium2) basic_machine=i686-pc ;; pentium-* | p5-* | k5-* | k6-* | nexgen-*) basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pentiumpro-* | p6-* | 6x86-* | athlon-*) basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pentiumii-* | pentium2-*) basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pn) basic_machine=pn-gould ;; power) basic_machine=power-ibm ;; ppc) basic_machine=powerpc-unknown ;; ppc-*) basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ppcle | powerpclittle | ppc-le | powerpc-little) basic_machine=powerpcle-unknown ;; ppcle-* | powerpclittle-*) basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ppc64) basic_machine=powerpc64-unknown ;; ppc64-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ppc64le | powerpc64little | ppc64-le | powerpc64-little) basic_machine=powerpc64le-unknown ;; ppc64le-* | powerpc64little-*) basic_machine=powerpc64le-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ps2) basic_machine=i386-ibm ;; pw32) basic_machine=i586-unknown os=-pw32 ;; rom68k) basic_machine=m68k-rom68k os=-coff ;; rm[46]00) basic_machine=mips-siemens ;; rtpc | rtpc-*) basic_machine=romp-ibm ;; sa29200) basic_machine=a29k-amd os=-udi ;; sequent) basic_machine=i386-sequent ;; sh) basic_machine=sh-hitachi os=-hms ;; sparclite-wrs) basic_machine=sparclite-wrs os=-vxworks ;; sps7) basic_machine=m68k-bull os=-sysv2 ;; spur) basic_machine=spur-unknown ;; st2000) basic_machine=m68k-tandem ;; stratus) basic_machine=i860-stratus os=-sysv4 ;; sun2) basic_machine=m68000-sun ;; sun2os3) basic_machine=m68000-sun os=-sunos3 ;; sun2os4) basic_machine=m68000-sun os=-sunos4 ;; sun3os3) basic_machine=m68k-sun os=-sunos3 ;; sun3os4) basic_machine=m68k-sun os=-sunos4 ;; sun4os3) basic_machine=sparc-sun os=-sunos3 ;; sun4os4) basic_machine=sparc-sun os=-sunos4 ;; sun4sol2) basic_machine=sparc-sun os=-solaris2 ;; sun3 | sun3-*) basic_machine=m68k-sun ;; sun4) basic_machine=sparc-sun ;; sun386 | sun386i | roadrunner) basic_machine=i386-sun ;; sv1) basic_machine=sv1-cray os=-unicos ;; symmetry) basic_machine=i386-sequent os=-dynix ;; t3e) basic_machine=t3e-cray os=-unicos ;; tic54x | c54x*) basic_machine=tic54x-unknown os=-coff ;; tx39) basic_machine=mipstx39-unknown ;; tx39el) basic_machine=mipstx39el-unknown ;; tower | tower-32) basic_machine=m68k-ncr ;; udi29k) basic_machine=a29k-amd os=-udi ;; ultra3) basic_machine=a29k-nyu os=-sym1 ;; v810 | necv810) basic_machine=v810-nec os=-none ;; vaxv) basic_machine=vax-dec os=-sysv ;; vms) basic_machine=vax-dec os=-vms ;; vpp*|vx|vx-*) basic_machine=f301-fujitsu ;; vxworks960) basic_machine=i960-wrs os=-vxworks ;; vxworks68) basic_machine=m68k-wrs os=-vxworks ;; vxworks29k) basic_machine=a29k-wrs os=-vxworks ;; w65*) basic_machine=w65-wdc os=-none ;; w89k-*) basic_machine=hppa1.1-winbond os=-proelf ;; windows32) basic_machine=i386-pc os=-windows32-msvcrt ;; xmp) basic_machine=xmp-cray os=-unicos ;; xps | xps100) basic_machine=xps100-honeywell ;; z8k-*-coff) basic_machine=z8k-unknown os=-sim ;; none) basic_machine=none-none os=-none ;; # 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) basic_machine=hppa1.1-winbond ;; op50n) basic_machine=hppa1.1-oki ;; op60c) basic_machine=hppa1.1-oki ;; mips) if [ x$os = x-linux-gnu ]; then basic_machine=mips-unknown else basic_machine=mips-mips fi ;; romp) basic_machine=romp-ibm ;; rs6000) basic_machine=rs6000-ibm ;; vax) basic_machine=vax-dec ;; pdp10) # there are many clones, so DEC is not a safe bet basic_machine=pdp10-unknown ;; pdp11) basic_machine=pdp11-dec ;; we32k) basic_machine=we32k-att ;; sh3 | sh4 | sh3eb | sh4eb) basic_machine=sh-unknown ;; sparc | sparcv9 | sparcv9b) basic_machine=sparc-sun ;; cydra) basic_machine=cydra-cydrome ;; orion) basic_machine=orion-highlevel ;; orion105) basic_machine=clipper-highlevel ;; mac | mpw | mac-mpw) basic_machine=m68k-apple ;; pmac | pmac-mpw) basic_machine=powerpc-apple ;; c4x*) basic_machine=c4x-none os=-coff ;; *-unknown) # Make sure to match an already-canonicalized machine name. ;; *) echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 exit 1 ;; esac # Here we canonicalize certain aliases for manufacturers. case $basic_machine in *-digital*) basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'` ;; *-commodore*) basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'` ;; *) ;; esac # Decode manufacturer-specific aliases for certain operating systems. if [ x"$os" != x"" ] then case $os in # First match some system type aliases # that might get confused with valid system types. # -solaris* is a basic system type, with this one exception. -solaris1 | -solaris1.*) os=`echo $os | sed -e 's|solaris1|sunos4|'` ;; -solaris) os=-solaris2 ;; -svr4*) os=-sysv4 ;; -unixware*) os=-sysv4.2uw ;; -gnu/linux*) os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'` ;; # First accept the basic system types. # The portable systems comes first. # Each alternative MUST END IN A *, to match a version number. # -sysv* is not here because it comes later, after sysvr4. -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \ | -*vms* | -sco* | -esix* | -isc* | -aix* | -sunos | -sunos[34]*\ | -hpux* | -unos* | -osf* | -luna* | -dgux* | -solaris* | -sym* \ | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \ | -aos* \ | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ | -hiux* | -386bsd* | -netbsd* | -openbsd* | -freebsd* | -riscix* \ | -lynxos* | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ | -chorusos* | -chorusrdb* \ | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ | -mingw32* | -linux-gnu* | -uxpv* | -beos* | -mpeix* | -udk* \ | -interix* | -uwin* | -rhapsody* | -darwin* | -opened* \ | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \ | -os2* | -vos*) # Remember, each alternative MUST END IN *, to match a version number. ;; -qnx*) case $basic_machine in x86-* | i*86-*) ;; *) os=-nto$os ;; esac ;; -nto*) os=-nto-qnx ;; -sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \ | -windows* | -osx | -abug | -netware* | -os9* | -beos* \ | -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*) ;; -mac*) os=`echo $os | sed -e 's|mac|macos|'` ;; -linux*) os=`echo $os | sed -e 's|linux|linux-gnu|'` ;; -sunos5*) os=`echo $os | sed -e 's|sunos5|solaris2|'` ;; -sunos6*) os=`echo $os | sed -e 's|sunos6|solaris3|'` ;; -opened*) os=-openedition ;; -wince*) os=-wince ;; -osfrose*) os=-osfrose ;; -osf*) os=-osf ;; -utek*) os=-bsd ;; -dynix*) os=-bsd ;; -acis*) os=-aos ;; -386bsd) os=-bsd ;; -ctix* | -uts*) os=-sysv ;; -ns2 ) os=-nextstep2 ;; -nsk*) os=-nsk ;; # Preserve the version number of sinix5. -sinix5.*) os=`echo $os | sed -e 's|sinix|sysv|'` ;; -sinix*) os=-sysv4 ;; -triton*) os=-sysv3 ;; -oss*) os=-sysv3 ;; -svr4) os=-sysv4 ;; -svr3) os=-sysv3 ;; -sysvr4) os=-sysv4 ;; # This must come after -sysvr4. -sysv*) ;; -ose*) os=-ose ;; -es1800*) os=-ose ;; -xenix) os=-xenix ;; -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) os=-mint ;; -none) ;; *) # Get rid of the `-' at the beginning of $os. os=`echo $os | sed 's/[^-]*-//'` echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2 exit 1 ;; esac else # Here we handle the default operating systems that come with various machines. # The value should be what the vendor currently ships out the door with their # machine or put another way, the most popular os provided with the machine. # Note that if you're going to try to match "-MANUFACTURER" here (say, # "-sun"), then you have to tell the case statement up towards the top # that MANUFACTURER isn't an operating system. Otherwise, code above # will signal an error saying that MANUFACTURER isn't an operating # system, and we'll never get to this point. case $basic_machine in *-acorn) os=-riscix1.2 ;; arm*-rebel) os=-linux ;; arm*-semi) os=-aout ;; pdp10-*) os=-tops20 ;; pdp11-*) os=-none ;; *-dec | vax-*) os=-ultrix4.2 ;; m68*-apollo) os=-domain ;; i386-sun) os=-sunos4.0.2 ;; m68000-sun) os=-sunos3 # This also exists in the configure program, but was not the # default. # os=-sunos4 ;; m68*-cisco) os=-aout ;; mips*-cisco) os=-elf ;; mips*-*) os=-elf ;; *-tti) # must be before sparc entry or we get the wrong os. os=-sysv3 ;; sparc-* | *-sun) os=-sunos4.1.1 ;; *-be) os=-beos ;; *-ibm) os=-aix ;; *-wec) os=-proelf ;; *-winbond) os=-proelf ;; *-oki) os=-proelf ;; *-hp) os=-hpux ;; *-hitachi) os=-hiux ;; i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent) os=-sysv ;; *-cbm) os=-amigaos ;; *-dg) os=-dgux ;; *-dolphin) os=-sysv3 ;; m68k-ccur) os=-rtu ;; m88k-omron*) os=-luna ;; *-next ) os=-nextstep ;; *-sequent) os=-ptx ;; *-crds) os=-unos ;; *-ns) os=-genix ;; i370-*) os=-mvs ;; *-next) os=-nextstep3 ;; *-gould) os=-sysv ;; *-highlevel) os=-bsd ;; *-encore) os=-bsd ;; *-sgi) os=-irix ;; *-siemens) os=-sysv4 ;; *-masscomp) os=-rtu ;; f30[01]-fujitsu | f700-fujitsu) os=-uxpv ;; *-rom68k) os=-coff ;; *-*bug) os=-coff ;; *-apple) os=-macos ;; *-atari*) os=-mint ;; *) os=-none ;; esac fi # Here we handle the case where we know the os, and the CPU type, but not the # manufacturer. We pick the logical manufacturer. vendor=unknown case $basic_machine in *-unknown) case $os in -riscix*) vendor=acorn ;; -sunos*) vendor=sun ;; -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 ;; -mvs* | -opened*) vendor=ibm ;; -ptx*) vendor=sequent ;; -vxsim* | -vxworks*) 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 basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"` ;; esac echo $basic_machine$os exit 0 # Local variables: # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "timestamp='" # time-stamp-format: "%:y-%02m-%02d" # time-stamp-end: "'" # End: bar-1.11.1.orig/fd.h0000644000175000017500000000036410510504276014241 0ustar georgeskgeorgesk/* * File descriptor manipulation */ #ifndef __fd_h__ #define __fd_h__ #include "headers.h" #include "config.h" #include "types.h" int fdBegin(int fd); int fdEnd(int fd); int fdIsFile(int fd); int fdFileSize(int fd, uint64 *size); #endif bar-1.11.1.orig/test-0030000754000175000017500000000235110510504276014701 0ustar georgeskgeorgesk#!/bin/sh src_file="./test-file-003.1.bin" tmp_file="./test-file-003.incomplete.bin" dst_file="./test-file-003.2.bin" if [ ! -c /dev/random ]; then echo "*** NOTICE: Skipping test -- no /dev/random found" exit 0 fi if [ ! -f "${src_file}" ]; then echo "- Creating test file (this may take a while...)" dd \ if=/dev/random \ of=${tmp_file} \ bs=1024 \ count=1024 \ 2> /dev/null if [ "$?" -ne 0 ]; then echo "*** ERROR: Failed to create test file" echo " Test inconclusive" exit 1 fi mv ${tmp_file} ${src_file} if [ "$?" -ne 0 ]; then echo "*** ERROR: Failed to create test file" echo " Test inconclusive" rm -f ${tmp_file} exit 1 fi else echo "- Using existing test file: ${src_file}..." fi echo "- Copying file..." cp ${src_file} ${dst_file} if [ "$?" -ne 0 ]; then echo "*** ERROR: Unable to copy file" echo " Test inconclusive" exit 1 fi echo "- Copying file through bar..." ./bar -if ${src_file} -of ${dst_file} 2> /dev/null if [ "$?" -ne 0 ]; then echo "*** ERROR: bar failed" exit 1 fi echo "- Comparing file against copy..." cmp ${src_file} ${dst_file} > /dev/null 2>&1 if [ "$?" -ne 0 ]; then echo "*** ERROR: Files differ" exit 1 fi rm -f ${src_file} ${dst_file} exit 0 bar-1.11.1.orig/test-types.c0000644000175000017500000000163510510504276015766 0ustar georgeskgeorgesk#include "config.h" #include "headers.h" #include "types.h" void test_u8(void) { uint8 u8 = 0; uint8 u8_old = 0; unsigned int c = 0; u8 = 1; for (c = 0; u8 != u8_old; c++) { u8_old = u8; u8 <<= 1; u8 |= 1; } assert(c == 8); } void test_u16(void) { uint16 u16 = 0; uint16 u16_old = 0; unsigned int c = 0; u16 = 1; for (c = 0; u16 != u16_old; c++) { u16_old = u16; u16 <<= 1; u16 |= 1; } assert(c == 16); } void test_u32(void) { uint32 u32 = 0; uint32 u32_old = 0; unsigned int c = 0; u32 = 1; for (c = 0; u32 != u32_old; c++) { u32_old = u32; u32 <<= 1; u32 |= 1; } assert(c == 32); } void test_u64(void) { uint64 u64 = 0; uint64 u64_old = 0; unsigned int c = 0; u64 = 1; for (c = 0; u64 != u64_old; c++) { u64_old = u64; u64 <<= 1; u64 |= 1; } assert(c == 64); } int main(int argc, char* argv[]) { test_u8(); test_u16(); test_u32(); test_u64(); return(0); } bar-1.11.1.orig/doxygen.conf.in0000644000175000017500000012734210510516514016434 0ustar georgeskgeorgesk# Doxyfile 1.3.5 # This file describes the settings to be used by the documentation system # doxygen (www.doxygen.org) for a project # # All text after a hash (#) is considered a comment and will be ignored # The format is: # TAG = value [value, ...] # For lists items can also be appended using: # TAG += value [value, ...] # Values that contain spaces should be placed between quotes (" ") #--------------------------------------------------------------------------- # Project related configuration options #--------------------------------------------------------------------------- # The PROJECT_NAME tag is a single word (or a sequence of words surrounded # by quotes) that should identify the project. PROJECT_NAME = {PACKAGE} # The PROJECT_NUMBER tag can be used to enter a project or revision number. # This could be handy for archiving the generated documentation or # if some version control system is used. PROJECT_NUMBER = {VERSION} # The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) # base path where the generated documentation will be put. # If a relative path is entered, it will be relative to the location # where doxygen was started. If left blank the current directory will be used. OUTPUT_DIRECTORY = {DOC_DIR} # The OUTPUT_LANGUAGE tag is used to specify the language in which all # documentation generated by doxygen is written. Doxygen will use this # information to generate all constant output in the proper language. # The default language is English, other supported languages are: # Brazilian, Catalan, Chinese, Chinese-Traditional, Croatian, Czech, Danish, Dutch, # Finnish, French, German, Greek, Hungarian, Italian, Japanese, Japanese-en # (Japanese with English messages), Korean, Norwegian, Polish, Portuguese, # Romanian, Russian, Serbian, Slovak, Slovene, Spanish, Swedish, and Ukrainian. OUTPUT_LANGUAGE = English # This tag can be used to specify the encoding used in the generated output. # The encoding is not always determined by the language that is chosen, # but also whether or not the output is meant for Windows or non-Windows users. # In case there is a difference, setting the USE_WINDOWS_ENCODING tag to YES # forces the Windows encoding (this is the default for the Windows binary), # whereas setting the tag to NO uses a Unix-style encoding (the default for # all platforms other than Windows). USE_WINDOWS_ENCODING = NO # If the BRIEF_MEMBER_DESC tag is set to YES (the default) Doxygen will # include brief member descriptions after the members that are listed in # the file and class documentation (similar to JavaDoc). # Set to NO to disable this. BRIEF_MEMBER_DESC = YES # If the REPEAT_BRIEF tag is set to YES (the default) Doxygen will prepend # the brief description of a member or function before the detailed description. # Note: if both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the # brief descriptions will be completely suppressed. REPEAT_BRIEF = YES # This tag implements a quasi-intelligent brief description abbreviator # that is used to form the text in various listings. Each string # in this list, if found as the leading text of the brief description, will be # stripped from the text and the result after processing the whole list, is used # as the annotated text. Otherwise, the brief description is used as-is. If left # blank, the following values are used ("$name" is automatically replaced with the # name of the entity): "The $name class" "The $name widget" "The $name file" # "is" "provides" "specifies" "contains" "represents" "a" "an" "the" ABBREVIATE_BRIEF = # If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then # Doxygen will generate a detailed section even if there is only a brief # description. ALWAYS_DETAILED_SEC = NO # If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all inherited # members of a class in the documentation of that class as if those members were # ordinary class members. Constructors, destructors and assignment operators of # the base classes will not be shown. INLINE_INHERITED_MEMB = NO # If the FULL_PATH_NAMES tag is set to YES then Doxygen will prepend the full # path before files name in the file list and in the header files. If set # to NO the shortest path that makes the file name unique will be used. FULL_PATH_NAMES = NO # If the FULL_PATH_NAMES tag is set to YES then the STRIP_FROM_PATH tag # can be used to strip a user-defined part of the path. Stripping is # only done if one of the specified strings matches the left-hand part of # the path. It is allowed to use relative paths in the argument list. STRIP_FROM_PATH = # If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter # (but less readable) file names. This can be useful is your file systems # doesn't support long names like on DOS, Mac, or CD-ROM. SHORT_NAMES = NO # If the JAVADOC_AUTOBRIEF tag is set to YES then Doxygen # will interpret the first line (until the first dot) of a JavaDoc-style # comment as the brief description. If set to NO, the JavaDoc # comments will behave just like the Qt-style comments (thus requiring an # explicit @brief command for a brief description. JAVADOC_AUTOBRIEF = YES # The MULTILINE_CPP_IS_BRIEF tag can be set to YES to make Doxygen # treat a multi-line C++ special comment block (i.e. a block of //! or /// # comments) as a brief description. This used to be the default behaviour. # The new default is to treat a multi-line C++ comment block as a detailed # description. Set this tag to YES if you prefer the old behaviour instead. MULTILINE_CPP_IS_BRIEF = NO # If the DETAILS_AT_TOP tag is set to YES then Doxygen # will output the detailed description near the top, like JavaDoc. # If set to NO, the detailed description appears after the member # documentation. DETAILS_AT_TOP = NO # If the INHERIT_DOCS tag is set to YES (the default) then an undocumented # member inherits the documentation from any documented member that it # re-implements. INHERIT_DOCS = YES # If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC # tag is set to YES, then doxygen will reuse the documentation of the first # member in the group (if any) for the other members of the group. By default # all members of a group must be documented explicitly. DISTRIBUTE_GROUP_DOC = NO # The TAB_SIZE tag can be used to set the number of spaces in a tab. # Doxygen uses this value to replace tabs by spaces in code fragments. TAB_SIZE = 8 # This tag can be used to specify a number of aliases that acts # as commands in the documentation. An alias has the form "name=value". # For example adding "sideeffect=\par Side Effects:\n" will allow you to # put the command \sideeffect (or @sideeffect) in the documentation, which # will result in a user-defined paragraph with heading "Side Effects:". # You can put \n's in the value part of an alias to insert newlines. ALIASES = # Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C sources # only. Doxygen will then generate output that is more tailored for C. # For instance, some of the names that are used will be different. The list # of all members will be omitted, etc. OPTIMIZE_OUTPUT_FOR_C = YES # Set the OPTIMIZE_OUTPUT_JAVA tag to YES if your project consists of Java sources # only. Doxygen will then generate output that is more tailored for Java. # For instance, namespaces will be presented as packages, qualified scopes # will look different, etc. OPTIMIZE_OUTPUT_JAVA = NO # Set the SUBGROUPING tag to YES (the default) to allow class member groups of # the same type (for instance a group of public functions) to be put as a # subgroup of that type (e.g. under the Public Functions section). Set it to # NO to prevent subgrouping. Alternatively, this can be done per class using # the \nosubgrouping command. SUBGROUPING = YES #--------------------------------------------------------------------------- # Build related configuration options #--------------------------------------------------------------------------- # If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in # documentation are documented, even if no documentation was available. # Private class members and static file members will be hidden unless # the EXTRACT_PRIVATE and EXTRACT_STATIC tags are set to YES EXTRACT_ALL = YES # If the EXTRACT_PRIVATE tag is set to YES all private members of a class # will be included in the documentation. EXTRACT_PRIVATE = YES # If the EXTRACT_STATIC tag is set to YES all static members of a file # will be included in the documentation. EXTRACT_STATIC = YES # If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs) # defined locally in source files will be included in the documentation. # If set to NO only classes defined in header files are included. EXTRACT_LOCAL_CLASSES = YES # If the HIDE_UNDOC_MEMBERS tag is set to YES, Doxygen will hide all # undocumented members of documented classes, files or namespaces. # If set to NO (the default) these members will be included in the # various overviews, but no documentation section is generated. # This option has no effect if EXTRACT_ALL is enabled. HIDE_UNDOC_MEMBERS = NO # If the HIDE_UNDOC_CLASSES tag is set to YES, Doxygen will hide all # undocumented classes that are normally visible in the class hierarchy. # If set to NO (the default) these classes will be included in the various # overviews. This option has no effect if EXTRACT_ALL is enabled. HIDE_UNDOC_CLASSES = NO # If the HIDE_FRIEND_COMPOUNDS tag is set to YES, Doxygen will hide all # friend (class|struct|union) declarations. # If set to NO (the default) these declarations will be included in the # documentation. HIDE_FRIEND_COMPOUNDS = NO # If the HIDE_IN_BODY_DOCS tag is set to YES, Doxygen will hide any # documentation blocks found inside the body of a function. # If set to NO (the default) these blocks will be appended to the # function's detailed documentation block. HIDE_IN_BODY_DOCS = NO # The INTERNAL_DOCS tag determines if documentation # that is typed after a \internal command is included. If the tag is set # to NO (the default) then the documentation will be excluded. # Set it to YES to include the internal documentation. INTERNAL_DOCS = NO # If the CASE_SENSE_NAMES tag is set to NO then Doxygen will only generate # file names in lower-case letters. If set to YES upper-case letters are also # allowed. This is useful if you have classes or files whose names only differ # in case and if your file system supports case sensitive file names. Windows # users are advised to set this option to NO. CASE_SENSE_NAMES = YES # If the HIDE_SCOPE_NAMES tag is set to NO (the default) then Doxygen # will show members with their full class and namespace scopes in the # documentation. If set to YES the scope will be hidden. HIDE_SCOPE_NAMES = NO # If the SHOW_INCLUDE_FILES tag is set to YES (the default) then Doxygen # will put a list of the files that are included by a file in the documentation # of that file. SHOW_INCLUDE_FILES = YES # If the INLINE_INFO tag is set to YES (the default) then a tag [inline] # is inserted in the documentation for inline members. INLINE_INFO = YES # If the SORT_MEMBER_DOCS tag is set to YES (the default) then doxygen # will sort the (detailed) documentation of file and class members # alphabetically by member name. If set to NO the members will appear in # declaration order. SORT_MEMBER_DOCS = YES # The GENERATE_TODOLIST tag can be used to enable (YES) or # disable (NO) the todo list. This list is created by putting \todo # commands in the documentation. GENERATE_TODOLIST = YES # The GENERATE_TESTLIST tag can be used to enable (YES) or # disable (NO) the test list. This list is created by putting \test # commands in the documentation. GENERATE_TESTLIST = YES # The GENERATE_BUGLIST tag can be used to enable (YES) or # disable (NO) the bug list. This list is created by putting \bug # commands in the documentation. GENERATE_BUGLIST = YES # The GENERATE_DEPRECATEDLIST tag can be used to enable (YES) or # disable (NO) the deprecated list. This list is created by putting # \deprecated commands in the documentation. GENERATE_DEPRECATEDLIST= YES # The ENABLED_SECTIONS tag can be used to enable conditional # documentation sections, marked by \if sectionname ... \endif. ENABLED_SECTIONS = # The MAX_INITIALIZER_LINES tag determines the maximum number of lines # the initial value of a variable or define consists of for it to appear in # the documentation. If the initializer consists of more lines than specified # here it will be hidden. Use a value of 0 to hide initializers completely. # The appearance of the initializer of individual variables and defines in the # documentation can be controlled using \showinitializer or \hideinitializer # command in the documentation regardless of this setting. MAX_INITIALIZER_LINES = 30 # Set the SHOW_USED_FILES tag to NO to disable the list of files generated # at the bottom of the documentation of classes and structs. If set to YES the # list will mention the files that were used to generate the documentation. SHOW_USED_FILES = YES #--------------------------------------------------------------------------- # configuration options related to warning and progress messages #--------------------------------------------------------------------------- # The QUIET tag can be used to turn on/off the messages that are generated # by doxygen. Possible values are YES and NO. If left blank NO is used. QUIET = NO # The WARNINGS tag can be used to turn on/off the warning messages that are # generated by doxygen. Possible values are YES and NO. If left blank # NO is used. WARNINGS = YES # If WARN_IF_UNDOCUMENTED is set to YES, then doxygen will generate warnings # for undocumented members. If EXTRACT_ALL is set to YES then this flag will # automatically be disabled. WARN_IF_UNDOCUMENTED = YES # If WARN_IF_DOC_ERROR is set to YES, doxygen will generate warnings for # potential errors in the documentation, such as not documenting some # parameters in a documented function, or documenting parameters that # don't exist or using markup commands wrongly. WARN_IF_DOC_ERROR = YES # The WARN_FORMAT tag determines the format of the warning messages that # doxygen can produce. The string should contain the $file, $line, and $text # tags, which will be replaced by the file and line number from which the # warning originated and the warning text. WARN_FORMAT = "$file:$line: $text" # The WARN_LOGFILE tag can be used to specify a file to which warning # and error messages should be written. If left blank the output is written # to stderr. WARN_LOGFILE = #--------------------------------------------------------------------------- # configuration options related to the input files #--------------------------------------------------------------------------- # The INPUT tag can be used to specify the files and/or directories that contain # documented source files. You may enter file names like "myfile.cpp" or # directories like "/usr/src/myproject". Separate the files or directories # with spaces. INPUT = # If the value of the INPUT tag contains directories, you can use the # FILE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp # and *.h) to filter out the source-files in the directories. If left # blank the following patterns are tested: # *.c *.cc *.cxx *.cpp *.c++ *.java *.ii *.ixx *.ipp *.i++ *.inl *.h *.hh *.hxx *.hpp # *.h++ *.idl *.odl *.cs *.php *.php3 *.inc FILE_PATTERNS = *.h *.c *.cc # The RECURSIVE tag can be used to turn specify whether or not subdirectories # should be searched for input files as well. Possible values are YES and NO. # If left blank NO is used. RECURSIVE = NO # The EXCLUDE tag can be used to specify files and/or directories that should # excluded from the INPUT source files. This way you can easily exclude a # subdirectory from a directory tree whose root is specified with the INPUT tag. EXCLUDE = # The EXCLUDE_SYMLINKS tag can be used select whether or not files or directories # that are symbolic links (a Unix filesystem feature) are excluded from the input. EXCLUDE_SYMLINKS = NO # If the value of the INPUT tag contains directories, you can use the # EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude # certain files from those directories. EXCLUDE_PATTERNS = # The EXAMPLE_PATH tag can be used to specify one or more files or # directories that contain example code fragments that are included (see # the \include command). EXAMPLE_PATH = # If the value of the EXAMPLE_PATH tag contains directories, you can use the # EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp # and *.h) to filter out the source-files in the directories. If left # blank all files are included. EXAMPLE_PATTERNS = # If the EXAMPLE_RECURSIVE tag is set to YES then subdirectories will be # searched for input files to be used with the \include or \dontinclude # commands irrespective of the value of the RECURSIVE tag. # Possible values are YES and NO. If left blank NO is used. EXAMPLE_RECURSIVE = NO # The IMAGE_PATH tag can be used to specify one or more files or # directories that contain image that are included in the documentation (see # the \image command). IMAGE_PATH = # The INPUT_FILTER tag can be used to specify a program that doxygen should # invoke to filter for each input file. Doxygen will invoke the filter program # by executing (via popen()) the command , where # is the value of the INPUT_FILTER tag, and is the name of an # input file. Doxygen will then use the output that the filter program writes # to standard output. INPUT_FILTER = # If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using # INPUT_FILTER) will be used to filter the input files when producing source # files to browse (i.e. when SOURCE_BROWSER is set to YES). FILTER_SOURCE_FILES = NO #--------------------------------------------------------------------------- # configuration options related to source browsing #--------------------------------------------------------------------------- # If the SOURCE_BROWSER tag is set to YES then a list of source files will # be generated. Documented entities will be cross-referenced with these sources. # Note: To get rid of all source code in the generated output, make sure also # VERBATIM_HEADERS is set to NO. SOURCE_BROWSER = YES # Setting the INLINE_SOURCES tag to YES will include the body # of functions and classes directly in the documentation. INLINE_SOURCES = NO # Setting the STRIP_CODE_COMMENTS tag to YES (the default) will instruct # doxygen to hide any special comment blocks from generated source code # fragments. Normal C and C++ comments will always remain visible. STRIP_CODE_COMMENTS = NO # If the REFERENCED_BY_RELATION tag is set to YES (the default) # then for each documented function all documented # functions referencing it will be listed. REFERENCED_BY_RELATION = YES # If the REFERENCES_RELATION tag is set to YES (the default) # then for each documented function all documented entities # called/used by that function will be listed. REFERENCES_RELATION = YES # If the VERBATIM_HEADERS tag is set to YES (the default) then Doxygen # will generate a verbatim copy of the header file for each class for # which an include is specified. Set to NO to disable this. VERBATIM_HEADERS = YES #--------------------------------------------------------------------------- # configuration options related to the alphabetical class index #--------------------------------------------------------------------------- # If the ALPHABETICAL_INDEX tag is set to YES, an alphabetical index # of all compounds will be generated. Enable this if the project # contains a lot of classes, structs, unions or interfaces. ALPHABETICAL_INDEX = YES # If the alphabetical index is enabled (see ALPHABETICAL_INDEX) then # the COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns # in which this list will be split (can be a number in the range [1..20]) COLS_IN_ALPHA_INDEX = 5 # In case all classes in a project start with a common prefix, all # classes will be put under the same header in the alphabetical index. # The IGNORE_PREFIX tag can be used to specify one or more prefixes that # should be ignored while generating the index headers. IGNORE_PREFIX = #--------------------------------------------------------------------------- # configuration options related to the HTML output #--------------------------------------------------------------------------- # If the GENERATE_HTML tag is set to YES (the default) Doxygen will # generate HTML output. GENERATE_HTML = YES # The HTML_OUTPUT tag is used to specify where the HTML docs will be put. # If a relative path is entered the value of OUTPUT_DIRECTORY will be # put in front of it. If left blank `html' will be used as the default path. HTML_OUTPUT = html # The HTML_FILE_EXTENSION tag can be used to specify the file extension for # each generated HTML page (for example: .htm,.php,.asp). If it is left blank # doxygen will generate files with .html extension. HTML_FILE_EXTENSION = .html # The HTML_HEADER tag can be used to specify a personal HTML header for # each generated HTML page. If it is left blank doxygen will generate a # standard header. HTML_HEADER = # The HTML_FOOTER tag can be used to specify a personal HTML footer for # each generated HTML page. If it is left blank doxygen will generate a # standard footer. HTML_FOOTER = # The HTML_STYLESHEET tag can be used to specify a user-defined cascading # style sheet that is used by each HTML page. It can be used to # fine-tune the look of the HTML output. If the tag is left blank doxygen # will generate a default style sheet. Note that doxygen will try to copy # the style sheet file to the HTML output directory, so don't put your own # stylesheet in the HTML output directory as well, or it will be erased! HTML_STYLESHEET = # If the HTML_ALIGN_MEMBERS tag is set to YES, the members of classes, # files or namespaces will be aligned in HTML using tables. If set to # NO a bullet list will be used. HTML_ALIGN_MEMBERS = YES # If the GENERATE_HTMLHELP tag is set to YES, additional index files # will be generated that can be used as input for tools like the # Microsoft HTML help workshop to generate a compressed HTML help file (.chm) # of the generated HTML documentation. GENERATE_HTMLHELP = NO # If the GENERATE_HTMLHELP tag is set to YES, the CHM_FILE tag can # be used to specify the file name of the resulting .chm file. You # can add a path in front of the file if the result should not be # written to the html output directory. CHM_FILE = # If the GENERATE_HTMLHELP tag is set to YES, the HHC_LOCATION tag can # be used to specify the location (absolute path including file name) of # the HTML help compiler (hhc.exe). If non-empty doxygen will try to run # the HTML help compiler on the generated index.hhp. HHC_LOCATION = # If the GENERATE_HTMLHELP tag is set to YES, the GENERATE_CHI flag # controls if a separate .chi index file is generated (YES) or that # it should be included in the master .chm file (NO). GENERATE_CHI = NO # If the GENERATE_HTMLHELP tag is set to YES, the BINARY_TOC flag # controls whether a binary table of contents is generated (YES) or a # normal table of contents (NO) in the .chm file. BINARY_TOC = NO # The TOC_EXPAND flag can be set to YES to add extra items for group members # to the contents of the HTML help documentation and to the tree view. TOC_EXPAND = YES # The DISABLE_INDEX tag can be used to turn on/off the condensed index at # top of each HTML page. The value NO (the default) enables the index and # the value YES disables it. DISABLE_INDEX = NO # This tag can be used to set the number of enum values (range [1..20]) # that doxygen will group on one line in the generated HTML documentation. ENUM_VALUES_PER_LINE = 4 # If the GENERATE_TREEVIEW tag is set to YES, a side panel will be # generated containing a tree-like index structure (just like the one that # is generated for HTML Help). For this to work a browser that supports # JavaScript, DHTML, CSS and frames is required (for instance Mozilla 1.0+, # Netscape 6.0+, Internet explorer 5.0+, or Konqueror). Windows users are # probably better off using the HTML help feature. GENERATE_TREEVIEW = NO # If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be # used to set the initial width (in pixels) of the frame in which the tree # is shown. TREEVIEW_WIDTH = 150 #--------------------------------------------------------------------------- # configuration options related to the LaTeX output #--------------------------------------------------------------------------- # If the GENERATE_LATEX tag is set to YES (the default) Doxygen will # generate Latex output. GENERATE_LATEX = NO # The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put. # If a relative path is entered the value of OUTPUT_DIRECTORY will be # put in front of it. If left blank `latex' will be used as the default path. LATEX_OUTPUT = latex # The LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be # invoked. If left blank `latex' will be used as the default command name. LATEX_CMD_NAME = latex # The MAKEINDEX_CMD_NAME tag can be used to specify the command name to # generate index for LaTeX. If left blank `makeindex' will be used as the # default command name. MAKEINDEX_CMD_NAME = makeindex # If the COMPACT_LATEX tag is set to YES Doxygen generates more compact # LaTeX documents. This may be useful for small projects and may help to # save some trees in general. COMPACT_LATEX = NO # The PAPER_TYPE tag can be used to set the paper type that is used # by the printer. Possible values are: a4, a4wide, letter, legal and # executive. If left blank a4wide will be used. PAPER_TYPE = a4wide # The EXTRA_PACKAGES tag can be to specify one or more names of LaTeX # packages that should be included in the LaTeX output. EXTRA_PACKAGES = # The LATEX_HEADER tag can be used to specify a personal LaTeX header for # the generated latex document. The header should contain everything until # the first chapter. If it is left blank doxygen will generate a # standard header. Notice: only use this tag if you know what you are doing! LATEX_HEADER = # If the PDF_HYPERLINKS tag is set to YES, the LaTeX that is generated # is prepared for conversion to pdf (using ps2pdf). The pdf file will # contain links (just like the HTML output) instead of page references # This makes the output suitable for online browsing using a pdf viewer. PDF_HYPERLINKS = YES # If the USE_PDFLATEX tag is set to YES, pdflatex will be used instead of # plain latex in the generated Makefile. Set this option to YES to get a # higher quality PDF documentation. USE_PDFLATEX = YES # If the LATEX_BATCHMODE tag is set to YES, doxygen will add the \\batchmode. # command to the generated LaTeX files. This will instruct LaTeX to keep # running if errors occur, instead of asking the user for help. # This option is also used when generating formulas in HTML. LATEX_BATCHMODE = YES # If LATEX_HIDE_INDICES is set to YES then doxygen will not # include the index chapters (such as File Index, Compound Index, etc.) # in the output. LATEX_HIDE_INDICES = NO #--------------------------------------------------------------------------- # configuration options related to the RTF output #--------------------------------------------------------------------------- # If the GENERATE_RTF tag is set to YES Doxygen will generate RTF output # The RTF output is optimized for Word 97 and may not look very pretty with # other RTF readers or editors. GENERATE_RTF = NO # The RTF_OUTPUT tag is used to specify where the RTF docs will be put. # If a relative path is entered the value of OUTPUT_DIRECTORY will be # put in front of it. If left blank `rtf' will be used as the default path. RTF_OUTPUT = rtf # If the COMPACT_RTF tag is set to YES Doxygen generates more compact # RTF documents. This may be useful for small projects and may help to # save some trees in general. COMPACT_RTF = NO # If the RTF_HYPERLINKS tag is set to YES, the RTF that is generated # will contain hyperlink fields. The RTF file will # contain links (just like the HTML output) instead of page references. # This makes the output suitable for online browsing using WORD or other # programs which support those fields. # Note: wordpad (write) and others do not support links. RTF_HYPERLINKS = NO # Load stylesheet definitions from file. Syntax is similar to doxygen's # config file, i.e. a series of assignments. You only have to provide # replacements, missing definitions are set to their default value. RTF_STYLESHEET_FILE = # Set optional variables used in the generation of an rtf document. # Syntax is similar to doxygen's config file. RTF_EXTENSIONS_FILE = #--------------------------------------------------------------------------- # configuration options related to the man page output #--------------------------------------------------------------------------- # If the GENERATE_MAN tag is set to YES (the default) Doxygen will # generate man pages GENERATE_MAN = NO # The MAN_OUTPUT tag is used to specify where the man pages will be put. # If a relative path is entered the value of OUTPUT_DIRECTORY will be # put in front of it. If left blank `man' will be used as the default path. MAN_OUTPUT = man # The MAN_EXTENSION tag determines the extension that is added to # the generated man pages (default is the subroutine's section .3) MAN_EXTENSION = .3 # If the MAN_LINKS tag is set to YES and Doxygen generates man output, # then it will generate one additional man file for each entity # documented in the real man page(s). These additional files # only source the real man page, but without them the man command # would be unable to find the correct page. The default is NO. MAN_LINKS = NO #--------------------------------------------------------------------------- # configuration options related to the XML output #--------------------------------------------------------------------------- # If the GENERATE_XML tag is set to YES Doxygen will # generate an XML file that captures the structure of # the code including all documentation. GENERATE_XML = NO # The XML_OUTPUT tag is used to specify where the XML pages will be put. # If a relative path is entered the value of OUTPUT_DIRECTORY will be # put in front of it. If left blank `xml' will be used as the default path. XML_OUTPUT = xml # The XML_SCHEMA tag can be used to specify an XML schema, # which can be used by a validating XML parser to check the # syntax of the XML files. XML_SCHEMA = # The XML_DTD tag can be used to specify an XML DTD, # which can be used by a validating XML parser to check the # syntax of the XML files. XML_DTD = # If the XML_PROGRAMLISTING tag is set to YES Doxygen will # dump the program listings (including syntax highlighting # and cross-referencing information) to the XML output. Note that # enabling this will significantly increase the size of the XML output. XML_PROGRAMLISTING = YES #--------------------------------------------------------------------------- # configuration options for the AutoGen Definitions output #--------------------------------------------------------------------------- # If the GENERATE_AUTOGEN_DEF tag is set to YES Doxygen will # generate an AutoGen Definitions (see autogen.sf.net) file # that captures the structure of the code including all # documentation. Note that this feature is still experimental # and incomplete at the moment. GENERATE_AUTOGEN_DEF = NO #--------------------------------------------------------------------------- # configuration options related to the Perl module output #--------------------------------------------------------------------------- # If the GENERATE_PERLMOD tag is set to YES Doxygen will # generate a Perl module file that captures the structure of # the code including all documentation. Note that this # feature is still experimental and incomplete at the # moment. GENERATE_PERLMOD = NO # If the PERLMOD_LATEX tag is set to YES Doxygen will generate # the necessary Makefile rules, Perl scripts and LaTeX code to be able # to generate PDF and DVI output from the Perl module output. PERLMOD_LATEX = NO # If the PERLMOD_PRETTY tag is set to YES the Perl module output will be # nicely formatted so it can be parsed by a human reader. This is useful # if you want to understand what is going on. On the other hand, if this # tag is set to NO the size of the Perl module output will be much smaller # and Perl will parse it just the same. PERLMOD_PRETTY = YES # The names of the make variables in the generated doxyrules.make file # are prefixed with the string contained in PERLMOD_MAKEVAR_PREFIX. # This is useful so different doxyrules.make files included by the same # Makefile don't overwrite each other's variables. PERLMOD_MAKEVAR_PREFIX = #--------------------------------------------------------------------------- # Configuration options related to the preprocessor #--------------------------------------------------------------------------- # If the ENABLE_PREPROCESSING tag is set to YES (the default) Doxygen will # evaluate all C-preprocessor directives found in the sources and include # files. ENABLE_PREPROCESSING = YES # If the MACRO_EXPANSION tag is set to YES Doxygen will expand all macro # names in the source code. If set to NO (the default) only conditional # compilation will be performed. Macro expansion can be done in a controlled # way by setting EXPAND_ONLY_PREDEF to YES. MACRO_EXPANSION = NO # If the EXPAND_ONLY_PREDEF and MACRO_EXPANSION tags are both set to YES # then the macro expansion is limited to the macros specified with the # PREDEFINED and EXPAND_AS_PREDEFINED tags. EXPAND_ONLY_PREDEF = NO # If the SEARCH_INCLUDES tag is set to YES (the default) the includes files # in the INCLUDE_PATH (see below) will be search if a #include is found. SEARCH_INCLUDES = YES # The INCLUDE_PATH tag can be used to specify one or more directories that # contain include files that are not input files but should be processed by # the preprocessor. INCLUDE_PATH = # You can use the INCLUDE_FILE_PATTERNS tag to specify one or more wildcard # patterns (like *.h and *.hpp) to filter out the header-files in the # directories. If left blank, the patterns specified with FILE_PATTERNS will # be used. INCLUDE_FILE_PATTERNS = # The PREDEFINED tag can be used to specify one or more macro names that # are defined before the preprocessor is started (similar to the -D option of # gcc). The argument of the tag is a list of macros of the form: name # or name=definition (no spaces). If the definition and the = are # omitted =1 is assumed. PREDEFINED = # If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then # this tag can be used to specify a list of macro names that should be expanded. # The macro definition that is found in the sources will be used. # Use the PREDEFINED tag if you want to use a different macro definition. EXPAND_AS_DEFINED = # If the SKIP_FUNCTION_MACROS tag is set to YES (the default) then # doxygen's preprocessor will remove all function-like macros that are alone # on a line, have an all uppercase name, and do not end with a semicolon. Such # function macros are typically used for boiler-plate code, and will confuse the # parser if not removed. SKIP_FUNCTION_MACROS = YES #--------------------------------------------------------------------------- # Configuration::addtions related to external references #--------------------------------------------------------------------------- # The TAGFILES option can be used to specify one or more tagfiles. # Optionally an initial location of the external documentation # can be added for each tagfile. The format of a tag file without # this location is as follows: # TAGFILES = file1 file2 ... # Adding location for the tag files is done as follows: # TAGFILES = file1=loc1 "file2 = loc2" ... # where "loc1" and "loc2" can be relative or absolute paths or # URLs. If a location is present for each tag, the installdox tool # does not have to be run to correct the links. # Note that each tag file must have a unique name # (where the name does NOT include the path) # If a tag file is not located in the directory in which doxygen # is run, you must also specify the path to the tagfile here. TAGFILES = # When a file name is specified after GENERATE_TAGFILE, doxygen will create # a tag file that is based on the input files it reads. GENERATE_TAGFILE = # If the ALLEXTERNALS tag is set to YES all external classes will be listed # in the class index. If set to NO only the inherited external classes # will be listed. ALLEXTERNALS = NO # If the EXTERNAL_GROUPS tag is set to YES all external groups will be listed # in the modules index. If set to NO, only the current project's groups will # be listed. EXTERNAL_GROUPS = YES # The PERL_PATH should be the absolute path and name of the perl script # interpreter (i.e. the result of `which perl'). PERL_PATH = /usr/bin/perl #--------------------------------------------------------------------------- # Configuration options related to the dot tool #--------------------------------------------------------------------------- # If the CLASS_DIAGRAMS tag is set to YES (the default) Doxygen will # generate a inheritance diagram (in HTML, RTF and LaTeX) for classes with base or # super classes. Setting the tag to NO turns the diagrams off. Note that this # option is superseded by the HAVE_DOT option below. This is only a fallback. It is # recommended to install and use dot, since it yields more powerful graphs. CLASS_DIAGRAMS = YES # If set to YES, the inheritance and collaboration graphs will hide # inheritance and usage relations if the target is undocumented # or is not a class. HIDE_UNDOC_RELATIONS = YES # If you set the HAVE_DOT tag to YES then doxygen will assume the dot tool is # available from the path. This tool is part of Graphviz, a graph visualization # toolkit from AT&T and Lucent Bell Labs. The other options in this section # have no effect if this option is set to NO (the default) HAVE_DOT = YES # If the CLASS_GRAPH and HAVE_DOT tags are set to YES then doxygen # will generate a graph for each documented class showing the direct and # indirect inheritance relations. Setting this tag to YES will force the # the CLASS_DIAGRAMS tag to NO. CLASS_GRAPH = YES # If the COLLABORATION_GRAPH and HAVE_DOT tags are set to YES then doxygen # will generate a graph for each documented class showing the direct and # indirect implementation dependencies (inheritance, containment, and # class references variables) of the class with other documented classes. COLLABORATION_GRAPH = YES # If the UML_LOOK tag is set to YES doxygen will generate inheritance and # collaboration diagrams in a style similar to the OMG's Unified Modeling # Language. UML_LOOK = YES # If set to YES, the inheritance and collaboration graphs will show the # relations between templates and their instances. TEMPLATE_RELATIONS = YES # If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDE_GRAPH, and HAVE_DOT # tags are set to YES then doxygen will generate a graph for each documented # file showing the direct and indirect include dependencies of the file with # other documented files. INCLUDE_GRAPH = YES # If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDED_BY_GRAPH, and # HAVE_DOT tags are set to YES then doxygen will generate a graph for each # documented header file showing the documented files that directly or # indirectly include this file. INCLUDED_BY_GRAPH = YES # If the CALL_GRAPH and HAVE_DOT tags are set to YES then doxygen will # generate a call dependency graph for every global function or class method. # Note that enabling this option will significantly increase the time of a run. # So in most cases it will be better to enable call graphs for selected # functions only using the \callgraph command. CALL_GRAPH = YES # If the GRAPHICAL_HIERARCHY and HAVE_DOT tags are set to YES then doxygen # will graphical hierarchy of all classes instead of a textual one. GRAPHICAL_HIERARCHY = YES # The DOT_IMAGE_FORMAT tag can be used to set the image format of the images # generated by dot. Possible values are png, jpg, or gif # If left blank png will be used. DOT_IMAGE_FORMAT = png # The tag DOT_PATH can be used to specify the path where the dot tool can be # found. If left blank, it is assumed the dot tool can be found on the path. DOT_PATH = # The DOTFILE_DIRS tag can be used to specify one or more directories that # contain dot files that are included in the documentation (see the # \dotfile command). DOTFILE_DIRS = # The MAX_DOT_GRAPH_WIDTH tag can be used to set the maximum allowed width # (in pixels) of the graphs generated by dot. If a graph becomes larger than # this value, doxygen will try to truncate the graph, so that it fits within # the specified constraint. Beware that most browsers cannot cope with very # large images. MAX_DOT_GRAPH_WIDTH = # The MAX_DOT_GRAPH_HEIGHT tag can be used to set the maximum allows height # (in pixels) of the graphs generated by dot. If a graph becomes larger than # this value, doxygen will try to truncate the graph, so that it fits within # the specified constraint. Beware that most browsers cannot cope with very # large images. MAX_DOT_GRAPH_HEIGHT = # The MAX_DOT_GRAPH_DEPTH tag can be used to set the maximum depth of the # graphs generated by dot. A depth value of 3 means that only nodes reachable # from the root by following a path via at most 3 edges will be shown. Nodes that # lay further from the root node will be omitted. Note that setting this option to # 1 or 2 may greatly reduce the computation time needed for large code bases. Also # note that a graph may be further truncated if the graph's image dimensions are # not sufficient to fit the graph (see MAX_DOT_GRAPH_WIDTH and MAX_DOT_GRAPH_HEIGHT). # If 0 is used for the depth value (the default), the graph is not depth-constrained. MAX_DOT_GRAPH_DEPTH = 0 # If the GENERATE_LEGEND tag is set to YES (the default) Doxygen will # generate a legend page explaining the meaning of the various boxes and # arrows in the dot generated graphs. GENERATE_LEGEND = YES # If the DOT_CLEANUP tag is set to YES (the default) Doxygen will # remove the intermediate dot files that are used to generate # the various graphs. DOT_CLEANUP = YES #--------------------------------------------------------------------------- # Configuration::addtions related to the search engine #--------------------------------------------------------------------------- # The SEARCHENGINE tag specifies whether or not a search engine should be # used. If set to NO the values of all tags below this one will be ignored. SEARCHENGINE = YES bar-1.11.1.orig/troubleshooter0000754000175000017500000000562610510504276016512 0ustar georgeskgeorgesk#! /bin/sh trouble_log="trouble.log" error () { echo echo "*** ERROR: ${1}" shift while [ $# -gt 0 ]; do echo " ${1}" shift done } find_binary () { if which ${1} > /dev/null 2>&1 ; then eval ${1}=`which ${1} 2> /dev/null` else error "Program ${1} not found" exit 1 fi } cmd () { echo >> ${trouble_log} echo "-------------------------------------------------------------------------------" >> ${trouble_log} echo "Executing: $*" >> ${trouble_log} echo "-------------------------------------------------------------------------------" >> ${trouble_log} echo >> ${trouble_log} $* >> ${trouble_log} 2>&1 cmd_result=$? echo >> ${trouble_log} echo >> ${trouble_log} echo "Exit code: ${cmd_result}" >> ${trouble_log} echo >> ${trouble_log} echo "-------------------------------------------------------------------------------" >> ${trouble_log} echo >> ${trouble_log} return ${cmd_result} } echo "Searching for required programs..." find_binary grep find_binary sed find_binary awk find_binary cut find_binary cat find_binary ls find_binary rm find_binary script find_binary gzip ${cat} << EOF This script will attempt to assemble a wealth of drivel that the author hopes will be useful in trying to resolve problems with bar and help him to increase bar's ease of installation and portability in future versions. Please wait... EOF if [ -f ${trouble_log} ]; then ${rm} -f ${trouble_log} fi if [ -f ${trouble_log}.gz ]; then ${rm} -f ${trouble_log}.gz fi # if [ -f ./config.log ]; then # echo "./config.log found, searching for last configure options used..." # opts=` \ # ${cat} ./config.log \ # | ${grep} '^ \$ \.\/configure' \ # | ${sed} 's,^ \$ \.\/configure,,g' \ # | ${sed} 's,^ ,,g' \ # ` # if [ -z "${opts}" ]; then # echo "No options were used with configure" # else # echo "Options last used: ${opts}" # fi # else # opts=''; # fi if cmd ./configure ; then cmd ${cat} ./config.log if cmd make ; then if cmd make check ; then if cmd ./bar -if ./bar -of /dev/null ; then ${cat} << EOF Hmm... It looks as though bar's I/O works fine, but then the tests and/or this script might be missing something. EOF fi fi fi if cmd ./configure --disable-use-memalign --disable-use-iovec ; then cmd ${cat} ./config.log if cmd make ; then if cmd make check ; then if cmd ./bar -if ./bar -of /dev/null ; then ${cat} << EOF It appears that bar works if configured without aligned memory and vectored I/O support. You might try configuring bar with --disable-use-memalign and --disable-use-iovec and see if that fixes things. EOF fi fi fi else cmd ${cat} ./config.log fi else cmd ${cat} ./config.log fi echo "Compressing log file..." gzip -9v ${trouble_log} echo "Done." ${cat} << EOF Please email michaelpeek@users.sourceforge.net. Include a description of your problem and attach the file ${trouble_log}.gz. EOF # vim:ts=2:shiftwidth=2:filetype=sh:syntax=sh: bar-1.11.1.orig/headers.h0000644000175000017500000000233211433512646015265 0ustar georgeskgeorgesk#ifndef STDC_HEADERS #error "Argh! This system has non-standard header files!" #endif #ifdef STAT_MACROS_BROKEN #error "Argh! This system has broken sys/stat.h macros!" #endif #ifdef HAVE_STDIO_H #include #endif #ifdef HAVE_STDLIB_H #include #endif #ifdef HAVE_MALLOC_H #include #endif #ifdef HAVE_CTYPE_H #include #endif #ifdef HAVE_STDARG_H #include #endif #ifdef HAVE_UNISTD_H #include #endif #ifdef HAVE_SYS_STAT_H #include #endif #ifdef HAVE_SYS_TYPES_H #include #endif #ifdef HAVE_FCNTL_H #include #endif #if TIME_WITH_SYS_TIME # include # include #else # if HAVE_SYS_TIME_H # include # else # include # endif #endif #ifdef HAVE_STRING_H #include #endif #ifdef HAVE_STRINGS_H #include #endif #ifdef HAVE_SIGNAL_H #include #endif #ifdef HAVE_TERMIOS_H #include #endif #ifdef HAVE_SYS_IOCTL_H #include #endif #ifdef HAVE_SYS_SELECT_H #include #endif #ifdef HAVE_SYS_UIO_H #include #endif #ifdef HAVE_ERRNO_H #include #endif #ifdef HAVE_ASSERT_H #include #endif bar-1.11.1.orig/configure.in0000644000175000017500000004472511541656011016021 0ustar georgeskgeorgeskAC_INIT(bar.c) AC_CANONICAL_SYSTEM AM_INIT_AUTOMAKE(bar,1.11.1) AM_CONFIG_HEADER(config.h) AC_PROG_CC AC_PROG_INSTALL AC_PROG_LN_S AC_PROG_AWK AC_HEADER_STDC AC_CHECK_HEADERS([ \ assert.h \ ctype.h \ errno.h \ fcntl.h \ malloc.h \ stdarg.h \ stdio.h \ stdlib.h \ string.h \ strings.h \ sys/ioctl.h \ sys/select.h \ sys/stat.h \ sys/time.h \ sys/uio.h \ unistd.h \ signal.h \ termios.h \ ]) AC_CHECK_FUNCS([ \ posix_memalign \ select \ strerror \ sysconf \ sprintf \ ]) AC_FUNC_MALLOC AC_HEADER_TIME dnl dnl The following tests for Large File support reverse-engineered from dnl the GNU core utilities: ftp://alpha.gnu.org/gnu/coreutils/ dnl AC_MSG_CHECKING([if filesystem supports Large Files natively]) if test "${ac_cv_c_native_large_file_support+set}" = set; then AC_MSG_RESULT([(cached)] $ac_cv_c_native_large_file_support) else AC_TRY_COMPILE( [ #include #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) ] , [ int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 && LARGE_OFF_T % 2147483647 == 1) ? 1 : -1]; ] , ac_cv_c_native_large_file_support=yes , ac_cv_c_native_large_file_support=no ) AC_MSG_RESULT($ac_cv_c_native_large_file_support) fi if test $ac_cv_c_native_large_file_support = no; then AC_MSG_CHECKING([if _FILE_OFFSET_BITS needed for Large Files]) AC_TRY_COMPILE( [ #define _FILE_OFFSET_BITS 64 #include #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) ] , [ int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 && LARGE_OFF_T % 2147483647 == 1) ? 1 : -1]; ] , ac_cv_c_need_file_offset_bits=yes AC_DEFINE(_FILE_OFFSET_BITS,64,[Define if OS needs it for Large Files]) AC_MSG_RESULT([yes]) , ac_cv_c_need_file_offset_bits=no AC_MSG_RESULT([no]) ) fi if test $ac_cv_c_native_large_file_support = no; then AC_MSG_CHECKING([if _LARGE_FILES needed for Large Files]) if test $ac_cv_c_need_file_offset_bits = yes; then ac_cv_c_need_large_files=no AC_MSG_RESULT([no]) else AC_TRY_COMPILE( [ #define _LARGE_FILES 1 #include #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) ] , [ int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 && LARGE_OFF_T % 2147483647 == 1) ? 1 : -1]; ] , ac_cv_c_need_large_files=yes AC_DEFINE(_LARGE_FILES,1,[Define if OS needs it for Large Files]) AC_MSG_RESULT([yes]) , ac_cv_c_need_large_files=no AC_MSG_RESULT([no]) ) fi fi dnl dnl Check to see if struct iovec is available dnl AC_MSG_CHECKING([for vectored I/O support]) if test "${ac_cv_have_struct_iovec+set}" = set; then AC_MSG_RESULT([(cached)] $ac_cv_have_struct_iovec) else AC_TRY_COMPILE( [ #ifdef HAVE_SYS_UIO_H #include #endif ], [ struct iovec vec[2]; vec[0].iov_base = 0; vec[0].iov_len = 0; ], [ac_cv_have_struct_iovec=yes] AC_DEFINE(HAVE_STRUCT_IOVEC,1,[Define if struct iovec found]) , [ac_cv_have_struct_iovec=no] ) AC_MSG_RESULT($ac_cv_have_struct_iovec) fi AC_CHECK_SIZEOF(unsigned char) AC_CHECK_SIZEOF(unsigned short) AC_CHECK_SIZEOF(unsigned int) AC_CHECK_SIZEOF(unsigned long) AC_CHECK_SIZEOF(unsigned long long) AC_CHECK_SIZEOF(size_t) AC_CHECK_DECLS(_SC_PAGE_SIZE) AC_CHECK_DECLS(_SC_PAGESIZE) ac_cv_default_sw_minus_one=0 case "$target" in *-pc-cygwin) ac_cv_default_sw_minus_one=1 ;; esac AC_ARG_ENABLE( sw-1, AC_HELP_STRING( [--enable-sw-1], [Assume screen width - 1] ), [ac_cv_default_sw_minus_one=1], [ac_cv_default_sw_minus_one=0] ) AC_ARG_ENABLE( sw-0, AC_HELP_STRING( [--enable-sw-0], [Assume full screen width] ), [ac_cv_default_sw_minus_one=0], ) AC_ARG_ENABLE( sh-1, AC_HELP_STRING( [--enable-sh-1], [Assume screen height - 1] ), [ac_cv_default_sh_minus_one=1], [ac_cv_default_sh_minus_one=0] ) AC_ARG_ENABLE( sh-0, AC_HELP_STRING( [--enable-sh-0], [Assume full screen height] ), [ac_cv_default_sh_minus_one=0], ) AC_CACHE_CHECK( [for default screen width adjustment], [ac_cv_default_sw_minus_one], [ac_cv_default_sw_minus_one=0] ) AC_CACHE_CHECK( [for default screen height adjustment], [ac_cv_default_sh_minus_one], [ac_cv_default_sh_minus_one=0] ) AC_DEFINE_UNQUOTED( DEFAULT_SW_MINUS_ONE, $ac_cv_default_sw_minus_one, [Use a screen width adjustment of -1 by default] ) AC_SUBST(DEFAULT_SW_MINUS_ONE) AC_DEFINE_UNQUOTED( DEFAULT_SH_MINUS_ONE, $ac_cv_default_sh_minus_one, [Use a screen height adjustment of -1 by default] ) AC_SUBST(DEFAULT_SH_MINUS_ONE) AC_ARG_ENABLE( [display-twiddle], AC_HELP_STRING( [--enable-display-twiddle], [Enable twiddle display by default] ), [ac_cv_default_display_twiddle=1], [ac_cv_default_display_twiddle=0] ) AC_CACHE_CHECK( [if twiddle display should be enabled by default], [ac_cv_default_display_twiddle], [ac_cv_default_display_twiddle=0] ) AC_DEFINE_UNQUOTED( DEFAULT_DISPLAY_TWIDDLE, $ac_cv_default_display_twiddle, [Default twiddle display setting] ) AC_SUBST(DEFAULT_DISPLAY_TWIDDLE) AC_ARG_WITH( [buffer-size], AC_HELP_STRING([--with-buffer-size=SIZE], [Default buffer size = SIZE bytes (default: 52488 (or 512KB))] ), [ac_cv_default_buffer_size=$withval], [ac_cv_default_buffer_size=52488] ) AC_CACHE_CHECK( [default buffer size], [ac_cv_default_buffer_size], [ac_cv_default_buffer_size=52488] ) AC_DEFINE_UNQUOTED( DEFAULT_BUFFER_SIZE, $ac_cv_default_buffer_size, [Use this default buffer size] ) AC_SUBST(DEFAULT_BUFFER_SIZE) if test "${ac_cv_func_sysconf}" = "yes"; then AC_MSG_CHECKING([sysconf usability]) if test "${ac_cv_sysconf_works+set}" = set; then AC_MSG_RESULT([(cached)] $ac_cv_sysconf_works) else AC_TRY_RUN( [ #include #include #include #include #include #ifdef HAVE_SYSCONF # if HAVE_DECL__SC_PAGE_SIZE == 1 # define PAGESIZE _SC_PAGE_SIZE # else # if HAVE_DECL__SC_PAGESIZE == 1 # define PAGESIZE _SC_PAGESIZE # endif # endif # ifndef PAGESIZE # error I dont know how to retrieve the size of a page using sysconf. # undef HAVE_SYSCONF # endif #endif int main(int argc, char *argv[]) { long page_size = 0; #ifdef HAVE_SYSCONF page_size = sysconf(PAGESIZE); #endif fprintf(stderr, "sysconf says the page size is: %ld\n", page_size); assert(page_size != 0); assert(page_size > 0); assert(page_size % sizeof(void *) == 0); return(0); } ] , ac_cv_sysconf_works="yes" , ac_cv_sysconf_works="no" ) AC_MSG_RESULT($ac_cv_sysconf_works) fi fi if test "${ac_cv_sysconf_works}" = "yes"; then ac_cv_default_page_size=`cat config.log | grep '^sysconf says the page size is: ' | awk -F: '{print $2}' | sed 's, ,,g'`; fi AC_ARG_WITH( [page-size], AC_HELP_STRING([--with-page-size=SIZE], [Default page size = SIZE bytes (default: as reported by sysconf, or 8192 (or 8KB))] ), [ac_cv_default_page_size=$withval], ) if test "${ac_cv_default_page_size+set}" != set; then ac_cv_default_page_size=8192 fi AC_CACHE_CHECK( [default page size], [ac_cv_default_page_size], [ac_cv_default_page_size=8192] ) AC_DEFINE_UNQUOTED( DEFAULT_PAGE_SIZE, $ac_cv_default_page_size, [Use this default page size if cannot determine through sysconf] ) AC_SUBST(DEFAULT_PAGE_SIZE) AC_ARG_ENABLE( [use-memalign], AC_HELP_STRING( [--disable-use-memalign], [Disable aligned memory allocation (save memory, less than 1% performance decrease) (default: enabled)] ), [ac_cv_use_memalign=$enableval], [ac_cv_use_memalign="yes"] ) AC_CACHE_CHECK( [if aligned memory allocation is enabled], [ac_cv_use_memalign], [ac_cv_use_memalign] ) if test "${ac_cv_use_memalign}" = "yes"; then if test "${ac_cv_func_posix_memalign}" = "no"; then ac_cv_use_memalign="no" else AC_MSG_CHECKING([for posix_memalign usability]) if test "${ac_cv_posix_memalign_works+set}" = set; then AC_MSG_RESULT([(cached)] $ac_cv_posix_memalign_works) else AC_TRY_RUN( [ #include #include #include #include #ifdef HAVE_SYSCONF # if HAVE_DECL__SC_PAGE_SIZE == 1 # define PAGESIZE _SC_PAGE_SIZE # else # if HAVE_DECL__SC_PAGESIZE == 1 # define PAGESIZE _SC_PAGESIZE # endif # endif # ifndef PAGESIZE # warning I dont know how to retrieve the size of a page using sysconf. # warning Assuming page size is DEFAULT_PAGE_SIZE bytes. # undef HAVE_SYSCONF # endif #endif int main(int argc, char *argv[]) { long page_size = DEFAULT_PAGE_SIZE; unsigned long long buffer_size = DEFAULT_PAGE_SIZE; unsigned long long count = 0; char * ptr = 0; int ret_val = 0; int einval = EINVAL; int enomem = ENOMEM; #ifdef HAVE_SYSCONF page_size = sysconf(PAGESIZE); #endif assert(page_size > 0); assert(page_size % sizeof(void *) == 0); if (page_size > buffer_size) { buffer_size = page_size; } buffer_size /= sizeof(void *); buffer_size *= 2*sizeof(void *); ret_val = posix_memalign((void *)&ptr,page_size,buffer_size); assert(!(ret_val == einval)); assert(!(ret_val == enomem)); assert(ret_val == 0); for (count = 0; count < buffer_size; count++) { ptr[count] = 0; } free(ptr); return(0); } ] , ac_cv_posix_memalign_works=yes , ac_cv_posix_memalign_works=no ) AC_MSG_RESULT($ac_cv_posix_memalign_works) fi if test "${ac_cv_posix_memalign_works}" = "no"; then AC_MSG_CHECKING([if posix_memalign requires _GNU_SOURCE to be defined]) if test "${ac_cv_posix_memalign_gnu_source+set}" = set; then AC_MSG_RESULT([(cached)] $ac_cv_posix_memalign_gnu_source) else AC_TRY_RUN( [ #include #include #include #include #ifdef HAVE_SYSCONF # if HAVE_DECL__SC_PAGE_SIZE == 1 # define PAGESIZE _SC_PAGE_SIZE # else # if HAVE_DECL__SC_PAGESIZE == 1 # define PAGESIZE _SC_PAGESIZE # endif # endif # ifndef PAGESIZE # warning I dont know how to retrieve the size of a page using sysconf. # warning Assuming page size is DEFAULT_PAGE_SIZE bytes. # undef HAVE_SYSCONF # endif #endif #define _GNU_SOURCE 1 int main(int argc, char *argv[]) { long page_size = DEFAULT_PAGE_SIZE; unsigned long long buffer_size = DEFAULT_PAGE_SIZE; unsigned long long count = 0; char * ptr = 0; int ret_val = 0; int einval = EINVAL; int enomem = ENOMEM; #ifdef HAVE_SYSCONF page_size = sysconf(PAGESIZE); #endif assert(page_size > 0); assert(page_size % sizeof(void *) == 0); if (page_size > buffer_size) { buffer_size = page_size; } buffer_size /= sizeof(void *); buffer_size *= 2*sizeof(void *); ret_val = posix_memalign((void *)&ptr,page_size,buffer_size); assert(!(ret_val == einval)); assert(!(ret_val == enomem)); assert(ret_val == 0); for (count = 0; count < buffer_size; count++) { ptr[count] = 0; } free(ptr); return(0); } ] , ac_cv_posix_memalign_gnu_source=yes ac_cv_posix_memalign_works=yes AC_DEFINE(_GNU_SOURCE,1,[Define if posix_memalign needs _GNU_SOURCE]) AC_MSG_RESULT([yes]) , ac_cv_posix_memalign_gnu_source=no AC_MSG_RESULT([no]) ) fi fi if test "${ac_cv_posix_memalign_works}" = "no"; then AC_MSG_CHECKING([if posix_memalign requires _XOPEN_SOURCE=600 to be defined]) if test "${ac_cv_posix_memalign_xopen_source+set}" = set; then AC_MSG_RESULT([(cached)] $ac_cv_posix_memalign_xopen_source) else AC_TRY_RUN( [ #include #include #include #include #ifdef HAVE_SYSCONF # if HAVE_DECL__SC_PAGE_SIZE == 1 # define PAGESIZE _SC_PAGE_SIZE # else # if HAVE_DECL__SC_PAGESIZE == 1 # define PAGESIZE _SC_PAGESIZE # endif # endif # ifndef PAGESIZE # warning I dont know how to retrieve the size of a page using sysconf. # warning Assuming page size is DEFAULT_PAGE_SIZE bytes. # undef HAVE_SYSCONF # endif #endif #define _XOPEN_SOURCE 600 int main(int argc, char *argv[]) { long page_size = DEFAULT_PAGE_SIZE; unsigned long long buffer_size = DEFAULT_PAGE_SIZE; unsigned long long count = 0; char * ptr = 0; int ret_val = 0; int einval = EINVAL; int enomem = ENOMEM; #ifdef HAVE_SYSCONF page_size = sysconf(PAGESIZE); #endif assert(page_size > 0); assert(page_size % sizeof(void *) == 0); if (page_size > buffer_size) { buffer_size = page_size; } buffer_size /= sizeof(void *); buffer_size *= 2*sizeof(void *); ret_val = posix_memalign((void *)&ptr,page_size,buffer_size); assert(!(ret_val == einval)); assert(!(ret_val == enomem)); assert(ret_val == 0); for (count = 0; count < buffer_size; count++) { ptr[count] = 0; } free(ptr); return(0); } ] , ac_cv_posix_memalign_xopen_source=yes ac_cv_posix_memalign_works=yes AC_DEFINE(_XOPEN_SOURCE,600,[Define if posix_memalign needs _XOPEN_SOURCE >= 600]) AC_MSG_RESULT([yes]) , ac_cv_posix_memalign_xopen_source=no AC_MSG_RESULT([no]) ) fi fi fi fi AC_CACHE_CHECK( [if aligned memory allocation is available], [ac_cv_use_memalign], [ac_cv_use_memalign] ) if test "${ac_cv_use_memalign}" = "yes"; then AC_MSG_CHECKING([if aligned memory allocation is usable]) if test "${ac_cv_posix_memalign_works}" = "yes"; then AC_MSG_RESULT([yes]) else AC_MSG_RESULT([no]) ac_cv_use_memalign="no" fi fi if test "${ac_cv_use_memalign}" = "yes"; then AC_DEFINE(USE_MEMALIGN,1,[Use aligned memory allocation (if available)]) fi AC_ARG_ENABLE( [use-iovec], AC_HELP_STRING( [--disable-use-iovec], [Disable vectored I/O (30-50% performance decrease) (default: enabled)] ), [ac_cv_use_iovec=$enableval], [ac_cv_use_iovec="yes"] ) AC_CACHE_CHECK( [if vectored I/O is enabled], [ac_cv_use_iovec], [ac_cv_use_iovec] ) if test "${ac_cv_have_struct_iovec}" = "no"; then ac_cv_use_iovec="no" fi AC_CACHE_CHECK( [if vectored I/O is available], [ac_cv_use_iovec], [ac_cv_use_iovec] ) if test "${ac_cv_use_iovec}" = "yes"; then AC_DEFINE(USE_IOVEC,1,[Use vectored I/O (if available)]) fi dnl dnl Check to see if CC supports -m64 dnl AC_MSG_CHECKING([whether CC supports -m64]) if test "${ac_cv_m64_available+set}" = set; then AC_MSG_RESULT([(cached)] $ac_cv_m64_available) else my_save_cflags="$CFLAGS" CFLAGS=-m64 AC_TRY_COMPILE( [ #include ] , [ return(0); ] , ac_cv_m64_available=yes , ac_cv_m64_available=no ) CFLAGS="$my_save_cflags" AC_MSG_RESULT($ac_cv_m64_available) fi dnl dnl Check to see if we should use -m64 dnl AC_ARG_ENABLE( [use-m64], AC_HELP_STRING( [--disable-use-m64], [Disable the use of -m64 compiler flag (default: enabled)] ), [ac_cv_use_m64=$enableval], [ac_cv_use_m64="yes"] ) AC_CACHE_CHECK( [if the use of -m64 compiler flag is enabled], [ac_cv_use_m64], [ac_cv_use_m64] ) if test "${ac_cv_m64_available}" = "yes"; then if test "${ac_cv_use_m64}" = "yes"; then AM_CFLAGS="${AM_CFLAGS} -m64" AC_SUBST([AM_CFLAGS]) fi fi dnl dnl Not all systems can count to 1 exabyte (apparently) dnl This seems to be a bug in some compilers that do not natively generate dnl 64-bit executables on 64-bit operating systems. dnl AC_MSG_CHECKING([if system supports counting to 1 exabyte]) if test "${ac_cv_c_exabyte_support+set}" = set; then AC_MSG_RESULT([(cached)] $ac_cv_c_exabyte_support) else AC_TRY_COMPILE( [ #include ] , [ unsigned long long n = 1; n *= 1000; /* 1K */ n *= 1000; /* 1M */ n *= 1000; /* 1G */ n *= 1000; /* 1T */ n *= 1000; /* 1P */ n *= 1000; /* 1E */ n /= 1000; n /= 1000; n /= 1000; n /= 1000; n /= 1000; n /= 1000; assert(n == 1); ] , [ac_cv_c_exabyte_support=yes] AC_DEFINE(HAVE_EXABYTE_SUPPORT,1,[Define if we can count to 1E]) , [ac_cv_c_exabyte_support=no] ) AC_MSG_RESULT($ac_cv_c_exabyte_support) fi dnl dnl Not all systems can count to 1 petabyte (apparently) dnl This seems to be a bug in some compilers that do not natively generate dnl 64-bit executables on 64-bit operating systems. dnl AC_MSG_CHECKING([if system supports counting to 1 petabyte]) if test "${ac_cv_c_petabyte_support+set}" = set; then AC_MSG_RESULT([(cached)] $ac_cv_c_petabyte_support) else AC_TRY_COMPILE( [ #include ] , [ unsigned long long n = 1; n *= 1000; /* 1K */ n *= 1000; /* 1M */ n *= 1000; /* 1G */ n *= 1000; /* 1T */ n *= 1000; /* 1P */ n /= 1000; n /= 1000; n /= 1000; n /= 1000; n /= 1000; assert(n == 1); ] , [ac_cv_c_petabyte_support=yes] AC_DEFINE(HAVE_PETABYTE_SUPPORT,1,[Define if we can count to 1P]) , [ac_cv_c_petabyte_support=no] ) AC_MSG_RESULT($ac_cv_c_petabyte_support) fi dnl dnl Not all systems can count to 1 terabyte (apparently) dnl This seems to be a bug in some compilers that do not natively generate dnl 64-bit executables on 64-bit operating systems. dnl AC_MSG_CHECKING([if system supports counting to 1 terabyte]) if test "${ac_cv_c_terabyte_support+set}" = set; then AC_MSG_RESULT([(cached)] $ac_cv_c_terabyte_support) else AC_TRY_COMPILE( [ #include ] , [ unsigned long long n = 1; n *= 1000; /* 1K */ n *= 1000; /* 1M */ n *= 1000; /* 1G */ n *= 1000; /* 1T */ n /= 1000; n /= 1000; n /= 1000; n /= 1000; assert(n == 1); ] , [ac_cv_c_terabyte_support=yes] AC_DEFINE(HAVE_TERABYTE_SUPPORT,1,[Define if we can count to 1T]) , [ac_cv_c_terabyte_support=no] ) AC_MSG_RESULT($ac_cv_c_terabyte_support) fi if test "${ac_cv_c_exabyte_support}" = "no"; then if test "${ac_cv_c_petabyte_support}" = "no"; then if test "${ac_cv_c_terabyte_support}" = "no"; then ac_cv_c_max_safe_multiplier=1000000000 else ac_cv_c_max_safe_multiplier=1000000000000 fi else ac_cv_c_max_safe_multiplier=1000000000000000 fi else ac_cv_c_max_safe_multiplier=1000000000000000000 fi AC_DEFINE_UNQUOTED( MAX_SAFE_MULTIPLIER, $ac_cv_c_max_safe_multiplier, [Use this as the maximum safe multiplier value for safe_mul()] ) AC_SUBST(MAX_SAFE_MULTIPLIER) AC_CONFIG_FILES([Makefile bar.1 doxygen.conf]) AC_CONFIG_COMMANDS([test-script-preparation],[chmod u+x test-00?]) AC_OUTPUT AC_MSG_NOTICE([]) AC_MSG_NOTICE([Current Configuration:]) AC_MSG_NOTICE([----------------------]) if test "${ac_cv_default_sw_minus_one}" -eq 1; then AC_MSG_NOTICE([ Screen width -1 modifier: yes]) else AC_MSG_NOTICE([ Screen width -1 modifier: no]) fi if test "${ac_cv_default_sh_minus_one}" -eq 1; then AC_MSG_NOTICE([ Screen height -1 modifier: yes]) else AC_MSG_NOTICE([ Screen height -1 modifier: no]) fi if test "${ac_cv_default_display_twiddle}" -eq 1; then AC_MSG_NOTICE([ Display twiddle by default: yes]) else AC_MSG_NOTICE([ Display twiddle by default: no]) fi if test "${ac_cv_use_memalign}" = "yes"; then AC_MSG_NOTICE([Use aligned memory allocation:] $ac_cv_use_memalign [(default page size:] $ac_cv_default_page_size[)]) else AC_MSG_NOTICE([Use aligned memory allocation:] $ac_cv_use_memalign) fi AC_MSG_NOTICE([ Use vectored I/O:] $ac_cv_use_iovec) AC_MSG_NOTICE([ Default I/O buffer size:] $ac_cv_default_buffer_size) AC_MSG_NOTICE([ Install Path:] $prefix) AC_MSG_NOTICE([]) bar-1.11.1.orig/Makefile.am0000644000175000017500000001346411541674165015552 0ustar georgeskgeorgesk# # To override any of the following variables, you can set the veriable in your # environment before calling make. Be sure that make will honor environmental # overrides, usually by passing the -e flag to make or by setting MAKEFLAGS in # your environment. # # Ex: # # $ ./configure # $ CFLAGS="-g -Wall" make -e # $ make install # # CFLAGS = # CFLAGS = -O2 # CFLAGS = -g -Wall # LDFLAGS = -s # LDFLAGS = bin_PROGRAMS = noinst_PROGRAMS = noinst_HEADERS = TESTS = nodist_TESTS = BUILT_SOURCES = CLEANFILES = *~ DISTCLEANFILES = ./deps/*.P EXTRA_DIST = man_MANS = noinst_HEADERS += headers.h noinst_PROGRAMS += test-types test_types_SOURCES = \ test-types.c \ # TESTS += test-types # noinst_PROGRAMS += test-args # test_args_SOURCES = \ # error.c \ # fd.c \ # io.c \ # display.c \ # args.c \ # test-args.c \ # # # TESTS += test-args noinst_PROGRAMS += test-001-pre test_001_pre_SOURCES = \ test-001-pre.c \ # noinst_PROGRAMS += test-001-post test_001_post_SOURCES = \ test-001-post.c \ # TESTS += test-001 EXTRA_DIST += test-001 TESTS += test-002 EXTRA_DIST += test-002 CLEANFILES += test-file-002.1.bin test-file-002.2.bin # TESTS += test-003 EXTRA_DIST += test-003 CLEANFILES += test-file-003.incomplete.bin CLEANFILES += test-file-003.1.bin CLEANFILES += test-file-003.2.bin CLEANFILES += test-pipe-003.1 CLEANFILES += test-pipe-003.2 CLEANFILES += test-pipe-003.3 # TESTS += test-004 EXTRA_DIST += test-004 CLEANFILES += test-file-004.incomplete.bin CLEANFILES += test-file-004.bin CLEANFILES += test-file-004.1.bin CLEANFILES += test-file-004.2.bin EXTRA_DIST += itest EXTRA_DIST += itest2 DISTCLEANFILES += ./log.test-* bin_PROGRAMS += bar noinst_HEADERS += types.h noinst_HEADERS += error.h noinst_HEADERS += fd.h noinst_HEADERS += io.h noinst_HEADERS += display.h noinst_HEADERS += args.h bar_SOURCES = \ error.c \ fd.c \ io.c \ display.c \ args.c \ bar.c \ # man_MANS += bar.1 EXTRA_DIST += $(man_MANS) # EXTRA_DIST += PORTING EXTRA_DIST += autogen EXTRA_DIST += debian/changelog EXTRA_DIST += debian/control EXTRA_DIST += debian/copyright EXTRA_DIST += debian/dirs EXTRA_DIST += debian/install EXTRA_DIST += debian/rules EXTRA_DIST += sourceforge.mk EXTRA_DIST += TROUBLESHOOTING EXTRA_DIST += troubleshooter EXTRA_DIST += infofile include sourceforge.mk dch: cd ./debian && dch --check-dirname-level 0 dchi: cd ./debian && dch -i --check-dirname-level 0 # #------------------------------------------------------------------------------ # FILE_DIR = ../dist WEB_DIR = ../www ARCH := $(shell uname -m) update: update-dist update-www update-dist: dist [ -d $(FILE_DIR) ] || exit 1 [ -f $(distdir).tar.gz ] || exit 1 chmod 0755 $(FILE_DIR) -rm -fr $(FILE_DIR)/$(PACKAGE)* -rm -fr $(FILE_DIR)/$(distdir) gzip -dc $(distdir).tar.gz | (cd $(FILE_DIR) && tar -xvf -) [ -x /usr/bin/dpkg-buildpackage ] || exit 1 [ -x /usr/bin/fakeroot ] || exit 1 cd $(FILE_DIR)/$(distdir) && dpkg-buildpackage -us -uc -rfakeroot rm -fr $(FILE_DIR)/$(distdir) [ -x /usr/bin/alien ] || exit 1 cd $(FILE_DIR) && fakeroot alien --to-rpm $(PACKAGE)_$(VERSION)_*.deb [ -x /usr/bin/alien ] || exit 1 cd $(FILE_DIR) && fakeroot alien --to-tgz $(PACKAGE)_$(VERSION)_*.deb cd $(FILE_DIR) && mv $(PACKAGE)-$(VERSION).tgz $(PACKAGE)-$(VERSION)_$(ARCH).tgz -rm ./ChangeLog cp debian/changelog $(FILE_DIR)/$(PACKAGE)-$(VERSION)-ChangeLog [ ! -f README ] || cp README $(FILE_DIR)/$(PACKAGE)-$(VERSION)-README [ -x /usr/bin/groff ] || exit 1 for file in $(man_MANS); do \ cat $${file} \ | groff -man -Tascii \ | sed \ -e 's,_,,g' \ -e 's,.,,g' \ > $(FILE_DIR)/$(PACKAGE)-$(VERSION)-man.txt \ ; \ done update-www: [ -d $(WEB_DIR) ] || exit 1 -rm -fr $(WEB_DIR)/doxygen/$(VERSION) cat doxygen.conf.in \ | sed "s,{PACKAGE},$(PACKAGE),g" \ | sed "s,{VERSION},$(VERSION),g" \ | sed "s,{DOC_DIR},$(WEB_DIR)/doxygen/$(VERSION),g" \ > doxygen.conf doxygen ./doxygen.conf cd $(WEB_DIR) && $(MAKE) ############################################################################### # # Automated Sourceforge Compilefarm Testing # ############################################################################### # include sourceforge.mk # $(PACKAGE)-$(VERSION).tar.gz: $(DIST_COMMON) $(SOURCES) # $(MAKE) dist # # update-sourceforge-compilefarm: .update-sourceforge-compilefarm # .update-sourceforge-compilefarm: $(PACKAGE)-$(VERSION).tar.gz # tar -cvf - ./$(PACKAGE)-$(VERSION).tar.gz \ # | ssh -l michaelpeek shell.cf.sourceforge.net \ # "tar -xvf -" # touch $@ # # test-sourceforge-compilefarm-generic: .test-sourceforge-compilefarm-$(HOST) # .test-sourceforge-compilefarm-$(HOST): .update-sourceforge-compilefarm # -ssh -l michaelpeek shell.cf.sourceforge.net \ # "test-project \"$(HOST)\" \"$(PACKAGE)\" \"$(VERSION)\"" 2>&1 \ # | tee log.sourceforge.$(HOST).txt \ # | sed 's,^,[$(HOST)]: ,g' # # test-sourceforge-compilefarm: .update-sourceforge-compilefarm # for host in $(SOURCEFORGE_COMPILE_FARM_HOSTS); do \ # $(MAKE) test-sourceforge-compilefarm-generic HOST="$${host}" ; \ # done ; \ # # # # test-sourceforge: .update-sourceforge-compilefarm # -rm -f log.sourceforge.* # $(MAKE) test-sourceforge-compilefarm 2>&1 | tee log.sourceforge.txt ############################################################################### beep: @printf '' @sleep 1 @printf '' @sleep 1 @printf '' extract-deb: bin-pkgs for this_file in $(shell ls -1 $(PKG_DIR)/); do \ this_name=$$(dpkg-deb --field "$${this_file}" Package) ; \ this_vers=$$(dpkg-deb --field "$${this_file}" Version) ; \ this_arch=$$(dpkg-deb --field "$${this_file}" Architecture) ; \ this_dir="$(PKG_DIR)/$${this_name}_$${this_vers}_$${this_arch}" ; \ rm -fr "$${this_dir}" || true ; \ mkdir -p "$${this_dir}" || exit 1 ; \ dpkg-deb -x "$${this_file}" "$${this_dir}" || exit 1 ; \ dpkg-deb -e "$${this_file}" "$${this_dir}/DEBIAN" || exit 1 ; \ done ; \ #