]>
Commit | Line | Data |
---|---|---|
a495a069 ER |
1 | # |
2 | # Conditional build: | |
d33cb680 | 3 | %bcond_with capifax # capifax has some error and won't build right now |
cd0c35f0 | 4 | |
1b551225 | 5 | Summary: CAPI 2.0 libraries and configuration tools |
3a5f210d ER |
6 | Summary(de.UTF-8): CAPI 2.0 Werkzeuge für verschiedene ISDN Karten |
7 | Summary(pl.UTF-8): Biblioteki i narzędzia konfiguracyjne CAPI 2.0 | |
1b551225 | 8 | Name: capi4k-utils |
92c39629 | 9 | Version: 2005.07.18 |
a495a069 | 10 | Release: 4 |
1b551225 TP |
11 | License: GPL |
12 | Group: Applications/Communications | |
92c39629 | 13 | Source0: ftp://ftp.in-berlin.de/pub/capi4linux/%{name}-2005-07-18.tar.gz |
14 | # Source0-md5: c745759b6b3d64e19763727176648cdf | |
1b551225 | 15 | Source1: ftp://ftp.in-berlin.de/pub/capi4linux/CHANGES |
92c39629 | 16 | # Source1-md5: 03739a0170eba14f03f7dc7ccc58bba8 |
1b551225 TP |
17 | Source10: capi.conf |
18 | Source11: capi.init | |
b0ded9b5 KK |
19 | Patch0: %{name}-include.patch |
20 | Patch1: %{name}-make.patch | |
21 | Patch2: %{name}-msg2str_safety.patch | |
22 | Patch3: %{name}-ppd244.patch | |
23 | Patch4: %{name}-ppd245.patch | |
24 | Patch5: %{name}-rcapid.patch | |
25 | Patch6: %{name}-amd64.patch | |
1b551225 TP |
26 | URL: ftp://ftp.in-berlin.de/pub/capi4linux/ |
27 | BuildRequires: libtool | |
28 | BuildRequires: ppp-plugin-devel | |
0621f6b4 ER |
29 | BuildRequires: rpmbuild(macros) >= 1.268 |
30 | Requires(post): /sbin/ldconfig | |
1b551225 | 31 | Requires(post,preun): /sbin/chkconfig |
180f9ba6 | 32 | Requires: rc-scripts |
1b551225 TP |
33 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
34 | ||
35 | %define ppp_ver %(awk -F'"' '/VERSION/ { print $2 }' /usr/include/pppd/patchlevel.h 2>/dev/null || echo ERROR) | |
36 | ||
37 | %description | |
df147066 | 38 | These are the necessary tools to operate various CAPI 2.0 compatible |
39 | ISDN adapters. | |
1b551225 | 40 | |
df147066 | 41 | In order to use the tools you need to install the appropriate driver |
42 | for the adapter. Native driver packages for some adapters are provided | |
43 | with the kernel. | |
1b551225 | 44 | |
37f23fb5 | 45 | %description -l de.UTF-8 |
df147066 | 46 | Dies sind die notwendigen Grundprogramme um verschiedene CAPI 2.0 |
37f23fb5 JR |
47 | fähige Geräte und ISDN Karten einzurichten. Für einige Karten müssen |
48 | Sie zusätzlich entsprechende Treiber installieren. | |
1b551225 | 49 | |
37f23fb5 JR |
50 | %description -l pl.UTF-8 |
51 | W tym pakiecie zawarte są biblioteki współdzielone libcapi20 oraz | |
52 | narzędzia służące do ładowania i konfiguracji sterowników CAPI. | |
1b551225 | 53 | |
37f23fb5 JR |
54 | Aby skorzystać z tych narzędzi potrzebny jest jeszcze odpowiedni |
55 | sterownik do karty ISDN. Kilka takich sterowników znajduje się już w | |
56 | jądrze. | |
1b551225 TP |
57 | |
58 | %package devel | |
5cd715a5 | 59 | Summary: Header files for capi development |
3a5f210d ER |
60 | Summary(de.UTF-8): Kopfdateien zur Entwicklung von CAPI Programmen |
61 | Summary(pl.UTF-8): Pliki nagłówkowe capi | |
1b551225 TP |
62 | Group: Development/Libraries |
63 | Requires: %{name} = %{version}-%{release} | |
64 | ||
65 | %description devel | |
5cd715a5 JB |
66 | This package contains the header files required to develop capi |
67 | applications. | |
1b551225 | 68 | |
37f23fb5 JR |
69 | %description devel -l pl.UTF-8 |
70 | Ten pakiet zawiera pliki nagłówkowe potrzebne do budowania programów | |
71 | korzystających ze sterowników w standardzie CAPI poprzez bibliotekę | |
5cd715a5 | 72 | libcapi. |
1b551225 | 73 | |
37f23fb5 | 74 | %description devel -l de.UTF-8 |
5cd715a5 | 75 | Dieses Paket stellt die Dateien bereit um CAPI Programme zu entwickeln |
37f23fb5 | 76 | oder neu zu Übersetzen. |
5cd715a5 JB |
77 | |
78 | %package static | |
79 | Summary: Static capi libraries | |
3a5f210d | 80 | Summary(pl.UTF-8): Statyczne biblioteki capi |
5cd715a5 JB |
81 | Group: Development/Libraries |
82 | Requires: %{name}-devel = %{version}-%{release} | |
83 | ||
84 | %description static | |
85 | Static versions of capi libraries. | |
86 | ||
37f23fb5 | 87 | %description static -l pl.UTF-8 |
5cd715a5 | 88 | Statyczne wersje bibliotek capi. |
1b551225 | 89 | |
cd0c35f0 | 90 | %if %{with capifax} |
1b551225 TP |
91 | %package capifax |
92 | Summary: CAPI 2.0 fax tool | |
3a5f210d ER |
93 | Summary(de.UTF-8): CAPI 2.0 Fax Programm |
94 | Summary(pl.UTF-8): Proste narzędzia do faksowania wykorzystujący możliwości CAPI 2.0 | |
1b551225 TP |
95 | Group: Applications/Communications |
96 | Requires: %{name} = %{version}-%{release} | |
97 | ||
98 | %description capifax | |
99 | Native tools for sending and receiving fax with CAPI 2.0. | |
100 | ||
df147066 | 101 | HINT: If you intend to use other CAPI 2.0 compliant fax software you |
102 | do not need to install this package. | |
103 | ||
37f23fb5 | 104 | %description capifax -l de.UTF-8 |
df147066 | 105 | Basis Programm zum Senden und Empfangen von Fax mittels CAPI 2.0. |
106 | ||
37f23fb5 | 107 | HINWEIS: Falls Sie andere CAPI 2.0 fähige Faxprogramme einsetzen |
df147066 | 108 | wollen brauchen Sie dieses Paket nicht installieren. |
1b551225 | 109 | |
37f23fb5 JR |
110 | %description capifax -l pl.UTF-8 |
111 | Podstawowe programy do wysyłania i odbierania faksów przez CAPI 2.0. | |
1b551225 | 112 | |
37f23fb5 | 113 | PORADA: Jeśli zamierzasz korzystać z innego pakietu do obsługi faksów |
1b551225 TP |
114 | (np. capisuite lub hylafax) to nie potrzebujesz tego pakietu. |
115 | ||
cd0c35f0 | 116 | %endif |
117 | ||
1b551225 TP |
118 | %package remotecapi |
119 | Summary: CAPI 2.0 remote tool | |
3a5f210d ER |
120 | Summary(de.UTF-8): CAPI 2.0 Fernsteuerungsprogramm |
121 | Summary(pl.UTF-8): Program udostępniający interface CAPI 2.0 przez sieć | |
1b551225 TP |
122 | Group: Applications/Communications |
123 | Requires: %{name} = %{version}-%{release} | |
124 | ||
125 | %description remotecapi | |
126 | Native tool for remote control (login) with CAPI 2.0. | |
127 | ||
128 | ATTENTION: This is extreme BETA. | |
129 | Avoid to install this package. | |
130 | ||
37f23fb5 | 131 | %description remotecapi -l de.UTF-8 |
1b551225 TP |
132 | Basis Programm zu Fernsteuerung (Login) mittels CAPI 2.0. |
133 | ||
134 | ACHTUNG: Dieses Programm ist BETA Testsoftware. | |
135 | Vermeiden Sie dieses Paket zu installieren. | |
136 | ||
37f23fb5 JR |
137 | %description remotecapi -l pl.UTF-8 |
138 | Program udostępniający interface CAPI 2.0 przez sieć | |
df147066 | 139 | |
37f23fb5 | 140 | UWAGA: To jest na razie BETA. Tylko do testów. |
df147066 | 141 | |
1b551225 | 142 | %package -n ppp-plugin-capi |
a495a069 ER |
143 | Summary: capiplugin for pppd |
144 | Summary(pl.UTF-8): Wtyczka capi dla pppd | |
1b551225 TP |
145 | Group: Applications/Communications |
146 | Requires: %{name} = %{version}-%{release} | |
a495a069 | 147 | Requires: ppp |
1b551225 TP |
148 | |
149 | %description -n ppp-plugin-capi | |
a495a069 | 150 | capiplugin for pppd. |
1b551225 | 151 | |
37f23fb5 | 152 | %description -n ppp-plugin-capi -l pl.UTF-8 |
a495a069 | 153 | Wtyczka capi dla pppd. |
1b551225 TP |
154 | |
155 | %prep | |
156 | %setup -q -n %{name} | |
157 | %patch0 -p1 | |
5133f98b | 158 | %patch1 -p1 |
b0ded9b5 KK |
159 | %patch2 -p0 |
160 | %patch3 -p0 | |
161 | %patch4 -p0 | |
162 | %patch5 -p1 | |
163 | %if "%{_lib}" == "lib64" | |
164 | %patch6 -p1 | |
6b04e7be | 165 | %endif |
1b551225 TP |
166 | |
167 | cat > .config << END | |
168 | CONFIG_BINDIR='%{_bindir}' | |
169 | CONFIG_SBINDIR='%{_sbindir}' | |
170 | CONFIG_MANDIR='%{_mandir}' | |
171 | CONFIG_AVMCAPICTRL=y | |
b2b732e0 | 172 | CONFIG_LIBDIR='%{_libdir}' |
cd0c35f0 | 173 | %{?with_capifax:CONFIG_CAPIFAX=y} |
1b551225 TP |
174 | CONFIG_RCAPID=y |
175 | CONFIG_PPPDCAPIPLUGIN=y | |
176 | END | |
177 | ||
178 | install -p %{SOURCE1} . | |
179 | ||
180 | %build | |
a495a069 ER |
181 | %{__make} subconfig \ |
182 | CC="%{__cc}" | |
183 | ||
5cd715a5 | 184 | %{__make} \ |
a495a069 | 185 | CC="%{__cc}" |
5cd715a5 | 186 | PPPVERSIONS=%{ppp_ver} |
1b551225 TP |
187 | |
188 | %install | |
189 | rm -rf $RPM_BUILD_ROOT | |
5cd715a5 JB |
190 | |
191 | %{__make} install \ | |
192 | PPPVERSIONS=%{ppp_ver} \ | |
1b551225 TP |
193 | DESTDIR=$RPM_BUILD_ROOT |
194 | ||
a495a069 ER |
195 | mv $RPM_BUILD_ROOT%{_libdir}/pppd/{%{ppp_ver},plugins} |
196 | ||
1b551225 | 197 | # Firmware goes here - see LSB and kernel 2.6.x ISDN stuff |
5cd715a5 | 198 | install -d $RPM_BUILD_ROOT%{_datadir}/isdn |
1b551225 TP |
199 | |
200 | # install capi configuration file used by capiinit | |
5cd715a5 JB |
201 | install -d $RPM_BUILD_ROOT%{_sysconfdir}/capi |
202 | install %{SOURCE10} $RPM_BUILD_ROOT%{_sysconfdir}/capi | |
1b551225 TP |
203 | |
204 | # install capi startup script | |
72edd9d5 | 205 | install -D %{SOURCE11} $RPM_BUILD_ROOT/etc/rc.d/init.d/capi |
5cd715a5 JB |
206 | |
207 | %clean | |
208 | rm -rf $RPM_BUILD_ROOT | |
1b551225 | 209 | |
5cd715a5 | 210 | %post |
1b551225 TP |
211 | /sbin/ldconfig |
212 | /sbin/chkconfig --add capi | |
0621f6b4 | 213 | %service capi restart |
1b551225 | 214 | |
5cd715a5 | 215 | %preun |
1b551225 | 216 | if [ "$1" = "0" ]; then |
0621f6b4 | 217 | %service capi stop |
1b551225 TP |
218 | /sbin/chkconfig --del capi |
219 | fi | |
1b551225 | 220 | |
0621f6b4 | 221 | %postun -p /sbin/ldconfig |
1b551225 | 222 | |
1b551225 TP |
223 | %files |
224 | %defattr(644,root,root,755) | |
5cd715a5 JB |
225 | %doc CHANGES pppdcapiplugin/examples |
226 | %attr(755,root,root) %{_bindir}/capiinfo | |
227 | %attr(755,root,root) %{_sbindir}/capiinit | |
228 | %attr(755,root,root) %{_sbindir}/avmcapictrl | |
b0ded9b5 | 229 | %ghost %{_libdir}/libcapi20.so.3 |
1b551225 | 230 | %attr(755,root,root) %{_libdir}/lib*.so.*.* |
72edd9d5 | 231 | %attr(754,root,root) /etc/rc.d/init.d/capi |
1b551225 TP |
232 | %{_mandir}/man8/capiinfo.8* |
233 | %{_mandir}/man8/avmcapictrl.8* | |
234 | %dir %{_datadir}/isdn | |
235 | %dir %{_sysconfdir}/capi | |
416bb05d | 236 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/capi/capi.conf |
1b551225 TP |
237 | # mi to nie chce dzialac, wypisuje ze brak pliku |
238 | #%ghost %{_sysconfdir}/capi.conf | |
239 | ||
240 | %files devel | |
241 | %defattr(644,root,root,755) | |
242 | %attr(755,root,root) %{_libdir}/lib*.so | |
1b551225 | 243 | %{_libdir}/lib*.la |
5cd715a5 JB |
244 | %{_includedir}/* |
245 | ||
246 | %files static | |
247 | %defattr(644,root,root,755) | |
1b551225 TP |
248 | %{_libdir}/lib*.a |
249 | ||
cd0c35f0 | 250 | %if %{with capifax} |
1b551225 TP |
251 | %files capifax |
252 | %defattr(644,root,root,755) | |
5cd715a5 | 253 | %attr(755,root,root) %{_bindir}/capifax* |
cd0c35f0 | 254 | %endif |
1b551225 TP |
255 | |
256 | %files remotecapi | |
257 | %defattr(644,root,root,755) | |
5cd715a5 | 258 | %attr(755,root,root) %{_sbindir}/rcapid |
1b551225 TP |
259 | |
260 | %files -n ppp-plugin-capi | |
261 | %defattr(644,root,root,755) | |
262 | %exclude %{_sysconfdir}/drdsl | |
263 | %exclude %{_sysconfdir}/ppp | |
a495a069 | 264 | %{_libdir}/pppd/plugins/* |
1b551225 | 265 | %{_mandir}/man8/capiplugin.8* |