1
0
mirror of synced 2024-12-22 21:00:20 +01:00
TheChymera-overlay/net-p2p/btsync/btsync-1.1.70.ebuild

64 lines
1.5 KiB
Bash
Raw Normal View History

2013-09-28 02:56:52 +02:00
# Copyright (C) 2013 Jonathan Vasquez
2013-09-28 01:18:49 +02:00
# Distributed under the terms of the GNU General Public License v2
2013-09-28 02:56:52 +02:00
EAPI="4"
2013-09-28 01:18:49 +02:00
inherit systemd user
2013-09-28 01:18:49 +02:00
2013-09-28 02:56:52 +02:00
DESCRIPTION="Automatically sync files via secure, distributed technology."
2013-09-28 01:18:49 +02:00
HOMEPAGE="http://labs.bittorrent.com/experiments/sync.html"
2013-09-28 02:56:52 +02:00
SRC_URI="
amd64? ( http://syncapp.bittorrent.com/${PV}/${PN}_x64-${PV}.tar.gz )
x86? ( http://syncapp.bittorrent.com/${PV}/${PN}_i386-${PV}.tar.gz )
arm? ( http://syncapp.bittorrent.com/${PV}/${PN}_arm-${PV}.tar.gz )
ppc? ( http://syncapp.bittorrent.com/${PV}/${PN}_powerpc-${PV}.tar.gz )"
2013-09-28 01:18:49 +02:00
2013-09-28 02:56:52 +02:00
RESTRICT="mirror strip"
2013-09-28 01:18:49 +02:00
LICENSE="BitTorrent"
SLOT="0"
2013-10-20 03:01:10 +02:00
KEYWORDS="amd64 ~x86"
2013-09-28 01:18:49 +02:00
IUSE=""
DEPEND=""
RDEPEND="${DEPEND}"
QA_PREBUILT="opt/${PN}/${PN}"
2013-09-28 01:18:49 +02:00
2013-09-28 02:56:52 +02:00
S="${WORKDIR}"
2013-09-28 01:18:49 +02:00
pkg_setup() {
enewgroup btsync
}
2013-09-28 01:18:49 +02:00
src_install() {
exeinto "/opt/${PN}"
doexe btsync
insinto "/etc/${PN}"
doins "${FILESDIR}/config"
doinitd "${FILESDIR}/init.d/${PN}"
2013-10-16 03:35:47 +02:00
cp ${FILESDIR}/btsync.service ${D}/btsync@.service
systemd_dounit "${D}/btsync@.service"
mkdir ${D}/opt/${PN}/pid/
fowners -R root:btsync /opt/${PN}
fperms -R 775 /opt/${PN}
}
pkg_postinst() {
ewarn "You have to add your user to the btsync group to use btsync.
Do this by running the following command from a root terminal:
usermod -a -G btsync your_user
If you are using systemd you should start the service per user:
systemctl start btsync@your_user
You may also tell your system to automatically launch btsync:
systemctl enable btsync@your_user
You may access the web-GUI at localhost:8888.
"
}