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

Re: Newbie: General ports management



On Sun, 23 Jun 2002, Marcus Bointon wrote:

> However, I'm getting into a bit of a state regarding what I have installed.
> Often when installing a port, although it will work with the usual make;make
> install, there are often additional configuration options in a ./configure
> (PHP springs to mind).

When using a port, I look at the Makefile, searching for FLAVOR lines.
For example, /usr/ports/www/php4/Makefile has:

FLAVORS+=       gdbm gettext imap ldap mhash mm recode snmp
FLAVORS+=       gd no_x11 pdflib mcrypt curl
FLAVORS+=       dbase filepro mysql mysql_bundled postgresql iodbc

`man ports`, and searching for FLAVORS will show the correct syntax
for using these:

           $ env FLAVOR="static" make package

and even using PHP as an example of multiple flavors:

           $ cd /usr/ports/www/php4
           $ env FLAVOR="imap ldap recode" make install

> When a port is installed and working, I'm very
> unclear as to how I go about upgrading it.

I upgrade a port when I upgrade my port tree. Then (in the simple case),
I pkg_delete $oldpackage, then cd /usr/ports/$category/$newpackage; make
make install. There may be times when there are dependency trees that need
to be backtracked, and upgraded, which is more of a hassle, but essentially
the same process. Note that if you have a production machine where
unannounced service interruption is unacceptable, schedule a maintenance
window, and time the build process on a *testbed* machine so you know how
long to make that window.

[snip]

> It seems that the FAQs are, quite rightly, concerned with getting things up
> and running, and they were great getting me here, but general strategies for
> system management just seems too woolly a topic for them to cover.

Indeed. There are many resources for general system management.
http://www.usa.openbsd.org/books.html lists two books that are
canonical favorites.

The purple book (formerly the red book[1]), _UNIX System Administration
Handbook (3rd Edition)_
http://www.amazon.com/exec/obidos/ASIN/0130206016/qid=1024819617/sr=8-1/ref=sr_8_1/002-5136187-0518462

_Essential System Administration_
http://www.amazon.com/exec/obidos/ASIN/1565921275/qid=1024819651/sr=1-12/ref=sr_1_12/002-5136187-0518462

> I'm finding that things are getting unmanageable. I have no idea what
> dependencies these things might have, so I can't just go around removing
> them.

Again, look at the Makefile, for DEPENDS. Or `pkg_info -f $pkgname` and
grep for "depends".

[snip]

[1] No, it's not the only red book. This is my red book. There are many
    like it, but this one is mine. Etc.

[ Dave Taira <bodhi_(_at_)_hagakure_(_dot_)_org>                2002.06.23/01:29:02 PDT ]
[ Morlock for Hire                                                       ]
[ You don't have to be impossible to manipulate. You just make it more   ]
[ trouble than you're worth.                                    --Andr00 ]



Visit your host, monkey.org