Fix android build using hardcoded path for data instead of using the one fetched...
authorsapier <Sapier at GMX dot net>
Wed, 1 Oct 2014 20:18:29 +0000 (22:18 +0200)
committersapier <Sapier at GMX dot net>
Wed, 1 Oct 2014 20:18:29 +0000 (22:18 +0200)
Fix android missing version information

src/config.h
src/porting.cpp

index 510c5ef1e3a93394dec5e90bcaff0acccb933b94..f1aef03aa56756adc871792b4a1ddebfdad10082 100644 (file)
        #define VERSION_EXTRA_STRING CMAKE_VERSION_EXTRA_STRING
 #endif
 
+#ifdef __ANDROID__
+       #include "android_version.h"
+       #define VERSION_STRING CMAKE_VERSION_STRING
+#endif
+
 #endif
 
index ad942b0bc32c5ba75da9d797fb8b2ad92e3a9cde..2fc5d036476e9304697924b2386bf239f57c4dcf 100644 (file)
@@ -480,7 +480,7 @@ void initializePaths()
                        bindir + DIR_DELIM + ".." + DIR_DELIM + "share" + DIR_DELIM + PROJECT_NAME);
        trylist.push_back(bindir + DIR_DELIM + "..");
 #ifdef __ANDROID__
-       trylist.push_back(DIR_DELIM "sdcard" DIR_DELIM PROJECT_NAME);
+       trylist.push_back(path_user);
 #endif
 
        for(std::list<std::string>::const_iterator i = trylist.begin();
@@ -502,8 +502,6 @@ void initializePaths()
        }
 #ifndef __ANDROID__
        path_user = std::string(getenv("HOME")) + DIR_DELIM + "." + PROJECT_NAME;
-#else
-       path_user = std::string(DIR_DELIM "sdcard" DIR_DELIM PROJECT_NAME DIR_DELIM);
 #endif
 
        /*