request for help: g++ compiler error in mapreduce library

Can someone please help me with a g++ compiler error with my MapReduce library test program? My primary development platform is MSVC 2005 on Windows. I have an Ubuntu box with g++ 4.3.3 which I am not particularly familiar with. Compiling the test program 'mrtest' in boost-sandbox/libs/mapreduce/test on g++, I get an error which I cannot resolve: mrtest.cpp:228: error: expected primary-expression before '>' token here's the piece of code (the full source is in https://svn.boost.org/svn/boost/sandbox/libs/mapreduce/test/mrtest.cpp): typename Job::datasource_type datasource(spec); Job job(datasource, spec); job.run<boost::mapreduce::schedule_policy::cpu_parallel<Job>
(result); // <-- ERROR
The code compiles and runs fine on Windows. Any ideas? Thanks -- Craig Craig Henderson <http://craighenderson.co.uk/> http://www.craighenderson.co.uk http://www.siteupdatenotification.com

On Sat, Aug 22, 2009 at 12:01 AM, Craig Henderson<cdm.henderson@googlemail.com> wrote:
Can someone please help me with a g++ compiler error with my MapReduce library test program? job.run<boost::mapreduce::schedule_policy::cpu_parallel<Job>
(result); // <-- ERROR
Just change the line to: job.template run<boost::mapreduce::schedule_policy::cpu_parallel<Job>
(result);
to allow the compiler to handle the dependent name BTW, the only error I get now is platform.hpp:98: undefined reference to `boost::mapreduce::linux_os::get_temporary_filename(std::basic_string<char, std::char_traits<char>, std::allocator<char> >&) which was available before. regards jose

Can someone please help me with a g++ compiler error with my MapReduce library test program? job.run<boost::mapreduce::schedule_policy::cpu_parallel<Job>
(result); // <-- ERROR
Just change the line to:
job.template run<boost::mapreduce::schedule_policy::cpu_parallel<Job>
(result);
to allow the compiler to handle the dependent name
Thanks - I've never come across that syntax before. MSVC doesn't need it, but can cope with it. I've updated the sandbox.
BTW, the only error I get now is
platform.hpp:98: undefined reference to `boost::mapreduce::linux_os::get_temporary_filename(std::basic_string<c har, std::char_traits<char>, std::allocator<char> >&)
which was available before.
I think you modified platform.hpp locally for this - you've sent me the code, but I haven't integrated it yet. I'll do that shortly. Thanks for your continued help -- Craig

BTW, the only error I get now is
platform.hpp:98: undefined reference to `boost::mapreduce::linux_os::get_temporary_filename(std::basic_string<c har, std::char_traits<char>, std::allocator<char> >&)
which was available before.
This is now in the sandbox. Regards -- Craig
participants (2)
-
Craig Henderson
-
Jose