Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

trustify/server build error #87

Closed
helio-frota opened this issue Mar 18, 2024 · 12 comments
Closed

trustify/server build error #87

helio-frota opened this issue Mar 18, 2024 · 12 comments

Comments

@helio-frota
Copy link
Collaborator

helio-frota commented Mar 18, 2024

cargo test

error: failed to run custom build command for `sequoia-openpgp v1.19.0`
Caused by:
  process didn't exit successfully: `Desktop/tc/trustify/target/debug/build/sequoia-openpgp-49fc058589fa4216/build-script-build` (exit status: 1)
  --- stderr
  No cryptographic backend selected.

  Sequoia requires a cryptographic backend.  This backend is selected at compile
  time using feature flags.

  See https://crates.io/crates/sequoia-openpgp#crypto-backends

nettle related ? #61

@ctron
Copy link
Contributor

ctron commented Mar 18, 2024

Using sequoia requires to select one (exactly one) cryptographic backend. As this works in the CI (and for me locally), it would be important to standard what steps you're taking to run into this error.

@helio-frota
Copy link
Collaborator Author

it would be important to standard what steps you're taking to run into this error

The steps I ran:

cd trustify/server
cargo test

@ctron
Copy link
Contributor

ctron commented Mar 18, 2024

Works for me:

    Finished test [unoptimized + debuginfo] target(s) in 11.95s
     Running unittests src/lib.rs (/home/jreimann/git/trustify/target/debug/deps/trustify_server-2a99c2dd7afc397d)

running 1 test
test server::write::advisory::tests::upload_advisory ... ok

test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 2.26s

   Doc-tests trustify-server

running 0 tests

test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s

What OS do you run this on?

@helio-frota
Copy link
Collaborator Author

What OS do you run this on?

fedora 39

@ctron
Copy link
Contributor

ctron commented Mar 18, 2024

Same as I. What local modification on the source of trustify do you have?

@helio-frota
Copy link
Collaborator Author

Same as I. What local modification on the source of trustify do you have?

I have no modifications

2024-03-18_09-47

@helio-frota
Copy link
Collaborator Author

I start to suspect that I missed installing something--foo--devel ?

@helio-frota
Copy link
Collaborator Author

I'm assuming I'm doing something wrong 👍
( I already have nettle installed )

trustify git:(main) sudo dnf list installed | rg nettle
nettle.x86_64                                        3.9.1-2.fc39                        @anaconda
nettle-devel.x86_64                                  3.9.1-2.fc39                        @fedora

@ctron
Copy link
Contributor

ctron commented Mar 18, 2024

We don't use nettle but openssl:

csaf-walker = { version = "=0.6.0-alpha.8", default-features = false, features = ["crypto-openssl", "csaf"] }
sbom-walker = { version = "=0.6.0-alpha.8", default-features = false, features = ["crypto-openssl", "cyclonedx-bom", "spdx-rs"] }

Sorry, I ran out of ideas. Maybe try replicating the CI environment. 🤷

@helio-frota
Copy link
Collaborator Author

helio-frota commented Mar 18, 2024

Thanks for the extra info

When I added this to the dependencies:

csaf-walker = { version = "=0.6.0-alpha.8", default-features = false, features = ["crypto-openssl"] }

then it worked

running 1 test
test server::write::advisory::tests::upload_advisory ... ok

test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 2.35s

   Doc-tests trustify-server

running 0 tests

test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s

but I can see in your draft pr you are not using it

walker-common = "=0.6.0-alpha.8"

how that can be possible -- I'm not following 🤷

➜  server git:(main) ✗ rustc --version
rustc 1.76.0 (07dca489a 2024-02-04)
➜  server git:(main) ✗ cargo --version
cargo 1.76.0 (c84b36747 2024-01-18)

@helio-frota
Copy link
Collaborator Author

helio-frota commented Mar 18, 2024

🤔 I'll close this issue and wait for your PR , as I'm not understanding what's going on I suspect that everything I'll be fixed once the PR get merged,

thanks

@helio-frota
Copy link
Collaborator Author

feedback: build fixed after PR merge ^

➜  server git:(main) cargo test
    Finished test [unoptimized + debuginfo] target(s) in 0.26s
     Running unittests src/lib.rs (/home/heliofrota/Desktop/tc/trustify/target/debug/deps/trustify_server-faaafebe68c1c223)

running 1 test
test server::write::advisory::tests::upload_advisory ... ok

test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 1.92s

   Doc-tests trustify-server

running 0 tests

test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants