Re: Bug#68661: Should not remove pager's alternative on upgrade
>>>>> "Stephen" == Stephen Zander <gibreel@pobox.com> writes:
>>>>> "Brian" == Brian May <bam@debian.org> writes:
Brian> Why doesn't running update-alternatives-jdk1.1 change the
Brian> status to manual? -- Brian May <bam@debian.org>
Stephen> Because it's still manipulating /etc/alternaives through
Stephen> update-alternatives, the Right Way to do it.
Thats not how I read the code (I must say I was rather surprised when
I first saw it):
make_link_jdk11() {
if [ -L /etc/alternatives/$1 ]; then
echo $1
if [ "$2" = "--auto" ]; then
update-alternatives --auto $1
else
ln -sf /usr/lib/jdk1.1/bin/$1 /etc/alternatives/$1
ln -sf /usr/share/man/man1/java-jdk11.1.gz /etc/alternatives/${1}.1.gz
fi
fi
}
if [ "$1" = "--help" ] ; then
echo "Usage: update-alternatives-jdk1.1 [--help] [--auto]"
echo
echo "Normally, just run as root with no arguments to set links in /etc/alternatives."
echo " --help This usage summary"
echo " --auto Use update-alternatives --auto to set symlinks to defaults"
0 exit
fi
# From jdk1.1-runtime
make_link_jdk11 java $*
[...]
so - why is this not marking it as "manual"?
I didn't notice that --auto option though. Interesting...
Stephen> Manually manipulating the symlinks at the f/s level is
Stephen> what causes update-alternatives to mark an alternative as
Stephen> being in manual mode, the Wrong Way to do it.
The following message would appear to contradict what you have
just said:
&pr("Checking available versions of $name, updating links in $altdir ...\n".
"(You may modify the symlinks there yourself if desired - see \`man ln'.)")
if $verbosemode > 0;
Not that I am deliberately shooting holes in your reasoning, I am just
curious how this is meant to work...
--
Brian May <bam@debian.org>
Reply to: