removed syncthing (newer version in portage)
This commit is contained in:
parent
c375811b17
commit
6ceedc6219
@ -1,3 +1,6 @@
|
||||
DIST BitTorrent-Sync_arm.tar.gz 5413181 SHA256 80c018ba8672325deb537f77d48b383722ffa28d6ee10434d81915a79b066404 SHA512 ab6a368325ed7f53fdd66c421651d794f24a9f91614b0091d72933c35e044b4d5bb9adcb2bab86b53bd1177db7beed61416f0e284840c6d132838f1fd0f6e99f WHIRLPOOL acbf57a566e670c10e29f541a3425ab6360f90ba9f2688d20fccf9be7ad27350c76cee8ca80e0c60293a9010eea8ad51e55e230fd5b40386b4088b540b61eb9c
|
||||
DIST BitTorrent-Sync_i386.tar.gz 5199007 SHA256 2cc4079f9492be044bd6dc40052349cfabac38a14d9655d0396f701d478813ba SHA512 3227d0d4c96265e6b903d1692e0b5e1ea4c4de8bd539d9850470327329e614f973f19d00fb8956071660e313a41098b269f8639bb0dc7a22868a8284580083ad WHIRLPOOL 0015e301ea7ec29e321589a98ea7773ad538543d3dd9629c7c9e31d96e25943b4431ed6ae6f9f6ce4ae8e0e999e9289701b880e52dc4eebd298b6b450286bcd7
|
||||
DIST BitTorrent-Sync_x64.tar.gz 5535248 SHA256 eb09aacca9b28125b67a8f48f734d6c5453ed2fe8395a940bbabf5db3c88b0d1 SHA512 ca344bee25f66809d3bd887554525bffed220e887958c1b61cccf344e4171f6df93f4d22af16a0cac7ef4fdf5118bc1201bf57e69ff6fc33a31549cf27c4fe07 WHIRLPOOL e84878b8a2796e04c3370677e89cc43b23e6308217a6422f5c215b3edb939aee70a91513853938ec4d60e78a5440b6a27db558488da9dbaa9d3b82e51e2dd696
|
||||
DIST btsync_arm-1.1.70.tar.gz 1279220 SHA256 d79b3cf1881fcab95614693569c950d07dd93ffb70cefd901963dec54b75a05b SHA512 321079de894170eafdd8f923f2e1bfd0909904d350b678707f67566ed0afd1ef8af333270b791d6a429774d7e454da4ef064b417be36b338de2e53599e699bd3 WHIRLPOOL f6499199eae078bc7609aa190a61800866dffbc40fcf08f1ae65456ab6ebf36123e5542b3bbff39f0e61d7ae7161d97684ebed3f091145a90e6eb0b789d3db41
|
||||
DIST btsync_arm-1.1.82.tar.gz 1287272 SHA256 c1502fb7d907caf105c7aa5403f4d575f86aa8ca57817ca90aa4ba1398181a3e SHA512 627e24495f3ee1f48f666a85df8d053f5f7ed51784c23d454410d468773c0d6251211ea188f8235b1cb3c14da20e01a5d4cfdc28b0e16de841a4c805ed2bfbe4 WHIRLPOOL 9d58ff32d68e969a64f2c51cae865b5372f69835b90855de61e927355e794d686760ddef8a651076a6bfb01e4269d15c1e2883f0910f7ac25c3c989097bdf4ed
|
||||
DIST btsync_arm-1.2.82.tar.gz 2244128 SHA256 e9f1a3aacfda8e1b5002228de134e5798ff4e0a69ca749fcde6f803c5b500885 SHA512 203806be2d7f066420b006a3eb3897a67d02fde4edef7778cbf6c17b057e8e5102aeefd08f446854fe7db0a595f2dc0468d6ea5b7d8db110a5d3fafc46656182 WHIRLPOOL 8746e9e924b48429d8847a3a190ebd5db9d9bea1b36c23a05d3e5258908741c3740c28d93d488608d3df36d7466da2d1887df30dd524e5c3bedbd9296c3efebc
|
||||
|
77
net-p2p/btsync/btsync-9999.ebuild
Normal file
77
net-p2p/btsync/btsync-9999.ebuild
Normal file
@ -0,0 +1,77 @@
|
||||
# Distributed under the terms of the GNU General Public License v3
|
||||
# Authors: Horea Christian, Robert Walker
|
||||
|
||||
EAPI=5
|
||||
|
||||
inherit eutils pax-utils user flag-o-matic multilib autotools pam systemd versionator
|
||||
|
||||
DESCRIPTION="Sync files & folders using BitTorrent protocol"
|
||||
HOMEPAGE="http://labs.bittorrent.com/experiments/sync.html"
|
||||
SRC_URI="amd64? ( https://download-cdn.getsync.com/stable/linux-x64/BitTorrent-Sync_x64.tar.gz )
|
||||
x86? ( https://download-cdn.getsync.com/stable/linux-i386/BitTorrent-Sync_i386.tar.gz )
|
||||
arm? ( https://download-cdn.getsync.com/stable/linux-arm/BitTorrent-Sync_arm.tar.gz )"
|
||||
|
||||
RESTRICT="mirror strip"
|
||||
LICENSE="BitTorrent"
|
||||
SLOT="0"
|
||||
KEYWORDS=""
|
||||
IUSE=""
|
||||
|
||||
DEPEND=""
|
||||
RDEPEND="${DEPEND}"
|
||||
|
||||
S="${WORKDIR}"
|
||||
|
||||
QA_PREBUILT="/opt/${PN}/"
|
||||
|
||||
src_install() {
|
||||
dodoc "${S}/LICENSE.TXT"
|
||||
|
||||
newconfd "${FILESDIR}/${PN}_confd" "/${PN}"
|
||||
|
||||
# system-v-init support
|
||||
newinitd "${FILESDIR}/${PN}_initd" "/${PN}"
|
||||
|
||||
# systemd support
|
||||
systemd_dounit "${FILESDIR}/${PN}.service"
|
||||
systemd_newunit "${FILESDIR}/${PN}_at.service" "${PN}@.service"
|
||||
#systemd_newuserunit "${FILESDIR}/${PN}_user.service" "${PN}.service"
|
||||
insinto "$(systemd_get_userunitdir)"
|
||||
newins "${FILESDIR}/${PN}_user.service" "${PN}.service"
|
||||
|
||||
exeinto "/opt/${PN}/bin/"
|
||||
doexe "${FILESDIR}/${PN}_setup"
|
||||
doexe "${PN}"
|
||||
}
|
||||
|
||||
pkg_preinst() {
|
||||
enewgroup "${PN}"
|
||||
enewuser "${PN}" -1 -1 -1 "${PN}"
|
||||
dodir "/run/${PN}"
|
||||
fowners "${PN}":"${PN}" "/run/${PN}"
|
||||
dodir "/var/lib/${PN}"
|
||||
fowners "${PN}":"${PN}" "/var/lib/${PN}"
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
einfo "Auto-generated configuration file is located at /etc/btsync.conf"
|
||||
einfo "(use this file as a template for user-level privilege service units)"
|
||||
einfo ""
|
||||
einfo "systemd"
|
||||
einfo "btsync.service:"
|
||||
einfo " run as a system service as user/group btsync:btsync"
|
||||
einfo " uses /var/lib/btsync for btsync working data"
|
||||
einfo "btsync@<user>.service"
|
||||
einfo " run as a system service but with user privilege"
|
||||
einfo " uses /home/<user>/.btsync/btsync.conf for btsync working data"
|
||||
einfo "btsync_user.service"
|
||||
einfo " run as a standard user service"
|
||||
einfo " uses /home/<user>/.btsync/btsync.conf for btsync working data"
|
||||
einfo ""
|
||||
einfo "Ensure you open the following ports in your firewall:"
|
||||
einfo " btsync.conf specified sync listening port (UDP/TCP)"
|
||||
einfo " port 3838 (UDP) for DHT tracking"
|
||||
einfo ""
|
||||
einfo "WebUI listens on: localhost:(8888), nominally localhost:(7888+UID)"
|
||||
|
||||
}
|
@ -1,12 +0,0 @@
|
||||
*syncthing-0.12.14 (21 Jan 2016)
|
||||
|
||||
21 Jan 2016; <chymera@gentoo.org> +syncthing-0.12.14.ebuild, files/syncthing:
|
||||
net-p2p/syncthing: version bump
|
||||
|
||||
13 Jan 2016; <chymera@gentoo.org> +files/syncthing:
|
||||
net-p2p/syncthing: added syncthing launcher file
|
||||
|
||||
*syncthing-0.12.12 (13 Jan 2016)
|
||||
|
||||
13 Jan 2016; <chymera@gentoo.org> +syncthing-0.12.12.ebuild:
|
||||
net-p2p/syncthing: added ebuild by mva
|
@ -1,2 +0,0 @@
|
||||
DIST syncthing-0.11.11.tar.gz 3217356 SHA256 ed5606305c7f365dffc364b1f72a9a521a99341ddc0cfa75e89430a7558da779 SHA512 2b79b4dcb101322370b9fd0d06e1da3f48b4622dd815884aa2ea942527e6c2937afe8ddf3d036aff05cf7f094eb710a3eb838af4ef511f6e43b37230a218f580 WHIRLPOOL 45003a21c58d959e290fca8b529ae63917496b4e6b0af63dd2d8108a57685e4fa1242133620dbebca5956ae318d793d5462273e1fbffd992f2e1453b129bbb58
|
||||
DIST syncthing-0.11.19.tar.gz 3393477 SHA256 a57bbf9264f8db03e22657958e2b0d77438acc2180be8a24a8d9965d63a00cff SHA512 2015b73022b7bcb616d5fbfef6339b6eedacbdfd40ba00887e04bdb128211eaaebcad15a4af414b5ee16111ccd5cea15e5d7d234e494c087ccccfbf8eeff0bc6 WHIRLPOOL 1c822809bf91837097d2728cb81cdc58b170be5607b5c5355bd3a7bb8f605c6ff4ca622d5fadf2fec2b8e99f12679f8768e4ce7f457ba4f8880aa7a074254038
|
@ -1,15 +0,0 @@
|
||||
# Config file for /etc/init.d/syncthing
|
||||
|
||||
SYNC_NAME="syncthing"
|
||||
SYNC_PIDFILE="/var/run/${SYNC_NAME}.pid"
|
||||
|
||||
# If you are going to run syncthing as a user, also uncomment the SYNC_HOME line
|
||||
SYNC_USER="root"
|
||||
SYNC_GROUP="root"
|
||||
#SYNC_HOME="/home/${SYNC_USER}/.config/${SYNC_NAME}"
|
||||
|
||||
# Make sure SYNC_HOME is set to something so we reduce DRY here and in the init script
|
||||
SYNC_HOME="${SYNC_HOME:-/etc/${SYNC_NAME}}"
|
||||
|
||||
# Any options you want you can set them here
|
||||
SYNC_OPTS="--home=${SYNC_HOME}"
|
@ -1,36 +0,0 @@
|
||||
#!/sbin/runscript
|
||||
|
||||
# Copyright 2014-2015 Jonathan Vasquez <jvasquez1011@gmail.com>
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
DISPLAY_NAME="SyncThing"
|
||||
|
||||
SYNC_PATH="/usr/bin"
|
||||
SYNC_BINARY="${SYNC_PATH}/${SYNC_NAME}"
|
||||
SYNC_USER="${SYNC_USER:-root}"
|
||||
SYNC_GROUP="${SYNC_GROUP:-root}"
|
||||
SYNC_HOME="${SYNC_HOME:-/etc/${SYNC_NAME}}"
|
||||
|
||||
start() {
|
||||
ebegin "Starting ${DISPLAY_NAME}"
|
||||
|
||||
if [[ ${SYNC_USER} == "root" ]]; then
|
||||
SYNC_NAME="root"
|
||||
SYNC_GROUP="root"
|
||||
|
||||
einfo "Running ${DISPLAY_NAME} as root:root. Home directory: ${SYNC_HOME}"
|
||||
fi
|
||||
|
||||
start-stop-daemon -m --pidfile "${SYNC_PIDFILE}" -b \
|
||||
--start --user ${SYNC_USER} --group ${SYNC_GROUP} --exec "${SYNC_BINARY}" -- ${SYNC_OPTS}
|
||||
|
||||
eend $?
|
||||
}
|
||||
|
||||
stop() {
|
||||
ebegin "Stopping ${DISPLAY_NAME}"
|
||||
|
||||
start-stop-daemon --stop --exec "${SYNC_BINARY}" --pidfile "${SYNC_PIDFILE}"
|
||||
|
||||
eend $?
|
||||
}
|
@ -1,29 +0,0 @@
|
||||
#!/sbin/runscript
|
||||
# Copyright 1999-2016 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
SVCUSER=${SVCNAME#*.}
|
||||
pid_file="/run/syncthing-${SVCUSER}/syncthing.pid"
|
||||
|
||||
depend() {
|
||||
need net
|
||||
provide syncthing
|
||||
}
|
||||
|
||||
start_pre() {
|
||||
checkpath -d -m 0775 -o ${SVCUSER}:${SVCUSER} /run/syncthing-${SVCUSER}
|
||||
}
|
||||
|
||||
start() {
|
||||
ebegin "Starting Syncthing"
|
||||
start-stop-daemon --start --make-pidfile --pidfile ${pid_file} \
|
||||
--user ${SVCUSER} --group ${SVCUSER} --background --exec /usr/bin/syncthing -- -no-browser
|
||||
eend $?
|
||||
}
|
||||
|
||||
stop() {
|
||||
ebegin "Stopping Syncthing"
|
||||
start-stop-daemon --stop --pidfile ${pid_file}
|
||||
eend $?
|
||||
}
|
@ -1,8 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
|
||||
<pkgmetadata>
|
||||
<maintainer>
|
||||
<email>jvasquez1011@gmail.com</email>
|
||||
<name>Jonathan Vasquez</name>
|
||||
</maintainer>
|
||||
</pkgmetadata>
|
@ -1,67 +0,0 @@
|
||||
# Copyright 2014-2015 Jonathan Vasquez <jvasquez1011@gmail.com>
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=5
|
||||
|
||||
inherit user systemd
|
||||
|
||||
GITHUB_USER="syncthing"
|
||||
GITHUB_REPO="syncthing"
|
||||
GITHUB_TAG="${PV}"
|
||||
|
||||
NAME="syncthing"
|
||||
DESCRIPTION="Open Source Continuous File Synchronization"
|
||||
HOMEPAGE="http://syncthing.net/"
|
||||
|
||||
SRC_URI="https://github.com/${GITHUB_USER}/${GITHUB_REPO}/archive/v${GITHUB_TAG}.tar.gz -> ${P}.tar.gz"
|
||||
|
||||
RESTRICT="mirror"
|
||||
LICENSE="MPL-2.0"
|
||||
SLOT="0"
|
||||
KEYWORDS="~x86 amd64"
|
||||
|
||||
DEPEND=">=dev-lang/go-1.3.0"
|
||||
|
||||
S="${WORKDIR}"
|
||||
|
||||
configDir="~/.config/syncthing"
|
||||
config="${configDir}/config.xml"
|
||||
|
||||
src_install() {
|
||||
# Create directory structure recommended by SyncThing Documentation
|
||||
# Since Go is "very particular" about file locations.
|
||||
local newBaseDir="src/github.com/${PN}"
|
||||
local newWorkDir="${newBaseDir}/${PN}"
|
||||
|
||||
mkdir -p "${newBaseDir}"
|
||||
mv "${P}" "${newWorkDir}"
|
||||
|
||||
cd "${newWorkDir}"
|
||||
|
||||
# Build SyncThing ;D
|
||||
go run build.go -version v${PV} -no-upgrade=true
|
||||
|
||||
# Copy compiled binary over to image directory
|
||||
dobin "bin/${PN}"
|
||||
|
||||
# Install the OpenRC init/conf files
|
||||
doinitd "${FILESDIR}/init.d/${NAME}"
|
||||
doconfd "${FILESDIR}/conf.d/${NAME}"
|
||||
|
||||
# Install the systemd unit file
|
||||
local systemdServiceFile="etc/linux-systemd/system/${PN}@.service"
|
||||
systemd_dounit "${systemdServiceFile}"
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
elog "This is a breaking change release (0.11.X). If you have other devices that are"
|
||||
elog "running on 0.10.X, you will need to upgrade them as well since these versions"
|
||||
elog "cannot communicate with each other."
|
||||
elog ""
|
||||
elog "In order to be able to view the Web UI remotely (from another machine),"
|
||||
elog "edit your ${config} and change the 127.0.0.1:8080 to 0.0.0.0:8080 in"
|
||||
elog "the 'address' section. This file will only be generated once you start syncthing."
|
||||
elog ""
|
||||
elog "Modify the /etc/conf.d/${PN} file and set the user/group/ and syncthing home directory"
|
||||
elog "before launching. Afterwards, you can start ${PN} by doing a: rc-config start ${PN}"
|
||||
}
|
@ -1,63 +0,0 @@
|
||||
# Copyright 2014-2015 Jonathan Vasquez <jvasquez1011@gmail.com>
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=5
|
||||
|
||||
inherit user systemd
|
||||
|
||||
GITHUB_USER="syncthing"
|
||||
GITHUB_REPO="syncthing"
|
||||
GITHUB_TAG="${PV}"
|
||||
|
||||
NAME="syncthing"
|
||||
DESCRIPTION="Open Source Continuous File Synchronization"
|
||||
HOMEPAGE="http://syncthing.net/"
|
||||
|
||||
SRC_URI="https://github.com/${GITHUB_USER}/${GITHUB_REPO}/archive/v${GITHUB_TAG}.tar.gz -> ${P}.tar.gz"
|
||||
|
||||
RESTRICT="mirror"
|
||||
LICENSE="MPL-2.0"
|
||||
SLOT="0"
|
||||
KEYWORDS="~x86 ~amd64 ~arm"
|
||||
|
||||
DEPEND=">=dev-lang/go-1.3.0"
|
||||
|
||||
S="${WORKDIR}"
|
||||
|
||||
configDir="~/.config/syncthing"
|
||||
config="${configDir}/config.xml"
|
||||
|
||||
src_install() {
|
||||
# Create directory structure recommended by SyncThing Documentation
|
||||
# Since Go is "very particular" about file locations.
|
||||
local newBaseDir="src/github.com/${PN}"
|
||||
local newWorkDir="${newBaseDir}/${PN}"
|
||||
|
||||
mkdir -p "${newBaseDir}"
|
||||
mv "${P}" "${newWorkDir}"
|
||||
|
||||
cd "${newWorkDir}"
|
||||
|
||||
# Build SyncThing ;D
|
||||
go run build.go -version v${PV} -no-upgrade=true
|
||||
|
||||
# Copy compiled binary over to image directory
|
||||
dobin "bin/${PN}"
|
||||
|
||||
# Install the OpenRC init/conf files
|
||||
doinitd "${FILESDIR}/init.d/${NAME}"
|
||||
doconfd "${FILESDIR}/conf.d/${NAME}"
|
||||
|
||||
# Install the systemd unit file
|
||||
local systemdServiceFile="etc/linux-systemd/system/${PN}@.service"
|
||||
systemd_dounit "${systemdServiceFile}"
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
elog "In order to be able to view the Web UI remotely (from another machine),"
|
||||
elog "edit your ${config} and change the 127.0.0.1:8080 to 0.0.0.0:8080 in"
|
||||
elog "the 'address' section. This file will only be generated once you start syncthing."
|
||||
elog ""
|
||||
elog "Modify the /etc/conf.d/${PN} file and set the user/group/ and syncthing home directory"
|
||||
elog "before launching. Afterwards, you can start ${PN} by doing a: rc-config start ${PN}"
|
||||
}
|
@ -1,64 +0,0 @@
|
||||
# Copyright 1999-2016 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI="5"
|
||||
|
||||
inherit eutils base systemd git-r3
|
||||
|
||||
DESCRIPTION="Open, trustworthy and decentralized syncing engine (some kind of analog of DropBox and
|
||||
BTSync)"
|
||||
HOMEPAGE="http://syncthing.net"
|
||||
|
||||
SRC_URI=""
|
||||
EGIT_REPO_URI="https://github.com/syncthing/${PN}"
|
||||
EGIT_COMMIT="v${PV}"
|
||||
|
||||
LICENSE="MIT"
|
||||
SLOT="0"
|
||||
# No ~x86 keyword on godep in the tree
|
||||
KEYWORDS="~amd64"
|
||||
|
||||
COMMON_DEPEND="systemd? ( sys-apps/systemd )"
|
||||
DEPEND="
|
||||
dev-lang/go
|
||||
dev-go/godep
|
||||
"
|
||||
RDEPEND="${DEPEND}"
|
||||
|
||||
DOCS=( README.md AUTHORS LICENSE CONTRIBUTING.md )
|
||||
|
||||
export GOPATH="${S}"
|
||||
|
||||
GO_PN="github.com/syncthing/${PN}"
|
||||
EGIT_CHECKOUT_DIR="${S}/src/${GO_PN}"
|
||||
S="${EGIT_CHECKOUT_DIR}"
|
||||
|
||||
src_compile() {
|
||||
# XXX: All the stuff below needs for "-version" command to show actual info
|
||||
local version="$(git describe --always | sed
|
||||
's/\([v\.0-9]*\)\(-\(beta\|alpha\)[0-9]*\)\?-/\1\2+/')";
|
||||
local date="$(git show -s --format=%ct)";
|
||||
local user="$(whoami)"
|
||||
local host="$(hostname)"; host="${host%%.*}";
|
||||
local lf="-w -X main.Version=${version} -X main.BuildStamp=${date} -X main.BuildUser=${user} -X
|
||||
main.BuildHost=${host}"
|
||||
|
||||
godep go build -ldflags "${lf}" -tags noupgrade ./cmd/syncthing
|
||||
}
|
||||
|
||||
src_install() {
|
||||
dobin syncthing
|
||||
systemd_dounit "${S}/etc/linux-systemd/system/${PN}@.service"
|
||||
systemd_douserunit "${S}/etc/linux-systemd/user/${PN}.service"
|
||||
doinitd "${FILESDIR}/syncthing"
|
||||
base_src_install_docs
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
elog "To run Syncthing for more users, create a symlink to the syncthing init script from a link
|
||||
called"
|
||||
elog "syncthing.username - like so"
|
||||
elog " cd /etc/init.d"
|
||||
elog " ln -s syncthing syncthing.username"
|
||||
}
|
@ -1,60 +0,0 @@
|
||||
# Copyright 1999-2016 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI="5"
|
||||
|
||||
inherit eutils base systemd git-r3
|
||||
|
||||
DESCRIPTION="Open, trustworthy and decentralized syncing engine (some kind of analog of DropBox and BTSync)"
|
||||
HOMEPAGE="http://syncthing.net"
|
||||
|
||||
SRC_URI=""
|
||||
EGIT_REPO_URI="https://github.com/syncthing/${PN}"
|
||||
EGIT_COMMIT="v${PV}"
|
||||
|
||||
LICENSE="MIT"
|
||||
SLOT="0"
|
||||
# No ~x86 keyword on godep in the tree
|
||||
KEYWORDS="~amd64"
|
||||
|
||||
COMMON_DEPEND="systemd? ( sys-apps/systemd )"
|
||||
DEPEND="
|
||||
dev-lang/go
|
||||
dev-go/godep
|
||||
"
|
||||
RDEPEND="${DEPEND}"
|
||||
|
||||
DOCS=( README.md AUTHORS LICENSE CONTRIBUTING.md )
|
||||
|
||||
export GOPATH="${S}"
|
||||
|
||||
GO_PN="github.com/syncthing/${PN}"
|
||||
EGIT_CHECKOUT_DIR="${S}/src/${GO_PN}"
|
||||
S="${EGIT_CHECKOUT_DIR}"
|
||||
|
||||
src_compile() {
|
||||
# XXX: All the stuff below needs for "-version" command to show actual info
|
||||
local version="$(git describe --always | sed 's/\([v\.0-9]*\)\(-\(beta\|alpha\)[0-9]*\)\?-/\1\2+/')";
|
||||
local date="$(git show -s --format=%ct)";
|
||||
local user="$(whoami)"
|
||||
local host="$(hostname)"; host="${host%%.*}";
|
||||
local lf="-w -X main.Version=${version} -X main.BuildStamp=${date} -X main.BuildUser=${user} -X main.BuildHost=${host}"
|
||||
|
||||
godep go build -ldflags "${lf}" -tags noupgrade ./cmd/syncthing
|
||||
}
|
||||
|
||||
src_install() {
|
||||
dobin syncthing
|
||||
systemd_dounit "${S}/etc/linux-systemd/system/${PN}@.service"
|
||||
systemd_douserunit "${S}/etc/linux-systemd/user/${PN}.service"
|
||||
doinitd "${FILESDIR}/syncthing"
|
||||
base_src_install_docs
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
elog "To run Syncthing for more users, create a symlink to the syncthing init script from a link called"
|
||||
elog "syncthing.username - like so"
|
||||
elog " cd /etc/init.d"
|
||||
elog " ln -s syncthing syncthing.username"
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user