From 929e460ff343180b19cba63113de623120c3500f Mon Sep 17 00:00:00 2001 From: Netch Date: Mon, 13 Sep 2021 01:26:57 +0800 Subject: [PATCH] Build dnsproxy --- Other/dnsproxy/build.ps1 | 19 +++++++++++++++++++ Other/dnsproxy/deps.ps1 | 0 2 files changed, 19 insertions(+) create mode 100644 Other/dnsproxy/build.ps1 create mode 100644 Other/dnsproxy/deps.ps1 diff --git a/Other/dnsproxy/build.ps1 b/Other/dnsproxy/build.ps1 new file mode 100644 index 00000000..44d03ee2 --- /dev/null +++ b/Other/dnsproxy/build.ps1 @@ -0,0 +1,19 @@ +Push-Location (Split-Path $MyInvocation.MyCommand.Path -Parent) + +git clone https://github.com/AdguardTeam/dnsproxy -b 'v0.39.5' src +if ( -Not $? ) { + Pop-Location + exit $lastExitCode +} +Push-Location src + +$Env:CGO_ENABLED='0' +$Env:GOROOT_FINAL='/usr' + +$Env:GOOS='windows' +$Env:GOARCH='amd64' +go build -a -trimpath -asmflags '-s -w' -ldflags '-s -w' -o '..\..\release\dnsproxy.exe' + +Pop-Location +Pop-Location +exit $lastExitCode \ No newline at end of file diff --git a/Other/dnsproxy/deps.ps1 b/Other/dnsproxy/deps.ps1 new file mode 100644 index 00000000..e69de29b