diff --git a/bin/pastisd b/bin/pastisd index d00bb1d..32ace5f 100755 --- a/bin/pastisd +++ b/bin/pastisd @@ -9,13 +9,13 @@ from libpastis import ClientAgent from libpastis.types import FuzzingEngine try: - import hfwrapper - from hfwrapper import Honggfuzz + import pastishonggfuzz + from pastishonggfuzz import Honggfuzz if os.environ.get("HFUZZ_PATH") is None: raise ImportError("HFUZZ_PATH not set") HONGGFUZZ_AVAILABLE = True except ImportError: - hfwrapper, Honggfuzz = None, None + pastishonggfuzz, Honggfuzz = None, None HONGGFUZZ_AVAILABLE = False try: import pastistritondse @@ -77,7 +77,7 @@ def main(host=PASTIS_MASTER): engines = [] if HONGGFUZZ_AVAILABLE: - engines.append((FuzzingEngine.HONGGFUZZ, hfwrapper.__version__)) + engines.append((FuzzingEngine.HONGGFUZZ, pastishonggfuzz.__version__)) else: logging.warning("Honggfuzz is not available (cannot import it)") if PASTISTRITONDSE_AVAILABLE: diff --git a/bin/pastis-benchmark b/pastisbenchmark/__main__.py similarity index 99% rename from bin/pastis-benchmark rename to pastisbenchmark/__main__.py index 7a0f59b..3747063 100755 --- a/bin/pastis-benchmark +++ b/pastisbenchmark/__main__.py @@ -1,5 +1,3 @@ -#!/usr/bin/env python3 - # built-in imports import shutil @@ -389,6 +387,9 @@ def history(workspace: str): plotter.show_delta_history(campaign) -if __name__ == "__main__": +def main(): cli() + +if __name__ == "__main__": + main() diff --git a/bin/pastis-broker b/pastisbroker/__main__.py similarity index 99% rename from bin/pastis-broker rename to pastisbroker/__main__.py index 57d4ad8..cc6ace8 100755 --- a/bin/pastis-broker +++ b/pastisbroker/__main__.py @@ -1,5 +1,3 @@ -#!/usr/bin/env python3 - # built-in imports import click import sys diff --git a/setup.py b/setup.py index 532dc40..411cdc7 100644 --- a/setup.py +++ b/setup.py @@ -68,14 +68,14 @@ test_suite="", entry_points={ "console_scripts": [ + "pastis-benchmark = pastisbenchmark.__main__:main", + "pastis-broker = pastisbroker.__main__:main", "pastis-aflpp = pastisaflpp.__main__:main", "pastis-honggfuzz = pastishonggfuzz.__main__:main", "pastis-tritondse = pastistritondse.__main__:main" ] }, scripts=[ - 'bin/pastis-broker', - 'bin/pastis-benchmark', 'bin/pastisd', ] )