fix: use double quote for LDFLAGS/CPPFLAGS

This commit is contained in:
Amin Yahyaabadi 2022-05-17 13:19:04 -07:00
parent e9ad632584
commit 3526010570
4 changed files with 6 additions and 6 deletions

2
dist/setup_cpp.js vendored

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -310,8 +310,8 @@ export async function activateLLVM(directory: string, versionGiven: string) {
addEnv("DYLD_LIBRARY_PATH", `${lib}${path.delimiter}${dyld}`),
// compiler flags
addEnv("LDFLAGS", `-L'${directory}/lib'`),
addEnv("CPPFLAGS", `-I'${directory}/include'`),
addEnv("LDFLAGS", `-L"${directory}/lib"`),
addEnv("CPPFLAGS", `-I"${directory}/include"`),
// compiler paths
addEnv("CC", addBinExtension(`${directory}/bin/clang`)),

View File

@ -54,8 +54,8 @@ async function addEnvSystem(name: string, valGiven: string | undefined) {
switch (process.platform) {
case "win32": {
// We do not use `execa.sync(`setx PATH "${path};%PATH%"`)` because of its character limit
await execPowershell(`[Environment]::SetEnvironmentVariable("${name}", "${val}", "User")`)
info(`${name}="${val}" was set in the environment.`)
await execPowershell(`[Environment]::SetEnvironmentVariable('${name}', '${val}', "User")`)
info(`${name}='${val}' was set in the environment.`)
return
}
case "linux":