| 1 | # Based on http://pkgs.fedoraproject.org/cgit/rpms/tig.git/tree/tig.spec?id=5d56685605a3a91f698586130cdd619652b49add
|
|---|
| 2 |
|
|---|
| 3 | %global bash_completion_dir %(pkg-config --variable=completionsdir bash-completion || echo %{_sysconfdir}/bash_completion.d)/
|
|---|
| 4 |
|
|---|
| 5 | Name: tig
|
|---|
| 6 | Version: 2.2.1
|
|---|
| 7 | Release: 1%{?dist}
|
|---|
| 8 | Summary: Text-mode interface for the git revision control system
|
|---|
| 9 |
|
|---|
| 10 | License: GPLv2+
|
|---|
| 11 | URL: http://jonas.nitro.dk/tig
|
|---|
| 12 |
|
|---|
| 13 | %scm_source github https://github.com/bitwiseworks/%{name}-os2 %{name}-%{version}-os2
|
|---|
| 14 |
|
|---|
| 15 | BuildRequires: git
|
|---|
| 16 | BuildRequires: ncurses-devel
|
|---|
| 17 | # TODO don't have these on OS/2 yet.
|
|---|
| 18 | %if 0
|
|---|
| 19 | BuildRequires: xmlto
|
|---|
| 20 | BuildRequires: asciidoc
|
|---|
| 21 | BuildRequires: bash-completion
|
|---|
| 22 | %endif
|
|---|
| 23 | Requires: git
|
|---|
| 24 |
|
|---|
| 25 | %description
|
|---|
| 26 | Tig is a repository browser for the git revision control system that
|
|---|
| 27 | additionally can act as a pager for output from various git commands.
|
|---|
| 28 |
|
|---|
| 29 | When browsing repositories, it uses the underlying git commands to present the
|
|---|
| 30 | user with various views, such as summarized revision log and showing the commit
|
|---|
| 31 | with the log message, diffstat, and the diff.
|
|---|
| 32 |
|
|---|
| 33 | Using it as a pager, it will display input from stdin and colorize it.
|
|---|
| 34 |
|
|---|
| 35 | %debug_package
|
|---|
| 36 |
|
|---|
| 37 |
|
|---|
| 38 | %prep
|
|---|
| 39 | %scm_setup
|
|---|
| 40 | # Generate configure & friends
|
|---|
| 41 | autogen.sh
|
|---|
| 42 |
|
|---|
| 43 | %build
|
|---|
| 44 | export LDFLAGS="-Zomf -Zmap -Zhigh-mem -Zargs-wild -Zargs-resp"
|
|---|
| 45 | export LIBS="-lcx"
|
|---|
| 46 | %configure
|
|---|
| 47 | # TODO don't have these on OS/2 yet (doc-man doc-html won't work).
|
|---|
| 48 | # TODO %make_build requires rpm 4.13.0.1 to fix make -O flag
|
|---|
| 49 | #make_build all doc-man doc-html
|
|---|
| 50 | %{__make} %{_smp_mflags} all
|
|---|
| 51 |
|
|---|
| 52 | #Convert to unix line endings
|
|---|
| 53 | # TODO don't have these on OS/2 yet (doc-man doc-html won't work).
|
|---|
| 54 | #sed -i -e 's/\r//' *.html
|
|---|
| 55 |
|
|---|
| 56 | # Remove shebang from bash-completion script
|
|---|
| 57 | sed -i '/^#!bash/,+1 d' contrib/%{name}-completion.bash
|
|---|
| 58 |
|
|---|
| 59 |
|
|---|
| 60 | %install
|
|---|
| 61 | # TODO don't have these on OS/2 yet (install-doc-man).
|
|---|
| 62 | #make_install install-doc-man
|
|---|
| 63 | %make_install
|
|---|
| 64 |
|
|---|
| 65 | # Setup bash completion
|
|---|
| 66 | install -Dpm 644 contrib/%{name}-completion.bash %{buildroot}%{bash_completion_dir}/%{name}
|
|---|
| 67 |
|
|---|
| 68 |
|
|---|
| 69 | %files
|
|---|
| 70 | %license COPYING
|
|---|
| 71 | # TODO don't have these on OS/2 yet (doc-man doc-html won't work).
|
|---|
| 72 | #doc COPYING NEWS.adoc README.adoc *.html
|
|---|
| 73 | %doc COPYING NEWS.adoc README.adoc
|
|---|
| 74 | %{_bindir}/tig.exe
|
|---|
| 75 | %{bash_completion_dir}
|
|---|
| 76 | %config(noreplace) %{_sysconfdir}/%{name}rc
|
|---|
| 77 | # TODO don't have these on OS/2 yet (doc-man doc-html won't work).
|
|---|
| 78 | %if 0
|
|---|
| 79 | %{_mandir}/man1/tig.1*
|
|---|
| 80 | %{_mandir}/man5/tigrc.5*
|
|---|
| 81 | %{_mandir}/man7/tigmanual.7*
|
|---|
| 82 | %endif
|
|---|
| 83 |
|
|---|
| 84 |
|
|---|
| 85 | %changelog
|
|---|
| 86 | * Mon Apr 10 2017 Dmitriy Kuminov <coding@dmik.org> 2.2.1-1
|
|---|
| 87 | - Initial package.
|
|---|