#!/bin/sh

set -e

if test "$1" = install -o "$1" = upgrade; then
    # DEP17 P1 mitigation. Remove these diversions via postinst once trixie is released.
    for lib in e2p.so.2 e2p.so.2.3 ext2fs.so.2 ext2fs.so.2.4; do
	dpkg-divert --package libext2fs2t64 --no-rename --divert "/lib/x86_64-linux-gnu/lib$lib.usr-is-merged" --add "/lib/x86_64-linux-gnu/lib$lib"
    done
fi


