]> git.pld-linux.org Git - packages/gammu.git/blob - gammu.spec
- updated to 1.28.0 (DEVEL merge)
[packages/gammu.git] / gammu.spec
1 Summary:        Tool suite for mobile phones
2 Summary(pl.UTF-8):      Zestaw narzędzi do telefonów komórkowych
3 Name:           gammu
4 Version:        1.28.0
5 Release:        1
6 Epoch:          1
7 License:        GPL v2+
8 Group:          Applications/Communications
9 Source0:        http://dl.cihar.com/gammu/releases/%{name}-%{version}.tar.bz2
10 # Source0-md5:  1cddf45348b0c8cebcc14c9e693c6c9a
11 Source1:        %{name}-smsd.init
12 Source2:        %{name}-smsd.sysconfig
13 Patch0:         %{name}-etc_dir.patch
14 URL:            http://www.gammu.org/
15 BuildRequires:  bluez-libs-devel
16 BuildRequires:  cmake >= 2.4.6
17 BuildRequires:  curl-devel
18 BuildRequires:  gettext-devel
19 BuildRequires:  mysql-devel
20 BuildRequires:  postgresql-devel
21 BuildRequires:  python-devel >= 1:2.5
22 BuildRequires:  rpm-pythonprov
23 BuildRequires:  rpmbuild(macros) >= 1.293
24 Requires:       %{name}-libs = %{epoch}:%{version}-%{release}
25 Suggests:       %{name}-smsd = %{epoch}:%{version}-%{release}
26 Provides:       mygnokii2
27 Obsoletes:      mygnokii2
28 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
29
30 %description
31 Gammu (formerly known as MyGnokii2) is cellular manager for various
32 mobile phones and modems. It currently supports Nokia 3210, 33xx,
33 3410, 3510, 51xx, 5210, 5510, 61xx, 62xx, 63xx, 6510, 7110, 82xx,
34 8310, 9110, and 9210, and AT devices (such as Siemens, Alcatel,
35 WaveCom, IPAQ, and other). It has a command line version with many
36 functions for ringtones, phonebook, SMS, logos, WAP, date/time, alarm,
37 calls, etc. It can also make full backups and restore them.
38
39 %description -l pl.UTF-8
40 Gammu (poprzednio znany jako MyGnokii2) jest narzędziem do zarządzania
41 różnymi telefonami komórkowymi i modemami. Aktualnie obsługuje Nokie
42 3210, 33xx, 3410, 51xx, 5210, 5510, 61xx, 62xx, 63xx, 6510, 7110,
43 82xx, 8310, 9110 i 3210 oraz urządzenia AT (takie jak Siemens,
44 Alcatel, WaveCom, IPAQ i inne). Ma wersję działającą z linii poleceń z
45 wieloma funkcjami do dzwonków, książki telefonicznej, SMS-ów, logo,
46 WAP, daty/czasu, budzika, dzwonienia itp. Może także wykonywać pełne
47 kopie zapasowe danych i odtwarzać je.
48
49 %package smsd
50 Summary:        Gammu SMS Daemon
51 Summary(pl.UTF-8):      Demon SMS Gammu
52 Group:          Applications/Communications
53 Requires:       %{name} = %{epoch}:%{version}-%{release}
54
55 %description smsd
56 Gammu SMS Daemon is a program that periodically scans GSM modem for
57 received messages, stores them in defined storage and also sends
58 messages enqueued in this storage. It is perfect tool for managing big
59 amounts of received or sent messages and automatically process them.
60
61 %description smsd -l pl.UTF-8
62 Demon SMS Gammu jest programem, któr okresowo sprawdza czy modem GSM
63 odebrał jakieś wiadomości, przechowuje je w zdefiniowanym zasobie a
64 także wysyła wiadomości skolejkowane w tym zasobie. Jest idealnym
65 narzędziem do zarządzania dużą ilością otrzymanych lub wysyłanych
66 wiadomości i atomatycznego przetwarzania ich.
67
68 %package libs
69 Summary:        Gammu library
70 Summary(pl.UTF-8):      Biblioteka Gammu
71 Group:          Libraries
72
73 %description libs
74 Gammu tool suite library.
75
76 %description libs -l pl.UTF-8
77 Biblioteka zestawu narzędzi dla telefonów komórkowych Gammu.
78
79 %package devel
80 Summary:        Header files for Gammu tool suite for mobile phones
81 Summary(pl.UTF-8):      Pliki nagłówkowe zestawu narzędzi dla telefonów komórkowych Gammu
82 Group:          Development/Libraries
83 Requires:       %{name}-libs = %{epoch}:%{version}-%{release}
84 Requires:       bluez-libs-devel
85
86 %description devel
87 Header files for Gammu tool suite for mobile phones.
88
89 %description devel -l pl.UTF-8
90 Pliki nagłówkowe zestawu narzędzi dla telefonów komórkowych Gammu.
91
92 %package -n python-gammu
93 Summary:        Python bingings for Gammu library
94 Summary(pl.UTF-8):      Wiązania języka Python dla biblioteki Gammu
95 Group:          Development/Languages/Python
96 Requires:       %{name}-libs = %{epoch}:%{version}-%{release}
97 %pyrequires_eq  python-modules
98
99 %description -n python-gammu
100 Python bingings for Gammu library.
101
102 %description -n python-gammu -l pl.UTF-8
103 Wiązania języka Python dla biblioteki Gammu.
104
105 %package static
106 Summary:        Gammu static library
107 Summary(pl.UTF-8):      Biblioteka statyczna Gammu
108 Group:          Development/Libraries
109 Requires:       %{name}-devel = %{epoch}:%{version}-%{release}
110
111 %description static
112 Gammu static library.
113
114 %description static -l pl.UTF-8
115 Biblioteka statyczna zestawu narzędzi dla telefonów komórkowych Gammu.
116
117 %package -n bash-completion-gammu
118 Summary:        bash-completion for gammu
119 Summary(pl.UTF-8):      bashowe uzupełnianie nazw dla gammu
120 Group:          Applications/Shells
121 Requires:       %{name} = %{epoch}:%{version}-%{release}
122 Requires:       bash-completion
123
124 %description -n bash-completion-gammu
125 This package provides bash-completion for gammu.
126
127 %description -n bash-completion-gammu -l pl.UTF-8
128 Pakiet ten dostarcza bashowe uzupełnianie nazw dla gammu.
129
130 %prep
131 %setup -q
132 %patch0 -p1
133
134 %build
135 mkdir -p build
136 cd build
137 %cmake .. \
138         -DCMAKE_INSTALL_PREFIX="%{_prefix}" \
139         -DCMAKE_VERBOSE_MAKEFILE=ON \
140         -DBUILD_SHARED_LIBS=OFF \
141         -DINSTALL_LIB_DIR=%{_lib} \
142         -DINSTALL_LIBDATA_DIR=%{_libdir} \
143         %{?debug:-DCMAKE_BUILD_TYPE="Debug"}
144 %{__make}
145 mv libgammu/libGammu.a ..
146 mv smsd/libgsmsd.a ..
147 %cmake .. \
148         -DCMAKE_INSTALL_PREFIX="%{_prefix}" \
149         -DCMAKE_VERBOSE_MAKEFILE=ON \
150         -DBUILD_SHARED_LIBS=ON \
151         -DINSTALL_LIB_DIR=%{_lib} \
152         -DINSTALL_LIBDATA_DIR=%{_libdir} \
153         %{?debug:-DCMAKE_BUILD_TYPE="Debug"}
154 %{__make}
155
156 %install
157 rm -rf $RPM_BUILD_ROOT
158 install -d $RPM_BUILD_ROOT{%{_sysconfdir},%{_examplesdir}/%{name}-%{version}}
159
160 %{__make} -C build install \
161         DESTDIR=$RPM_BUILD_ROOT
162
163 install docs/config/gammurc $RPM_BUILD_ROOT%{_sysconfdir}
164 cp -r docs/develop $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
165 install libGammu.a $RPM_BUILD_ROOT%{_libdir}
166 install libgsmsd.a $RPM_BUILD_ROOT%{_libdir}
167 install -d $RPM_BUILD_ROOT%{_sysconfdir}/%{name}-smsd $RPM_BUILD_ROOT/etc/{rc.d/init.d,sysconfig}
168 install docs/config/smsdrc $RPM_BUILD_ROOT%{_sysconfdir}/%{name}-smsd/ttyS0.conf
169 install -p %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}-smsd
170 cp -a %{SOURCE2} $RPM_BUILD_ROOT/etc/sysconfig/%{name}-smsd
171 install -d $RPM_BUILD_ROOT/%{_varrun}/%{name}-smsd
172 install -d $RPM_BUILD_ROOT/%{_sharedstatedir}/%{name}-smsd
173
174 %find_lang %{name}
175 %find_lang libgammu
176
177 rm -rf $RPM_BUILD_ROOT%{_docdir}/%{name}
178
179 # for rpm autodeps
180 chmod 755 $RPM_BUILD_ROOT%{_libdir}/lib*.so*
181
182 %clean
183 rm -rf $RPM_BUILD_ROOT
184
185 %post   libs -p /sbin/ldconfig
186 %postun libs -p /sbin/ldconfig
187
188 %pre smsd
189 %groupadd -g 251 gammu-smsd
190 %useradd -u 251 -d /var/lib/gammu-smsd -s /bin/false -c "Gammu SMSD user" -G dialout -g gammu-smsd gammu-smsd
191
192 %post smsd
193 /sbin/chkconfig --add gammu-smsd
194 %service gammu-smsd restart "Gammu SMSD"
195
196 %preun smsd
197 if [ "$1" = "0" ]; then
198         %service gammu-smsd stop
199         /sbin/chkconfig --del gammu-smsd
200 fi
201
202 %postun smsd
203 if [ "$1" = "0" ]; then
204         %groupremove gammu-smsd
205         %userremove gammu-smsd
206 fi
207
208 %files -f %{name}.lang
209 %defattr(644,root,root,755)
210 %doc AUTHORS BUGS ChangeLog docs/user/gammu.html docs/user/gammu.html README README.Python
211 %doc %lang(it) docs/user/gammu.it.txt docs/user/readme.it.txt
212 %attr(755,root,root) %{_bindir}/%{name}
213 %attr(755,root,root) %{_bindir}/jadmaker
214 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/gammurc
215 %{_examplesdir}/%{name}-%{version}
216 %{_mandir}/man[157]/*
217 %lang(cs) %{_mandir}/cs/man[157]/*
218
219 %files smsd
220 %defattr(644,root,root,755)
221 %doc docs/sql/*.sql
222 %attr(755,root,root) %{_bindir}/gammu-smsd
223 %attr(755,root,root) %{_bindir}/gammu-smsd-inject
224 %attr(755,root,root) %{_bindir}/gammu-smsd-monitor
225 %attr(754,root,root) /etc/rc.d/init.d/%{name}-smsd
226 %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/%{name}-smsd
227 %{_sysconfdir}/%{name}-smsd
228 %attr(750,root,gammu-smsd) %{_varrun}/%{name}-smsd
229 %attr(750,gammu-smsd,gammu-smsd) %{_sharedstatedir}/%{name}-smsd
230
231 %files libs -f libgammu.lang
232 %defattr(644,root,root,755)
233 %attr(755,root,root) %{_libdir}/libGammu.so.*.*
234 %attr(755,root,root) %{_libdir}/libgsmsd.so.*.*.*.*
235 %attr(755,root,root) %ghost %{_libdir}/libgsmsd.so.?
236 %attr(755,root,root) %ghost %{_libdir}/libGammu.so.?
237
238 %files devel
239 %defattr(644,root,root,755)
240 %attr(755,root,root) %{_bindir}/%{name}-config
241 %attr(755,root,root) %{_libdir}/libGammu.so
242 %attr(755,root,root) %{_libdir}/libgsmsd.so
243 %{_includedir}/*
244 %dir %{py_sitedir}/gammu/
245 %attr(755,root,root) %{py_sitedir}/gammu/_gammu.so
246 %{_pkgconfigdir}/gammu.pc
247 %{_pkgconfigdir}/gammu-smsd.pc
248
249 %files -n python-gammu
250 %defattr(644,root,root,755)
251 %dir %{py_sitedir}/gammu
252 %attr(755,root,root) %{py_sitedir}/gammu/*.so
253 %{py_sitedir}/gammu/*.py
254
255 %files static
256 %defattr(644,root,root,755)
257 %{_libdir}/libgsmsd.a
258 %{_libdir}/libGammu.a
259
260 %files -n bash-completion-gammu
261 %defattr(644,root,root,755)
262 %{_sysconfdir}/bash_completion.d/gammu
This page took 0.077508 seconds and 4 git commands to generate.