Change bool parameter definitions from 0/1 to y/n to match the new menu app
This commit is contained in:
parent
54f47822eb
commit
47fddc8716
19 changed files with 223 additions and 298 deletions
|
@ -28,13 +28,13 @@
|
|||
<xsl:param name="testsuite" select="1"/>
|
||||
|
||||
<!-- 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 -->
|
||||
<xsl:param name="timezone" select="GMT"/>
|
||||
|
@ -102,7 +102,7 @@
|
|||
</xsl:choose>
|
||||
<xsl:if test="sect2[@role='installation']">
|
||||
<xsl:text>cd $PKGDIR
</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
</xsl:text>
|
||||
</xsl:if>
|
||||
</xsl:if>
|
||||
|
@ -125,7 +125,7 @@
|
|||
contains(string(),'check')) and
|
||||
($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>
|
||||
<xsl:value-of select="substring-after(string(),'make')"/>
|
||||
|
@ -193,7 +193,7 @@
|
|||
</xsl:if>
|
||||
<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>
|
||||
<xsl:value-of select="substring-after(string(),'check')"/>
|
||||
|
@ -214,7 +214,7 @@
|
|||
<xsl:choose>
|
||||
<xsl:when test="$testsuite != '0'">
|
||||
<xsl:choose>
|
||||
<xsl:when test="$bomb-testsuite = '0'">
|
||||
<xsl:when test="$bomb-testsuite = 'n'">
|
||||
<xsl:text>make -k check >> $TEST_LOG 2>&1 || true
</xsl:text>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
|
@ -230,7 +230,7 @@
|
|||
<xsl:when test="$testsuite != '0'">
|
||||
<xsl:value-of select="substring-before(string(),'>g')"/>
|
||||
<xsl:choose>
|
||||
<xsl:when test="$bomb-testsuite = '0'">
|
||||
<xsl:when test="$bomb-testsuite = 'n'">
|
||||
<xsl:text>>> $TEST_LOG 2>&1 || true
</xsl:text>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
|
|
|
@ -54,8 +54,8 @@ CONFIG=
|
|||
BOOT_CONFIG=
|
||||
|
||||
# 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
|
||||
# If you have previously checked out the book from the repository
|
||||
|
|
|
@ -497,7 +497,7 @@ final_system_Makefiles() { #
|
|||
# Test if the stripping phase must be skipped.
|
||||
# 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
|
||||
|
||||
|
@ -607,7 +607,7 @@ bm_final_system_Makefiles() { #
|
|||
# Test if the stripping phase must be skipped
|
||||
# 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
|
||||
|
||||
|
@ -882,7 +882,7 @@ bootable_Makefiles() { #
|
|||
done
|
||||
|
||||
# Add SBU-disk_usage report target if required
|
||||
if [[ "$REPORT" = "1" ]] ; then wrt_report ; fi
|
||||
if [[ "$REPORT" = "y" ]] ; then wrt_report ; fi
|
||||
|
||||
}
|
||||
|
||||
|
@ -961,7 +961,7 @@ bm_bootable_Makefiles() { #
|
|||
done
|
||||
|
||||
# Add SBU-disk_usage report target if required
|
||||
if [[ "$REPORT" = "1" ]] ; then wrt_report ; fi
|
||||
if [[ "$REPORT" = "y" ]] ; then wrt_report ; fi
|
||||
|
||||
}
|
||||
|
||||
|
@ -985,7 +985,7 @@ build_Makefile() { # Construct a Makefile from the book scripts
|
|||
fi
|
||||
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
|
||||
else
|
||||
|
@ -995,7 +995,7 @@ build_Makefile() { # Construct a Makefile from the book scripts
|
|||
fi
|
||||
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
|
||||
fi
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
<xsl:param name="keymap" select="none"/>
|
||||
|
||||
<!-- Install vim-lang package? -->
|
||||
<xsl:param name="vim-lang" select="1"/>
|
||||
<xsl:param name="vim-lang" select="y"/>
|
||||
|
||||
<!-- Time zone -->
|
||||
<xsl:param name="timezone" select="GMT"/>
|
||||
|
@ -75,7 +75,7 @@
|
|||
</xsl:if>
|
||||
<xsl:if test="sect2[@role='installation']">
|
||||
<xsl:text>cd $PKGDIR
</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
</xsl:text>
|
||||
</xsl:if>
|
||||
</xsl:if>
|
||||
|
|
|
@ -33,8 +33,8 @@ FSTAB=
|
|||
CONFIG=
|
||||
|
||||
# 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
|
||||
# If you have previously checked out the book from the repository
|
||||
|
|
|
@ -215,7 +215,7 @@ final_system_Makefiles() { #
|
|||
# Test if the stripping phase must be skipped.
|
||||
# Skip alsp temp-perl for iterative runs
|
||||
case $this_script in
|
||||
*stripping*) [[ "$STRIP" = "0" ]] && continue ;;
|
||||
*stripping*) [[ "$STRIP" = "n" ]] && continue ;;
|
||||
esac
|
||||
|
||||
# Grab the name of the target, strip id number, XXX-script
|
||||
|
@ -403,7 +403,7 @@ bootable_Makefiles() { #
|
|||
done
|
||||
|
||||
# Add SBU-disk_usage report target if required
|
||||
if [[ "$REPORT" = "1" ]] ; then wrt_report ; fi
|
||||
if [[ "$REPORT" = "y" ]] ; then wrt_report ; fi
|
||||
|
||||
}
|
||||
|
||||
|
|
94
Config.in
94
Config.in
|
@ -336,7 +336,7 @@ menu "--- General Settings"
|
|||
help
|
||||
#-- The directory where the created system will be located.
|
||||
|
||||
config CONFIG_GETPKG
|
||||
config GETPKG
|
||||
bool "Retrieve source files"
|
||||
default n
|
||||
help
|
||||
|
@ -348,28 +348,28 @@ menu "--- General Settings"
|
|||
config SRC_ARCHIVE
|
||||
string "Package Archive Directory"
|
||||
default "$SRC_ARCHIVE"
|
||||
depends CONFIG_GETPKG
|
||||
depends GETPKG
|
||||
help
|
||||
#-- A local archive for packages/file (not $BUILDDIR/sources)
|
||||
# Used only if GETPKG = 1
|
||||
# Any missing file will be downloaded and archived here,
|
||||
# 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
|
||||
help
|
||||
#-- Automatically run the makefile once it has been created
|
||||
|
||||
config CONFIG_REBUILD
|
||||
config CLEAN
|
||||
bool "Rebuild files"
|
||||
default n
|
||||
help
|
||||
|
@ -430,22 +430,23 @@ menu "--- Build Settings"
|
|||
default "2" if TST_2
|
||||
default "3" if TST_3
|
||||
|
||||
choice
|
||||
choice
|
||||
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
|
||||
|
||||
#--- FSTAB
|
||||
|
@ -494,11 +495,11 @@ menu "--- Build Settings"
|
|||
# a keymap included in the kernel
|
||||
#--- 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
|
||||
|
@ -549,12 +550,12 @@ endmenu
|
|||
|
||||
menu "--- Advanced Features"
|
||||
|
||||
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
|
||||
default n
|
||||
|
@ -574,21 +575,21 @@ menu "--- Advanced Features"
|
|||
#
|
||||
|
||||
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
|
||||
#-- Run farce testing
|
||||
|
@ -647,54 +648,3 @@ endmenu
|
|||
# depends CONFIG_BLFS_CMDS
|
||||
|
||||
|
||||
# convert CONFIG_XXXX n/y to XXXX 0/1
|
||||
|
||||
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
|
||||
|
|
|
@ -9,8 +9,8 @@
|
|||
#--- Which library model to use uclibc/glibc
|
||||
MODEL=glibc
|
||||
|
||||
#--- The host system has grsecurity options enabled? 0(no)/1(yes)
|
||||
GRSECURITY_HOST=0
|
||||
#--- The host system has grsecurity options enabled? n0(no)/y(yes)
|
||||
GRSECURITY_HOST=n
|
||||
|
||||
#--- Unprivileged user and group name
|
||||
LUSER=hlfs
|
||||
|
@ -24,8 +24,8 @@ FSTAB=
|
|||
CONFIG=
|
||||
|
||||
# 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
|
||||
# If you have previously checked out the book from the repository
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
<xsl:param name="model" select="glibc"/>
|
||||
|
||||
<!-- 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? -->
|
||||
<xsl:param name="keymap" select="none"/>
|
||||
|
@ -31,10 +31,10 @@
|
|||
<xsl:param name="testsuite" select="1"/>
|
||||
|
||||
<!-- 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 -->
|
||||
<xsl:param name="timezone" select="GMT"/>
|
||||
|
@ -143,7 +143,7 @@
|
|||
contains(string(),'check')) and
|
||||
($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>
|
||||
<xsl:value-of select="substring-after(string(),'make')"/>
|
||||
|
@ -176,7 +176,7 @@
|
|||
<!-- grsecurity kernel in the host? -->
|
||||
<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
|
||||
contains(string(),'export LANG=')">
|
||||
|
@ -226,7 +226,7 @@
|
|||
</xsl:if>
|
||||
<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>
|
||||
<xsl:value-of select="substring-after(string(),'check')"/>
|
||||
|
@ -247,7 +247,7 @@
|
|||
<xsl:when test="$testsuite != '0'">
|
||||
<xsl:apply-templates/>
|
||||
<xsl:choose>
|
||||
<xsl:when test="$bomb-testsuite = '0'">
|
||||
<xsl:when test="$bomb-testsuite = 'n'">
|
||||
<xsl:text> >> $TEST_LOG 2>&1 || true
</xsl:text>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
|
@ -263,7 +263,7 @@
|
|||
<xsl:when test="$testsuite != '0'">
|
||||
<xsl:value-of select="substring-before(string(),'> glibc-')"/>
|
||||
<xsl:choose>
|
||||
<xsl:when test="$bomb-testsuite = '0'">
|
||||
<xsl:when test="$bomb-testsuite = 'n'">
|
||||
<xsl:text> >> $TEST_LOG 2>&1 || true
</xsl:text>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
|
|
|
@ -175,7 +175,7 @@ chapter5_Makefiles() { # Bootstrap or temptools phase
|
|||
# Nothing interestin in this script
|
||||
*introduction* ) continue ;;
|
||||
# Test if the stripping phase must be skipped
|
||||
*stripping* ) [[ "$STRIP" = "0" ]] && continue ;;
|
||||
*stripping* ) [[ "$STRIP" = "n" ]] && continue ;;
|
||||
*) ;;
|
||||
esac
|
||||
|
||||
|
@ -287,7 +287,7 @@ chapter6_Makefiles() { # sysroot or chroot build phase
|
|||
# dependencies and target creation.
|
||||
*chroot* ) continue ;;
|
||||
# Test if the stripping phase must be skipped
|
||||
*-stripping* ) [[ "$STRIP" = "0" ]] && continue ;;
|
||||
*-stripping* ) [[ "$STRIP" = "n" ]] && continue ;;
|
||||
esac
|
||||
|
||||
# Grab the name of the target
|
||||
|
@ -465,7 +465,7 @@ EOF
|
|||
done # for file in chapter07/*
|
||||
|
||||
# Add SBU-disk_usage report target if required
|
||||
if [[ "$REPORT" = "1" ]] ; then wrt_report ; fi
|
||||
if [[ "$REPORT" = "y" ]] ; then wrt_report ; fi
|
||||
}
|
||||
|
||||
|
||||
|
@ -482,7 +482,7 @@ build_Makefile() { # Construct a Makefile from the book scripts
|
|||
chapter5_Makefiles
|
||||
chapter6_Makefiles
|
||||
# Add the iterations targets, if needed
|
||||
[[ "$COMPARE" != "0" ]] && wrt_compare_targets
|
||||
[[ "$COMPARE" = "y" ]] && wrt_compare_targets
|
||||
chapter7_Makefiles
|
||||
|
||||
# Add a header, some variables and include the function file
|
||||
|
|
|
@ -18,8 +18,8 @@ FSTAB=
|
|||
CONFIG=
|
||||
|
||||
# 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
|
||||
# If you have previously checked out the book from the repository
|
||||
|
|
16
LFS/lfs.xsl
16
LFS/lfs.xsl
|
@ -22,13 +22,13 @@
|
|||
<xsl:param name="testsuite" select="1"/>
|
||||
|
||||
<!-- 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 -->
|
||||
<xsl:param name="timezone" select="GMT"/>
|
||||
|
@ -90,7 +90,7 @@
|
|||
</xsl:choose>
|
||||
<xsl:if test="sect2[@role='installation']">
|
||||
<xsl:text>cd $PKGDIR
</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
</xsl:text>
|
||||
</xsl:if>
|
||||
</xsl:if>
|
||||
|
@ -117,7 +117,7 @@
|
|||
ancestor::chapter[@id='chapter-building-system']) 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>
|
||||
<xsl:value-of select="substring-after(string(),'make')"/>
|
||||
|
@ -181,7 +181,7 @@
|
|||
</xsl:if>
|
||||
<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>
|
||||
<xsl:value-of select="substring-after(string(),'check')"/>
|
||||
|
@ -204,7 +204,7 @@
|
|||
ancestor::chapter[@id='chapter-building-system']) or
|
||||
$testsuite = '3'">
|
||||
<xsl:choose>
|
||||
<xsl:when test="$bomb-testsuite = '0'">
|
||||
<xsl:when test="$bomb-testsuite = 'n'">
|
||||
<xsl:text>make -k check >> $TEST_LOG 2>&1 || true
</xsl:text>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
|
|
|
@ -79,7 +79,7 @@ chapter5_Makefiles() {
|
|||
*tcl) [[ "${TEST}" = "0" ]] && continue ;;
|
||||
*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 ;;
|
||||
esac
|
||||
|
@ -176,7 +176,7 @@ chapter6_Makefiles() {
|
|||
# dependencies and target creation.
|
||||
case "${this_script}" in
|
||||
*chroot) continue ;;
|
||||
*stripping*) [[ "${STRIP}" = "0" ]] && continue ;;
|
||||
*stripping*) [[ "${STRIP}" = "n" ]] && continue ;;
|
||||
esac
|
||||
|
||||
# Grab the name of the target
|
||||
|
@ -334,7 +334,7 @@ chapter789_Makefiles() {
|
|||
done # for file in chapter0{7,8,9}/*
|
||||
|
||||
# Add SBU-disk_usage report target if required
|
||||
if [[ "$REPORT" = "1" ]] ; then wrt_report ; fi
|
||||
if [[ "$REPORT" = "y" ]] ; then wrt_report ; fi
|
||||
}
|
||||
|
||||
|
||||
|
@ -351,7 +351,7 @@ build_Makefile() {
|
|||
chapter5_Makefiles
|
||||
chapter6_Makefiles
|
||||
# Add the iterations targets, if needed
|
||||
[[ "$COMPARE" != "0" ]] && wrt_compare_targets
|
||||
[[ "$COMPARE" = "y" ]] && wrt_compare_targets
|
||||
chapter789_Makefiles
|
||||
|
||||
|
||||
|
|
1
Makefile
1
Makefile
|
@ -7,6 +7,7 @@ CONFIG_CONFIG_IN = Config.in
|
|||
CONFIG = menu
|
||||
|
||||
all: menuconfig
|
||||
@clear
|
||||
@touch using_menuconfig
|
||||
@`grep RUN_ME configuration | sed -e 's@RUN_ME=\"@@' -e 's@\"@@' ` || rm -f using_menuconfig
|
||||
@rm -f using_menuconfig
|
||||
|
|
|
@ -572,7 +572,7 @@ EOF
|
|||
run_make() { #
|
||||
#----------------------------#
|
||||
# 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
|
||||
echo "You must be logged in as root to successfully build the system."
|
||||
|
@ -592,7 +592,7 @@ run_make() { #
|
|||
clean_builddir() { #
|
||||
#----------------------------#
|
||||
# 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
|
||||
echo "You must be logged in as root to clean the build directory."
|
||||
|
@ -705,7 +705,7 @@ extract_commands() { #
|
|||
--stringparam timezone $TIMEZONE \
|
||||
--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
|
||||
;;
|
||||
|
||||
|
@ -717,7 +717,7 @@ extract_commands() { #
|
|||
--stringparam timezone $TIMEZONE \
|
||||
--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
|
||||
;;
|
||||
hlfs)
|
||||
|
@ -731,7 +731,7 @@ extract_commands() { #
|
|||
--stringparam page $PAGE \
|
||||
--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
|
||||
;;
|
||||
|
@ -795,7 +795,7 @@ get_sources() { # Download file, write name to MISSING_FILES.DMP if
|
|||
local IFS line URL1 URL2 FILE BOOKMD5 MD5 HAVEMD5 fromARCHIVE
|
||||
|
||||
# Test if the packages must be downloaded
|
||||
[ ! "$GETPKG" = "1" ] && return
|
||||
[ ! "$GETPKG" = "y" ] && return
|
||||
|
||||
gs_wrt_message(){
|
||||
echo "${RED}$1${OFF}"
|
||||
|
@ -825,7 +825,7 @@ get_sources() { # Download file, write name to MISSING_FILES.DMP if
|
|||
;;
|
||||
*linux/linux-* )
|
||||
[[ -z "$CONFIG" ]] && [[ -z "$BOOT_CONFIG" ]] && \
|
||||
[[ "$GETKERNEL" = "0" ]] && continue
|
||||
[[ "$GETKERNEL" = "n" ]] && continue
|
||||
;;
|
||||
esac
|
||||
|
||||
|
@ -907,7 +907,7 @@ get_sources() { # Download file, write name to MISSING_FILES.DMP if
|
|||
echo -e "\n\n${tab_}${RED} One or more files were not retrieved or have bad MD5SUMS.\n${tab_} Check ${L_arrow}$BUILDDIR/sources/MISSING_FILES.DMP${R_arrow} for names ${OFF}\n"
|
||||
# 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
|
||||
}
|
||||
|
||||
|
|
|
@ -11,18 +11,18 @@ declare -r LOG=000-masterscript.log
|
|||
#--- Mount point for the build
|
||||
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.
|
||||
SRC_ARCHIVE=$SRC_ARCHIVE
|
||||
|
@ -32,8 +32,8 @@ SRC_ARCHIVE=$SRC_ARCHIVE
|
|||
SERVER=ftp://ftp.lfs-matrix.net
|
||||
|
||||
#=== 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]
|
||||
# 0 = no optimization
|
||||
|
@ -52,12 +52,12 @@ OPTIMIZE=0
|
|||
TEST=1
|
||||
|
||||
#--- 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
|
||||
PAGE=letter
|
||||
|
@ -65,8 +65,8 @@ PAGE=letter
|
|||
#--- set default timezone.
|
||||
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
|
||||
LANG=$LANG
|
||||
|
@ -79,17 +79,17 @@ LC_ALL=$LC_ALL # (not used in LFS)
|
|||
KEYMAP=none
|
||||
|
||||
#=== 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 ====
|
||||
# Don't edit it unless you know what you are doing
|
||||
|
|
|
@ -54,7 +54,7 @@ wrt_compare_work() { #
|
|||
local DEST_TOPDIR=$BUILDDIR/${SCRIPT_ROOT}
|
||||
fi
|
||||
|
||||
if [[ "$RUN_ICA" = "1" ]] ; then
|
||||
if [[ "$RUN_ICA" = "y" ]] ; then
|
||||
local DEST_ICA=$DEST_TOPDIR/ICA && \
|
||||
(
|
||||
cat << EOF
|
||||
|
@ -67,7 +67,7 @@ EOF
|
|||
fi
|
||||
fi
|
||||
|
||||
if [[ "$RUN_FARCE" = "1" ]] ; then
|
||||
if [[ "$RUN_FARCE" = "y" ]] ; then
|
||||
local DEST_FARCE=$DEST_TOPDIR/farce && \
|
||||
(
|
||||
cat << EOF
|
||||
|
|
|
@ -1,13 +1,15 @@
|
|||
# $Id$
|
||||
|
||||
declare -r dotSTR=".................."
|
||||
|
||||
#----------------------------#
|
||||
validate_target() { #
|
||||
#----------------------------#
|
||||
local -r ERROR_MSG_pt1='The variable \"${L_arrow}TARGET${R_arrow}\" value ${L_arrow}${BOLD}${TARGET}${R_arrow} is invalid for the ${L_arrow}${BOLD}${ARCH}${R_arrow} architecture'
|
||||
local -r ERROR_MSG_pt2=' check the config file ${BOLD}${GREEN}\<$(echo $PROGNAME | tr [a-z] [A-Z])/config\> or \<common/config\>${OFF}'
|
||||
|
||||
local -r PARAM_VALS='TARGET: ${L_arrow}${BOLD}${TARGET}${OFF}${R_arrow}'
|
||||
local -r PARAM_VALS2='TARGET32: ${L_arrow}${BOLD}${TARGET32}${OFF}${R_arrow}'
|
||||
local -r PARAM_VALS='TARGET${dotSTR:6} ${L_arrow}${BOLD}${TARGET}${OFF}${R_arrow}'
|
||||
local -r PARAM_VALS2='TARGET32${dotSTR:8} ${L_arrow}${BOLD}${TARGET32}${OFF}${R_arrow}'
|
||||
|
||||
write_error_and_die() {
|
||||
echo -e "\n${DD_BORDER}"
|
||||
|
@ -93,7 +95,7 @@ inline_doc
|
|||
|
||||
local -r ERROR_MSG_pt1='The variable \"${L_arrow}${config_param}${R_arrow}\" value ${L_arrow}${BOLD}${!config_param}${R_arrow} is invalid,'
|
||||
local -r ERROR_MSG_pt2=' check the config file ${BOLD}${GREEN}\<$(echo $PROGNAME | tr [a-z] [A-Z])/config\> or \<common/config\>${OFF}'
|
||||
local -r PARAM_VALS='${config_param}: ${L_arrow}${BOLD}${!config_param}${OFF}${R_arrow}'
|
||||
local -r PARAM_VALS='${config_param}${dotSTR:${#config_param}} ${L_arrow}${BOLD}${!config_param}${OFF}${R_arrow}'
|
||||
|
||||
local PARAM_LIST=
|
||||
local config_param
|
||||
|
@ -174,26 +176,26 @@ inline_doc
|
|||
TIMEZONE) echo -e "`eval echo $PARAM_VALS`" ;;
|
||||
|
||||
# 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
|
||||
else
|
||||
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
|
||||
echo "Edit /common/config and set ${L_arrow}${BOLD}RUN_ICA${R_arrow} and/or ${L_arrow}${BOLD}RUN_FARCE${R_arrow} to the required values" >&2
|
||||
|
@ -201,14 +203,14 @@ inline_doc
|
|||
exit 1
|
||||
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" ;;
|
||||
METHOD) validate_against_str "xchrootx xbootx" ;;
|
||||
|
@ -220,7 +222,7 @@ inline_doc
|
|||
LGROUP) echo -e "`eval echo $PARAM_VALS`"
|
||||
[[ "${!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
|
||||
BOOK) if [[ "${WC}" = "1" ]] ; then
|
||||
|
@ -232,7 +234,7 @@ inline_doc
|
|||
# Validate directories, testable states:
|
||||
# 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
|
||||
[[ "xx x/x" =~ "x${!config_param}x" ]] &&
|
||||
|
|
216
master.sh
216
master.sh
|
@ -46,27 +46,6 @@ fi
|
|||
MODULE_CONFIG=$PACKAGE_DIR/config
|
||||
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
|
||||
[[ $VERBOSITY > 0 ]] && echo -n "Loading config params from <configuration>..."
|
||||
|
@ -84,7 +63,13 @@ if [[ -e using_menuconfig ]]; then
|
|||
ICALOGDIR=$LOGDIR/ICA
|
||||
#--- 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
|
||||
case $BRANCH_ID in
|
||||
dev* | SVN | trunk )
|
||||
|
@ -112,8 +97,52 @@ if [[ -e using_menuconfig ]]; then
|
|||
;;
|
||||
esac
|
||||
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_}"
|
||||
|
||||
|
||||
#===========================================================
|
||||
# If the var BOOK contains something then, maybe, it points
|
||||
# to a working doc.. set WC=1, else 'null'
|
||||
|
@ -190,7 +219,7 @@ while test $# -gt 0 ; do
|
|||
esac
|
||||
;;
|
||||
|
||||
--get-packages | -G ) GETPKG=1 ;;
|
||||
--get-packages | -G ) GETPKG=y ;;
|
||||
|
||||
--help | -h ) usage | more && exit ;;
|
||||
|
||||
|
@ -267,18 +296,9 @@ while test $# -gt 0 ; do
|
|||
test $# = 1 && eval "$exit_missing_arg"
|
||||
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."
|
||||
exit 1
|
||||
|
@ -316,88 +336,40 @@ while test $# -gt 0 ; do
|
|||
--arch | -A )
|
||||
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,6 +419,7 @@ while test $# -gt 0 ; do
|
|||
shift
|
||||
done
|
||||
|
||||
|
||||
#===================================================
|
||||
# Set the document location...
|
||||
# BOOK is either defined in
|
||||
|
@ -460,8 +433,7 @@ BOOK=${BOOK:=$PROGNAME-$LFSVRS}
|
|||
#===================================================
|
||||
|
||||
|
||||
# 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"
|
||||
check_version "3.0" "$BASH_VERSION" "BASH"
|
||||
|
@ -482,7 +454,7 @@ echo "${nl_}${SD_BORDER}${nl_}"
|
|||
|
||||
# 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
|
||||
[[ $? > 0 ]] && echo "$COMMON_DIR/func_compare.sh did not load.." && exit
|
||||
|
@ -537,7 +509,7 @@ if [[ "$PWD" != "$JHALFSDIR" ]]; then
|
|||
#
|
||||
[[ "$OPTIMIZE" != "0" ]] && cp optimize/opt_override $JHALFSDIR/
|
||||
#
|
||||
if [[ "$COMPARE" != "0" ]] ; then
|
||||
if [[ "$COMPARE" = "y" ]]; then
|
||||
mkdir -p $JHALFSDIR/extras
|
||||
cp extras/* $JHALFSDIR/extras
|
||||
fi
|
||||
|
@ -549,14 +521,14 @@ if [[ "$PWD" != "$JHALFSDIR" ]]; then
|
|||
popd 1> /dev/null
|
||||
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
|
||||
# This file will be used to create the REPORT header
|
||||
validate_config > $JHALFSDIR/jhalfs.config
|
||||
fi
|
||||
#
|
||||
[[ "$GETPKG" = "1" ]] && cp $COMMON_DIR/urls.xsl $JHALFSDIR/
|
||||
[[ "$GETPKG" = "y" ]] && cp $COMMON_DIR/urls.xsl $JHALFSDIR/
|
||||
#
|
||||
cp $COMMON_DIR/packages.xsl $JHALFSDIR/
|
||||
#
|
||||
|
|
Reference in a new issue