yashsingh1/xdaforums huggingface dataset:
[Verizon HTC One (M8)] wtoj34:
Hello all, as a humongous fan of the n64 and practically any classic game and a huge fan of the m8, it concerns me how poorly it runs this particular emulator.

Super smash bros 64

-60fps 50% of the time <20fps the rest

Majora's mask

-Constant >20fps

ePSXe runs like a dream, so does Drastic. Has anyone had better luck than me?

*Clean ROM 1.1 default kernel little to no tweaks using sixaxis controller wirelessly and no power saving.
[Verizon HTC One (M8)] coldconfession13:
hmm I'm interested in this topic as well
[Verizon HTC One (M8)] richii0207:
Have you tried retroarch? Thing is the mother of all emulators, and it's free
[Verizon HTC One (M8)] wtoj34:
Thanks for the reply, that'll definitely come in later however it still uses the same mupen64 codecs and runs at a consistent 20 or so fps in ssb
[Verizon HTC One (M8)] wtoj34:
Can any user try this same emulator and report results? The emulator is free, and there is also a donate version in the play store. I'm curious if it's a kernel thing.

Emulator site and download >>>> http://www.paulscode.com/forum/index.php?topic=96.msg2243#msg2243
[Nexus 10 General] nigelhealy:
https://developers.google.com/android/nexus/images#mantarayktu84l
[Nexus 10 General] jhnl33:
does anyone know if it breaks root? if so, can we get root back in the same way?
[Nexus 10 General] nigelhealy:
wait. I'm doing install now....
[Nexus 10 General] styckx:
I'm just flashing the entire factory images. I never use my Nexus 10 anymore because the Wifi is a disaster... Worse that can happen is it actually works right now.. Which is highly doubtful.

---------- Post added at 07:37 PM ---------- Previous post was at 07:07 PM ----------

Still a broken POS... Installed, Play store restored all my stuff. Browsed around for a bit.. Sat it down... Went to the PC for 15 minutes.. Came back to Nexus 10.. First website I tried to open.. Yep.. No data throughput on two bars of wifi.. Same god damn crap that has plagued this stupid lemon of a tablet for ages.. Two bars of wifi strength and this stupid thing doesn't know what to do. Meanwhile my Nexus 4 performs flawlessly with 1 bar of wifi and never has data throughput issues since the day I bought it at launch.. Nexus 10 is such a massive flop...
[Nexus 10 General] nigelhealy:
I did a stock install at command line. There is a bug which isn't relevant it tries to flash a recovery img which isn't included but I checked and its the most current version anyway.

fastboot flash bootloader ./bootloader-manta-mantamf01.img
error: cannot load './bootloader-manta-mantamf01.img': No such file or directory

fastboot -w update image-mantaray-ktu84l.zip
archive does not contain 'boot.sig'
archive does not contain 'recovery.sig'
archive does not contain 'system.sig'
--------------------------------------------
Bootloader Version...: MANTAMF01
Baseband Version.....: no modem
Serial Number........: R32D104HJYB
--------------------------------------------

I then flashed CWM recovery, copied over supersu.zip, applied and then installed and used a root app (Stickmount) and it worked.

So.... far.... nothing broke.....

i did this first to my Nexus 10 as it has the simplest needs if I bricked it. Will do Nexus 7 then Nexus 5.
[Nexus 10 General] nigelhealy:
Sell it. it's an issue with your router. I had the issue til I put on DD-WRT on my router and set a fixed channel, then it worked fine. Not saying don't blame N10, it should behave better, just if you all you are going to do is complain you're of nil value help.
[Nexus 10 General] jhnl33:
I had the exact same issue with the horrible wifi. It has been working flawlessly ever since I got it until about a month ago. On a 70 mbps connection with the router 2 feet away, I couldn't even load the play store, let alone anything else. I tried all that "disable wifi optimization" stuff and other things and nothing worked. 2 weeks ago, I relocked my bootloader and reverted everything back to stock and it still didn't work. Just for fun, I unlocked the bootloader again, still running stock, and magically my wifi is back to ~60 mbps and everything works perfectly again. I have absolutely no idea how. Maybe you should try it because you already factory reset it, try locking and unlocking the bootloader and see what happens. Good luck :D

---------- Post added at 12:53 AM ---------- Previous post was at 12:51 AM ----------

Sweet thanks so much!!!
[Nexus 10 General] nigelhealy:
FYI if you just run the flash-all script it erases everything, I actually prefer that to begin with a clean slate, but I know you can run a subset of comamnds to limit what is erases. So the method I did by definition breaks root, but getting it back is easy, just install custom recovery and copy the root zip and install in recovery.

So far... i'm configuring all my apps, nothing seems broke but it will take a while to know if any of my functions are broken....
[Nexus 10 General] robrob777:
Works

Root works.

Unlock, Flashed the Factory image, then CWM.img and then flashed SuperSU zip and everything is good.

I had a CWM backup so I'm up and running in no time.

BTW I have never ever had problems with WIFI, I have a netgear router, but it also works with trendnet and Linksys.

btw Total RAM is 1124832KB

First quadrant 2.0 is 5501 with stock kernel
[Nexus 10 General] zensui:
I update thru OTA with superuser survival turned on. Confirmed it went perfectly fine on update with root still kept.
[Nexus 10 General] VivaErBetis:
Fisrt problem... can't install busybox in /system/xbin due to lack of space in system partition...
[Nexus 10 General] viccie:
I have TWRP installed on my Nexus 10. Can I simply boot into recovery and install the zip that's in the tarball? Or won't that work?
[Nexus 10 General] fifthelement:
No , it wont work. the file from google is in fact two .tar files inside each other. you need to decompress the first one , the second one has no extension ! add .tar extension to it and decompress it again. I used winrar to do it. you will get the batch file and rom zip file which requires fastboot to be installed. if you search on google you will find many guides on how to install factory images on nexus devices.

Edit : Well , I guess the google file is .tar.gz file and not two tar files inside eachother. but for an unknown reason when you download it the extension is .tar , I renamed it to .tar.gz and then decompressed it and it worked fine.

---------- Post added at 08:37 AM ---------- Previous post was at 08:36 AM ----------

I installed busybox with "BusyBox on Rails" app with no issues. it is working fine here.
[Nexus 10 General] kun_ken:
where is bootloader img?

I extracted factory image file.

but i can not find bootloader img file.

I checked 'flash-all.sh' .

There is written like this 'fastboot flash bootloader bootloader-manta-mantamf01.img'

There have to be 'bootloader-manta-mantamf01.img'.

without updating new bootloader img, does it work well?
[Nexus 10 General] VivaErBetis:
They forgot to include it in the factory image. But don't worry, it works well.
[Nexus 10 General] ravenofdoom:
No TWRP flashable update.zip for 4.4.3 yet? Can't seem to find any on the threads, though folks are talking of OTA (I only see the factory image .tar).
[Nexus 10 General] nigelhealy:
I just now installed it. Zero problems.

Of course i did what I always recommend of doign a full fresh flash and erase everything. It is always the safest best way. It took me about 30mins to install my apps and configure them.
[Nexus 10 General] nigelhealy:
The URL of the OTA zip isn't out yet.

http://xdaforums.com/showthread.php?t=1971165

http://xdaforums.com/showpost.php?p=53108544&postcount=291

Wait or do what I always do and just do a full fresh install, it cleans out any crap.

Funny, the last 4.4.2 we had the OTA zips out before the full image zips, the reverse timing schedule. We had to do a flash then OTA for about a week i think then.
[Nexus 10 General] nigelhealy:
They forgot it but its also not necessary, the 4.4.2 had that same file flashed already.
[Nexus 10 General] VivaErBetis:
Well, I finally installed the busybox applets using softlinks instead of copies. It may cause problems with some apps but it's the only way.

It's not a problem of fresh space but the system partition of the nexus 10 is really small compared to other nexus like 4 or 5.
[General Questions and Answers] mron71:
Hi, I searched but couldn't find. I want to unroot my phone but I didn't save any files on my PC when I rooted it....noob. Is there a guide or toolkit that can help me with this? This is for an HTC ONE X. Thanks.
[General Questions and Answers] pinkLeviosa:
Try these links:

http://xdaforums.com/showthread.php?t=1609190

http://theunlockr.com/2012/10/22/how-to-unroot-the-htc-one-x/

http://www.androidrootguide.com/2013/07/how-to-unroot-htc-one-x-smartphone.html
[Android Software/Hacking General [Developers Only]] 7175:
::Downloads:: (#7 or #8 is the static binary by itself)

(1) mksh R50 source, binary, manual

(2) Highly compressed pack of extra bins/libs that are mentioned in my mkshrc (zsh, lz4c, grep, busybox, bash, nano, vim, curl, etc) and some other cool ones like macchanger and ed. Download #3 to extract on Android.

(3) 7za in case you need it to extract (2) on Android.

7za x name_of_archive.7z

(4) Classic unix text editor "ed" which mksh uses for edit functionality. (Copy to /system/bin along with mksh.)

(5) Official mkshrc (unzip and copy to /system/etc, set permissions to 0444)

(6)

My personalized mkshrc startup mksh shell script based on the official full mkshrc 2014/01/11 release. Described in first post. If you try this, make sure to symlink /system/xbin/busybox to /system/bin/busybox.ndk.

Official mkshrc 2014/01/11 release

"diff -ur /system/etc/dot.mkshrc--official.mkshrc mkshrc" (diff patch set from official mkshrc to my personalized mkshrc)

(7) mksh static binary! (Just unzip, "chmod +rx" it, and copy to /system/bin or run from anywhere, no libs required :) )

(8) mksh R50e with printf builtin (I know some people were looking for this)
[Android Software/Hacking General [Developers Only]] E:V:A:
[MENTION=5109059]7175[/MENTION] : Hello! Look like a bunch of hard work there. Very nice.

1. Would you have any clue to what's going on HERE?

2. Would you know if I can just install over my old mksh binary to get this working, or do I need "everything"?

3. And since I've heard that /system/bin/mksh will soon be permanently only /system/bin/sh perhaps this need to be changed?
[Android Software/Hacking General [Developers Only]] 7175:
Hey E.VA. thanks for checking out the thread. If you want to just test out R48 mksh, just copy(from zip root directory) the lib*.so from /data/media/shell to /system/lib and then copy /data/media/shell/mksh to /system/bin (and chmod 0555 /system/bin/mksh; chmod 0444 /system/lib/*.so). Then you'll have your whole system running full mksh R48.

As far as the ssh problem with android, this definitely becomes grey-zone material to my knowledge, which is limited in this area. I'm pretty sure android has udev amputated so it lacks a fully working /dev/tty. This could probably be patched over though with some terminal work, mknod action. I've gotten ssh working under "terminal ide", but haven't used the stock ssh stuff in /system/bin. Now that you mention this though, I will try and get stock ssh going as well as openssh which had a similar problem last time I tried (thx for mentioning your support thread, I'll be checking that out).

Here's what I searched to shed a little light on that ssh /dev/tty issue: duckduckgo.com/html5/?q=ssh+%27dev%2Ftty%27+error.

It looks like you've done a ton of searching though.

For su commands, I would try using, e.g.,

su exec [i]command[/i]

...opposed to "su -c", or better e.g.,

su -c exec /system/bin/sh -c '[i]command[/i]'

...and see if that gives any different results.

I just know from experience "su -c" hasn't always cut it.

*edit: Couple other things worth trying:

1) preappend command with environment variable: global TTY=/dev/pts/0 ...

2) use the -T option when calling mksh, i,e. ssh ... -e mksh -T /dev/pts/0 ...
[Android Software/Hacking General [Developers Only]] E:V:A:
@7175 : Hey thanks for looking into this. I will definitely try your suggestions.

However, I've already tried the -T flag to ssh, but never by specifying the pts to use, as it should be dynamically allocated by the ptmx. (As it could be already in use, by something else, like ATE.) Also, what does "global" do?

You also mentioned "stock ssh" in /system/bin. I've never seen that. Perhaps that could be a better solution, unless its' even more crippled. Does it also support sshd (i.e. ssh -D)?

In the mean time, is there any particular reason why you decided to dynamically link mksh? (I assumed it would have been more portable with static linking?)

I see that you did a huge amount of work on that mkshrc script. Looks crazy (in a good way)!

Finally, and aside, I also noticed that when I start mksh from ssh session, there are some aliases in there, that is not specified in the mkshrc, nor the .profile of my SSH server, so where the heck do they come from?

[SIZE=2]u0_a202@MSM8960:home # alias
autoload='typeset -fu'
functions='typeset -f'
hash='alias -t'
history='fc -l'
integer='typeset -i'
local=typeset
login='exec login'
nameref='typeset -n'
nohup='nohup '
r='fc -e -'
source='PATH=$PATH:. command .'
type='whence -v'[/SIZE]

Perhaps they're hardcoded or sourced from somewhere? Have you seen this?
[Android Software/Hacking General [Developers Only]] 7175:
Thanks man lol it's a big rc. It was 50KB before I converted a bunch of the functions to fpath functions in /etc/fpath and stripped most of the comments. It should give a pretty quick shell in terminal though with the ulimit and renicing tweaks. The PS1 prompt is pretty awesome, probably the best thing in the mkshrc I included.

"global" is a function just like "typeset" or "declare" in bash. The difference is that global prevents an accessed variable from being localized/ different than the global value in a function. This is a mksh function, bash will use "declare -g". There are a couple of example usage in the mkshrc, like with the set -x spam fix for the command prompt.

I checked and stock ssh in /system/bin has the "-D" flag. I would also check rolo's zshaolin zsh project which comes with some afterstock ssh stuff, ssh keygen, ssh keysearch, different ssh etc.

Yeah I just symlinked sh to save space really and for portability to try out other shells like bash and zsh(this works!) to run the system. Recently I switched to using a copy of mksh as sh since "chattr +i" wasn't protecting the symlink from being over-linked.

The aliases you posted are in fact hard-coded. If you do "strings /system/bin/mksh | grep -C7 autoload" or something similar, you'll see them in the binary. I always wondered where those came from too until I read through the mksh manual over a couple months, that's some pretty dense reading lol. mksh is a superb shell though, so it's definitely well worth it.

Sorry I can't be of more help with the ssh /dev/tty problem. I will keep my eyes open though, and try not to be so lazy using telnet for all my remote connections. I mean that's basically using the internet without a condom lol.

(*Also, just something I should mention about the install zip contents: not all the /etc/fpath functions are finished yet. I still gotta tweak the ssh ports from /etc/ssh and finish my xargs. Most should work though and are safe and won't interfer with shell usage, even if autoloaded.)
[Android Software/Hacking General [Developers Only]] E:V:A:
@mirabilos :

Hi, why did you choose to hardcode the aliases (shown in post#6) into the mksh binary?

Also, do you have a later version than the R48 Android binary above?

The "r" alias is particularly disturbing as it is masking the native toolbox use of "r" to read a memory location.
[Android Software/Hacking General [Developers Only]] E:V:A:
Why do they need to be tweaked?

Sorry my bad, I was sleepy and mistakenly understood "-D" as running SSH in daemon mode, when in fact it does the opposite and prevents it. Seem like his links are dead or I'm just looking in the wrong place.

Not sure what you're saying here...

Thanks, but if telnet works with tty/pts jobcontrol and vi etc, then I'm fine with that for now. I tried your command variations above and got this:

[SIZE=2]#ssh -2 dummy@192.168.1.10 -p 2222 -T su -c exec /system/bin/sh -i # This worked!

#ssh -2 dummy@192.168.1.10 -p 2222 -T su -c exec /tmp-mksh/tmp-mksh -T /dev/pts/0
/tmp-mksh/tmp-mksh: chvt: can't find tty /dev/pts/0

#ssh -2 dummy@192.168.1.10 -p 2222 -T su -c exec /tmp-mksh/tmp-mksh -T /dev/ptmx
/tmp-mksh/tmp-mksh: chvt: new shell is potentially insecure, can't revoke /dev/ptmx
[/SIZE]

The fist one is good to get direct root prompt, the second fails, since pts/0 has not been created yet, and if it has, it fails with permission issue, since another process is trying to steal the pts. The reason why the third one fails, is very cryptic and I don't understand the error message and neither the code generating it.

Do you think one could use the ATE app to get a working root shell by the use of a more complex ssh command? Any suggestions how that would look?

Finally, I'm a bit worried about replacing the libc.so dependency, since the whole system depend upon it, and would probably not boot if an incompatible libc.so is used. This is why I asked about a static binary. I'd much rather have a bloated mksh than having to add library files. (We have plenty of memory and space these days.)

Regarding compiling, I would recommend using Linaro a build, rather than the crappy and often broken/outdated Code Sourcery junk.

Check this thread:

[LINARO GCC] Cross Compiler Toolchains [Linaro GCC 4.9 2014.07, 4.8 and 4.7 2014.04][19/07/2014]

Cheers!
[Android Software/Hacking General [Developers Only]] mirabilos:
Hi! As the author of mksh, I am hereby explicitly requesting you to add a suffix to the shell version, similar to what the PLD Linux guys do here, because this changes the behaviour of the shell in an incompatible way. (Just add your own string there after a space, the [MENTION=1585175]distro[/MENTION]@ is just a placeholder that gets replaced with the PLD Linux package version.)

Do note that ^U in Korn Shell (and others) is “delete entire line”.

Interesting idea, I think I will pick up the “set +x” thing.

Do you mind sharing a patchset of all your changes, so I can incorporate those I feel would be good to have in general?

Just link the shell statically, then.

You are annoying me. I've told you times and times again to disable SEAndroid, or to fix its SELinux policies.

Define “everything”. mksh in AOSP is /system/bin/mksh plus mkshrc.

I'm working with enh of Google on that. I would like for mksh to be installed as /system/bin/mksh and /system/bin/sh to be a link/copy of it, always. He said he'd agree I could change that back.

These are part of the shell, and have always been, even in pdksh times.

I do not deal in binaries normally. I'm somewhat working on updating AOSP to mksh CVS HEAD, in tandem with enh from Google, but when I had the time for that, it appears they changed the build system requirements. But it will be there.

It's not as if a newer mksh version would fix your SELinux problem, though…

The “r” alias is especially required for the Emacs command line editing mode. Interesting that toolbox uses it too. Thanks for bringing this to my attention, I will ask enh to change “r” in toolbox.
[Android Software/Hacking General [Developers Only]] 7175:
[MENTION=4372730]E:V:A[/MENTION] : Glad the first execution you mentioned worked. I would try messing with quotes/double quotes around the shell command, i.e. ssh ... -T su -c 'exec ...' or try ssh ... -T su -c exec "...", as something to test out further. This can make a lot of difference.

The ulimit shell function can control all sorts of performance related stuff, priority, max niceness, etc. You can see all values with "ulimit -a".

I understand your hesitance about the libc.so replacement. I would keep a copy of the old one and twrp backup before trying out a new one. I get what you're saying about statically linked binaries. I just fixed my i7 desktop that had a blown power supply, so I'll be looking into this. Thanks for the linaro link!

[MENTION=3420143]mirabilos[/MENTION] : Thanks for taking a look at this and providing us with mksh! I updated my OP with the specifics about the rebinds for "control I" and "control U" that you mentioned, and I added a suffix to the beginning comments of the file. Something like:

# $MirOS: src/bin/mksh/dot.mkshrc,v 1.88 2014/01/11 18:09:39 tg Exp $Android_mod by 7175@xda-developers.com 2014/08/04$

Not sure if that's what you wanted me to add in. I included an extra zip to download in the 2nd post that contains the official mkshrc 2014/01/11, my personal mkshrc, and a "diff -ur" patch (also attached to this post).

I will look into getting a statically linked mksh compiled, that sounds like something really handy to keep around.

edit: Here's basically what I added to the beginning and end of PS1 to trim down its "set -x" verbosity to 3 lines. I'd like to get it down more but haven't figured it out.

PS1=$'\001\r'; PS1+='${|
local e=$?
[[ -o -x ]] && set +x && global -x XTR_DBG=1 || global -x XTR_DBG=0
...
...
...
(( XTR_DBG )) && set -x
return ${e}
} '
[Android Software/Hacking General [Developers Only]] mirabilos:
You’re welcome!

Ah, so you did not patch the mksh binary, only the mkshrc file?

But then, that’s okay as you wrote, sure.

OK, thanks. Will have a look at it within the next weeks (August is going to be a busy month for me).

I’m assuming you are okay with me adding some of your changes back to main mksh?

Indeed, it is.

The first mksh run on Android actually was statically compiled against µClibc, though that’s cheating. (Also, dietlibc and klibc are better than µClibc). I think it should work against Bionic, too.

I don’t think it works in less, considering you have to save the previous $?. There are a few handy tricks around. I tried these four:

#1 is:

local e=$?
[[ -o -x ]]; local x=$?; set +x

(( e )) && REPLY+="$e|"
[…]
(( x )) || set -x
return $e

This is about what you did. #2 is:

local e=$? x=$([[ -o -x ]]; echo $?); set +x

(( e )) && REPLY+="$e|"
[…]
(( x )) || set -x
return $e

This only looks different (I’d prefer #1 over this.) #3 is:

set +x $? $([[ -o -x ]]; echo $?)

(( $1 )) && REPLY+="$1|"
[…]
(( $2 )) || set -x
return $1

This reduces visual clutter. #4 is:

set +x $? $([[ -o -x ]]; echo $?)

(( $1 )) && REPLY+="$1|"
[…]
(( $2 )) && return $1
(( $1 )) && set -x && return $1
set -x

This reduces visual clutter even more, in that, when $? is 0, one line less is shown. But it makes the number of lines shown be not always the same. YMMV on whether to use this, #3 or #1.

This could be made even nicer *iff* mksh had the EXIT trap when leaving a function. The manpage says it’s TODO. This part of the manpage is from 1999 or older. (I started mksh in late 2002, early 2003.) Go figure… But now I have a reason to add it ☺

Another thing you could do is “set +o inherit-xtrace”, which makes functions not run with “set -x” when the main body runs with it. But wait, I see now that it does not affect ${|…;} blocks. This is a bug, which I’ll fix ☻