config() {
  NEW="$1"
  OLD="$(dirname $NEW)/$(basename $NEW .new)"
  if [ ! -r $OLD ]; then
    mv $NEW $OLD
  elif [ "$(cat $OLD | md5sum)" = "$(cat $NEW | md5sum)" ]; then
    rm $NEW
  fi
}

config usr/share/dbus-test-runner/session.conf.new
config usr/share/dbus-test-runner/system.conf.new
( cd usr/lib64 ; rm -rf libdbustest.so )
( cd usr/lib64 ; ln -sf libdbustest.so.1.0.0 libdbustest.so )
( cd usr/lib64 ; rm -rf libdbustest.so.1 )
( cd usr/lib64 ; ln -sf libdbustest.so.1.0.0 libdbustest.so.1 )
