From 38acb6d5c8772e7ed8b96b7c698574fb668b1e81 Mon Sep 17 00:00:00 2001 From: ipkalm Date: Sun, 9 May 2021 19:06:35 +0700 Subject: [PATCH 1/2] New package: v2ray-4.39.2 --- srcpkgs/v2ray/files/v2ray/run | 3 +++ srcpkgs/v2ray/template | 34 ++++++++++++++++++++++++++++++++++ 2 files changed, 37 insertions(+) create mode 100644 srcpkgs/v2ray/files/v2ray/run create mode 100644 srcpkgs/v2ray/template diff --git a/srcpkgs/v2ray/files/v2ray/run b/srcpkgs/v2ray/files/v2ray/run new file mode 100644 index 00000000000000..3b1ac46ab2401b --- /dev/null +++ b/srcpkgs/v2ray/files/v2ray/run @@ -0,0 +1,3 @@ +#!/bin/sh + +exec chpst -u _v2ray v2ray -config=/etc/v2ray/config.json 2>&1 diff --git a/srcpkgs/v2ray/template b/srcpkgs/v2ray/template new file mode 100644 index 00000000000000..f9cf205ecd9ad4 --- /dev/null +++ b/srcpkgs/v2ray/template @@ -0,0 +1,34 @@ +# Template file for 'v2ray' +pkgname=v2ray +version=4.39.2 +revision=1 +wrksrc=${pkgname}-core-${version} +build_style=go +go_import_path="github.com/v2fly/v2ray-core/v4" +go_ldflags="-s -w" +short_desc="Platform for building proxies to bypass network restrictions" +maintainer="ipkalm " +license="MIT" +homepage="https://github.com/v2fly/v2ray-core" +distfiles="https://github.com/v2fly/v2ray-core/archive/v${version}/${pkgname}-${version}.tar.gz" +checksum=bcb35c0fd3fed604762b4c2a0950718b0118d7f4cb0ca9987d716a6a6e471b2b +conf_files="/etc/v2ray/config.json" + +system_accounts="_v2ray" + +do_build() { + export GOFLAGS="-x -p=$XBPS_MAKEJOBS -buildmode=pie -trimpath" + go build -ldflags "${go_ldflags}" -o "${GOPATH}/bin/v2ray" ./main + go build -ldflags "${go_ldflags}" -o "${GOPATH}/bin/v2ctl" -tags "confonly" ./infra/control/main +} + +do_check() { + go test -p 1 -tags json -v -timeout 30m ./... +} + +post_install() { + vlicense LICENSE + vmkdir etc/v2ray + vcopy release/config/*.json etc/v2ray/ + vsv v2ray +} From ad2c02754065cf567007e4bb7942cdaaa22f4fae Mon Sep 17 00:00:00 2001 From: ipkalm Date: Thu, 24 Jun 2021 11:22:11 +0700 Subject: [PATCH 2/2] New package: v2ray-4.40.1 --- srcpkgs/v2ray/template | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/srcpkgs/v2ray/template b/srcpkgs/v2ray/template index f9cf205ecd9ad4..2617e5d5ee8e65 100644 --- a/srcpkgs/v2ray/template +++ b/srcpkgs/v2ray/template @@ -1,6 +1,6 @@ # Template file for 'v2ray' pkgname=v2ray -version=4.39.2 +version=4.40.1 revision=1 wrksrc=${pkgname}-core-${version} build_style=go @@ -11,7 +11,7 @@ maintainer="ipkalm " license="MIT" homepage="https://github.com/v2fly/v2ray-core" distfiles="https://github.com/v2fly/v2ray-core/archive/v${version}/${pkgname}-${version}.tar.gz" -checksum=bcb35c0fd3fed604762b4c2a0950718b0118d7f4cb0ca9987d716a6a6e471b2b +checksum=75b599cb9866c2469056b71f2c0c69cbdab08cf15f6bd2273c893cd0bd16f175 conf_files="/etc/v2ray/config.json" system_accounts="_v2ray"