# Generated by go2rpm 1 %bcond_without check # https://github.com/prometheus/prom2json %global goipath github.com/prometheus/prom2json Version: 1.3.0 %gometa %global common_description %{expand: A tool to scrape a Prometheus client and dump the result as JSON.} %global golicenses LICENSE NOTICE %global godocs CHANGELOG.md CONTRIBUTING.md MAINTAINERS.md README.md Name: %{goname} Release: 1%{?dist} Summary: A tool to scrape a Prometheus client and dump the result as JSON # Upstream license specification: Apache-2.0 License: ASL 2.0 URL: %{gourl} Source0: %{gosource} BuildRequires: golang(github.com/matttproud/golang_protobuf_extensions/pbutil) BuildRequires: golang(github.com/prometheus/client_model/go) BuildRequires: golang(github.com/prometheus/common/expfmt) BuildRequires: golang(github.com/prometheus/common/log) %if %{with check} # Tests BuildRequires: golang(github.com/davecgh/go-spew/spew) %endif %description %{common_description} %gopkg %prep %goprep %build for cmd in cmd/* ; do %gobuild -o %{gobuilddir}/bin/$(basename $cmd) %{goipath}/$cmd done %install %gopkginstall install -m 0755 -vd %{buildroot}%{_bindir} install -m 0755 -vp %{gobuilddir}/bin/* %{buildroot}%{_bindir}/ %if %{with check} %check %gocheck %endif %files %license LICENSE NOTICE %doc CHANGELOG.md CONTRIBUTING.md MAINTAINERS.md README.md %{_bindir}/* %gopkgfiles %changelog * Thu Jul 23 21:44:38 CEST 2020 Robert-André Mauchin - 1.3.0-1 - Initial package