blob: a00603e63a9728a2f6cc8366a698d6459977ae50 [file] [log] [blame]
#!/bin/bash
#
# SPDX-License-Identifier: GPL-2.0
# Origin: https://github.com/google/syzkaller
mkdir -p bin
for f in linux/*.c; do
out="bin/`basename "$f" .c`"
if test -f "$out"; then
continue
fi
echo $f
flags=""
if grep "__NR_mmap2" $f; then
flags="-m32"
fi
gcc "$f" -static -pthread $flags -o $out
done