Comment 2 for bug 1285791

Revision history for this message
Dan Kegel (dank) wrote :

The postinst script for openjdk-6-jdk_6b27-1.12.6-1ubuntu0.10.04.4_amd64.deb says:

case "$1" in
configure)
    # obsolete tool
    if update-alternatives --list apt 2>/dev/null; then
        update-alternatives --remove-all apt || true
    fi

    if [ -z "$2" ]; then
        update_alternatives=y
    fi

...

https://www.debian.org/doc/debian-policy/ch-maintainerscripts.html says $2 is " most-recently-configured-version".

Thus it looks like a thinko ... the author of the postinst script thought $2 meant something else, or forgot that the postrm script removed the alternatives?

The same test appears to be present in ubuntu 12.04's openjdk-7-jdk_7u51-2.4.4-0ubuntu0.12.04.2_amd64.deb,
but I haven't verified yet whether the problem occurs there as well.