All of a sudden all install scripts and published instructions break after Openvas-Scanner 23.9.0.
Up to 23.9.0 the install instructions require 2 cargo.toml files to build from ( ./rust/openvasd and ./rust/scannerctl) and this works fine.
With 23.10.0 onwards, the source structure has changed and previous cargo.toml files for openvasd & scannerctl no longer exist, resulting in multiple error: could not find Cargo.toml
.
Can someone please shed light on the correct way to build with 23.10.0 onwards?
Looks like the source directories are incorrect in the build documentation. They should be:
cd $SOURCE_DIR/openvas-scanner-$OPENVAS_DAEMON/rust/src
cargo build --release
cd $SOURCE_DIR/openvas-scanner-$OPENVAS_DAEMON/rust/src/scannerctl
cargo build --release
However, you may experience other errors building openvasd
version 23.10.0
. I guess it is not fully ready yet.
EDIT: Here is the error message when doing cargo build --release
:
Compiling scannerlib v0.1.0 (/home/greenbone/source/openvas-scanner-23.10.1/rust)
error[E0733]: recursion in an `async fn` requires boxing
--> src/nasl/interpreter/interpreter.rs:137:5
|
137 | async fn include(&mut self, name: &Statement) -> InterpretResult {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ recursive `async fn`
|
= note: a recursive `async fn` must be rewritten to return a boxed `dyn Future`
= note: consider using the `async_recursion` crate: https://crates.io/crates/async_recursion
error[E0733]: recursion in an `async fn` requires boxing
--> src/nasl/interpreter/interpreter.rs:210:5
|
210 | pub(crate) async fn resolve(&mut self, statement: &Statement) -> InterpretResult {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ recursive `async fn`
|
= note: a recursive `async fn` must be rewritten to return a boxed `dyn Future`
= note: consider using the `async_recursion` crate: https://crates.io/crates/async_recursion
For more information about this error, try `rustc --explain E0733`.
error: could not compile `scannerlib` (lib) due to 2 previous errors
warning: build failed, waiting for other jobs to finish...