3 %bcond_without apidocs # API documentation
4 %bcond_with glade # install glade catalog
5 %bcond_without static_libs # static library
6 %bcond_without vala # do not build Vala API
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
13 License: LGPL v2+ (library), GPL v2+ (some language specs files)
15 Source0: https://download.gnome.org/sources/gtksourceview/4.8/gtksourceview-%{version}.tar.xz
16 # Source0-md5: d10c624feb48412542f9e3447e75d6bc
17 URL: https://wiki.gnome.org/Projects/GtkSourceView
18 BuildRequires: docbook-dtd412-xml
19 BuildRequires: fribidi-devel >= 0.19.7
20 BuildRequires: gettext-tools >= 0.19.4
21 BuildRequires: glib2-devel >= 1:2.48.0
22 BuildRequires: gobject-introspection-devel >= 1.42.0
23 BuildRequires: gtk+3-devel >= 3.24
24 %{?with_apidocs:BuildRequires: gtk-doc >= 1.25}
25 BuildRequires: itstool
27 BuildRequires: libgladeui-devel >= 3.9.0
29 BuildRequires: libxml2-devel >= 1:2.6.31
30 BuildRequires: meson >= 0.50.0
31 BuildRequires: ninja >= 1.5
32 BuildRequires: pkgconfig
33 BuildRequires: rpm-build >= 4.6
34 BuildRequires: rpm-pythonprov
35 BuildRequires: rpmbuild(macros) >= 1.736
36 BuildRequires: sed >= 4.0
37 BuildRequires: tar >= 1:1.22
40 Requires: fribidi >= 0.19.7
41 Requires: glib2 >= 1:2.48.0
42 Requires: gtk+3 >= 3.24
43 Requires: libxml2 >= 1:2.6.31
44 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
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.
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
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}
62 Requires: fribidi-devel >= 0.19.7
63 Requires: glib2-devel >= 1:2.48.0
64 Requires: gtk+3-devel >= 3.24
65 Requires: libxml2-devel >= 1:2.6.31
68 Header files for GtkSourceView.
70 %description devel -l pl.UTF-8
71 Pliki nagłówkowe dla GtkSourceView.
74 Summary: Static GtkSourceView library
75 Summary(pl.UTF-8): Statyczna biblioteka GtkSourceView
76 Group: X11/Development/Libraries
77 Requires: %{name}-devel = %{version}-%{release}
80 Static GtkSourceView library.
82 %description static -l pl.UTF-8
83 Statyczna biblioteka GtkSourceView.
86 Summary: GtkSourceView API documentation
87 Summary(pl.UTF-8): Dokumentacja API GtkSourceView
89 Requires: gtk-doc-common
93 GtkSourceView API documentation.
95 %description apidocs -l pl.UTF-8
96 Dokumentacja API GtkSourceView.
98 %package -n glade3-gtksourceview
99 Summary: Glade3 catalog entry for GtkSourceView library
100 Summary(pl.UTF-8): Wpis katalogu Glade3 dla biblioteki GtkSourceView
101 Group: X11/Development/Libraries
102 Requires: %{name}-devel = %{version}-%{release}
103 Requires: libgladeui >= 3.9.0
105 %description -n glade3-gtksourceview
106 Glade3 catalog entry for GtkSourceView library.
108 %description -n glade3-gtksourceview -l pl.UTF-8
109 Wpis katalogu Glade3 dla biblioteki GtkSourceView.
111 %package -n vala-gtksourceview4
112 Summary: GtkSourceView API for Vala language
113 Summary(pl.UTF-8): API GtkSourceView dla języka Vala
114 Group: Development/Libraries
115 Requires: %{name}-devel = %{version}-%{release}
119 %description -n vala-gtksourceview4
120 GtkSourceView API for Vala language.
122 %description -n vala-gtksourceview4 -l pl.UTF-8
123 API GtkSourceView dla języka Vala.
126 %setup -q -n gtksourceview-%{version}
128 %if %{with static_libs}
129 %{__sed} -i -e 's/gtksource_lib = shared_library/gtksource_lib = library/' gtksourceview/meson.build
134 %{?with_glade:-Dglade_catalog=true} \
135 %{?with_apidocs:-Dgtk_doc=true}
137 %ninja_build -C build
140 rm -rf $RPM_BUILD_ROOT
142 %ninja_install -C build
144 %find_lang gtksourceview-4
147 rm -rf $RPM_BUILD_ROOT
149 %post -p /sbin/ldconfig
150 %postun -p /sbin/ldconfig
152 %files -f gtksourceview-4.lang
153 %defattr(644,root,root,755)
154 %attr(755,root,root) %{_libdir}/libgtksourceview-4.so.*.*.*
155 %attr(755,root,root) %ghost %{_libdir}/libgtksourceview-4.so.0
156 %{_datadir}/gtksourceview-4
157 %{_libdir}/girepository-1.0/GtkSource-4.typelib
160 %defattr(644,root,root,755)
161 %attr(755,root,root) %{_libdir}/libgtksourceview-4.so
162 %{_includedir}/gtksourceview-4
163 %{_pkgconfigdir}/gtksourceview-4.pc
164 %{_datadir}/gir-1.0/GtkSource-4.gir
166 %if %{with static_libs}
168 %defattr(644,root,root,755)
169 %{_libdir}/libgtksourceview-4.a
174 %defattr(644,root,root,755)
175 %{_gtkdocdir}/gtksourceview-4.0
179 %files -n glade3-gtksourceview
180 %defattr(644,root,root,755)
181 %{_datadir}/glade3/catalogs/gtksourceview.xml
185 %files -n vala-gtksourceview4
186 %defattr(644,root,root,755)
187 %{_datadir}/vala/vapi/gtksourceview-4.deps
188 %{_datadir}/vala/vapi/gtksourceview-4.vapi