# Portmaster vs Portupgrade in 9.1 w/ pkgng recommendations



## shepper (Mar 11, 2013)

I recently installed 9.1 with PKGNG and began building ports March 7, 2013.  The xombrero port has a gtk failure that has been reported to the maintainer and there are updates for gimp.

At this time, everything was built from ports and I would like to upgrade the packages.  I read the handbook on ports and searched the forums looking information to guide the decision of choosing portmaster vs portupgrade.  Also looked for information to see if either tool integrates better with PKGNG.

I would appreciate any recommendations and rationale for the choice of ports management tool.


----------



## vermaden (Mar 11, 2013)

I choose portmaster long time ago because its in plain /bin/sh, no additional dependencies, works with plain FreeBSD base system. On the other hand portupgrade requires ruby, creates its own additional database which You also have to update, its totally useless approach for me.

The portmaster is simple, well thought, efficient and uses only the FreeBSD packages database.


----------



## wblock@ (Mar 11, 2013)

ports-mgmt/portupgrade and ports-mgmt/portupgrade-devel have some features that ports-mgmt/portmaster does not.  Those extra features are rarely needed, and now I only use portmaster.


----------



## bkouhi (Mar 11, 2013)

I decided to use portmaster but portupgrade has a very useful utility named portsclean. I use portsclean to remove old distfiles from /usr/ports/distfiles:

`# portclean -i -D`


Does portmaster have something like this? Or is there any other way to remove old distfiles form /usr/ports/distfiles?


----------



## kpa (Mar 11, 2013)

`# portmaster --clean-distfiles`

Automatic clean up without any questions:

`# portmaster -y --clean-distfiles`


----------



## jb_fvwm2 (Mar 12, 2013)

Oftentimes, one may wish to keep distfiles around for minor version bumps and rebuilds.
"d", lowercase, keeps the most recent one, but sometimes removes others which start with the same characters, but are longer.  Usually of no consequence.

```
make fetchindex && portsdb -u && pkgdb -F --omit-check
```
That is the principal way I use portupgrade...
it prompts for the removal of expired ports, as well as other fixups.  It works a whole lot better than it used to... if one has a little practice in answering its questions along the way.


----------



## attilagyorffy (Mar 12, 2013)

I've been having a very similar question. I'm also using PKGNG and I've been wondering if any of those tools (portmaster vs portupgrade) integrate with PKGNG.

Is that even feasible to have anything besides PKGNG? Won't portmaster (or portupgrade) and PKGNG step on each others' toes? What do I use to recompile outdated packages while I'm still using PKGNG for package management?

Thank you.


----------



## kpa (Mar 12, 2013)

PKGNG knows nothing about ports(7) *), it can not be used for the actual compilation of ports. It's a replacement for the old pkg_* tools, nothing else. Tools that know how to compile ports can use PKGNG as the backend for creating and registering compiled ports as packages to the system.

*) It does know how to parse /usr/ports/UPDATING for `$ pkg updating` but that is a special case.


----------

