]>
Commit | Line | Data |
---|---|---|
eadc58de JB |
1 | # TODO: gtk4 variant |
2 | # | |
3 | # Conditional build: | |
4 | %bcond_without apidocs # gtk-doc documentation | |
5 | %bcond_without static_libs # shared library | |
c5aabc94 | 6 | %bcond_without vala # Vala API |
eadc58de JB |
7 | # |
8 | Summary: NetworkManager UI utilities (libnm version) | |
9 | Summary(pl.UTF-8): Narzędzia UI NetworkManagera (wersja libnm) | |
10 | Name: libnma | |
c5aabc94 | 11 | Version: 1.8.28 |
f8ab59e7 | 12 | Release: 2 |
eadc58de JB |
13 | License: LGPL v2.1+ |
14 | Group: X11/Libraries | |
15 | Source0: http://ftp.gnome.org/pub/GNOME/sources/libnma/1.8/%{name}-%{version}.tar.xz | |
c5aabc94 | 16 | # Source0-md5: 094c45d7694b153612cbdc3c713edcb5 |
eadc58de JB |
17 | URL: https://gitlab.gnome.org/GNOME/libnma |
18 | BuildRequires: NetworkManager-devel >= 2:1.7 | |
19 | BuildRequires: autoconf >= 2.63 | |
20 | BuildRequires: automake >= 1:1.11 | |
eadc58de | 21 | BuildRequires: gcr-ui-devel >= 3.14 |
c5aabc94 | 22 | BuildRequires: gettext-tools >= 0.18 |
eadc58de JB |
23 | BuildRequires: glib2-devel >= 1:2.23 |
24 | BuildRequires: gobject-introspection-devel >= 0.9.6 | |
eadc58de | 25 | BuildRequires: gtk+3-devel >= 3.10 |
c5aabc94 | 26 | BuildRequires: gtk-doc >= 1.0 |
eadc58de JB |
27 | BuildRequires: libtool >= 2:2.2.6 |
28 | BuildRequires: pkgconfig | |
29 | BuildRequires: rpmbuild(macros) >= 1.98 | |
30 | BuildRequires: tar >= 1:1.22 | |
c5aabc94 JP |
31 | %if %{with vala} |
32 | BuildRequires: vala >= 2:0.17.1.24 | |
33 | BuildRequires: vala-NetworkManager | |
34 | %endif | |
eadc58de JB |
35 | BuildRequires: xz |
36 | Requires: NetworkManager-libs >= 2:1.7 | |
37 | Requires: gcr-ui >= 3.14 | |
38 | Requires: glib2 >= 1:2.23 | |
39 | Requires: gtk+3 >= 3.10 | |
40 | Requires: iso-codes | |
41 | Requires: mobile-broadband-provider-info | |
f8ab59e7 | 42 | Provides: NetworkManager-gtk-lib = %{version}-%{release} |
a8f805b2 | 43 | Obsoletes: NetworkManager-gtk-lib < 1.8.26 |
eadc58de JB |
44 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
45 | ||
46 | %description | |
47 | NetworkManager UI utilities (libnm version). | |
48 | ||
49 | %description -l pl.UTF-8 | |
50 | Narzędzia UI NetworkManagera (wersja libnm). | |
51 | ||
52 | %package devel | |
53 | Summary: Header files for libnma library | |
54 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki libnma | |
55 | Group: X11/Development/Libraries | |
56 | Requires: %{name} = %{version}-%{release} | |
57 | Requires: NetworkManager-devel >= 2:1.7 | |
58 | Requires: glib2-devel >= 1:2.23 | |
59 | Requires: gtk+3-devel >= 3.10 | |
f8ab59e7 | 60 | Provides: NetworkManager-gtk-lib-devel = %{version}-%{release} |
a8f805b2 | 61 | Obsoletes: NetworkManager-gtk-lib-devel < 1.8.26 |
eadc58de JB |
62 | |
63 | %description devel | |
64 | Header files for libnma library. | |
65 | ||
66 | %description devel -l pl.UTF-8 | |
67 | Pliki nagłówkowe biblioteki libnma. | |
68 | ||
69 | %package static | |
70 | Summary: Static libnma library | |
71 | Summary(pl.UTF-8): Statyczna biblioteka libnma | |
72 | Group: X11/Development/Libraries | |
73 | Requires: %{name}-devel = %{version}-%{release} | |
74 | ||
75 | %description static | |
76 | Static libnma library. | |
77 | ||
78 | %description static -l pl.UTF-8 | |
79 | Statyczna biblioteka libnma. | |
80 | ||
81 | %package apidocs | |
82 | Summary: API documentation for libnma library | |
83 | Summary(pl.UTF-8): Dokumentacja API biblioteki libnma | |
84 | Group: Documentation | |
a8f805b2 | 85 | Obsoletes: NetworkManager-gtk-lib-apidocs < 1.8.26 |
eadc58de JB |
86 | %if "%{_rpmversion}" >= "5" |
87 | BuildArch: noarch | |
88 | %endif | |
89 | ||
90 | %description apidocs | |
91 | API documentation for libnma library. | |
92 | ||
93 | %description apidocs -l pl.UTF-8 | |
94 | Dokumentacja API biblioteki libnma. | |
95 | ||
c5aabc94 JP |
96 | %package -n vala-libnma |
97 | Summary: Vala API for libnma library | |
98 | Summary(pl.UTF-8): API języka Vala do biblioteki libnma | |
99 | Group: Development/Libraries | |
100 | Requires: %{name}-devel = %{epoch}:%{version}-%{release} | |
101 | Requires: vala >= 2:0.17.1.24 | |
102 | %if "%{_rpmversion}" >= "5" | |
103 | BuildArch: noarch | |
104 | %endif | |
105 | ||
106 | %description -n vala-libnma | |
107 | Vala API for libnma library. | |
108 | ||
109 | %description -n vala-libnma -l pl.UTF-8 | |
110 | API języka Vala do biblioteki libnma. | |
111 | ||
eadc58de JB |
112 | %prep |
113 | %setup -q | |
114 | ||
115 | %build | |
116 | %{__libtoolize} | |
117 | %{__aclocal} -I m4 | |
118 | %{__autoconf} | |
119 | %{__autoheader} | |
120 | %{__automake} | |
121 | %configure \ | |
122 | --disable-iso-codes \ | |
123 | --disable-mobile-broadband-provider-info \ | |
124 | --disable-silent-rules \ | |
125 | %{!?with_static_libs:--disable-static} \ | |
c5aabc94 | 126 | %{__enable_disable vala} \ |
eadc58de JB |
127 | --with-html-dir=%{_gtkdocdir} |
128 | ||
129 | %{__make} | |
130 | ||
131 | %install | |
132 | rm -rf $RPM_BUILD_ROOT | |
133 | ||
134 | %{__make} install \ | |
135 | DESTDIR=$RPM_BUILD_ROOT | |
136 | ||
137 | # obsoleted by pkg-config | |
138 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/libnma.la | |
139 | ||
c5aabc94 | 140 | %find_lang %{name} |
eadc58de JB |
141 | |
142 | %clean | |
143 | rm -rf $RPM_BUILD_ROOT | |
144 | ||
145 | %post -p /sbin/ldconfig | |
146 | %postun -p /sbin/ldconfig | |
147 | ||
c5aabc94 | 148 | %files -f %{name}.lang |
eadc58de JB |
149 | %defattr(644,root,root,755) |
150 | %doc NEWS | |
151 | %attr(755,root,root) %{_libdir}/libnma.so.*.*.* | |
152 | %attr(755,root,root) %ghost %{_libdir}/libnma.so.0 | |
153 | %{_libdir}/girepository-1.0/NMA-1.0.typelib | |
c5aabc94 | 154 | %{_datadir}/glib-2.0/schemas/org.gnome.nm-applet.gschema.xml |
eadc58de JB |
155 | |
156 | %files devel | |
157 | %defattr(644,root,root,755) | |
158 | %attr(755,root,root) %{_libdir}/libnma.so | |
159 | %{_includedir}/libnma | |
160 | %{_datadir}/gir-1.0/NMA-1.0.gir | |
161 | %{_pkgconfigdir}/libnma.pc | |
162 | ||
163 | %if %{with static_libs} | |
164 | %files static | |
165 | %defattr(644,root,root,755) | |
166 | %{_libdir}/libnma.a | |
167 | %endif | |
168 | ||
169 | %if %{with apidocs} | |
170 | %files apidocs | |
171 | %defattr(644,root,root,755) | |
172 | %{_gtkdocdir}/libnma | |
173 | %endif | |
c5aabc94 JP |
174 | |
175 | %if %{with vala} | |
176 | %files -n vala-libnma | |
177 | %defattr(644,root,root,755) | |
178 | %{_datadir}/vala/vapi/libnma.deps | |
179 | %{_datadir}/vala/vapi/libnma.vapi | |
180 | %endif |