app-editors/zed: add 0.144.3, drop 0.143.7
[gentoo-zh.git] / net-dns / mosdns / mosdns-5.3.1.ebuild
blobcad59f4e4dec971651c961003fc1cda068497a3c
1 # Copyright 1999-2023 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
4 EAPI=8
5 inherit go-module systemd
7 DESCRIPTION="A DNS forwarder"
8 HOMEPAGE="https://github.com/IrineSistiana/mosdns"
9 SRC_URI="
10         https://github.com/IrineSistiana/mosdns/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz
11         https://github.com/peeweep/gentoo-go-deps/releases/download/${P}/${P}-deps.tar.xz
14 RDEPEND="!net-dns/mosdns:4"
15 DEPEND="${RDEPEND}"
16 LICENSE="GPL-3"
17 SLOT="5"
18 KEYWORDS="~amd64 ~arm64 ~riscv"
19 IUSE="systemd"
21 src_compile() {
22         local ldflags="\
23                 -X main.version=${PV} \
24                 -w -s"
25         ego build -o ${P} -trimpath -ldflags "${ldflags}"
26         ./${P} config gen config.yaml
29 src_install() {
30         use systemd && systemd_dounit "${FILESDIR}/mosdns.service"
31         newbin ${P} mosdns
32         insinto /etc/mosdns/
33         doins config.yaml