From 4a7935e1f8d1756cbeafb2564066551f9bd766f0 Mon Sep 17 00:00:00 2001 From: jjll Date: Wed, 6 Sep 2023 14:25:30 +0200 Subject: [PATCH] compatibility boost >= 1.83 --- src/lib/parallel_progress.h | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/src/lib/parallel_progress.h b/src/lib/parallel_progress.h index 958b170..ee938d9 100755 --- a/src/lib/parallel_progress.h +++ b/src/lib/parallel_progress.h @@ -23,7 +23,14 @@ #ifndef VINA_PARALLEL_PROGRESS_H #define VINA_PARALLEL_PROGRESS_H +#include +#if BOOST_VERSION < 107200 #include +typedef boost::progress_display boost_progress; +#else +#include +typedef boost::timer::progress_display boost_progress; +#endif #include #include @@ -34,7 +41,7 @@ struct parallel_progress : public incrementable { parallel_progress(std::function* c = NULL) : p(NULL), callback(c) {} void init(unsigned long n) { count = n; - p = new boost::progress_display(count); + p = new boost_progress(count); } void operator++() { if(p) { @@ -47,7 +54,7 @@ struct parallel_progress : public incrementable { virtual ~parallel_progress() { delete p; } private: boost::mutex self; - boost::progress_display* p; + boost_progress* p; std::function* callback; unsigned long count; };