openpkg/rpm-config.pod

changeset 13
cb59d6afeb61
child 428
f880f219c566
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/openpkg/rpm-config.pod	Tue Jan 06 23:40:39 2009 +0100
     1.3 @@ -0,0 +1,125 @@
     1.4 +##
     1.5 +##  rpm-config -- OpenPKG RPM Library Build Utility
     1.6 +##  Copyright (c) 2000-2007 OpenPKG Foundation e.V. <http://openpkg.net/>
     1.7 +##  Copyright (c) 2000-2007 Ralf S. Engelschall <http://engelschall.com/>
     1.8 +##
     1.9 +##  Permission to use, copy, modify, and distribute this software for
    1.10 +##  any purpose with or without fee is hereby granted, provided that
    1.11 +##  the above copyright notice and this permission notice appear in all
    1.12 +##  copies.
    1.13 +##
    1.14 +##  THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
    1.15 +##  WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
    1.16 +##  MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
    1.17 +##  IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR
    1.18 +##  CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
    1.19 +##  SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
    1.20 +##  LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
    1.21 +##  USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
    1.22 +##  ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
    1.23 +##  OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
    1.24 +##  OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
    1.25 +##  SUCH DAMAGE.
    1.26 +##
    1.27 +##  rpm-config.pod: manual page
    1.28 +##
    1.29 +
    1.30 +=pod
    1.31 +
    1.32 +=head1 NAME
    1.33 +
    1.34 +B<rpm-config> - OpenPKG RPM library build utility
    1.35 +
    1.36 +=head1 VERSION
    1.37 +
    1.38 +OpenPKG RPM RPM_VERSION
    1.39 +
    1.40 +=head1 SYNOPSIS
    1.41 +
    1.42 +B<rpm-config>
    1.43 +[B<--help>]
    1.44 +[B<--version>]
    1.45 +[B<--cc>]
    1.46 +[B<--cppflags>]
    1.47 +[B<--cflags>]
    1.48 +[B<--ldflags>]
    1.49 +[B<--libs>]
    1.50 +
    1.51 +=head1 DESCRIPTION
    1.52 +
    1.53 +The B<rpm-config> program is a little helper utility for easy
    1.54 +configuring and building applications based on the OpenPKG RPM library.
    1.55 +It can be used to query the C compiler and linker flags which are
    1.56 +required to correctly compile and link the application against the
    1.57 +RPM library.
    1.58 +
    1.59 +=head1 OPTIONS
    1.60 +
    1.61 +B<rpm-config> accepts the following options:
    1.62 +
    1.63 +=over 4
    1.64 +
    1.65 +=item B<--help>
    1.66 +
    1.67 +Prints the short usage information.
    1.68 +
    1.69 +=item B<--version>
    1.70 +
    1.71 +Prints the version number and date of the installed RPM library.
    1.72 +
    1.73 +=item B<--cc>
    1.74 +
    1.75 +=item B<--cppflags>
    1.76 +
    1.77 +Prints the C pre-processor flags (C<-I>) which are needed to compile the
    1.78 +RPM-based application. The output is usually added to the C<CPPFLAGS>
    1.79 +variable of the applications C<Makefile>.
    1.80 +
    1.81 +=item B<--cflags>
    1.82 +
    1.83 +Prints the C compiler flags which are needed to compile the RPM-based
    1.84 +application. The output is usually added to the C<CFLAGS> variable of the
    1.85 +applications C<Makefile>.
    1.86 +
    1.87 +=item B<--ldflags>
    1.88 +
    1.89 +Prints the linker flags (C<-L>) which are needed to link the application with
    1.90 +the RPM library. The output is usually added to the C<LDFLAGS> variable of
    1.91 +the applications C<Makefile>.
    1.92 +
    1.93 +=item B<--libs>
    1.94 +
    1.95 +Prints the library flags (C<-l>) which are needed to link the application with
    1.96 +the RPM library. The output is usually added to the C<LIBS> variable of the
    1.97 +applications C<Makefile>.
    1.98 +
    1.99 +=back
   1.100 +
   1.101 +=head1 EXAMPLE
   1.102 +
   1.103 + CC       = `rpm-config --cc`
   1.104 + CPPFLAGS = `rpm-config --cppflags`
   1.105 + CFLAGS   = `rpm-config --cflags`
   1.106 + LDFLAGS  = `rpm-config --ldflags`
   1.107 + LIBS     = `rpm-config --libs`
   1.108 +
   1.109 + all: foo
   1.110 +
   1.111 + foo: foo.o
   1.112 +     $(CC) $(LDFLAGS) -o foo foo.o $(LIBS)
   1.113 +
   1.114 + foo.o: foo.c
   1.115 +     $(CC) $(CPPFLAGS) $(CFLAGS) -o foo.o -c foo.c
   1.116 +
   1.117 +=head1 SEE ALSO
   1.118 +
   1.119 +rpm(1), cc(1).
   1.120 +
   1.121 +=head1 AUTHOR
   1.122 +
   1.123 + Ralf S. Engelschall
   1.124 + rse@engelschall.com
   1.125 + www.engelschall.com
   1.126 +
   1.127 +=cut
   1.128 +

mercurial