summaryrefslogtreecommitdiff
path: root/examples/file/README.md
diff options
context:
space:
mode:
Diffstat (limited to 'examples/file/README.md')
-rw-r--r--examples/file/README.md19
1 files changed, 19 insertions, 0 deletions
diff --git a/examples/file/README.md b/examples/file/README.md
new file mode 100644
index 00000000..4a79457b
--- /dev/null
+++ b/examples/file/README.md
@@ -0,0 +1,19 @@
+1. Compile file/libmagic
+
+```shell
+$ cd file-5.37/
+$ CC="honggfuzz/hfuzz_cc/hfuzz-clang" ./configure --enable-static --disable-shared
+$ make -j$(nproc)
+```
+
+2. Compile/link the persistent-file
+
+```shell
+$ honggfuzz/hfuzz_cc/hfuzz-clang -I ./file-5.37/ honggfuzz/examples/file/persistent-file.c -o persistent-file ./file-5.37/src/.libs/libmagic.a -lz
+```
+
+3. Fuzz it!
+
+```shell
+$ honggfuzz/honggfuzz --input inputs/ -- ./persistent-file ./file-5.37/magic/magic.mgc
+```