zerotier / DesktopUI

ZeroTier Desktop Tray Application and UI
https://zerotier.com
Mozilla Public License 2.0
176 stars 27 forks source link

compile fail: DesktopUI-1.8.4\vendor\windows_x86_64_msvc\lib/windows.lib` #31

Closed soarway closed 2 years ago

soarway commented 2 years ago

PS D:\NewDev\DesktopUI-1.8.4> cargo build error: failed to calculate checksum of: D:\NewDev\DesktopUI-1.8.4\vendor\windows_x86_64_msvc\lib/windows.lib

Caused by: failed to open file D:\NewDev\DesktopUI-1.8.4\vendor\windows_x86_64_msvc\lib/windows.lib

PS D:\NewDev\DesktopUI-1.8.4>

soarway commented 2 years ago

PS D:\NewDev\DesktopUI-1.8.4> make make -C tray clean make[1]: Entering directory 'D:/NewDev/DesktopUI-1.8.4/tray' del /q .o .a example .exe .lib make[1]: Leaving directory 'D:/NewDev/DesktopUI-1.8.4/tray' make -C tray zt_lib make[1]: Entering directory 'D:/NewDev/DesktopUI-1.8.4/tray' gcc -O -DTRAY_WINAPI=1 -std=c99 -m64 -fno-exceptions -c -o zt_desktop_tray.o zt_desktop_tray.c ar rcs zt_desktop_tray.lib zt_desktop_tray.o make[1]: Leaving directory 'D:/NewDev/DesktopUI-1.8.4/tray' cargo build --release --target=x86_64-pc-windows-msvc error: failed to calculate checksum of: D:\NewDev\DesktopUI-1.8.4\vendor\windows_x86_64_msvc\lib/windows.lib

Caused by: failed to open file D:\NewDev\DesktopUI-1.8.4\vendor\windows_x86_64_msvc\lib/windows.lib

glimberg commented 2 years ago

Do you have all of the build prerequisites from the README installed?

soarway commented 2 years ago

It's all installed。(gcc, g++, vs2019, cargo ) The total tools Can develop applications normally.

glimberg commented 2 years ago

So I did a little digging in a VM today. I'm not sure why yet, but I got the same thing until I did a cargo vendor -s Cargo.toml and I was able to build after that (I also had to make sure that line endings were checked out as LF from the git repo on Windows, but that's another story). From what I've read, that shouldn't be the case and syncing the vendored code should not be necessary, but it is right now for some reason. I'll have to track down @adamierymenko when he has some time to figure out exactly what is going on here.

soarway commented 2 years ago

Thank you. After executing "cargo vendor -s Cargo.toml", "failed to open file windows.lib" The problem of Lib has been solved。 But new problems arise。

cargo build --target=x86_64-pc-windows-msvc error: the listed checksum of D:\NewDev\DesktopUI\vendor\widestring-0.4.3\src/ucstr.rs has changed: expected: c29a35edbff145e4b0a20916afc7fc7f6ace13675f08dbbfb5abf742d0589b93 actual: c5cf6456f8912cbe8dafbaaad49a421b16325d09417e1b620966ec860f389f4a

directory sources are not intended to be edited, if modifications are required then it is recommended that [patch] is used with a forked copy of the source make: *** [Makefile:27: windows] Error 101

glimberg commented 2 years ago

probably a line endings issue. \n vs \r\n

soarway commented 2 years ago

After executing "cargo vendor -s Cargo.toml", the windows.lib file appears 。

soarway commented 2 years ago

cargo build --target=x86_64-pc-windows-msvc error: the listed checksum of D:\NewDev\DesktopUI\vendor\single-instance\Cargo.toml has changed: expected: 99a6b0d130f498c4d784a9f5a4baee7d25eb03eee1686032061a690b7a1a64f8 actual: efb571e334a56cd78b0ad6401f1c2431ee832cc11aeb2b2ce42d9ac403305651