[packages/gitlab-workhorse] fix version patching
glen
glen at pld-linux.org
Sun Apr 17 21:54:10 CEST 2016
commit 1fecad85d39382f5a594f5c41bf1a2fd7a961cce
Author: Elan Ruusamäe <glen at delfi.ee>
Date: Sun Apr 17 22:53:17 2016 +0300
fix version patching
the go linker magic must be without equal sign for go 1.4
gitlab-workhorse.spec | 4 +++-
go.patch | 10 ++++++++++
2 files changed, 13 insertions(+), 1 deletion(-)
---
diff --git a/gitlab-workhorse.spec b/gitlab-workhorse.spec
index 4aa77d2..803c01a 100644
--- a/gitlab-workhorse.spec
+++ b/gitlab-workhorse.spec
@@ -1,12 +1,13 @@
Summary: An HTTP daemon that serves Git clients
Name: gitlab-workhorse
Version: 0.7.1
-Release: 0.6
+Release: 0.7
License: MIT
Group: Development/Building
# md5 deliberately omitted until this package is useful
Source0: https://gitlab.com/gitlab-org/gitlab-workhorse/repository/archive.tar.gz?ref=v%{version}&/%{name}-%{version}.tar.gz
Source1: %{name}.service
+Patch0: go.patch
URL: https://gitlab.com/gitlab-org/gitlab-workhorse
BuildRequires: git-core
BuildRequires: golang
@@ -23,6 +24,7 @@ Rails app.
%prep
%setup -qc
mv %{name}-v%{version}-*/* .
+%patch0 -p1
%build
# make version similar when built from git:
diff --git a/go.patch b/go.patch
new file mode 100644
index 0000000..2b138d0
--- /dev/null
+++ b/go.patch
@@ -0,0 +1,10 @@
+--- gitlab-workhorse-0.7.1/Makefile~ 2016-03-21 14:04:24.000000000 +0200
++++ gitlab-workhorse-0.7.1/Makefile 2016-04-17 22:52:07.310556758 +0300
+@@ -1,6 +1,6 @@
+ PREFIX=/usr/local
+ VERSION=$(shell git describe)-$(shell date -u +%Y%m%d.%H%M%S)
+-GOBUILD=go build -ldflags "-X main.Version=${VERSION}"
++GOBUILD=go build -ldflags "-X main.Version ${VERSION}"
+
+ all: gitlab-zip-cat gitlab-zip-metadata gitlab-workhorse
+
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/gitlab-workhorse.git/commitdiff/1fecad85d39382f5a594f5c41bf1a2fd7a961cce
More information about the pld-cvs-commit
mailing list