Make SHELL=/bin/bash a Makefile variable instead using it inside the sub-make invocations to avoid be propagated to make processes started by the actual build scripts.
This commit is contained in:
parent
dcf0e25966
commit
81f7dc1ed0
6 changed files with 26 additions and 25 deletions
|
@ -782,18 +782,18 @@ ck_UID:
|
|||
#---------------AS ROOT
|
||||
mk_SETUP:
|
||||
@\$(call echo_SU_request)
|
||||
@sudo make SHELL=/bin/bash SETUP
|
||||
@sudo make SETUP
|
||||
@touch \$@
|
||||
|
||||
#---------------AS LUSER
|
||||
mk_CROSS: mk_SETUP
|
||||
@\$(call echo_PHASE,Cross and Temporary Tools)
|
||||
@(sudo \$(SU_LUSER) "source .bashrc && cd \$(MOUNT_PT)/\$(SCRIPT_ROOT) && make SHELL=/bin/bash AS_LUSER" )
|
||||
@(sudo \$(SU_LUSER) "source .bashrc && cd \$(MOUNT_PT)/\$(SCRIPT_ROOT) && make AS_LUSER" )
|
||||
@sudo make restore-luser-env
|
||||
@touch \$@
|
||||
|
||||
mk_SUDO: mk_CROSS
|
||||
@sudo make SHELL=/bin/bash SUDO
|
||||
@sudo make SUDO
|
||||
@touch \$@
|
||||
#
|
||||
# The convoluted piece of code below is necessary to provide 'make' with a valid shell in the
|
||||
|
@ -899,18 +899,18 @@ ck_UID:
|
|||
|
||||
mk_SETUP:
|
||||
@\$(call echo_SU_request)
|
||||
@sudo make SHELL=/bin/bash SETUP
|
||||
@sudo make SETUP
|
||||
@touch \$@
|
||||
|
||||
#---------------AS LUSER
|
||||
|
||||
mk_CROSS: mk_SETUP
|
||||
@\$(call echo_PHASE,Cross Tool)
|
||||
@(sudo \$(SU_LUSER) "source .bashrc && cd \$(MOUNT_PT)/\$(SCRIPT_ROOT) && make SHELL=/bin/bash AS_LUSER" )
|
||||
@(sudo \$(SU_LUSER) "source .bashrc && cd \$(MOUNT_PT)/\$(SCRIPT_ROOT) && make AS_LUSER" )
|
||||
@touch \$@
|
||||
|
||||
mk_SUDO: mk_CROSS
|
||||
@sudo make SHELL=/bin/bash SUDO
|
||||
@sudo make SUDO
|
||||
@touch \$@
|
||||
|
||||
#---------------AS ROOT
|
||||
|
|
|
@ -437,19 +437,19 @@ ck_UID:
|
|||
|
||||
mk_SETUP:
|
||||
@\$(call echo_SU_request)
|
||||
@sudo make SHELL=/bin/bash SETUP
|
||||
@sudo make SETUP
|
||||
@touch \$@
|
||||
|
||||
mk_LUSER: mk_SETUP
|
||||
@\$(call echo_SULUSER_request)
|
||||
@(sudo \$(SU_LUSER) "source .bashrc && cd \$(MOUNT_PT)/\$(SCRIPT_ROOT) && make SHELL=/bin/bash LUSER" )
|
||||
@(sudo \$(SU_LUSER) "source .bashrc && cd \$(MOUNT_PT)/\$(SCRIPT_ROOT) && make LUSER" )
|
||||
@touch \$@
|
||||
|
||||
mk_CUSTOM_TOOLS: create-sbu_du-report
|
||||
\$(call echo_PHASE,CUSTOM_TOOLS)
|
||||
@if [ "\$(ADD_CUSTOM_TOOLS)" = "y" ]; then \\
|
||||
(sudo \$(SU_LUSER) "mkdir -p $BUILDDIR$TRACKING_DIR"); \\
|
||||
(sudo \$(SU_LUSER) "source .bashrc && cd \$(MOUNT_PT)/\$(SCRIPT_ROOT) && make SHELL=/bin/bash CUSTOM_TOOLS"); \\
|
||||
(sudo \$(SU_LUSER) "source .bashrc && cd \$(MOUNT_PT)/\$(SCRIPT_ROOT) && make CUSTOM_TOOLS"); \\
|
||||
fi;
|
||||
@touch \$@
|
||||
|
||||
|
@ -457,7 +457,7 @@ mk_BLFS_TOOL: mk_CUSTOM_TOOLS
|
|||
\$(call echo_PHASE,BLFS_TOOL)
|
||||
@if [ "\$(ADD_BLFS_TOOLS)" = "y" ]; then \\
|
||||
(sudo \$(SU_LUSER) "mkdir -p $BUILDDIR$TRACKING_DIR"); \\
|
||||
(sudo \$(SU_LUSER) "source .bashrc && cd \$(MOUNT_PT)/\$(SCRIPT_ROOT) && make SHELL=/bin/bash BLFS_TOOL"); \\
|
||||
(sudo \$(SU_LUSER) "source .bashrc && cd \$(MOUNT_PT)/\$(SCRIPT_ROOT) && make BLFS_TOOL"); \\
|
||||
fi;
|
||||
@touch \$@
|
||||
|
||||
|
@ -465,7 +465,7 @@ mk_ROOT: mk_BLFS_TOOL
|
|||
@\$(call echo_SU_request)
|
||||
@echo "$VERSION-sysroot - jhalfs build" > clfs-release && \\
|
||||
sudo mv clfs-release \$(MOUNT_PT)/etc
|
||||
@sudo make SHELL=/bin/bash ROOT
|
||||
@sudo make ROOT
|
||||
@touch \$@
|
||||
|
||||
SETUP: $host_prep
|
||||
|
|
|
@ -490,19 +490,19 @@ ck_UID:
|
|||
|
||||
mk_SETUP:
|
||||
@\$(call echo_SU_request)
|
||||
@sudo make SHELL=/bin/bash SETUP
|
||||
@sudo make SETUP
|
||||
@touch \$@
|
||||
|
||||
mk_LUSER: mk_SETUP
|
||||
@\$(call echo_SULUSER_request)
|
||||
@(sudo \$(SU_LUSER) "source .bashrc && cd \$(MOUNT_PT)/\$(SCRIPT_ROOT) && make SHELL=/bin/bash LUSER" )
|
||||
@(sudo \$(SU_LUSER) "source .bashrc && cd \$(MOUNT_PT)/\$(SCRIPT_ROOT) && make LUSER" )
|
||||
@touch \$@
|
||||
|
||||
mk_CUSTOM_TOOLS: create-sbu_du-report
|
||||
\$(call echo_PHASE,Building CUSTOM_TOOLS);
|
||||
@if [ "\$(ADD_CUSTOM_TOOLS)" = "y" ]; then \\
|
||||
(sudo \$(SU_LUSER) "mkdir -p $BUILDDIR$TRACKING_DIR"); \\
|
||||
(sudo \$(SU_LUSER) "source .bashrc && cd \$(MOUNT_PT)/\$(SCRIPT_ROOT) && make SHELL=/bin/bash CUSTOM_TOOLS"); \\
|
||||
(sudo \$(SU_LUSER) "source .bashrc && cd \$(MOUNT_PT)/\$(SCRIPT_ROOT) && make CUSTOM_TOOLS"); \\
|
||||
fi;
|
||||
@touch \$@
|
||||
|
||||
|
@ -510,7 +510,7 @@ mk_ROOT: mk_CUSTOM_TOOLS
|
|||
@\$(call echo_SU_request)
|
||||
@echo "$VERSION-embedded - jhalfs build" > clfs-release && \\
|
||||
sudo mv clfs-release \$(MOUNT_PT)/etc
|
||||
@sudo make SHELL=/bin/bash ROOT
|
||||
@sudo make ROOT
|
||||
@touch \$@
|
||||
|
||||
|
||||
|
|
|
@ -546,17 +546,17 @@ ck_UID:
|
|||
|
||||
mk_SETUP:
|
||||
@\$(call echo_SU_request)
|
||||
@sudo make SHELL=/bin/bash SETUP
|
||||
@sudo make SETUP
|
||||
@touch \$@
|
||||
|
||||
mk_LUSER: mk_SETUP
|
||||
@\$(call echo_SULUSER_request)
|
||||
@(sudo \$(SU_LUSER) "source .bashrc && cd \$(MOUNT_PT)/\$(SCRIPT_ROOT) && make SHELL=/bin/bash LUSER" )
|
||||
@(sudo \$(SU_LUSER) "source .bashrc && cd \$(MOUNT_PT)/\$(SCRIPT_ROOT) && make LUSER" )
|
||||
@sudo make restore-luser-env
|
||||
@touch \$@
|
||||
|
||||
mk_SUDO: mk_LUSER
|
||||
@sudo make SHELL=/bin/bash SUDO
|
||||
@sudo make SUDO
|
||||
@touch \$@
|
||||
|
||||
mk_CHROOT: mk_SUDO
|
||||
|
|
|
@ -424,17 +424,17 @@ ck_UID:
|
|||
|
||||
mk_SETUP:
|
||||
@\$(call echo_SU_request)
|
||||
@sudo make SHELL=/bin/bash SETUP
|
||||
@sudo make SETUP
|
||||
@touch \$@
|
||||
|
||||
mk_LUSER: mk_SETUP
|
||||
@\$(call echo_SULUSER_request)
|
||||
@( sudo \$(SU_LUSER) "source .bashrc && cd \$(MOUNT_PT)/\$(SCRIPT_ROOT) && make SHELL=/bin/bash LUSER" )
|
||||
@( sudo \$(SU_LUSER) "source .bashrc && cd \$(MOUNT_PT)/\$(SCRIPT_ROOT) && make LUSER" )
|
||||
@sudo make restore-luser-env
|
||||
@touch \$@
|
||||
|
||||
mk_SUDO: mk_LUSER
|
||||
@sudo make SHELL=/bin/bash SUDO
|
||||
@sudo make SUDO
|
||||
touch \$@
|
||||
#
|
||||
# The convoluted piece of code below is necessary to provide 'make' with a valid shell in the
|
||||
|
|
|
@ -14,6 +14,7 @@ wrt_Makefile_header() { #
|
|||
#
|
||||
# Generated on `date "+%F %X %Z"`
|
||||
|
||||
SHELL = /bin/bash
|
||||
|
||||
SRC = /sources
|
||||
MOUNT_PT = $BUILDDIR
|
||||
|
|
Reference in a new issue