I'm trying my hand at C++, I've got Eclipse on my Arch machine. I'm trying to get an example at Boost.Org working:
#include <iostream>
#include <boost/asio.hpp>
#include <boost/date_time/posix_time/posix_time.hpp>
int main()
{
boost::asio::io_context io;
boost::asio::deadline_timer t(io, boost::posix_time::seconds(5));
t.wait();
std::cout << "Hello, world!" << std::endl;
return 0;
}
I've downloaded the library tar and extracted it to /usr/local/include as this appeared the most obvious from the default include folders, but I still got the following error: Unresolved inclusion: <boost/asio.hpp>
Any suggestions?
UPDATE: Just needed to give Eclipse time to acknowledge the library being moved to /usr/local/include (a default include folder).
You should just run
pacman -S boost
this will install boost in the system include path that GCC always uses.