]> git.pld-linux.org Git - packages/liblouis.git/blob - liblouis.spec
- release 2 (by relup.sh)
[packages/liblouis.git] / liblouis.spec
1 #
2 # Conditional build:
3 %bcond_without  python2 # Python 2 binding
4 %bcond_without  python3 # Python 3 binding
5 #
6 Summary:        Braille translator and back-translator library
7 Summary(pl.UTF-8):      Biblioteka tłumacząca na i z alfabetu Braille'a
8 Name:           liblouis
9 Version:        3.2.0
10 Release:        2
11 License:        LGPL v2.1+ (library), GPL v3+ (tools)
12 Group:          Libraries
13 #Source0Download: http://liblouis.org/downloads/
14 Source0:        https://github.com/liblouis/liblouis/releases/download/v%{version}/%{name}-%{version}.tar.gz
15 # Source0-md5:  bff9275955610815803a86248c5e712f
16 Patch0:         %{name}-info.patch
17 URL:            http://liblouis.org/
18 BuildRequires:  help2man
19 BuildRequires:  pkgconfig
20 %{?with_python2:BuildRequires:  python-modules >= 1:2.6}
21 %{?with_python3:BuildRequires:  python3-modules >= 1:3.2}
22 BuildRequires:  rpmbuild(macros) >= 1.714
23 BuildRequires:  texinfo >= 5
24 BuildRequires:  yaml-devel
25 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
26
27 %description
28 Liblouis is an open-source braille translator and back-translator. It
29 features support for computer and literary braille, supports
30 contracted and uncontracted translation for many, many languages
31
32 %description -l pl.UTF-8
33 Liblouis to mający otwarte źródła tłumacz na i z alfabetu Braille'a.
34 Ma obsługę komputerowego i literackiego Braille'a, obowiązujących
35 i nie obowiązujących tłumaczeń dla naprawdę wielu języków.
36
37 %package devel
38 Summary:        Header files for liblouis library
39 Summary(pl.UTF-8):      Pliki nagłówkowe biblioteki liblouis
40 Group:          Development/Libraries
41 Requires:       %{name} = %{version}-%{release}
42
43 %description devel
44 Header files for liblouis library.
45
46 %description devel -l pl.UTF-8
47 Pliki nagłówkowe biblioteki liblouis.
48
49 %package static
50 Summary:        Static liblouis library
51 Summary(pl.UTF-8):      Statyczna biblioteka liblouis
52 Group:          Development/Libraries
53 Requires:       %{name}-devel = %{version}-%{release}
54
55 %description static
56 Static liblouis library.
57
58 %description static -l pl.UTF-8
59 Statyczna biblioteka liblouis.
60
61 %package -n python-louis
62 Summary:        Python ctypes binding for liblouis
63 Summary(pl.UTF-8):      Wiązania Pythona oparte na ctypes do biblioteki liblouis
64 Group:          Development/Languages/Python
65 Requires:       %{name} = %{version}-%{release}
66
67 %description -n python-louis
68 Python ctypes binding for liblouis.
69
70 %description -n python-louis -l pl.UTF-8
71 Wiązania Pythona oparte na ctypes do biblioteki liblouis.
72
73 %package -n python3-louis
74 Summary:        Python 3 ctypes binding for liblouis
75 Summary(pl.UTF-8):      Wiązania Pythona 3 oparte na ctypes do biblioteki liblouis
76 Group:          Development/Languages/Python
77 Requires:       %{name} = %{version}-%{release}
78
79 %description -n python3-louis
80 Python 3 ctypes binding for liblouis.
81
82 %description -n python3-louis -l pl.UTF-8
83 Wiązania Pythona 3 oparte na ctypes do biblioteki liblouis.
84
85 %prep
86 %setup -q
87 %patch0 -p1
88
89 %build
90 %configure \
91         --enable-ucs4
92
93 %{__make} -j1 \
94         dlname="liblouis.so.12"
95
96 %if %{with python2}
97 cd python
98 LD_LIBRARY_PATH=$(pwd)/../liblouis/.libs \
99 %py_build
100 cd ..
101 %endif
102
103 %if %{with python2}
104 cd python
105 LD_LIBRARY_PATH=$(pwd)/../liblouis/.libs \
106 %py3_build
107 cd ..
108 %endif
109
110 %install
111 rm -rf $RPM_BUILD_ROOT
112
113 %{__make} install \
114         DESTDIR=$RPM_BUILD_ROOT
115
116 %if %{with python2}
117 cd python
118 LD_LIBRARY_PATH=$(pwd)/../liblouis/.libs \
119 %py_install
120 cd ..
121 %py_postclean
122 %endif
123
124 %if %{with python3}
125 cd python
126 LD_LIBRARY_PATH=$(pwd)/../liblouis/.libs \
127 %py3_install
128 cd ..
129 %endif
130
131 # obsoleted by pkg-config
132 %{__rm} $RPM_BUILD_ROOT%{_libdir}/liblouis.la
133 # packaged as %doc
134 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/liblouis
135
136 %py_postclean
137
138 %clean
139 rm -rf $RPM_BUILD_ROOT
140
141 %post   -p /sbin/ldconfig
142 %postun -p /sbin/ldconfig
143
144 %post   devel -p /sbin/postshell
145 -/usr/sbin/fix-info-dir -c %{_infodir}
146
147 %postun devel -p /sbin/postshell
148 -/usr/sbin/fix-info-dir -c %{_infodir}
149
150 %files
151 %defattr(644,root,root,755)
152 %doc AUTHORS ChangeLog NEWS README TODO
153 %attr(755,root,root) %{_bindir}/lou_allround
154 %attr(755,root,root) %{_bindir}/lou_checkhyphens
155 %attr(755,root,root) %{_bindir}/lou_checktable
156 %attr(755,root,root) %{_bindir}/lou_checkyaml
157 %attr(755,root,root) %{_bindir}/lou_compare
158 %attr(755,root,root) %{_bindir}/lou_debug
159 %attr(755,root,root) %{_bindir}/lou_trace
160 %attr(755,root,root) %{_bindir}/lou_translate
161 %attr(755,root,root) %{_libdir}/liblouis.so.*.*.*
162 %attr(755,root,root) %ghost %{_libdir}/liblouis.so.14
163 %{_datadir}/liblouis
164 %{_mandir}/man1/lou_allround.1*
165 %{_mandir}/man1/lou_checkhyphens.1*
166 %{_mandir}/man1/lou_checktable.1*
167 %{_mandir}/man1/lou_checkyaml.1*
168 %{_mandir}/man1/lou_debug.1*
169 %{_mandir}/man1/lou_trace.1*
170 %{_mandir}/man1/lou_translate.1*
171
172 %files devel
173 %defattr(644,root,root,755)
174 %doc HACKING doc/liblouis.html
175 %attr(755,root,root) %{_libdir}/liblouis.so
176 %{_includedir}/liblouis
177 %{_pkgconfigdir}/liblouis.pc
178 %{_infodir}/liblouis.info*
179
180 %files static
181 %defattr(644,root,root,755)
182 %{_libdir}/liblouis.a
183
184 %if %{with python2}
185 %files -n python-louis
186 %defattr(644,root,root,755)
187 %doc python/README
188 %dir %{py_sitescriptdir}/louis
189 %{py_sitescriptdir}/louis/__init__.py[co]
190 %{py_sitescriptdir}/louis-%{version}-py*.egg-info
191 %endif
192
193 %if %{with python3}
194 %files -n python3-louis
195 %defattr(644,root,root,755)
196 %doc python/README
197 %dir %{py3_sitescriptdir}/louis
198 %{py3_sitescriptdir}/louis/__init__.py
199 %{py3_sitescriptdir}/louis/__pycache__
200 %{py3_sitescriptdir}/louis-%{version}-py*.egg-info
201 %endif
This page took 0.116683 seconds and 3 git commands to generate.