Blob Blame History Raw
# Run tests in check section
# Need to package deps
# Fail with Go 1.12.1
# https://github.com/uber-go/zap/issues/682
%bcond_with check

# https://github.com/uber-go/zap
%global goipath         go.uber.org/zap
%global forgeurl        https://github.com/uber-go/zap
Version:                1.9.1

%global common_description %{expand:
Blazing fast, structured, leveled logging in Go.}

%gometa

Name:           %{goname}
Release:        1%{?dist}
Summary:        Blazing fast, structured, leveled logging in Go
# Detected licences
# - Expat License at 'LICENSE.txt'
License:        MIT
URL:            %{gourl}
Source0:        %{gosource}

BuildRequires: golang(go.uber.org/atomic)
BuildRequires: golang(go.uber.org/multierr)
%if %{with check}
# To package
BuildRequires: golang(github.com/apex/log)
# To package
BuildRequires: golang(github.com/go-kit/kit)
BuildRequires: golang(github.com/pkg/errors)
# To package
BuildRequires: golang(github.com/rs/zerolog)
BuildRequires: golang(github.com/sirupsen/logrus)
%endif

%description
%{common_description}


%package devel
Summary:       %{summary}
BuildArch:     noarch

%description devel
%{common_description}

This package contains library source intended for
building other packages which use import path with
%{goipath} prefix.


%prep
%forgeautosetup


%install
%goinstall


%if %{with check}
%check
%gochecks
%endif


%files devel -f devel.file-list
%license LICENSE.txt
%doc README.md FAQ.md CONTRIBUTING.md CODE_OF_CONDUCT.md CHANGELOG.md


%changelog
* Thu Mar 14 2019 Robert-André Mauchin <zebob.m@gmail.com> - 1.9.1-1
- First package for Fedora