5
0
mirror of https://github.com/wailsapp/wails.git synced 2025-05-02 04:59:38 +08:00

Generalize manual compile steps (#1644)

`go build -tags desktop,production -ldflags "-w -s -H windowsgui"` returns an error on MacOS/Linux.
It is referenced in Wails CLI that manually only `-w -s` are passed by default.
This commit is contained in:
Antonio Cheong 2022-07-24 20:12:45 +08:00 committed by GitHub
parent ebb76d85ed
commit 63b47cc852
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -84,7 +84,7 @@ This step could be done from the command line or a script with `npm run build` o
#### Manual steps #### Manual steps
- For dev build, the minimum command would be: `go build -tags dev -gcflags "all=-N -l"` - For dev build, the minimum command would be: `go build -tags dev -gcflags "all=-N -l"`
- For production build, the minimum command would be: `go build -tags desktop,production -ldflags "-w -s -H windowsgui"` - For production build, the minimum command would be: `go build -tags desktop,production -ldflags "-w -s"`. Add `-H windowsgui` to `ldflags` on Windows
- Ensure that you compile in the same directory as the `.syso` file - Ensure that you compile in the same directory as the `.syso` file
### Compress application ### Compress application