Man Linux: Main Page and Category List

NAME

     pmkfile - pmk specification file

DESCRIPTION

     pmkfile is a file containing specifications that help configuring a
     package build on a given platform.

SYNTAX

     See pmksyntax.5 to have an overview of the basic syntax of pmkfiles.

SPECIFIC COMMANDS

     The following commands have no label.

     SETTINGS
             This command sets pmk parameters.

             Arguments:

                   AC_COMPAT  type is ’quoted’, enable autoconf compatibility
                              (empty string or filename).

                   LANG       type is ’quoted’, global default language.

                   TARGET     type is ’list’, list of target’s filenames.

                   DETECT     type is ’list’, list of languages (compilers to
                              identify).

             For example:

                   SETTINGS {
                           AC_COMPAT="config.h"
                           LANG="C"
                           TARGET=("src/file.c","src/file.h")
                           DETECT=("CC")
                   }

     DEFINE  This command permits to define variables.

             Arguments:

             Those are the variables to be defined (quote data type only).

             For example:

                   DEFINE {
                           PACKAGE="my_prog"
                           VERSION="0.1"
                   }

     SWITCHES
             This command is setting dependency switches (see further DEPEND
             definition).

             Arguments:

             For example:

                   SWITCHES {
                           use_curses=TRUE
                           use_gtk=FALSE
                   }

STANDARD COMMANDS

     All these commands need a label.

     They can all have the following optional arguments:

           REQUIRED  Specify if this test is required to achieve the
                     configuration.  Type is ’bool’.  If not specified, it is
                     TRUE by default.

           DEPEND    Specify check dependencies.  Type is ’list’.  A
                     dependency is a label or a switch name.  The value of
                     each dependency can be negated by adding a leading ’!’
                     sign.  If at least one of the dependencies is false then
                     the check will be disabled.

                     For example:

                           DEPEND = ("header_gtk","!header_qt")

           DEFS      Specify additional defines.  Type is ’list’.  If the
                     check succeeds then the given defines are also recorded
                     else they are ignored.

     Some of these commands can also have the following arguments:

     LANG    Specify the language used in the following list:

             C, C++

             Type is ’quoted’, by default \"C\" is the used language.

     Here the list of commands:

     CHECK_BINARY
             Check if a binary is in the path.

             Arguments:

                   REQUIRED

                   DEPEND

                   DEFS

                   NAME      type is ’quoted’, name of the binary.

                   VARIABLE  type is ’quoted’, variable name to store the
                             path.

     CHECK_HEADER
             Check language header and optionally a function.

             Arguments:

                   REQUIRED

                   DEPEND

                   DEFS

                   LANG

                   NAME      type is ’quoted’, name of the header.

                   MACRO     type is ’list’, list of one or more compiler
                             macros to check, optional.

                   FUNCTION  type is ’quoted’ or ’list’, name or list of
                             functions to check, optional.

                   CFLAGS    type is ’quoted’, variable name to store CFLAGS
                             values, optional.

                   SUBHDR    type is ’list’, list of header dependencies,
                             optional.

     CHECK_LIB
             Check a library and optionally a function.

             Arguments:

                   REQUIRED

                   DEPEND

                   DEFS

                   LANG

                   NAME      type is ’quoted’, name of the library to check.

                   FUNCTION  type is ’quoted’ or ’list’, name or list of
                             functions to check, optional.

                   LIBS      type is ’quoted’, variable name to store LIBS
                             values, optional.

     CHECK_CONFIG
             Check using a *-config tool.

             Arguments:

                   REQUIRED

                   DEPEND

                   DEFS

                   NAME      type is ’quoted’, config tool name.

                   VERSION   type is ’quoted’, minimal version needed,
                             optional.

                   CFLAGS    type is ’quoted’, variable name to store CFLAGS
                             values, optional.

                   LIBS      type is ’quoted’, variable name to store LIBS
                             values, optional.

                   VARIABLE  type is ’quoted’, variable name to store the path
                             of the config tool, optional.

     CHECK_PKG_CONFIG
             Check a package using pkg-config.

             Arguments:

                   REQUIRED

                   DEPEND

                   DEFS

                   NAME      type is ’quoted’, package name.

                   VERSION   type is ’quoted’, minimal version needed,
                             optional.

                   CFLAGS    type is ’quoted’, variable name to store CFLAGS
                             values, optional.

                   LIBS      type is ’quoted’, variable name to store LIBS
                             values, optional.

     CHECK_TYPE
             Check if the given type exists.

             Arguments:

                   REQUIRED

                   DEPEND

                   DEFS

                   LANG

                   NAME      type is ’quoted’, name of the type to check.

                   HEADER    type is quoted, name of the header where to find
                             the given type.

                   MEMBER    type is quoted, name of a member of the structure
                             given in NAME to be checked.

     CHECK_VARIABLE
             Check if the given variable does exist and optionally its value.

             Arguments:

                   REQUIRED

                   DEPEND

                   DEFS

                   NAME      type is ’quoted’, name of the variable to check.

                   VALUE     type is ’quoted’, value to check with the
                             variable, optional.

CONDITIONAL COMMANDS

     IF(expression)
             It contains other commands that will be executed only if the
             given expression is true.

             Arguments:

             For example:

                   IF(header_gtk) {
                           DEFINE {
                                   HAVE_GTK = "1"
                           }
                   }

     ELSE(expression)
             It contains other commands that will be executed only if the
             given expression is false.

             Arguments:

             For example:

                   ELSE(header_glib) {
                           DEFINE {
                                   HAVE_GLIB = "0"
                           }
                   }

LIBRARY NAME BUILDING

     BUILD_LIB_NAME
             This command helps you to build static and/or shared library
             name(s) depending on the rules of the host operanding system.

             Arguments:

                   NAME     type is ’quoted’, name of the library (without
                            leading ’lib’).

                   MAJOR    type is ’quoted’, major number for the version,
                            optional.

                   MINOR    type is ’quoted’, minor number for the version,
                            optional.

                   SHARED   type is ’quoted’, variable that will be set with
                            the shared library name, optional.

                   STATIC   type is ’quoted’, variable that will be set with
                            the static library name, optional.

                   VERSION  type is ’boolean’, boolean value for library
                            version processing , optional.

             For example:

                   BUILD_LIB_NAME {
                           NAME = "test"
                           STATIC = "TESTLIB_STATIC"
                           SHARED = "TESTLIB_SHARED"
                           MAJOR = "0"
                           MINOR = "2"
                           VERSION = TRUE
                   }

     BUILD_SHLIB_NAME
             This command has been obsoleted by the BUILD_LIB_NAME command.

SEE ALSO

     pmk(1), pmkscan(1), pmksyntax.5