[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lmi-commits] [lmi] master 67d4657 5/9: Fix defect introduced 20190420T2
From: |
Greg Chicares |
Subject: |
[lmi-commits] [lmi] master 67d4657 5/9: Fix defect introduced 20190420T2117: non-minimal $PATH |
Date: |
Sat, 18 May 2019 14:50:02 -0400 (EDT) |
branch: master
commit 67d4657088a8e86980935473d250a77eacda3961
Author: Gregory W. Chicares <address@hidden>
Commit: Gregory W. Chicares <address@hidden>
Fix defect introduced 20190420T2117: non-minimal $PATH
Prior to commit 7ea51651e7a4, this block of (pseudo)code was correct:
# a minimal $PATH had already been set long before
{
run commands that require only a minimal $PATH
add lmi runtime paths to minimal $PATH
run commands that require lmi runtime paths
}
Commit 7ea51651e7a4 wrapped that block in a for-loop, rendering it
incorrect: $PATH was minimal, as intended, only for the first iteration
of the loop.
Anyone who doesn't believe that $PATH should contain nothing more than
is required also might not believe this matters. But proof is a higher
standard than belief.
---
install_msw.sh | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/install_msw.sh b/install_msw.sh
index 285545e..275da78 100755
--- a/install_msw.sh
+++ b/install_msw.sh
@@ -199,6 +199,10 @@ export LMI_TRIPLET
#for LMI_TRIPLET in i686-w64-mingw32 ;
for LMI_TRIPLET in x86_64-w64-mingw32 i686-w64-mingw32 ;
do
+ # Set a minimal path for makefiles and scripts that are
+ # designed to be independent of lmi's runtime path.
+ export PATH="$minimal_path"
+
# For Cygwin, install and use this msw-native compiler.
# Install it for other build types, too, even if only for
# validating the installation procedure.
@@ -219,6 +223,7 @@ do
find /cache_for_lmi/downloads -type f | xargs md5sum
+ # Source this script only for commands that depend upon it.
. ./set_toolchain.sh
make $coefficiency --output-sync=recurse wx_config_check
- [lmi-commits] [lmi] master updated (f2caa81 -> e0988be), Greg Chicares, 2019/05/18
- [lmi-commits] [lmi] master 210257a 7/9: Source a script in a makefile, Greg Chicares, 2019/05/18
- [lmi-commits] [lmi] master e0988be 9/9: Prefer xz to bzip2, Greg Chicares, 2019/05/18
- [lmi-commits] [lmi] master 7ea9aff 3/9: Import a terminal-tab setup script from branch odd/multiarch, Greg Chicares, 2019/05/18
- [lmi-commits] [lmi] master f28084a 6/9: Prepare to "source" a script in a makefile, Greg Chicares, 2019/05/18
- [lmi-commits] [lmi] master 8cb87e1 8/9: Remove redundant duplication, Greg Chicares, 2019/05/18
- [lmi-commits] [lmi] master 67d4657 5/9: Fix defect introduced 20190420T2117: non-minimal $PATH,
Greg Chicares <=
- [lmi-commits] [lmi] master f52f6e1 4/9: Invoke 'set_toolchain.sh' instead of duplicating parts of it, Greg Chicares, 2019/05/18
- [lmi-commits] [lmi] master e2e8d43 2/9: Adapt imported script to current directory structure, Greg Chicares, 2019/05/18
- [lmi-commits] [lmi] master b03530f 1/9: Improve documentation, Greg Chicares, 2019/05/18