mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-09-24 04:59:14 -07:00
net-p2p/syncthing: add 1.20.3
Now with icons for .desktop files. Closes: https://bugs.gentoo.org/857000 Signed-off-by: Marek Szuba <marecki@gentoo.org>
This commit is contained in:
@@ -2,3 +2,5 @@ DIST syncthing-1.19.2-deps.tar.xz 206531144 BLAKE2B 88e5246217f792c8258f0074ecb3
|
||||
DIST syncthing-1.19.2.tar.gz 6197504 BLAKE2B 0db0f286a79ef8b9c4b74f9aa2da275f216d0a1cb5e10ec7fbd9a479c55f81ec8b8c06b2dbea6aed135eccf6bf539499c8852a8586bd37c4d0ba9969503a2114 SHA512 51641574e01daf591083e00aa956aeb0b6820eeb660c34dc0c161d2edfc183786dfa3bf50f75b6502b73440e3666672e651f0afc75c26cabbb457f0591d75f89
|
||||
DIST syncthing-1.20.2-deps.tar.xz 96286888 BLAKE2B ddac0c324dc9fedfebb4e7b261dbee301c8fafb473f46959f11df64a311ef32fd7c5dfe3857c0993ee895bb1f92810dd304b95a91447876c2078a4b3f526c393 SHA512 fb060910a33a83f5fdeab01889acf02cd8717e2906eaa34c175882b7b664ae24c1a4d3fba1d112dd01d03ff215c2c40419eda4293bba9e8e31a717a59168838b
|
||||
DIST syncthing-1.20.2.tar.gz 6303918 BLAKE2B 4a9786558584ee3d11d7dc278e99d98a57b727dd2b1e61a82357bc4f9be5d025b3e5b003ae0d44e033991c8fe91aa9668dd653a8dedd200e4d385a827c361918 SHA512 f4abf939ce4023df8bd619d8be393dedc657a9e62d99b3793af32ca88a4478ba6640ccecd6b4ae009a06656e74bca3e462bef717ad17a6e9fa6ac00ef77ea137
|
||||
DIST syncthing-1.20.3-deps.tar.xz 96198124 BLAKE2B 196bffdd1004a00545c046ac3f3f4a2db3f5c779c3e9d0f1fbe1417f8cd27f6b8969a7c4f8c515ad85abad9391b5dbf9b64a6acf949f17b982e6465658d296d2 SHA512 5f8b52af226c2e86be84bb5dfe06a1e76d21f90aaf84cd44d9724cb0c0f918bb80c88fe0fe2c70ff6942626659492ceb5b3d618efa65d401f63eeff8ab6052a0
|
||||
DIST syncthing-1.20.3.tar.gz 6304903 BLAKE2B 61534220a633c8cf9b99e60a43032834874bdf6f3cfd26c81b578148a22ac0d3443f112e5763e3fb916cfea6d7f55564bdfec967e8fa83f0c9502f1dbbe8689c SHA512 429fb13de8b34459794d7c9dff66abe0e6c12086a27af71d90934c2ac09f2a332a103eaa7149baa0b1920ddb676380ab2c0fbcc025d80d032dd7d8d67284328a
|
||||
|
||||
111
net-p2p/syncthing/syncthing-1.20.3.ebuild
Normal file
111
net-p2p/syncthing/syncthing-1.20.3.ebuild
Normal file
@@ -0,0 +1,111 @@
|
||||
# Copyright 1999-2022 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
inherit desktop go-module systemd xdg-utils
|
||||
|
||||
DESCRIPTION="Open Source Continuous File Synchronization"
|
||||
HOMEPAGE="https://syncthing.net"
|
||||
SRC_URI="https://github.com/${PN}/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz
|
||||
https://dev.gentoo.org/~marecki/dists/${CATEGORY}/${PN}/${P}-deps.tar.xz"
|
||||
|
||||
LICENSE="Apache-2.0 BSD BSD-2 CC0-1.0 ISC MIT MPL-2.0 Unlicense"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86"
|
||||
IUSE="selinux tools"
|
||||
|
||||
RDEPEND="acct-group/syncthing
|
||||
acct-user/syncthing
|
||||
tools? ( >=acct-user/stdiscosrv-1
|
||||
>=acct-user/strelaysrv-1 )
|
||||
selinux? ( sec-policy/selinux-syncthing )"
|
||||
|
||||
DOCS=( README.md AUTHORS CONTRIBUTING.md )
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}"/${PN}-1.3.4-TestIssue5063_timeout.patch
|
||||
"${FILESDIR}"/${PN}-1.18.4-tool_users.patch
|
||||
)
|
||||
|
||||
src_prepare() {
|
||||
# Bug #679280
|
||||
xdg_environment_reset
|
||||
|
||||
default
|
||||
sed -i \
|
||||
's|^ExecStart=.*|ExecStart=/usr/libexec/syncthing/stdiscosrv|' \
|
||||
cmd/stdiscosrv/etc/linux-systemd/stdiscosrv.service \
|
||||
|| die
|
||||
sed -i \
|
||||
's|^ExecStart=.*|ExecStart=/usr/libexec/syncthing/strelaysrv|' \
|
||||
cmd/strelaysrv/etc/linux-systemd/strelaysrv.service \
|
||||
|| die
|
||||
|
||||
# We do not need this and it sometimes causes build failures
|
||||
rm -rf cmd/stupgrades
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
GOARCH= go run build.go -version "v${PV}" -no-upgrade -build-out=bin/ \
|
||||
${GOARCH:+-goarch="${GOARCH}"} \
|
||||
build $(usex tools "all" "") || die "build failed"
|
||||
}
|
||||
|
||||
src_test() {
|
||||
go run build.go test || die "test failed"
|
||||
}
|
||||
|
||||
src_install() {
|
||||
local icon_size
|
||||
|
||||
doman man/*.[157]
|
||||
einstalldocs
|
||||
|
||||
dobin bin/syncthing
|
||||
|
||||
domenu etc/linux-desktop/*.desktop
|
||||
for icon_size in 32 64 128 256 512; do
|
||||
newicon -s ${icon_size} assets/logo-${icon_size}.png ${PN}.png
|
||||
done
|
||||
newicon -s scalable assets/logo-only.svg ${PN}.svg
|
||||
|
||||
if use tools; then
|
||||
exeinto /usr/libexec/syncthing
|
||||
local exe
|
||||
for exe in bin/* ; do
|
||||
[[ "${exe}" == "bin/syncthing" ]] || doexe "${exe}"
|
||||
done
|
||||
fi
|
||||
|
||||
systemd_dounit etc/linux-systemd/system/${PN}{@,-resume}.service
|
||||
systemd_douserunit etc/linux-systemd/user/${PN}.service
|
||||
newconfd "${FILESDIR}"/${PN}.confd ${PN}
|
||||
newinitd "${FILESDIR}"/${PN}.initd-r2 ${PN}
|
||||
|
||||
keepdir /var/log/${PN}
|
||||
insinto /etc/logrotate.d
|
||||
newins "${FILESDIR}"/${PN}.logrotate ${PN}
|
||||
|
||||
if use tools; then
|
||||
systemd_dounit cmd/stdiscosrv/etc/linux-systemd/stdiscosrv.service
|
||||
newconfd "${FILESDIR}"/stdiscosrv.confd stdiscosrv
|
||||
newinitd "${FILESDIR}"/stdiscosrv.initd-r1 stdiscosrv
|
||||
|
||||
systemd_dounit cmd/strelaysrv/etc/linux-systemd/strelaysrv.service
|
||||
newconfd "${FILESDIR}"/strelaysrv.confd strelaysrv
|
||||
newinitd "${FILESDIR}"/strelaysrv.initd-r1 strelaysrv
|
||||
|
||||
insinto /etc/logrotate.d
|
||||
newins "${FILESDIR}"/stdiscosrv.logrotate strelaysrv
|
||||
newins "${FILESDIR}"/strelaysrv.logrotate strelaysrv
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
xdg_desktop_database_update
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
xdg_desktop_database_update
|
||||
}
|
||||
Reference in New Issue
Block a user