Subject: Re: Package update disaster
To: Anand Buddhdev <arb@anand.org>
From: Frederick Bruckman <fredb@immanent.net>
List: netbsd-users
Date: 10/06/2004 18:26:50
In article <41644E92.9050207@anand.org>,
	arb@anand.org (Anand Buddhdev) writes:
> 
> I must say that my initial excitement about pkgsrc is waning somewhat. 
> The pkgsrc guide recommends a user to type "make update" to update 
> packages.

"make update" is a bad joke.  What I do these days, is install to an
alternate "LOCALBASE", such as "/usr/pkg2" or "/usr/pkg3", adjusting
my "PATH" as appropropriate. E.g:

    $ /usr/pkg2/etc/mk.conf       
    # Don't forget to source "mk.sh"!
    #

    LOCALBASE=/usr/pkg2
    PACKAGES=/usr/pkg2/packages
    PKG_DBDIR=/usr/pkg2/var/db/pkg
    RPM_DB_PREFIX=/usr/pkg2/var/pkg

    .include "/etc/mk.conf"

    $ cat /usr/pkg2/etc/mk.sh 
    # Source me!
    #
    PATH=/bin:/usr/bin:/usr/pkg2/bin:/usr/X11R6/bin:/sbin:/usr/sbin:/usr/pkg2/sbin:/usr/X11R6/sbin

    export LOCALBASE=/usr/pkg2
    export MAKECONF=/usr/pkg2/etc/mk.conf
    export PACKAGES=/usr/pkg2/packages
    export PKG_DBDIR=/usr/pkg2/var/db/pkg
    export RPM_DB_PREFIX=/usr/pkg2/var/pkg

My normal, run-time "PATH" has everything in it. I also universally
build using "make package" as root, so everything that's installed
gets packaged, and if I do have to rebuild just one package, I can
reinstall all of its dependents quickly without rebuilding them.


Frederick