Index: CLFS/clfs.xsl
===================================================================
--- CLFS/clfs.xsl	(revision 5be3651d7f7b42651c1dc9100c665ca90ed30a3a)
+++ CLFS/clfs.xsl	(revision 401f81e4da7d18f00f44b0bb93d4dbed3c8209b2)
@@ -29,11 +29,11 @@
 
   <!-- Bomb on test suites failures?
-       0 = no, I want to build the full system and review the logs
-       1 = yes, bomb at the first test suite failure to can review the build dir
+       n = no, I want to build the full system and review the logs
+       y = yes, bomb at the first test suite failure to can review the build dir
   -->
-  <xsl:param name="bomb-testsuite" select="0"/>
+  <xsl:param name="bomb-testsuite" select="n"/>
 
   <!-- Install vim-lang package? -->
-  <xsl:param name="vim-lang" select="1"/>
+  <xsl:param name="vim-lang" select="y"/>
 
   <!-- Time zone -->
@@ -103,5 +103,5 @@
             <xsl:if test="sect2[@role='installation']">
               <xsl:text>cd $PKGDIR&#xA;</xsl:text>
-              <xsl:if test="@id='ch-system-vim' and $vim-lang = '1'">
+              <xsl:if test="@id='ch-system-vim' and $vim-lang = 'y'">
                 <xsl:text>tar -xvf ../vim-&vim-version;-lang.* --strip-components=1&#xA;</xsl:text>
               </xsl:if>
@@ -126,5 +126,5 @@
             ($testsuite = '2' or $testsuite = '3')">
       <xsl:choose>
-        <xsl:when test="$bomb-testsuite = '0'">
+        <xsl:when test="$bomb-testsuite = 'n'">
           <xsl:value-of select="substring-before(string(),'make')"/>
           <xsl:text>make -k</xsl:text>
@@ -198,5 +198,5 @@
             <xsl:if test="contains(string(),'check')">
               <xsl:choose>
-                <xsl:when test="$bomb-testsuite = '0'">
+                <xsl:when test="$bomb-testsuite = 'n'">
                   <xsl:value-of select="substring-before(string(),'check')"/>
                   <xsl:text>-k check</xsl:text>
@@ -223,5 +223,5 @@
           <xsl:when test="$testsuite != '0'">
             <xsl:choose>
-              <xsl:when test="$bomb-testsuite = '0'">
+              <xsl:when test="$bomb-testsuite = 'n'">
                 <xsl:text>make -k check &gt;&gt; $TEST_LOG 2&gt;&amp;1 || true&#xA;</xsl:text>
               </xsl:when>
@@ -243,5 +243,5 @@
             <xsl:value-of select="substring-before(string(),'&gt;g')"/>
             <xsl:choose>
-              <xsl:when test="$bomb-testsuite = '0'">
+              <xsl:when test="$bomb-testsuite = 'n'">
                 <xsl:text>&gt;&gt; $TEST_LOG 2&gt;&amp;1 || true&#xA;</xsl:text>
               </xsl:when>
Index: CLFS/config
===================================================================
--- CLFS/config	(revision 5be3651d7f7b42651c1dc9100c665ca90ed30a3a)
+++ CLFS/config	(revision 401f81e4da7d18f00f44b0bb93d4dbed3c8209b2)
@@ -55,6 +55,6 @@
 
 # Get the kernel package and patches even if no configutation file
-# has been supplied? 0(no)/1(yes)
-GETKERNEL=0
+# has been supplied? n(no)/y(yes)
+GETKERNEL=n
 
 #--- Book's sources directory
Index: CLFS/master.sh
===================================================================
--- CLFS/master.sh	(revision 5be3651d7f7b42651c1dc9100c665ca90ed30a3a)
+++ CLFS/master.sh	(revision 401f81e4da7d18f00f44b0bb93d4dbed3c8209b2)
@@ -5,5 +5,4 @@
 ###          FUNCTIONS          ###
 ###################################
-
 
 
@@ -499,5 +498,5 @@
     # Skip alsp temp-perl for iterative runs
     case $this_script in
-      *stripping*) [[ "$STRIP" = "0" ]] && continue ;;
+      *stripping*) [[ "$STRIP" = "n" ]] && continue ;;
       *temp-perl*) [[ -n "$N" ]] && continue ;;
     esac
@@ -609,5 +608,5 @@
     # Skip alsp temp-perl for iterative runs
     case $this_script in
-      *stripping*) [[ "$STRIP" = "0" ]] && continue ;;
+      *stripping*) [[ "$STRIP" = "n" ]] && continue ;;
       *temp-perl*) [[ -n "$N" ]] && continue ;;
     esac
@@ -884,5 +883,5 @@
 
   # Add SBU-disk_usage report target if required
-  if [[ "$REPORT" = "1" ]] ; then wrt_report ; fi
+  if [[ "$REPORT" = "y" ]] ; then wrt_report ; fi
 
 }
@@ -963,5 +962,5 @@
 
   # Add SBU-disk_usage report target if required
-  if [[ "$REPORT" = "1" ]] ; then wrt_report ; fi
+  if [[ "$REPORT" = "y" ]] ; then wrt_report ; fi
 
 }
@@ -987,5 +986,5 @@
     final_system_Makefiles         # $basicsystem
     # Add the iterations targets, if needed
-    [[ "$COMPARE" != "0" ]] && wrt_compare_targets
+    [[ "$COMPARE" = "y" ]] && wrt_compare_targets
     bootscripts_Makefiles          # $bootscripttools
     bootable_Makefiles             # $bootabletools
@@ -997,5 +996,5 @@
     bm_final_system_Makefiles      # $basicsystem
     # Add the iterations targets, if needed
-    [[ "$COMPARE" != "0" ]] && wrt_compare_targets
+    [[ "$COMPARE" = "y" ]] && wrt_compare_targets
     bm_bootscripts_Makefiles       # $bootscipttools
     bm_bootable_Makefiles          # $bootabletoosl
@@ -1010,9 +1009,27 @@
 $HEADER
 
-SRC= /sources
-MOUNT_PT= $BUILDDIR
-PKG_LST= $PKG_LST
-LUSER= $LUSER
-LGROUP= $LGROUP
+SRC          = /sources
+MOUNT_PT     = $BUILDDIR
+PKG_LST      = $PKG_LST
+LUSER        = $LUSER
+LGROUP       = $LGROUP
+SCRIPT_ROOT  = $SCRIPT_ROOT
+
+BASEDIR      = \$(MOUNT_PT)
+SRCSDIR      = \$(BASEDIR)/sources
+CMDSDIR      = \$(BASEDIR)/\$(SCRIPT_ROOT)/$PROGNAME-commands
+LOGDIR       = \$(BASEDIR)/\$(SCRIPT_ROOT)/logs
+TESTLOGDIR   = \$(BASEDIR)/\$(SCRIPT_ROOT)/test-logs
+
+crSRCSDIR    = /sources
+crCMDSDIR    = /\$(SCRIPT_ROOT)/$PROGNAME-commands
+crLOGDIR     = /\$(SCRIPT_ROOT)/logs
+crTESTLOGDIR = /\$(SCRIPT_ROOT)/test-logs
+
+SU_LUSER     = su - \$(LUSER) -c
+LUSER_HOME   = /home/\$(LUSER)
+PRT_DU       = echo -e "\nKB: \`du -skx --exclude=jhalfs \$(MOUNT_PT)\`\n"
+PRT_DU_CR    = echo -e "\nKB: \`du -skx --exclude=\$(SCRIPT_ROOT) \$(MOUNT_PT)\`\n"
+
 
 include makefile-functions
Index: CLFS2/clfs2.xsl
===================================================================
--- CLFS2/clfs2.xsl	(revision 5be3651d7f7b42651c1dc9100c665ca90ed30a3a)
+++ CLFS2/clfs2.xsl	(revision 401f81e4da7d18f00f44b0bb93d4dbed3c8209b2)
@@ -18,5 +18,5 @@
 
   <!-- Install vim-lang package? -->
-  <xsl:param name="vim-lang" select="1"/>
+  <xsl:param name="vim-lang" select="y"/>
 
   <!-- Time zone -->
@@ -76,5 +76,5 @@
             <xsl:if test="sect2[@role='installation']">
               <xsl:text>cd $PKGDIR&#xA;</xsl:text>
-              <xsl:if test="@id='ch-system-vim' and $vim-lang = '1'">
+              <xsl:if test="@id='ch-system-vim' and $vim-lang = 'y'">
                 <xsl:text>tar -xvf ../vim-&vim-version;-lang.* --strip-components=1&#xA;</xsl:text>
               </xsl:if>
Index: CLFS2/config
===================================================================
--- CLFS2/config	(revision 5be3651d7f7b42651c1dc9100c665ca90ed30a3a)
+++ CLFS2/config	(revision 401f81e4da7d18f00f44b0bb93d4dbed3c8209b2)
@@ -34,6 +34,6 @@
 
 # Get the kernel package and patches even if no configutation file
-# has been supplied? 0(no)/1(yes)
-GETKERNEL=0
+# has been supplied? n(no)/y(yes)
+GETKERNEL=n
 
 #--- Book's sources directory
Index: CLFS2/master.sh
===================================================================
--- CLFS2/master.sh	(revision 5be3651d7f7b42651c1dc9100c665ca90ed30a3a)
+++ CLFS2/master.sh	(revision 401f81e4da7d18f00f44b0bb93d4dbed3c8209b2)
@@ -216,5 +216,5 @@
     # Skip alsp temp-perl for iterative runs
     case $this_script in
-      *stripping*) [[ "$STRIP" = "0" ]] && continue ;;
+      *stripping*) [[ "$STRIP" = "n" ]] && continue ;;
     esac
 
@@ -404,5 +404,5 @@
 
   # Add SBU-disk_usage report target if required
-  if [[ "$REPORT" = "1" ]] ; then wrt_report ; fi
+  if [[ "$REPORT" = "y" ]] ; then wrt_report ; fi
 
 }
@@ -430,9 +430,20 @@
 $HEADER
 
-SRC= /sources
-MOUNT_PT= $BUILDDIR
-PKG_LST= $PKG_LST
-LUSER= $LUSER
-LGROUP= $LGROUP
+SRC         = /sources
+MOUNT_PT    = $BUILDDIR
+PKG_LST     = $PKG_LST
+LUSER       = $LUSER
+LGROUP      = $LGROUP
+SCRIPT_ROOT = $SCRIPT_ROOT
+
+BASEDIR    = \$(MOUNT_PT)
+SRCSDIR    = \$(BASEDIR)/sources
+CMDSDIR    = \$(BASEDIR)/\$(SCRIPT_ROOT)/$PROGNAME-commands
+LOGDIR     = \$(BASEDIR)/\$(SCRIPT_ROOT)/logs
+TESTLOGDIR = \$(BASEDIR)/\$(SCRIPT_ROOT)/test-logs
+
+SU_LUSER   = su - \$(LUSER) -c
+PRT_DU     = echo -e "\nKB: \`du -skx --exclude=jhalfs \$(MOUNT_PT)\`\n"
+LUSER_HOME = /home/\$(LUSER)
 
 include makefile-functions
Index: Config.in
===================================================================
--- Config.in	(revision 5be3651d7f7b42651c1dc9100c665ca90ed30a3a)
+++ Config.in	(revision 401f81e4da7d18f00f44b0bb93d4dbed3c8209b2)
@@ -59,5 +59,5 @@
 
 	config	BRANCH_ID
-		string	"Branch (mandatory)"
+		string	"Book Version (mandatory)"
 		default	"**EDIT ME**"
 		depends	BRANCH
@@ -251,5 +251,5 @@
 
 	#--- HLFS specific params
-	config	CONFIG_GRSECURITY_HOST
+	config	GRSECURITY_HOST
 		bool	"Building on grsecurity enabled host?"
 		default	n
@@ -357,5 +357,5 @@
 			#-- The directory where the created system will be located.
 
-	config	CONFIG_GETPKG
+	config	GETPKG
 		bool "Retrieve source files"
 		default n
@@ -369,5 +369,5 @@
 		string "Package Archive Directory"
 		default "$SRC_ARCHIVE"
-		depends CONFIG_GETPKG
+		depends GETPKG
 		help
 			#-- A local archive for packages/file (not $BUILDDIR/sources)
@@ -376,13 +376,13 @@
 			#   if the user has the right priviledges.
 
-	config	CONFIG_GETKERNEL
+	config	GETKERNEL
 		bool	"Always retrieve kernel package"
 		default	n
-		depends CONFIG_GETPKG
+		depends GETPKG
 		help
 			#-- Get the kernel package and patches even if no configuration
 			#   file has been supplied.
 
-	config	CONFIG_RUNMAKE
+	config	RUNMAKE
 		bool	"Run the makefile"
 		default n
@@ -390,5 +390,5 @@
 			#-- Automatically run the makefile once it has been created
 
-	config	CONFIG_REBUILD
+	config	CLEAN
 		bool	"Rebuild files"
 		default	n
@@ -410,5 +410,5 @@
 		bool	"Run testsuites"
 		depends	!BOOK_CLFS2
-		default	n
+		default	y
 		help
 			#-- Run test suites
@@ -455,17 +455,18 @@
 		prompt	"Flavour ->"
 		depends	CONFIG_TESTS
-		default	NO_BOMB
 
 		config	NO_BOMB
 			bool	"Don't stop on test suite failures"
+			default n
 
 		config	BOMB
 			bool	"Abort the build at the first test suite failure"
+			default n
 	endchoice
 
 	config	BOMB_TEST
-		int
-		default	"0"	if NO_BOMB
-		default	"1"	if BOMB
+		bool
+		default	BOMB
+
 	#--- End Test Suites
 
@@ -516,13 +517,13 @@
 	#--- End Kernel
 
-	config	CONFIG_STRIP
+	config	STRIP
 		bool "Strip Installed Binaries/Libraries"
 		default y
 
-	config	CONFIG_VIMLANG
+	config	VIMLANG
 		bool "Install vim-lang package"
 		default y
 		help
-			#-- install the optional vim-lang package
+			#-- Install the optional vim-lang package
 
 	config	TIMEZONE
@@ -572,10 +573,10 @@
 	depends on !BOOK_BLFS
 
-	config	CONFIG_REPORT
+	config	REPORT
 		bool "Create SBU and disk usage report"
 		default y
 
 	#--- ICA/farce
-	config	CONFIG_COMPARE
+	config	COMPARE
 		bool "Run comparison analysis on final stage"
 		depends	!BOOK_CLFS2
@@ -597,19 +598,19 @@
 
 	config	ITERATIONS
-		int	"Number of test runs (2,3,4,5)"
-		depends on CONFIG_COMPARE
+		int	"Number of test runs (2,3,4,5)"	if COMPARE
+		depends on COMPARE
 		range	2 5
 		default	3
 
-	config	CONFIG_ICA
+	config	RUN_ICA
 		bool	"ICA testing"
-		depends on CONFIG_COMPARE
+		depends on COMPARE
 		default y
 		help
 			#-- Run ICA testing
 
-	config	CONFIG_FARCE
+	config	RUN_FARCE
 		bool	"farce testing"
-		depends on CONFIG_COMPARE
+		depends on COMPARE
 		default n
 		help
@@ -668,60 +669,2 @@
 #		default	"none"
 #		depends	CONFIG_BLFS_CMDS
-
-
-# convert CONFIG_XXXX n/y to XXXX 0/1
-
-	config	GRSECURITY_HOST
-		int
-		default 0	if !CONFIG_GRSECURITY_HOST
-		default 1	if  CONFIG_GRSECURITY_HOST
-
-	config	COMPARE
-		int
-		default 0	if !CONFIG_COMPARE
-		default 1	if  CONFIG_COMPARE
-
-	config	GETPKG
-		int
-		default 0	if !CONFIG_GETPKG
-		default 1	if  CONFIG_GETPKG
-
-	config	GETKERNEL
-		int
-		default	0	if !CONFIG_GETKERNEL
-		default	1	if  CONFIG_GETKERNEL
-
-	config	RUNMAKE
-		int
-		default	0	if !CONFIG_RUNMAKE
-		default 1	if  CONFIG_RUNMAKE
-
-	config	STRIP
-		int
-		default	0	if !CONFIG_STRIP
-		default	1	if  CONFIG_STRIP
-
-	config	REPORT
-		int
-		default	0	if !CONFIG_REPORT
-		default 1	if  CONFIG_REPORT
-
-	config	VIMLANG
-		int
-		default	0	if !CONFIG_VIMLANG
-		default	1	if  CONFIG_VIMLANG
-
-	config	RUN_ICA
-		int
-		default	0	if !CONFIG_ICA
-		default	1	if  CONFIG_ICA
-
-	config	RUN_FARCE
-		int
-		default	0	if !CONFIG_FARCE
-		default	1	if  CONFIG_FARCE
-
-	config	CLEAN
-		int
-		default	0	if !CONFIG_REBUILD
-		default	1	if  CONFIG_REBUILD
Index: HLFS/config
===================================================================
--- HLFS/config	(revision 5be3651d7f7b42651c1dc9100c665ca90ed30a3a)
+++ HLFS/config	(revision 401f81e4da7d18f00f44b0bb93d4dbed3c8209b2)
@@ -10,6 +10,6 @@
 MODEL=glibc
 
-#--- The host system has grsecurity options enabled? 0(no)/1(yes)
-GRSECURITY_HOST=0
+#--- The host system has grsecurity options enabled? n(no)/y(yes)
+GRSECURITY_HOST=n
 
 #--- Unprivileged user and group name
@@ -25,6 +25,6 @@
 
 # Get the kernel package and patches even if no configutation file
-# has been supplied? 0(no)/1(yes)
-GETKERNEL=0
+# has been supplied? n(no)/y(yes)
+GETKERNEL=n
 
 #--- Book's sources directory
Index: HLFS/hlfs.xsl
===================================================================
--- HLFS/hlfs.xsl	(revision 5be3651d7f7b42651c1dc9100c665ca90ed30a3a)
+++ HLFS/hlfs.xsl	(revision 401f81e4da7d18f00f44b0bb93d4dbed3c8209b2)
@@ -18,5 +18,5 @@
 
   <!-- Is the host kernel using grsecurity? -->
-  <xsl:param name="grsecurity_host" select="0"/>
+  <xsl:param name="grsecurity_host" select="n"/>
 
   <!-- Compile the keymap into the kernel? -->
@@ -32,8 +32,8 @@
 
   <!-- Bomb on test suites failures?
-       0 = no, I want to build the full system and review the logs
-       1 = yes, bomb at the first test suite failure to can review the build dir
+       n = no, I want to build the full system and review the logs
+       y = yes, bomb at the first test suite failure to can review the build dir
   -->
-  <xsl:param name="bomb-testsuite" select="0"/>
+  <xsl:param name="bomb-testsuite" select="n"/>
 
   <!-- Time zone -->
@@ -144,5 +144,5 @@
                   ($testsuite = '2' or $testsuite = '3')">
       <xsl:choose>
-        <xsl:when test="$bomb-testsuite = '0'">
+        <xsl:when test="$bomb-testsuite = 'n'">
           <xsl:value-of select="substring-before(string(),'make')"/>
           <xsl:text>make -k</xsl:text>
@@ -181,5 +181,5 @@
       <xsl:when test="ancestor::sect1[@id='ch-system-kernfs'] and
                 contains(string(),'sysctl')
-                and $grsecurity_host ='0'"/>
+                and $grsecurity_host ='n'"/>
       <!-- Setting $LC_ALL and $LANG for /etc/profile -->
       <xsl:when test="ancestor::sect1[@id='bootable-profile'] and
@@ -231,5 +231,5 @@
             <xsl:if test="contains(string(),'check')">
               <xsl:choose>
-                <xsl:when test="$bomb-testsuite = '0'">
+                <xsl:when test="$bomb-testsuite = 'n'">
                   <xsl:value-of select="substring-before(string(),'check')"/>
                   <xsl:text>-k check</xsl:text>
@@ -256,5 +256,5 @@
             <xsl:apply-templates/>
             <xsl:choose>
-              <xsl:when test="$bomb-testsuite = '0'">
+              <xsl:when test="$bomb-testsuite = 'n'">
                 <xsl:text> &gt;&gt; $TEST_LOG 2&gt;&amp;1 || true&#xA;</xsl:text>
               </xsl:when>
@@ -276,5 +276,5 @@
             <xsl:value-of select="substring-before(string(),'&gt; glibc-')"/>
             <xsl:choose>
-              <xsl:when test="$bomb-testsuite = '0'">
+              <xsl:when test="$bomb-testsuite = 'n'">
                 <xsl:text> &gt;&gt; $TEST_LOG 2&gt;&amp;1 || true&#xA;</xsl:text>
               </xsl:when>
Index: HLFS/master.sh
===================================================================
--- HLFS/master.sh	(revision 5be3651d7f7b42651c1dc9100c665ca90ed30a3a)
+++ HLFS/master.sh	(revision 401f81e4da7d18f00f44b0bb93d4dbed3c8209b2)
@@ -14,13 +14,20 @@
   local this_script=$2
   local  tc_phase
-
+  local binutil_tarball
+  local gcc_core_tarball
+  
   echo "${tab_}${tab_}${GREEN}toolchain ${L_arrow}${toolchain}${R_arrow}"
 
   #
   # Safe method to remove existing toolchain dirs
-  pkg_tarball=$(get_package_tarball_name "binutils")
-  wrt_remove_existing_dirs  "$pkg_tarball"
-  pkg_tarball=$(get_package_tarball_name "gcc-core")
-  wrt_remove_existing_dirs  "$pkg_tarball"
+  binutil_tarball=$(get_package_tarball_name "binutils")
+  gcc_core_tarball=$(get_package_tarball_name "gcc-core")
+(
+cat << EOF
+	@\$(call remove_existing_dirs,$binutil_tarball)
+	@\$(call remove_existing_dirs,$gcc_core_tarball)
+EOF
+) >> $MKFILE.tmp
+
   #
   # Manually remove the toolchain directories..
@@ -54,9 +61,11 @@
   esac
   #
-  # Safe method to remove packages unpacked while inside the toolchain script
-  pkg_tarball=$(get_package_tarball_name "binutils")
-  wrt_remove_existing_dirs  "$pkg_tarball"
-  pkg_tarball=$(get_package_tarball_name "gcc-core")
-  wrt_remove_existing_dirs  "$pkg_tarball"
+(
+cat << EOF
+	@\$(call remove_existing_dirs,$binutil_tarball)
+	@\$(call remove_existing_dirs,$gcc_core_tarball)
+EOF
+) >> $MKFILE.tmp
+
   #
   # Manually remove the toolchain directories..
@@ -167,5 +176,5 @@
       *introduction* ) continue ;;
         # Test if the stripping phase must be skipped
-      *stripping* ) [[ "$STRIP" = "0" ]] && continue ;;
+      *stripping* ) [[ "$STRIP" = "n" ]] && continue ;;
       *) ;;
     esac
@@ -279,5 +288,5 @@
       *chroot* )  continue ;;
         # Test if the stripping phase must be skipped
-      *-stripping* )  [[ "$STRIP" = "0" ]] && continue ;;
+      *-stripping* )  [[ "$STRIP" = "n" ]] && continue ;;
     esac
 
@@ -457,5 +466,5 @@
 
   # Add SBU-disk_usage report target if required
-  if [[ "$REPORT" = "1" ]] ; then wrt_report ; fi
+  if [[ "$REPORT" = "y" ]] ; then wrt_report ; fi
 }
 
@@ -474,5 +483,5 @@
   chapter6_Makefiles
   # Add the iterations targets, if needed
-  [[ "$COMPARE" != "0" ]] && wrt_compare_targets
+  [[ "$COMPARE" = "y" ]] && wrt_compare_targets
   chapter7_Makefiles
 
@@ -483,9 +492,26 @@
 $HEADER
 
-SRC= /sources
-MOUNT_PT= $BUILDDIR
-PKG_LST= $PKG_LST
-LUSER= $LUSER
-LGROUP= $LGROUP
+SRC          = /sources
+MOUNT_PT     = $BUILDDIR
+PKG_LST      = $PKG_LST
+LUSER        = $LUSER
+LGROUP       = $LGROUP
+SCRIPT_ROOT  = $SCRIPT_ROOT
+
+BASEDIR      = \$(MOUNT_PT)
+SRCSDIR      = \$(BASEDIR)/sources
+CMDSDIR      = \$(BASEDIR)/\$(SCRIPT_ROOT)/$PROGNAME-commands
+LOGDIR       = \$(BASEDIR)/\$(SCRIPT_ROOT)/logs
+TESTLOGDIR   = \$(BASEDIR)/\$(SCRIPT_ROOT)/test-logs
+
+crSRCSDIR    = /sources
+crCMDSDIR    = /\$(SCRIPT_ROOT)/$PROGNAME-commands
+crLOGDIR     = /\$(SCRIPT_ROOT)/logs
+crTESTLOGDIR = /\$(SCRIPT_ROOT)/test-logs
+
+SU_LUSER     = su - \$(LUSER) -c
+LUSER_HOME   = /home/\$(LUSER)
+PRT_DU       = echo -e "\nKB: \`du -skx --exclude=jhalfs \$(MOUNT_PT)\`\n"
+PRT_DU_CR    = echo -e "\nKB: \`du -skx --exclude=\$(SCRIPT_ROOT) \$(MOUNT_PT)\`\n"
 
 include makefile-functions
Index: LFS/config
===================================================================
--- LFS/config	(revision 5be3651d7f7b42651c1dc9100c665ca90ed30a3a)
+++ LFS/config	(revision 401f81e4da7d18f00f44b0bb93d4dbed3c8209b2)
@@ -19,6 +19,6 @@
 
 # Get the kernel package and patches even if no configuration file
-# has been supplied? 0(no)/1(yes)
-GETKERNEL=0
+# has been supplied? n(no)/y(yes)
+GETKERNEL=n
 
 #--- Book's sources directory
Index: LFS/lfs.xsl
===================================================================
--- LFS/lfs.xsl	(revision 5be3651d7f7b42651c1dc9100c665ca90ed30a3a)
+++ LFS/lfs.xsl	(revision 401f81e4da7d18f00f44b0bb93d4dbed3c8209b2)
@@ -23,11 +23,11 @@
 
   <!-- Bomb on test suites failures?
-       0 = no, I want to build the full system and review the logs
-       1 = yes, bomb at the first test suite failure to can review the build dir
+       n = no, I want to build the full system and review the logs
+       y = yes, bomb at the first test suite failure to can review the build dir
   -->
-  <xsl:param name="bomb-testsuite" select="0"/>
+  <xsl:param name="bomb-testsuite" select="n"/>
 
   <!-- Install vim-lang package? -->
-  <xsl:param name="vim-lang" select="1"/>
+  <xsl:param name="vim-lang" select="y"/>
 
   <!-- Time zone -->
@@ -91,5 +91,5 @@
         <xsl:if test="sect2[@role='installation']">
           <xsl:text>cd $PKGDIR&#xA;</xsl:text>
-          <xsl:if test="@id='ch-system-vim' and $vim-lang = '1'">
+          <xsl:if test="@id='ch-system-vim' and $vim-lang = 'y'">
             <xsl:text>tar -xvf ../vim-&vim-version;-lang.* --strip-components=1&#xA;</xsl:text>
           </xsl:if>
@@ -118,5 +118,5 @@
             $testsuite = '3')">
       <xsl:choose>
-        <xsl:when test="$bomb-testsuite = '0'">
+        <xsl:when test="$bomb-testsuite = 'n'">
           <xsl:value-of select="substring-before(string(),'make')"/>
           <xsl:text>make -k</xsl:text>
@@ -186,5 +186,5 @@
             <xsl:if test="contains(string(),'check')">
               <xsl:choose>
-                <xsl:when test="$bomb-testsuite = '0'">
+                <xsl:when test="$bomb-testsuite = 'n'">
                   <xsl:value-of select="substring-before(string(),'check')"/>
                   <xsl:text>-k check</xsl:text>
@@ -213,5 +213,5 @@
                     $testsuite = '3'">
             <xsl:choose>
-              <xsl:when test="$bomb-testsuite = '0'">
+              <xsl:when test="$bomb-testsuite = 'n'">
                 <xsl:text>make -k check &gt;&gt; $TEST_LOG 2&gt;&amp;1 || true&#xA;</xsl:text>
               </xsl:when>
Index: LFS/master.sh
===================================================================
--- LFS/master.sh	(revision 5be3651d7f7b42651c1dc9100c665ca90ed30a3a)
+++ LFS/master.sh	(revision 401f81e4da7d18f00f44b0bb93d4dbed3c8209b2)
@@ -6,5 +6,4 @@
 ###	    FUNCTIONS		###
 ###################################
-
 
 
@@ -81,5 +80,5 @@
       *expect)    [[ "${TEST}" = "0" ]] && continue ;;
       *dejagnu)   [[ "${TEST}" = "0" ]] && continue ;;
-      *stripping) [[ "${STRIP}" = "0" ]] && continue ;;
+      *stripping) [[ "${STRIP}" = "n" ]] && continue ;;
       *glibc)     [[ "${TEST}" = "3" ]] && \
                   sed -i 's@/usr/lib/locale@/tools/lib/locale@' $file ;;
@@ -178,5 +177,5 @@
     case "${this_script}" in
       *chroot)      continue ;;
-      *stripping*) [[ "${STRIP}" = "0" ]] && continue ;;
+      *stripping*) [[ "${STRIP}" = "n" ]] && continue ;;
     esac
 
@@ -336,5 +335,5 @@
 
   # Add SBU-disk_usage report target if required
-  if [[ "$REPORT" = "1" ]] ; then wrt_report ; fi
+  if [[ "$REPORT" = "y" ]] ; then wrt_report ; fi
 }
 
@@ -353,5 +352,5 @@
   chapter6_Makefiles
   # Add the iterations targets, if needed
-  [[ "$COMPARE" != "0" ]] && wrt_compare_targets
+  [[ "$COMPARE" = "y" ]] && wrt_compare_targets
   chapter789_Makefiles
 
@@ -363,9 +362,27 @@
 $HEADER
 
-SRC= /sources
-MOUNT_PT= $BUILDDIR
-PKG_LST= $PKG_LST
-LUSER= $LUSER
-LGROUP= $LGROUP
+SRC          = /sources
+MOUNT_PT     = $BUILDDIR
+PKG_LST      = $PKG_LST
+LUSER        = $LUSER
+LGROUP       = $LGROUP
+SCRIPT_ROOT  = $SCRIPT_ROOT
+
+BASEDIR      = \$(MOUNT_PT)
+SRCSDIR      = \$(BASEDIR)/sources
+CMDSDIR      = \$(BASEDIR)/\$(SCRIPT_ROOT)/$PROGNAME-commands
+LOGDIR       = \$(BASEDIR)/\$(SCRIPT_ROOT)/logs
+TESTLOGDIR   = \$(BASEDIR)/\$(SCRIPT_ROOT)/test-logs
+
+crSRCSDIR    = /sources
+crCMDSDIR    = /\$(SCRIPT_ROOT)/$PROGNAME-commands
+crLOGDIR     = /\$(SCRIPT_ROOT)/logs
+crTESTLOGDIR = /\$(SCRIPT_ROOT)/test-logs
+
+SU_LUSER     = su - \$(LUSER) -c
+LUSER_HOME   = /home/\$(LUSER)
+PRT_DU       = echo -e "\nKB: \`du -skx --exclude=jhalfs \$(MOUNT_PT)\`\n"
+PRT_DU_CR    = echo -e "\nKB: \`du -skx --exclude=\$(SCRIPT_ROOT) \$(MOUNT_PT)\`\n"
+
 
 include makefile-functions
Index: Makefile
===================================================================
--- Makefile	(revision 5be3651d7f7b42651c1dc9100c665ca90ed30a3a)
+++ Makefile	(revision 401f81e4da7d18f00f44b0bb93d4dbed3c8209b2)
@@ -8,4 +8,5 @@
 
 all: menuconfig
+	@clear
 	@touch using_menuconfig
 	@`grep RUN_ME configuration | sed -e 's@RUN_ME=\"@@' -e 's@\"@@' ` || rm -f using_menuconfig
Index: common/common-functions
===================================================================
--- common/common-functions	(revision 5be3651d7f7b42651c1dc9100c665ca90ed30a3a)
+++ common/common-functions	(revision 401f81e4da7d18f00f44b0bb93d4dbed3c8209b2)
@@ -261,96 +261,4 @@
 }
 
-#----------------------------------#
-wrt_remove_existing_dirs() {       #
-#----------------------------------#
-  local PKG_NAME=$1
-(
-cat << EOF
-	@PKG_PATH=\`ls -t \$(MOUNT_PT)\$(SRC)/${PKG_NAME} | 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)/${PKG_NAME%-*}-build ]; then \\
-		rm -rf \$(MOUNT_PT)\$(SRC)/${PKG_NAME%-*}-build; \\
-	fi;
-EOF
-) >> $MKFILE.tmp
-}
-
-#----------------------------------#
-wrt_remove_existing_dirs2() {      #
-#----------------------------------#
-  local PKG_NAME=$1
-(
-cat << EOF
-	@PKG_PATH=\`ls -t \$(SRC)/${PKG_NAME} | head -n1\` && \\
-	ROOT=\`tar -tf \$\$PKG_PATH | head -n1 | sed -e 's@^./@@;s@/.*@@'\` && \\
-	[[ -n \$\$ROOT ]] && \\
-	rm -rf \$(SRC)/\$\$ROOT && \\
-	if [ -e \$(SRC)/${PKG_NAME%-*}-build ]; then \\
-		rm -rf \$(SRC)/${PKG_NAME%-*}-build; \\
-	fi;
-EOF
-) >> $MKFILE.tmp
-}
-
-
-
-#----------------------------------#
-wrt_unpack() {                     # Unpack and set 'ROOT' var
-#----------------------------------#
-  local FILE=$1
-  local optSAVE_PREVIOUS=$2
-
-  if [ "${optSAVE_PREVIOUS}" != "1" ]; then
-    wrt_remove_existing_dirs "$FILE"
-  fi
-(
-cat << EOF
-	@\$(call unpack,$FILE)
-	@ROOT=\`head -n1 \$(MOUNT_PT)\$(SRC)/\$(PKG_LST) | sed 's@^./@@;s@/.*@@'\` && \\
-	echo "export PKGDIR=\$(MOUNT_PT)\$(SRC)/\$\$ROOT" > envars && \\
-	chown -R \$(LUSER) \$(MOUNT_PT)\$(SRC)/\$\$ROOT
-EOF
-) >> $MKFILE.tmp
-}
-
-
-#----------------------------------#
-wrt_unpack2() {                    #
-#----------------------------------#
-  local FILE=$1
-  local optSAVE_PREVIOUS=$2
-
-  if [ "${optSAVE_PREVIOUS}" != "1" ]; then
-    wrt_remove_existing_dirs "$FILE"
-  fi
-(
-cat  << EOF
-	@\$(call unpack2,$FILE)
-	@ROOT=\`head -n1 \$(MOUNT_PT)\$(SRC)/\$(PKG_LST) | sed 's@^./@@;s@/.*@@'\` && \\
-	echo "export PKGDIR=\$(SRC)/\$\$ROOT" > envars
-EOF
-) >> $MKFILE.tmp
-}
-
-
-#----------------------------------#
-wrt_unpack3() {                    #
-#----------------------------------#
-  local FILE=$1
-  local optSAVE_PREVIOUS=$2
-
-  if [ "${optSAVE_PREVIOUS}" != "1" ]; then
-    wrt_remove_existing_dirs2 "$FILE"
-  fi
-(
-cat  << EOF
-	@\$(call unpack3,$FILE)
-	@ROOT=\`head -n1 \$(SRC)/\$(PKG_LST) | sed 's@^./@@;s@/.*@@'\` && \\
-	echo "export PKGDIR=\$(SRC)/\$\$ROOT" > envars
-EOF
-) >> $MKFILE.tmp
-}
 
 #----------------------------------#
@@ -392,12 +300,159 @@
 
 #----------------------------------#
+wrt_copy_fstab() {                 #
+#----------------------------------#
+  local i=$1
+(
+    cat << EOF
+	@cp -v $FSTAB \$(MOUNT_PT)/etc/fstab >>logs/$i 2>&1
+EOF
+) >> $MKFILE.tmp
+}
+
+
+#----------------------------------#
+wrt_copy_fstab2() {                #
+#----------------------------------#
+  local i=$1
+(
+    cat << EOF
+	@cp -v /sources/fstab /etc/fstab >>logs/$i 2>&1
+EOF
+) >> $MKFILE.tmp
+}
+
+
+#----------------------------------#
+wrt_report() {                     #
+#----------------------------------#
+(
+cat << EOF
+
+create-sbu_du-report:  $PREV
+	@\$(call echo_message, Building)
+	@./create-sbu_du-report.sh logs $VERSION
+	@\$(call echo_report,$VERSION-SBU_DU-$(date --iso-8601).report)
+	@touch  \$@
+EOF
+) >> $MKFILE.tmp
+
+chapter789="$chapter789 create-sbu_du-report"
+}
+
+unset wrt_unpack
+#----------------------------------#
+wrt_unpack() {                     # Unpack and set 'ROOT' var
+#----------------------------------#
+  local FILE=$1
+  local optSAVE_PREVIOUS=$2
+
+  if [[ "${optSAVE_PREVIOUS}" != "1" ]]; then
+(
+cat << EOF
+	@\$(call remove_existing_dirs,$FILE)
+EOF
+) >> $MKFILE.tmp
+  fi
+
+(
+cat << EOF
+	@\$(call unpack,$FILE)
+	@\$(call get_pkg_root)
+EOF
+) >> $MKFILE.tmp
+
+}
+
+unset wrt_unpack2
+#----------------------------------#
+wrt_unpack2() {                    #
+#----------------------------------#
+  local FILE=$1
+  local optSAVE_PREVIOUS=$2
+
+  if [ "${optSAVE_PREVIOUS}" != "1" ]; then
+(
+cat << EOF
+	@\$(call remove_existing_dirs,$FILE)
+EOF
+) >> $MKFILE.tmp
+  fi
+(
+cat  << EOF
+	@\$(call unpack2,$FILE)
+	@\$(call get_pkg_root,nouser)
+EOF
+) >> $MKFILE.tmp
+}
+
+#----------------------------------#
+wrt_unpack3() {                    #
+#----------------------------------#
+  local FILE=$1
+  local optSAVE_PREVIOUS=$2
+
+  if [ "${optSAVE_PREVIOUS}" != "1" ]; then
+(
+cat << EOF
+	@\$(call remove_existing_dirs2,$FILE)
+EOF
+) >> $MKFILE.tmp
+  fi
+(
+cat  << EOF
+	@\$(call unpack3,$FILE)
+	@\$(call get_pkg_root2)
+EOF
+) >> $MKFILE.tmp
+}
+
+
+unset wrt_remove_build_dirs
+#----------------------------------#
+wrt_remove_build_dirs() {          #
+#----------------------------------#
+  local name=$1
+(
+cat << EOF
+	@\$(call remove_build_dirs,$name)
+EOF
+) >> $MKFILE.tmp
+}
+
+#----------------------------------#
+wrt_remove_build_dirs2() {         #
+#----------------------------------#
+  local name=$1
+(
+cat << EOF
+	@\$(call remove_build_dirs2,$name)
+EOF
+) >> $MKFILE.tmp
+}
+
+
+
+unset wrt_touch
+#----------------------------------#
+wrt_touch() {                      #
+#----------------------------------#
+(
+cat << EOF
+	@\$(call housekeeping)
+EOF
+) >> $MKFILE.tmp
+}
+
+unset wrt_RunAsUser
+#----------------------------------#
 wrt_RunAsUser() {                  # Execute script inside time { }, footer to log file
 #----------------------------------#
   local this_script=$1
   local file=$2
-(
-cat << EOF
-	@( time { su - \$(LUSER) -c "source /home/\$(LUSER)/.bashrc && $JHALFSDIR/${PROGNAME}-commands/$file" >>logs/$this_script 2>&1 ; } ) 2>>logs/$this_script && \\
-	echo -e "\nKB: \`du -skx --exclude=${SCRIPT_ROOT} \$(MOUNT_PT)\`\n" >>logs/$this_script
+
+(
+cat << EOF
+	@( time { \$(SU_LUSER) "source \$(LUSER_HOME)/.bashrc && \$(CMDSDIR)/`dirname $file`/\$@" >> logs/\$@ 2>&1; } ) 2>> logs/\$@ && \\
+	\$(PRT_DU) >> logs/\$@
 EOF
 ) >> $MKFILE.tmp
@@ -423,10 +478,9 @@
 (
 cat << EOF
-	@( time { export ${MOUNT_ENV}=\$(MOUNT_PT) && ${PROGNAME}-commands/$file >>logs/$this_script 2>&1 ; } ) 2>>logs/$this_script && \\
-	echo -e "\nKB: \`du -skx --exclude=${SCRIPT_ROOT} \$(MOUNT_PT)\`\n" >>logs/$this_script
-EOF
-) >> $MKFILE.tmp
-}
-
+	@( time { export ${MOUNT_ENV}=\$(MOUNT_PT) && ${PROGNAME}-commands/`dirname $file`/\$@ >>logs/\$@ 2>&1 ; } ) 2>>logs/\$@ && \\
+	\$(PRT_DU_CR) >>logs/\$@
+EOF
+) >> $MKFILE.tmp
+}
 
 #----------------------------------#
@@ -437,11 +491,12 @@
 (
 cat << EOF
-	@( time { source envars && ${PROGNAME}-commands/$file >>logs/$this_script 2>&1 ; } ) 2>>logs/$this_script && \\
-	echo -e "\nKB: \`du -skx --exclude=${SCRIPT_ROOT} \`\n" >>logs/$this_script
-EOF
-) >> $MKFILE.tmp
-}
-
-
+	@( time { source envars && ${PROGNAME}-commands/`dirname $file`/\$@ >>logs/\$@ 2>&1 ; } ) 2>>logs/\$@ && \\
+	echo -e "\nKB: \`du -skx --exclude=${SCRIPT_ROOT} \`\n" >>logs/\$@
+EOF
+) >> $MKFILE.tmp
+}
+
+
+unset wrt_run_as_chroot1
 #----------------------------------#
 wrt_run_as_chroot1() {             #
@@ -450,12 +505,12 @@
   local file=$2
 (
-    cat << EOF
-	@( time { \$(CHROOT1) 'cd /${SCRIPT_ROOT} && source envars && /${SCRIPT_ROOT}/${PROGNAME}-commands/$file >>/${SCRIPT_ROOT}/logs/${this_script} 2>&1' ; } ) 2>>logs/$this_script && \\
-	echo -e "\nKB: \`du -skx --exclude=${SCRIPT_ROOT} \$(MOUNT_PT)\`\n" >>logs/${this_script}
-EOF
-) >> $MKFILE.tmp
-}
-
-
+cat << EOF
+	@( time { \$(CHROOT1) 'cd \$(SCRIPT_ROOT) && source envars && \$(crCMDSDIR)/`dirname $file`/\$@ >>logs/\$@ 2>&1' ; } ) 2>>logs/\$@ && \\
+	\$(PRT_DU_CR) >> logs/\$@
+EOF
+) >> $MKFILE.tmp
+}
+
+unset wrt_run_as_chroot2
 #----------------------------------#
 wrt_run_as_chroot2() {             #
@@ -465,96 +520,51 @@
 (
 cat << EOF
-	@( time { \$(CHROOT2) 'cd /${SCRIPT_ROOT} && source envars && /${SCRIPT_ROOT}/${PROGNAME}-commands/$file >>/${SCRIPT_ROOT}/logs/${this_script} 2>&1' ; } ) 2>>logs/$this_script && \\
-	echo -e "\nKB: \`du -skx --exclude=${SCRIPT_ROOT} \$(MOUNT_PT)\`\n" >>logs/${this_script}
-EOF
-) >> $MKFILE.tmp
-}
-
-
-#----------------------------------#
-wrt_copy_fstab() {                 #
+	@( time { \$(CHROOT2) 'cd \$(SCRIPT_ROOT) && source envars && \$(crCMDSDIR)/`dirname $file`/\$@ >>logs/\@ 2>&1' ; } ) 2>>logs/\@ && \\
+	\$(PRT_DU_CR) >> logs/\$@
+EOF
+) >> $MKFILE.tmp
+}
+
+unset wrt_target
+#----------------------------------#
+wrt_target() {                     # Create target and initialize log file
 #----------------------------------#
   local i=$1
-(
-    cat << EOF
-	@cp -v $FSTAB \$(MOUNT_PT)/etc/fstab >>logs/$i 2>&1
-EOF
-) >> $MKFILE.tmp
-}
-
-#----------------------------------#
-wrt_copy_fstab2() {                #
+  local PREV=$2
+  case $i in
+    iteration* ) local LOGFILE="\$@.log" ;;
+             * ) local LOGFILE="\$@"     ;;
+  esac
+(
+cat << EOF
+
+$i:  $PREV
+	@\$(call echo_message, Building)
+	@./progress_bar.sh \$@ &
+	@echo -e "\n\`date\`\n\nKB: \`du -skx --exclude=${SCRIPT_ROOT} \$(MOUNT_PT)\`\n" >logs/$LOGFILE
+EOF
+) >> $MKFILE.tmp
+}
+
+#----------------------------------#
+wrt_target_boot() {                # Create target and initialize log file
 #----------------------------------#
   local i=$1
-(
-    cat << EOF
-	@cp -v /sources/fstab /etc/fstab >>logs/$i 2>&1
-EOF
-) >> $MKFILE.tmp
-}
-
-
-#----------------------------------#
-wrt_remove_build_dirs() {          #
-#----------------------------------#
-  local name=$1
-(
-cat << EOF
-	@ROOT=\`head -n1 \$(MOUNT_PT)\$(SRC)/\$(PKG_LST) | sed 's@^./@@;s@/.*@@'\` && \\
-	rm -rf \$(MOUNT_PT)\$(SRC)/\$\$ROOT && \\
-	if [ -e \$(MOUNT_PT)\$(SRC)/$name-build ]; then \\
-		rm -rf \$(MOUNT_PT)\$(SRC)/$name-build; \\
-	fi;
-EOF
-) >> $MKFILE.tmp
-}
-
-
-#----------------------------------#
-wrt_remove_build_dirs2() {         #
-#----------------------------------#
-  local name=$1
-(
-cat << EOF
-	@ROOT=\`head -n1 \$(SRC)/\$(PKG_LST) | sed 's@^./@@;s@/.*@@'\` && \\
-	rm -rf \$(SRC)/\$\$ROOT && \\
-	if [ -e \$(SRC)/$name-build ]; then \\
-		rm -rf \$(SRC)/$name-build; \\
-	fi;
-EOF
-) >> $MKFILE.tmp
-}
-
-
-#----------------------------------#
-wrt_touch() {                      #
-#----------------------------------#
-(
-cat << EOF
-	@touch  \$@ && \\
-	sleep .25 && \\
-	echo -e "\n\n "\$(BOLD)Target \$(BLUE)\$@ \$(BOLD)OK && \\
-	echo --------------------------------------------------------------------------------\$(WHITE)
-EOF
-) >> $MKFILE.tmp
-}
-
-
-#----------------------------------#
-wrt_report() {                     #
-#----------------------------------#
-(
-cat << EOF
-
-create-sbu_du-report:  $PREV
+  local PREV=$2
+  case $i in
+    iteration* ) local LOGFILE="\$@.log" ;;
+             * ) local LOGFILE="\$@" ;;
+  esac
+(
+cat << EOF
+
+$i:  $PREV
 	@\$(call echo_message, Building)
-	@./create-sbu_du-report.sh logs $VERSION
-	@\$(call echo_report,$VERSION-SBU_DU-$(date --iso-8601).report)
-	@touch  \$@
-EOF
-) >> $MKFILE.tmp
-
-chapter789="$chapter789 create-sbu_du-report"
-}
+	@./progress_bar.sh \$@ &
+	@echo -e "\n\`date\`\n\nKB: \`du -skx --exclude=${SCRIPT_ROOT}\`\n" >logs/$LOGFILE
+EOF
+) >> $MKFILE.tmp
+}
+
 
 
@@ -563,5 +573,5 @@
 #----------------------------#
   # Test if make must be run.
-  if [ "$RUNMAKE" = "1" ] ; then
+  if [ "$RUNMAKE" = "y" ] ; then
     # Test to make sure we're running the build as root
     if [ "$UID" != "0" ] ; then
@@ -583,5 +593,5 @@
 #----------------------------#
   # Test if the clean must be done.
-  if [ "$CLEAN" = "1" ] ; then
+  if [ "${CLEAN}" = "y" ]; then
     # Test to make sure we're running the clean as root
     if [ "$UID" != "0" ] ; then
@@ -696,5 +706,5 @@
                  --stringparam page $PAGE \
                  --stringparam lang $LANG \
-                 --stringparam keymap ${KEYMAP:-"none"} \
+                 --stringparam keymap $KEYMAP \
                  -o ./${PROGNAME}-commands/ $XSL $BOOK/$ARCH-index.xml >>$LOGDIR/$LOG 2>&1
       ;;
@@ -708,5 +718,5 @@
                  --stringparam page $PAGE \
                  --stringparam lang $LANG \
-                 --stringparam keymap ${KEYMAP:-"none"} \
+                 --stringparam keymap $KEYMAP \
                  -o ./${PROGNAME}-commands/ $XSL $BOOK/$ARCH-index.xml >>$LOGDIR/$LOG 2>&1
       ;;
@@ -722,5 +732,5 @@
                  --stringparam lang $LANG \
                  --stringparam lc_all $LC_ALL \
-                 --stringparam keymap ${KEYMAP:-"none"} \
+                 --stringparam keymap $KEYMAP \
                  --stringparam grsecurity_host $GRSECURITY_HOST \
                  -o ./${PROGNAME}-commands/ $XSL $BOOK/index.xml >>$LOGDIR/$LOG 2>&1
@@ -786,5 +796,5 @@
 
     # Test if the packages must be downloaded
-  [ ! "$GETPKG" = "1" ] && return
+  [ ! "$GETPKG" = "y" ] && return
 
   gs_wrt_message(){
@@ -816,5 +826,5 @@
         *linux/linux-* )
             [[ -z "$CONFIG" ]] && [[ -z "$BOOT_CONFIG" ]] && \
-            [[ "$GETKERNEL" = "0" ]] && continue
+            [[ "$GETKERNEL" = "n" ]] && continue
           ;;
     esac
@@ -898,5 +908,5 @@
       # Do not allow the automatic execution of the Makefile.
     echo "${tab_}${BOLD}${RED}*** ${YELLOW}Automatic execution of the generated makefile has been inhibited. ${RED}***${OFF}${nl_}"
-    RUNMAKE=0
+    RUNMAKE="n"
   fi
 }
Index: common/config
===================================================================
--- common/config	(revision 5be3651d7f7b42651c1dc9100c665ca90ed30a3a)
+++ common/config	(revision 401f81e4da7d18f00f44b0bb93d4dbed3c8209b2)
@@ -12,16 +12,16 @@
 BUILDDIR=/mnt/build_dir
 
-# Create SBU and disk usage report  0(no)/1(yes)
+# Create SBU and disk usage report  n(no)/y(yes)
 # NOTE: requires to have bc installed on the host
-REPORT=1
+REPORT=y
 
 #=== Getting packages ===
 #    Files will be retrieved from the local archive SRC_ARCHIVE
 #    (if defined) or the 'net and will be stored in $BUILDDIR/sources
-#--- Download the source packages 0(no)/1(yes)
-GETPKG=0
+#--- Download the source packages n(no)/y(yes)
+GETPKG=n
 
 #--- The local repository for packages/file
-#    Used only if GETPKG = 1
+#    Used only if GETPKG = y
 #    Any missing file will be downloaded and archived here,
 #    if the user has the right priviledges.
@@ -33,6 +33,6 @@
 
 #=== Build options ===
-#--- Automatically run the makefile once it has been created  0(no)/1(yes)
-RUNMAKE=0
+#--- Automatically run the makefile once it has been created  n(no)/y(yes)
+RUNMAKE=n
 
 #--- Optimize the build  [0-2]
@@ -53,10 +53,10 @@
 
 #--- Bomb on test suites failures?
-#  0 = no, I want to build the full system and review the logs
-#  1 = yes, bomb at the first test suite failure to can review the build dir
-BOMB_TEST=0
+#  n = no, I want to build the full system and review the logs
+#  y = yes, bomb at the first test suite failure to can review the build dir
+BOMB_TEST=n
 
-#--- Run the stripping phases  0(no)/1(yes)
-STRIP=1
+#--- Run the stripping phases  n(no)/y(yes)
+STRIP=y
 
 #--- page definition for groff letter/A4
@@ -66,6 +66,6 @@
 TIMEZONE=${TZ:-GMT}
 
-#--- install the optional vim-lang package  0(no)/1(yes)
-VIMLANG=1
+#--- install the optional vim-lang package  n(no)/y(yes)
+VIMLANG=y
 
 #--- Language information in /etc/profile  See <locale -a> for values
@@ -80,15 +80,15 @@
 
 #=== Variables needed by iterative comparison analysis ===
-#--- Should some iterative comparison analysis by made? 0(no)/1(yes)
-COMPARE=0
+#--- Should some iterative comparison analysis by made? n(no)/y(yes)
+COMPARE=n
 
 #--- The number of final stage builds to create and compare, min. 2, max. 5
 ITERATIONS=3
 
-#--- Run ICA testing 0(no)/1(yes)
-RUN_ICA=0
+#--- Run ICA testing n(no)/y(yes)
+RUN_ICA=n
 
-#--- Run farce testing 0(no)/1(yes)
-RUN_FARCE=0
+#--- Run farce testing n(no)/y(yes)
+RUN_FARCE=n
 
 #==== INTERNAL VARIABLES ====
Index: common/func_compare.sh
===================================================================
--- common/func_compare.sh	(revision 5be3651d7f7b42651c1dc9100c665ca90ed30a3a)
+++ common/func_compare.sh	(revision 401f81e4da7d18f00f44b0bb93d4dbed3c8209b2)
@@ -55,5 +55,5 @@
   fi
 
-  if [[ "$RUN_ICA" = "1" ]] ; then
+  if [[ "$RUN_ICA" = "y" ]] ; then
     local DEST_ICA=$DEST_TOPDIR/ICA && \
 (
@@ -68,5 +68,5 @@
   fi
 
-  if [[ "$RUN_FARCE" = "1" ]] ; then
+  if [[ "$RUN_FARCE" = "y" ]] ; then
     local DEST_FARCE=$DEST_TOPDIR/farce && \
 (
Index: common/func_validate_configs.sh
===================================================================
--- common/func_validate_configs.sh	(revision 5be3651d7f7b42651c1dc9100c665ca90ed30a3a)
+++ common/func_validate_configs.sh	(revision 401f81e4da7d18f00f44b0bb93d4dbed3c8209b2)
@@ -178,11 +178,11 @@
 
       # Validate general parameters..
-      GETPKG)     validate_against_str "x0x x1x" ;;
+      GETPKG)     validate_against_str "xnx xyx" ;;
       GETKERNEL ) if [[ -z "$CONFIG" ]] && [[ -z "$BOOT_CONFIG" ]] ; then
-                    [[ "$GETPKG" = "1" ]] && validate_against_str "x0x x1x"
+                    [[ "$GETPKG" = "y" ]] && validate_against_str "xnx xyx"
                   fi ;;
-      RUNMAKE)    validate_against_str "x0x x1x" ;;
-      REPORT)     validate_against_str "x0x x1x"
-                  if [[ "${!config_param}" = "1" ]]; then
+      RUNMAKE)    validate_against_str "xnx xyx" ;;
+      REPORT)     validate_against_str "xnx xyx"
+                  if [[ "${!config_param}" = "y" ]]; then
                     if [[ `type -p bc` ]]; then
                       continue
@@ -190,12 +190,12 @@
                       echo -e "  ${BOLD}The bc binary was not found${OFF}"
                       echo -e "  The SBU and disk usage report creation will be skiped"
-                      REPORT=0
+                      REPORT=n
                       continue
                     fi
                   fi ;;
-      COMPARE)    if [[ ! "$COMPARE" = "1" ]]; then
-                    validate_against_str "x0x x1x"
+      COMPARE)    if [[ ! "$COMPARE" = "y" ]]; then
+                    validate_against_str "xnx xyx"
                   else
-                    if [[ ! "${RUN_ICA}" = "1" ]] && [[ ! "${RUN_FARCE}" = "1" ]]; then
+                    if [[ ! "${RUN_ICA}" = "y" ]] && [[ ! "${RUN_FARCE}" = "y" ]]; then
                        echo  "${nl_}${DD_BORDER}"
                        echo  "You have elected to analyse your build but have failed to select a tool." >&2
@@ -205,12 +205,12 @@
                     fi
                   fi ;;
-      RUN_ICA)    [[ "$COMPARE" = "1" ]] && validate_against_str "x0x x1x" ;;
-      RUN_FARCE)  [[ "$COMPARE" = "1" ]] && validate_against_str "x0x x1x" ;;
-      ITERATIONS) [[ "$COMPARE" = "1" ]] && validate_against_str "x2x x3x x4x x5x" ;;
+      RUN_ICA)    [[ "$COMPARE" = "y" ]] && validate_against_str "xnx xyx" ;;
+      RUN_FARCE)  [[ "$COMPARE" = "y" ]] && validate_against_str "xnx xyx" ;;
+      ITERATIONS) [[ "$COMPARE" = "y" ]] && validate_against_str "x2x x3x x4x x5x" ;;
       TEST)       validate_against_str "x0x x1x x2x x3x" ;;
-      BOMB_TEST)  [[ ! "$TEST" = "0" ]] && validate_against_str "x0x x1x" ;;
+      BOMB_TEST)  [[ ! "$TEST" = "0" ]] && validate_against_str "xnx xyx" ;;
       OPTIMIZE)   validate_against_str "x0x x1x x2x" ;;
-      STRIP)      validate_against_str "x0x x1x" ;;
-      VIMLANG)    validate_against_str "x0x x1x" ;;
+      STRIP)      validate_against_str "xnx xyx" ;;
+      VIMLANG)    validate_against_str "xnx xyx" ;;
       MODEL)      validate_against_str "xglibcx xuclibcx" ;;
       PAGE)       validate_against_str "xletterx xA4x" ;;
@@ -224,5 +224,5 @@
                   [[ "${!config_param}" = "**EDIT ME**" ]] && write_error_and_die
                   ;;
-      GRSECURITY_HOST)  validate_against_str "x0x x1x" ;;
+      GRSECURITY_HOST)  validate_against_str "xnx xyx" ;;
 
       # BOOK validation. Very ugly, need be fixed
@@ -236,5 +236,5 @@
       #  fatal   -z -d -w,
       #  warning -z+   -w+
-      SRC_ARCHIVE) [[ "$GETPKG" = "1" ]] && validate_dir -z+ -d -w+ ;;
+      SRC_ARCHIVE) [[ "$GETPKG" = "y" ]] && validate_dir -z+ -d -w+ ;;
       BUILDDIR)   # The build directory/partition MUST exist and be writable by the user
                   validate_dir -z -d -w
Index: common/makefile-functions
===================================================================
--- common/makefile-functions	(revision 5be3651d7f7b42651c1dc9100c665ca90ed30a3a)
+++ common/makefile-functions	(revision 401f81e4da7d18f00f44b0bb93d4dbed3c8209b2)
@@ -16,11 +16,60 @@
 endef
 
+define remove_existing_dirs
+  @PKG_PATH=`ls -t $(SRCSDIR)/$(1) | head -n1` && \
+  ROOT=`tar -tf $$PKG_PATH | head -n1 | sed -e 's@^./@@;s@/.*@@'` && \
+  rm -rf $(SRCSDIR)/$$ROOT && \
+  rm -rf $(SRCSDIR)/$${ROOT%-*}-build
+endef
+
+define remove_existing_dirs2
+  @PKG_PATH=\`ls -t $(SRC)/$(1) | head -n1\` && \
+  ROOT=`tar -tf $$PKG_PATH | head -n1 | sed -e 's@^./@@;s@/.*@@'` && \
+  rm -rf $(SRC)/$$ROOT && \
+  rm -rf $(SRC)/$${ROOT-*}-build
+endef
+
+define remove_build_dirs
+  @ROOT=`head -n1 $(SRCSDIR)/$(PKG_LST) | sed 's@^./@@;s@/.*@@'` && \
+  rm -rf $(SRCSDIR)/$$ROOT && \
+  rm -rf $(SRCSDIR)/$(1)-build
+endef
+
+define remove_build_dirs2
+  @ROOT=`head -n1 $(SRC)/$(PKG_LST) | sed 's@^./@@;s@/.*@@'` && \
+  rm -rf $(SRC)/$$ROOT && \
+  rm -rf $(SRC)/$(1)-build
+endef
+
+define housekeeping
+  @touch  $@ && \
+  sleep .25 && \
+  echo -e "\n\n "$(BOLD)Target $(BLUE)$@ $(BOLD)OK && \
+  echo --------------------------------------------------------------------------------$(WHITE)
+
+endef
+
+define get_pkg_root
+  @ROOT=`head -n1 $(SRCSDIR)/$(PKG_LST) | sed 's@^./@@;s@/.*@@'` && \
+  if [ "$(1)" != "nouser" ]; then \
+    echo "export PKGDIR=$(SRCSDIR)/$$ROOT" > envars; \
+    chown -R $(LUSER) $(SRCSDIR)/$$ROOT; \
+  else \
+    echo "export PKGDIR=$(crSRCSDIR)/$$ROOT" > envars; \
+  fi;
+endef
+
+define get_pkg_root2
+  @ROOT=`head -n1 $(SRC)/$(PKG_LST) | sed 's@^./@@;s@/.*@@'` && \
+  echo "export PKGDIR=$(SRC)/$$ROOT" > envars
+endef
+
 define unpack
-  @cd $(MOUNT_PT)$(SRC) && \
+  @cd $(SRCSDIR) && \
   tar -xvf `ls -t $(1) | head -n1` > $(PKG_LST)
 endef
 
 define unpack2
-  @cd $(MOUNT_PT)$(SRC) && \
+  @cd $(SRCSDIR) && \
   /tools/bin/tar -xvf `ls -t $(1) | head -n1` > $(PKG_LST)
 endef
Index: master.sh
===================================================================
--- master.sh	(revision 5be3651d7f7b42651c1dc9100c665ca90ed30a3a)
+++ master.sh	(revision 401f81e4da7d18f00f44b0bb93d4dbed3c8209b2)
@@ -47,25 +47,4 @@
     VERBOSITY=0
 
-[[ $VERBOSITY > 0 ]] && echo -n "Loading common-functions module..."
-source $COMMON_DIR/common-functions
-[[ $? > 0 ]] && echo " $COMMON_DIR/common-functions did not load.." && exit
-[[ $VERBOSITY > 0 ]] && echo "OK"
-#
-[[ $VERBOSITY > 0 ]] && echo -n "Loading masterscript conf..."
-source $COMMON_DIR/config
-[[ $? > 0 ]] && echo "$COMMON_DIR/conf did not load.." && exit
-[[ $VERBOSITY > 0 ]] && echo "OK"
-#
-[[ $VERBOSITY > 0 ]] && echo -n "Loading config module <$MODULE_CONFIG>..."
-source $MODULE_CONFIG
-[[ $? > 0 ]] && echo "$MODULE_CONFIG did not load.." && exit 1
-[[ $VERBOSITY > 0 ]] && echo "OK"
-#
-[[ $VERBOSITY > 0 ]] && echo -n "Loading code module <$MODULE>..."
-source $MODULE
-[[ $? > 0 ]] && echo "$MODULE did not load.." && exit 2
-[[ $VERBOSITY > 0 ]] && echo "OK"
-#
-[[ $VERBOSITY > 0 ]] && echo "${SD_BORDER}${nl_}"
 
 if [[ -e using_menuconfig ]]; then
@@ -85,4 +64,10 @@
 	#--- farce report log directory
   FARCELOGDIR=$LOGDIR/farce
+          XSL=$PROGNAME.xsl
+
+  case $PROGNAME in
+    clfs2) LFSVRS=development; TREE=branches/clfs-2.0/BOOK ;;
+        *) LFSVRS=development; TREE=trunk/BOOK             ;;
+  esac
 
   if [[ ! -z ${BRANCH_ID} ]]; then
@@ -113,5 +98,49 @@
     esac
   fi
-fi
+  # These are boolean vars generated from Config.in.
+  # ISSUE: If a boolean parameter is not set <true> that
+  # variable is not defined by the menu app. This can
+  # cause a headache if you are not careful.
+  #  The following parameters MUST be created and have a
+  #  default value.
+  RUNMAKE=${RUNMAKE:-n}
+  GETPKG=${GETPKG:-n}
+  GETKERNEL=${GETKERNEL:-n}
+  COMPARE=${COMPARE:-n}
+  RUN_FARCE=${RUN_FARCE:-n}
+  RUN_ICA=${RUN_ICA:-n}
+  BOMB_TEST=${BOMB_TEST:-n}
+  STRIP=${STRIP:=n}
+  REPORT=${REPORT:=n}
+  VIMLANG=${VIMLANG:-n}
+  KEYMAP=${KEYMAP:=none}
+  GRSECURITY_HOST=${GRSECURITY_HOST:-n}
+
+else
+  #
+  [[ $VERBOSITY > 0 ]] && echo -n "Loading masterscript conf..."
+  source $COMMON_DIR/config
+  [[ $? > 0 ]] && echo "$COMMON_DIR/conf did not load.." && exit
+  [[ $VERBOSITY > 0 ]] && echo "OK"
+  #
+  [[ $VERBOSITY > 0 ]] && echo -n "Loading config module <$MODULE_CONFIG>..."
+  source $MODULE_CONFIG
+  [[ $? > 0 ]] && echo "$MODULE_CONFIG did not load.." && exit 1
+  [[ $VERBOSITY > 0 ]] && echo "OK"
+  #
+fi
+
+
+[[ $VERBOSITY > 0 ]] && echo -n "Loading common-functions module..."
+source $COMMON_DIR/common-functions
+[[ $? > 0 ]] && echo " $COMMON_DIR/common-functions did not load.." && exit
+[[ $VERBOSITY > 0 ]] && echo "OK"
+[[ $VERBOSITY > 0 ]] && echo -n "Loading code module <$MODULE>..."
+source $MODULE
+[[ $? > 0 ]] && echo "$MODULE did not load.." && exit 2
+[[ $VERBOSITY > 0 ]] && echo "OK"
+#
+[[ $VERBOSITY > 0 ]] && echo "${SD_BORDER}${nl_}"
+
 
 #===========================================================
@@ -191,5 +220,5 @@
       ;;
 
-    --get-packages | -G )      GETPKG=1    ;;
+    --get-packages | -G )      GETPKG=y    ;;
 
     --help | -h )  usage | more && exit  ;;
@@ -268,16 +297,7 @@
       shift
       case $1 in
-        ICA)              RUN_ICA=1
-                        RUN_FARCE=0
-                          COMPARE=1
-        ;;
-        farce)            RUN_ICA=0
-                        RUN_FARCE=1
-                          COMPARE=1
-        ;;
-        both)             RUN_ICA=1
-                        RUN_FARCE=1
-                          COMPARE=1
-        ;;
+        ICA)    RUN_ICA=y; RUN_FARCE=n; COMPARE=y  ;;
+        farce)  RUN_ICA=n; RUN_FARCE=y; COMPARE=y  ;;
+        both)   RUN_ICA=y; RUN_FARCE=y; COMPARE=y  ;;
         *)
           echo -e "\n$1 is an unknown analysis method."
@@ -309,7 +329,7 @@
       ;;
 
-    --run-make | -M )      RUNMAKE=1 ;;
-
-    --rebuild | -R )       CLEAN=1   ;;
+    --run-make | -M )      RUNMAKE=y ;;
+
+    --rebuild | -R )       CLEAN=y   ;;
 
     # CLFS options
@@ -317,86 +337,38 @@
       test $# = 1 && eval "$exit_missing_arg"
       shift
-      case $1 in
-        arm )
-          ARCH=arm
-          TARGET="arm-unknown-linux-gnu"
-          ;;
-        x86 )
-          ARCH=x86
-          TARGET="i686-pc-linux-gnu"
-          ;;
-        i486 )
-          ARCH=x86
-          TARGET="i486-pc-linux-gnu"
-          ;;
-        i586 )
-          ARCH=x86
-          TARGET="i586-pc-linux-gnu"
-          ;;
-        ppc )
-          ARCH=ppc
-          TARGET="powerpc-unknown-linux-gnu"
-          ;;
-        mips )
-          ARCH=mips
-          TARGET="mips-unknown-linux-gnu"
-          ;;
-        mipsel )
-          ARCH=mips
-          TARGET="mipsel-unknown-linux-gnu"
-          ;;
-        sparc )
-          ARCH=sparc
-          TARGET="sparcv9-unknown-linux-gnu"
-          ;;
-        x86_64-64 )
-          ARCH=x86_64-64
-          TARGET="x86_64-unknown-linux-gnu"
-          ;;
-        mips64-64 )
-          ARCH=mips64-64
-          TARGET="mips-unknown-linux-gnu"
-          ;;
-        mipsel64-64 )
-          ARCH=mips64-64
-          TARGET="mipsel-unknown-linux-gnu"
-          ;;
-        sparc64-64 )
-          ARCH=sparc64-64
-          TARGET="sparc64-unknown-linux-gnu"
-          ;;
-        alpha )
-          ARCH=alpha
-          TARGET="alpha-unknown-linux-gnu"
-          ;;
-        x86_64 )
-          ARCH=x86_64
-          TARGET="x86_64-unknown-linux-gnu"
-          TARGET32="i686-pc-linux-gnu"
-          ;;
-        mips64 )
-          ARCH=mips64
-          TARGET="mips-unknown-linux-gnu"
-          TARGET32="mips-unknown-linux-gnu"
-          ;;
-        mipsel64 )
-          ARCH=mips64
-          TARGET="mipsel-unknown-linux-gnu"
-          TARGET32="mipsel-unknown-linux-gnu"
-          ;;
-        sparc64 )
-          ARCH=sparc64
-          TARGET="sparc64-unknown-linux-gnu"
-          TARGET32="sparcv9-unknown-linux-gnu"
-          ;;
-        ppc64 )
-          ARCH=ppc64
-          TARGET="powerpc64-unknown-linux-gnu"
-          TARGET32="powerpc-unknown-linux-gnu"
-          ;;
-        * )
-          echo -e "\n$1 is an unknown or unsupported arch."
-          exit 1
-          ;;
+      case $PROGNAME in
+        CLFS2)
+	  case $1 in
+            arm) ARCH=arm; TARGET="arm-unknown-linux-gnu" ;;
+            x86) ARCH=x86; TARGET="i686-pc-linux-gnu"     ;;
+	      *) echo -e "\n$1 is an unknown or unsupported arch.";  exit 1
+          esac
+	  ;;
+        CLFS)
+          case $1 in
+            arm )   ARCH=arm;   TARGET="arm-unknown-linux-gnu" ;;
+            x86 )   ARCH=x86;   TARGET="i686-pc-linux-gnu"     ;;
+           i486 )   ARCH=x86;   TARGET="i486-pc-linux-gnu"     ;;
+           i586 )   ARCH=x86;   TARGET="i586-pc-linux-gnu"     ;;
+            ppc )   ARCH=ppc;   TARGET="powerpc-unknown-linux-gnu"   ;;
+           mips )   ARCH=mips;  TARGET="mips-unknown-linux-gnu"      ;;
+           mipsel ) ARCH=mips;  TARGET="mipsel-unknown-linux-gnu"    ;;
+            sparc ) ARCH=sparc; TARGET="sparcv9-unknown-linux-gnu"   ;;
+
+           x86_64-64 )   ARCH=x86_64-64;  TARGET="x86_64-unknown-linux-gnu"   ;;
+           mips64-64 )   ARCH=mips64-64;  TARGET="mips-unknown-linux-gnu"     ;;
+           mipsel64-64 ) ARCH=mips64-64;  TARGET="mipsel-unknown-linux-gnu" ;;
+           sparc64-64 )  ARCH=sparc64-64; TARGET="sparc64-unknown-linux-gnu" ;;
+           alpha )       ARCH=alpha;      TARGET="alpha-unknown-linux-gnu"   ;;
+
+           x86_64 )   ARCH=x86_64;  TARGET="x86_64-unknown-linux-gnu";    TARGET32="i686-pc-linux-gnu"        ;;
+           mips64 )   ARCH=mips64;  TARGET="mips-unknown-linux-gnu";      TARGET32="mips-unknown-linux-gnu"   ;;
+           mipsel64 ) ARCH=mips64;  TARGET="mipsel-unknown-linux-gnu";    TARGET32="mipsel-unknown-linux-gnu"  ;;
+           sparc64 )  ARCH=sparc64; TARGET="sparc64-unknown-linux-gnu";   TARGET32="sparcv9-unknown-linux-gnu"  ;;
+            ppc64 )   ARCH=ppc64;   TARGET="powerpc64-unknown-linux-gnu"; TARGET32="powerpc-unknown-linux-gnu"  ;;
+
+            * )  echo -e "\n$1 is an unknown or unsupported arch.";   exit 1  ;;
+          esac
+	  ;;
       esac
       ;;
@@ -447,4 +419,5 @@
   shift
 done
+
 
 #===================================================
@@ -461,6 +434,5 @@
 
 
-# Check for minimum gcc and kernel versions
-#check_requirements  1 # 0/1  0-do not display values.
+# Check for minimum bash,tar,gcc and kernel versions
 echo
 check_version "2.6.2" "`uname -r`"         "KERNEL"
@@ -483,5 +455,5 @@
 # Load additional modules or configuration files based on global settings
 # compare module
-if [[ "$COMPARE" = "1" ]]; then
+if [[ "$COMPARE" = "y" ]]; then
   [[ $VERBOSITY > 0 ]] && echo -n "Loading compare module..."
   source $COMMON_DIR/func_compare.sh
@@ -538,5 +510,5 @@
   [[ "$OPTIMIZE" != "0" ]] && cp optimize/opt_override $JHALFSDIR/
   #
-  if [[ "$COMPARE" != "0" ]] ; then
+  if [[ "$COMPARE" = "y" ]]; then
     mkdir -p $JHALFSDIR/extras
     cp extras/* $JHALFSDIR/extras
@@ -550,5 +522,5 @@
   fi
   #
-  if [[ "$REPORT" = "1" ]]; then
+  if [[ "$REPORT" = "y" ]]; then
     cp $COMMON_DIR/create-sbu_du-report.sh  $JHALFSDIR/
     # After being sure that all looks sane, dump the settings to a file
@@ -557,5 +529,5 @@
   fi
   #
-  [[ "$GETPKG" = "1" ]] && cp $COMMON_DIR/urls.xsl  $JHALFSDIR/
+  [[ "$GETPKG" = "y" ]] && cp $COMMON_DIR/urls.xsl  $JHALFSDIR/
   #
   cp $COMMON_DIR/packages.xsl  $JHALFSDIR/
