mirror of
https://github.com/github/codeql-action.git
synced 2026-01-04 21:50:17 +08:00
Respect value of LD_PRELOAD given by the CLI
This commit is contained in:
@@ -212,25 +212,25 @@ export async function getCombinedTracerConfig(
|
||||
);
|
||||
}
|
||||
mainTracerConfig = concatTracerConfigs(tracedLanguageConfigs, config);
|
||||
}
|
||||
|
||||
// Add a couple more variables
|
||||
mainTracerConfig.env["ODASA_TRACER_CONFIGURATION"] = mainTracerConfig.spec;
|
||||
const codeQLDir = path.dirname(codeql.getPath());
|
||||
if (process.platform === "darwin") {
|
||||
mainTracerConfig.env["DYLD_INSERT_LIBRARIES"] = path.join(
|
||||
codeQLDir,
|
||||
"tools",
|
||||
"osx64",
|
||||
"libtrace.dylib"
|
||||
);
|
||||
} else if (process.platform !== "win32") {
|
||||
mainTracerConfig.env["LD_PRELOAD"] = path.join(
|
||||
codeQLDir,
|
||||
"tools",
|
||||
"linux64",
|
||||
"${LIB}trace.so"
|
||||
);
|
||||
// Add a couple more variables
|
||||
mainTracerConfig.env["ODASA_TRACER_CONFIGURATION"] = mainTracerConfig.spec;
|
||||
const codeQLDir = path.dirname(codeql.getPath());
|
||||
if (process.platform === "darwin") {
|
||||
mainTracerConfig.env["DYLD_INSERT_LIBRARIES"] = path.join(
|
||||
codeQLDir,
|
||||
"tools",
|
||||
"osx64",
|
||||
"libtrace.dylib"
|
||||
);
|
||||
} else if (process.platform !== "win32") {
|
||||
mainTracerConfig.env["LD_PRELOAD"] = path.join(
|
||||
codeQLDir,
|
||||
"tools",
|
||||
"linux64",
|
||||
"${LIB}trace.so"
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
// On macos it's necessary to prefix the build command with the runner executable
|
||||
|
||||
Reference in New Issue
Block a user