]> git.pld-linux.org Git - packages/mongodb.git/blob - boost-1.50.patch
FILESYSTEM V3 fix
[packages/mongodb.git] / boost-1.50.patch
1 --- mongodb-src-r2.0.6/pch.h~   2012-06-04 15:42:54.000000000 +0200
2 +++ mongodb-src-r2.0.6/pch.h    2012-07-11 14:32:55.482057987 +0200
3 @@ -79,7 +79,7 @@
4  //#include <boost/any.hpp>
5  #include "boost/thread/once.hpp"
6  //#include <boost/archive/iterators/transform_width.hpp>
7 -#define BOOST_FILESYSTEM_VERSION 2
8 +#define BOOST_FILESYSTEM_VERSION 3
9  #include <boost/filesystem/convenience.hpp>
10  #include <boost/filesystem/exception.hpp>
11  #include <boost/filesystem/operations.hpp>
12 Binary files mongodb-src-r2.0.6.orig/lib/libboost_thread-gcc41-mt-d-1_34_1.a and mongodb-src-r2.0.6/lib/libboost_thread-gcc41-mt-d-1_34_1.a differ
13 diff -ur mongodb-src-r2.0.6.orig/util/background.cpp mongodb-src-r2.0.6/util/background.cpp
14 --- mongodb-src-r2.0.6.orig/util/background.cpp 2012-06-04 15:42:54.000000000 +0200
15 +++ mongodb-src-r2.0.6/util/background.cpp      2012-07-11 14:35:09.392053263 +0200
16 @@ -89,7 +89,7 @@
17              if ( msTimeOut ) {
18                  // add msTimeOut millisecond to current time
19                  boost::xtime xt;
20 -                boost::xtime_get( &xt, boost::TIME_UTC );
21 +                boost::xtime_get( &xt, boost::TIME_UTC_ );
22  
23                  unsigned long long ns = msTimeOut * 1000000ULL; // milli to nano
24                  if ( xt.nsec + ns < 1000000000 ) {
25 diff -ur mongodb-src-r2.0.6.orig/util/concurrency/mutex.h mongodb-src-r2.0.6/util/concurrency/mutex.h
26 --- mongodb-src-r2.0.6.orig/util/concurrency/mutex.h    2012-06-04 15:42:54.000000000 +0200
27 +++ mongodb-src-r2.0.6/util/concurrency/mutex.h 2012-07-11 14:35:09.392053263 +0200
28 @@ -29,7 +29,7 @@
29  
30      inline boost::xtime incxtimemillis( long long s ) {
31          boost::xtime xt;
32 -        boost::xtime_get(&xt, boost::TIME_UTC);
33 +        boost::xtime_get(&xt, boost::TIME_UTC_);
34          xt.sec += (int)( s / 1000 );
35          xt.nsec += (int)(( s % 1000 ) * 1000000);
36          if ( xt.nsec >= 1000000000 ) {
37 diff -ur mongodb-src-r2.0.6.orig/util/queue.h mongodb-src-r2.0.6/util/queue.h
38 --- mongodb-src-r2.0.6.orig/util/queue.h        2012-06-04 15:42:54.000000000 +0200
39 +++ mongodb-src-r2.0.6/util/queue.h     2012-07-11 14:35:09.392053263 +0200
40 @@ -82,7 +82,7 @@
41              Timer timer;
42  
43              boost::xtime xt;
44 -            boost::xtime_get(&xt, boost::TIME_UTC);
45 +            boost::xtime_get(&xt, boost::TIME_UTC_);
46              xt.sec += maxSecondsToWait;
47  
48              scoped_lock l( _lock );
49 diff -ur mongodb-src-r2.0.6.orig/util/time_support.h mongodb-src-r2.0.6/util/time_support.h
50 --- mongodb-src-r2.0.6.orig/util/time_support.h 2012-06-04 15:42:54.000000000 +0200
51 +++ mongodb-src-r2.0.6/util/time_support.h      2012-07-11 14:35:09.392053263 +0200
52 @@ -106,7 +106,7 @@
53          if ( s <= 0 )
54              return;
55          boost::xtime xt;
56 -        boost::xtime_get(&xt, boost::TIME_UTC);
57 +        boost::xtime_get(&xt, boost::TIME_UTC_);
58          xt.sec += (int)( s / 1000000 );
59          xt.nsec += (int)(( s % 1000000 ) * 1000);
60          if ( xt.nsec >= 1000000000 ) {
61 @@ -118,13 +118,13 @@
62  #elif defined(__sunos__)
63      inline void sleepsecs(int s) {
64          boost::xtime xt;
65 -        boost::xtime_get(&xt, boost::TIME_UTC);
66 +        boost::xtime_get(&xt, boost::TIME_UTC_);
67          xt.sec += s;
68          boost::thread::sleep(xt);
69      }
70      inline void sleepmillis(long long s) {
71          boost::xtime xt;
72 -        boost::xtime_get(&xt, boost::TIME_UTC);
73 +        boost::xtime_get(&xt, boost::TIME_UTC_);
74          xt.sec += (int)( s / 1000 );
75          xt.nsec += (int)(( s % 1000 ) * 1000000);
76          if ( xt.nsec >= 1000000000 ) {
77 @@ -137,7 +137,7 @@
78          if ( s <= 0 )
79              return;
80          boost::xtime xt;
81 -        boost::xtime_get(&xt, boost::TIME_UTC);
82 +        boost::xtime_get(&xt, boost::TIME_UTC_);
83          xt.sec += (int)( s / 1000000 );
84          xt.nsec += (int)(( s % 1000000 ) * 1000);
85          if ( xt.nsec >= 1000000000 ) {
86 @@ -202,24 +202,24 @@
87  #ifdef _WIN32 // no gettimeofday on windows
88      inline unsigned long long curTimeMillis64() {
89          boost::xtime xt;
90 -        boost::xtime_get(&xt, boost::TIME_UTC);
91 +        boost::xtime_get(&xt, boost::TIME_UTC_);
92          return ((unsigned long long)xt.sec) * 1000 + xt.nsec / 1000000;
93      }
94      inline Date_t jsTime() {
95          boost::xtime xt;
96 -        boost::xtime_get(&xt, boost::TIME_UTC);
97 +        boost::xtime_get(&xt, boost::TIME_UTC_);
98          unsigned long long t = xt.nsec / 1000000;
99          return ((unsigned long long) xt.sec * 1000) + t + getJSTimeVirtualSkew() + getJSTimeVirtualThreadSkew();
100      }
101      inline unsigned long long curTimeMicros64() {
102          boost::xtime xt;
103 -        boost::xtime_get(&xt, boost::TIME_UTC);
104 +        boost::xtime_get(&xt, boost::TIME_UTC_);
105          unsigned long long t = xt.nsec / 1000;
106          return (((unsigned long long) xt.sec) * 1000000) + t;
107      }    
108      inline unsigned curTimeMicros() {
109          boost::xtime xt;
110 -        boost::xtime_get(&xt, boost::TIME_UTC);
111 +        boost::xtime_get(&xt, boost::TIME_UTC_);
112          unsigned t = xt.nsec / 1000;
113          unsigned secs = xt.sec % 1024;
114          return secs*1000000 + t;
115 diff -ur mongodb-src-r2.0.6.orig/db/db.cpp mongodb-src-r2.0.6/db/db.cpp
116 --- mongodb-src-r2.0.6.orig/db/db.cpp   2012-06-04 15:42:54.000000000 +0200
117 +++ mongodb-src-r2.0.6/db/db.cpp        2012-07-11 14:39:15.945377899 +0200
118 @@ -976,7 +976,7 @@
119          if (params.count("shutdown")){
120              bool failed = false;
121  
122 -            string name = ( boost::filesystem::path( dbpath ) / "mongod.lock" ).native_file_string();
123 +            string name = ( boost::filesystem::path( dbpath ) / "mongod.lock" ).native();
124              if ( !boost::filesystem::exists( name ) || boost::filesystem::file_size( name ) == 0 )
125                  failed = true;
126  
127 diff -ur mongodb-src-r2.0.6.orig/db/dur.cpp mongodb-src-r2.0.6/db/dur.cpp
128 --- mongodb-src-r2.0.6.orig/db/dur.cpp  2012-06-04 15:42:54.000000000 +0200
129 +++ mongodb-src-r2.0.6/db/dur.cpp       2012-07-11 14:38:50.248712139 +0200
130 @@ -692,7 +692,7 @@
131  
132              bool samePartition = true;
133              try {
134 -                const string dbpathDir = boost::filesystem::path(dbpath).native_directory_string();
135 +                const string dbpathDir = boost::filesystem::path(dbpath).native();
136                  samePartition = onSamePartition(getJournalDir().string(), dbpathDir);
137              }
138              catch(...) {
139 diff -ur mongodb-src-r2.0.6.orig/db/instance.cpp mongodb-src-r2.0.6/db/instance.cpp
140 --- mongodb-src-r2.0.6.orig/db/instance.cpp     2012-06-04 15:42:54.000000000 +0200
141 +++ mongodb-src-r2.0.6/db/instance.cpp  2012-07-11 14:39:15.948711232 +0200
142 @@ -893,7 +893,7 @@
143      }
144  
145      void acquirePathLock(bool doingRepair) {
146 -        string name = ( boost::filesystem::path( dbpath ) / "mongod.lock" ).native_file_string();
147 +        string name = ( boost::filesystem::path( dbpath ) / "mongod.lock" ).native();
148  
149          bool oldFile = false;
150  
151 diff -ur mongodb-src-r2.0.6.orig/db/pdfile.cpp mongodb-src-r2.0.6/db/pdfile.cpp
152 --- mongodb-src-r2.0.6.orig/db/pdfile.cpp       2012-06-04 15:42:54.000000000 +0200
153 +++ mongodb-src-r2.0.6/db/pdfile.cpp    2012-07-11 14:38:50.252045472 +0200
154 @@ -2093,7 +2093,7 @@
155              uniqueReservedPath( ( preserveClonedFilesOnFailure || backupOriginalFiles ) ?
156                                  "backup" : "$tmp" );
157          BOOST_CHECK_EXCEPTION( boost::filesystem::create_directory( reservedPath ) );
158 -        string reservedPathString = reservedPath.native_directory_string();
159 +        string reservedPathString = reservedPath.native();
160  
161          bool res;
162          {
163 diff -ur mongodb-src-r2.0.6.orig/dbtests/framework.cpp mongodb-src-r2.0.6/dbtests/framework.cpp
164 --- mongodb-src-r2.0.6.orig/dbtests/framework.cpp       2012-06-04 15:42:54.000000000 +0200
165 +++ mongodb-src-r2.0.6/dbtests/framework.cpp    2012-07-11 14:38:50.252045472 +0200
166 @@ -281,7 +281,7 @@
167                  boost::filesystem::create_directory(p);
168              }
169  
170 -            string dbpathString = p.native_directory_string();
171 +            string dbpathString = p.native();
172              dbpath = dbpathString.c_str();
173  
174              cmdLine.prealloc = false;
175 diff -ur mongodb-src-r2.0.6.orig/shell/shell_utils.cpp mongodb-src-r2.0.6/shell/shell_utils.cpp
176 --- mongodb-src-r2.0.6.orig/shell/shell_utils.cpp       2012-06-04 15:42:54.000000000 +0200
177 +++ mongodb-src-r2.0.6/shell/shell_utils.cpp    2012-07-11 14:39:15.948711232 +0200
178 @@ -388,7 +388,7 @@
179  #endif
180                  }
181  
182 -                argv_.push_back( programPath.native_file_string() );
183 +                argv_.push_back( programPath.native() );
184  
185                  port_ = -1;
186  
This page took 0.040297 seconds and 4 git commands to generate.