[BACK]Return to pkg-config.1 CVS log [TXT][DIR] Up to [local] / src / usr.bin / pkg-config

Annotation of src/usr.bin/pkg-config/pkg-config.1, Revision 1.3

1.3     ! ckuethe     1: .\"    $OpenBSD: pkg-config.1,v 1.2 2006/11/28 01:20:44 ckuethe Exp $
1.1       ckuethe     2: .\"
                      3: .\"    Copyright (c) 2006 Chris Kuethe <ckuethe@openbsd.org>
                      4: .\"
                      5: .\"    Permission to use, copy, modify, and distribute this software for any
                      6: .\"    purpose with or without fee is hereby granted, provided that the above
                      7: .\"    copyright notice and this permission notice appear in all copies.
                      8: .\"
                      9: .\"    THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
                     10: .\"    WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
                     11: .\"    MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
                     12: .\"    ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
                     13: .\"    WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
                     14: .\"    ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
                     15: .\"    OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
                     16: .\"
                     17: .Dd November 27, 2006
                     18: .Dt pkg-config 1
                     19: .Os
                     20: .Sh NAME
                     21: .Nm pkg-config
                     22: .Nd fetch metadata about installed software packages
                     23: .Sh SYNOPSIS
                     24: .Nm pkg-config
                     25: .Op Ar options
                     26: .Ar pkg-name Op Ar pkg-name ...
                     27: .Sh DESCRIPTION
                     28: The
                     29: .Nm
                     30: utility retreives metadata about the installation of software packages.
                     31: This metadata includes version, compiler and linker flags, and dependency
                     32: information.
1.2       ckuethe    33: It is inspired by, and intended to operate as a drop-in replacement to the
                     34: program of the same name available from freedesktop.org.
1.1       ckuethe    35: .Pp
                     36: Metadata is stored in files named after the package they describe; the
                     37: Yoyodyne package would likely be described by "yoyodyne.pc".
1.2       ckuethe    38: Not all software packages provide
                     39: .Nm
                     40: metadata. Packages controlled by the
1.1       ckuethe    41: .Xr ports 7
1.2       ckuethe    42: system store their metadata, if provided, in
                     43: .Pa ${LOCALBASE}/lib/pkgconfig ;
                     44: the X Window System stores its metadata in
1.1       ckuethe    45: .Pa ${X11BASE}/lib/pkgconfig.
1.2       ckuethe    46: The
                     47: .Nm
                     48: utility will search these locations by default.
1.1       ckuethe    49: .Pp
1.2       ckuethe    50: Because
                     51: .Nm
                     52: attempts to output the full set of compiler or linker flags required to
                     53: use a package, it will also output the flags required for any prerequisite
                     54: packages.
                     55: If the "foo" package depends on the bar package, "pkg-config --cflags foo"
                     56: might output something like "-I/usr/local/include/foo
                     57: -I/usr/local/include/bar", even though the compiler flags for "bar" were not
                     58: explicitly requested.
1.1       ckuethe    59: .Pp
                     60: The options are as follows:
                     61: .Bl -tag -width Ds
                     62: .It Fl -debug
                     63: Enable internal development and debugging messages.
                     64: .It Fl -help
                     65: Print a help message and exit.
                     66: .It Fl -usage
                     67: Print a help message and exit.
                     68: .It Fl -list-all
                     69: List all installed packages and exit.
                     70: .It Fl -version
                     71: Print version of
                     72: .Nm
                     73: and exit.
                     74: .It Fl -errors-to-stdout
                     75: Direct error messages to stdout rather than stderr.
                     76: .It Fl -atleast-pkgconfig-version Ar version
                     77: Exit with error if
                     78: .Nm
                     79: is not new enough.
                     80:
                     81: .It Fl -cflags
                     82: Return all compiler flags required to compile against the package.
                     83: .It Fl -cflags-only-I
                     84: Return only the include path flags required to compile against the package.
                     85: .It Fl -cflags-only-other
                     86: Return all compiler flags, other than the include path flags, required to
                     87: compile against the package.
                     88:
                     89: .It Fl -libs
                     90: Return all linker flags required to linker against the package.
                     91: .It Fl -libs-only-l
                     92: Return only the library (-lwhatever) flags required to link against
                     93: the package.
                     94: .It Fl -libs-only-L
                     95: Return only the library path (-L/path/to/lib) flags required to link
                     96: against the package.
                     97: .It Fl -libs-only-other
                     98: Return linker flags, other than the library and path flags, required to
                     99: compile against the package.
                    100:
                    101: .It Fl -exists
                    102: Return true if all the specified packages are installed.
                    103: .It Fl -uninstalled
                    104: Allow packages not controlled by
                    105: .Nm
                    106: to be used.
                    107: .It Fl -static
                    108: Return the compiler and/or linker flags required for static linking.
                    109: .It Fl -atleast-version Ar version
                    110: Exit with error if the specified package is not new enough
                    111: .It Fl -modversion
1.3     ! ckuethe   112: Fetch package version.
        !           113: If no package is given,
        !           114: .Nm
        !           115: returns its own version.
1.1       ckuethe   116: .It Fl -variable Ar name
                    117: Fetch the value of the named variable.
                    118: .El
                    119: .Sh ENVIRONMENT
                    120: .Bl -tag -width PKG_CONFIG_PATH
                    121: .It Ev PKG_CONFIG_PATH
                    122: This can be used to specify a colon-separated list of paths to search for
                    123: package files.
                    124: If given, this list of paths is prepended to the standard search path.
                    125: .El
                    126: .Pp
                    127: .Sh SEE ALSO
                    128: .Xr pkg_info 1 ,
                    129: .Xr ports 7
                    130: .Sh HISTORY
                    131: The
                    132: .Nm
                    133: utility first appeared in
                    134: .Ox 4.1