From 4b332eb7985630d575ce09311cb2253362921298 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc=20W=C3=A4ckerlin?= Date: Fri, 11 Mar 2005 23:22:05 +0000 Subject: [PATCH] multithreading libraries, new auto functiontrace and minor corrections --- mrw/mrw.hpp.in | 65 +++++++++++++++++++++++++++++++++++++------------- 1 file changed, 48 insertions(+), 17 deletions(-) diff --git a/mrw/mrw.hpp.in b/mrw/mrw.hpp.in index 716a3e1..42a7bad 100644 --- a/mrw/mrw.hpp.in +++ b/mrw/mrw.hpp.in @@ -39,22 +39,30 @@ See the "Related Pages". - - @ref readme "The Readme, a Short Overview" - - @ref download "Download, Dependencies and Simple Installation" - - @ref usage "Usage of the Library: Include and Link" - - @ref threads "Thread Safety" - - @ref libversion "Library Versioning" - - @ref license "License Information (LGPL)" - - @ref install "Detailed Compilation and Installation Information" - - @ref news "Breaking News, What's New?" - - @ref changes "Change Log" + - @ref readme + - @ref download + - @ref usage + - @ref threads + - @ref libversion + - @ref license + - @ref install + - @ref news + - @ref changes */ -/** @page download Download, Detailed und Simple Installation +/** @page download Download and Installation Download this version from here: - Requirements: - - No special requirements for the binary package! + - Boost thread library for multi threading: + http://boost.org + - log4cxx for automated tracing and function traces: + - http://logging.apache.org/log4cxx + - RPM: http://marc.waeckerlin.org/mrw-c++/log4cxx-0.9.7-1.i386.rpm + - @ref mrw::StackTrace requires: + - the GNU Binutils + - either GNU Compiler gcc or GNU C library glibc + - runs better on: either Linux or Solaris - Binary - Binary RPM Packages (built on i586/SuSE): - http://marc.waeckerlin.org/@PACKAGENAME@/@PACKAGENAME@-@MAJOR@.@MINOR@.@LEAST@-1.i586.rpm @@ -65,6 +73,7 @@ rpm -Uvh @PACKAGENAME@-devel-@MAJOR@.@MINOR@.@LEAST@-1.i586.rpm - Source - Requirements to build from source: + - boost: http://boost.org - cppunit: http://cppunit.sf.net - log4cxx: http://logging.apache.org/log4cxx - doxygen: http://doxygen.org @@ -93,27 +102,49 @@ #include @endverbatim - All classes are in the mrw namespace. + All classes are in the @c mrw namespace. if you want the mrw::StackTrace to evaluate file and line numbers, then you need to compile with debug information enabled, thats option @c -g. - Link to the library with option @c -lmrw, e.g.: + Link to the library with option @c -lmrw (or @c -lmrw-mt if your + program is multi threaded), e.g.: @verbatim g++ -g -o myprogram myprogram.cpp -lmrw @endverbatim - For the @ref AutoTools "unexpected handler" you need to link with - @c -lmrwexcstderr or @c -lmrwexclog4cxx. -*/ + For the @ref AutoTools "unexpected handler" you need to link to + @c -lmrwexcstderr or @c -lmrwexclog4cxx (or @c -lmrwexcstderr-mt + or @c -lmrwexclog4cxx-mt if your program is multi threaded). + + For the @ref AutoFunctionTrace "automated function trace" you need + to link to @c -lmrwautofunctiontracelog4cxx (or @c + -lmrwautofunctiontracelog4cxx-mt if your program is multi + threaded). In addition, you must compile and link your program + with the GNU compiler specific option @c -finstrument-functions */ /** @page threads Thread Safety + To enable thread safety, you must link to @c libmrw-mt instead of + @c libmrw. That means, your link option is: @c -lmrw-mt + + Different instances of classes can run in different threads, but + instances of classes can not be shared between different threads. + All classes are not thread safe, that means they should either always be accessed from the same thread, or you are responsible - for locking. If you need thread safety as a feature, please send + for locking. + + All methods are threads safe, that means, they can be called at + the same time from different threads. But not on the same object. + + This means: One instance should only be used within one single + thread. Different instances of the same class can be accessed + simultaneousely in different threads. + + If you need more thread safety as a feature, please send me an email and ask me for it (you find the address in the package or on my personal homepage: http://marc.waeckerlin.org). */