Add the possibility to install BLFS tools to a running LFS from the jhalfs
menu: - Add the possibility to choose BOOK_BLFS from menu. That hides all the irrelevant parameters - Adapt install-blfs-tools.sh - Change slightly mconf.c so that there is a better alignement in menus
This commit is contained in:
parent
18567e96ff
commit
e5d44f5f1f
3 changed files with 1040 additions and 1006 deletions
353
Config.in
353
Config.in
|
@ -1,29 +1,42 @@
|
|||
menu "--- BOOK Settings"
|
||||
menu "BOOK Settings"
|
||||
|
||||
#--- BOOK/script
|
||||
choice
|
||||
prompt "Use BOOK"
|
||||
default BOOK_LFS
|
||||
help
|
||||
#-- Select the BOOK/Build style you wish to configure.
|
||||
Select the book where build instructions are retrieved.
|
||||
|
||||
config BOOK_LFS
|
||||
bool "Linux From Scratch System V"
|
||||
help
|
||||
Set up the tools to build LFS with Sys V init.
|
||||
|
||||
config BOOK_LFS_SYSD
|
||||
bool "Linux From Scratch systemd"
|
||||
help
|
||||
Set up the tools to build LFS with systemd init.
|
||||
|
||||
config BOOK_CLFS
|
||||
bool "Cross-Compiled Linux From Scratch"
|
||||
help
|
||||
Set up the tools to build CLFS.
|
||||
|
||||
config BOOK_CLFS2
|
||||
bool "Cross-Compiled Linux From Scratch (Sysroot method)"
|
||||
help
|
||||
Set up the tools to build CLFS by the sysroot method.
|
||||
|
||||
config BOOK_CLFS3
|
||||
bool "Cross-Compiled Linux From Scratch (Embedded Systems)"
|
||||
help
|
||||
Set up the tools to build CLFS with tools for embedded systems.
|
||||
|
||||
# config BOOK_HLFS
|
||||
# bool "Hardened Linux From Scratch"
|
||||
config BOOK_BLFS
|
||||
bool "Beyond Linux From Scratch (see help)"
|
||||
help
|
||||
if the (C)LFS system has already been built, install the tools
|
||||
to build BLFS packages.
|
||||
endchoice
|
||||
|
||||
config INITSYS
|
||||
|
@ -37,58 +50,61 @@ menu "--- BOOK Settings"
|
|||
default "clfs" if BOOK_CLFS
|
||||
default "clfs2" if BOOK_CLFS2
|
||||
default "clfs3" if BOOK_CLFS3
|
||||
default "hlfs" if BOOK_HLFS
|
||||
|
||||
config RUN_ME
|
||||
string
|
||||
default "./jhalfs run"
|
||||
default "./jhalfs run" if BOOK_LFS || BOOK_LFS_SYSD || BOOK_CLFS || \
|
||||
BOOK_CLFS2 || BOOK_CLFS_3
|
||||
default "./install-blfs-tools.sh auto" if BOOK_BLFS
|
||||
#--- End BOOK/script
|
||||
|
||||
#--- Book version
|
||||
choice
|
||||
prompt "Release"
|
||||
default relSVN if BOOK_LFS || BOOK_HLFS || BOOK_LFS_SYSD
|
||||
default relSVN if BOOK_LFS || BOOK_LFS_SYSD || BOOK_BLFS
|
||||
default relGIT if BOOK_CLFS || BOOK_CLFS2 || BOOK_CLFS3
|
||||
|
||||
config relSVN
|
||||
bool "SVN"
|
||||
depends on BOOK_LFS || BOOK_HLFS || BOOK_LFS_SYSD
|
||||
depends on BOOK_LFS || BOOK_BLFS || BOOK_LFS_SYSD
|
||||
help
|
||||
#-- Current development version as in trunk
|
||||
Current development version as in trunk
|
||||
|
||||
config relGIT
|
||||
bool "GIT"
|
||||
depends on BOOK_CLFS || BOOK_CLFS2 || BOOK_CLFS3
|
||||
help
|
||||
#-- Current development git master branch
|
||||
Current development git master branch
|
||||
|
||||
config WORKING_COPY
|
||||
bool "Working Copy"
|
||||
help
|
||||
#-- A local working copy
|
||||
A local working copy
|
||||
|
||||
config BRANCH
|
||||
bool "Branch or stable book" if !BOOK_CLFS2 && !BOOK_CLFS3
|
||||
help
|
||||
#-- A supported SVN/GIT branch or stable released book
|
||||
A supported SVN/GIT branch or stable released book
|
||||
endchoice
|
||||
|
||||
config BRANCH_ID
|
||||
string "Stable Version or branch (preceded by branch-)"
|
||||
string "Branch (preceded by \"branch-\"), stable Version, or tag"
|
||||
default "**EDIT ME**"
|
||||
depends BRANCH
|
||||
help
|
||||
#-- A list of valid branches and stable book IDs is available here:
|
||||
# http://wiki.linuxfromscratch.org/alfs/wiki/SupportedBooks
|
||||
# Enter branch-XXX for branch XXX, and just YYY for tag YYY or
|
||||
# stable YYY version
|
||||
A list of valid branches and stable book IDs is available at
|
||||
http://wiki.linuxfromscratch.org/alfs/wiki/SupportedBooks
|
||||
|
||||
Enter "branch-XXX" for branch XXX, or just "YYY" for stable (or tag)
|
||||
YYY version.
|
||||
|
||||
config BOOK
|
||||
string "Loc of working copy (mandatory)"
|
||||
default "**EDIT ME**"
|
||||
depends WORKING_COPY
|
||||
help
|
||||
#-- The full path to a local copy of the book XML sources
|
||||
#
|
||||
The full path to a local copy of the book XML sources
|
||||
|
||||
#--- End BOOK version
|
||||
|
||||
#--- CLFS specific params
|
||||
|
@ -97,7 +113,7 @@ menu "--- BOOK Settings"
|
|||
default ARCH_X86
|
||||
depends BOOK_CLFS || BOOK_CLFS2 || BOOK_CLFS3
|
||||
help
|
||||
#-- Choose the target system base architecture
|
||||
Choose the target system base architecture
|
||||
|
||||
config ARCH_X86
|
||||
bool "x86"
|
||||
|
@ -126,8 +142,8 @@ menu "--- BOOK Settings"
|
|||
depends BOOK_CLFS3 && ARCH_MIPS
|
||||
default PLATFORM_GENERIC
|
||||
help
|
||||
# Choose a destination platform
|
||||
# Platform specific files will be included
|
||||
Choose a destination platform
|
||||
Platform specific files will be included
|
||||
|
||||
config PLATFORM_GENERIC
|
||||
bool "Generic platform"
|
||||
|
@ -141,7 +157,7 @@ menu "--- BOOK Settings"
|
|||
depends (BOOK_CLFS && !ARCH_ALPHA) || (BOOK_CLFS3 && ARCH_MIPS)
|
||||
default DATA_32
|
||||
help
|
||||
#-- Choose the target system libraries type
|
||||
Choose the target system libraries type
|
||||
|
||||
config DATA_32
|
||||
bool "32-bit"
|
||||
|
@ -157,7 +173,7 @@ menu "--- BOOK Settings"
|
|||
prompt "Processor type"
|
||||
depends (BOOK_CLFS || BOOK_CLFS2 || BOOK_CLFS3) && ((ARCH_X86 && !(DATA_64 || DATA_MULTI)) || ARCH_MIPS || ARCH_HPPA || ARCH_ALPHA || (ARCH_SPARC && (DATA_64 || DATA_MULTI)) || (ARCH_ARM && BOOK_CLFS3))
|
||||
help
|
||||
#-- Choose the target system processor
|
||||
Choose the target system processor
|
||||
|
||||
config PROC_i486
|
||||
bool "486 Compatibles" if ARCH_X86
|
||||
|
@ -228,7 +244,7 @@ menu "--- BOOK Settings"
|
|||
depends BOOK_CLFS3 && ARCH_MIPS && DATA_64
|
||||
default ABI_64
|
||||
help
|
||||
#-- Choose the target system ABI to use
|
||||
Choose the target system ABI to use
|
||||
|
||||
config ABI_32
|
||||
bool "o32"
|
||||
|
@ -358,8 +374,9 @@ menu "--- BOOK Settings"
|
|||
prompt "Build method"
|
||||
depends BOOK_CLFS
|
||||
help
|
||||
#-- What build method should be used: a chroot jail or minimal boot system
|
||||
# Review the Cross-LFS book chap6 "TO BOOT OR CHROOT" for a full explanation.
|
||||
What build method should be used: a chroot jail or minimal boot
|
||||
system. Review the Cross-LFS book chap6 "TO BOOT OR CHROOT" for
|
||||
a full explanation.
|
||||
|
||||
config BUILD_CHROOT
|
||||
bool "chroot"
|
||||
|
@ -378,131 +395,34 @@ menu "--- BOOK Settings"
|
|||
default "***EDIT ME***"
|
||||
depends on BUILD_BOOT
|
||||
help
|
||||
#-- If METHOD=boot, location of boot-kernel config file
|
||||
# The config file will be copied to ${BUILD_DIR}/sources
|
||||
# and renamed 'bootkernel-config'
|
||||
#
|
||||
# NOTE: this setting is required
|
||||
If METHOD=boot, location of boot-kernel config file
|
||||
The config file will be copied to ${BUILD_DIR}/sources
|
||||
and renamed 'bootkernel-config'
|
||||
NOTE: this setting is required
|
||||
#--- End CLFS specific params
|
||||
|
||||
#--- HLFS specific params
|
||||
config GRSECURITY_HOST
|
||||
bool "Building on grsecurity enabled host?"
|
||||
default n
|
||||
depends on BOOK_HLFS
|
||||
help
|
||||
#-- If your build system has grsecurity patches applied
|
||||
# you MUST enable this switch.
|
||||
|
||||
choice
|
||||
prompt "Library"
|
||||
depends on BOOK_HLFS
|
||||
help
|
||||
#-- Which library model to use: uClibc/glibc
|
||||
|
||||
config LIB_GLIBC
|
||||
bool "glibc"
|
||||
|
||||
config LIB_UCLIBC
|
||||
bool "uClibc"
|
||||
endchoice
|
||||
|
||||
config MODEL
|
||||
depends on BOOK_HLFS
|
||||
string
|
||||
default "glibc" if LIB_GLIBC
|
||||
default "uclibc" if LIB_UCLIBC
|
||||
|
||||
choice
|
||||
prompt "Kernel series"
|
||||
depends on BOOK_HLFS
|
||||
help
|
||||
#-- Which kernel series to use: 2.6/2.4
|
||||
|
||||
config KERNEL_26
|
||||
bool "2.6 kernel series"
|
||||
|
||||
config KERNEL_24
|
||||
bool "2.4 kernel series"
|
||||
endchoice
|
||||
|
||||
config KERNEL
|
||||
depends on BOOK_HLFS
|
||||
string
|
||||
default "2.6" if KERNEL_26
|
||||
default "2.4" if KERNEL_24
|
||||
|
||||
#--- Custom Tools support
|
||||
config CUSTOM_TOOLS
|
||||
bool "Add custom tools support"
|
||||
default n
|
||||
help
|
||||
#--- Activating this option additional packages you create
|
||||
# will be installed after finished the xLFS system build.
|
||||
#
|
||||
#--- End Custom Tools support
|
||||
|
||||
#--- blfs-tool Support
|
||||
config BLFS_TOOL
|
||||
bool "Add blfs-tool support"
|
||||
default n
|
||||
depends on !BOOK_CLFS3
|
||||
depends on !BOOK_CLFS3 && !BOOK_BLFS
|
||||
help
|
||||
#--- Activating this option will install additional
|
||||
# packages needed to use blfs-tool when booting
|
||||
# the new system.
|
||||
#
|
||||
# The blfs-tool files will be installed under
|
||||
# $BUILD_DIR/blfs_root.
|
||||
Activating this option will install additional packages needed
|
||||
to use blfs tools after booting the new system.
|
||||
The blfs-tool files will be installed under $BUILD_DIR/blfs_root
|
||||
(see below).
|
||||
After booting the new xLFS system, but before using the blfs tools,
|
||||
you should create a user account, move the /blfs_root directory
|
||||
to that user's home, and change its ownership to that of the user.
|
||||
Also, be sure to give the user read and write access on the
|
||||
$TRACKING_DIR directory and the files that it contains.
|
||||
Don't forget to configure sudo properly on the new system.
|
||||
|
||||
# After booting the new xLFS system, but before using
|
||||
# blfs-tool, you should create a user account and
|
||||
# move the /blfs-root directory to the user's home,
|
||||
# making them the directory and files owner.
|
||||
#
|
||||
# Also, be sure to give the user read and write
|
||||
# privileges on the $TRACKING_DIR directory and
|
||||
# the files that it contains.
|
||||
#
|
||||
# Don't forget to configure sudo properly.
|
||||
|
||||
choice
|
||||
prompt "BLFS Release"
|
||||
default BLFS_SVN
|
||||
depends on BLFS_TOOL
|
||||
config BLFS_SVN
|
||||
bool "BLFS SVN"
|
||||
help
|
||||
#-- Current development version as in trunk
|
||||
|
||||
config BLFS_WORKING_COPY
|
||||
bool "BLFS working copy"
|
||||
help
|
||||
#-- A local working copy of the BLFS book.
|
||||
|
||||
config BLFS_BRANCH
|
||||
bool "BLFS Branch or stable book"
|
||||
help
|
||||
#-- A supported SVN branch or stable book release
|
||||
endchoice
|
||||
|
||||
config BLFS_WC_LOCATION
|
||||
string "Location of the local BLFS working copy (mandatory)"
|
||||
default "**EDIT ME**"
|
||||
depends on BLFS_WORKING_COPY
|
||||
help
|
||||
#-- Full path to the BLFS book working copy"
|
||||
|
||||
config BLFS_BRANCH_ID
|
||||
string "BLFS Book Version (mandatory)"
|
||||
default "**EDIT ME**"
|
||||
depends on BLFS_BRANCH
|
||||
help
|
||||
#-- A list of valid branches and stable book IDs is available here.
|
||||
# http://wiki.linuxfromscratch.org/alfs/wiki/SupportedBooks
|
||||
config DUMMY # Avoid indenting the items below
|
||||
bool
|
||||
|
||||
if BLFS_TOOL
|
||||
menu "blfs-tool dependencies"
|
||||
depends on BLFS_TOOL
|
||||
|
||||
config DEP_LIBXML
|
||||
bool "libxml2 (required)"
|
||||
|
@ -516,10 +436,6 @@ menu "--- BOOK Settings"
|
|||
bool "DocBook XML DTD (required)"
|
||||
default y
|
||||
|
||||
#config DEP_DBXSL
|
||||
#bool "DocBook XSL (required)"
|
||||
#default y
|
||||
|
||||
config DEP_LYNX
|
||||
bool "lynx (optional, for reading the generated book)"
|
||||
default y
|
||||
|
@ -536,78 +452,139 @@ menu "--- BOOK Settings"
|
|||
bool "GPM (optional, see help)"
|
||||
default n
|
||||
help
|
||||
#-- if you install gpm, it will be started
|
||||
# automatically on boot. You'll have to edit
|
||||
# /etc/sysconfig/mouse for your system
|
||||
if you install gpm, it will be started
|
||||
automatically on boot. You'll have to edit
|
||||
/etc/sysconfig/mouse for your system
|
||||
|
||||
config DEP_SVN
|
||||
bool "SVN client (optional, see help)"
|
||||
default n
|
||||
help
|
||||
#-- Subversion is needed for updating the book
|
||||
# sources. If you want ssl support, select
|
||||
# OPENSSL below.
|
||||
Subversion is needed for updating the book
|
||||
sources. If you want ssl support, select
|
||||
OPENSSL below.
|
||||
|
||||
config DEP_OPENSSL
|
||||
bool "OPENSSL (optional, see help)"
|
||||
default n
|
||||
help
|
||||
#-- selecting OPENSSL here allows to build
|
||||
# subversion with ssl support, avoiding a later
|
||||
# recompilation
|
||||
selecting OPENSSL here allows to build
|
||||
subversion with ssl support, avoiding a later
|
||||
recompilation
|
||||
|
||||
config DEP_PYTHON
|
||||
bool "PYTHON 2 (optional, see help)"
|
||||
default n
|
||||
help
|
||||
#-- selecting PYTHON 2 here allows to build
|
||||
# the libxml2 and libxslt python modules,
|
||||
# avoiding a later recompilation
|
||||
selecting PYTHON 2 here allows to build
|
||||
the libxml2 and libxslt python modules,
|
||||
avoiding a later recompilation
|
||||
|
||||
endmenu
|
||||
|
||||
choice
|
||||
prompt "BLFS Release"
|
||||
default BLFS_SVN
|
||||
|
||||
config BLFS_SVN
|
||||
bool "BLFS SVN"
|
||||
help
|
||||
Current development version as in trunk
|
||||
|
||||
config BLFS_WORKING_COPY
|
||||
bool "BLFS working copy"
|
||||
help
|
||||
A local working copy of the BLFS book.
|
||||
|
||||
config BLFS_BRANCH
|
||||
bool "BLFS Branch or stable book"
|
||||
help
|
||||
A supported SVN branch or stable book release
|
||||
endchoice
|
||||
|
||||
config BLFS_WC_LOCATION
|
||||
string "Location of the local BLFS working copy (mandatory)"
|
||||
default "**EDIT ME**"
|
||||
depends on BLFS_WORKING_COPY
|
||||
help
|
||||
Full path to the BLFS book working copy"
|
||||
|
||||
config BLFS_BRANCH_ID
|
||||
string "BLFS Book Version (mandatory)"
|
||||
default "**EDIT ME**"
|
||||
depends on BLFS_BRANCH
|
||||
help
|
||||
A list of valid branches and stable book IDs is available at
|
||||
http://wiki.linuxfromscratch.org/alfs/wiki/SupportedBooks.
|
||||
endif
|
||||
#--- End blfs-tool Support
|
||||
|
||||
#--- BLFS specific params
|
||||
#--- BLFS params (Used for installing the tools, either after a jhalfs run
|
||||
# or directly)
|
||||
config BLFS_ROOT
|
||||
string "Directory root"
|
||||
string "Root of the tools directory (see help)"
|
||||
default "/blfs_root"
|
||||
depends on BLFS_TOOL
|
||||
depends on BLFS_TOOL || BOOK_BLFS
|
||||
help
|
||||
#-- Full path to the directory where all required
|
||||
# files and scripts will be stored.
|
||||
Path to the directory where all required files and scripts
|
||||
will be stored.
|
||||
|
||||
This path must begin with a slash, and:
|
||||
- is relative to the user's HOME directory when installing the
|
||||
blfs tools on an already existing LFS system.
|
||||
- is relative to the root of the build directory (`/' in chroot)
|
||||
when adding the tools after a jhalfs run
|
||||
|
||||
CAUTION: this directory will be removed if it already exists.
|
||||
|
||||
config BLFS_XML
|
||||
string "BLFS sources directory"
|
||||
string "BLFS sources directory (internal parameter)"
|
||||
default "blfs-xml"
|
||||
depends BLFS_TOOL
|
||||
depends BLFS_TOOL || BOOK_BLFS
|
||||
help
|
||||
#-- The directory name under $BLFS_ROOT where the BLFS
|
||||
# book sources will be checkout.
|
||||
The directory name under $BLFS_ROOT where the BLFS
|
||||
book sources will be copied or checked out. Do not change that
|
||||
unless you know what you are doing...
|
||||
# End of BLFS parameters
|
||||
|
||||
#--- Custom Tools support
|
||||
config CUSTOM_TOOLS
|
||||
depends !BOOK_BLFS
|
||||
bool "Add custom tools support"
|
||||
default n
|
||||
help
|
||||
Activating this option additional packages you create
|
||||
will be installed after finished the xLFS system build.
|
||||
#--- End Custom Tools support
|
||||
|
||||
#--- This direcotry is needed for blfs tools installation and custom tools
|
||||
# As well.
|
||||
config TRACKING_DIR
|
||||
string "Installed packages database directory"
|
||||
default "/var/lib/jhalfs/BLFS"
|
||||
depends on BLFS_TOOL || CUSTOM_TOOLS
|
||||
depends on BOOK_BLFS || BLFS_TOOL || CUSTOM_TOOLS
|
||||
help
|
||||
#-- Full path to the directory where the database of
|
||||
# installed packages will be created.
|
||||
#
|
||||
# If you are installing blfs-tool on a running xLFS system
|
||||
# you MUST create this directory manually.
|
||||
#
|
||||
# If you are installing blfs-tool as part of an xLFS build
|
||||
# and/or using the customized scripts feature, you will
|
||||
# need to fix this directory's permissions after booting
|
||||
# the new system.
|
||||
#
|
||||
# Note that the user that will build the packages must
|
||||
# have read and write privileges on this directory.
|
||||
#--- End BLFS specific params
|
||||
Full path to the directory where the database of
|
||||
installed packages will be created.
|
||||
|
||||
If the blfs tools are installed on a running xLFS system,
|
||||
the user must have enough privileges to create this directory.
|
||||
It may be necessary to create the /var/lib/jhalfs directory as
|
||||
root, and make it writable by the user before running this tool.
|
||||
|
||||
If you are installing the blfs tools as part of an xLFS build
|
||||
and/or using the customized scripts feature, you will
|
||||
need to fix this directory's permissions after booting
|
||||
the new system.
|
||||
|
||||
Note that the user that will build the packages must
|
||||
have read and write access to this directory.
|
||||
|
||||
#--- End BOOK Settings
|
||||
endmenu
|
||||
|
||||
menu "--- General Settings"
|
||||
menu "General Settings"
|
||||
depends !BOOK_BLFS
|
||||
|
||||
#--- Set User Account
|
||||
config CONFIG_USER
|
||||
|
@ -726,7 +703,7 @@ menu "--- General Settings"
|
|||
|
||||
config SERVER
|
||||
string "FTP mirror"
|
||||
default "ftp://ftp.lfs-matrix.net"
|
||||
default "http://ftp.osuosl.org"
|
||||
depends GETPKG
|
||||
help
|
||||
#-- FTP mirror to download packages and patches if not found
|
||||
|
@ -747,12 +724,12 @@ menu "--- General Settings"
|
|||
#-- Clean the build directory before performing any other task.
|
||||
# The directory is cleaned only if it was populated by a
|
||||
# previous JHALFS run.
|
||||
#
|
||||
|
||||
#--- End General Settings
|
||||
endmenu
|
||||
|
||||
menu "--- Build Settings"
|
||||
menu "Build Settings"
|
||||
depends !BOOK_BLFS
|
||||
|
||||
#--- Test Suites
|
||||
config CONFIG_TESTS
|
||||
|
@ -956,7 +933,8 @@ menu "--- Build Settings"
|
|||
#--- End Build Settings
|
||||
endmenu
|
||||
|
||||
menu "--- Advanced Features"
|
||||
menu "Advanced Features"
|
||||
depends !BOOK_BLFS
|
||||
|
||||
config REPORT
|
||||
bool "Create SBU and disk usage report"
|
||||
|
@ -1113,6 +1091,7 @@ endif
|
|||
endmenu
|
||||
|
||||
config REBUILD_MAKEFILE
|
||||
depends !BOOK_BLFS
|
||||
bool "Rebuild the Makefile (see help)"
|
||||
default n
|
||||
help
|
||||
|
|
|
@ -19,6 +19,9 @@ use jhalfs, or forgot to include the jhalfs-blfs tools:
|
|||
(as user) INIT_SYSTEM=<your system> ./install-blfs-tools.sh
|
||||
2 - To install with only user privileges (default to sysv):
|
||||
TRACKING_DIR=$HOME/blfs_root/trackdir ./install-blfs-tools.sh
|
||||
|
||||
This script can also be called automatically after running make in this
|
||||
directory. The parameters will then be taken from the configuration file.
|
||||
inline_doc
|
||||
|
||||
|
||||
|
@ -45,20 +48,63 @@ declare -r nl_=$'\n'
|
|||
declare -r DD_BORDER="${BOLD}==============================================================================${OFF}"
|
||||
declare -r SD_BORDER="${BOLD}------------------------------------------------------------------------------${OFF}"
|
||||
declare -r STAR_BORDER="${BOLD}******************************************************************************${OFF}"
|
||||
declare -r dotSTR=".................." # Format display of parameters and versions
|
||||
|
||||
# bold yellow > < pair
|
||||
declare -r R_arrow=$'\e[1;33m>\e[0m'
|
||||
declare -r L_arrow=$'\e[1;33m<\e[0m'
|
||||
|
||||
VERBOSITY=1
|
||||
|
||||
# Take parameters from "configuration" if $1="auto"
|
||||
if [ "$1" = auto ]; then
|
||||
[[ $VERBOSITY > 0 ]] && echo -n "Loading configuration ... "
|
||||
source configuration
|
||||
[[ $? > 0 ]] && echo -e "\nconfiguration could not be loaded" && exit 2
|
||||
[[ $VERBOSITY > 0 ]] && echo "OK"
|
||||
fi
|
||||
|
||||
if [ "$BOOK_BLFS" = y ]; then
|
||||
## Read variables and sanity checks
|
||||
[[ "$relSVN" = y ]] && BLFS_BRANCH_ID=development
|
||||
[[ "$BRANCH" = y ]] && BLFS_BRANCH_ID=$BRANCH_ID
|
||||
[[ "$WORKING_COPY" = y ]] && BLFS_BOOK=$BOOK
|
||||
[[ "$BRANCH_ID" = "**EDIT ME**" ]] &&
|
||||
echo You have not set the book version or branch && exit 1
|
||||
[[ "$BOOK" = "**EDIT ME**" ]] &&
|
||||
echo You have not set the working copy location && exit 1
|
||||
fi
|
||||
|
||||
COMMON_DIR="common"
|
||||
# blfs-tool envars
|
||||
BLFS_TOOL='y'
|
||||
BUILDDIR=$(cd ~;pwd)
|
||||
BLFS_ROOT="${BLFS_ROOT:=/blfs_root}"
|
||||
TRACKING_DIR="${TRACKING_DIR:=/var/lib/jhalfs/BLFS}"
|
||||
INIT_SYSTEM="${INIT_SYSTEM:=sysv}"
|
||||
BLFS_BRANCH_ID=${BLFS_BRANCH_ID:=development}
|
||||
BLFS_XML=${BLFS_XML:=blfs-xml}
|
||||
|
||||
# Validate the configuration:
|
||||
PARAMS="BLFS_ROOT TRACKING_DIR INIT_SYSTEM BLFS_XML"
|
||||
if [ "$WORKING_COPY" = y ]; then
|
||||
PARAMS="$PARAMS WORKING_COPY BOOK"
|
||||
else
|
||||
PARAMS="$PARAMS BLFS_BRANCH_ID"
|
||||
fi
|
||||
# Format for displaying parameters:
|
||||
declare -r PARAM_VALS='${config_param}${dotSTR:${#config_param}} ${L_arrow}${BOLD}${!config_param}${OFF}${R_arrow}'
|
||||
|
||||
for config_param in $PARAMS; do
|
||||
echo -e "`eval echo $PARAM_VALS`"
|
||||
done
|
||||
|
||||
echo "${SD_BORDER}${nl_}"
|
||||
echo -n "Are you happy with these settings? yes/no (no): "
|
||||
read ANSWER
|
||||
if [ x$ANSWER != "xyes" ] ; then
|
||||
echo "${nl_}Rerun make and fix your settings.${nl_}"
|
||||
exit
|
||||
fi
|
||||
[[ $VERBOSITY > 0 ]] && echo "${SD_BORDER}${nl_}"
|
||||
|
||||
#*******************************************************************#
|
||||
|
@ -69,8 +115,6 @@ source $COMMON_DIR/libs/func_check_version.sh
|
|||
|
||||
[[ $VERBOSITY > 0 ]] && echo "${SD_BORDER}${nl_}"
|
||||
|
||||
# blfs-tool envars
|
||||
BLFS_BRANCH_ID=${BLFS_BRANCH_ID:=development}
|
||||
case $BLFS_BRANCH_ID in
|
||||
development ) BLFS_TREE=trunk/BOOK ;;
|
||||
branch-* ) BLFS_TREE=branches/${BLFS_BRANCH_ID#branch-} ;;
|
||||
|
@ -78,7 +122,6 @@ case $BLFS_BRANCH_ID in
|
|||
esac
|
||||
|
||||
# Check for build prerequisites.
|
||||
declare -r dotSTR=".................." # needed for proper display of versions
|
||||
echo
|
||||
check_alfs_tools
|
||||
check_blfs_tools
|
||||
|
@ -87,6 +130,7 @@ echo "${SD_BORDER}${nl_}"
|
|||
# Install the files
|
||||
[[ $VERBOSITY > 0 ]] && echo -n Populating the ${BUILDDIR}${BLFS_ROOT} directory
|
||||
[[ ! -d ${BUILDDIR}${BLFS_ROOT} ]] && mkdir -pv ${BUILDDIR}${BLFS_ROOT}
|
||||
rm -rf ${BUILDDIR}${BLFS_ROOT}/*
|
||||
cp -r BLFS/* ${BUILDDIR}${BLFS_ROOT}
|
||||
cp -r menu ${BUILDDIR}${BLFS_ROOT}
|
||||
cp $COMMON_DIR/progress_bar.sh ${BUILDDIR}${BLFS_ROOT}
|
||||
|
@ -101,7 +145,7 @@ rm -rf ${BUILDDIR}${BLFS_ROOT}/xsl/.svn
|
|||
rm -rf ${BUILDDIR}${BLFS_ROOT}/menu/.svn
|
||||
rm -rf ${BUILDDIR}${BLFS_ROOT}/menu/lxdialog/.svn
|
||||
# We do not want to keep an old version of the book:
|
||||
rm -rf ${BUILDDIR}${BLFS_ROOT}/blfs-xml
|
||||
rm -rf ${BUILDDIR}${BLFS_ROOT}/$BLFS_XML
|
||||
|
||||
# Set some harcoded envars to their proper values
|
||||
sed -i s@tracking-dir@$TRACKING_DIR@ \
|
||||
|
@ -114,10 +158,17 @@ sed -i s@tracking-dir@$TRACKING_DIR@ \
|
|||
mkdir -p $TRACKING_DIR
|
||||
[[ $VERBOSITY > 0 ]] && echo "... OK"
|
||||
|
||||
[[ $VERBOSITY > 0 ]] && echo "Downloading and validating the book (may take some time)"
|
||||
[[ $VERBOSITY > 0 ]] &&
|
||||
echo "Retrieving and validating the book (may take some time)"
|
||||
|
||||
[[ -z "$BLFS_BOOK" ]] ||
|
||||
[[ $BLFS_BOOK = $BUILDDIR$BLFS_ROOT/$BLFS_XML ]] ||
|
||||
cp -a $BLFS_BOOK $BUILDDIR$BLFS_ROOT/$BLFS_XML
|
||||
|
||||
make -j1 -C $BUILDDIR$BLFS_ROOT \
|
||||
TRACKING_DIR=$TRACKING_DIR \
|
||||
REV=$INIT_SYSTEM \
|
||||
BLFS_XML=$BUILDDIR$BLFS_ROOT/$BLFS_XML \
|
||||
SVN=svn://svn.linuxfromscratch.org/BLFS/$BLFS_TREE \
|
||||
$BUILDDIR$BLFS_ROOT/packages.xml
|
||||
[[ $VERBOSITY > 0 ]] && echo "... OK"
|
||||
|
|
12
menu/mconf.c
12
menu/mconf.c
|
@ -473,7 +473,8 @@ static void build_conf(struct menu *menu)
|
|||
struct symbol *sym;
|
||||
struct property *prop;
|
||||
struct menu *child;
|
||||
int type, tmp, doint = 2;
|
||||
/* int type, tmp, doint = 2; */
|
||||
int type, doint = 2;
|
||||
tristate val;
|
||||
char ch;
|
||||
|
||||
|
@ -595,11 +596,14 @@ static void build_conf(struct menu *menu)
|
|||
break;
|
||||
default:
|
||||
cprint_tag("s%p", menu);
|
||||
tmp = cprint_name("(%s)", sym_get_string_value(sym));
|
||||
/* tmp = cprint_name("(%s)", sym_get_string_value(sym));
|
||||
tmp = indent - tmp + 4;
|
||||
if (tmp < 0)
|
||||
tmp = 0;
|
||||
cprint_name("%*c%s%s", tmp, ' ', menu_get_prompt(menu),
|
||||
tmp = 0; */
|
||||
cprint_name(" %*c%s (%s)%s",
|
||||
indent+1, ' ',
|
||||
menu_get_prompt(menu),
|
||||
sym_get_string_value(sym),
|
||||
(sym_has_value(sym) || !sym_is_changable(sym)) ?
|
||||
"" : " (NEW)");
|
||||
goto conf_childs;
|
||||
|
|
Reference in a new issue