From INSTALL.txt, I wonder whether the following is relevant. I seem to
remember some issue with Boost and lock. What Linux are you using?
The Boost C++ libraries version 1.31 and higher (1.33.1 reccomended)
(www.boost.org). Note that 1.31 is required if you are using Python
2.3 or higher, and is recommended in any case due to getting much
better error messages. 1.32.0 or higher is required if you want to use
GNU G++ 3.4.0 or higher to build the suite.
You need libboost-python-dev, libboost-signals-dev, and libboost-thread-dev.
*** It is an unfortunate fact of life that the Boost libraries that
*** deal with Python have names that do not reflect what version of
*** Python they were built for and with. You have to be careful to
*** install Boost Python libraries that were built for your version of
Python.
You also need the threadpool resource: sourceforge.net/projects/threadpool.
If you are using the 1_35_0 Boost libraries, you can use version 0.2.4
which is included in the package (in dependencies). If you use a
different version of the Boost libraries, you need to get an appropriate
threadpool version and replace the files in
"dependencies/threadpool/include". Copy into the include directory the
contents of the boost directory in the threadpool package, which
includes a directory named "include" and a file "threadpool.hpp".
Bruce Sherwood
Helmut Jarausch wrote:
> Hi,
>
> I'm trying to compile vpython (CVS from today) but my gcc-4.3.3 bails
> out :
> ../include/platlinux.h:27: error: declaration of 'typedef class visual::lock<visual::mutex> visual::mutex::lock'
> ../include/vthread.h:13: error: changes meaning of 'lock' from 'class visual::lock<visual::mutex>'
>
> It doesn't seem possible to redefine 'lock'
>
> Here a simple test case
> #include <pthread.h>
>
> template <class syncObject>
> class lock
> {
> private:
> syncObject& obj;
>
> public:
>
> lock(syncObject& _obj) : obj(_obj) { _obj.sync_lock(); }
>
> ~lock() { obj.sync_unlock(); }
>
> private: // not implemented by design, to be noncopyable
> lock(const lock&);
> void operator=(const lock&);
> };
>
> class mutex
> {
> int count;
> pthread_mutex_t mtx;
>
> public:
> typedef lock<mutex> lock;
>
> };
>
>
> Has anybody solved that problem (perhaps by changing one of the
> definitions of 'lock' to 'Lock' ) ?
>
> Many thanks for a hint,
> Helmut.
>
|