mirror of
https://github.com/vincentmli/bpfire.git
synced 2026-04-28 11:43:25 +02:00
make.sh: Tidy up LOGFILE
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
This commit is contained in:
31
make.sh
31
make.sh
@@ -990,8 +990,7 @@ buildtoolchain() {
|
|||||||
exiterror "Could not create ${TOOLS_DIR} symbolic link"
|
exiterror "Could not create ${TOOLS_DIR} symbolic link"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
LOGFILE="$BASEDIR/log/_build.toolchain.log"
|
local LOGFILE="$BASEDIR/log/_build.toolchain.log"
|
||||||
export LOGFILE
|
|
||||||
|
|
||||||
lfsmake1 stage1
|
lfsmake1 stage1
|
||||||
lfsmake1 binutils PASS=1
|
lfsmake1 binutils PASS=1
|
||||||
@@ -1037,8 +1036,8 @@ buildtoolchain() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
buildbase() {
|
buildbase() {
|
||||||
LOGFILE="$BASEDIR/log/_build.base.log"
|
local LOGFILE="$BASEDIR/log/_build.base.log"
|
||||||
export LOGFILE
|
|
||||||
lfsmake2 stage2
|
lfsmake2 stage2
|
||||||
lfsmake2 linux KCFG="-headers"
|
lfsmake2 linux KCFG="-headers"
|
||||||
lfsmake2 man-pages
|
lfsmake2 man-pages
|
||||||
@@ -1111,8 +1110,8 @@ buildbase() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
buildipfire() {
|
buildipfire() {
|
||||||
LOGFILE="$BASEDIR/log/_build.ipfire.log"
|
local LOGFILE="$BASEDIR/log/_build.ipfire.log"
|
||||||
export LOGFILE
|
|
||||||
lfsmake2 configroot
|
lfsmake2 configroot
|
||||||
lfsmake2 initscripts
|
lfsmake2 initscripts
|
||||||
lfsmake2 backup
|
lfsmake2 backup
|
||||||
@@ -1746,8 +1745,8 @@ buildipfire() {
|
|||||||
|
|
||||||
buildinstaller() {
|
buildinstaller() {
|
||||||
# Run installer scripts one by one
|
# Run installer scripts one by one
|
||||||
LOGFILE="$BASEDIR/log/_build.installer.log"
|
local LOGFILE="$BASEDIR/log/_build.installer.log"
|
||||||
export LOGFILE
|
|
||||||
lfsmake2 memtest
|
lfsmake2 memtest
|
||||||
lfsmake2 installer
|
lfsmake2 installer
|
||||||
# use toolchain bash for chroot to strip
|
# use toolchain bash for chroot to strip
|
||||||
@@ -1755,8 +1754,8 @@ buildinstaller() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
buildpackages() {
|
buildpackages() {
|
||||||
LOGFILE="$BASEDIR/log/_build.packages.log"
|
local LOGFILE="$BASEDIR/log/_build.packages.log"
|
||||||
export LOGFILE
|
|
||||||
echo "... see detailed log in _build.*.log files" >> $LOGFILE
|
echo "... see detailed log in _build.*.log files" >> $LOGFILE
|
||||||
|
|
||||||
|
|
||||||
@@ -1839,11 +1838,6 @@ exec_in_namespace() {
|
|||||||
# Set BASEDIR
|
# Set BASEDIR
|
||||||
readonly BASEDIR="$(find_base)"
|
readonly BASEDIR="$(find_base)"
|
||||||
|
|
||||||
LOGFILE=$BASEDIR/log/_build.preparation.log
|
|
||||||
export LOGFILE
|
|
||||||
DIR_CHK=$BASEDIR/cache/check
|
|
||||||
mkdir $BASEDIR/log/ 2>/dev/null
|
|
||||||
|
|
||||||
# Get some information about the host system
|
# Get some information about the host system
|
||||||
SYSTEM_PROCESSORS="$(system_processors)"
|
SYSTEM_PROCESSORS="$(system_processors)"
|
||||||
SYSTEM_MEMORY="$(system_memory)"
|
SYSTEM_MEMORY="$(system_memory)"
|
||||||
@@ -1893,6 +1887,13 @@ configure_build "${BUILD_ARCH}"
|
|||||||
# Set directories
|
# Set directories
|
||||||
readonly CCACHE_DIR="${BASEDIR}/ccache/${BUILD_ARCH}/${TOOLCHAINVER}"
|
readonly CCACHE_DIR="${BASEDIR}/ccache/${BUILD_ARCH}/${TOOLCHAINVER}"
|
||||||
readonly BUILD_DIR="${BASEDIR}/build"
|
readonly BUILD_DIR="${BASEDIR}/build"
|
||||||
|
readonly LOG_DIR="${BASEDIR}/log"
|
||||||
|
|
||||||
|
# Set the LOGFILE
|
||||||
|
LOGFILE="${LOG_DIR}/_build.preparation.log"
|
||||||
|
|
||||||
|
# Ensure the log directory exists
|
||||||
|
mkdir -p "${LOG_DIR}"
|
||||||
|
|
||||||
# See what we're supposed to do
|
# See what we're supposed to do
|
||||||
case "$1" in
|
case "$1" in
|
||||||
|
|||||||
Reference in New Issue
Block a user