We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent fc0e7d4 commit 152a918Copy full SHA for 152a918
fuzzing/private/oss_fuzz/package.bzl
@@ -29,8 +29,11 @@ def _oss_fuzz_package_impl(ctx):
29
outputs = [output_archive],
30
inputs = action_inputs,
31
command = """
32
- declare -r STAGING_DIR="$(pwd)/{output}.staging"
33
- mkdir "$STAGING_DIR"
+ declare -r STAGING_DIR="$(mktemp --directory -t oss-fuzz-pkg.XXXXXXXXXX)"
+ function cleanup() {{
34
+ rm -rf "$STAGING_DIR"
35
+ }}
36
+ trap cleanup EXIT
37
ln -s "$(pwd)/{binary_path}" "$STAGING_DIR/{base_name}"
38
if [[ -n "{corpus_dir}" ]]; then
39
pushd "{corpus_dir}" >/dev/null
0 commit comments