]> git.pld-linux.org Git - packages/jq.git/blame - jq.spec
- release 5 (by relup.sh)
[packages/jq.git] / jq.spec
CommitLineData
ab4223ae
ER
1#
2# Conditional build:
d6faab77
JB
3%bcond_without static_libs # static library
4%bcond_without tests # check target
d5afc843 5%bcond_with tests_valgrind # use valgrind for tests (suspectible to glibc false positives)
ab4223ae
ER
6
7%ifnarch %{ix86} %{x8664}
d6faab77 8# valgrind required
ab4223ae
ER
9%undefine with_tests
10%endif
11
12Summary: Command-line JSON processor
d6faab77 13Summary(pl.UTF-8): Procesor JSON działający z linii poleceń
ab4223ae
ER
14Name: jq
15Version: 1.5
4ddf780c 16Release: 5
d6faab77 17License: MIT, Apache, CC-BY, GPL v3
97271e8a 18Group: Applications/Text
d6faab77 19#Source0Download: https://github.com/stedolan/jq/releases
ab4223ae
ER
20Source0: https://github.com/stedolan/jq/releases/download/%{name}-%{version}/jq-%{version}.tar.gz
21# Source0-md5: 0933532b086bd8b6a41c1b162b1731f9
97271e8a 22Patch0: static.patch
ab4223ae 23URL: https://stedolan.github.io/jq/
d6faab77
JB
24BuildRequires: autoconf >= 2.64
25BuildRequires: automake >= 1:1.11.2
26BuildRequires: bison >= 3
ab4223ae 27BuildRequires: flex
d6faab77 28BuildRequires: libtool >= 2:2
ab4223ae 29BuildRequires: oniguruma-devel
d5afc843 30%if %{with tests_valgrind}
ab4223ae
ER
31BuildRequires: valgrind
32%endif
33Requires: %{name}-libs = %{version}-%{release}
34BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
35
36%description
d6faab77 37lightweight and flexible command-line JSON processor.
ab4223ae
ER
38
39jq is like sed for JSON data - you can use it to slice and filter and
40map and transform structured data with the same ease that sed, awk,
41grep and friends let you play with text.
42
43It is written in portable C, and it has zero runtime dependencies.
44
d6faab77
JB
45%description -l pl.UTF-8
46Lekki i elastyczny procesor JSON działający z linii poleceń.
47
48jq jest odpowiednikiem seda dla danych JSON - można go używać do
49podziału, filtrowania, odwzorowywania i przekształceń danych
50strukturalnych tak samo łatwo, jak programy sed, awk, grep i podobne
51pozwalają bawić się tekstem.
52
53Jest napisany w przenośnym C i nie ma dodatkowych zależności.
ab4223ae
ER
54
55%package libs
d6faab77
JB
56Summary: Shared jq library
57Summary(pl.UTF-8): Biblioteka współdzielona jq
ab4223ae
ER
58Group: Libraries
59
60%description libs
d6faab77
JB
61Shared jq library.
62
63%description libs -l pl.UTF-8
64Biblioteka współdzielona jq.
ab4223ae
ER
65
66%package devel
d6faab77
JB
67Summary: Header files for jq library
68Summary(pl.UTF-8): Pliki nagłówkowe biblioteki jq
69Group: Development/Libraries
ab4223ae
ER
70Requires: %{name}-libs = %{version}-%{release}
71
72%description devel
d6faab77
JB
73Header files for jq library.
74
75%description devel -l pl.UTF-8
76Pliki nagłówkowe biblioteki jq.
77
78%package static
79Summary: Static jq library
80Summary(pl.UTF-8): Statyczna biblioteka jq
81Group: Development/Libraries
82Requires: %{name}-devel = %{version}-%{release}
83
84%description static
85Static jq library.
86
87%description static -l pl.UTF-8
88Statyczna biblioteka jq.
ab4223ae
ER
89
90%prep
97271e8a
ER
91%setup -q
92%patch0 -p1
ab4223ae
ER
93
94%build
97271e8a 95%{__libtoolize}
dcd7543b 96%{__aclocal} -I config/m4
97271e8a
ER
97%{__autoconf}
98%{__automake}
ab4223ae 99%configure \
125477e6 100 --disable-docs \
d6faab77 101 %{!?with_static_libs:--disable-static} \
97271e8a 102 --disable-all-static \
d5afc843
JB
103 --disable-silent-rules \
104 %{!?with_tests_valgrind:--disable-valgrind}
ab4223ae 105
26df1630
AO
106echo -e '#!/bin/sh\necho "'%{version}'"' > scripts/version
107
ab4223ae
ER
108%{__make}
109
110# Docs already shipped in jq's tarball.
111# In order to build the manual page, it
d5afc843 112# is necessary to install rake, rubygem-ronn, bonsai
ab4223ae
ER
113# and do the following steps:
114#
115# # yum install rake rubygem-ronn
116# $ cd docs/
117# $ curl -L https://get.rvm.io | bash -s stable --ruby=1.9.3
118# $ source $HOME/.rvm/scripts/rvm
119# $ bundle install
120# $ cd ..
121# $ ./configure
122# $ make real_docs
123
124%if %{with tests}
125%{__make} check
126%endif
127
128%install
129rm -rf $RPM_BUILD_ROOT
130%{__make} install \
131 DESTDIR=$RPM_BUILD_ROOT
132
133%{__rm} -r $RPM_BUILD_ROOT%{_docdir}/%{name}
134%{__rm} $RPM_BUILD_ROOT%{_libdir}/libjq.la
135
136%clean
137rm -rf $RPM_BUILD_ROOT
138
139%post libs -p /sbin/ldconfig
140%postun libs -p /sbin/ldconfig
141
142%files
143%defattr(644,root,root,755)
144%doc README README.md AUTHORS COPYING
145%attr(755,root,root) %{_bindir}/jq
146%{_mandir}/man1/jq.1*
147
148%files libs
149%defattr(644,root,root,755)
150%attr(755,root,root) %{_libdir}/libjq.so.*.*.*
d6faab77 151%attr(755,root,root) %ghost %{_libdir}/libjq.so.1
ab4223ae
ER
152
153%files devel
154%defattr(644,root,root,755)
d6faab77 155%attr(755,root,root) %{_libdir}/libjq.so
ab4223ae
ER
156%{_includedir}/jq.h
157%{_includedir}/jv.h
d6faab77
JB
158
159%if %{with static_libs}
160%files static
161%defattr(644,root,root,755)
162%{_libdir}/libjq.a
163%endif
This page took 0.100239 seconds and 4 git commands to generate.