|
Integrating Thread-- into projectsThread-- consists entirely of declaration files, so if you want to use Thread-- in you projects, you can just copy the headers into your projects source tree and read below for a few more issues. (However, read Copyright of the source code., and make sure you understand the terms of how you can do that).Autotools Based ProjectsThe easiest way is to use the provided aclocal macro filethreadmm.m4 . In this file, the macro AM_PATH_THREADMM that you can use in your configure.ac file. This will define the substitution variable THREADMM_CPPFLAGS to contain the path to the Thread-- headers, and THREADMM_LIBS to contain the libraries of the backend. Put that macro in your configuration file.
... AM_PATH_THREADMM ...
And in your
... AM_CPPFLAGS = $(THREADMM_CPPFLAGS) AM_LDFLAGS = $(THREADMM_LIBS) ... Selecting the Backend to UseOfcourse, if you copy the headers to your project, you know where the headers are, and so you don't need to get the inclussion path for the headers. However, you still need to figure out what bakend will be used on the targe system. If you're only compiling for one thread model (say POSIX threads), then you can probably do away with defining the preprocessor macrosTHREADMM_POSIX , THREADMM_CTHREADS , and/or THREADMM_WIN32 . However, if you do not know a priori what thread library is available on the target system, you need to do some sort of test to see what is available.
The file
... THREADMM_MODELS ...
This macro will define the preprocessor macro
THREADMM_MODELS tries to figure that out for you, but if you don't use that macro, you need to figure it out yourself.
Top of pageLast update Tue Nov 9 12:40:50 2004 Christian Holm Created by DoxyGen 1.3.9.1 |