app-misc/gpick:
[gentoo-zh.git] / dev-libs / v2ray-domain-list-community / v2ray-domain-list-community-9999.ebuild
blobe644fa4026239d25f5dc740a5eb05a263a5265c9
1 # Copyright 2021 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
4 EAPI=7
6 inherit go-module
8 DESCRIPTION="Community managed domain list for V2Ray."
9 HOMEPAGE="https://github.com/v2fly/domain-list-community"
10 if [[ ${PV} == *9999 ]]; then
11 inherit git-r3
12 EGIT_REPO_URI="https://github.com/v2fly/domain-list-community.git"
13 else
14 EGO_SUM=(
15 # module deps for non-live version
17 go-module_set_globals
18 SRC_URI="https://github.com/v2fly/domain-list-community/archive/refs/tags/${PV#*_p}.tar.gz -> ${P}.tar.gz
19 ${EGO_SUM_SRC_URI}"
20 KEYWORDS="~amd64 ~arm ~arm64 ~x86"
21 S="${WORKDIR%/}/${PN#v2ray-}-${PV#*_p}"
24 LICENSE="MIT"
25 SLOT="0"
27 DEPEND=""
28 RDEPEND="${DEPEND}
29 !dev-libs/v2ray-domain-list-community-bin
30 !<net-proxy/v2ray-4.38.3
32 BDEPEND=">=dev-lang/go-1.16"
34 src_unpack() {
35 if [[ ${PV} == *9999 ]]; then
36 git-r3_src_unpack
37 #TODO: Looking for a more elegant way to download deps
38 export GOPROXY="https://goproxy.cn,direct" || die
39 go-module_live_vendor
40 else
41 go-module_src_unpack
45 src_compile() {
46 go run ./
49 src_install() {
50 insinto /usr/share/v2ray
51 newins dlc.dat geosite.dat
54 pkg_postinst() {