]>
Commit | Line | Data |
---|---|---|
86fd4aa9 JB |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without python # don't build python bindings | |
4 | # | |
914017f0 | 5 | Summary: Little CMS - a library to transform between colour profiles |
ba784bd7 | 6 | Summary(pl.UTF-8): Little CMS - biblioteka do konwersji między profilami kolorów |
914017f0 | 7 | Name: lcms |
896f7926 | 8 | Version: 1.17 |
9cefcb82 | 9 | Release: 2 |
896f7926 | 10 | License: MIT |
914017f0 | 11 | Group: Libraries |
429231dc | 12 | Source0: http://dl.sourceforge.net/lcms/%{name}-%{version}.tar.gz |
896f7926 | 13 | # Source0-md5: 07bdbb4cfb05d21caa58fe3d1c84ddc1 |
14847a72 | 14 | Patch0: %{name}-python.patch |
914017f0 | 15 | URL: http://www.littlecms.com/ |
429231dc | 16 | BuildRequires: autoconf >= 2.57 |
63b969c4 | 17 | BuildRequires: automake >= 1:1.7.2 |
38ffa639 | 18 | BuildRequires: libjpeg-devel |
429231dc | 19 | BuildRequires: libstdc++-devel |
38ffa639 | 20 | BuildRequires: libtiff-devel |
429231dc | 21 | BuildRequires: libtool >= 1:1.4.2-9 |
4af9957c | 22 | BuildRequires: sed >= 4.0 |
64ad2df3 | 23 | %if %{with python} |
14847a72 JB |
24 | BuildRequires: python-devel >= 2.2 |
25 | BuildRequires: swig-python >= 1.3.30 | |
64ad2df3 | 26 | %endif |
38ffa639 | 27 | BuildRequires: zlib-devel |
914017f0 JB |
28 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
29 | ||
30 | # There is no pretty description in source archive... use these. | |
31 | ||
32 | %description | |
33 | lcms does not allow to write profiles, and profile manipulation is not | |
34 | its goal. Instead, lcms focus on implement fast transforms between | |
35 | profiles. | |
36 | ||
b3bff7a9 JR |
37 | %description -l pl.UTF-8 |
38 | lcms nie pozwala na tworzenie profili i obróbka profili nie jest celem | |
39 | tej biblioteki. Natomiast lcms skupia się na implementacji szybkiej | |
40 | konwersji między profilami. | |
914017f0 JB |
41 | |
42 | %package devel | |
43 | Summary: Little CMS - header files and developer's documentation | |
ba784bd7 | 44 | Summary(pl.UTF-8): Little CMS - pliki nagłówkowe i dokumentacja |
914017f0 | 45 | Group: Development/Libraries |
d4a273c7 | 46 | Requires: %{name} = %{version}-%{release} |
914017f0 JB |
47 | |
48 | %description devel | |
49 | Header files needed to compile programs with liblcms and some | |
50 | documentation useful for programmers. | |
51 | ||
b3bff7a9 JR |
52 | %description devel -l pl.UTF-8 |
53 | Pliki nagłówkowe potrzebne do konsolidacji z liblcms oraz dokumentacja | |
54 | dla programistów. | |
914017f0 JB |
55 | |
56 | %package static | |
57 | Summary: Little CMS - static library | |
ba784bd7 | 58 | Summary(pl.UTF-8): Little CMS - biblioteka statyczna |
914017f0 | 59 | Group: Development/Libraries |
d4a273c7 | 60 | Requires: %{name}-devel = %{version}-%{release} |
914017f0 JB |
61 | |
62 | %description static | |
63 | Static version of liblcms. | |
64 | ||
b3bff7a9 | 65 | %description static -l pl.UTF-8 |
914017f0 JB |
66 | Statyczna biblioteka liblcms. |
67 | ||
38ffa639 JB |
68 | %package progs |
69 | Summary: Example and demonstration programs for Little CMS | |
ba784bd7 | 70 | Summary(pl.UTF-8): Programy przykładowe i demonstracyjne do Little CMS |
38ffa639 | 71 | Group: Applications/Graphics |
d4a273c7 | 72 | Requires: %{name} = %{version}-%{release} |
38ffa639 JB |
73 | |
74 | %description progs | |
75 | Example and demonstration programs for Little CMS. | |
76 | ||
b3bff7a9 JR |
77 | %description progs -l pl.UTF-8 |
78 | Programy przykładowe i demonstracyjne do Little CMS. | |
38ffa639 | 79 | |
429231dc JB |
80 | %package -n python-lcms |
81 | Summary: Little CMS module for Python | |
ba784bd7 | 82 | Summary(pl.UTF-8): Moduł Little CMS dla Pythona |
429231dc | 83 | Group: Libraries/Python |
d4a273c7 | 84 | Requires: %{name} = %{version}-%{release} |
429231dc JB |
85 | %pyrequires_eq python |
86 | ||
87 | %description -n python-lcms | |
88 | Little CMS module for Python. | |
89 | ||
b3bff7a9 JR |
90 | %description -n python-lcms -l pl.UTF-8 |
91 | Moduł Little CMS dla Pythona. | |
429231dc | 92 | |
914017f0 JB |
93 | %prep |
94 | %setup -q | |
14847a72 | 95 | %patch0 -p1 |
914017f0 JB |
96 | |
97 | %build | |
14847a72 JB |
98 | # rebuild using newer swig (needed for g++ 4/python 2.5) |
99 | cd python | |
100 | rm -f lcms.py lcms_wrap.cxx | |
101 | swig -python -c++ -I../include lcms.i | |
102 | cd .. | |
5ec09a5a | 103 | %{__libtoolize} |
104 | %{__aclocal} | |
105 | %{__autoconf} | |
106 | %{__automake} | |
429231dc | 107 | %configure \ |
64ad2df3 | 108 | --with%{!?with_python:out}-python |
5ec09a5a | 109 | |
429231dc | 110 | %{__make} |
914017f0 JB |
111 | |
112 | %install | |
113 | rm -rf $RPM_BUILD_ROOT | |
114 | ||
5ec09a5a | 115 | %{__make} install \ |
116 | DESTDIR=$RPM_BUILD_ROOT | |
914017f0 | 117 | |
38ffa639 JB |
118 | install samples/{icctrans,wtpt} tifficc/tifficc $RPM_BUILD_ROOT%{_bindir} |
119 | ||
429231dc JB |
120 | rm -f $RPM_BUILD_ROOT%{py_sitedir}/*.{a,la} |
121 | ||
914017f0 JB |
122 | %clean |
123 | rm -rf $RPM_BUILD_ROOT | |
124 | ||
125 | %post -p /sbin/ldconfig | |
126 | %postun -p /sbin/ldconfig | |
127 | ||
128 | %files | |
129 | %defattr(644,root,root,755) | |
896f7926 | 130 | %doc AUTHORS COPYING NEWS README.1ST |
14847a72 | 131 | %attr(755,root,root) %{_libdir}/liblcms.so.*.*.* |
f723569a | 132 | %attr(755,root,root) %ghost %{_libdir}/liblcms.so.1 |
914017f0 JB |
133 | |
134 | %files devel | |
135 | %defattr(644,root,root,755) | |
44e323b4 | 136 | %doc doc/* |
14847a72 JB |
137 | %attr(755,root,root) %{_libdir}/liblcms.so |
138 | %{_libdir}/liblcms.la | |
429231dc | 139 | %{_includedir}/*.h |
14847a72 | 140 | %{_pkgconfigdir}/lcms.pc |
914017f0 JB |
141 | |
142 | %files static | |
143 | %defattr(644,root,root,755) | |
14847a72 | 144 | %{_libdir}/liblcms.a |
38ffa639 JB |
145 | |
146 | %files progs | |
147 | %defattr(644,root,root,755) | |
148 | %attr(755,root,root) %{_bindir}/* | |
02971f77 | 149 | %{_mandir}/man1/*.1* |
429231dc | 150 | |
64ad2df3 | 151 | %if %{with python} |
429231dc JB |
152 | %files -n python-lcms |
153 | %defattr(644,root,root,755) | |
154 | %attr(755,root,root) %{py_sitedir}/_lcms.so | |
155 | %{py_sitedir}/lcms.py | |
64ad2df3 | 156 | %endif |