What can be learned from:
go get error and timeout - G0mini - Blog Garden (cnblogs.com)
Flutter package windows desktop program steps (generate .exe file) - Short Book (jianshu.com)
1. First enable flutter windows support
flutter config --enable-windows-desktop
Use flutter devices to view connected devices to see the effect of enabled support
Next, flutter create myapp
Enter the myapp file, run the desktop, flutter run -d windows
Failed to run, flutter doctor
Error solution here: Run the flutter doctor command to check whether the environment is configured successfully and report an error and solution - Programmer Sought
When obtaining licenses, the java version reports an error, but the Java versions supported by the Android SDK are JDK 8 and JDK 11. Maybe the 11 level I installed is not enough?
I am too lazy to update Java, I am opportunistic, and I am going to try to reduce the version of command-line, it can work normally, but I should choose latest
Generally speaking, it is enough to go to the second step of the link above. I have not done the third step, but if I do it, I may encounter the problem that choco does not exist.
In admin powershell:
Set-ExecutionPolicy Bypass -Scope Process -Force; [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))
, So far, the basic flutter software can be successfully run.
2. Operate in your existing project
flutter create .
then run
flutter run -d windows
——————————
Next, deal with the error reporting of personal projects:
a. Building with plugins requires symlink support.
b. Rerun and encounter a new error: NUGET.EXE not found.
CMake Error at flutter/ephemeral/.plugin_symlinks/flutter_blue_plus/windows/CMakeLists.txt:10 (message):
Please install this executable, and run CMake again.
download nuget
Then put it in a custom folder, put the location in the path set by the system; then search for nuget globally in the project
It still won’t work again here, I’m going to restart it (every time I reinstall a new path on my computer, I basically have to restart it if I want it to take effect), but by the way, I added a few options to download in the previous vs.
c. After restarting: the previous problem was solved, but a new problem appeared; should it be caused by a plug-in that cannot be applied to the computer?
CMake Error:
Error evaluating generator expression:
$<TARGET_FILE:flutter_blue_plus_plugin>
No target "flutter_blue_plus_plugin"