[Ffmpeg-cvslog] r5509 - trunk/configure
mru
subversion
Thu Jun 22 20:57:40 CEST 2006
Author: mru
Date: Thu Jun 22 20:57:40 2006
New Revision: 5509
Modified:
trunk/configure
Log:
enable logging in configure by default, and print some advice on failure
Modified: trunk/configure
==============================================================================
--- trunk/configure (original)
+++ trunk/configure Thu Jun 22 20:57:40 2006
@@ -9,7 +9,7 @@
echo
echo "Standard options:"
echo " --help print this message"
- echo " --log log tests and output to config.err"
+ echo " --log[=FILE|yes|no] log tests and output to FILE [config.err]"
echo " --prefix=PREFIX install in PREFIX [$prefix]"
echo " --libdir=DIR install libs in DIR [PREFIX/lib]"
echo " --incdir=DIR install includes in DIR [PREFIX/include/ffmpeg]"
@@ -107,9 +107,29 @@
log END $1
}
-die(){
+echolog(){
log "$@"
echo "$@"
+}
+
+die(){
+ echolog "$@"
+ cat <<EOF
+If you think configure made a mistake, make sure you are using the latest
+version from SVN. If the latest version fails, report the problem to the
+ffmpeg-devel at mplayerhq.hu mailing list or IRC #ffmpeg on irc.freenode.net.
+EOF
+ if enabled log; then
+ cat <<EOF
+Include the log file "$logfile" produced by configure as this will help
+solving the problem.
+EOF
+ else
+cat <<EOF
+Rerun configure with logging enabled (do not use --log=no), and include the
+log this produces with your report.
+EOF
+ fi
rm -f $TMPC $TMPO $TMPE $TMPS $TMPH
exit 1
}
@@ -278,8 +298,8 @@
TMPH="${TMPDIR1}/ffmpeg-conf-${RANDOM}-$$-${RANDOM}.h"
# default parameters
-log="no"
-logfile="/dev/null"
+log="yes"
+logfile="config.err"
prefix="/usr/local"
libdir=""
incdir=""
@@ -631,7 +651,9 @@
for opt do
case "$opt" in
- --log) log=yes
+ --log)
+ ;;
+ --log=*) log="${opt#*-}"
;;
--prefix=*) prefix=`echo $opt | cut -d '=' -f 2`; force_prefix=yes
;;
@@ -797,10 +819,12 @@
esac
done
-if enabled log; then
- logfile=config.err
+if test "$log" != no; then
+ test "$log" = yes || logfile="$log"
echo "# $0 $@" >$logfile
set >>$logfile
+else
+ logfile=/dev/null
fi
# Combine FFLDFLAGS and the LDFLAGS environment variable
More information about the ffmpeg-cvslog
mailing list