Hello i am new to Rust, i just wanted to compile a project.
If i compile it in debug mode, it will compile without problems
cargo build --features sqlite
But if i compile it for release
cargo build --features sqlite --release
i get an error at compiling
Compiling writeable v0.5.5
Running `C:\Users\admin\.rustup\toolchains\1.86.0-x86_64-pc-windows-msvc\bin\rustc.exe --crate-name litemap --edition=2021 C:\Users\admin\.cargo\registry\src\index.crates.io-1949cf8c6b5b557f\litemap-0.7.5\src\lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --diagnostic-width=119 --crate-type lib --emit=dep-info,metadata,link -C opt-level=3 -C linker-plugin-lto -C codegen-units=1 --cfg "feature=\"alloc\"" --check-cfg cfg(docsrs,test) --check-cfg "cfg(feature, values(\"alloc\", \"databake\", \"default\", \"serde\", \"testing\", \"yoke\"))" -C metadata=4939e3338cb5d1b4 -C extra-filename=-bf633c3ead055e44 --out-dir D:\vw\target\release\deps -C strip=debuginfo -L dependency=D:\vw\target\release\deps --cap-lints allow`
Running `C:\Users\admin\.rustup\toolchains\1.86.0-x86_64-pc-windows-msvc\bin\rustc.exe --crate-name writeable --edition=2021 C:\Users\admin\.cargo\registry\src\index.crates.io-1949cf8c6b5b557f\writeable-0.5.5\src\lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --diagnostic-width=119 --crate-type lib --emit=dep-info,metadata,link -C opt-level=3 -C linker-plugin-lto -C codegen-units=1 --check-cfg cfg(docsrs,test) --check-cfg "cfg(feature, values(\"bench\", \"either\"))" -C metadata=5540673de430bdb5 -C extra-filename=-ac3548a34d035252 --out-dir D:\vw\target\release\deps -C strip=debuginfo -L dependency=D:\vw\target\release\deps --cap-lints allow`
Compiling icu_locid_transform_data v1.5.1
Running `C:\Users\admin\.rustup\toolchains\1.86.0-x86_64-pc-windows-msvc\bin\rustc.exe --crate-name build_script_build --edition=2021 C:\Users\admin\.cargo\registry\src\index.crates.io-1949cf8c6b5b557f\icu_locid_transform_data-1.5.1\build.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --diagnostic-width=119 --crate-type bin --emit=dep-info,link -C embed-bitcode=no -C debug-assertions=off --check-cfg cfg(docsrs,test) --check-cfg "cfg(feature, values())" -C metadata=dea906800d619e89 -C extra-filename=-a6fc31b7f98e9e52 --out-dir D:\vw\target\release\build\icu_locid_transform_data-a6fc31b7f98e9e52 -C strip=debuginfo -L dependency=D:\vw\target\release\deps --cap-lints allow`
Compiling icu_locid v1.5.0
Running `C:\Users\admin\.rustup\toolchains\1.86.0-x86_64-pc-windows-msvc\bin\rustc.exe --crate-name icu_locid --edition=2021 C:\Users\admin\.cargo\registry\src\index.crates.io-1949cf8c6b5b557f\icu_locid-1.5.0\src\lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --diagnostic-width=119 --crate-type lib --emit=dep-info,metadata,link -C opt-level=3 -C linker-plugin-lto -C codegen-units=1 --cfg "feature=\"zerovec\"" --check-cfg cfg(docsrs,test) --check-cfg "cfg(feature, values(\"bench\", \"databake\", \"serde\", \"std\", \"zerovec\"))" -C metadata=d3e2c2348134578e -C extra-filename=-974f9a5e67619d8b --out-dir D:\vw\target\release\deps -C strip=debuginfo -L dependency=D:\vw\target\release\deps --extern displaydoc=D:\vw\target\release\deps\displaydoc-d744388f5069d438.dll --extern litemap=D:\vw\target\release\deps\liblitemap-bf633c3ead055e44.rmeta --extern tinystr=D:\vw\target\release\deps\libtinystr-9f72506fe69b8611.rmeta --extern writeable=D:\vw\target\release\deps\libwriteable-ac3548a34d035252.rmeta --extern zerovec=D:\vw\target\release\deps\libzerovec-d8345d7f12cd195d.rmeta --cap-lints allow`
error: linking with `link.exe` failed: exit code: 1104
|
= note: "C:\\Program Files\\Microsoft Visual Studio\\2022\\Community\\VC\\Tools\\MSVC\\14.43.34808\\bin\\HostX64\\x64\\link.exe" "/NOLOGO" "C:\\Users\\DEV~1.ADM\\AppData\\Local\\Temp\\rustcttFTLn\\symbols.o" "<2 object files omitted>" "<sysroot>\\lib\\rustlib\\x86_64-pc-windows-msvc\\lib/{libstd-*,libpanic_unwind-*,libwindows_targets-*,librustc_demangle-*,libstd_detect-*,libhashbrown-*,librustc_std_workspace_alloc-*,libunwind-*,libcfg_if-*,liballoc-*,librustc_std_workspace_core-*,libcore-*,libcompiler_builtins-*}.rlib" "kernel32.lib" "kernel32.lib" "advapi32.lib" "ntdll.lib" "userenv.lib" "ws2_32.lib" "dbghelp.lib" "/defaultlib:msvcrt" "/NXCOMPAT" "/OUT:D:\\vw\\target\\release\\build\\icu_locid_transform_data-a6fc31b7f98e9e52\\build_script_build-a6fc31b7f98e9e52.exe" "/OPT:REF,NOICF" "/DEBUG" "/PDBALTPATH:%_PDB%" "/NATVIS:<sysroot>\\lib\\rustlib\\etc\\intrinsic.natvis" "/NATVIS:<sysroot>\\lib\\rustlib\\etc\\liballoc.natvis" "/NATVIS:<sysroot>\\lib\\rustlib\\etc\\libcore.natvis" "/NATVIS:<sysroot>\\lib\\rustlib\\etc\\libstd.natvis"
= note: some arguments are omitted. use `--verbose` to show all linker arguments
= note: LINK : fatal error LNK1104: cannot open file 'D:\vw\target\release\build\icu_locid_transform_data-a6fc31b7f98e9e52\build_script_build-a6fc31b7f98e9e52.exe'␍
error: could not compile `icu_locid_transform_data` (build script) due to 1 previous error
Caused by:
process didn't exit successfully: `C:\Users\admin\.rustup\toolchains\1.86.0-x86_64-pc-windows-msvc\bin\rustc.exe --crate-name build_script_build --edition=2021 C:\Users\admin\.cargo\registry\src\index.crates.io-1949cf8c6b5b557f\icu_locid_transform_data-1.5.1\build.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --diagnostic-width=119 --crate-type bin --emit=dep-info,link -C embed-bitcode=no -C debug-assertions=off --check-cfg cfg(docsrs,test) --check-cfg "cfg(feature, values())" -C metadata=dea906800d619e89 -C extra-filename=-a6fc31b7f98e9e52 --out-dir D:\vw\target\release\build\icu_locid_transform_data-a6fc31b7f98e9e52 -C strip=debuginfo -L dependency=D:\vw\target\release\deps --cap-lints allow` (exit code: 1)
warning: build failed, waiting for other jobs to finish...
I tried allread a cargo --clean
Has somabody an idea how i can get som more information why i can't compile it?
By the way it is on windows and the project is vaultwarden.
thanks for all help