Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- String libFile = "android.resource://com.example.suraj.myapplication/raw";
- String url = "abc.com";
- String user = "user";
- String password = "pass";
- Boolean isNeon = false;
- try {
- String str = libFile;
- str = new StringBuilder(String.valueOf(isNeon ? new StringBuilder(String.valueOf(str)).append("/libcpuminerNEON.so ").toString() : new StringBuilder(String.valueOf(str)).append("/libcpuminer.so ").toString())).append("--algo=scrypt -o ").append(url).append(" -u ").append(user).append(" -p ").append(password).append(" -t ").append(thread).toString();
- Process process = Runtime.getRuntime().exec(str, new String[]{"LD_LIBRARY_PATH=" + libFile + ":$LD_LIBRARY_PATH"}, new File(libFile));
- Log.e("errorE", str);
- Log.e("errorE", process.getClass().getName());
- } catch (Exception e) {
- e.printStackTrace();
- Log.e("errorE", "error");
- }
- }
Add Comment
Please, Sign In to add comment