]> git.pld-linux.org Git - packages/Collage.git/blob - Collage-boost.patch
boost rebuild
[packages/Collage.git] / Collage-boost.patch
1 --- Collage-1.7.0/co/dataIStreamArchive.ipp.orig        2020-08-01 08:04:33.045186314 +0200
2 +++ Collage-1.7.0/co/dataIStreamArchive.ipp     2020-08-01 08:42:36.396149673 +0200
3 @@ -17,6 +17,7 @@
4  
5  #include "dataIStream.h"
6  #include "dataStreamArchiveException.h"
7 +#include <boost/endian/conversion.hpp>
8  
9  namespace co
10  {
11 @@ -39,12 +40,6 @@
12  typename boost::enable_if<boost::is_integral<T> >::type
13      DataIStreamArchive::load(T& t)
14  {
15 -#if BOOST_VERSION < 104800
16 -    namespace bs = boost::detail;
17 -#else
18 -    namespace bs = boost::spirit::detail;
19 -#endif
20 -
21      // get the number of bytes in the stream
22      if (signed char size = _loadSignedChar())
23      {
24 @@ -62,7 +57,7 @@
25  
26          // load the value from little endian - is is then converted
27          // to the target type T and fits it because size <= sizeof(T)
28 -        t = bs::load_little_endian<T, sizeof(T)>(&temp);
29 +        t = boost::endian::endian_load<T, sizeof(T), boost::endian::order::little>(reinterpret_cast<const unsigned char*>(&temp));
30      }
31      else
32          // zero optimization
33 --- Collage-1.7.0/co/dataOStreamArchive.h.orig  2020-08-01 08:04:33.045186314 +0200
34 +++ Collage-1.7.0/co/dataOStreamArchive.h       2020-08-01 09:13:51.802656391 +0200
35 @@ -43,7 +43,7 @@
36  #include <boost/serialization/item_version_type.hpp>
37  #endif
38  
39 -#include <boost/spirit/home/support/detail/endian.hpp>
40 +#include <boost/endian/conversion.hpp>
41  #include <boost/math/special_functions/fpclassify.hpp>
42  
43  #include <boost/type_traits/is_floating_point.hpp>
44 --- Collage-1.7.0/co/dataOStreamArchive.ipp.orig        2020-08-01 08:04:33.045186314 +0200
45 +++ Collage-1.7.0/co/dataOStreamArchive.ipp     2020-08-01 09:13:54.569308070 +0200
46 @@ -15,6 +15,7 @@
47   * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
48   */
49  
50 +
51  template <typename T>
52  void DataOStreamArchive::save_array(const boost::serialization::array_wrapper<T>& a,
53                                      unsigned int)
54 @@ -34,11 +35,6 @@
55  typename boost::enable_if<boost::is_integral<T> >::type
56      DataOStreamArchive::save(const T& t)
57  {
58 -#if BOOST_VERSION < 104800
59 -    namespace bs = boost::detail;
60 -#else
61 -    namespace bs = boost::spirit::detail;
62 -#endif
63  
64      if (T temp = t)
65      {
66 @@ -60,7 +56,7 @@
67  
68          // we choose to use little endian because this way we just
69          // save the first size bytes to the stream and skip the rest
70 -        bs::store_little_endian<T, sizeof(T)>(&temp, t);
71 +        boost::endian::endian_store<T, sizeof(T), boost::endian::order::little>(reinterpret_cast<unsigned char*>(&temp), t);
72          save_binary(&temp, size);
73      }
74      else
This page took 0.206719 seconds and 3 git commands to generate.