Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 8 Dec 2014 20:58:36 +0000 (UTC)
From:      Sean Bruno <sbruno@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r374320 - head/x11-fonts/fontconfig/files
Message-ID:  <201412082058.sB8KwaIS044360@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: sbruno
Date: Mon Dec  8 20:58:36 2014
New Revision: 374320
URL: https://svnweb.freebsd.org/changeset/ports/374320
QAT: https://qat.redports.org/buildarchive/r374320/

Log:
  #define fc_atomic_ptr_cmpexch() for mips/mips64 to supported functions.  Fixes
  build on these arch's
  
  PR:		195794
  Submitted by:	sson
  Reviewed by:	kwm
  Approved by:	mentor (implicit)

Added:
  head/x11-fonts/fontconfig/files/patch-src_fcatomic.h   (contents, props changed)

Added: head/x11-fonts/fontconfig/files/patch-src_fcatomic.h
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/x11-fonts/fontconfig/files/patch-src_fcatomic.h	Mon Dec  8 20:58:36 2014	(r374320)
@@ -0,0 +1,20 @@
+--- ./src/fcatomic.h.orig	2013-10-11 03:10:18.000000000 +0000
++++ ./src/fcatomic.h	2014-12-06 21:48:12.136252912 +0000
+@@ -96,7 +96,17 @@
+ #define fc_atomic_int_add(AI, V)	__sync_fetch_and_add (&(AI), (V))
+ 
+ #define fc_atomic_ptr_get(P)		(void *) (__sync_synchronize (), *(P))
++#if defined(__FreeBSD__) && defined(__mips_n64)
++#include <sys/types.h>
++#include <machine/atomic.h>
++#define fc_atomic_ptr_cmpexch(P,O,N)	atomic_cmpset_rel_64 ((uint64_t *)(P), (uint64_t)(O), (uint64_t)(N))
++#elif defined(__FreeBSD__) && defined(__mips)
++#include <sys/types.h>
++#include <machine/atomic.h>
++#define fc_atomic_ptr_cmpexch(P,O,N)	atomic_cmpset_rel_32 ((uint32_t *)(P), (uint32_t)(O), (uint32_t)(N))
++#else
+ #define fc_atomic_ptr_cmpexch(P,O,N)	__sync_bool_compare_and_swap ((P), (O), (N))
++#endif /* defined(__FreeBSD__) && defined(__mips__) */
+ 
+ 
+ #elif !defined(FC_NO_MT) && defined(HAVE_SOLARIS_ATOMIC_OPS)



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201412082058.sB8KwaIS044360>