mirror of
https://github.com/microsoft/onefuzz.git
synced 2025-06-18 04:38:09 +00:00
always use unix file endings when building libfuzzer-qemu wrappers (#782)
This commit is contained in:
@ -626,7 +626,7 @@ class Libfuzzer(Command):
|
|||||||
with tempfile.TemporaryDirectory() as tempdir:
|
with tempfile.TemporaryDirectory() as tempdir:
|
||||||
if sysroot:
|
if sysroot:
|
||||||
setup_path = File(os.path.join(tempdir, "setup.sh"))
|
setup_path = File(os.path.join(tempdir, "setup.sh"))
|
||||||
with open(setup_path, "w") as handle:
|
with open(setup_path, "w", newline="\n") as handle:
|
||||||
sysroot_filename = helper.target_exe_blob_name(sysroot, None)
|
sysroot_filename = helper.target_exe_blob_name(sysroot, None)
|
||||||
handle.write(
|
handle.write(
|
||||||
"#!/bin/bash\n"
|
"#!/bin/bash\n"
|
||||||
@ -638,7 +638,7 @@ class Libfuzzer(Command):
|
|||||||
)
|
)
|
||||||
|
|
||||||
wrapper_path = File(os.path.join(tempdir, wrapper_name))
|
wrapper_path = File(os.path.join(tempdir, wrapper_name))
|
||||||
with open(wrapper_path, "w") as handle:
|
with open(wrapper_path, "w", newline="\n") as handle:
|
||||||
handle.write(
|
handle.write(
|
||||||
"#!/bin/bash\n"
|
"#!/bin/bash\n"
|
||||||
'SETUP_DIR=$(dirname "$(readlink -f "$0")")\n'
|
'SETUP_DIR=$(dirname "$(readlink -f "$0")")\n'
|
||||||
@ -648,7 +648,7 @@ class Libfuzzer(Command):
|
|||||||
upload_files = [setup_path, wrapper_path, sysroot]
|
upload_files = [setup_path, wrapper_path, sysroot]
|
||||||
else:
|
else:
|
||||||
setup_path = File(os.path.join(tempdir, "setup.sh"))
|
setup_path = File(os.path.join(tempdir, "setup.sh"))
|
||||||
with open(setup_path, "w") as handle:
|
with open(setup_path, "w", newline="\n") as handle:
|
||||||
handle.write(
|
handle.write(
|
||||||
"#!/bin/bash\n"
|
"#!/bin/bash\n"
|
||||||
"set -ex\n"
|
"set -ex\n"
|
||||||
@ -656,7 +656,7 @@ class Libfuzzer(Command):
|
|||||||
)
|
)
|
||||||
|
|
||||||
wrapper_path = File(os.path.join(tempdir, wrapper_name))
|
wrapper_path = File(os.path.join(tempdir, wrapper_name))
|
||||||
with open(wrapper_path, "w") as handle:
|
with open(wrapper_path, "w", newline="\n") as handle:
|
||||||
handle.write(
|
handle.write(
|
||||||
"#!/bin/bash\n"
|
"#!/bin/bash\n"
|
||||||
'SETUP_DIR=$(dirname "$(readlink -f "$0")")\n'
|
'SETUP_DIR=$(dirname "$(readlink -f "$0")")\n'
|
||||||
|
Reference in New Issue
Block a user