2 ## GNU Pth - The GNU Portable Threads
3 ## Copyright (c) 1999-2006 Ralf S. Engelschall <rse@engelschall.com>
5 ## This file is part of GNU Pth, a non-preemptive thread scheduling
6 ## library which can be found at http://www.gnu.org/software/pth/.
8 ## This library is free software; you can redistribute it and/or
9 ## modify it under the terms of the GNU Lesser General Public
10 ## License as published by the Free Software Foundation; either
11 ## version 2.1 of the License, or (at your option) any later version.
13 ## This library is distributed in the hope that it will be useful,
14 ## but WITHOUT ANY WARRANTY; without even the implied warranty of
15 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 ## Lesser General Public License for more details.
18 ## You should have received a copy of the GNU Lesser General Public
19 ## License along with this library; if not, write to the Free Software
20 ## Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
21 ## USA, or contact Ralf S. Engelschall <rse@engelschall.com>.
23 ## pthread-config.pod: pthread library build utility manual page
30 B<pthread-config> - Pth pthread library build utility
34 GNU Pth PTH_VERSION_STR
54 The B<pthread-config> program is a little helper utility for easy configuring
55 and building applications based on the pthread emulation API of the GNU
56 Portable Threads (pth) library. It can be used to query the C compiler and
57 linker flags which are required to correctly compile and link the application
58 against the pth(3) library.
62 B<pthread-config> accepts the following options:
68 Prints the short usage information.
72 Prints the version number and date of the installed pth(3) library.
76 Forces the output of all flags, that is, including extra flags which are not
81 Prints the installation prefix of architecture independent files
83 =item B<--exec-prefix>
85 Prints the installation prefix of architecture dependent files.
89 Prints the installation directory of binaries.
93 Prints the installation directory of libraries.
97 Prints the installation directory of include headers.
101 Prints the installation directory of manual pages.
105 Prints the C compiler flags which are needed to compile the pth(3)-based
106 application. The output is usually added to the C<CFLAGS> variable of the
107 applications C<Makefile>.
111 Prints the linker flags (C<-L>) which are needed to link the application with
112 the pth(3) library. The output is usually added to the C<LDFLAGS> variable of
113 the applications C<Makefile>.
117 Prints the library flags (C<-l>) which are needed to link the application with
118 the pth(3) library. The output is usually added to the C<LIBS> variable of the
119 applications C<Makefile>.
126 CFLAGS = -O `pthread-config --cflags`
127 LDFLAGS = `pthread-config --ldflags`
128 LIBS = -lm `pthread-config --libs`
132 $(CC) $(LDFLAGS) -o foo foo.o $(LIBS)
134 $(CC) $(CFLAGS) -c foo.c