--- slim-1.2.3-r1.ebuild 2006-01-10 18:28:47.000000000 +0100 +++ slim-1.2.4.ebuild 2006-01-19 14:56:59.000000000 +0100 @@ -20,13 +20,13 @@ src_unpack() { unpack ${A} cd ${S} - epatch ${FILESDIR}/${P}-cflags.patch - epatch ${FILESDIR}/${P}-daemon-configoption.patch + epatch ${FILESDIR}/${PN}-cflags.patch +# epatch ${FILESDIR}/${P}-daemon-configoption.patch - if [ -e /etc/init.d/xdm ]; then + if [ -e /etc/init.d/xdm ] && [ -z "`grep slim /etc/init.d/xdm`" ]; then einfo "Patching /etc/init.d/xdm file..." cp /etc/init.d/xdm . - epatch ${FILESDIR}/${P}-xdm.patch + epatch ${FILESDIR}/${PN}-xdm.patch fi # Remove all X11R6 references from slim.conf @@ -56,3 +56,6 @@ einfo "xinitrc.sample in /usr/share/doc/${PF}" } +pkg_postrm() { + patch -R --no-backup-if-mismatch /etc/init.d/xdm ${FILESDIR}/${PN}-xdm.patch +}