diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2012-03-29 13:57:35 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2012-03-29 14:04:17 +0200 |
commit | 8431ad2d8b64400052b8e6e218117dd9fb72f316 (patch) | |
tree | fcad1822deddc62078e58890caa55cb299d060d1 /boost | |
parent | 21ca0847952be3eabc7c11200a2b70e0801a8fc6 (diff) |
Backport some Boost 1.48.0 changes to keep GCC 4.7 -std=c++11 happy
Diffstat (limited to 'boost')
-rw-r--r-- | boost/boost_1_44_0-gcc4.7.patch | 49 | ||||
-rw-r--r-- | boost/makefile.mk | 3 |
2 files changed, 52 insertions, 0 deletions
diff --git a/boost/boost_1_44_0-gcc4.7.patch b/boost/boost_1_44_0-gcc4.7.patch new file mode 100644 index 000000000000..842a92a681d6 --- /dev/null +++ b/boost/boost_1_44_0-gcc4.7.patch | |||
@@ -0,0 +1,49 @@ | |||
1 | --- misc/boost_1_44_0/boost/smart_ptr/shared_ptr.hpp 2009-12-14 18:44:19.000000000 +0100 | ||
2 | +++ misc/build/boost_1_44_0/boost/smart_ptr/shared_ptr.hpp 2012-03-28 08:32:46.772493003 +0200 | ||
3 | @@ -207,7 +207,17 @@ | ||
4 | boost::detail::sp_enable_shared_from_this( this, p, p ); | ||
5 | } | ||
6 | |||
7 | -// generated copy constructor, destructor are fine | ||
8 | +// generated copy constructor, destructor are fine... | ||
9 | + | ||
10 | +#if defined( BOOST_HAS_RVALUE_REFS ) | ||
11 | + | ||
12 | +// ... except in C++0x, move disables the implicit copy | ||
13 | + | ||
14 | + shared_ptr( shared_ptr const & r ): px( r.px ), pn( r.pn ) // never throws | ||
15 | + { | ||
16 | + } | ||
17 | + | ||
18 | +#endif | ||
19 | |||
20 | template<class Y> | ||
21 | explicit shared_ptr(weak_ptr<Y> const & r): pn(r.pn) // may throw | ||
22 | --- misc/boost_1_44_0/boost/smart_ptr/weak_ptr.hpp 2009-12-14 18:44:19.000000000 +0100 | ||
23 | +++ misc/build/boost_1_44_0/boost/smart_ptr/weak_ptr.hpp 2012-03-28 10:31:57.607462325 +0200 | ||
24 | @@ -40,8 +40,24 @@ | ||
25 | { | ||
26 | } | ||
27 | |||
28 | -// generated copy constructor, assignment, destructor are fine | ||
29 | +// generated copy constructor, assignment, destructor are fine... | ||
30 | |||
31 | +#if defined( BOOST_HAS_RVALUE_REFS ) | ||
32 | + | ||
33 | +// ... except in C++0x, move disables the implicit copy | ||
34 | + | ||
35 | + weak_ptr( weak_ptr const & r ): px( r.px ), pn( r.pn ) // never throws | ||
36 | + { | ||
37 | + } | ||
38 | + | ||
39 | + weak_ptr & operator=( weak_ptr const & r ) // never throws | ||
40 | + { | ||
41 | + px = r.px; | ||
42 | + pn = r.pn; | ||
43 | + return *this; | ||
44 | + } | ||
45 | + | ||
46 | +#endif | ||
47 | |||
48 | // | ||
49 | // The "obvious" converting constructor implementation: | ||
diff --git a/boost/makefile.mk b/boost/makefile.mk index 093566bb579c..cab945fc5a17 100644 --- a/boost/makefile.mk +++ b/boost/makefile.mk | |||
@@ -71,6 +71,9 @@ PATCH_FILES+=boost.windows.patch | |||
71 | PATCH_FILES += boost_1_44_0-unused-parameters.patch | 71 | PATCH_FILES += boost_1_44_0-unused-parameters.patch |
72 | .END | 72 | .END |
73 | 73 | ||
74 | # Backporting fixes for the GCC 4.7 -std=c++11 mode from Boost 1.48.0: | ||
75 | PATCH_FILES += boost_1_44_0-gcc4.7.patch | ||
76 | |||
74 | ADDITIONAL_FILES= \ | 77 | ADDITIONAL_FILES= \ |
75 | libs/thread/src/win32/makefile.mk \ | 78 | libs/thread/src/win32/makefile.mk \ |
76 | libs/date_time/src/gregorian/makefile.mk | 79 | libs/date_time/src/gregorian/makefile.mk |