generated from demus/golang-rpm-template
118 lines
4.6 KiB
RPMSpec
118 lines
4.6 KiB
RPMSpec
# Generated by go2rpm 1.15.0
|
|
%bcond check 0
|
|
%bcond bootstrap 0
|
|
|
|
%if %{with bootstrap}
|
|
%global debug_package %{nil}
|
|
%endif
|
|
|
|
%if %{with bootstrap}
|
|
%global __requires_exclude %{?__requires_exclude:%{__requires_exclude}|}^golang\\(.*\\)$
|
|
%endif
|
|
|
|
# https://github.com/google/gnostic
|
|
%global goipath github.com/google/gnostic
|
|
Version: 0.5.7
|
|
%global tag v0.5.7-v3refs
|
|
|
|
%gometa -f
|
|
|
|
%global common_description %{expand:
|
|
A compiler for APIs described by the OpenAPI Specification with plugins for
|
|
code generation and other API support tasks.}
|
|
|
|
%global golicenses LICENSE
|
|
%global godocs examples CONTRIBUTING.md README.md\\\
|
|
apps/disco/README.md apps/petstore-builder/README.md\\\
|
|
examples apps/protoc-gen-openapi/README.md\\\
|
|
apps/report/README.md apps/report-messages/README.md\\\
|
|
apps/vocabulary-operations/README.md\\\
|
|
compiler/README.md discovery/README.md\\\
|
|
extensions/README.md generate-gnostic/README.md\\\
|
|
jsonschema/README.md jsonwriter/README.md\\\
|
|
linters/README.md linters/go/gnostic-lint-\\\
|
|
descriptions/README.md linters/go/gnostic-lint-\\\
|
|
paths/README.md linters/node/gnostic-lint-\\\
|
|
operations/README.md linters/node/gnostic-lint-\\\
|
|
responses/README.md openapiv2/README.md\\\
|
|
openapiv3/README.md openapiv3/schema-\\\
|
|
generator/3.0.0.md openapiv3/schema-\\\
|
|
generator/3.0.1.md openapiv3/schema-\\\
|
|
generator/3.0.2.md openapiv3/schema-\\\
|
|
generator/3.1.0.md openapiv3/schema-\\\
|
|
generator/README.md plugins/README.md\\\
|
|
plugins/gnostic-analyze/README.md plugins/gnostic-\\\
|
|
complexity/README.md plugins/gnostic-\\\
|
|
summary/README.md printer/README.md surface/README.md\\\
|
|
tools/README.md
|
|
|
|
Name: golang-github-google-gnostic
|
|
Release: %autorelease
|
|
Summary: A compiler for APIs described by the OpenAPI Specification with plugins for code generation and other API support tasks
|
|
|
|
License: Apache-2.0
|
|
URL: %{gourl}
|
|
Source: %{gosource}
|
|
|
|
%description %{common_description}
|
|
|
|
%gopkg
|
|
|
|
%prep
|
|
%goprep -A
|
|
%autopatch -p1 -q
|
|
|
|
%if %{without bootstrap}
|
|
%generate_buildrequires
|
|
%go_generate_buildrequires
|
|
%endif
|
|
|
|
%if %{without bootstrap}
|
|
%build
|
|
%gobuild -o %{gobuilddir}/bin/gnostic %{goipath}
|
|
for cmd in apps/disco apps/parse-linter-output apps/petstore-builder apps/protoc-gen-openapi apps/report apps/report-messages apps/vocabulary-operations generate-gnostic jsonschema linters/go/gnostic-lint-descriptions linters/go/gnostic-lint-paths openapiv3/schema-generator plugins/gnostic-analyze plugins/gnostic-analyze/summarize plugins/gnostic-complexity plugins/gnostic-linter plugins/gnostic-plugin-request plugins/gnostic-process-plugin-response plugins/gnostic-summary plugins/gnostic-vocabulary tools/format-schema tools/j2y2j; do
|
|
%gobuild -o %{gobuilddir}/bin/$(basename $cmd) %{goipath}/$cmd
|
|
done
|
|
%endif
|
|
|
|
%install
|
|
%gopkginstall
|
|
%if %{without bootstrap}
|
|
install -m 0755 -vd %{buildroot}%{_bindir}
|
|
install -m 0755 -vp %{gobuilddir}/bin/* %{buildroot}%{_bindir}/
|
|
%endif
|
|
|
|
%if %{without bootstrap}
|
|
%if %{with check}
|
|
%check
|
|
%gocheck
|
|
%endif
|
|
%endif
|
|
|
|
%if %{without bootstrap}
|
|
%files
|
|
%license LICENSE
|
|
%doc examples CONTRIBUTING.md README.md apps/disco/README.md
|
|
%doc apps/petstore-builder/README.md examples apps/protoc-gen-openapi/README.md
|
|
%doc apps/report/README.md apps/report-messages/README.md
|
|
%doc apps/vocabulary-operations/README.md compiler/README.md discovery/README.md
|
|
%doc extensions/README.md generate-gnostic/README.md jsonschema/README.md
|
|
%doc jsonwriter/README.md linters/README.md
|
|
%doc linters/go/gnostic-lint-descriptions/README.md
|
|
%doc linters/go/gnostic-lint-paths/README.md
|
|
%doc linters/node/gnostic-lint-operations/README.md
|
|
%doc linters/node/gnostic-lint-responses/README.md openapiv2/README.md
|
|
%doc openapiv3/README.md openapiv3/schema-generator/3.0.0.md
|
|
%doc openapiv3/schema-generator/3.0.1.md openapiv3/schema-generator/3.0.2.md
|
|
%doc openapiv3/schema-generator/3.1.0.md openapiv3/schema-generator/README.md
|
|
%doc plugins/README.md plugins/gnostic-analyze/README.md
|
|
%doc plugins/gnostic-complexity/README.md plugins/gnostic-summary/README.md
|
|
%doc printer/README.md surface/README.md tools/README.md
|
|
%{_bindir}/*
|
|
%endif
|
|
|
|
%gopkgfiles
|
|
|
|
%changelog
|
|
%autochangelog
|