/[smecontribs]/rpms/ejabberd/contribs7/ejabberd.spec
ViewVC logotype

Diff of /rpms/ejabberd/contribs7/ejabberd.spec

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

Revision 1.2 by slords, Thu May 8 21:12:30 2008 UTC Revision 1.10 by slords, Thu Mar 4 16:11:50 2010 UTC
# Line 3  Line 3 
3  # Name: Jean-Paul Leclère  # Name: Jean-Paul Leclère
4    
5  Name:           ejabberd  Name:           ejabberd
6  Version:        2.0.0  Version:        2.0.5
7  Release:        3%{?dist}  Release:        2%{?dist}
8  Summary:        A distributed, fault-tolerant Jabber/XMPP server  Summary:        A distributed, fault-tolerant Jabber/XMPP server
9    
10  Group:          Applications/Internet  Group:          Applications/Internet
11  License:        GPLv2  License:        GPLv2+
12  URL:            http://www.ejabberd.im/  URL:            http://www.ejabberd.im/
13  Source0:        http://www.process-one.net/downloads/%{name}/%{version}/%{name}-%{version}.tar.gz  Source0:        http://www.process-one.net/downloads/%{name}/%{version}/%{name}-%{version}.tar.gz
14  Source1:        ejabberd.init  Source1:        ejabberd.init
15  Source2:        ejabberd.logrotate  Source2:        ejabberd.logrotate
16    Source3:        ejabberd.sysconfig
17    
18  # http://ejabberd.jabber.ru/ejabberdctl-extra  # http://www.ejabberd.im/mod_ctlextra
19  Source4:        https://svn.process-one.net/ejabberd-modules/mod_ctlextra/trunk/src/mod_ctlextra.erl  # svn export -r 873 https://svn.process-one.net/ejabberd-modules/mod_ctlextra/trunk/src/mod_ctlextra.erl
20    Source4:        mod_ctlextra.erl
21    
22  # The following were extracted from a patch found on http://realloc.spb.ru/share/ejabberdad.html  # The following were extracted from a patch found on http://realloc.spb.ru/share/ejabberdad.html
23  Source5:        ejabberd_auth_ad.erl  Source5:        ejabberd_auth_ad.erl
24  Source6:        mod_shared_roster_ad.erl  Source6:        mod_shared_roster_ad.erl
25  Source7:        mod_vcard_ad.erl  Source7:        mod_vcard_ad.erl
26  #  
27  #Source8:        ejabberdctl  # PAM support
28  Source9:        ejabberdctl.pam  Source9:        ejabberdctl.pam
29  Source10:       ejabberdctl.apps  Source10:       ejabberdctl.apps
30    Source11:       ejabberd.pam
31    
32  # originally from  # Fedora-specific stuff - fixing paths
 # https://support.process-one.net/secure/attachment/11788/ejab-446.patch  
 Patch0: ejab-446.patch  
   
 # local stuff  
33  Patch1: ejabberd-build.patch  Patch1: ejabberd-build.patch
34    # BZ# 439583, 452326, 451554, 465196
35    Patch2: ejabberd-ejabberdctl_fix.diff
36    # Use ejabberd as an example for PAM service name
37    Patch3: ejabberd-ejabberd_cfg_pam_name.diff
38    # CAPTCHA support, see https://support.process-one.net/doc/display/XAAI/Fighting+Multi-User+Chat+SPAM+with+CAPTCHA
39    # wget https://support.process-one.net/secure/attachment/13851/XEP-0158_ejabberd-2.0.4.patch -O ejabberd-captcha.patch
40    Patch4: ejabberd-captcha.patch
41    
 # R12B  
 Patch2: ejabberd-ssl.patch  
   
 # R11B SSL  
 Patch3: ejabberd_s2s_in_erl.diff  
42    
43  BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)  BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
44    
# Line 45  BuildRequires:  expat-devel Line 46  BuildRequires:  expat-devel
46  BuildRequires:  openssl-devel  BuildRequires:  openssl-devel
47  BuildRequires:  pam-devel  BuildRequires:  pam-devel
48  BuildRequires:  erlang  BuildRequires:  erlang
49  %if %{?rhel:0}%{!?rhel:1}  BuildRequires:  dos2unix
50    %if %{undefined rhel}
51  BuildRequires:  hevea  BuildRequires:  hevea
52  %endif  %endif
53    
# Line 54  Requires:       usermode Line 56  Requires:       usermode
56    
57  Requires(pre): fedora-usermgmt  Requires(pre): fedora-usermgmt
58  Requires(post): /sbin/chkconfig  Requires(post): /sbin/chkconfig
59    Requires(post): /usr/bin/openssl
60  Requires(preun): /sbin/chkconfig  Requires(preun): /sbin/chkconfig
61  Requires(preun): /sbin/service  Requires(preun): /sbin/service
62  Requires(postun): /sbin/service  Requires(postun): /sbin/service
# Line 82  Documentation for ejabberd. Line 85  Documentation for ejabberd.
85  %post  %post
86  /sbin/chkconfig --add ejabberd  /sbin/chkconfig --add ejabberd
87    
88    (cd /etc/ejabberd
89    if [ ! -f ejabberd.pem ]
90    then
91        echo "Generating SSL certificate /etc/ejabberd/ejabberd.pem..."
92        HOSTNAME=$(hostname -s)
93        DOMAINNAME=$(hostname -d)
94        openssl req -new -x509 -days 365 -nodes -out ejabberd.pem \
95                    -keyout ejabberd.pem > /dev/null 2>&1 <<+++
96    .
97    .
98    .
99    $DOMAINNAME
100    $HOSTNAME
101    ejabberd
102    root@$HOSTNAME.$DOMAINNAME
103    +++
104    chown ejabberd:ejabberd ejabberd.pem
105    chmod 600 ejabberd.pem
106    fi)
107    
108  %preun  %preun
109  if [ $1 = 0 ]; then  if [ $1 = 0 ]; then
110          /sbin/service ejabberd stop >/dev/null 2>&1          /sbin/service ejabberd stop >/dev/null 2>&1
# Line 94  if [ "$1" -ge "1" ]; then Line 117  if [ "$1" -ge "1" ]; then
117  fi  fi
118    
119  %prep  %prep
120  %setup -q -n %{name}-%{version}  %setup -q
121  %patch0 -p1 -b .Er12b-build  %patch1 -p0 -b .fix_paths
122  %patch1 -p1 -b .MC-build  %patch2 -p0 -b .fix_user
123  #%patch2 -p1 -b .R12B  %patch3 -p0 -b .pam_name
124  %patch3 -p0 -b .r11_ssl  #%patch4 -p1 -b .captcha
125    dos2unix src/odbc/mssql.sql
 %{__perl} -pi -e "s!/var/lib/ejabberd!%{_libdir}/ejabberd-%{version}!g" src/Makefile.in  
 %{__perl} -pi -e "s!/etc!%{_sysconfdir}!g" src/Makefile.in  
 %{__perl} -pi -e "s!\@prefix\@!!g" src/Makefile.in  
126    
127  cp %{S:4} src  cp %{S:4} src
128  cp %{S:5} src  cp %{S:5} src
# Line 111  cp %{S:7} src Line 131  cp %{S:7} src
131    
132  %build  %build
133  pushd src  pushd src
134  %configure --enable-odbc --enable-debug  %configure --enable-odbc --enable-debug --enable-pam
135  make %{?_smp_mflags}  # doesn't builds on SMP currently
136    make
137  popd  popd
138  %if %{?rhel:0}%{!?rhel:1}  %if %{undefined rhel}
139  pushd doc  pushd doc
140  make html pdf  make html pdf
141  popd  popd
# Line 127  pushd src Line 148  pushd src
148  make install DESTDIR=%{buildroot}  make install DESTDIR=%{buildroot}
149  popd  popd
150    
151  chmod a+x %{buildroot}%{_libdir}/ejabberd-%{version}/priv/lib/*.so  chmod a+x %{buildroot}%{_libdir}/%{name}/priv/lib/*.so
152    
153  %{__perl} -pi -e 's!./ssl.pem!/etc/ejabberd/ejabberd.pem!g' %{buildroot}/etc/ejabberd/ejabberd.cfg  %{__perl} -pi -e 's!./ssl.pem!/etc/ejabberd/ejabberd.pem!g' %{buildroot}/etc/ejabberd/ejabberd.cfg
154    
# Line 136  mkdir -p %{buildroot}/var/lib/ejabberd/s Line 157  mkdir -p %{buildroot}/var/lib/ejabberd/s
157    
158  mkdir -p %{buildroot}%{_bindir}  mkdir -p %{buildroot}%{_bindir}
159  ln -s consolehelper %{buildroot}%{_bindir}/ejabberdctl  ln -s consolehelper %{buildroot}%{_bindir}/ejabberdctl
 #install -D -p -m 0755 %{S:8} %{buildroot}%{_sbindir}/ejabberdctl  
160  install -D -p -m 0644 %{S:9} %{buildroot}%{_sysconfdir}/pam.d/ejabberdctl  install -D -p -m 0644 %{S:9} %{buildroot}%{_sysconfdir}/pam.d/ejabberdctl
161  install -D -p -m 0644 %{S:10} %{buildroot}%{_sysconfdir}/security/console.apps/ejabberdctl  install -D -p -m 0644 %{S:10} %{buildroot}%{_sysconfdir}/security/console.apps/ejabberdctl
162    install -D -p -m 0644 %{S:11} %{buildroot}%{_sysconfdir}/pam.d/ejabberd
163    
164  mkdir -p %{buildroot}%{_initrddir}  # install init-script
165  install -p -m 0755 %{S:1} %{buildroot}%{_initrddir}/ejabberd  install -D -p -m 0755 %{S:1} %{buildroot}%{_initrddir}/ejabberd
 chmod a+x %{buildroot}%{_initrddir}/ejabberd  
166    
167  mkdir -p %{buildroot}%{_sysconfdir}/logrotate.d  # install config for logrotate
168  cp -p %{S:2} %{buildroot}%{_sysconfdir}/logrotate.d/ejabberd  install -D -p -m 0644  %{S:2} %{buildroot}%{_sysconfdir}/logrotate.d/ejabberd
169    
170  %{__perl} -pi -e 's!\@libdir\@!%{_libdir}!g' %{buildroot}%{_initrddir}/ejabberd %{buildroot}%{_sysconfdir}/logrotate.d/ejabberd %{buildroot}%{_sbindir}/ejabberdctl  # install sysconfig file
171    install -D -p -m 0644  %{S:3} %{buildroot}%{_sysconfdir}/sysconfig/ejabberd
172    
173    %{__perl} -pi -e 's!\@libdir\@!%{_libdir}!g'  %{buildroot}%{_initrddir}/ejabberd %{buildroot}%{_sysconfdir}/logrotate.d/ejabberd %{buildroot}%{_sbindir}/ejabberdctl
174  %{__perl} -pi -e 's!\@version\@!%{version}!g' %{buildroot}%{_initrddir}/ejabberd %{buildroot}%{_sysconfdir}/logrotate.d/ejabberd %{buildroot}%{_sbindir}/ejabberdctl  %{__perl} -pi -e 's!\@version\@!%{version}!g' %{buildroot}%{_initrddir}/ejabberd %{buildroot}%{_sysconfdir}/logrotate.d/ejabberd %{buildroot}%{_sbindir}/ejabberdctl
175    
176  #cp %{S:3} %{buildroot}%{_sysconfdir}/ejabberd/inetrc  # BZ# 439583
177  #mv %{buildroot}%{_sysconfdir}/ejabberd/{ejabberd.,}inetrc  %{__perl} -pi -e 's!MAINDIR=!MAINDIR=%{_libdir}/ejabberd!g' %{buildroot}%{_sbindir}/ejabberdctl
178    
179  %clean  %clean
180  rm -rf %{buildroot}  rm -rf %{buildroot}
181    
182  %files  %files
183  %defattr(-,root,root,-)  %defattr(-,root,root,-)
184  %doc COPYING  %doc COPYING src/odbc/mysql.sql src/odbc/mssql.sql src/odbc/pg.sql
185    # tools/captcha.sh
186    
187  %attr(750,ejabberd,ejabberd) %dir %{_sysconfdir}/ejabberd  %attr(750,ejabberd,ejabberd) %dir %{_sysconfdir}/ejabberd
188  %attr(640,ejabberd,ejabberd) %config(noreplace) %{_sysconfdir}/ejabberd/ejabberd.cfg  %attr(640,ejabberd,ejabberd) %config(noreplace) %{_sysconfdir}/ejabberd/ejabberd.cfg
# Line 167  rm -rf %{buildroot} Line 191  rm -rf %{buildroot}
191    
192  %{_initrddir}/ejabberd  %{_initrddir}/ejabberd
193  %config(noreplace) %{_sysconfdir}/logrotate.d/ejabberd  %config(noreplace) %{_sysconfdir}/logrotate.d/ejabberd
194    %config(noreplace) %{_sysconfdir}/sysconfig/ejabberd
195    %config(noreplace) %{_sysconfdir}/pam.d/ejabberd
196  %config(noreplace) %{_sysconfdir}/pam.d/ejabberdctl  %config(noreplace) %{_sysconfdir}/pam.d/ejabberdctl
197  %config(noreplace) %{_sysconfdir}/security/console.apps/ejabberdctl  %config(noreplace) %{_sysconfdir}/security/console.apps/ejabberdctl
198  %{_bindir}/ejabberdctl  %{_bindir}/ejabberdctl
199  %{_sbindir}/ejabberdctl  %{_sbindir}/ejabberdctl
200    
201  %dir %{_libdir}/ejabberd-%{version}  %dir %{_libdir}/%{name}
202  %dir %{_libdir}/ejabberd-%{version}/ebin  %dir %{_libdir}/%{name}/ebin
203  %{_libdir}/ejabberd-%{version}/ebin/*.app  %dir %{_libdir}/%{name}/priv
204  %{_libdir}/ejabberd-%{version}/ebin/*.beam  %dir %{_libdir}/%{name}/priv/bin
205    %attr(4750,root,ejabberd)    %{_libdir}/%{name}/priv/bin/epam
206  %dir %{_libdir}/ejabberd-%{version}/priv  %dir %{_libdir}/%{name}/priv/lib
207    %dir %{_libdir}/%{name}/priv/msgs
208  %dir %{_libdir}/ejabberd-%{version}/priv/lib  
209  %{_libdir}/ejabberd-%{version}/priv/lib/*.so  %{_libdir}/%{name}/ebin/*.app
210    %{_libdir}/%{name}/ebin/*.beam
211  %dir %{_libdir}/ejabberd-%{version}/priv/msgs  %{_libdir}/%{name}/priv/lib/*.so
212  %{_libdir}/ejabberd-%{version}/priv/msgs/*.msg  %{_libdir}/%{name}/priv/msgs/*.msg
213    
214  %attr(750,ejabberd,ejabberd) %dir /var/lib/ejabberd  %attr(750,ejabberd,ejabberd) %dir /var/lib/ejabberd
215  %attr(750,ejabberd,ejabberd) %dir /var/lib/ejabberd/spool  %attr(750,ejabberd,ejabberd) %dir /var/lib/ejabberd/spool
   
216  %attr(750,ejabberd,ejabberd) %dir /var/log/ejabberd  %attr(750,ejabberd,ejabberd) %dir /var/log/ejabberd
217    
218  %files doc  %files doc
219  %defattr(-,root,root,-)  %defattr(-,root,root,-)
220  %if %{?rhel:0}%{!?rhel:1}  %if %{undefined rhel}
221  %doc ChangeLog COPYING doc/*.pdf doc/*.html doc/*.png doc/release_notes_*  %doc ChangeLog COPYING doc/release_notes_* doc/*.pdf doc/*.html doc/*.png
222  %else  %else
223  %doc ChangeLog COPYING doc/release_notes_*  %doc ChangeLog COPYING doc/release_notes_*
224  %endif  %endif
225    
226  %changelog  %changelog
227    * Sat Apr  4 2009 Peter Lemenkov <lemenkov@gmail.com> 2.0.5-2
228    - Really disable CAPTCHA
229    
230    * Fri Apr  3 2009 Peter Lemenkov <lemenkov@gmail.com> 2.0.5-1
231    - Ver. 2.0.5
232    - Temporarily disabled CAPTCHA support
233    
234    * Sun Mar 15 2009 Peter Lemenkov <lemenkov@gmail.com> 2.0.4-2
235    - Support for CAPTCHA (XEP-0158)
236    - Updated mod_ctlextra.erl (fixed EJAB-789, EJAB-864)
237    
238    * Sun Mar 15 2009 Peter Lemenkov <lemenkov@gmail.com> 2.0.4-1
239    - Ver. 2.0.4
240    
241    * Tue Feb 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0.3-2
242    - Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
243    
244    * Mon Jan 26 2009 Peter Lemenkov <lemenkov@gmail.com> 2.0.3-1
245    - Ver. 2.0.3
246    - Merged some stuff from git://dev.laptop.org/users/martin/ejabberd-xs.git
247    
248    * Fri Jan 16 2009 Tomas Mraz <tmraz@redhat.com> 2.0.2-4
249    - rebuild with new openssl
250    
251    * Thu Oct  2 2008 Peter Lemenkov <lemenkov@gmail.com> 2.0.2-3
252    - Fixed broken ejabberdctl (BZ# 465196)
253    
254    * Sat Aug 30 2008 Peter Lemenkov <lemenkov@gmail.com> 2.0.2-2
255    - Added missing Requires
256    
257    * Fri Aug 29 2008 Peter Lemenkov <lemenkov@gmail.com> 2.0.2-1
258    - Ver. 2.0.2
259    
260    * Sat Aug  9 2008 Peter Lemenkov <lemenkov@gmail.com> 2.0.2-0.3.beta1
261    - PAM support (BZ# 452803)
262    
263    * Sat Aug  9 2008 Peter Lemenkov <lemenkov@gmail.com> 2.0.2-0.2.beta1
264    - Fix build with --fuzz=0
265    
266    * Sat Aug  9 2008 Peter Lemenkov <lemenkov@gmail.com> 2.0.2-0.1.beta1
267    - Version 2.0.2-beta1
268    - Fixed BZ# 452326
269    - Fixed BZ# 227270
270    
271    * Sun Jun 22 2008 Peter Lemenkov <lemenkov@gmail.com> 2.0.1-4
272    - Last minute fix (issue with shortnames/fqdn)
273    
274    * Sun Jun 22 2008 Peter Lemenkov <lemenkov@gmail.com> 2.0.1-3
275    -Fixed BZ# 439583, 452326, 451554
276    
277    * Thu May 29 2008 Peter Lemenkov <lemenkov@gmail.com> 2.0.1-2
278    - Fixed BZ# 439583
279    
280    * Sat May 24 2008 Peter Lemenkov <lemenkov@gmail.com> 2.0.1-1
281    - Ver. 2.0.1
282    - Upstreamed patches dropped
283    - No longer uses versioned libdir (/usr/lib/ejabberd-x.x.x)
284    - Added sql-scripts in docs-directory
285    
286  * Mon May  5 2008 Peter Lemenkov <lemenkov@gmail.com> 2.0.0-3  * Mon May  5 2008 Peter Lemenkov <lemenkov@gmail.com> 2.0.0-3
287  - Fix build against R11B-2  - Fix build against R11B-2
288    
# Line 217  rm -rf %{buildroot} Line 300  rm -rf %{buildroot}
300    
301  * Wed Jan 23 2008 Peter Lemenkov <lemenkov@gmail.com> 2.0.0-0.2.rc1  * Wed Jan 23 2008 Peter Lemenkov <lemenkov@gmail.com> 2.0.0-0.2.rc1
302  - Enabled some previously disabled modules  - Enabled some previously disabled modules
303    
304  * Sat Jan 19 2008 Matej Cepl <mcepl@redhat.com> 2.0.0-0.1.rc1  * Sat Jan 19 2008 Matej Cepl <mcepl@redhat.com> 2.0.0-0.1.rc1
305  - Upgrade to the current upsteram version.  - Upgrade to the current upsteram version.
306  - Make ejabberd.init LSB compliant (missing Provides: tag)  - Make ejabberd.init LSB compliant (missing Provides: tag)


Legend:
Removed lines/characters  
Changed lines/characters
  Added lines/characters

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed