Quick guide to building (the binary is linked at the bottom of the page) the Top command line application on the Apple TV, originally posted by jMahn on the AwkTV forums, its come up a couple of times since so I figured put it in the main how-to section, if anybody has any other info or edits to this of course feel free, I've never posted on a wiki before - DaiMac79
(Original post is here) The version of the "top" command from OSX doesn't run on Apple TV (at least not the 10.4.9 version from my MacBook).
I was able to download the source for the Darwin version from Apple and it works just fine. Basic instructions...
- Get source here: http://www.opensource.apple.com/darwinsource/10.4.9.x86/ . Scroll down to: top-17.4
- Download source. You'll need to have registered as an Apple developer (remember, it's free).
- Unpack, then in Terminal, CD into the directory and type "make"
- There will be an error at the end because by default, the Makefile tries to install the newly built "top", but you didn't run it with "sudo". That's okay, you don't actually want to install it on your Mac.
- Copy the new version to your AppleTV, either with scp or drag and drop if you've got its drive mounted.
- Then move it into /usr/bin.
- You need to give it special permissions since it does system stuff:
sudo chown root:wheel /usr/bin/top sudo chmod 4755 /usr/bin/top
Then, just type top ! (/usr/bin always in search path)
If you don't want to compile it yourself, I've attached the copy I just built (code is APSL license so it should be just fine to post the binary here): (MD5 of unzipped binary was 17b202a3d19c152123cec65c80e10d97)