]>
Commit | Line | Data |
---|---|---|
990e8f22 | 1 | Summary: A JSON implementation in C |
d42ebe80 | 2 | Summary(pl.UTF-8): Implementacja JSON w C |
990e8f22 | 3 | Name: json-c |
040cc79c | 4 | Version: 0.11 |
6cafbf58 | 5 | Release: 3 |
d42ebe80 | 6 | License: MIT |
6cafbf58 | 7 | Group: Libraries |
040cc79c JR |
8 | Source0: https://s3.amazonaws.com/json-c_releases/releases/%{name}-%{version}.tar.gz |
9 | # Source0-md5: aa02367d2f7a830bf1e3376f77881e98 | |
10 | URL: https://github.com/json-c/json-c/wiki | |
990e8f22 AM |
11 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
12 | ||
13 | %description | |
14 | JSON-C implements a reference counting object model that allows you to | |
15 | easily construct JSON objects in C, output them as JSON formatted | |
16 | strings and parse JSON formatted strings back into the C | |
17 | representation of JSON objects. | |
18 | ||
d42ebe80 JB |
19 | %description -l pl.UTF-8 |
20 | JSON-C implementuje model obiektów ze zliczaniem odwołań, pozwalający | |
21 | łatwo konstruować obiekty JSON w C, wypisywać je w postaci łańcuchów w | |
22 | formacie JSON i analizować łańcuchy w formacie JSON tworząc z powrotem | |
23 | reprezentacje obiektów JSON w C. | |
24 | ||
990e8f22 AM |
25 | %package devel |
26 | Summary: Header files for the json-c library | |
d42ebe80 | 27 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki json-c |
990e8f22 AM |
28 | Group: Development/Libraries |
29 | Requires: %{name} = %{version}-%{release} | |
30 | ||
31 | %description devel | |
32 | Header files for the json-c library. | |
33 | ||
d42ebe80 JB |
34 | %description devel -l pl.UTF-8 |
35 | Pliki nagłówkowe biblioteki json-c. | |
36 | ||
990e8f22 AM |
37 | %package static |
38 | Summary: Static json-c library | |
d42ebe80 | 39 | Summary(pl.UTF-8): Statyczna biblioteka json-c |
990e8f22 AM |
40 | Group: Development/Libraries |
41 | Requires: %{name}-devel = %{version}-%{release} | |
42 | ||
43 | %description static | |
44 | Static json-c library. | |
45 | ||
d42ebe80 JB |
46 | %description static -l pl.UTF-8 |
47 | Statyczna biblioteka json-c. | |
48 | ||
990e8f22 AM |
49 | %prep |
50 | %setup -q | |
51 | ||
52 | %build | |
53 | %configure | |
040cc79c | 54 | %{__make} -j1 |
990e8f22 AM |
55 | |
56 | %install | |
57 | rm -rf $RPM_BUILD_ROOT | |
58 | ||
59 | %{__make} install \ | |
60 | DESTDIR=$RPM_BUILD_ROOT | |
61 | ||
2233c506 JR |
62 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/*.la |
63 | ||
6cafbf58 JB |
64 | # link with libjson-c directly (stub libjson won't work with --no-copy-dt-needed-entries |
65 | ln -sf $(basename $RPM_BUILD_ROOT%{_libdir}/libjson-c.so.*.*.*) $RPM_BUILD_ROOT%{_libdir}/libjson.so | |
66 | ||
990e8f22 AM |
67 | %clean |
68 | rm -rf $RPM_BUILD_ROOT | |
69 | ||
70 | %post -p /sbin/ldconfig | |
71 | %postun -p /sbin/ldconfig | |
72 | ||
6cafbf58 JB |
73 | %pretrans devel |
74 | # transition from 0.11-2 | |
75 | [ ! -L %{_includedir}/json-c ] || rm -f %{_includedir}/json-c | |
76 | # transition from <= 0.10 and 0.11-2 | |
77 | if [ -d %{_includedir}/json -a ! -d %{_includedir}/json-c ]; then | |
78 | mv -f %{_includedir}/json %{_includedir}/json-c | |
79 | ln -sf json-c %{_includedir}/json | |
80 | fi | |
81 | ||
990e8f22 AM |
82 | %files |
83 | %defattr(644,root,root,755) | |
d42ebe80 | 84 | %doc AUTHORS COPYING ChangeLog README README.html |
990e8f22 AM |
85 | %attr(755,root,root) %{_libdir}/libjson.so.*.*.* |
86 | %attr(755,root,root) %ghost %{_libdir}/libjson.so.0 | |
2233c506 JR |
87 | %attr(755,root,root) %{_libdir}/libjson-c.so.*.*.* |
88 | %attr(755,root,root) %ghost %{_libdir}/libjson-c.so.2 | |
990e8f22 AM |
89 | |
90 | %files devel | |
91 | %defattr(644,root,root,755) | |
990e8f22 | 92 | %attr(755,root,root) %{_libdir}/libjson.so |
2233c506 | 93 | %attr(755,root,root) %{_libdir}/libjson-c.so |
d42ebe80 | 94 | %{_includedir}/json |
2233c506 | 95 | %{_includedir}/json-c |
990e8f22 | 96 | %{_pkgconfigdir}/json.pc |
2233c506 | 97 | %{_pkgconfigdir}/json-c.pc |
990e8f22 AM |
98 | |
99 | %files static | |
100 | %defattr(644,root,root,755) | |
101 | %{_libdir}/libjson.a | |
2233c506 | 102 | %{_libdir}/libjson-c.a |