%define name ayttm %define version 0.2.2 %define release 2mdk # Enable to turn off stripping of binaries %{?_without_stripping: %{expand: %%define __os_install_post %%{nil}}} Summary: Instant messaging client Name: %{name} Version: %{version} Release: %{release} License: GPL Group: Networking/Instant messaging Source: %{name}-%{version}.tar.bz2 Source10: %{name}.16.png.bz2 Source11: %{name}.32.png.bz2 Source12: %{name}.48.png.bz2 Patch1: %{name}-%{version}-fixchatrestore.patch.bz2 URL: http://www.nongnu.org/ayttm/ Requires: ispell BuildRequires: bison BuildRequires: flex BuildRequires: gtk+-devel BuildRequires: libltdl-devel BuildRequires: libesound-devel BuildRequires: libarts-devel BuildRequires: freetype-devel BuildRoot: %{_tmppath}/%{name}-buildroot %description Ayttm is designed to become a Universal Instant Messaging client designed to seamlessly integrate all existing Instant Messaging clients and provide a single consistant user interface. Currently, Ayttm supports sending and receiving messages via AOL, ICQ, Yahoo, MSN, IRC and Jabber. Ayttm is a fork of everybuddy, which is being maintained and has bug fixes made to it. %prep rm -rf $RPM_BUILD_ROOT #CVS build setup #%setup -q -n %{name}-20030130 %setup -q %patch1 -p2 -b .chatrestore # "patch" to make the modules go in the right place. # Because we're changing the Makefile's we need to remake the automake # stuff... perl -pi -e 's#\${pkgdatadir}/modules#\${libdir}/\@PACKAGE\@#g' src/Makefile.am perl -pi -e 's#lib_LTLIBRARIES#pkglib_LTLIBRARIES#g' `find modules -name Makefile.am` libtoolize --copy --force --ltdl --automake aclocal -I m4 $ACLOCAL_FLAGS autoheader automake -a -c autoconf %build # gen is needed for CVS builds #./gen %configure --enable-esd --enable-arts --enable-xft %make %install %makeinstall # We don't need the .a files... rm -f %{buildroot}/%{_libdir}/%{name}/*.a (cd $RPM_BUILD_ROOT mkdir -p ./usr/lib/menu cat > ./usr/lib/menu/%{name} <<EOF ?package(%{name}):\ command="/usr/bin/ayttm"\ icon="%{name}.png"\ title="Ayttm"\ longtitle="Universal Instant Messaging Client"\ needs="x11"\ section="Networking/Instant messaging" EOF ) mkdir -p $RPM_BUILD_ROOT%{_miconsdir} mkdir -p $RPM_BUILD_ROOT%{_liconsdir} bzcat %{SOURCE10} > $RPM_BUILD_ROOT%{_miconsdir}/%{name}.png bzcat %{SOURCE11} > $RPM_BUILD_ROOT%{_iconsdir}/%{name}.png bzcat %{SOURCE12} > $RPM_BUILD_ROOT%{_liconsdir}/%{name}.png # remove unpackaged files rm -f $RPM_BUILD_ROOT/etc/X11/applnk/Internet/Ayttm.desktop rm -f $RPM_BUILD_ROOT/usr/share/applnk/Internet/ayttm.desktop rm -f $RPM_BUILD_ROOT/usr/share/gnome/apps/Internet/ayttm.desktop %find_lang %name %post %{update_menus} # Fix the paths to the modules in the prefs files... # Note that $ has to be escaped so the shell doesn't wack # them. perl <<EOP while (my (@pwent) = getpwent()) { my \$homedir = \$pwent[7]; my \$prefs; if (open PREFS, "<\$homedir/.ayttm/prefs") { while (<PREFS>) { s!%{_datadir}/%{name}/modules!%{_libdir}/%{name}!g; \$prefs .= \$_; } close PREFS; unless (rename("\$homedir/.ayttm/prefs","\$homedir/.ayttm/prefs.orig")) { warn "Cannot \$homedir/.ayttm/prefs to \$homdir/.ayttm/prefs.orig"; next; } open PREFS, ">\$homedir/.ayttm/prefs"; print PREFS \$prefs; close PREFS; } } EOP %postun %{clean_menus} %files -f %name.lang %defattr (-,root,root) %doc doc/ AUTHORS COPYING ChangeLog INSTALL README TODO %{_bindir}/* %{_mandir}/man1/* #%{_datadir}/applnk/Internet/Everybuddy.kdelnk %{_datadir}/pixmaps/ayttm.png %dir %_datadir/%name %_datadir/%name %dir %_libdir/%name %_libdir/%name #%{_datadir}/gnome/apps/Networking/Everybuddy.desktop %{_iconsdir}/*.png %{_miconsdir}/*.png %{_liconsdir}/*.png %{_menudir}/* %clean rm -rf $RPM_BUILD_ROOT %changelog * Sun Mar 09 2003 Ben Reser <ben@reser.org> 0.2.2-2mdk - Move the modules to %%_libdir rather than %%_datadir to comply with FHS. - Add script to post to fix prefs due to the change in path for the modules. - Remove static library files that we don't really need. - Enable xft - BuildRequire freetype-devel * Wed Feb 26 2003 Ben Reser <ben@reser.org> 0.2.2-1mdk - 0.2.2 - Remove readprefs patch, integrated upstream. - Add patch to fix chat restore with do_strip_html=1 Was a bug in the released version. * Tue Feb 11 2003 Ben Reser <ben@reser.org> 0.2.1-2mdk - Fix description - Fix group - Remove unused menu files - Make package the owner of its dir under share - Add some missing documentation files. - Add icons for the menu - Use Mandrake macros for build - Add BuildRequires/Requires - Add some commented out stuff to the spec for easier CVS builds. - Quiet the %%setup. - Clean out non-Mandrake formated changelog - Force arts and esd to be enabled so it should work right with them without soundwrapper! * Mon Feb 10 2003 Lenny Cartier <lenny@mandrakesoft.com> 0.2.1-1mdk - new - icon - bzip2 patch