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

Fix build with Go v1.22.1, liboqs v0.10.0 #36

Merged
merged 2 commits into from
Mar 26, 2024

Conversation

cipherboy
Copy link
Contributor

This fixes the build with newer toolchain, liboqs versions:

  • liboqs v0.10.0 drops support for the NIST KAT Random source in open-quantum-safe/liboqs@cc453db from the public API.

  • This also fixes some places in the test suite where go test ./... fails due to calling string(...) on Go 1.22.1:

     > conversion from int to string yields a string of one rune, not a string of digits (did you mean fmt.Sprint(x)?)
    

In cc453db4a6e02d97bf5fc974840ace881ffa6da1 of liboqs, NIST KAT random
helpers were removed from the public API interface of liboqs, causing
liboqs-go to fail to build. Remove these functions as there's no way to
support them anymore (and likely don't have much value).

Signed-off-by: Alexander Scheel <[email protected]>
This uses fmt.Sprintf("%v", ...) to format numbers; per newer Go
toolchain versions:

> conversion from int to string yields a string of one rune,
>   not a string of digits (did you mean fmt.Sprint(x)?)

This fixes `go test ./...`.

Signed-off-by: Alexander Scheel <[email protected]>
@vsoftco vsoftco self-requested a review March 26, 2024 20:26
@vsoftco vsoftco merged commit 22b7b24 into open-quantum-safe:main Mar 26, 2024
4 checks passed
Copy link
Member

@vsoftco vsoftco left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All good from my side

@cipherboy
Copy link
Contributor Author

Thank you @vsoftco!

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

Successfully merging this pull request may close these issues.

2 participants