[alfs-log] r3976 - in jhalfs/trunk: . LFS common common/libs

pierre at higgs.linuxfromscratch.org pierre at higgs.linuxfromscratch.org
Tue Jul 4 05:19:46 PDT 2017


Author: pierre
Date: Tue Jul  4 05:19:46 2017
New Revision: 3976

Log:
Package management: compute times and sizes without packing times and sizes

Modified:
   jhalfs/trunk/Config.in
   jhalfs/trunk/LFS/lfs.xsl
   jhalfs/trunk/common/create-sbu_du-report.sh
   jhalfs/trunk/common/libs/func_wrt_Makefile

Modified: jhalfs/trunk/Config.in
==============================================================================
--- jhalfs/trunk/Config.in	Tue Jul  4 05:17:11 2017	(r3975)
+++ jhalfs/trunk/Config.in	Tue Jul  4 05:19:46 2017	(r3976)
@@ -1070,7 +1070,6 @@
 depends !BOOK_BLFS
 
     config    REPORT
-        depends !PKGMNGT
         bool "Create SBU and disk usage report"
         default y
 

Modified: jhalfs/trunk/LFS/lfs.xsl
==============================================================================
--- jhalfs/trunk/LFS/lfs.xsl	Tue Jul  4 05:17:11 2017	(r3975)
+++ jhalfs/trunk/LFS/lfs.xsl	Tue Jul  4 05:19:46 2017	(r3976)
@@ -259,7 +259,9 @@
 </xsl:text>
           </xsl:if>
           <xsl:text>'
+PREV_SEC=${SECONDS}
 packInstall
+SECONDS=${PREV_SEC}
 </xsl:text>
         </xsl:when>
         <xsl:otherwise>
@@ -297,7 +299,9 @@
 for dir in $PKG_DEST/{boot,etc,lib,bin,sbin}; do
   [[ -z $(ls $dir) ]] && rmdir -v $dir
 done
+PREV_SEC=${SECONDS}
 packInstall
+SECONDS=${PREV_SEC}
 rm -rf $PKG_DEST
 </xsl:text>
         </xsl:otherwise>
@@ -371,7 +375,9 @@
                             @role != 'nodump']/userinput[@remap != 'adjust']"
            mode="pkgmngt"/>
         <xsl:if test="$dirname = 'chapter06'">
-          <xsl:text>packInstall
+          <xsl:text>PREV_SEC=${SECONDS}
+packInstall
+SECONDS=${PREV_SEC}
 rm -rf "$PKG_DEST"
 </xsl:text>
         </xsl:if>
@@ -573,7 +579,9 @@
             <xsl:text>ZONEINFO=$PKG_DEST</xsl:text>
             <xsl:copy-of select="substring-after(string(),'ZONEINFO=')"/>
             <xsl:text>
+PREV_SEC=${SECONDS}
 packInstall
+SECONDS=${PREV_SEC}
 rm -rf $PKG_DEST
 </xsl:text>
           </xsl:when>
@@ -584,7 +592,9 @@
 ZONEINFO=</xsl:text>
             <xsl:copy-of select="substring-after(string(),'ZONEINFO=')"/>
             <xsl:text>'
+PREV_SEC=${SECONDS}
 packInstall
+SECONDS=${PREV_SEC}
 </xsl:text>
           </xsl:otherwise>
         </xsl:choose>

Modified: jhalfs/trunk/common/create-sbu_du-report.sh
==============================================================================
--- jhalfs/trunk/common/create-sbu_du-report.sh	Tue Jul  4 05:17:11 2017	(r3975)
+++ jhalfs/trunk/common/create-sbu_du-report.sh	Tue Jul  4 05:19:46 2017	(r3976)
@@ -121,7 +121,7 @@
 # For printing the last 'Installed files disk usage', we need to 'du' the
 # root dir, excluding the jhalfs directory (and lost+found). We assume
 # that the rootdir is $LOGSDIR/../..
-DU1=`du -skx --exclude=jhalfs --exclude=lost+found $LOGSDIR/../.. | cut -f1`
+DU1=`du -skx --exclude=jhalfs --exclude=lost+found --exclude /var/lib $LOGSDIR/../.. | cut -f1`
 DU1MB=`perl -e 'printf "%.3f" , ('$DU1' / '1024')';`
 INSTALL=`perl -e 'print ('$DU1' - '$DU1PREV')';`
 INSTALLMB=`perl -e 'printf "%.3f" , ('$DU1MB' - '$DU1MBPREV')';`

Modified: jhalfs/trunk/common/libs/func_wrt_Makefile
==============================================================================
--- jhalfs/trunk/common/libs/func_wrt_Makefile	Tue Jul  4 05:17:11 2017	(r3975)
+++ jhalfs/trunk/common/libs/func_wrt_Makefile	Tue Jul  4 05:19:46 2017	(r3976)
@@ -39,7 +39,7 @@
 SU_LUSER       = sudo -u \$(LUSER) -i sh -c
 LUSER_HOME     = \$(LHOME)/\$(LUSER)
 PRT_DU         = echo -e "\nKB: \`du -skx --exclude=\$(SCRIPT_ROOT) --exclude=lost+found \$(MOUNT_PT) \`\n"
-PRT_DU_CR      = echo -e "\nKB: \`du -skx --exclude=\$(SCRIPT_ROOT) --exclude=lost+found / \`\n"
+PRT_DU_CR      = echo -e "\nKB: \`du -skx --exclude=\$(SCRIPT_ROOT) --exclude=lost+found --exclude /var/lib / \`\n"
 
 ADD_REPORT       = $REPORT
 ADD_CUSTOM_TOOLS = $CUSTOM_TOOLS


More information about the alfs-log mailing list