PDA

View Full Version : Setting up a Tivo S2 Development System



EvilJack
09-16-2004, 09:08 AM
I'd like to use this thread to discuss setting up a TiVo S2 development system. ( If you've got one already going... please post the details. )

Getting a cross-compiler going isn't enough. Just because you have
the MIPS Cross compiler set up, doesn't mean you can unpack
pico.tar.gz or nano.tar.gz and just run make to get it to work.

I can't figure out how to compile the devbin and cmd stuff that
Tivo provies. There is the README.TiVoBuild challenge

Note to developers: the Makefile(s) in this directory tree have been
set up according to the conventions used by TiVo's automated build
environment. These conventions assume a certain (rather complex)
structuring of the source and destination directories, and the locations
of certain utility data files and programs. They also assume that
the versions of the GNU C compiler and related utilities used by
TiVo have been installed.

It is possible - quite likely, in fact - that you'll need to edit some
of the Makefiles and other configuration files in this directory tree,
or set various environment variables in useful ways, in order to build
this software yourself. You will almost certainly need to install the
GNU toolchain version used by TiVo (it's available on our Web site).

that I'd like to figure out. I'd like to be able to set up a 'clone' of
their build system to see if that makes it easer to cross-compile
applications.

I'd like to use this thread to talk about what all is needed.

For example, does it matter what i386 distribution your running?

Is it better to use a fast MIPS Cross compiler, or is there a
fast, cheap, non-tivo MIPS platform that would work better?

I've been thinking that a small, i386 distribution of Linux that closely
matches what Tivo uses ( same kernel, libs, etc but for i386 ) might
help figure out how to cross compile some of this stuff.

Anyway... if your interested in this ( or already figured it all out )
let me know.

jack

Tymanthius
09-16-2004, 09:45 AM
I'm not a developer, so I won't be posting code, sorry. :(

However, in response to the posts that kinda got this thread started:

I agree that making a new TivoScripts ISO isn't really a good idea. However, an ISO that has been built w/ Series 2's in mind, or DTivo's S2's in mind, or whatever, is a good idea.

All the tools in one place, LOTS of ReadMe's, and kept somewhat up-to-date. Doesn't have to be bleeding edge. I think this would help SO much more in learning how to hack, vs. the Sleeper image.

I'm a linux user (not great, but I don't get confused when ppl talk about rc.* files), but even so, I ended up using the Sleeper ISO b/c it would get me up in running in less than a day. Everything else would take at least a day of just reading. Now that my system is Sleepered, I still go in and add things such as installing TWP to replace TW, installing the endpad & bufferhacks, etc.

So, anyone who wants to learn, will, regardless of what method they use to start. However, having all the tools handy would be WONDERFUL. Having to wade thru this spaghetti nest of posts is just awful at present.

Just my thoughts on how to make a good ISO - "The tools and info for a particular service (SA, DTivo, S1, S2) all in one place, but minimal, or no automated scripts."

Numbski
09-16-2004, 10:27 AM
How many of you guys know how to use a wiki (http://wiki.org/wiki.cgi?WhatIsWiki)? I mean, if I set up a Wiki on our web server, we could at least compile all of our 'known good' information re: S2 Tivo's. So far as working a development system/distro then we can at least start brainstorming here.

It appears that RC3105 (http://www.dealdatabase.com/forum/member.php?userid=2651) is claiming the rights to killhdinitrd (http://www.dealdatabase.com/forum/showthread.php?t=36692) so including that would be up to him. I'm not super-savvy to linux licensing since I usually deal with BSD (FreeBSD and MacOSX) where the code is free as in speech and beer, rather than just speech. :P I don't even know if including a binary-only application with a ponderance of GPL software violates the GPL, which is viral in of itself.

Licensing aside though, I think we have a good basis for a start. We can at least contact the devloper of killhdinitrd for permission, which is good. There is (apparently) a GPL'ed version of the MFSTools, which is certainly a plus.

What else?

EvilJack
09-16-2004, 10:44 AM
As far as killhdinitrd and MFSTOOLS goes... I think your talking about
a 'TOOLS' type of distribution / delivery system... those don't really have
anything to do with setting up compilers and libraries and what not, so
you can generate your own programs and things to run on Tivo.

A wiki is fine.... but the last two post in this thread are oriented more
towards 'support' and not 'development'. This thread was set up solely for
DEVELOPMENT of new tools... not delivery/licensing of existing tools.

jack

Numbski
09-16-2004, 10:49 AM
I think we're close to thinking the same, not quite.

I'm thinking of setting up a development type environment that runs ON THE TIVO.

You're thinking of setting up a development environment that run on Linux i386.

So not quite the same. :\

I want compile the information neccessary to get people effeciently informed of what is needed to get a Tivo development environment up and running. I think documenting the setup process is important, and not in a spoon-fed kind of way. Tell people what it is the Tivo is doing, and what the programs are doing to set up the environment. Right now, the only thing a person can do is guess and guess and read some more and guess some more and eventually the person gets it hacked to a point that it does what they want, but they still don't REALLY understand what's going on.

Not exactly comfortable with developing for that kind of environment. I'd like to standardize the environment that we're working with, and that requires documenting a setup process that is both sane and hacker-friendly.

You follow?

Numbski
09-16-2004, 10:52 AM
Let me shorten and clarify there:

If we are going to set up a development system on i386 Linux, we have to make presumptions about the environment on the Tivo. With people hacking this way and that, we can't really make many solid presumptions about that environment (can we?), so the best way to do this is to start by standardizing the Tivo environment, then mimic it on i386 Linux. This includes documenting what is needed to get that environment running.

mrblack51
09-16-2004, 12:59 PM
realize that a dev environment on the tivo, while somewhat standard, will be painfully slow. compiling stuff on the tivo is not a quick process compared to a standalone linux box.

psxboy
09-16-2004, 03:56 PM
It appears that RC3105 (http://www.dealdatabase.com/forum/member.php?userid=2651) is claiming the rights to killhdinitrd (http://www.dealdatabase.com/forum/showthread.php?t=36692) so including that would be up to him. I'm not super-savvy to linux licensing since I usually deal with BSD (FreeBSD and MacOSX) where the code is free as in speech and beer, rather than just speech. :P I don't even know if including a binary-only application with a ponderance of GPL software violates the GPL, which is viral in of itself.

The license for killhdinitrd was derived by it's creators (HDTeam). RC3105 is merely honoring their request and acting as the go-between for HDTeam and the DealDatabase community. Boiled down, the terms of use set forth by HDTeam for killhdinitrd and kernel images that include their code is meant to prevent (as much as possible) EBay scammers and anyone else from making a quick buck off of their work. They want it to be free, both to use and distribute, but not to be included as part of a "pre-hacked" system or in "unauthorized imaging tools created by self-aggrandizing heroes".

The 0.9.1 version (in the third post in the killhdinitrd thread) contains the full ReadMe and the source code. (Dunno why these weren't included in the newer versions... petition for change?)

-psxboy

Numbski
09-16-2004, 07:00 PM
Hmm...so it would appear that so long as we're honoring the spirit of the license, we're good. I would like to get in contact with someone from the HDTeam just be sure though. Last thing I want to do is upset anyone. :eek:

kelsky
04-20-2005, 10:49 AM
So the question is, who is compiling for the S2 and what OS are they using? What works the best?

mrblack51
04-20-2005, 11:35 AM
So the question is, who is compiling for the S2 and what OS are they using? What works the best?

most are using some flavor of a standard linux distro (debian, suse, redhat/fedora, etc.) and cross compiling.

rc3105
05-12-2005, 08:53 PM
anyone considered doing a knoppix based tivo build environment? the cygwin env's are a good start but it's way to easy to get tripped up by windows issues :eek: (not that live-bsd or <insert fav *nix flavor here> wouldn't be equally handy, just seems that knop 3.x hardware support works well and *nix noobs are less likely to hose their pc with a livecd)

since mfstool pretty much requires a fat 32 partition, how about a tgz that would unpack to a single fat32 dir and provide full kernel/mfstool/vplay build capability? (used to have a loadlin-fat32 slackware s1 build env here that made tinkering & dev SO much easier)

EvilJack
05-31-2005, 10:32 PM
Does anyone know if Tivo has released the 6.2 sources...
http://www.tivo.com/linux lists a lot of stuff... but no 6.2.
Is 6.1 'close enough'?

Also... does anyone know what versions of GCC and GLIBC
were used for tivo's 6.2 binaries and libs?

I used gcc-3.0.4 and glibc-2.2.3 and want to know if I can/should
upgrade to something newer.

jack

Jamie
06-01-2005, 12:42 AM
Does anyone know if Tivo has released the 6.2 sources...
http://www.tivo.com/linux lists a lot of stuff... but no 6.2.
Is 6.1 'close enough'?

Also... does anyone know what versions of GCC and GLIBC
were used for tivo's 6.2 binaries and libs?

I used gcc-3.0.4 and glibc-2.2.3 and want to know if I can/should
upgrade to something newer.

jackSomeone probably needs to make a formal request for the GPL'd 6.2 code.

The recent kernels (including the 6.2 kernel) still show "(gcc version 3.0)" in their version string. That's the version I use. I know the mips abi changed in later versions (3.4?), so you definitely don't want that.

You should probably use the tivo devenv version of glibc (which is based on glibc-2.2.3).

EvilJack
06-02-2005, 04:47 AM
On a lot of configure scripts I look at, when you try and
cross-compile something, they are hard coded to abort if you
are cross compiling. You get this error after a bit whne you
try and ./configure....
configure: error: can not run test program while cross compiling

If you look at the actual configure script and hack around the
if test "$cross_compiling" = yes; then
check, it usually ( most of the time ) works anyway.

My question is... what puts in that cross compiler abort? Is it
the user the originally created/edited that script or what?
Is there an 'easy' way to fix this, or do you have to fix
each occurance as you find them?

jack