discuss-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Discuss-gnuradio] Tests fail building with boost1.52


From: Johnathan Corgan
Subject: Re: [Discuss-gnuradio] Tests fail building with boost1.52
Date: Wed, 23 Jan 2013 09:40:22 -0800

On Wed, Jan 23, 2013 at 7:08 AM, Tom Rondeau <address@hidden> wrote:
 
Unfortunately, they have also deprecated Mutex::scoped_lock, so we're going to have to reevaluate our use of that.... (not a show-stopper by any means, just some changes we'll have to make).

It looks like we are using the gruel::scoped_lock typedef everywhere except in the gr_file_source and gr::file_source blocks where bare boost::mutex::scoped_lock is used.  I did a quick test of the below change to use the recommended type and at least all the QA unit tests pass:

--- a/gruel/src/include/gruel/thread.h
+++ b/gruel/src/include/gruel/thread.h
@@ -31,7 +31,7 @@ namespace gruel {
 
   typedef boost::thread                    thread;
   typedef boost::mutex                     mutex;
-  typedef boost::mutex::scoped_lock        scoped_lock;
+  typedef boost::unique_lock<boost::mutex> scoped_lock;
   typedef boost::condition_variable        condition_variable;
 
 } /* namespace gruel */

So when the time comes it should be easy to switch over (and fix the bare usage in the file source.)

Johnathan

reply via email to

[Prev in Thread] Current Thread [Next in Thread]