commit-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Commit-gnuradio] [gnuradio] 08/12: android: runtime: need to use a usab


From: git
Subject: [Commit-gnuradio] [gnuradio] 08/12: android: runtime: need to use a usable, writable location for android apps, so use the tmp path that we set up to point to the app's home directory.
Date: Fri, 19 Feb 2016 13:58:39 +0000 (UTC)

This is an automated email from the git hooks/post-receive script.

trondeau pushed a commit to branch android
in repository gnuradio.

commit b5ac4c385e727b90e1d045e6201c78b5297fb460
Author: Tom Rondeau <address@hidden>
Date:   Sun Jan 18 11:24:33 2015 -0500

    android: runtime: need to use a usable, writable location for android
    apps, so use the tmp path that we set up to point to the app's home
    directory.
---
 gnuradio-runtime/lib/prefs.cc | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/gnuradio-runtime/lib/prefs.cc b/gnuradio-runtime/lib/prefs.cc
index b303ffd..932eb0b 100644
--- a/gnuradio-runtime/lib/prefs.cc
+++ b/gnuradio-runtime/lib/prefs.cc
@@ -62,7 +62,13 @@ namespace gr {
   {
     std::vector<std::string> fnames;
 
+#if ANDROID
+    //FIXME: provide function to determine where this should go
+    fs::path dir = fs::path("/sdcard");
+#else
     fs::path dir = prefsdir();
+#endif
+
     if(!fs::is_directory(dir))
       return fnames;
 
@@ -77,7 +83,13 @@ namespace gr {
     // Find if there is a ~/.gnuradio/config.conf file and add this to
     // the end of the file list to override any preferences in the
     // installed path config files.
+#if ANDROID
+    //FIXME: provide function to determine where this should go
+    fs::path homedir = fs::path("/sdcard");
+#else
     fs::path homedir = fs::path(gr::appdata_path());
+#endif
+
     homedir = homedir/".gnuradio/config.conf";
     if(fs::exists(homedir)) {
       fnames.push_back(homedir.string());



reply via email to

[Prev in Thread] Current Thread [Next in Thread]