Giter VIP home page Giter VIP logo

Comments (8)

thomwiggers avatar thomwiggers commented on September 13, 2024 1

(Commenting on stuff from my phone is easy, running the update script will require a boring talk at RWC)

from pqcrypto.

l3utterfly avatar l3utterfly commented on September 13, 2024

Full output if needed:

Updating git repository https://github.com/rustpq/pqcrypto
Updating git submodule https://github.com/pqclean/PQClean.git
Updating git submodule https://github.com/eliben/pycparser.git
Compiling pqcrypto-traits v0.3.4 (https://github.com/rustpq/pqcrypto#dedb29e9)
Compiling pqcrypto-internals v0.2.3 (https://github.com/rustpq/pqcrypto#dedb29e9)
Compiling pqcrypto-falcon v0.2.10 (https://github.com/rustpq/pqcrypto#dedb29e9)
Compiling pqcrypto-classicmceliece v0.1.6 (https://github.com/rustpq/pqcrypto#dedb29e9)
Compiling pqcrypto-frodo v0.4.10 (https://github.com/rustpq/pqcrypto#dedb29e9)
Compiling pqcrypto-kyber v0.7.4 (https://github.com/rustpq/pqcrypto#dedb29e9)
Compiling pqcrypto-hqc v0.1.4 (https://github.com/rustpq/pqcrypto#dedb29e9)
Compiling pqcrypto-rainbow v0.2.4 (https://github.com/rustpq/pqcrypto#dedb29e9)
Compiling pqcrypto-ntruprime v0.1.5 (https://github.com/rustpq/pqcrypto#dedb29e9)
Compiling pqcrypto-sphincsplus v0.6.3 (https://github.com/rustpq/pqcrypto#dedb29e9)
Compiling pqcrypto-ntru v0.5.7 (https://github.com/rustpq/pqcrypto#dedb29e9)
Compiling pqcrypto-saber v0.1.10 (https://github.com/rustpq/pqcrypto#dedb29e9)
Compiling pqcrypto-dilithium v0.4.4 (https://github.com/rustpq/pqcrypto#dedb29e9)
error: failed to run custom build command for pqcrypto-internals v0.2.3 (https://github.com/rustpq/pqcrypto#dedb29e9)

Caused by:
process didn't exit successfully: C:\src\butterfly-consensus\sphincs-test\target\debug\build\pqcrypto-internals-11b1745acdab2985\build-script-build (exit code: 1)
--- stdout
cargo:includepath=\?\C:\Users\gcpth.cargo\git\checkouts\pqcrypto-e9887127992f2d13\dedb29e\pqcrypto-internals\include
TARGET = Some("x86_64-pc-windows-msvc")
OPT_LEVEL = Some("0")
HOST = Some("x86_64-pc-windows-msvc")
CC_x86_64-pc-windows-msvc = None
CC_x86_64_pc_windows_msvc = None
HOST_CC = None
CC = None
CFLAGS_x86_64-pc-windows-msvc = None
CFLAGS_x86_64_pc_windows_msvc = None
HOST_CFLAGS = None
CFLAGS = None
CRATE_CC_NO_DEFAULTS = None
CARGO_CFG_TARGET_FEATURE = Some("fxsr,llvm14-builtins-abi,sse,sse2")
DEBUG = Some("true")
running: "C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.31.31103\bin\HostX64\x64\cl.exe" "-nologo" "-MD" "-Z7" "-Brepro" "-I" "\\?\C:\Users\gcpth\.cargo\git\checkouts\pqcrypto-e9887127992f2d13\dedb29e\pqcrypto-internals\include" "-W4" "-FoC:\src\butterfly-consensus\sphincs-test\target\debug\build\pqcrypto-internals-49d4009b3b02f44e\out\cfiles\nistseedexpander.o" "-c" "cfiles\nistseedexpander.c"
running: "C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.31.31103\bin\HostX64\x64\cl.exe" "-nologo" "-MD" "-Z7" "-Brepro" "-I" "\\?\C:\Users\gcpth\.cargo\git\checkouts\pqcrypto-e9887127992f2d13\dedb29e\pqcrypto-internals\include" "-W4" "-FoC:\src\butterfly-consensus\sphincs-test\target\debug\build\pqcrypto-internals-49d4009b3b02f44e\out\cfiles\aes.o" "-c" "cfiles\aes.c"
running: "C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.31.31103\bin\HostX64\x64\cl.exe" "-nologo" "-MD" "-Z7" "-Brepro" "-I" "\\?\C:\Users\gcpth\.cargo\git\checkouts\pqcrypto-e9887127992f2d13\dedb29e\pqcrypto-internals\include" "-W4" "-FoC:\src\butterfly-consensus\sphincs-test\target\debug\build\pqcrypto-internals-49d4009b3b02f44e\out\cfiles\sha2.o" "-c" "cfiles\sha2.c"
running: "C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.31.31103\bin\HostX64\x64\cl.exe" "-nologo" "-MD" "-Z7" "-Brepro" "-I" "\\?\C:\Users\gcpth\.cargo\git\checkouts\pqcrypto-e9887127992f2d13\dedb29e\pqcrypto-internals\include" "-W4" "-FoC:\src\butterfly-consensus\sphincs-test\target\debug\build\pqcrypto-internals-49d4009b3b02f44e\out\cfiles\sp800-185.o" "-c" "cfiles\sp800-185.c"
running: "C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.31.31103\bin\HostX64\x64\cl.exe" "-nologo" "-MD" "-Z7" "-Brepro" "-I" "\\?\C:\Users\gcpth\.cargo\git\checkouts\pqcrypto-e9887127992f2d13\dedb29e\pqcrypto-internals\include" "-W4" "-FoC:\src\butterfly-consensus\sphincs-test\target\debug\build\pqcrypto-internals-49d4009b3b02f44e\out\cfiles\fips202.o" "-c" "cfiles\fips202.c"
nistseedexpander.c
aes.c
sha2.c
sp800-185.c
fips202.c
cfiles\nistseedexpander.c(9): fatal error C1083: Cannot open include file: 'nistseedexpander.h': No such file or directory
cfiles\aes.c(32): fatal error C1083: Cannot open include file: 'aes.h': No such file or directory
exit code: 2
cfiles\sha2.c(10): fatal error C1083: Cannot open include file: 'sha2.h': No such file or directory
exit code: 2
cfiles\sp800-185.c(4): fatal error C1083: Cannot open include file: 'sp800-185.h': No such file or directoryc
files\fips202.c(13): fatal error C1083: Cannot open include file: 'fips202.h': No such file or directory
exit code: 2
exit code: 2
exit code: 2

--- stderr

error occurred: Command "C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.31.31103\bin\HostX64\x64\cl.exe" "-nologo" "-MD" "-Z7" "-Brepro" "-I" "\\?\C:\Users\gcpth\.cargo\git\checkouts\pqcrypto-e9887127992f2d13\dedb29e\pqcrypto-internals\include" "-W4" "-FoC:\src\butterfly-consensus\sphincs-test\target\debug\build\pqcrypto-internals-49d4009b3b02f44e\out\cfiles\fips202.o" "-c" "cfiles\fips202.c" with args "cl.exe" did not execute successfully (status code exit code: 2).

warning: build failed, waiting for other jobs to finish...

from pqcrypto.

l3utterfly avatar l3utterfly commented on September 13, 2024

Figured out a workaround:

It seems the build process cannot find the ".h" files in the "include" folder. Manually moving them to the "cfiles" folder in the project "pqcrypto-internals" worked for the build process.

I'm not familiar with the rust build process enough to figure out the cause of this issue though. So any help would be appreciated here.

from pqcrypto.

thomwiggers avatar thomwiggers commented on September 13, 2024

-I" "\\?\C:\Users\gcpth\.cargo\git\checkouts\pqcrypto-e9887127992f2d13\dedb29e\pqcrypto-internals\include" should set the include path. I'm not sure why that's prefixed with \\?.

The includepath is set here. I don't run Windows, it's not easy for me to test this. I'm also at a workshop today.

from pqcrypto.

l3utterfly avatar l3utterfly commented on September 13, 2024

Thanks for the pointer, I'll look into this a bit more since I'm on Windows

from pqcrypto.

l3utterfly avatar l3utterfly commented on September 13, 2024

I've managed to fix the issue by using an external "dunce" crate. The include path creation changes simply to: dunce::canonicalize(Path::new("include")).unwrap()

https://stackoverflow.com/questions/50322817/how-do-i-remove-the-prefix-from-a-canonical-windows-path

On non-Windows systems, this should not affect anything as it compiles back to Path::canonicalize.

Let me know if you think this is acceptable. I can create a PR if you want

from pqcrypto.

l3utterfly avatar l3utterfly commented on September 13, 2024

Thanks for merging the PR. Do you mind bumping up the version on crates.io with this change? I can then use it without including the source code in my project.

Appreciate it!

from pqcrypto.

thomwiggers avatar thomwiggers commented on September 13, 2024

Yep that's #36.

Closed by #36

from pqcrypto.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.