]>
Commit | Line | Data |
---|---|---|
6a1b752e JB |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without apidocs # API documentation | |
4 | %bcond_without static_libs # static library | |
5 | %bcond_without tests # unit tests | |
6 | # | |
30c49423 | 7 | %define fribidi_ver 1.0.6 |
d7c1a71d | 8 | # |
6a1b752e JB |
9 | Summary: Library for complex text layout |
10 | Summary(pl.UTF-8): Biblioteka do skomplikowanego układu tekstu | |
11 | Name: libraqm | |
30c49423 | 12 | Version: 0.9.0 |
b1d76c38 | 13 | Release: 1 |
6a1b752e JB |
14 | License: MIT |
15 | Group: Libraries | |
16 | #Source0Download: https://github.com/HOST-Oman/libraqm/releases | |
30c49423 JB |
17 | Source0: https://github.com/HOST-Oman/libraqm/releases/download/v%{version}/raqm-%{version}.tar.xz |
18 | # Source0-md5: 10229aa3fad2a70e5dd4c693995da823 | |
6a1b752e | 19 | URL: https://github.com/HOST-Oman/libraqm |
30c49423 JB |
20 | # pkgconfig(freetype2) >= 24.0.18 |
21 | BuildRequires: freetype-devel >= 1:2.11.0 | |
d7c1a71d | 22 | BuildRequires: fribidi-devel >= %{fribidi_ver} |
6a1b752e | 23 | %{?with_tests:BuildRequires: glib2-devel >= 2.0} |
21e35c24 | 24 | %if %{with tests} && %(locale -a | grep -q '^C\.utf8$'; echo $?) |
6a1b752e JB |
25 | BuildRequires: glibc-localedb-all |
26 | %endif | |
27 | BuildRequires: gtk-doc >= 1.14 | |
30c49423 JB |
28 | BuildRequires: harfbuzz-devel >= 3.0.0 |
29 | BuildRequires: meson | |
30 | BuildRequires: ninja >= 1.5 | |
6a1b752e | 31 | BuildRequires: pkgconfig >= 1:0.20 |
30c49423 JB |
32 | BuildRequires: rpmbuild(macros) >= 1.736 |
33 | BuildRequires: tar >= 1:1.22 | |
34 | BuildRequires: xz | |
d7c1a71d | 35 | Requires: fribidi >= %{fribidi_ver} |
6a1b752e JB |
36 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
37 | ||
38 | %description | |
39 | Raqm is a small library that encapsulates the logic for complex text | |
40 | layout and provide a convenient API. | |
41 | ||
42 | It currently provides bidirectional text support (using FriBiDi), | |
43 | shaping (using HarfBuzz), and proper script itemization. As a result, | |
44 | Raqm can support most writing systems covered by Unicode. | |
45 | ||
46 | %description -l pl.UTF-8 | |
47 | Raqm to mała biblioteka opakowująca logikę złożonego układu tekstu i | |
48 | udostępniająca wygodne API. | |
49 | ||
50 | Obecnie zapewnia obsługę tekstu dwukierunkowego (przy użyciu FriBiDi), | |
51 | formowanie (przy użyciu HarfBuzz) i właściwe wyszczególnienie pisma. | |
52 | W efekcie Raqm potrafi obsłużyć większość systemów pisma pokrytych | |
53 | przez Unikod. | |
54 | ||
55 | %package devel | |
56 | Summary: Header files for Raqm library | |
57 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki Raqm | |
58 | Group: Development/Libraries | |
59 | Requires: %{name} = %{version}-%{release} | |
30c49423 | 60 | Requires: freetype-devel >= 1:2.11.0 |
d7c1a71d | 61 | Requires: fribidi-devel >= %{fribidi_ver} |
30c49423 | 62 | Requires: harfbuzz-devel >= 3.0.0 |
6a1b752e JB |
63 | |
64 | %description devel | |
65 | Header files for Raqm library. | |
66 | ||
67 | %description devel -l pl.UTF-8 | |
68 | Pliki nagłówkowe biblioteki Raqm. | |
69 | ||
70 | %package static | |
71 | Summary: Static Raqm library | |
72 | Summary(pl.UTF-8): Statyczna biblioteka Raqm | |
73 | Group: Development/Libraries | |
74 | Requires: %{name}-devel = %{version}-%{release} | |
75 | ||
76 | %description static | |
77 | Static Raqm library. | |
78 | ||
79 | %description static -l pl.UTF-8 | |
80 | Statyczna biblioteka Raqm. | |
81 | ||
82 | %package apidocs | |
83 | Summary: API documentation for Raqm library | |
84 | Summary(pl.UTF-8): Dokumentacja API biblioteki Raqm | |
85 | Group: Documentation | |
6a1b752e | 86 | BuildArch: noarch |
6a1b752e JB |
87 | |
88 | %description apidocs | |
89 | API documentation for Raqm library. | |
90 | ||
91 | %description apidocs -l pl.UTF-8 | |
92 | Dokumentacja API biblioteki Raqm. | |
93 | ||
94 | %prep | |
95 | %setup -q -n raqm-%{version} | |
6a1b752e JB |
96 | |
97 | %build | |
30c49423 JB |
98 | %meson build \ |
99 | -Ddocs=true | |
100 | ||
101 | %ninja_build -C build | |
6a1b752e JB |
102 | |
103 | %if %{with tests} | |
104 | LC_ALL=C.UTF-8 \ | |
30c49423 | 105 | %ninja_test -C build |
6a1b752e JB |
106 | %endif |
107 | ||
108 | %install | |
109 | rm -rf $RPM_BUILD_ROOT | |
110 | ||
30c49423 | 111 | %ninja_install -C build |
6a1b752e JB |
112 | |
113 | %clean | |
114 | rm -rf $RPM_BUILD_ROOT | |
115 | ||
116 | %post -p /sbin/ldconfig | |
117 | %postun -p /sbin/ldconfig | |
118 | ||
119 | %files | |
120 | %defattr(644,root,root,755) | |
30c49423 | 121 | %doc AUTHORS COPYING NEWS README.md |
6a1b752e JB |
122 | %attr(755,root,root) %{_libdir}/libraqm.so.*.*.* |
123 | %attr(755,root,root) %ghost %{_libdir}/libraqm.so.0 | |
124 | ||
125 | %files devel | |
126 | %defattr(644,root,root,755) | |
127 | %attr(755,root,root) %{_libdir}/libraqm.so | |
128 | %{_includedir}/raqm.h | |
b1d76c38 | 129 | %{_includedir}/raqm-version.h |
6a1b752e JB |
130 | %{_pkgconfigdir}/raqm.pc |
131 | ||
132 | %if %{with static_libs} | |
133 | %files static | |
134 | %defattr(644,root,root,755) | |
135 | %{_libdir}/libraqm.a | |
136 | %endif | |
137 | ||
138 | %if %{with apidocs} | |
139 | %files apidocs | |
140 | %defattr(644,root,root,755) | |
141 | %{_gtkdocdir}/raqm | |
142 | %endif |