net-proxy/sing-box: new package, add 1.9.0_rc13
This commit is contained in:
parent
9f891e25d9
commit
65d1228754
2
net-proxy/sing-box/Manifest
Normal file
2
net-proxy/sing-box/Manifest
Normal file
@ -0,0 +1,2 @@
|
||||
DIST sing-box-1.9.0_rc13-vendor.tar.xz 5227952 BLAKE2B 415f328b6146a2bdd7845c3460b3252a1448f47898b1e856b00a8dbd868a8370d596f1243578441c1a07c2a8dc3f78b6ea344cd1d767c06db3b2e32256c9af13 SHA512 79c401bb787864c9d5406efd12ff31fe115db2fb92d127e6038d146a11c1b328797180fadc5e4e0e0e53907394070024832d290834460b7ae31c6e7aa2b12a69
|
||||
DIST sing-box-1.9.0_rc13.tar.gz 365341 BLAKE2B 6f9c4a876032309f71b65a4bc594bd42f6f187025c4a882e2ff1b60907867892a50e78843bb1b430818f6213c51e0b9dc7e89c095386ea7e1e86b0671d0e9702 SHA512 882fc25e1079cd6bef61370b6fafeb9fcf2a3664bc0d2a40f2ba0da26a5581e19f0603d8ee6b4e3f9de8ac90e70399dbea0bda521ba7cb8206c3e38caaf41350
|
27
net-proxy/sing-box/metadata.xml
Normal file
27
net-proxy/sing-box/metadata.xml
Normal file
@ -0,0 +1,27 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
|
||||
<pkgmetadata>
|
||||
<maintainer type="person">
|
||||
<email>me@puqns67.icu</email>
|
||||
<name>Puqns67</name>
|
||||
</maintainer>
|
||||
<upstream>
|
||||
<doc>https://sing-box.sagernet.org/</doc>
|
||||
<bugs-to>https://github.com/SagerNet/sing-box/issues</bugs-to>
|
||||
<remote-id type="github">SagerNet/sing-box</remote-id>
|
||||
</upstream>
|
||||
<use>
|
||||
<flag name="quic">Build with QUIC support</flag>
|
||||
<flag name="grpc">Build with standard gRPC support</flag>
|
||||
<flag name="dhcp">Build with DHCP support</flag>
|
||||
<flag name="wireguard">Build with WireGuard support</flag>
|
||||
<flag name="ech">Build with TLS ECH extension support for TLS outbound</flag>
|
||||
<flag name="utls">Build with uTLS support for TLS outbound</flag>
|
||||
<flag name="reality">Build with reality TLS server support</flag>
|
||||
<flag name="acme">Build with ACME TLS certificate issuer support</flag>
|
||||
<flag name="clash-api">Build with Clash API support</flag>
|
||||
<flag name="v2ray-api">Build with V2Ray API support</flag>
|
||||
<flag name="gvisor">Build with gVisor support</flag>
|
||||
<flag name="tor">Build with embedded Tor support</flag>
|
||||
</use>
|
||||
</pkgmetadata>
|
54
net-proxy/sing-box/sing-box-1.9.0_rc13.ebuild
Normal file
54
net-proxy/sing-box/sing-box-1.9.0_rc13.ebuild
Normal file
@ -0,0 +1,54 @@
|
||||
# Copyright 2024 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
inherit go-module systemd
|
||||
|
||||
_PV="${PV/_/-}"
|
||||
_PV="${_PV/alpha/alpha.}"
|
||||
_PV="${_PV/beta/beta.}"
|
||||
_PV="${_PV/rc/rc.}"
|
||||
|
||||
DESCRIPTION="The universal proxy platform."
|
||||
HOMEPAGE="https://sing-box.sagernet.org/ https://github.com/SagerNet/sing-box"
|
||||
SRC_URI="https://github.com/SagerNet/sing-box/archive/refs/tags/v${_PV}.tar.gz -> ${P}.tar.gz
|
||||
https://github.com/Puqns67/gentoo-deps/releases/download/${P}/${P}-vendor.tar.xz"
|
||||
|
||||
S="${WORKDIR}/${PN}-${_PV}"
|
||||
|
||||
LICENSE="GPL-3+"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~riscv"
|
||||
|
||||
IUSE="+quic grpc +dhcp +wireguard +ech +utls +reality +acme +clash-api v2ray-api +gvisor tor"
|
||||
|
||||
RESTRICT="mirror"
|
||||
|
||||
src_compile() {
|
||||
TAGS=""
|
||||
if use quic; then TAGS+="with_quic,"; fi
|
||||
if use grpc; then TAGS+="with_grpc,"; fi
|
||||
if use dhcp; then TAGS+="with_dhcp,"; fi
|
||||
if use wireguard; then TAGS+="with_wireguard,"; fi
|
||||
if use ech; then TAGS+="with_ech,"; fi
|
||||
if use utls; then TAGS+="with_utls,"; fi
|
||||
if use reality; then TAGS+="with_reality_server,"; fi
|
||||
if use acme; then TAGS+="with_acme,"; fi
|
||||
if use clash-api; then TAGS+="with_clash_api,"; fi
|
||||
if use v2ray-api; then TAGS+="with_v2ray_api,"; fi
|
||||
if use gvisor; then TAGS+="with_gvisor,"; fi
|
||||
if use tor; then TAGS+="with_embedded_tor,"; fi
|
||||
TAGS="${TAGS%,}"
|
||||
|
||||
ego build -o sing-box -trimpath -tags "${TAGS}" \
|
||||
-ldflags "-s -w -X 'github.com/sagernet/sing-box/constant.Version=${PV}' -buildid=" \
|
||||
./cmd/sing-box
|
||||
}
|
||||
|
||||
src_install() {
|
||||
dobin sing-box
|
||||
insinto /etc/sing-box
|
||||
doins release/config/config.json config.json.example
|
||||
systemd_dounit release/config/sing-box{,@}.service
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user