From 661e53d553123947af9fdfdc4f90f0ebd0937b89 Mon Sep 17 00:00:00 2001 From: Hellojack <106379370+H1JK@users.noreply.github.com> Date: Tue, 7 Jun 2022 09:15:10 +0800 Subject: [PATCH] Clean build scripts --- Netch/Servers/V2ray/V2rayConfigUtils.cs | 8 ++++---- Other/libev-mingw/build.ps1 | 10 ---------- Other/libev-mingw/build.sh | 7 ------- Other/shadowsocks-rust/build.ps1 | 15 --------------- Other/shadowsocksr-libev/build.ps1 | 15 --------------- Other/shadowsocksr-libev/build.sh | 20 -------------------- Other/simple-obfs/build.ps1 | 15 --------------- Other/simple-obfs/build.sh | 10 ---------- Other/trojan-go/build.ps1 | 15 --------------- Other/xray-plugin/build.ps1 | 15 --------------- 10 files changed, 4 insertions(+), 126 deletions(-) delete mode 100644 Other/libev-mingw/build.ps1 delete mode 100644 Other/libev-mingw/build.sh delete mode 100644 Other/shadowsocks-rust/build.ps1 delete mode 100644 Other/shadowsocksr-libev/build.ps1 delete mode 100644 Other/shadowsocksr-libev/build.sh delete mode 100644 Other/simple-obfs/build.ps1 delete mode 100644 Other/simple-obfs/build.sh delete mode 100644 Other/trojan-go/build.ps1 delete mode 100644 Other/xray-plugin/build.ps1 diff --git a/Netch/Servers/V2ray/V2rayConfigUtils.cs b/Netch/Servers/V2ray/V2rayConfigUtils.cs index 9a7a6523..b921afa8 100644 --- a/Netch/Servers/V2ray/V2rayConfigUtils.cs +++ b/Netch/Servers/V2ray/V2rayConfigUtils.cs @@ -196,17 +196,17 @@ public static class V2rayConfigUtils var streamSettings = new StreamSettings { network = "tcp", - security = server.TLSSecureType + security = trojan.TLSSecureType }; - if (server.TLSSecureType != "none") + if (trojan.TLSSecureType != "none") { var tlsSettings = new TlsSettings { allowInsecure = Global.Settings.V2RayConfig.AllowInsecure, - serverName = server.Host ?? "" + serverName = trojan.Host ?? "" }; - switch (server.TLSSecureType) + switch (trojan.TLSSecureType) { case "tls": outbound.streamSettings.tlsSettings = tlsSettings; diff --git a/Other/libev-mingw/build.ps1 b/Other/libev-mingw/build.ps1 deleted file mode 100644 index 6e08551c..00000000 --- a/Other/libev-mingw/build.ps1 +++ /dev/null @@ -1,10 +0,0 @@ -Set-Location (Split-Path $MyInvocation.MyCommand.Path -Parent) - -git clone https://github.com/shadowsocks/libev -b 'mingw' src -if ( -Not $? ) { - exit $lastExitCode -} -Set-Location src - -msys2 ..\build.sh -exit $lastExitCode \ No newline at end of file diff --git a/Other/libev-mingw/build.sh b/Other/libev-mingw/build.sh deleted file mode 100644 index a3c30b93..00000000 --- a/Other/libev-mingw/build.sh +++ /dev/null @@ -1,7 +0,0 @@ -#!/usr/bin/env bash -mkdir -p "${PWD}/../../build" - -./configure --prefix="${PWD}/../../build" || exit $? - -make install -j2 -exit $? \ No newline at end of file diff --git a/Other/shadowsocks-rust/build.ps1 b/Other/shadowsocks-rust/build.ps1 deleted file mode 100644 index 966dc8b2..00000000 --- a/Other/shadowsocks-rust/build.ps1 +++ /dev/null @@ -1,15 +0,0 @@ -Set-Location (Split-Path $MyInvocation.MyCommand.Path -Parent) - -git clone https://github.com/shadowsocks/shadowsocks-rust -b 'v1.12.0' src -if ( -Not $? ) { - exit $lastExitCode -} -Set-Location src - -cargo build --features logging,trust-dns,local,utility,local-http,local-tunnel,local-socks4,multi-threaded,stream-cipher --release -if ( -Not $? ) { - exit $lastExitCode -} - -cp -Force '.\target\release\sslocal.exe' '..\..\release\Shadowsocks.exe' -exit 0 \ No newline at end of file diff --git a/Other/shadowsocksr-libev/build.ps1 b/Other/shadowsocksr-libev/build.ps1 deleted file mode 100644 index 18faea09..00000000 --- a/Other/shadowsocksr-libev/build.ps1 +++ /dev/null @@ -1,15 +0,0 @@ -Set-Location (Split-Path $MyInvocation.MyCommand.Path -Parent) - -git clone https://github.com/shadowsocksrr/shadowsocksr-libev -b 'Akkariiin/develop' src -if ( -Not $? ) { - exit $lastExitCode -} -Set-Location src - -msys2 ..\build.sh -if ( -Not $? ) { - exit $lastExitCode -} - -cp -Force '.\ss-local.exe' '..\..\release\ShadowsocksR.exe' -exit 0 diff --git a/Other/shadowsocksr-libev/build.sh b/Other/shadowsocksr-libev/build.sh deleted file mode 100644 index 8db73f91..00000000 --- a/Other/shadowsocksr-libev/build.sh +++ /dev/null @@ -1,20 +0,0 @@ -#!/usr/bin/env bash -git submodule update --init || exit $? - -cd libudns -./autogen.sh || exit $? -./configure || exit $? -make -j2 || exit $? -cd .. - -./autogen.sh || exit $? -CFLAGS+="-fstack-protector" ./configure --disable-documentation --with-ev="${PWD}/../../build" || exit $? - -sed -i "s/%I/%z/g" src/utils.h -sed -i "s/^const/extern const/g" src/tls.h -sed -i "s/^const/extern const/g" src/http.h - -make -j2 || exit $? - -gcc $(find src/ -name "ss_local-*.o") $(find . -name "*.a" ! -name "*.dll.a") "${PWD}/../../build/lib/libev.a" -o ss-local -fstack-protector -static -lpcre -lssl -lcrypto -lws2_32 -s -exit $? \ No newline at end of file diff --git a/Other/simple-obfs/build.ps1 b/Other/simple-obfs/build.ps1 deleted file mode 100644 index 9ecb5aef..00000000 --- a/Other/simple-obfs/build.ps1 +++ /dev/null @@ -1,15 +0,0 @@ -Set-Location (Split-Path $MyInvocation.MyCommand.Path -Parent) - -git clone https://github.com/shadowsocks/simple-obfs src -if ( -Not $? ) { - exit $lastExitCode -} -Set-Location src - -msys2 ..\build.sh -if ( -Not $? ) { - exit $lastExitCode -} - -cp -Force '.\obfs-local.exe' '..\..\release\simple-obfs.exe' -exit 0 \ No newline at end of file diff --git a/Other/simple-obfs/build.sh b/Other/simple-obfs/build.sh deleted file mode 100644 index ff1833aa..00000000 --- a/Other/simple-obfs/build.sh +++ /dev/null @@ -1,10 +0,0 @@ -#!/usr/bin/env bash -git submodule update --init || exit $? - -./autogen.sh || exit $? -./configure --disable-documentation --with-ev="${PWD}/../../build" || exit $? - -make -j2 || exit $? - -gcc $(find src/ -name "obfs_local-*.o") $(find . -name "*.a" ! -name "*.dll.a") "${PWD}/../../build/lib/libev.a" -o obfs-local -fstack-protector -static -lws2_32 -s -exit $? \ No newline at end of file diff --git a/Other/trojan-go/build.ps1 b/Other/trojan-go/build.ps1 deleted file mode 100644 index 4544e44e..00000000 --- a/Other/trojan-go/build.ps1 +++ /dev/null @@ -1,15 +0,0 @@ -Set-Location (Split-Path $MyInvocation.MyCommand.Path -Parent) - -git clone https://github.com/p4gefau1t/trojan-go -b 'v0.10.6' src -if ( -Not $? ) { - exit $lastExitCode -} -Set-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' -tags 'full' -o '..\..\release\Trojan.exe' -exit $lastExitCode \ No newline at end of file diff --git a/Other/xray-plugin/build.ps1 b/Other/xray-plugin/build.ps1 deleted file mode 100644 index bc69a486..00000000 --- a/Other/xray-plugin/build.ps1 +++ /dev/null @@ -1,15 +0,0 @@ -Set-Location (Split-Path $MyInvocation.MyCommand.Path -Parent) - -git clone https://github.com/teddysun/xray-plugin -b 'v1.5.6' src -if ( -Not $? ) { - exit $lastExitCode -} -Set-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\xray-plugin.exe' -exit $lastExitCode \ No newline at end of file