summaryrefslogtreecommitdiff
path: root/src/porting.h
diff options
context:
space:
mode:
authorShadowNinja <shadowninja@minetest.net>2015-08-24 17:00:06 -0400
committerShadowNinja <shadowninja@minetest.net>2015-12-07 13:51:41 -0500
commitea2964f5a168cb52d1b9f74a08f00c7c068c6649 (patch)
tree77785296ca680eced53d3c3e976a5dc948d5df30 /src/porting.h
parent51e8c2b27786c050f0271eeeaed5eea17d62f0a0 (diff)
downloadminetest-ea2964f5a168cb52d1b9f74a08f00c7c068c6649.tar.gz
minetest-ea2964f5a168cb52d1b9f74a08f00c7c068c6649.tar.bz2
minetest-ea2964f5a168cb52d1b9f74a08f00c7c068c6649.zip
Add seperate cache path
This is set to the XDG cache path where possible. It's set to the app's cache path on Android.
Diffstat (limited to 'src/porting.h')
-rw-r--r--src/porting.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/porting.h b/src/porting.h
index 1e89cd044..5da32607c 100644
--- a/src/porting.h
+++ b/src/porting.h
@@ -148,12 +148,23 @@ extern std::string path_user;
extern std::string path_locale;
/*
+ Path to directory for storing caches.
+*/
+extern std::string path_cache;
+
+/*
Get full path of stuff in data directory.
Example: "stone.png" -> "../data/stone.png"
*/
std::string getDataPath(const char *subpath);
/*
+ Move cache folder from path_user to the
+ system cache location if possible.
+*/
+void migrateCachePath();
+
+/*
Initialize path_*.
*/
void initializePaths();