|
From: | Eric PAIRE |
Subject: | Re: GCC with '-threads' on SOLARIS not supported by ltmain.sh |
Date: | Thu, 08 Jun 2006 17:20:11 +0200 |
User-agent: | Mozilla/5.0 (X11; U; SunOS sun4u; en-US; rv:1.0.1) Gecko/20020920 Netscape/7.0 |
Bob, The threads(3THR) manual page for Solaris specifies: POSIX cc -mt [ flag... ] file...- lpthread [ -lposix4 library... ] Solaris cc - mt [ flag... ] file...[ library... ]But, if you read closely, you will see that the page refers to 'cc' and not 'gcc' :-(, and if you read the specs files of 'gcc', you will discover that gcc refuses the '-mt' flag but accepts '-pthreads' flag when compiling for POSIX threads, and '-threads' one when compiling for SOLARIS threads, without having to add '-lpthread' (which is much simpler IMHO).
The problem now with ltmain.sh, is that it recognizes '-pthreads' and '-mt' flags (and plenty other ones) , but not '-threads' one (probably because nobody uses SOLARIS threads with libtool and gcc).
Hope this clarifies my request, Eric Bob Friesenhahn wrote:
On Thu, 8 Jun 2006, Eric PAIRE wrote:I try to use libtool with a SOLARIS multithreaded library using SOLARIS threads (not PTRHEADS) and gcc. It occurs that the option to use with gcc '-threads' is not taken into account by ltmain.sh, whereas '-mt' (the one to be used with Sun CC) is. I read in the latest version (1.5.22) that the problem is still present.I suggest that you read the threads(3THR) manual page for Solaris. It will become clear within the first paragraph. I promise!Bob ====================================== Bob Friesenhahnaddress@hidden, http://www.simplesystems.org/users/bfriesen/GraphicsMagick Maintainer, http://www.GraphicsMagick.org/
[Prev in Thread] | Current Thread | [Next in Thread] |