Build dll runner with goreleaser
This commit is contained in:
parent
c2249af78d
commit
9a402ede2e
|
|
@ -26,13 +26,30 @@ builds:
|
|||
goarch:
|
||||
- amd64
|
||||
ldflags:
|
||||
- -s -trimpath
|
||||
- -w -trimpath
|
||||
gobinary: "scripts/garble.sh"
|
||||
buildmode: c-shared
|
||||
tags:
|
||||
- release
|
||||
- dll
|
||||
|
||||
- id: "win-dll-loader"
|
||||
env:
|
||||
- CGO_ENABLED=1
|
||||
- CC=x86_64-w64-mingw32-gcc
|
||||
- CXX=x86_64-w64-mingw32-g++
|
||||
main: ./cmd/win-dll-runner/main.go
|
||||
ldflags:
|
||||
- -w
|
||||
gobinary: "scripts/garble.sh"
|
||||
goos:
|
||||
- windows
|
||||
goarch:
|
||||
- amd64
|
||||
tags:
|
||||
- release
|
||||
|
||||
|
||||
- id: "win-release"
|
||||
env:
|
||||
- CGO_ENABLED=1
|
||||
|
|
@ -43,7 +60,7 @@ builds:
|
|||
goarch:
|
||||
- amd64
|
||||
ldflags:
|
||||
- -H=windowsgui
|
||||
- -w -H=windowsgui
|
||||
gobinary: "scripts/garble.sh"
|
||||
tags:
|
||||
- release
|
||||
|
|
@ -52,7 +69,7 @@ upx:
|
|||
- # Whether to enable it or not.
|
||||
#
|
||||
# Templates: allowed.
|
||||
enabled: true
|
||||
enabled: false
|
||||
|
||||
# Filter by build ID.
|
||||
#ids: [build1, build2]
|
||||
|
|
|
|||
|
|
@ -5,7 +5,6 @@ package main
|
|||
|
||||
import (
|
||||
"golang.org/x/sys/windows"
|
||||
"os"
|
||||
)
|
||||
|
||||
func runMainFromDLL() {
|
||||
|
|
@ -17,7 +16,7 @@ func runMainFromDLL() {
|
|||
return
|
||||
}
|
||||
|
||||
_, _, _ := runMainFunc.Call()
|
||||
_, _, _ = runMainFunc.Call()
|
||||
}
|
||||
|
||||
func main() {
|
||||
|
|
|
|||
2
go.mod
2
go.mod
|
|
@ -6,13 +6,13 @@ require (
|
|||
github.com/cloudfoundry/socks5-proxy v0.2.120
|
||||
github.com/xor-gate/sshfp v0.0.0-20200411085609-13942eb67330
|
||||
golang.org/x/crypto v0.25.0
|
||||
golang.org/x/sys v0.22.0
|
||||
)
|
||||
|
||||
require (
|
||||
github.com/cloudfoundry/go-socks5 v0.0.0-20180221174514-54f73bdb8a8e // indirect
|
||||
github.com/miekg/dns v1.1.29 // indirect
|
||||
golang.org/x/net v0.27.0 // indirect
|
||||
golang.org/x/sys v0.22.0 // indirect
|
||||
)
|
||||
|
||||
replace github.com/cloudfoundry/socks5-proxy v0.2.120 => github.com/xor-gate/socks5-proxy v0.0.0-20240724155447-4b9ab1a56d38
|
||||
|
|
|
|||
Loading…
Reference in New Issue