Fixes for boost 1.55, use with at least cce/8.3.0.186  
======================================================

Hi Avi,

here a reply from Cray:


the following back from the compiler group on this:

---

This is one of half a dozen constants that GNU provides, but that we (at the present time) don't.  
I believe these will be defined by the compiler when we have relatively complete C++ 11 support.

In the meantime,

They can use the 1.56 version of ...boost/config/compiler/cray.hpp available here. 
https://github.com/boostorg/config/blob/master/include/boost/config/compiler/cray.hpp

 
Or insert the following into ...boost/config/user.hpp

#ifndef __ATOMIC_RELAXED
#define __ATOMIC_RELAXED 0
#define __ATOMIC_CONSUME 1
#define __ATOMIC_ACQUIRE 2
#define __ATOMIC_RELEASE 3
#define __ATOMIC_ACQ_REL 4
#define __ATOMIC_SEQ_CST 5
#endif


or add these 8 lines to the ...boost/config/compiler/cray.hpp that they are using now.


Christian

----- Original Message -----
> From: "Avi Bahra" <avi.bahra@ecmwf.int>
> To: "Christian Weihrauch" <christian.weihrauch@ecmwf.int>
> Cc: "Tiago Quintino" <tiago.quintino@ecmwf.int>
> Sent: Thursday, 19 June, 2014 3:43:19 PM
> Subject: Re: boost-1.55 patch for Cray
>
> Hi Christian,
>
>    I have applied the patch to boost 1.55.
>    Most of boost compiled libs now build, with cray cce/8.3.0.186.
>
>    However it still fails to compile boost thread.
>    Not sure if this is bug in their 'cray.jam' file, since it seems
>    reference gnu ?
>    Can you please inquire, if this is still a known issue.
>
> CC-20 crayc++: ERROR File =
> /perm/ma/ma0/boost/boost_1_55_0/./boost/atomic/detail/gcc-atomic.hpp,
> Line = 37
>   The identifier "__ATOMIC_RELAXED" is undefined.
>
>       return (order == memory_order_relaxed ? __ATOMIC_RELAXED :
>       (order == memory_order_consume ? __ATOMIC_CONSUME :
>
> Best regards
>
> Ta,
>   Avi
>
> ----- Original Message -----
> From: "Christian Weihrauch" <christian.weihrauch@ecmwf.int>
> To: "Avi Bahra" <avi.bahra@ecmwf.int>, "Tiago Quintino"
> <tiago.quintino@ecmwf.int>, "Stephan Siemen"
> <stephan.siemen@ecmwf.int>
> Sent: Monday, 16 June, 2014 4:01:03 PM
> Subject: boost-1.55 patch for Cray
>
> Hi,
>
> Here the diff for boost-1.55 provided by Cray.
>
>
> ###########################################################################################
>
> Please find attached a patch file against the boost-1.55.0 source.
>   This should be used with cce/8.3.0.
>
> Instructions for use:
>
> > tar xvf boost_1_55_0.tar   (untar the boost archive into
> > boost_1_55_0
> > cp smalldiff boost_1_55_0  (copy the patch file into the boost
> > directory)
> > cd boost_1_55_0
> > patch -p0 <smalldiff (apply patches to get cray to work better)
> > ./bootstrap.sh
> > ./b2 --with-serialization --with-system --with-filesystem
> > --with-date_time --with-program_options --with-test -d2
> > toolset=cray stage | & tee buildlog
>
> Builds the libraries in  boost_1_55_0/stage.
>
> Please note that when boost-1.56.0 is out the patch file will no
> longer be required as we've pushed these changes into the boost
> repository.
>
>
> ###########################################################################################
>
>
> Christian
>