microsoft / aici

AICI: Prompts as (Wasm) Programs
MIT License
1.92k stars 78 forks source link

can't build pyctrl on WSL (windows 11) #79

Open superchargez opened 6 months ago

superchargez commented 6 months ago

Can't build it with the command: ../aici.sh build . --tag pyctrl-latest

Error below: abridged version OpenSSL include directory does not exist: /usr/include/x86_64-linux-gnu/include

I have tried changing OPENSSL_DIR to many things, but nothing seams to work. By the way server is running in another terminal with command ./server.sh phi2

Where am I supposed to find the include directory? BTW the /usr/include does not work either nor does /usr. The header files are all scattered (though this is standard WSL installation). Here is the part of the error output when /usr is exported as openssl dir:

error: failed to run custom build command for cranelift-codegen v0.103.0

Caused by: process didn't exit successfully: /home/jawad/gits/aici/target/release/build/cranelift-codegen-ea038670b80c31b8/build-script-build (exit status: 101) --- stderr thread 'main' panicked at /home/jawad/.cargo/registry/src/index.crates.io-6f17d22bba15001f/cranelift-codegen-0.103.0/build.rs:45:53: error when identifying target: "no supported isa found for arch wasm32" note: run with RUST_BACKTRACE=1 environment variable to display a backtrace warning: build failed, waiting for other jobs to finish... error: Only features sync,macros,io-util,rt,time are supported on wasm. --> /home/jawad/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tokio-1.35.1/src/lib.rs:471:1 | 471 | compile_error!("Only features sync,macros,io-util,rt,time are supported on wasm."); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

The following warnings were emitted during compilation:

warning: openssl-sys@0.9.98: In file included from build/expando.c:1: warning: openssl-sys@0.9.98: In file included from /usr/include/openssl/opensslv.h:109: warning: openssl-sys@0.9.98: /usr/include/openssl/macros.h:14:10: error: 'openssl/opensslconf.h' file not found with include; use "quotes" instead warning: openssl-sys@0.9.98: #include <openssl/opensslconf.h> warning: openssl-sys@0.9.98: ^~~~~~~ warning: openssl-sys@0.9.98: "openssl/opensslconf.h" warning: openssl-sys@0.9.98: In file included from build/expando.c:1: warning: openssl-sys@0.9.98: In file included from /usr/include/openssl/opensslv.h:109: warning: openssl-sys@0.9.98: In file included from /usr/include/openssl/macros.h:14: warning: openssl-sys@0.9.98: /usr/include/openssl/openssl/opensslconf.h:14:11: fatal error: 'openssl/configuration.h' file not found warning: openssl-sys@0.9.98: # include <openssl/configuration.h> warning: openssl-sys@0.9.98: ^~~~~~~~~ warning: openssl-sys@0.9.98: 2 errors generated.

error: failed to run custom build command for openssl-sys v0.9.98

Caused by: process didn't exit successfully: /home/jawad/gits/aici/target/release/build/openssl-sys-3a9b890a93ef373d/build-script-main (exit status: 101)

mmoskal commented 6 months ago

Can you try ../../aici.sh build . --tag pyctrl-latest from controllers/pyctrl ?