POC for progress bar.

This commit is contained in:
Manuel Canales Esparcia 2006-05-31 20:43:41 +00:00
parent b7faa5a022
commit a858a7823c
6 changed files with 21 additions and 4 deletions

View file

@ -991,6 +991,7 @@ $HEADER
SRC= /sources
MOUNT_PT= $BUILDDIR
MAKE_PID=\`pidof make | cut -d " " -f1\`
include makefile-functions

View file

@ -478,6 +478,7 @@ $HEADER
SRC= /sources
MOUNT_PT= $BUILDDIR
MAKE_PID=\`pidof make | cut -d " " -f1\`
include makefile-functions

View file

@ -355,6 +355,7 @@ $HEADER
SRC= /sources
MOUNT_PT= $BUILDDIR
MAKE_PID=\`pidof make | cut -d " " -f1\`
include makefile-functions

View file

@ -201,6 +201,7 @@ cat << EOF
$i: $PREV
@\$(call echo_message, Building)
@./progress_bar.sh \$@ \$(MAKE_PID) &
@echo -e "\n\`date\`\n\nKB: \`du -skx --exclude=jhalfs \$(MOUNT_PT)\`\n" >logs/$LOGFILE
EOF
) >> $MKFILE.tmp

13
common/progress_bar.sh Executable file
View file

@ -0,0 +1,13 @@
#!/bin/bash
# $Id$
set -e
if [ ! -f $1 ] ; then
echo -n "."
sleep 1
if [ -d /proc/$2 ] ; then
./$0 $1 $2
fi
fi

View file

@ -481,7 +481,7 @@ fi
#
#
if [[ "$PWD" != "$JHALFSDIR" ]]; then
cp $COMMON_DIR/makefile-functions $JHALFSDIR/
cp $COMMON_DIR/{makefile-functions,progress_bar.sh} $JHALFSDIR/
[[ "$OPTIMIZE" != "0" ]] && cp optimize/opt_override $JHALFSDIR/
if [[ "$COMPARE" != "0" ]] ; then
mkdir -p $JHALFSDIR/extras