Date: Thursday, June 13, 2019 @ 19:38:15 Author: felixonmars Revision: 481298
archrelease: copy trunk to community-x86_64 Added: v2ray/repos/community-x86_64/PKGBUILD (from rev 481297, v2ray/trunk/PKGBUILD) v2ray/repos/community-x86_64/v2ray.service (from rev 481297, v2ray/trunk/v2ray.service) Deleted: v2ray/repos/community-x86_64/PKGBUILD v2ray/repos/community-x86_64/v2ray.service ---------------+ PKGBUILD | 105 ++++++++++++++++++++++++++++++-------------------------- v2ray.service | 28 +++++++------- 2 files changed, 71 insertions(+), 62 deletions(-) Deleted: PKGBUILD =================================================================== --- PKGBUILD 2019-06-13 19:37:38 UTC (rev 481297) +++ PKGBUILD 2019-06-13 19:38:15 UTC (rev 481298) @@ -1,48 +0,0 @@ -# Maintainer: Felix Yan <felixonm...@archlinux.org> -# Contributor: pandada8 <panda...@gmail.com> - -pkgname=v2ray -pkgver=4.18.0 -pkgrel=1 -pkgdesc="A platform for building proxies to bypass network restrictions" -arch=('x86_64') -url="https://github.com/v2ray/v2ray-core" -license=('MIT') -depends=('glibc') -makedepends=('go-pie' 'git') -backup=(etc/v2ray/config.json) -source=("$pkgname-$pkgver.zip::https://github.com/v2ray/v2ray-core/releases/download/v$pkgver/src_all.zip" - 'v2ray.service') -sha512sums=('5a3acd4c32b8ae96ad148fb0c9c78b8c9ca2a231a51ab728f61d46bb41368279b460d6047d71d22ebfa1d19f624b1bc94b2357b343bab47d84f586df0fa20cab' - '37efc20ef71147f4400eba2bf57766462b5803b5952768bd32d5224f35e37c9c5639aaa19e0f3b63b52063dafd0381f40e2bfbb60dace08b055f0b3245cfa2b7') - -prepare() { - export GOPATH="$srcdir/build" - mkdir -p "$GOPATH"/src - - mv *.com *.io *.org *.net "$GOPATH"/src/ -} - -build() { - go build -o v2ray v2ray.com/core/main - go build -o v2ctl v2ray.com/core/infra/control/main -} - -check() { - cd "$GOPATH"/src/v2ray.com/core - go test -p 1 -tags json -v v2ray.com/core/... -} - -package() { - cd "$GOPATH"/src/v2ray.com/core - install -Dm644 LICENSE "$pkgdir"/usr/share/licenses/v2ray/LICENSE - install -Dm644 release/config/systemd/v2ray.service "$pkgdir"/usr/lib/systemd/system/v2ray.service - sed -i -e '/ExecStart/i Environment=V2RAY_LOCATION_ASSET=/etc/v2ray' \ - -e 's|/usr/bin/v2ray/v2ray|/usr/bin/v2ray|' \ - "$pkgdir"/usr/lib/systemd/system/v2ray.service - install -Dm644 release/config/geoip.dat release/config/geosite.dat release/config/*.json -t "$pkgdir"/etc/v2ray/ - install -Dm755 "$srcdir"/v2ray -t "$pkgdir"/usr/bin/ - install -Dm755 "$srcdir"/v2ctl -t "$pkgdir"/usr/bin/ - - install -Dm644 "$srcdir"/v2ray.service "$pkgdir"/usr/lib/systemd/system/v2ray@.service -} Copied: v2ray/repos/community-x86_64/PKGBUILD (from rev 481297, v2ray/trunk/PKGBUILD) =================================================================== --- PKGBUILD (rev 0) +++ PKGBUILD 2019-06-13 19:38:15 UTC (rev 481298) @@ -0,0 +1,57 @@ +# Maintainer: Felix Yan <felixonm...@archlinux.org> +# Contributor: pandada8 <panda...@gmail.com> + +pkgname=v2ray +pkgver=4.19.1 +pkgrel=1 +pkgdesc="A platform for building proxies to bypass network restrictions" +arch=('x86_64') +url="https://github.com/v2ray/v2ray-core" +license=('MIT') +depends=('glibc') +makedepends=('go-pie' 'golang-golang-x-crypto' 'golang-golang-x-net' 'git') +backup=(etc/v2ray/config.json) +source=("$pkgname-$pkgver.tar.gz::https://github.com/v2ray/v2ray-core/archive/v$pkgver.tar.gz" + 'v2ray.service') +sha512sums=('59d79ddd094d864f5d50d6e76b4ffb91971f3b050b9e712c83e12755547afd9e7a8fbbdcc82d289b1fa0659178ab78f692ac972b63cd16f68f2ccdb581f27014' + '37efc20ef71147f4400eba2bf57766462b5803b5952768bd32d5224f35e37c9c5639aaa19e0f3b63b52063dafd0381f40e2bfbb60dace08b055f0b3245cfa2b7') + +prepare() { + export GOPATH="$srcdir/build:/usr/share/gocode" + mkdir -p "$srcdir"/build/src/v2ray.com + + # mv *.com *.io *.org *.net "$srcdir"/build/src/ + mv v2ray-core-$pkgver "$srcdir"/build/src/v2ray.com/core + + # Future makedepends + go get github.com/golang/protobuf/proto go.starlark.net/starlark go.starlark.net/syntax \ + google.golang.org/grpc + + # Future checkdepends + go get github.com/golang/mock/gomock github.com/google/go-cmp/cmp \ + golang.org/x/sync/errgroup github.com/miekg/dns h12.io/socks +} + +build() { + go build -o v2ray v2ray.com/core/main + go build -o v2ctl v2ray.com/core/infra/control/main +} + +check() { + cd "$srcdir"/build/src/v2ray.com/core + go test -p 1 -tags json -v -timeout 30m v2ray.com/core/... +} + +package() { + cd "$srcdir"/build/src/v2ray.com/core + install -Dm644 LICENSE "$pkgdir"/usr/share/licenses/v2ray/LICENSE + install -Dm644 release/config/systemd/v2ray.service "$pkgdir"/usr/lib/systemd/system/v2ray.service + sed -i -e '/ExecStart/i Environment=V2RAY_LOCATION_ASSET=/etc/v2ray' \ + -e 's|/usr/bin/v2ray/v2ray|/usr/bin/v2ray|' \ + "$pkgdir"/usr/lib/systemd/system/v2ray.service + install -Dm644 release/config/geoip.dat release/config/geosite.dat release/config/*.json -t "$pkgdir"/etc/v2ray/ + install -Dm755 "$srcdir"/v2ray -t "$pkgdir"/usr/bin/ + install -Dm755 "$srcdir"/v2ctl -t "$pkgdir"/usr/bin/ + + install -Dm644 "$srcdir"/v2ray.service "$pkgdir"/usr/lib/systemd/system/v2ray@.service +} Deleted: v2ray.service =================================================================== --- v2ray.service 2019-06-13 19:37:38 UTC (rev 481297) +++ v2ray.service 2019-06-13 19:38:15 UTC (rev 481298) @@ -1,14 +0,0 @@ -[Unit] -Description=V2Ray Service -After=network.target -Wants=network.target - -[Service] -Type=simple -PIDFile=/var/run/v2ray-%i.pid -Environment=V2RAY_LOCATION_ASSET=/etc/v2ray -ExecStart=/usr/bin/v2ray -config /etc/v2ray/%i.json -Restart=on-failure - -[Install] -WantedBy=multi-user.target Copied: v2ray/repos/community-x86_64/v2ray.service (from rev 481297, v2ray/trunk/v2ray.service) =================================================================== --- v2ray.service (rev 0) +++ v2ray.service 2019-06-13 19:38:15 UTC (rev 481298) @@ -0,0 +1,14 @@ +[Unit] +Description=V2Ray Service +After=network.target +Wants=network.target + +[Service] +Type=simple +PIDFile=/var/run/v2ray-%i.pid +Environment=V2RAY_LOCATION_ASSET=/etc/v2ray +ExecStart=/usr/bin/v2ray -config /etc/v2ray/%i.json +Restart=on-failure + +[Install] +WantedBy=multi-user.target