Dealing with versioned perl-base
-----BEGIN PGP SIGNED MESSAGE-----
Note that I've sent this to both debian-devel and debian-perl but sent
the followups to debian-perl since that's where this should really be
discussed. But since there don't seem to be anyone reading it, I'm
including debian-devel.
The problem:
Currently when perl-base is installed, it only installs
/usr/bin/perl.dist and mv's this to /usr/bin/perl in the postinst. When
it's removed/replaced, it ln's perl.dist to perl. This is so that
package preinst and postrm scripts that are written in Perl can still
run while perl-base is being replaced.
Well, this causes problems when there is more than one possible
perl-base installed. I was considering have a designated perl-base
which would be the only one. This would be good from a standpoint of
only having the one essential perl package and make it easier on me.
But it would suck for the users since they wouldn't be able to only use
a different version.
My current idea that I'm floating is to replace the current (from
base.prerm):
(cd /usr/bin; test -f perl.dist || ln perl perl.dist)
with something a little more complex. First, it would do a readlink to
find out if the current version being replaced is the version that is
linked to /usr/bin/perl in /etc/alternatives. If it's not, it doesn't
worry about it. If it is, it removes the symlink, makes a hard link
from perl to perl-=version=, and notes which version is current.
(mostly likely with a dangling symlink to the version-number.) This
should keep Perl around for postrms and preinsts. During the postinst,
the reverse would occur.
Does this sound like a viable idea?
Thanks,
Darren
- --
<torin@daft.com> <http://www.daft.com/~torin> <torin@debian.org> <torin@io.com>
Darren Stalder/2608 Second Ave, @282/Seattle, WA 98121-1212/USA/+1-800-921-4996
@ Sysadmin, webweaver, postmaster for hire. C/Perl/CGI/Pilot programmer/tutor @
@ Make a little hot-tub in your soul. @
-----BEGIN PGP SIGNATURE-----
Version: 2.6.3a
Charset: noconv
Comment: Processed by Mailcrypt 3.5.1, an Emacs/PGP interface
iQCVAwUBNyQwX44wrq++1Ls5AQG8rQP+PyqfShoonHqxGx5VCM+gA5KCFwk2igE8
v6CNb3qNk6Tp68ieJ2GJlfoYB5BXQdVER55FdOCXqULX3NwJDWYPUGDfGD4H1Xtr
vVY6kOtdJ55iivNaRgWENhJwhAsjncg4IRIjc7soVKle9ggtX1t3WexGVF9p6yG+
o+KAJ3KAkmM=
=qpgi
-----END PGP SIGNATURE-----
Reply to: