This is the README for pthreads.0.9.2.tgz [Download] [Browse] [Up]
*** PCthreads (tm) release 0.9.2 (beta) README file *** INSTALLATION: STEP I HOWTO INSTALL THE LIBRARIES AND HEADER FILES Edit the Make.defs file so that the TOPDIR variable points to the current directory (i.e., the directory in which this file resides). For example: TOPDIR = $(HOME)/pthreads-0.9.2 Once the Make.defs file is edited, the just type "make install" as illustrated below: prompt> make install This procedure does nothing more than make a set of links in the the pthreads-0.9.2 source tree. If you want the pthread libraries available on a system wide basis, you'll have to wait until the final release, sometime in January. For now, you can build and experiment with POSIX threads in this directory. Of course, nothing except your spirit of adventure should prevent you from installing these libraries and header files system-wide yourself. [:-) STEP II HOWTO BUILD THE ANCILLARY LIBRARIES AND EXECUTABLE TESTS To build the libraries and executables issue the following commands: 1) To build A.OUT formatted libraries and executables: prompt> make all 2) To build ELF formatted libraries and executables: prompt> make ISELF="yes" If you want to support both A.OUT and ELF, just issue both commands (in no particular order). At the conclusion you should have the following libraries and header files (the .so.1 libraries are symbolic links to appropriately versioned ELF-shared libraries): ./include pthread.h typedefs.h utils.h locks.h pthread_socket.h ./lib libpthreads.a POSIX .1 threads for linux libpthreads.so.1 libpthreads_dce.a Draft 4 threads for DCE libpthreads_dce.so.1 libpthreads-ext.a Exception handling I/F for DCE libpthreads-ext.so.1 liblocks.a Library of shared and priority lock liblocks.so.1 services libsock_r.a Thread blocking socket I/O libsock_r.so.1 libc_r.a Some thread-safe stdlib routines libc_r.so.1 NOTE: I've left A.OUT as the default because most ELF systems will support both ELF and A.OUT formats, while A.OUT systems will not. STEP III HOWTO INSTALL THE MAN PAGES To install the man pages, you will have to have root privileges. Change to the root account (if not already) and type prompt> make install.man This step will install the libraries, header files, and man pages. NOTE: The man pages are "hard-wired" to be copied into the directory /usr/local/man/man3 If this directory path doesn't exist, the installation procedure will fail and ask you to make this directory path. To install these man pages in another directory, feel free to modify the .install_man.sh script. It's dirt simple. NOTE: If your MANPATH variable doesn't include this directory, set the MANPATH variable in your .cshrc, .login, or .profile depending on your shell preference. For example, I use the csh so in my .cshrc file I have setenv MANPATH /usr/local/man:$MANPATH NEW FEATURES THIS RELEASE: ------------------------- 1) PCthreads now supports both A.OUT and ELF formats. Since most ELF systems can accomodate A.OUT, but not vice-versa, the default format is A.OUT. 2) Multithreaded applications built with PCthreads may now be dynamically configured with respect to: - Timer interrupt interval (from 10 milliseconds to ... ) - Timer idle interval (from 10 milliseconds to ... ) - Default scheduling policy - Default quantum. - Default thread stack size - Default thread execution priority. These parameters are simply specified in the initialization file, ".pthread_initrc". This file behaves according to the usual precedence rules, i.e., the .pthread_initrc file in the startup directory takes precedence over one in the $HOME directory. If neither directory contains an initialization file, the library uses its hardcoded defaults. See the man page pthread_info 3) All man pages complete. FIXED BUGS: ----------- 1) Fixed floating-point context-switch bug. PCthreads was incorrectly restoring floating-point context under some circumstances. KNOWN BUGS AND RESTRICTIONS: ---------------------------- 1) Non-blocking sendmsg() and recvmsg() are not supported in libtbio.a because Linux does not yet support these services (although their system call counterparts are stubbed out in versions of Linux after 1.3.22). To build the libtbio.a library for your system, you must define the SENDMSG constant in the makefile in ./socklib. 2) If an application built against PCthreads forks, all threads and data in the process are copied into the child. I believe POSIX specifies that only the thread issuing the fork() be [re]instantiated in the child. I have decided to support this feature, but will not have time to complete pthread_atfork() until sometime after V1.0 ships. Mayber V1.1? 3) Asynchronous cancellations are dangerous and I am still not sure if they are working properly. If you must use async cancellation, make sure that you enable cancellation *only* when the target thread doesn't hold one or more mutexes. If a thread is cancelled while holding a mutex PCthreads will attempt to unlock the mutex after all of the threads cleanup and cancellation handlers have completed, if possible. 4) Compiling with the PRODUCTION flags (see Make.defs) causes the volatile qualifiers in the exception handling code (libpthreads-ext.a) to be discarded. This means that after a return from [sig]longjmp (and other non-local gotos) a variable declared as volatile can not be relied upon. I've tested this extensively, and so far have not ran into any problems. But that doesn't mean one of you won't. If you do, please let me know. Reporting Bugs: -------------- Please report all problems (and questions) via email to mtp@big.aa.net.
These are the contents of the former NiCE NeXT User Group NeXTSTEP/OpenStep software archive, currently hosted by Netfuture.ch.