]> git.pld-linux.org Git - SPECS.git/blob - lensfun.spec
SPECS updated Wed 28 Jul 14:48:01 CEST 2021
[SPECS.git] / lensfun.spec
1 #
2 # Conditional build:
3 %bcond_with     sse             # SSE instructions
4 %bcond_with     sse2            # SSE2 instructions
5
6 %ifarch pentium3 pentium4 %{x8664} x32
7 %define with_sse        1
8 %endif
9 %ifarch pentium4 %{x8664} x32
10 %define with_sse2       1
11 %endif
12
13 Summary:        Camera lens database with image correction support
14 Summary(pl.UTF-8):      Baza danych obiektywów z funkcją korekcji zdjęć
15 Name:           lensfun
16 Version:        0.3.2
17 Release:        2
18 License:        LGPL v3 (library), CC-BY-SA v3.0 (lens database)
19 Group:          Libraries
20 Source0:        http://downloads.sourceforge.net/lensfun/%{name}-%{version}.tar.gz
21 # Source0-md5:  247e59a0812ec451f6cd0d20b3379cb5
22 Patch0:         0060-Various-CMake-patches-from-the-mailing-list.patch
23 URL:            http://lensfun.sourceforge.net/
24 BuildRequires:  cmake >= 2.8
25 BuildRequires:  docutils
26 BuildRequires:  doxygen >= 1.5.0
27 BuildRequires:  glib2-devel >= 2.0.0
28 BuildRequires:  libpng-devel >= 1.0
29 BuildRequires:  libstdc++-devel
30 BuildRequires:  make >= 3.81
31 BuildRequires:  pkgconfig
32 BuildRequires:  python
33 BuildRequires:  rpmbuild(macros) >= 1.605
34 BuildRequires:  zlib-devel >= 1.0
35 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
36
37 %description
38 The project provides a database of photographic lenses and a library
39 that allows advanced access to the database including functions to
40 correct images based on intimate knowledge of lens characteristics and
41 calibration data.
42
43 %description -l pl.UTF-8
44 Projekt dostarcza bazę danych obiektywów oraz bibliotekę pozwalającą
45 na dostęp do bazy i dodatkowo oferującą korekcję zdjęć w oparciu o
46 szczegółową charakterystykę obiektywu.
47
48 %package devel
49 Summary:        lensfun library header files
50 Summary(pl.UTF-8):      Pliki nagłówkowe biblioteki lensfun
51 License:        LGPL v3
52 Group:          Development/Libraries
53 Requires:       %{name} = %{version}-%{release}
54
55 %description devel
56 lensfun library header files.
57
58 %description devel -l pl.UTF-8
59 Pliki nagłówkowe biblioteki lensfun.
60
61 %package apidocs
62 Summary:        lensfun API documentation
63 Summary(pl.UTF-8):      Dokumentacja API biblioteki lensfun
64 Group:          Documentation
65 BuildArch:      noarch
66
67 %description apidocs
68 lensfun API documentation.
69
70 %description apidocs -l pl.UTF-8
71 Dokumentacja API biblioteki lensfun.
72
73 %prep
74 %setup -q
75 %patch0 -p1
76
77 %{__sed} -i -e '1s,/usr/bin/env python3,%{__python3},' apps/lensfun-{add-adapter,update-data}
78 %{__sed} -i -e '1s,/usr/bin/env sh,%{__sh},' apps/g-lensfun-update-data
79
80 %build
81 install -d build
82 cd build
83 %cmake .. \
84         -DBUILD_AUXFUN:BOOL=ON \
85         -DBUILD_DOC:BOOL=ON \
86         %{cmake_on_off sse BUILD_FOR_SSE} \
87         %{cmake_on_off sse2 BUILD_FOR_SSE2} \
88         -DBUILD_TESTS:BOOL=OFF \
89         -DCMAKE_INSTALL_DOCDIR:PATH=%{_docdir}/%{name}
90
91 %{__make}
92
93 %install
94 rm -rf $RPM_BUILD_ROOT
95 %{__make} -C build install/fast \
96         DESTDIR=$RPM_BUILD_ROOT
97
98 # packaged as %doc in -apidocs
99 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/%{name}
100
101 %clean
102 rm -rf $RPM_BUILD_ROOT
103
104 %post   -p /sbin/ldconfig
105 %postun -p /sbin/ldconfig
106
107 %files
108 %defattr(644,root,root,755)
109 %doc ChangeLog README.md docs/{cc-by-sa-3.0,manual-main,mounts}.txt
110 %attr(755,root,root) %{_libdir}/liblensfun.so.*.*.*
111 %attr(755,root,root) %ghost %{_libdir}/liblensfun.so.1
112 %attr(755,root,root) %{_bindir}/g-lensfun-update-data
113 %attr(755,root,root) %{_bindir}/lensfun-add-adapter
114 %attr(755,root,root) %{_bindir}/lensfun-update-data
115 %{_mandir}/man1/g-lensfun-update-data.1*
116 %{_mandir}/man1/lensfun-add-adapter.1*
117 %{_mandir}/man1/lensfun-update-data.1*
118 %{_datadir}/lensfun
119
120 %files devel
121 %defattr(644,root,root,755)
122 %attr(755,root,root) %{_libdir}/liblensfun.so
123 %{_includedir}/lensfun
124 %{_pkgconfigdir}/lensfun.pc
125
126 %files apidocs
127 %defattr(644,root,root,755)
128 %doc build/doc_doxygen/*
This page took 0.235516 seconds and 3 git commands to generate.