Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

It seems that the FreeBSD ports tree is busy transitioning from pkg-config to pkgconf. http://www.mail-archive.com/freebsd-ports-announce@freebsd.org/msg00018.html

I first thought as an end user this would not influence me and that a tool like portmaster would be taking care of any transition. However today, the regular portmaster -a gave the following problem:

sudo portmaster -a
===>>> Gathering distinfo list for installed ports

===>>> Starting check of installed ports for available updates

    ===>>> The devel/pkg-config port moved to devel/pkgconf
    ===>>> Reason: pkg-config has been replace by pkgconf

===>>> Launching child to reinstall pkg-config-0.25_1

===>>> All >> pkg-config-0.25_1 (1/1)

    ===>>> The devel/pkg-config port moved to devel/pkgconf
    ===>>> Reason: pkg-config has been replace by pkgconf

===>>> Port directory: /usr/ports/devel/pkgconf

===>>> Launching 'make checksum' for devel/pkgconf in background
===> No options to configure
===>>> Gathering dependency list for devel/pkgconf from ports
===>>> No dependencies for devel/pkgconf

===>>> Returning to update check of installed ports

===>>> All >> (1)

===>>> The following actions will be taken if you choose to proceed:
    Install devel/pkgconf

===>>> Proceed? y/n [y]

Finishing with:

Stop in /usr/ports/devel/pkgconf.

===>>> Installation of pkgconf-0.8.4 (devel/pkgconf) failed
===>>> Aborting update

===>>> Update for devel/pkgconf failed
===>>> Aborting update


===>>> You can restart from the point of failure with this command line:
       portmaster <flags> devel/pkgconf 

What should a 'normal' user of FreeBSD do? I can't remove pkg-config as a lot of ports depend on it. How can this be fixed?

share|improve this question
This forum thread could be helpful – sr_ Jul 30 '12 at 13:46
up vote 9 down vote accepted

You should always read /usr/ports/UPDATING before carrying out a port upgrade. In this case, it has this to say about the deprecation of pkg-config:

  AFFECTS: users of devel/pkg-config
  AUTHOR: bapt@FreeBSD.org

  devel/pkg-config has been replaced by devel/pkgconf

  # portmaster -o devel/pkgconf devel/pkg-config
  # portupgrade -fo devel/pkgconf pkg-config-\*

  # pkg set -o devel/pkg-config:devel/pkgconf
  # pkg install -f devel/pkgconf

If you follow these instructions, your ports management tool of choice (which seems to be portmaster in your case) will remove pkg-config and install pkgconf, and will update the package registry database under /var/db/pkg to reflect the change. If you were a portupgrade user, the upgrade would also fix up the dependency graph in portupgrade's own database, which is separate from the standard registry.

Future installs/upgrades should "just work".

share|improve this answer

For those without ports-mgmt tools, this should work:

pkg_delete -f pkg-config\*
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.