]> git.pld-linux.org Git - packages/callweaver.git/blob - callweaver.spec
- s/internetowymy/internetowymi/g
[packages/callweaver.git] / callweaver.spec
1 %bcond_with     simpledebug # for safe_callweaver core dump storing
2 %bcond_with     javascript
3 #
4 %define min_spandsp     1:0.0.4-0.pre9.1
5 %define snap    20070921
6 Summary:        PBX in software
7 Summary(pl.UTF-8):      Programowy PBX
8 Name:           callweaver
9 Version:        1.2.0
10 Release:        0.%{snap}.1
11 License:        GPL v2+
12 Group:          Applications
13 Source0:        http://devs.callweaver.org/1.2_snapshots/callweaver-RC-1.1.99.%{snap}.tar.gz
14 # Source0-md5:  f52285ed499003f5c96b41259ba05d9c
15 Source1:        %{name}.init
16 Source2:        %{name}.sysconfig
17 Source3:        %{name}.logrotate
18 URL:            http://www.callweaver.org/
19 BuildRequires:  bluez-libs-devel
20 BuildRequires:  curl-devel
21 BuildRequires:  libcap-devel
22 BuildRequires:  libogg-devel
23 BuildRequires:  libpri-devel
24 BuildRequires:  libsndfile-devel
25 BuildRequires:  libtiff-devel
26 BuildRequires:  libvorbis-devel
27 BuildRequires:  loudmouth-devel
28 BuildRequires:  mISDNuser-devel
29 BuildRequires:  mysql-devel
30 BuildRequires:  ncurses-devel
31 BuildRequires:  pkgconfig
32 BuildRequires:  popt-devel
33 BuildRequires:  postgresql-devel
34 BuildRequires:  readline-devel
35 BuildRequires:  rpmbuild(macros) >= 1.268
36 BuildRequires:  spandsp-devel >= %{min_spandsp}
37 BuildRequires:  speex-devel
38 BuildRequires:  sqlite3-devel
39 BuildRequires:  unixODBC-devel
40 BuildRequires:  zaptel-devel >= 1.2
41 BuildRequires:  zlib-devel
42 Requires:       spandsp >= %{min_spandsp}
43 Requires(post,preun):   /sbin/chkconfig
44 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
45
46 %description
47 Open Source PBX and telephony toolkit. It is, in a sense, middleware
48 between Internet and telephony channels on the bottom, and Internet
49 and telephony applications at the top.
50
51 %description -l pl.UTF-8
52 PBX i zestaw narzędziowy do telefonii o otwartych źródłach. Jest to
53 middleware między kanałami internetowymi i telefonicznymi z dołu a
54 aplikacjami internetowymi i telefonicznymi z góry.
55
56 %package devel
57 Summary:        Header files for callweaver
58 Summary(pl.UTF-8):      Pliki nagłówkowe callweavera
59 Group:          Development/Libraries
60 Requires:       %{name} = %{version}-%{release}
61
62 %description devel
63 Header files for callweaver.
64
65 %description devel -l pl.UTF-8
66 Pliki nagłówkowe callweavera.
67
68 %if %{with simpledebug}
69 %define no_install_post_strip   1
70 %endif
71
72 %prep
73 %setup -q -n %{name}-RC-1.1.99.%{snap}
74
75 %build
76 %configure \
77         --with-chan_misdn \
78         --with-chan_fax \
79         --with-chan_bluetooth \
80         --enable-odbc \
81         --with-cdr_odbc \
82         --with-res_config_odbc \
83         --with-res_odbc \
84         --enable-mysql \
85         --with-cdr_mysql \
86         --with-res_config_mysql \
87         --enable-postgresql \
88         --with-cdr_pgsql \
89         --with-res_config_pgsql \
90         --with-res_config_curl \
91         --enable-jabber \
92         --with-res_jabber \
93 %if %{with javascript}
94         --enable-javascript \
95         --with-res_js \
96 %endif
97         --with-res_sqlite \
98         --with-directory-layout=lsb
99
100 %{__make}
101
102 %install
103 rm -rf $RPM_BUILD_ROOT
104 install -d $RPM_BUILD_ROOT/etc/{rc.d/init.d,sysconfig,logrotate.d}
105 install -d $RPM_BUILD_ROOT%{_var}/spool/callweaver/voicemail
106
107 %{__make} install \
108         DESTDIR=$RPM_BUILD_ROOT
109
110 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}
111 install %{SOURCE2} $RPM_BUILD_ROOT/etc/sysconfig/%{name}
112 install %{SOURCE3} $RPM_BUILD_ROOT/etc/logrotate.d/%{name}
113
114 %clean
115 rm -rf $RPM_BUILD_ROOT
116
117 %pre
118 %groupadd -g 192 %{name}
119 %useradd -u 192 -d /var/lib/callweaver -s /bin/false -c "callweaver" -g %{name} %{name}
120
121 %post
122 /sbin/chkconfig --add %{name}
123 %service %{name} restart
124
125
126 %preun
127 if [ "$1" = "0" ]; then
128         %service -q %{name} stop
129         /sbin/chkconfig --del %{name}
130 fi
131
132 %postun
133 if [ "$1" = "0" ]; then
134         %userremove callweaver
135         %groupremove %{name}
136 fi
137
138 %files
139 %defattr(644,root,root,755)
140 %doc AUTHORS BUGS CREDITS ChangeLog HARDWARE InstallGuide.txt README SECURITY sounds.txt
141 %doc doc
142 %dir %{_sysconfdir}/%{name}
143 %attr(640,root,callweaver) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/*.*
144 %attr(755,root,root) %{_bindir}/*
145 %attr(755,root,root) %{_sbindir}/*
146 %dir %{_libdir}/%{name}
147 %attr(755,root,root) %{_libdir}/%{name}/*.so.*
148 %{_libdir}/%{name}/*.la
149 %dir %{_libdir}/%{name}/modules
150 %attr(755,root,root) %{_libdir}/%{name}/modules/*.so
151 %{_libdir}/%{name}/modules/*.la
152 %{_datadir}/%{name}
153 %{_mandir}/man*/*
154
155 %attr(750,callweaver,root) %dir %{_var}/lib/callweaver
156 %attr(750,callweaver,root) %dir %{_var}/lib/callweaver/core
157 %attr(750,callweaver,root) %dir %{_var}/log/callweaver
158 %attr(750,callweaver,root) %dir %{_var}/log/callweaver/*
159 %attr(750,callweaver,root) %dir %{_var}/run/callweaver
160 %attr(750,callweaver,root) %dir %{_var}/spool/callweaver
161 %attr(750,callweaver,root) %dir %{_var}/spool/callweaver/voicemail
162
163 %attr(754,root,root) /etc/rc.d/init.d/%{name}
164 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/%{name}
165 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/%{name}
166
167 %files devel
168 %defattr(644,root,root,755)
169 %{_includedir}/%{name}
This page took 0.068537 seconds and 3 git commands to generate.