pkgconfig class

The pkgconfig class is for packages that install .pc files. These files provide information about the build settings for the package vwhich are then made available by the pkg-config command.

Since the contents of the .pc files are used at build time they need to be installed into the staging area. All the actions performed by this class are appended to the stage task.

The actions performed by the pkgconfig class are:

  1. Copies the .pc files into the ${PKG_CONFIG_PATH} directory;

  2. If the package is not native then it modifies the contents of the .pc file in the ${PKG_CONFIG_PATH} area to ensure that all the paths in the script refer to the staging area;

A package is considered to be native if it also inherits the native class.

The class will search the source directory, ${S}, and all it's subdirectories, for files that end in .pc (it will ignore those that end in -uninstalled.pc) and process them as described above. All that is required to use the class is the addition of pkgconfig in an inherit statement:

inherit autotools pkgconfig