Windows line endings cause errors in MSYS
beta opened this issue · 3 comments
beta commented
When running konanc
(instead of konanc.bat
) in MSYS, it throws a lot of errors when executing this code:
for VAR in `cat "${KONAN_HOME}/tools/env_blacklist"`; do
unset $VAR
done
The errors are:
': not a valid identifierows-0.7/bin/run_konan: line 76: unset: `ADDITIONAL_SDKS
': not a valid identifierows-0.7/bin/run_konan: line 76: unset: `APPLICATION_EXTENSION_API_ONLY
': not a valid identifierows-0.7/bin/run_konan: line 76: unset: `ARCHS
': not a valid identifierows-0.7/bin/run_konan: line 76: unset: `ARCHS_STANDARD
': not a valid identifierows-0.7/bin/run_konan: line 76: unset: `ARCHS_STANDARD_32_64_BIT
': not a valid identifierows-0.7/bin/run_konan: line 76: unset: `ARCHS_STANDARD_32_BIT
': not a valid identifierows-0.7/bin/run_konan: line 76: unset: `ARCHS_STANDARD_64_BIT
': not a valid identifierows-0.7/bin/run_konan: line 76: unset: `ARCHS_STANDARD_INCLUDING_64_BIT
': not a valid identifierows-0.7/bin/run_konan: line 76: unset: `ARCHS_UNIVERSAL_IPHONE_OS
': not a valid identifierows-0.7/bin/run_konan: line 76: unset: `CLANG_ANALYZER_NONNULL
...
IMHO this is related to the line endings of file env_blacklist
. After I switched from Windows line endings (CRLF) to Unix endings (LF only), the errors are gone.
beta commented
It still doesn't work with CRLF endings, throwing me the same errors.
olonho commented
Oops, please try this way.