[Fontconfig] fontconfig: Branch 'master' - 23 commits
Raimund Steger
rs at mytum.de
Sun Jan 6 07:15:52 PST 2013
Behdad Esfahbod wrote:
> [...]
> diff --git a/configure.ac b/configure.ac
> index 5657bb5..fda5650 100644
> --- a/configure.ac
> +++ b/configure.ac
> [...]
> +
> +have_pthread=false
> +if test "$os_win32" = no; then
> + AX_PTHREAD([have_pthread=true])
> +fi
> +if $have_pthread; then
> + AC_DEFINE(HAVE_PTHREAD, 1, [Have POSIX threads])
> +fi
> +AM_CONDITIONAL(HAVE_PTHREAD, $have_pthread)
I was doing some more testing and got coredumps when using FcFontMatch
from multiple threads on Solaris, using GCC as well as Sun Studio (the
latter with atomic operations from atomic.h, see attached --
/experimental/ -- patch -- which is NO suggestion for the upcoming
snapshot release (*) ).
Then I noticed that -mt or -D_REENTRANT had not been passed to 'cc'. Now
this is a Solaris specialty but I think AX_PTHREAD could do all the work:
http://www.gnu.org/software/autoconf-archive/ax_pthread.html
For now I seem to be successful by adding the following in the 'if
$have_pthread' branch above, as suggested by the linked docs:
LIBS="$PTHREAD_LIBS $LIBS"
CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
CC="$PTHREAD_CC"
(*) Solaris atomic operations do not implement a full memory barrier.
However, I'm not sure whether this is a problem for the way fontconfig
uses these operations. So far I've not been able to attribute any
coredumps to _this_ circumstance. This would need attention from an
expert on the subject (which I'm not).
Raimund
--
Worringer Str 31 Duesseldorf 40211 DE home: <rs at mytum.de>
+49-179-2981632 icq 16845346 work: <rs at interface-ag.de>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: solaris-atomic-20130105.diff
Type: text/x-patch
Size: 1968 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/fontconfig/attachments/20130106/da64a396/attachment.bin>
More information about the Fontconfig
mailing list