diff --git a/README.md b/README.md index 46d0a94..b4ca766 100644 --- a/README.md +++ b/README.md @@ -18,23 +18,19 @@ Dependencies are: ## Usage -To clone test262, clone SerenityOS, build Lagom, and build `libjs-test262-runner`, run: +To clone test262, clone serenity and build Lagom run: ```console ./setup.sh ``` -The repositories will only be cloned if they don't exist yet locally, so you -can use this script for development of the test runner as well. - -If `SERENITY_SOURCE_DIR` is set, it will be used instead. However, if the Lagom -build directory already exists, the script will not touch your build in that -case, so you'll need to build `libLagom.a` yourself. +The repositories will only be cloned if they don't exist yet locally. +If `SERENITY_SOURCE_DIR` is set, it will be used to compile the runner instead of cloning serenity. Once that's done, run: ```console -python3 main.py --libjs-test262-runner ./Build/_deps/lagom-build/bin/test262-runner --test262-root ./test262/ +python3 main.py --libjs-test262-runner ./Build/bin/test262-runner --test262-root ./test262/ ``` ## Options diff --git a/run_all_and_update_results.py b/run_all_and_update_results.py index a141d7d..df05f87 100755 --- a/run_all_and_update_results.py +++ b/run_all_and_update_results.py @@ -30,13 +30,21 @@ def get_git_commit_timestamp(path: Path) -> int: def find_lagom_executable(test262_path: Path, serenity_path: Path, name: str): - executable_path = test262_path / f"Build/_deps/lagom-build/bin/{name}" - if not executable_path.exists(): - executable_path = serenity_path / f"Build/lagom/bin/{name}" - if not executable_path.exists(): - executable_path = serenity_path / f"Build/lagom/Meta/Lagom/bin/{name}" + # Build/bin: Local build + # serenity_path / Build/lagom/bin: Meta/Lagom source dir + # _deps: Local build before 2023-08-13 - return executable_path + paths = [ + test262_path / f"Build/bin/{name}", + serenity_path / f"Build/lagom/bin/{name}", + test262_path / f"Build/_deps/lagom-build/bin/{name}", + ] + + for path in paths: + if path.exists(): + return path + + raise RuntimeError(f"Unable to find {name}") def main() -> None: