]>
Commit | Line | Data |
---|---|---|
cb361dd9 | 1 | # TODO: |
f3406a5e | 2 | # warning: Installed (but unpackaged) file(s) found: |
3 | # /etc/hotplug/usb/xpp_fxloader | |
4 | # /etc/hotplug/usb/xpp_fxloader.usermap | |
cb361dd9 | 5 | # |
6f6c8480 | 6 | %include /usr/lib/rpm/macros.perl |
cb361dd9 | 7 | Summary: DAHDI telephony device support |
8 | Summary(pl.UTF-8): Obsługa urządzeń telefonicznych DAHDI | |
9 | Name: dahdi-tools | |
d4845b0b JB |
10 | Version: 2.6.1 |
11 | Release: 1 | |
12 | License: GPL v2 | |
cb361dd9 | 13 | Group: Base/Kernel |
14 | Source0: http://downloads.digium.com/pub/telephony/dahdi-tools/%{name}-%{version}.tar.gz | |
d4845b0b | 15 | # Source0-md5: c2e4f476a8e7f96a5cad46dd9b648446 |
cb361dd9 | 16 | Source1: dahdi.init |
17 | Source2: dahdi.sysconfig | |
18 | Patch0: %{name}-as-needed.patch | |
6f6c8480 | 19 | Patch1: %{name}-perl-path.patch |
d4845b0b | 20 | Patch2: %{name}-includes.patch |
cb361dd9 | 21 | URL: http://www.asterisk.org/ |
58e6c841 | 22 | BuildRequires: dahdi-linux-devel >= 2.3.0 |
cb361dd9 | 23 | BuildRequires: newt-devel |
24 | BuildRequires: perl-base | |
25 | BuildRequires: perl-tools-pod | |
6f6c8480 | 26 | BuildRequires: rpm-perlprov >= 4.1-13 |
e2e6d412 | 27 | BuildRequires: rpmbuild(macros) >= 1.379 |
d4845b0b | 28 | Obsoletes: dahdi-tools-utils |
e2e6d412 | 29 | Obsoletes: zaptel |
cb361dd9 | 30 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
31 | ||
cb361dd9 | 32 | %description |
33 | DAHDI telephony device driver. | |
34 | ||
35 | %description -l pl.UTF-8 | |
36 | Sterownik do urządzeń telefonicznych DAHDI. | |
37 | ||
38 | %package devel | |
39 | Summary: DAHDI development headers | |
40 | Summary(pl.UTF-8): Pliki nagłówkowe DAHDI | |
41 | Group: Development/Libraries | |
d4845b0b JB |
42 | Requires: %{name} = %{version}-%{release} |
43 | Requires: dahdi-linux-devel | |
e2e6d412 | 44 | Obsoletes: zaptel-devel |
cb361dd9 | 45 | |
46 | %description devel | |
47 | DAHDI development headers. | |
48 | ||
49 | %description devel -l pl.UTF-8 | |
50 | Pliki nagłówkowe DAHDI. | |
51 | ||
52 | %package static | |
53 | Summary: DAHDI static library | |
54 | Summary(pl.UTF-8): Biblioteka statyczna DAHDI | |
55 | Group: Development/Libraries | |
d4845b0b | 56 | Requires: %{name}-devel = %{version}-%{release} |
cb361dd9 | 57 | |
58 | %description static | |
59 | DAHDI static library. | |
60 | ||
61 | %description static -l pl.UTF-8 | |
62 | Biblioteka statyczna DAHDI. | |
63 | ||
cb361dd9 | 64 | %package init |
65 | Summary: DAHDI init scripts | |
66 | Summary(pl.UTF-8): Skrypty inicjalizujące DAHDI | |
67 | Group: Applications/Communications | |
68 | Requires(post,preun): /sbin/chkconfig | |
d4845b0b | 69 | Requires: %{name} = %{version}-%{release} |
cb361dd9 | 70 | Requires: rc-scripts |
e2e6d412 | 71 | Obsoletes: zaptel-init |
cb361dd9 | 72 | |
73 | %description init | |
74 | DAHDI boot-time initialization. | |
75 | ||
76 | %description init -l pl.UTF-8 | |
77 | Inicjalizacja DAHDI w czasie startu systemu. | |
78 | ||
79 | %package -n perl-Dahdi | |
80 | Summary: Perl interface to DAHDI | |
d4845b0b | 81 | Summary(pl.UTF-8): Perlowy interfejs do DAHDI |
cb361dd9 | 82 | Group: Development/Languages/Perl |
d4845b0b | 83 | Requires: %{name} = %{version}-%{release} |
cb361dd9 | 84 | |
85 | %description -n perl-Dahdi | |
86 | Perl inferface to DAHDI. | |
87 | ||
88 | %description -n perl-Dahdi -l pl.UTF-8 | |
d4845b0b | 89 | Perlowy interfejs do DAHDI. |
cb361dd9 | 90 | |
91 | %prep | |
92 | %setup -q | |
93 | %patch0 -p1 | |
6f6c8480 | 94 | %patch1 -p1 |
d4845b0b | 95 | %patch2 -p1 |
cb361dd9 | 96 | |
97 | cat > download-logger <<'EOF' | |
98 | #!/bin/sh | |
99 | # keep log of files make wanted to download in firmware/ dir | |
100 | echo "$@" >> download.log | |
101 | EOF | |
102 | chmod a+rx download-logger | |
cb361dd9 | 103 | |
104 | %build | |
105 | %configure | |
1a3180a1 AM |
106 | %{__make} \ |
107 | CC="%{__cc}" \ | |
108 | OPTFLAGS="%{rpmcppflags} %{rpmcflags}" | |
cb361dd9 | 109 | |
110 | %install | |
111 | rm -rf $RPM_BUILD_ROOT | |
112 | ||
113 | install -d $RPM_BUILD_ROOT/etc/{rc.d/init.d,sysconfig} | |
114 | ||
6f6c8480 | 115 | %{__make} -j1 install \ |
cb361dd9 | 116 | DESTDIR=$RPM_BUILD_ROOT |
117 | install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/dahdi | |
118 | install %{SOURCE2} $RPM_BUILD_ROOT/etc/sysconfig/dahdi | |
119 | touch $RPM_BUILD_ROOT%{_sysconfdir}/dahdi.conf | |
120 | ||
121 | %clean | |
122 | rm -rf $RPM_BUILD_ROOT | |
123 | ||
124 | %post init | |
125 | /sbin/chkconfig --add dahdi | |
126 | %service dahdi restart | |
127 | ||
128 | %preun init | |
129 | if [ "$1" = "0" ]; then | |
130 | %service dahdi stop | |
131 | /sbin/chkconfig --del dahdi | |
132 | fi | |
133 | ||
134 | %files | |
135 | %defattr(644,root,root,755) | |
136 | %doc README | |
137 | %attr(600,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/dahdi.conf | |
138 | %dir %{_sysconfdir}/dahdi | |
139 | %attr(600,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/dahdi/system.conf | |
140 | #/etc/hotplug/usb/xpp_fxloader | |
141 | #/etc/hotplug/usb/xpp_fxloader.usermap | |
d4845b0b JB |
142 | %attr(755,root,root) %{_sbindir}/astribank_* |
143 | %attr(755,root,root) %{_sbindir}/dahdi_* | |
144 | %attr(755,root,root) %{_sbindir}/fpga_load | |
145 | %attr(755,root,root) %{_sbindir}/fxotune | |
146 | %attr(755,root,root) %{_sbindir}/lsdahdi | |
147 | %attr(755,root,root) %{_sbindir}/sethdlc | |
148 | %attr(755,root,root) %{_sbindir}/twinstar | |
149 | %attr(755,root,root) %{_sbindir}/xpp_blink | |
150 | %attr(755,root,root) %{_sbindir}/xpp_sync | |
151 | %attr(755,root,root) %{_libdir}/libtonezone.so.1.* | |
152 | %attr(755,root,root) %ghost %{_libdir}/libtonezone.so.1 | |
153 | %attr(755,root,root) %{_libdir}/libtonezone.so.2.* | |
154 | %attr(755,root,root) %ghost %{_libdir}/libtonezone.so.2 | |
cb361dd9 | 155 | %{_datadir}/dahdi |
d4845b0b JB |
156 | %{_mandir}/man8/astribank_*.8* |
157 | %{_mandir}/man8/dahdi_*.8* | |
158 | %{_mandir}/man8/fpga_load.8* | |
159 | %{_mandir}/man8/fxotune.8* | |
160 | %{_mandir}/man8/lsdahdi.8* | |
161 | %{_mandir}/man8/twinstar.8* | |
162 | %{_mandir}/man8/xpp_blink.8* | |
163 | %{_mandir}/man8/xpp_sync.8* | |
cb361dd9 | 164 | |
165 | %files devel | |
166 | %defattr(644,root,root,755) | |
d4845b0b JB |
167 | %attr(755,root,root) %{_libdir}/libtonezone.so |
168 | %{_includedir}/dahdi/tonezone.h | |
cb361dd9 | 169 | |
170 | %files static | |
171 | %defattr(644,root,root,755) | |
d4845b0b | 172 | %{_libdir}/libtonezone.a |
cb361dd9 | 173 | |
d4845b0b | 174 | %files init |
cb361dd9 | 175 | %defattr(644,root,root,755) |
d4845b0b JB |
176 | %attr(754,root,root) /etc/rc.d/init.d/dahdi |
177 | %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/dahdi | |
cb361dd9 | 178 | |
179 | %files -n perl-Dahdi | |
180 | %defattr(644,root,root,755) | |
6f6c8480 | 181 | %{perl_vendorlib}/Dahdi |
182 | %{perl_vendorlib}/Dahdi.pm |