From bbf97a535aeb379cc6b9f60fdec7629bcdba4c64 Mon Sep 17 00:00:00 2001 From: John Smith Date: Thu, 1 Dec 2022 19:08:40 -0500 Subject: [PATCH] windows support and more recursion fixes --- setup_windows.bat | 38 ++++++++++++++++++++++++++++++++++ veilid-cli/src/main.rs | 1 + veilid-flutter/rust/src/lib.rs | 2 ++ veilid-server/src/main.rs | 1 + 4 files changed, 42 insertions(+) create mode 100644 setup_windows.bat diff --git a/setup_windows.bat b/setup_windows.bat new file mode 100644 index 00000000..c502034b --- /dev/null +++ b/setup_windows.bat @@ -0,0 +1,38 @@ +@echo off +setlocal + +REM ############################################# + +PUSHD %~dp0 +SET ROOTDIR=%CD% +POPD + +IF NOT DEFINED ProgramFiles(x86) ( + echo This script requires a 64-bit Windows Installation. Exiting. + goto end +) + +FOR %%X IN (protoc.exe) DO (SET PROTOC_FOUND=%%~$PATH:X) +IF NOT DEFINED PROTOC_FOUND ( + echo protobuf compiler ^(protoc^) is required but it's not installed. Install protoc 21.10 or higher. Ensure it is in your path. Aborting. + echo protoc is available here: https://github.com/protocolbuffers/protobuf/releases/download/v21.10/protoc-21.10-win64.zip + goto end +) + +FOR %%X IN (capnp.exe) DO (SET CAPNP_FOUND=%%~$PATH:X) +IF NOT DEFINED CAPNP_FOUND ( + echo capnproto compiler ^(capnp^) is required but it's not installed. Install capnp 0.10.3 or higher. Ensure it is in your path. Aborting. + echo capnp is available here: https://capnproto.org/capnproto-c++-win32-0.10.3.zip + goto end +) + +FOR %%X IN (cargo.exe) DO (SET CARGO_FOUND=%%~$PATH:X) +IF NOT DEFINED CARGO_FOUND ( + echo rust ^(cargo^) is required but it's not installed. Install rust 1.65 or higher. Ensure it is in your path. Aborting. + echo install rust via rustup here: https://static.rust-lang.org/rustup/dist/x86_64-pc-windows-msvc/rustup-init.exe + goto ends +) + +echo Setup successful +:end +ENDLOCAL diff --git a/veilid-cli/src/main.rs b/veilid-cli/src/main.rs index 389db983..13692b14 100644 --- a/veilid-cli/src/main.rs +++ b/veilid-cli/src/main.rs @@ -1,5 +1,6 @@ #![deny(clippy::all)] #![deny(unused_must_use)] +#![recursion_limit = "256"] use veilid_core::tools::*; diff --git a/veilid-flutter/rust/src/lib.rs b/veilid-flutter/rust/src/lib.rs index bd89a6b7..2121c5ce 100644 --- a/veilid-flutter/rust/src/lib.rs +++ b/veilid-flutter/rust/src/lib.rs @@ -1,3 +1,5 @@ +#![recursion_limit = "256"] + mod dart_ffi; mod dart_isolate_wrapper; mod tools; diff --git a/veilid-server/src/main.rs b/veilid-server/src/main.rs index 3856731d..7dd76d54 100644 --- a/veilid-server/src/main.rs +++ b/veilid-server/src/main.rs @@ -1,6 +1,7 @@ #![forbid(unsafe_code)] #![deny(clippy::all)] #![deny(unused_must_use)] +#![recursion_limit = "256"] mod client_api; mod cmdline;