From 41177a6375681f7cce8ed0062efdd21447b9b281 Mon Sep 17 00:00:00 2001 From: Duncan Overbruck Date: Fri, 26 Dec 2014 17:21:09 +0100 Subject: [PATCH 1/3] New package: syncthing-0.10.13 --- srcpkgs/syncthing/template | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 srcpkgs/syncthing/template diff --git a/srcpkgs/syncthing/template b/srcpkgs/syncthing/template new file mode 100644 index 0000000000..2c81d93bb7 --- /dev/null +++ b/srcpkgs/syncthing/template @@ -0,0 +1,35 @@ +# Template file for 'syncthing' +pkgname=syncthing +version=0.10.13 +revision=1 +wrksrc=src/github.com/syncthing/ +create_wrksrc=yes +hostmakedepends="go>=1.3" +if [ "$CROSS_BUILD" ]; then + hostmakedepends+=" go-cross-linux" +fi +depends="glibc>=2.8" +short_desc="Open Source Continuous File Synchronization" +maintainer="Duncan Overbruck " +license="GPL-3" +homepage="http://syncthing.net/" +distfiles="https://github.com/syncthing/${pkgname}/archive/v${version}.tar.gz" +checksum=19d0d72eac7af99714c047677d892559a8d4c96c73ef5ba50a48cec44a03def2 + +do_build() { + case "$XBPS_TARGET_MACHINE" in + armv6*) export GOARCH=arm; export GOARM=6;; + armv7*) export GOARCH=arm; export GOARM=7;; + i686*) export GOARCH=386;; + x86_64*) export GOARCH=amd64;; + esac + export GOPATH="${XBPS_BUILDDDIR}" + ln -sf ${pkgname}-${version} ${pkgname} + cd ${pkgname}-${version} + go run build.go -no-upgrade +} + +do_install() { + vbin ${pkgname}-${version}/bin/syncthing + vlicense ${pkgname}-${version}/LICENSE +} From e974a63fc3089d5d6790a1db6e26c184c462e66a Mon Sep 17 00:00:00 2001 From: Duncan Overbruck Date: Fri, 26 Dec 2014 17:31:26 +0100 Subject: [PATCH 2/3] remove glibc dependency --- srcpkgs/syncthing/template | 1 - 1 file changed, 1 deletion(-) diff --git a/srcpkgs/syncthing/template b/srcpkgs/syncthing/template index 2c81d93bb7..3b9bde0f76 100644 --- a/srcpkgs/syncthing/template +++ b/srcpkgs/syncthing/template @@ -8,7 +8,6 @@ hostmakedepends="go>=1.3" if [ "$CROSS_BUILD" ]; then hostmakedepends+=" go-cross-linux" fi -depends="glibc>=2.8" short_desc="Open Source Continuous File Synchronization" maintainer="Duncan Overbruck " license="GPL-3" From 5a83ef7ca41d2084015f0eb7172808e66f7cbb22 Mon Sep 17 00:00:00 2001 From: Duncan Overbruck Date: Fri, 26 Dec 2014 18:45:15 +0100 Subject: [PATCH 3/3] fix source path and add readme --- srcpkgs/syncthing/template | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/srcpkgs/syncthing/template b/srcpkgs/syncthing/template index 3b9bde0f76..6e19864c08 100644 --- a/srcpkgs/syncthing/template +++ b/srcpkgs/syncthing/template @@ -2,8 +2,6 @@ pkgname=syncthing version=0.10.13 revision=1 -wrksrc=src/github.com/syncthing/ -create_wrksrc=yes hostmakedepends="go>=1.3" if [ "$CROSS_BUILD" ]; then hostmakedepends+=" go-cross-linux" @@ -22,13 +20,16 @@ do_build() { i686*) export GOARCH=386;; x86_64*) export GOARCH=amd64;; esac - export GOPATH="${XBPS_BUILDDDIR}" - ln -sf ${pkgname}-${version} ${pkgname} - cd ${pkgname}-${version} + + export GOPATH="${PWD}/gopath" + mkdir -p $GOPATH/src/github.com/syncthing + ln -s $PWD $GOPATH/src/github.com/syncthing/${pkgname} + go run build.go -no-upgrade } do_install() { - vbin ${pkgname}-${version}/bin/syncthing - vlicense ${pkgname}-${version}/LICENSE + vbin bin/syncthing + vlicense LICENSE + vdoc README.md }