diff options
| author | Harini0924 <79345568+Harini0924@users.noreply.github.com> | 2024-08-26 15:56:22 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-08-26 15:56:22 -0700 |
| commit | 9007864f72d07ee26d710fc10b1f918c628affa0 (patch) | |
| tree | 55d0da199361089d4f679058556051260c876114 /lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.cpp | |
| parent | 82579f9d9ac575c4e6609899981e7897932a3576 (diff) | |
| download | llvm-9007864f72d07ee26d710fc10b1f918c628affa0.zip llvm-9007864f72d07ee26d710fc10b1f918c628affa0.tar.gz llvm-9007864f72d07ee26d710fc10b1f918c628affa0.tar.bz2 | |
[compiler-rt][tests] Fix env command not found errors with lit internal shell (#105879)
This patch addresses an issue where the `LIBFUZZER_OOP_TARGET`
environment variable was causing "command not found" errors in the
`out-of-process-fuzz` test when running with the
`LIT_USE_INTERNAL_SHELL=1 ninja check-compiler-rt` command.
Error displayed:
```
# .---command stderr------------
# | 'LIBFUZZER_OOP_TARGET=./oop-target > /dev/null 2>&1 ': command not found
# `-----------------------------
# error: command failed with exit status: 127
```
The lit internal shell was not correctly interpreting the command
redirection and environment variable assignment in a single line,
leading to the failure.
In this patch the test was updated to use `env` for setting the
`LIBFUZZER_OOP_TARGET` environment variable. This change ensures that
the command is properly recognized and executed within the internal
shell environment. The output of the fuzzing process was captured in a
temporary file instead of redirecting it directly to `/dev/null`,
allowing for more controlled output management. Finally, the results
from running `oop-target` on all corpus files are now appended to ensure
that every output is thoroughly checked by FileCheck. The `RUN` line
sets the `LIBFUZZER_OOP_TARGET` using `env`, runs the `oop-fuzzer` with
specific options and uses the seed files from `OOP_CORPUS/seed` to
initiate the fuzzing process.
This change is relevant for enabling the lit internal shell by default,
as outlined in [[RFC] Enabling the Lit Internal Shell by
Default](https://discourse.llvm.org/t/rfc-enabling-the-lit-internal-shell-by-default/80179)
Diffstat (limited to 'lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.cpp')
0 files changed, 0 insertions, 0 deletions
