Trying to build Maidsafe

I am basically getting the files from GitHub
git clone
git -C MaidSafe submodule update --init

and then per instructions doing the cmake and then the make.

But I have some errors. I may not have the proper boost library but there are no instructions on that.
Also when doing the cmake, it did not find all dependencies for qt5.

Here is one of the errors:

/root/MaidSafe/src/crux/include/maidsafe/crux/socket.hpp:430:62:   required from ‘typename boost::asio::async_result<typename boost::asio::handler_type<ConnectHandler, void(boost::system::error_code)>::type>::type maidsafe::crux::socket::async_connect(const string&, const string&, CompletionToken&&) [with CompletionToken = const boost::asio::use_future_t<>&; typename boost::asio::async_result<typename boost::asio::handler_type<ConnectHandler, void(boost::system::error_code)>::type>::type = std::future<void>; std::__cxx11::string = std::__cxx11::basic_string<char>]’
/root/MaidSafe/src/crux/example/future/echo_client.cpp:28:79:   required from here
/usr/include/c++/5/bits/alloc_traits.h:530:4: error: ‘using allocator_type = class std::allocator<void> {aka class std::allocator<void>}’ has no member named ‘construct’
  { __a.construct(__p, std::forward<_Args>(__args)...); }
1 Like

Ah - we moved our codebase over to Rust a while back! GitHub’s redirection to our archived repositories can be a nuisance. The old C++ code is all now under maidsafe-archive to try and give a hint that this code is obsolete. If you navigate to in your browser, it takes you to

We don’t have a Git superproject structure any more, but you can see all our repos at For example, here’s the vault code.

I’ve kept a personal superproject of all our backend repos in case that’s where your interest lies. I’ve found the superproject is an easy way to get all the code onto a new machine (and I used to do that frequently enough to make it worthwhile) and to update all repos locally - but it’s not required for building any or all of our repos like it was with the old C++ codebase.

I hope you didn’t spend too long on the C++ code!


Thanks, now trying to build that

I get
info: component ‘rust-std’ for target ‘i686-unknown-linux-gnu’ is up to date
fatal: destination path ‘MaidSafe-Rust’ already exists and is not an empty directory.
error: could not find Cargo.toml in /root/MaidSafe-Rust or any parent directory

source $HOME/.cargo/env

rustup target add i686-unknown-linux-gnu
git clone
cd MaidSafe-Rust
cargo build --release --target i686-unknown-linux-gnu

Cross-Compiling for 32-bit Linux

I think I have a misunderstanding.

It seems all builds are to take place on windows and to be cross compiled.
I use 64bit ubuntu and I suppose that will not work.

I found out when I tried to build the vault.

How can I easily build on Linux?

Those cross-compiling instructions were really just notes to remind me how I set up various environments. It should be pretty straightforward to build the vault code on Linux:

git clone
cd safe_vault
cargo build --release

To run the tests:

cargo test --release

For actually running a vault, see this thread. There are some options which need tweaked via config files.


This topic was automatically closed after 60 days. New replies are no longer allowed.