[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: RFC: allow output from maintainer scripts



On Thu, Oct 26, 2000 at 03:16:00PM -0600, Jason Gunthorpe wrote:
> On Fri, 27 Oct 2000, Anthony Towns wrote:
> > I find it hard to believe that this thread can reasonably go from
> > "there's no need for output at all for any reason" to "there's a need
> > for so much output that we must be able to categorise it and filter it,
> > and to hell with backwards compatability".
> No, the current situation has alot of output and this thread started
> because people want to see less - managing the output we already have
> seems to be a reasonable middle ground.

I don't really see what's so "middle ground" about it; it needs much more
significant changes to maintainer scripts [0], creates a compatability
problem, and doesn't really seem to buy anyone anything over the simpler
solution.

> > You'll be unable to install the .deb until your dpkg correctly supports
> > versioned provides (the preinst would fail), and apt won't have any idea
> > how to do the upgrade. This seems about exactly the same as previously.
> Er, I ment that using --asserts create confusing problems for the end user
> and preclude any possibility of a safe automatic upgrade. 

AFAICT, it's always *safe*, it's just that apt can't necessarily manage to
do everything for you *automatically*, and may require manual assistance
(by aborting halfway through) at (unpredicatable) times.

To fix this forever, we have to accurately predict all the sorts of
changes we'll ever make. Personally, I doubt that's possible.

Hmmm. Apart from the fact that dpkg and apt don't talk to each other about
ordering and failure issues to well, there needn't be a problem with a
preinst failing, need there? ie dpkg/apt sould be able to just finish
configuring the other stuff, and send a "Hey! This needs attention!"
report of some kind to the admin.

This is going a bit off topic...

Cheers,
aj

[0] Compare say:

	echo "Setting up emacsen-common to cope with emacs20." >&2
	/usr/lib/emacsen-common/emacs-install emacs20 >/dev/null 2>&1

    with, say (using the given API to display all the existing info in
    a filterable manner):

	dpkg-log () {
		if [ -e /usr/bin/dpkg-log ]; then 
			/usr/bin/dpkg-log "$@"
		else
			echo "$@"
		fi
	}
	dpkg-log "Setting up emacsen-common to cope with emacs20."
	/usr/lib/emacsen-common-common/emacs-install emacs20 |
		while read line; do
			dpkg-log --priority=low "$line"
		done


-- 
Anthony Towns <aj@humbug.org.au> <http://azure.humbug.org.au/~aj/>
I don't speak for anyone save myself. GPG signed mail preferred.

  ``We reject: kings, presidents, and voting.
                 We believe in: rough consensus and working code.''
                                      -- Dave Clark

Attachment: pgph3SDM1yKlR.pgp
Description: PGP signature


Reply to: