Expensive fuser in progress_bar.sh

M.Canales.es manuel at linuxfromscratch.org
Wed Jun 28 12:34:14 PDT 2006


El Miércoles, 28 de Junio de 2006 20:27, Dan Nicholson escribió:

> But, yes, there needs to be a less intrusive way.  I'm sure you guys
> will think of something. :) If I have any more bright ideas, I'll let
> you know. George's link looks promising.

I think that a combo of your patch plus the info on that link could to work, 
but will need a lot of code editions to can create targets like this one


028-binutils-pass1:  022-settingenvironment
 @$(call echo_message, Building) && touch $@.run
 @./progress_bar.sh $@ &
 @-echo -e "\n`date`\n\nKB: `du -skx --exclude=jhalfs $(MOUNT_PT)`\n" 
>logs/028-binutils-pass1 || rm $@.run && false
 @-PKG_PATH=`ls -t $(MOUNT_PT)$(SRC)/binutils-2.16.1.tar.bz2 | head -n1` && \
 ROOT=`tar -tf $$PKG_PATH | head -n1 | sed -e 's@^./@@;s@/.*@@'` && \
 [[ -n $$ROOT ]] && \
 rm -rf $(MOUNT_PT)$(SRC)/$$ROOT && \
 if [ -e $(MOUNT_PT)$(SRC)/binutils-build ]; then \
  rm -rf $(MOUNT_PT)$(SRC)/binutils-build; \
 fi; || rm $@.run && false
 @-$(call unpack,binutils-2.16.1.tar.bz2) || rm $@.run && false
 @-ROOT=`head -n1 $(MOUNT_PT)$(SRC)/$(PKG_LST) | sed 's@^./@@;s@/.*@@'` && \
 echo "export PKGDIR=$(MOUNT_PT)$(SRC)/$$ROOT" > envars && \
 chown -R lfs $(MOUNT_PT)$(SRC)/$$ROOT || rm $@.run && false
 @-( time { su - lfs -c "source /home/lfs/.bashrc 
&& /home/macana/test/jhalfs/lfs-commands/chapter05/028-binutils-pass1" 
>>logs/028-binutils-pass1 2>&1 ; } ) 2>>logs/028-binutils-pass1 && \
 echo -e "\nKB: `du -skx --exclude=jhalfs $(MOUNT_PT)`\n" 
>>logs/028-binutils-pass1 || rm $@.run && false
 @-ROOT=`head -n1 $(MOUNT_PT)$(SRC)/$(PKG_LST) | sed 's@^./@@;s@/.*@@'` && \
 rm -r $(MOUNT_PT)$(SRC)/$$ROOT && \
 if [ -e $(MOUNT_PT)$(SRC)/binutils-build ]; then \
  rm -r $(MOUNT_PT)$(SRC)/binutils-build; \
 fi; || rm $@.run && false
 @touch  $@ && rm $@.run && \
 sleep .25 && \
 echo -e "\n\n "$(BOLD)Target $(BLUE)$@ $(BOLD)OK && \
 echo 
--------------------------------------------------------------------------------$(WHITE)


-- 
Manuel Canales Esparcia
Usuario de LFS nº2886:       http://www.linuxfromscratch.org
LFS en castellano: http://www.escomposlinux.org/lfs-es http://www.lfs-es.info
TLDP-ES:                           http://es.tldp.org



More information about the alfs-discuss mailing list