You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
27 lines
671 B
Bash
27 lines
671 B
Bash
#交叉编译打包不同平台的安装包
|
|
|
|
#linux
|
|
bee pack -be GOOSlinux GOARCH=amd64
|
|
或
|
|
bee pack -be GOOS=linux GOARCH=amd64
|
|
|
|
#windows
|
|
bee pack -be GOOSwindows GOARCH=amd64
|
|
或
|
|
bee pack -be GOOS=windows GOARCH=amd64
|
|
|
|
#go build打包方式
|
|
GOOS=windows GOARCH=amd64 go build
|
|
GOOS=windows GOARCH=amd64 go build -o go_mqtt_pg.exe
|
|
GOOS=windows GOARCH=amd64 go build -o go_mqtt_weather.exe
|
|
|
|
GOOS=linux GOARCH=amd64 go build
|
|
GOOS=linux GOARCH=amd64 go build -o go_mqtt_pg
|
|
|
|
GOOS=freebsd GOARCH=amd64 go build
|
|
GOOS=freebsd GOARCH=amd64 go build -o go_mqtt_pg
|
|
|
|
GOOS=linux GOARCH=arm64 go build
|
|
GOOS=linux GOARCH=arm64 go build -o go_mqtt_pg
|
|
|
|
GOOS=darwin GOARCH=amd64 go build |