]>
Commit | Line | Data |
---|---|---|
896eb13d MB |
1 | # |
2 | # Conditional build: | |
b02f970b | 3 | %bcond_without apidocs # API documentation |
349c23b4 | 4 | %bcond_without static_libs # static library |
b02f970b | 5 | %bcond_with sysprof # sysprof profiler support |
349c23b4 | 6 | %bcond_without vala # do not build Vala API |
4564cf84 | 7 | |
44df7ec3 AF |
8 | Summary: Text widget that extends the standard GTK+ 3.x |
9 | Summary(pl.UTF-8): Widget tekstowy rozszerzający standardowy z GTK+ 3.x | |
fa1469d8 | 10 | Name: gtksourceview5 |
b02f970b | 11 | Version: 5.2.0 |
b2467359 | 12 | Release: 1 |
2a83e144 | 13 | License: LGPL v2+ (library), GPL v2+ (some language specs files) |
44df7ec3 | 14 | Group: X11/Libraries |
b02f970b JB |
15 | Source0: https://download.gnome.org/sources/gtksourceview/5.2/gtksourceview-%{version}.tar.xz |
16 | # Source0-md5: 0258374209704cc595b00000e93e3c4d | |
71b49bd9 | 17 | URL: https://wiki.gnome.org/Projects/GtkSourceView |
44df7ec3 | 18 | BuildRequires: docbook-dtd412-xml |
349c23b4 | 19 | BuildRequires: fribidi-devel >= 0.19.7 |
ede2878d | 20 | BuildRequires: gettext-tools >= 0.19.4 |
c701c478 | 21 | BuildRequires: glib2-devel >= 1:2.66 |
ad61f4ae | 22 | BuildRequires: gobject-introspection-devel >= 1.42.0 |
b02f970b | 23 | BuildRequires: gtk4-devel >= 4.2 |
349c23b4 | 24 | %{?with_apidocs:BuildRequires: gtk-doc >= 1.25} |
0b911454 | 25 | BuildRequires: itstool |
44df7ec3 | 26 | BuildRequires: libxml2-devel >= 1:2.6.31 |
c701c478 | 27 | BuildRequires: meson >= 0.53.0 |
349c23b4 | 28 | BuildRequires: ninja >= 1.5 |
fa1469d8 | 29 | BuildRequires: pcre2-8-devel >= 10.21 |
44df7ec3 | 30 | BuildRequires: pkgconfig |
d1fa7142 | 31 | BuildRequires: rpm-build >= 4.6 |
44df7ec3 | 32 | BuildRequires: rpm-pythonprov |
79ee4bba | 33 | BuildRequires: rpmbuild(macros) >= 1.736 |
349c23b4 | 34 | BuildRequires: sed >= 4.0 |
b02f970b | 35 | %{?with_sysprof:BuildRequires: sysprof-devel >= 3.38} |
67ae3529 | 36 | BuildRequires: tar >= 1:1.22 |
f5853990 | 37 | BuildRequires: vala |
67ae3529 | 38 | BuildRequires: xz |
349c23b4 | 39 | Requires: fribidi >= 0.19.7 |
c701c478 | 40 | Requires: glib2 >= 1:2.66 |
b02f970b | 41 | Requires: gtk4 >= 4.2 |
6a1741b2 | 42 | Requires: libxml2 >= 1:2.6.31 |
fa1469d8 | 43 | Requires: pcre2-8 >= 10.21 |
44df7ec3 AF |
44 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
45 | ||
46 | %description | |
47 | GtkSourceView is a text widget that extends the standard GTK+ 3.x text | |
48 | widget GtkTextView. It improves GtkTextView by implementing syntax | |
49 | highlighting and other features typical of a source editor. | |
50 | ||
51 | %description -l pl.UTF-8 | |
52 | GtkSourceView to widget tekstowy rozszerzający standardowy widget | |
53 | tekstowy GtkTextView z GTK+ 3.x. Ulepsza GtkTextView poprzez | |
54 | zaimplementowanie podświetlania składni i innych możliwości typowych | |
55 | dla edytora źródeł. | |
56 | ||
44df7ec3 AF |
57 | %package devel |
58 | Summary: Header files for GtkSourceView | |
59 | Summary(pl.UTF-8): Pliki nagłówkowe dla GtkSourceView | |
60 | Group: X11/Development/Libraries | |
61 | Requires: %{name} = %{version}-%{release} | |
349c23b4 | 62 | Requires: fribidi-devel >= 0.19.7 |
c701c478 | 63 | Requires: glib2-devel >= 1:2.66 |
b02f970b | 64 | Requires: gtk4-devel >= 4.2 |
44df7ec3 | 65 | Requires: libxml2-devel >= 1:2.6.31 |
fa1469d8 | 66 | Requires: pcre2-8-devel >= 10.21 |
44df7ec3 AF |
67 | |
68 | %description devel | |
69 | Header files for GtkSourceView. | |
70 | ||
71 | %description devel -l pl.UTF-8 | |
72 | Pliki nagłówkowe dla GtkSourceView. | |
73 | ||
74 | %package static | |
75 | Summary: Static GtkSourceView library | |
76 | Summary(pl.UTF-8): Statyczna biblioteka GtkSourceView | |
77 | Group: X11/Development/Libraries | |
78 | Requires: %{name}-devel = %{version}-%{release} | |
79 | ||
80 | %description static | |
81 | Static GtkSourceView library. | |
82 | ||
83 | %description static -l pl.UTF-8 | |
84 | Statyczna biblioteka GtkSourceView. | |
85 | ||
349c23b4 JB |
86 | %package apidocs |
87 | Summary: GtkSourceView API documentation | |
88 | Summary(pl.UTF-8): Dokumentacja API GtkSourceView | |
89 | Group: Documentation | |
90 | Requires: gtk-doc-common | |
349c23b4 | 91 | BuildArch: noarch |
349c23b4 JB |
92 | |
93 | %description apidocs | |
94 | GtkSourceView API documentation. | |
95 | ||
96 | %description apidocs -l pl.UTF-8 | |
97 | Dokumentacja API GtkSourceView. | |
98 | ||
fa1469d8 | 99 | %package -n vala-gtksourceview5 |
f5853990 MB |
100 | Summary: GtkSourceView API for Vala language |
101 | Summary(pl.UTF-8): API GtkSourceView dla języka Vala | |
102 | Group: Development/Libraries | |
103 | Requires: %{name}-devel = %{version}-%{release} | |
104 | Requires: vala | |
4564cf84 | 105 | BuildArch: noarch |
f5853990 | 106 | |
fa1469d8 | 107 | %description -n vala-gtksourceview5 |
f5853990 MB |
108 | GtkSourceView API for Vala language. |
109 | ||
fa1469d8 | 110 | %description -n vala-gtksourceview5 -l pl.UTF-8 |
f5853990 MB |
111 | API GtkSourceView dla języka Vala. |
112 | ||
44df7ec3 AF |
113 | %prep |
114 | %setup -q -n gtksourceview-%{version} | |
44df7ec3 | 115 | |
349c23b4 JB |
116 | %if %{with static_libs} |
117 | %{__sed} -i -e 's/gtksource_lib = shared_library/gtksource_lib = library/' gtksourceview/meson.build | |
118 | %endif | |
d5fd6af8 | 119 | |
44df7ec3 | 120 | %build |
349c23b4 | 121 | %meson build \ |
b02f970b JB |
122 | %{?with_apidocs:-Dgtk_doc=true} \ |
123 | %{?with_sysprof:-Dsysprof=true} | |
349c23b4 JB |
124 | |
125 | %ninja_build -C build | |
44df7ec3 AF |
126 | |
127 | %install | |
128 | rm -rf $RPM_BUILD_ROOT | |
129 | ||
349c23b4 | 130 | %ninja_install -C build |
e40ce944 | 131 | |
fa1469d8 | 132 | %find_lang gtksourceview-5 |
44df7ec3 AF |
133 | |
134 | %clean | |
135 | rm -rf $RPM_BUILD_ROOT | |
136 | ||
137 | %post -p /sbin/ldconfig | |
138 | %postun -p /sbin/ldconfig | |
139 | ||
fa1469d8 | 140 | %files -f gtksourceview-5.lang |
44df7ec3 | 141 | %defattr(644,root,root,755) |
fa1469d8 JB |
142 | %attr(755,root,root) %{_libdir}/libgtksourceview-5.so.*.*.* |
143 | %attr(755,root,root) %ghost %{_libdir}/libgtksourceview-5.so.0 | |
144 | %{_datadir}/gtksourceview-5 | |
145 | %{_libdir}/girepository-1.0/GtkSource-5.typelib | |
146 | %{_iconsdir}/hicolor/scalable/actions/completion-*-symbolic.svg | |
147 | %{_iconsdir}/hicolor/scalable/actions/lang-*-symbolic.svg | |
44df7ec3 | 148 | |
44df7ec3 AF |
149 | %files devel |
150 | %defattr(644,root,root,755) | |
fa1469d8 JB |
151 | %attr(755,root,root) %{_libdir}/libgtksourceview-5.so |
152 | %{_includedir}/gtksourceview-5 | |
153 | %{_pkgconfigdir}/gtksourceview-5.pc | |
154 | %{_datadir}/gir-1.0/GtkSource-5.gir | |
44df7ec3 | 155 | |
f03d635d | 156 | %if %{with static_libs} |
44df7ec3 AF |
157 | %files static |
158 | %defattr(644,root,root,755) | |
fa1469d8 | 159 | %{_libdir}/libgtksourceview-5.a |
f03d635d | 160 | %endif |
44df7ec3 | 161 | |
349c23b4 JB |
162 | %if %{with apidocs} |
163 | %files apidocs | |
164 | %defattr(644,root,root,755) | |
fa1469d8 | 165 | %{_gtkdocdir}/gtksourceview-5.0 |
44df7ec3 | 166 | %endif |
f5853990 MB |
167 | |
168 | %if %{with vala} | |
fa1469d8 | 169 | %files -n vala-gtksourceview5 |
f5853990 | 170 | %defattr(644,root,root,755) |
fa1469d8 JB |
171 | %{_datadir}/vala/vapi/gtksourceview-5.deps |
172 | %{_datadir}/vala/vapi/gtksourceview-5.vapi | |
f5853990 | 173 | %endif |