+%triggerpostun -- %{name} <= 0.75.1
+if [ -f /etc/clamav.conf.rpmsave ]; then
+ echo "Renaming config to new name /etc/clamd.conf"
+ mv -f /etc/clamd.conf /etc/clamd.conf.rpmnew
+ mv -f /etc/clamav.conf.rpmsave /etc/clamd.conf
+ echo "Changing config location in freshclam config"
+ %{__sed} -i -e 's/clamav.conf/clamd.conf/' /etc/freshclam.conf
+fi
+
+%triggerpostun -- %{name} < 0.90-0.rc2.0.10
+%{__cp} -f /etc/clamd.conf{,.rpmsave}
+%{__sed} -i -e '
+ s,^LogSyslog$,& yes,
+ s,^FixStaleSocket$,& yes,
+ s,^AllowSupplementaryGroups$,& yes,
+ s,^ClamukoScanOnOpen$,& yes,
+ s,^ClamukoScanOnClose$,& yes,
+ s,^ClamukoScanOnExec$,& yes,
+ s,^LogTime$,& yes,
+ s,^ScanPE$,& yes,
+' /etc/clamd.conf
+%banner -e %{name}-0.90 <<EOF
+ClamAV config was automatically upgraded to 0.90 format. You should review it
+that it's still valid.
+EOF
+#'
+# unfortunately clamd has no configcheck option so we just have to start it
+# once again after config was broken after upgrade
+touch /var/lock/subsys/clamd
+%service -q clamd restart
+