]>
Commit | Line | Data |
---|---|---|
adabce63 JB |
1 | # |
2 | # Conditional build: | |
6557b0db | 3 | %bcond_without apidocs # API documentation |
adabce63 JB |
4 | %bcond_without static_libs # static library |
5 | ||
6 | Summary: GSound - library for playing system sounds | |
7 | Summary(pl.UTF-8): GSound - biblioteka do odtwarzania dźwięków systemowych | |
8 | Name: gsound | |
6557b0db JB |
9 | Version: 1.0.3 |
10 | Release: 1 | |
adabce63 JB |
11 | License: LGPL v2.1+ |
12 | Group: Applications/System | |
6557b0db JB |
13 | Source0: https://download.gnome.org/sources/gsound/1.0/%{name}-%{version}.tar.xz |
14 | # Source0-md5: 7338c295034432a6e782fd20b3d04b68 | |
adabce63 JB |
15 | URL: https://wiki.gnome.org/Projects/GSound |
16 | BuildRequires: glib2-devel >= 1:2.36.0 | |
17 | BuildRequires: gobject-introspection-devel >= 1.2.9 | |
6557b0db | 18 | %{?with_apidocs:BuildRequires: gtk-doc >= 1.20} |
adabce63 | 19 | BuildRequires: libcanberra-devel |
6557b0db JB |
20 | BuildRequires: meson |
21 | BuildRequires: ninja >= 1.5 | |
adabce63 | 22 | BuildRequires: pkgconfig |
6557b0db JB |
23 | BuildRequires: rpm-build >= 4.6 |
24 | BuildRequires: rpmbuild(macros) >= 1.736 | |
adabce63 JB |
25 | BuildRequires: tar >= 1:1.22 |
26 | BuildRequires: vala >= 2:0.17.2.12 | |
27 | BuildRequires: vala-libcanberra | |
28 | BuildRequires: xz | |
29 | Requires: glib2 >= 1:2.36.0 | |
30 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
31 | ||
32 | %description | |
33 | GSound is a small library for playing system sounds. It's designed to | |
34 | be used via GObject Introspection, and is a thin wrapper around the | |
35 | libcanberra C library. | |
36 | ||
37 | %description -l pl.UTF-8 | |
38 | GSound to mała biblioteka do odtwarzania dźwięków systemowych. Jest | |
39 | zaprojektowana z myślą o używaniu poprzez GObject Introspection i jest | |
40 | niewielkim obudowaniem biblioteki C libcanberra. | |
41 | ||
42 | %package devel | |
43 | Summary: Header files for GSound library | |
44 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki GSound | |
45 | Group: Development/Libraries | |
46 | Requires: %{name} = %{version}-%{release} | |
47 | Requires: glib2-devel >= 1:2.36.0 | |
48 | ||
49 | %description devel | |
50 | Header files for GSound library. | |
51 | ||
52 | %description devel -l pl.UTF-8 | |
53 | Pliki nagłówkowe biblioteki GSound. | |
54 | ||
55 | %package static | |
56 | Summary: Static GSound library | |
57 | Summary(pl.UTF-8): Statyczna biblioteka GSound | |
58 | Group: Development/Libraries | |
59 | Requires: %{name}-devel = %{version}-%{release} | |
60 | ||
61 | %description static | |
62 | Static GSound library. | |
63 | ||
64 | %description static -l pl.UTF-8 | |
65 | Statyczna biblioteka GSound. | |
66 | ||
adabce63 JB |
67 | %package -n vala-gsound |
68 | Summary: Vala API for GSound library | |
69 | Summary(pl.UTF-8): API języka Vala do biblioteki GSound | |
70 | Group: Development/Libraries | |
71 | Requires: %{name}-devel = %{version}-%{release} | |
72 | Requires: vala >= 2:0.17.2.12 | |
73 | Requires: vala-libcanberra | |
20507459 | 74 | BuildArch: noarch |
adabce63 JB |
75 | |
76 | %description -n vala-gsound | |
77 | Vala API for GSound library. | |
78 | ||
79 | %description -n vala-gsound -l pl.UTF-8 | |
80 | API języka Vala do biblioteki GSound. | |
81 | ||
6557b0db JB |
82 | %package apidocs |
83 | Summary: API documentation for GSound library | |
84 | Summary(pl.UTF-8): Dokumentacja API biblioteki GSound | |
85 | Group: Documentation | |
86 | BuildArch: noarch | |
87 | ||
88 | %description apidocs | |
89 | API documentation for GSound library. | |
90 | ||
91 | %description apidocs -l pl.UTF-8 | |
92 | Dokumentacja API biblioteki GSound. | |
93 | ||
adabce63 JB |
94 | %prep |
95 | %setup -q | |
96 | ||
97 | %build | |
6557b0db JB |
98 | %meson build \ |
99 | %{!?with_static_libs:--default-library=shared} \ | |
100 | %{?with_apidocs:-Dgtk_doc=true} | |
adabce63 | 101 | |
6557b0db | 102 | %ninja_build -C build |
adabce63 JB |
103 | |
104 | %install | |
105 | rm -rf $RPM_BUILD_ROOT | |
106 | ||
6557b0db | 107 | %ninja_install -C build |
adabce63 JB |
108 | |
109 | %clean | |
110 | rm -rf $RPM_BUILD_ROOT | |
111 | ||
112 | %post -p /sbin/ldconfig | |
113 | %postun -p /sbin/ldconfig | |
114 | ||
115 | %files | |
116 | %defattr(644,root,root,755) | |
6557b0db | 117 | %doc README.md |
adabce63 JB |
118 | %attr(755,root,root) %{_bindir}/gsound-play |
119 | %attr(755,root,root) %{_libdir}/libgsound.so.*.*.* | |
120 | %attr(755,root,root) %ghost %{_libdir}/libgsound.so.0 | |
121 | %{_libdir}/girepository-1.0/GSound-1.0.typelib | |
6557b0db | 122 | %{_mandir}/man1/gsound-play.1* |
adabce63 JB |
123 | |
124 | %files devel | |
125 | %defattr(644,root,root,755) | |
126 | %attr(755,root,root) %{_libdir}/libgsound.so | |
127 | %{_includedir}/gsound*.h | |
128 | %{_datadir}/gir-1.0/GSound-1.0.gir | |
129 | %{_pkgconfigdir}/gsound.pc | |
130 | ||
131 | %if %{with static_libs} | |
132 | %files static | |
133 | %defattr(644,root,root,755) | |
134 | %{_libdir}/libgsound.a | |
135 | %endif | |
136 | ||
adabce63 JB |
137 | %files -n vala-gsound |
138 | %defattr(644,root,root,755) | |
139 | %{_datadir}/vala/vapi/gsound.deps | |
140 | %{_datadir}/vala/vapi/gsound.vapi | |
6557b0db JB |
141 | |
142 | %if %{with apidocs} | |
143 | %files apidocs | |
144 | %defattr(644,root,root,755) | |
145 | %{_gtkdocdir}/gsound-%{version} | |
146 | %endif |