Skip to content

Commit

Permalink
Check for test_corpus build
Browse files Browse the repository at this point in the history
  • Loading branch information
Rot127 committed Aug 22, 2024
1 parent bbe3e06 commit 6264091
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
9 changes: 6 additions & 3 deletions bindings/python/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -136,13 +136,16 @@ def build_libraries():
# Windows build: this process requires few things:
# - MSVC installed
# - Run this command in an environment setup for MSVC
if not os.path.exists("build"):
os.mkdir("build")
os.chdir("build")
if not os.path.exists("build_py"):
os.mkdir("build_py")
os.chdir("build_py")
print("Build Directory: {}\n".format(os.getcwd()))
# Only build capstone.dll / libcapstone.dylib
if SYSTEM == "win32":
os.system('cmake -DCMAKE_BUILD_TYPE=Release -DBUILD_SHARED_LIBS=ON -DCAPSTONE_BUILD_LEGACY_TESTS=OFF -DCAPSTONE_BUILD_CSTOOL=OFF -G "NMake Makefiles" ..')
elif 'AFL_NOOPT' in os.environ:
# build for test_corpus
os.system('cmake -DBUILD_SHARED_LIBS=ON -DCAPSTONE_BUILD_LEGACY_TESTS=OFF -DCAPSTONE_BUILD_CSTOOL=OFF ..')
else:
os.system('cmake -DCMAKE_BUILD_TYPE=Release -DBUILD_SHARED_LIBS=ON -DCAPSTONE_BUILD_LEGACY_TESTS=OFF -DCAPSTONE_BUILD_CSTOOL=OFF -G "Unix Makefiles" ..')
os.system("cmake --build .")
Expand Down
2 changes: 1 addition & 1 deletion suite/fuzz/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ else
$(link-static)
endif

$(FUZZERBIN): FUZZLDFLAGS="-fsanitize=fuzzer"
$(FUZZERBIN): FUZZLDFLAGS="-fsanitize=fuzzer -fno-sanitize-coverage=stack-depth"

$(FUZZERBIN): fuzz_disasm.o platform.o
@mkdir -p $(@D)
Expand Down

0 comments on commit 6264091

Please sign in to comment.