%global debug_package %{nil}
%global provider github
%global provider_tld com
%global project syndtr
%global repo gocapability
%global import_path %{provider}.%{provider_tld}/%{project}/%{repo}
%global commit 8e4cdcb3c22b40d5e330ade0b68cb2e2a3cf6f98
%global shortcommit %(c=%{commit}; echo ${c:0:7})
Name: golang-%{provider}-%{project}-%{repo}
Version: 0
Release: 0.9.git%{shortcommit}%{?dist}
Summary: POSIX capability library for the Go programming language
License: BSD
URL: https://%{import_path}
Source0: https://%{import_path}/archive/%{commit}/%{repo}-%{shortcommit}.tar.gz
%description
%{summary}
%package devel
BuildRequires: golang >= 1.2.1-3
Requires: golang >= 1.2.1-3
Summary: Source for POSIX capability for the Go programming language
%if 0%{?fedora} >= 19
BuildArch: noarch
%else
ExclusiveArch: %{ix86} x86_64 %{arm}
%endif
Provides: golang(%{import_path}/capability) = %{version}-%{release}
%description devel
%{summary}
This package contains library source intended for
building other packages which use %{project}/%{repo}.
%prep
%setup -q -n %{repo}-%{commit}
%build
%install
install -d -p %{buildroot}/%{gopath}/src/%{import_path}
cp -pav capability %{buildroot}/%{gopath}/src/%{import_path}/
%check
GOPATH=%{buildroot}/%{gopath} go test %{import_path}/capability
%files devel
%doc LICENSE
%dir %{gopath}/src/%{provider}.%{provider_tld}/%{project}
%{gopath}/src/%{import_path}/
%changelog
* Tue Apr 21 2015 jchaloup <jchaloup@redhat.com> - 0-0.9.git8e4cdcb
- Bump to upstream 8e4cdcb3c22b40d5e330ade0b68cb2e2a3cf6f98
related: #1032750
* Sat Aug 16 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0-0.8.git3c85049
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
* Fri Jun 13 2014 Lokesh Mandvekar <lsm5@fedoraproject.org> - 0-0.7.git
- RHBZ#1109039 update to upstream commit 3c85049eaeb429febe7788d9c7aac42322a377fe
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0-0.6.git3454319
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
* Fri Jan 17 2014 Lokesh Mandvekar <lsm5@redhat.com> 0-0.5.git3454319
- exclusivearch for el6+
* Fri Jan 17 2014 Lokesh Mandvekar <lsm5@redhat.com> 0-0.4.git3454319
- require golang as runtime dep
* Wed Nov 20 2013 Vincent Batts <vbatts@redhat.com> 0-0.3.git3454319
- typo
* Wed Nov 20 2013 Vincent Batts <vbatts@redhat.com> 0-0.2.git3454319
- clean up per code review (bz1032750)
* Wed Nov 20 2013 Vincent Batts <vbatts@redhat.com> 0-0.1.git3454319
- initial build