udpate resource paths

This commit is contained in:
Nathan Freitas 2016-09-19 16:11:30 -04:00
parent bab79046b2
commit 1ffea580c4
1 changed files with 7 additions and 21 deletions

View File

@ -74,7 +74,6 @@ public class TorResourceInstaller implements TorServiceConstants {
installFolder.mkdirs();
is = context.getResources().openRawResource(R.raw.torrc);
outFile = new File(installFolder, TORRC_ASSET_KEY);
streamToFile(is,outFile, false, false);
@ -83,23 +82,10 @@ public class TorResourceInstaller implements TorServiceConstants {
outFile = new File(installFolder, POLIPOCONFIG_ASSET_KEY);
streamToFile(is,outFile, false, false);
//only install if ARM (GoLang only supports ARM for now)
if (cpuPath.equals("armeabi"))
{
cpuPath = "armeabi";
is = context.getAssets().open(cpuPath + "/" + OBFSCLIENT_ASSET_KEY + MP3_EXT);
outFile = new File(installFolder, OBFSCLIENT_ASSET_KEY);
streamToFile(is,outFile, false, true);
setExecutable(outFile);
/**
is = context.getAssets().open(cpuPath + "/" + MEEK_ASSET_KEY + MP3_EXT);
outFile = new File(installFolder, MEEK_ASSET_KEY);
shell.add(new SimpleCommand(COMMAND_RM_FORCE + outFile.getAbsolutePath())).waitForFinish();
streamToFile(is,outFile, false, true);
setExecutable(outFile);
*/
}
is = context.getAssets().open(cpuPath + '/' + OBFSCLIENT_ASSET_KEY + MP3_EXT);
outFile = new File(installFolder, OBFSCLIENT_ASSET_KEY);
streamToFile(is,outFile, false, true);
setExecutable(outFile);
is = context.getAssets().open(cpuPath + '/' + TOR_ASSET_KEY + MP3_EXT);
outFile = new File(installFolder, TOR_ASSET_KEY);