/usr/Makefile: Add pkg-bootstrap target
authorJohn Marino <draco@marino.st>
Wed, 5 Jun 2013 23:51:47 +0000 (01:51 +0200)
committerJohn Marino <draco@marino.st>
Wed, 5 Jun 2013 23:51:47 +0000 (01:51 +0200)
commit3271cef575a2c2788dee60090dae9c01d21b62ac
treeb9b95dcfe818c920f1b6f3005a9d59a6807c3467
parent70585eea6b8190fc25b2987f43140d2b47103da2
/usr/Makefile: Add pkg-bootstrap target

New snapshots provide a pre-built "pkg" tool so pre-build dports
binaries can be installed easily.  However, upgrades from older releases
won't have "pkg" available, and for those systems they had to download
the entire dports repository just to build pkg in order to take advantage
of the available pre-built packages.

To fix this situation, and the situation where /usr/local/sbin/pkg is
lost for any reason, a new make target has been added to /usr/Makefile:
pkg-bootstrap

The pkg-bootstrap target will download a pre-built "pkg-static" program
along with pkg.conf and all the man pages.  In reality, pkg-static is
only used for one command, and that is to install a full "pkg" program
from the dragonfly repository.

If "pkg.conf" already exists, a message will instruct the user to move
it first.  If /usr/local/sbin/pkg already exists, the target won't work
and it won't even show as an option.

After pkg-static is installed, the user will be instructed to type
"rehash; pkg-static install -y pkg; rehash" which should result in the
system having the latest pkg on their system and thus can proceed to
install packages normally.
etc/Makefile.usr