%define localstatedir /var/lib %define version_num 1.4.2 %define release_num 10 %define jabber_lib_dir /var/lib/jabber %define msn_ver 1.2.8rc1 %define yahoo_ver 2.2.0 Summary: The Jabber IM (Instant Messaging) server. Name: jabber Version: %{version_num} Release: %{release_num} Group: System Environment/Daemons Copyright: GPL URL: http://www.jabber.org/ Source0: http://jabberd.jabberstudio.org/downloads/%{name}-%{version}.tar.gz Source1: aim-transport-stable.tar.gz Source2: msn-transport-%{msn_ver}.tar.gz Source3: yahoo-t-%{yahoo_ver}.tar.gz Source4: jud-20020220.tar.gz Source5: conference-20020220.tar.gz Source6: jabber.xml Source7: aim.xml Source8: icq.xml Source9: msn.xml Source10: yahoo.xml Source11: conference.xml Source12: jud.xml Source13: sysconfig-jabber Source14: jabberd.init Source15: README.RPM #Source16: irc-transport-0.1b-1.40.linux.tar.gz #Source17: irc.xml Patch0: msn-transport-flags.patch Buildroot: %{_tmppath}/%{name}-root Requires: /sbin/service, /sbin/chkconfig BuildRequires: perl glib-devel BuildRequires: krb5-devel openssl-devel PreReq: /etc/init.d %description Jabber is an XML-based, open-source system and protocol for real-time messaging and presence notification. The first application of Jabber is an instant messaging (IM) system similar to AOL Instant Messenger, ICQ, MSN Instant Messenger, or Yahoo! Messenger. However, Jabber is also being applied in the realms of wireless communications, embedded systems, and Internet infrastructure. %package aim Version: 20021214 Group: System Environment/Daemons Requires: %{name} Summary: AOL Instant Messenger and ICQ transport. %description aim A transport that allows Jabber server users to connect to the AOL Instant Messenger service (including ICQ). %package msn Version: %{msn_ver} Obsoletes: jabber-msn-20020220 Group: System Environment/Daemons Requires: %{name} Summary: Microsoft Network messaging transport. %description msn A transport that allows Jabber server users to connect to the Microsoft Network messaging service. %package yahoo Version: %{yahoo_ver} Group: System Environment/Daemons Requires: %{name} Summary: Yahoo messaging transport. Obsoletes: jabber-yahoo-20020220 Obsoletes: jabber-yahoo-2.1.1 %description yahoo A transport that allows Jabber server users to connect to the Yahoo messaging service. %package conference Version: 20020220 Group: System Environment/Daemons Requires: %{name} Summary: IRC-like chat system. %description conference An IRC-like conferencing system for Jabber. %package jud Version: 20020220 Requires: %{name} Group: System Environment/Daemons Summary: Searchable directory of Jabber users. %description jud The Jabber User Directory. The JUD allows you to search for Jabber users. #%package irc #Version: 1.40 #Requires: %{name} #Group: System Environment/Daemons #Summary: IRC Transport for java # #%description irc #The Jabber IRC bridge. %prep %setup -q %setup -D -T -a 1 %setup -D -T -a 2 %setup -D -T -a 3 %setup -D -T -a 4 %setup -D -T -a 5 #%setup -D -T -a 16 %build export JHOME=/var/jabber export SSLCFLAGS="%(pkg-config --silence-errors --cflags openssl)" export SSLLIBS="%(pkg-config --silence-errors --libs openssl)" # don't ask... weird auto* workaround =) export CFLAGS="$CFLAGS $SSLCFLAGS" export CXXFLAGS="$CFLAGS" export LD_FLAGS="$LDFLAGS $SSLLIBS" # build Jabber %configure --enable-ssl --prefix=/var/lib/jabber make # build the MSN transport pushd msn-transport-%{msn_ver} patch -p1 < %{PATCH0} OPTIONS="--prefix=%{jabber_lib_dir}/msn --with-jabberd=`pwd`/../jabberd --includedir=`pwd`/../jabberd/pth-1.4.0" if [ ! -f configure ]; then aclocal autoheader automake --include-deps --foreign --add-missing autoconf fi sh ./configure $OPTIONS make popd # build the AIM transport pushd aim-transport-stable-20021012 OPTIONS="--prefix=%{jabber_lib_dir}/aim --with-jabberd=`pwd`/../jabberd --includedir=`pwd`/../jabberd/pth-1.4.0" if [ ! -f configure ]; then sh ./autogen.sh $OPTIONS else sh ./configure $OPTIONS fi make popd # build the Yahoo transport pushd yahoo-transport-2 OPTIONS="--prefix=%{jabber_lib_dir}/msn --with-jabberd=`pwd`/../jabberd --includedir=`pwd`/../jabberd/pth-1.4.0" if [ ! -f configure ]; then if [ -f autogen.sh ]; then sh ./autogen.sh $OPTIONS fi else sh ./configure $OPTIONS fi make popd # build the IRC transport # pushd irc-transport-0.1b-1.40 # OPTIONS="--prefix=%{jabber_lib_dir}/irc --with-jabberd=`pwd`/../jabberd --includedir=`pwd`/../jabberd/pth-1.4.0" # if [ ! -f configure ]; then # sh ./autogen.sh $OPTIONS # else # sh ./configure $OPTIONS # fi # make # popd # build the conferencing module pushd conference make popd # build the JUD pushd jud make popd %install rm -rf %{buildroot} cp %{SOURCE15} . install -d -m 755 %{buildroot}%{_sbindir} install -m 755 jabberd/jabberd %{buildroot}%{_sbindir}/jabberd install -d -m 755 %{buildroot}%{_sysconfdir}/init.d install -m 755 %{SOURCE14} %{buildroot}%{_sysconfdir}/init.d/jabberd install -d -m 755 %{buildroot}%{jabber_lib_dir} install -d -m 755 %{buildroot}/var/log/jabber install -d -m 755 %{buildroot}/var/run/jabber install -d -m 755 %{buildroot}/var/spool/jabber # configuration files install -d -m 750 %{buildroot}/etc/jabber.d install -m 640 %{SOURCE6} %{buildroot}/etc/jabber.xml install -m 640 %{SOURCE7} %{buildroot}/etc/jabber.d/aim.xml install -m 640 %{SOURCE8} %{buildroot}/etc/jabber.d/icq.xml install -m 640 %{SOURCE9} %{buildroot}/etc/jabber.d/msn.xml install -m 640 %{SOURCE10} %{buildroot}/etc/jabber.d/yahoo.xml install -m 640 %{SOURCE11} %{buildroot}/etc/jabber.d/conference.xml install -m 640 %{SOURCE12} %{buildroot}/etc/jabber.d/jud.xml #install -m 640 %{SOURCE12} %{buildroot}/etc/jabber.d/irc.xml install -d -m 755 %{buildroot}/etc/sysconfig install -m 640 %{SOURCE13} %{buildroot}/etc/sysconfig/jabber install -d -m 755 %{buildroot}%{jabber_lib_dir}/aim/binary # core jabbes server infrastructure libraries for dir in jsm xdb_file pthsock dnsrv dialback conference jud; do strip $dir/*.so install -d -m 755 %{buildroot}%{jabber_lib_dir}/$dir install -m 755 $dir/*.so %{buildroot}%{jabber_lib_dir}/$dir/ done # extra transports for transport in msn; do strip $transport-transport-%{msn_ver}/src/*.so install -d -m 755 %{buildroot}%{jabber_lib_dir}/$transport install -m 755 $transport-transport-%{msn_ver}/src/*.so %{buildroot}%{jabber_lib_dir}/$transport/ done #aim update strip aim-transport-stable-20021012/src/*.so install -d -m 755 %{buildroot}%{jabber_lib_dir}/aim install -m 755 aim-transport-stable-20021012/src/*.so %{buildroot}%{jabber_lib_dir}/aim/ # yahoo transport strip yahoo-transport-2/*.so install -d -m 755 %{buildroot}%{jabber_lib_dir}/yahoo install -m 755 yahoo-transport-2/*.so %{buildroot}%{jabber_lib_dir}/yahoo/ # irc transport #strip irc-transport-0.1b-1.40/*.so # install -d -m 755 %{buildroot}%{jabber_lib_dir}/irc # install -m 755 yahoo-transport-2/*.so %{buildroot}%{jabber_lib_dir}/irc/ %pre useradd -M -r -d /var/lib/jabber -s /bin/bash -c "Jabber Server" jabber 2>/dev/null || : %post if [ $1 = 1 ]; then /sbin/chkconfig --add jabberd fi %post msn cd $(find /var/spool/jabber/ -type d |grep msn) for i in $(ls *.xml); do mv "$i" `echo $i | tr '[A-Z]' '[a-z]'`; done %preun if [ $1 = 0 ]; then /sbin/service jabberd stop >/dev/null 2>&1 || : /sbin/chkconfig --del jabberd fi %postun # Only if we are upgrading.. if [ "$1" -ge "1" ]; then /sbin/service jabberd condrestart >/dev/null 2>&1 || : else userdel jabber 2>/dev/null || : groupdel jabber 2>/dev/null || : fi %clean rm -rf %{buildroot} %files %defattr(644, jabber, jabber, 755) %doc README README.RPM UPGRADE %attr(755, jabber, jabber) %{_sbindir}/jabberd %config(noreplace) %{_sysconfdir}/jabber.xml %dir %{_sysconfdir}/jabber.d %attr(755, jabber, jabber) %config /etc/init.d/jabberd %attr(640, jabber, jabber) %config %{_sysconfdir}/sysconfig/jabber %dir %{jabber_lib_dir} %dir %{jabber_lib_dir}/jsm %attr(755, jabber, jabber) %{jabber_lib_dir}/jsm/*.so %dir %{jabber_lib_dir}/xdb_file %attr(755, jabber, jabber) %{jabber_lib_dir}/xdb_file/*.so %dir %{jabber_lib_dir}/pthsock %attr(755, jabber, jabber) %{jabber_lib_dir}/pthsock/*.so %dir %{jabber_lib_dir}/dnsrv %attr(755, jabber, jabber) %{jabber_lib_dir}/dnsrv/*.so %dir %{jabber_lib_dir}/dialback %attr(755, jabber, jabber) %{jabber_lib_dir}/dialback/*.so %attr(750, jabber, jabber) %dir /var/spool/jabber %attr(755, jabber, jabber) %dir /var/log/jabber %attr(755, jabber, jabber) %dir /var/run/jabber %files aim %defattr(644, jabber, jabber, 755) %{_sysconfdir}/jabber.d/aim.xml %{_sysconfdir}/jabber.d/icq.xml %dir %{jabber_lib_dir}/aim %attr(755, jabber, jabber) %{jabber_lib_dir}/aim/*.so %dir %{jabber_lib_dir}/aim/binary %files msn %defattr(644, jabber, jabber, 755) %{_sysconfdir}/jabber.d/msn.xml %dir %{jabber_lib_dir}/msn %attr(755, jabber, jabber) %{jabber_lib_dir}/msn/*.so %files yahoo %defattr(644, jabber, jabber, 755) %{_sysconfdir}/jabber.d/yahoo.xml %dir %{jabber_lib_dir}/yahoo %attr(755, jabber, jabber) %{jabber_lib_dir}/yahoo/*.so %files conference %defattr(644, jabber, jabber, 755) %{_sysconfdir}/jabber.d/conference.xml %dir %{jabber_lib_dir}/conference %attr(755, jabber, jabber) %{jabber_lib_dir}/conference/*.so %files jud %defattr(644, jabber, jabber, 755) %{_sysconfdir}/jabber.d/jud.xml %dir %{jabber_lib_dir}/ %attr(755, jabber, jabber) %{jabber_lib_dir}/jud/*.so #%files irc #%defattr(644, jabber, jabber, 755) #%{_sysconfdir}/jabber.d/irc.xml #%dir %{jabber_lib_dir}/ #%attr(755, jabber, jabber) %{jabber_lib_dir}/irc/*.so %changelog * Wed Oct 8 2003 Kevin Sonney 1.4.2-9 - yahoo transport update - yahoo config file updates * Tue Jun 3 2003 Kevin Sonney 1.4.2-8 - add buildrequires for openssl, krb5, and glib - aurora build fixes * Tue May 27 2003 Kevin Sonney 1.4.2-7 - fixed ssl on Red Hat Linux 9 * Fri Feb 21 2003 Kevin Sonney 1.4.2-6 - added localstate dir * Tue Feb 04 2003 Kevin Sonney 1.4.2-5 - fix yahoo transport XML error - move irc transport to port order in jabber.xml - should consider including irc transport for shits & giggles * Sat Dec 14 2002 Kevin Sonney 1.4.2-4 - updated msn Transport config file * Sat Dec 14 2002 Kevin Sonney 1.4.2-3 - updated aim Transport * Fri Dec 13 2002 Kevin Sonney 1.4.2-2 - updated yahoo transport source - added check for autogen.sh in yahoo transport - updated yahoo transport config file * Wed Feb 20 2002 Benjamin Reed 1.4.2-1 - Initial RPM (1.4.2) -- based on RPMs by Matthias Saou