boost::filesystem::remove_all compile error

Nov 5, 2016 at 10:20am
So I am trying to delete a folder and all subdirectories, files, etc. I'm using boost/filesystem.hpp for this.

But when I try to do boost::filesystem::remove_all(path); I get a really long compile error.

I did
1
2
boost::filesystem::remove_all
("/storage/emulated/0/Text Editor");
which didn't work. I'm sure the path is correct and the foler exists (has stuff inside).
Last edited on Nov 5, 2016 at 10:21am
Nov 5, 2016 at 10:22am
What are the compiler errors?
Nov 5, 2016 at 12:09pm
@SakurasouBusters

Here: https://goo.gl/p8ZmWB
Nov 5, 2016 at 5:55pm
There are linker errors.

Link with the libraries libboost_filesystem and libboost_system

Nov 6, 2016 at 4:36am
@JLBorges

I don't know how to link them. I have filesystem.hpp but not system.hpp. Only a folder in boost called system with header files like api_config.hpp, config.hpp, etc.

Is linking just "including" more header files?
Last edited on Nov 6, 2016 at 4:37am
Nov 6, 2016 at 5:07am
> I don't know how to link them.

Specifying libraries to link with depends on the tool-chain that is being used.

Have the boost libraries been built? What are you using to build your own code?
Nov 6, 2016 at 6:18am
@JLBorges

I'm using C4droid. I just have have the boost folder with the libraries (.hpp) in them.
Nov 6, 2016 at 8:06am
I'm using C4droid. I just have have the boost folder with the libraries (.hpp) in them.

Didn't you say you are using Code-Blocks?
Nov 6, 2016 at 1:05pm
I do not know anything about this C4droid tool-chain, let alone how to build the boost libraries with it.

From what I've heard, CrystaX SDK has reasonably good support for using the non-header-only boost libraries on android. https://www.crystax.net/en/android/ndk#afeature7
Topic archived. No new replies allowed.