git-lfs/git-lfs.spec

240 lines
7.7 KiB
RPMSpec
Raw Normal View History

2019-07-11 00:05:43 +00:00
%bcond_without check
# https://github.com/git-lfs/git-lfs
%global goipath github.com/git-lfs/git-lfs
Version: 2.7.2
2018-09-03 22:09:13 +00:00
%gometa
2017-09-02 18:54:44 +00:00
2019-07-11 00:05:43 +00:00
%global common_description %{expand:
Git extension for versioning large files.}
%global golicenses LICENSE.md
%global godocs docs CHANGELOG.md CODE-OF-CONDUCT.md\\\
CONTRIBUTING.md README.md
2017-09-02 18:54:44 +00:00
Name: git-lfs
Release: 3%{?dist}
2017-09-02 18:54:44 +00:00
Summary: Git extension for versioning large files
License: MIT
URL: https://git-lfs.github.io/
2018-09-03 22:09:13 +00:00
Source0: %{gosource}
2019-01-15 06:34:58 +00:00
BuildRequires: golang(github.com/git-lfs/gitobj) >= 1.1.0
2019-07-11 00:05:43 +00:00
BuildRequires: golang(github.com/git-lfs/gitobj/errors) >= 1.1.0
2018-09-03 09:03:36 +00:00
BuildRequires: golang(github.com/git-lfs/go-netrc/netrc) >= 0-0.1.20180827gite0e9ca4
2019-02-22 03:54:51 +00:00
BuildRequires: golang(github.com/git-lfs/wildmatch) >= 1.0.2
2018-09-03 09:03:36 +00:00
BuildRequires: golang(github.com/kr/pty)
2019-02-22 03:54:51 +00:00
BuildRequires: golang(github.com/mattn/go-isatty) >= 0.0.4
2017-09-02 18:54:44 +00:00
BuildRequires: golang(github.com/olekukonko/ts)
2018-09-03 09:03:36 +00:00
BuildRequires: golang(github.com/pkg/errors)
2017-09-02 18:54:44 +00:00
BuildRequires: golang(github.com/rubyist/tracerx)
2019-02-22 03:54:51 +00:00
BuildRequires: golang(github.com/spf13/cobra) >= 0.0.3
2019-07-11 00:05:43 +00:00
BuildRequires: golang(github.com/ThomsonReutersEikon/go-ntlm/ntlm)
2019-02-22 03:54:51 +00:00
BuildRequires: golang(golang.org/x/sync/semaphore)
2019-07-11 00:05:43 +00:00
# Generate man pages
2017-09-02 18:54:44 +00:00
BuildRequires: /usr/bin/ronn
2019-07-11 00:05:43 +00:00
%if %{with check}
# Tests
2019-02-22 03:54:51 +00:00
BuildRequires: golang(github.com/stretchr/testify/assert) >= 1.2.2
BuildRequires: golang(github.com/stretchr/testify/require) >= 1.2.2
2018-09-03 22:09:13 +00:00
BuildRequires: golang(github.com/xeipuuv/gojsonschema)
2017-11-03 08:25:40 +00:00
BuildRequires: perl-Digest-SHA
2018-09-03 09:03:36 +00:00
BuildRequires: perl-Test-Harness
2017-12-01 06:40:06 +00:00
# Tests require full git suite, but not generally needed.
2018-09-03 22:09:13 +00:00
BuildRequires: git >= 1.8.5
2019-07-11 00:05:43 +00:00
%endif
2017-09-02 18:54:44 +00:00
2018-09-03 22:09:13 +00:00
Requires: git-core >= 1.8.5
2017-09-02 18:54:44 +00:00
%description
Git Large File Storage (LFS) replaces large files such as audio samples,
videos, datasets, and graphics with text pointers inside Git, while
storing the file contents on a remote server.
2019-07-11 00:05:43 +00:00
%gopkg
2017-09-02 18:54:44 +00:00
%prep
2019-07-11 00:05:43 +00:00
%goprep
2017-09-02 18:54:44 +00:00
2018-09-04 06:09:13 +00:00
# Modify Makefile so that it expects binaries where we build them.
2019-07-11 00:05:43 +00:00
sed -i -e 's!\.\./bin/!/%{gobuilddir}/bin/!g' t/Makefile
2018-09-04 06:09:13 +00:00
2017-09-02 18:54:44 +00:00
%build
2017-11-04 04:26:57 +00:00
# Build manpages first (some embedding in the executable is done.)
pushd docs
2017-12-04 21:28:40 +00:00
ronn --roff man/*.ronn
2019-07-11 00:05:43 +00:00
%gobuild -o %{gobuilddir}/bin/mangen man/mangen.go
%{gobuilddir}/bin/mangen
2017-11-04 04:26:57 +00:00
popd
2017-09-02 18:54:44 +00:00
2019-07-11 00:05:43 +00:00
%gobuild -o %{gobuilddir}/bin/git-lfs %{goipath}
2017-09-02 18:54:44 +00:00
2017-11-03 08:25:40 +00:00
# Build test executables
2019-07-11 00:05:43 +00:00
for cmd in t/cmd/*.go; do
%gobuild -o "%{gobuilddir}/bin/$(basename $cmd .go)" "$cmd"
2017-11-03 08:25:40 +00:00
done
2019-07-11 00:05:43 +00:00
%gobuild -o "%{gobuilddir}/bin/git-lfs-test-server-api" t/git-lfs-test-server-api/*.go
2017-11-03 08:25:40 +00:00
2017-09-02 18:54:44 +00:00
%install
2019-07-11 00:05:43 +00:00
%gopkginstall
install -Dpm0755 %{gobuilddir}/bin/git-lfs %{buildroot}%{_bindir}/%{name}
2017-09-02 18:54:44 +00:00
install -d -p %{buildroot}%{_mandir}/man1/
install -Dpm0644 docs/man/*.1 %{buildroot}%{_mandir}/man1/
install -d -p %{buildroot}%{_mandir}/man5/
install -Dpm0644 docs/man/*.5 %{buildroot}%{_mandir}/man5/
%post
2019-01-15 06:34:58 +00:00
%{_bindir}/%{name} install --system --skip-repo
2017-09-02 18:54:44 +00:00
%preun
if [ $1 -eq 0 ]; then
2019-01-15 06:34:58 +00:00
%{_bindir}/%{name} uninstall --system --skip-repo
2017-09-02 18:54:44 +00:00
fi
exit 0
2019-07-11 00:05:43 +00:00
%if %{with check}
2017-09-02 18:54:44 +00:00
%check
2019-07-11 00:05:43 +00:00
%gocheck
PATH=%{buildroot}%{_bindir}:%{gobuilddir}/bin:$PATH \
2018-09-04 06:09:13 +00:00
make -C t PROVE_EXTRA_ARGS="-j$(getconf _NPROCESSORS_ONLN)"
2019-07-11 00:05:43 +00:00
%endif
2017-09-02 18:54:44 +00:00
%files
2019-07-11 00:05:43 +00:00
%doc README.md CHANGELOG.md docs
2017-09-02 18:54:44 +00:00
%license LICENSE.md
%{_bindir}/%{name}
%{_mandir}/man1/%{name}*.1*
%{_mandir}/man5/%{name}*.5*
2019-07-11 00:05:43 +00:00
%gopkgfiles
2017-09-02 18:54:44 +00:00
%changelog
* Thu Jul 25 2019 Fedora Release Engineering <releng@fedoraproject.org> - 2.7.2-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
2019-07-11 00:05:43 +00:00
* Wed Jul 10 2019 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 2.7.2-2
- Update to latest Go macros
2019-04-24 09:09:34 +00:00
* Wed Apr 24 2019 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 2.7.2-1
- Update to latest version
2019-02-27 05:31:18 +00:00
* Wed Feb 27 2019 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 2.7.1-1
- Update to latest version
2019-02-22 04:26:10 +00:00
* Thu Feb 21 2019 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 2.7.0-1
- Update to latest version
* Thu Jan 31 2019 Fedora Release Engineering <releng@fedoraproject.org> - 2.6.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
2019-01-15 06:34:58 +00:00
* Tue Jan 15 2019 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 2.6.1-1
- Update to latest version
2019-01-14 23:54:19 +00:00
* Mon Jan 14 2019 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 2.5.2-4
- Rebuilt for dependencies
* Tue Oct 23 2018 Nicolas Mailhot <nim@fedoraproject.org>
- 2.5.2-3
- redhat-rpm-config-123 triggers bugs in gosetup, remove it from Go spec files as its just an alias
- https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org/message/RWD5YATAYAFWKIDZBB7EB6N5DAO4ZKFM/
2018-10-12 02:02:54 +00:00
* Fri Oct 12 2018 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 2.5.2-2
- rebuilt
2018-10-11 00:00:27 +00:00
* Wed Oct 10 2018 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 2.5.2-1
- Update to latest version
2018-09-04 06:52:19 +00:00
* Tue Sep 04 2018 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 2.5.1-1
- Update to latest version
2018-09-03 09:03:36 +00:00
* Mon Sep 03 2018 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 2.5.0-1
- Update to 2.5.0
2018-08-29 06:55:31 +00:00
* Wed Aug 29 2018 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 2.4.2-1
- Update to 2.4.2
2018-07-31 12:40:23 +00:00
* Tue Jul 31 2018 Florian Weimer <fweimer@redhat.com> - 2.4.1-3
- Rebuild with fixed binutils
* Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 2.4.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
2018-05-23 05:34:04 +00:00
* Wed May 23 2018 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 2.4.1-1
- Update to latest release
* Mon May 21 2018 Carl George <carl@george.computer> - 2.4.0-3
- Fix %%preun to correctly remove the lfs filter on uninstall (rhbz#1580357)
* Mon Mar 12 2018 Carl George <carl@george.computer> - 2.4.0-2
- Add %%go_arches fallback to work around Koji issues
2018-03-04 08:00:53 +00:00
* Sun Mar 04 2018 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 2.4.0-1
- Update to latest release.
2018-02-09 22:10:36 +00:00
* Thu Feb 08 2018 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 2.3.4-6
- Add patches to build with Go 1.10.
* Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 2.3.4-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
* Mon Dec 04 2017 Carl George <carl@george.computer> - 2.3.4-4
- Use vendored libraries on RHEL
- Skip test on RHEL
- Don't build man pages on RHEL due to missing ronn
2017-12-04 21:28:40 +00:00
- Don't build html versions of man pages
2018-02-09 22:10:36 +00:00
* Fri Dec 01 2017 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 2.3.4-3
2017-12-01 06:40:06 +00:00
- Require git-core instead of git.
2018-02-09 22:10:36 +00:00
* Fri Nov 03 2017 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 2.3.4-2
- Patch tests to work on slow systems like arm and aarch builders.
2017-11-04 04:26:57 +00:00
- Fix "git lfs help" command.
2018-02-09 22:10:36 +00:00
* Fri Nov 03 2017 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 2.3.4-1
2017-11-03 06:21:27 +00:00
- Update to latest release.
2017-11-03 08:25:40 +00:00
- Run all tests during build.
2017-11-03 06:21:27 +00:00
2018-02-09 22:10:36 +00:00
* Fri Sep 01 2017 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 2.2.1-3
2017-09-02 18:54:44 +00:00
- Remove redundant doc tag on manpages.
- Use path macros in %%post/%%postun.
2018-02-09 22:10:36 +00:00
* Thu Aug 31 2017 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 2.2.1-2
2017-09-02 18:54:44 +00:00
- Disable unnecessary subpackages.
2018-02-09 22:10:36 +00:00
* Sun Jul 30 2017 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 2.2.1-1
2017-09-02 18:54:44 +00:00
- Update to latest version.
* Wed Apr 19 2017 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 2.0.2-2
- Patch up to build with Go 1.7
* Wed Apr 19 2017 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 2.0.2-1
- Update to latest release
- Add some requested macros
* Tue Mar 14 2017 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 2.0.1-1
- Update to latest release
- Don't disable git-lfs globally during upgrade
* Mon Mar 06 2017 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 2.0.0-1
- Update to latest release
* Sun Feb 12 2017 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 1.5.5-1
- Update to latest release
- Add -devel and -unit-test-devel subpackages
- Add post/preun scriptlets for global enablement
* Sun May 15 2016 Igor Gnatenko <i.gnatenko.brain@gmail.com> - 1.2.0-1
- Initial package