An anonymous reader writes
"TCCBOOT is the first boot loader able to compile and boot a Linux kernel directly from its source code. It can compile and start booting a typical Linux kernel in less than 15 seconds on a 2.4 GHz Pentium 4. TCCBOOT uses the latest version of the TinyCC C compiler."
Not a complete compile (Score:5, Informative)
I guess this could have some limited use somewhere, perhaps, but I can't really see how if you need some precompiled stuff.
Architecture Independence (Score:3, Informative)
I don't know how useful a processor architecture-independent version of this would be (the compiler itself is pre-compiled for a specific processor, presumably!) but it does seem a rather cool hack. Maybe an ultra-inclusive version of Gentoo?
Re:usefulness? (Score:2, Informative)
It's called a "hack".
Have the last nerd left the building?
Wha? (Score:3, Informative)
I guess 15 seconds is to compile without any device support other than the boot drive.
That said, linux boot time as it is sucks, especially if you want to use it on something like a router/firewall box like I do. The only button I ever press on that machine is reset. VPN not working? Reset.
That's how it should work IMO, but every time I do it the 'net is out for 10 mintues until it's back up.
Resetting the whole box should be faster than ssh'ing in and typing a "/etc/init.d/shorewall restart" and "/etc/init.d/openvpn restart".
Re:How? (Score:5, Informative)
Blatant Karma Whoring: In case of a slashdotting.. (Score:4, Informative)
Introduction
TCCBOOT is a boot loader able to compile and boot a Linux kernel directly from its source code.
TCCBOOT is only 138 KB big (uncompressed code) and it can compile and run a typical Linux kernel in less than 15 seconds on a 2.4 GHz Pentium 4.
TCCBOOT is based on the TinyCC compiler, assembler and linker. TinyCC is an experiment to produce a very small and simple C compiler compatible with the GNU C compiler and binary utilities.
Screenshots
Download
ISO image demonstation: tccboot.iso (5.9 MB).
Create a CD from it and boot it to see TCCBOOT in action (PC with at least 64 MB of RAM required). You can also try it with the QEMU PC emulator.
TCCBOOT source code: tccboot-0.1.tar.gz, and README file.
Re:script? (Score:3, Informative)
Re:How? (Score:4, Informative)
LinuxBIOS (Score:3, Informative)
BIOS there's the LinuxBIOS [linuxbios.org].
It looks like its only for clusters but I'd
like to get it from my next Linux box.
Re:But why? (Score:3, Informative)
It is indeed very fast, but it wouldn't compile ghostscript for me.
# apt-get install tcc[...]
$ cd ~/projects/ghostscript/gs
$ make distclean
[...]
$ CC=tcc
[...]
tcc -DHAVE_MKSTEMP -DHAVE_HYPOT -O -DHAVE_STDINT_H -DGX_COLOR_INDEX_TYPE="unsigned long long" -I./src -I./obj -I./obj -I./src -o
In file included from
In file included from
make: *** [obj/zfcid.o] Error 1
Compiler bug?
I also like how it has an auto-run switch to invoke the compiler output. So you can make C source executable from the command line by putting #!/usr/bin/tcc -run at the top. I would use that for quick test programs in C. Once it's debugged you can run it through gcc.
Re:TCC compiler (Score:5, Informative)
Tcc seems truly amazing (Score:2, Informative)
I had to download its source code, build it and use it to believe it. 100k for something that compile a C code about 5 times faster (my very rough measures) is something I would have consider a joke if I could not see it in action.
Obviously, it probably not do all the optimizations gcc implements, but still. Wow.
Re:How? (Score:4, Informative)
Re:Too fast... (Score:3, Informative)
1a)
Note that your init scripts might be in a slightly different location.
Re:usefulness? (Score:2, Informative)
echo "" > -i
You'll thank me if you do something stupid like that again. The "-i" will be seen as an argument to /bin/rm, and it'll ask you to confirm each item. Sure, this could be a pain in the ass, but I can't think of a good reason to "rm *" in an important directory like that.
Re:Too fast... (Score:2, Informative)
I then have a simple script that removes all the lockfiles in
This usually fixes many problems quickly (just the sysrq, login, run the script, and then tell it to start everything again; you can continue using X and since KDE or Gnome will mostly be cached in RAM it will start fast.)
Re:Too fast... (Score:3, Informative)
I am not your average sysadmin who can figure out every script and knows much about process lists, or Kill Signals.
That's what an education is for. From this sentence, I get the impression that you are a sysadmin, albeit one that is grossly unqualified for any sysadmin position.
I guess we can pin this sort of thing on Microsoft, who's penchant for wizards and paperclips has led to a flooding of the market by uneducated or unqualified IT workers. It's the same frightful problem that the developer space deals with, where VB6 allows people to create executables without understanding programming at all.
I apologize, if I'm being offensive. It is frustrating to see the industry that I work in crumble because of the antics of a single company and the bloat in salaries a few years back. I'm not saying that you, in particular, have no chance of learning, it looks like you're interested in what you're doing... But there are quite a few more capable and qualified people out there without jobs that can fill a sysadmin position that is filled by an MS drone.
Imagine... if all sysadmins had CS degrees, the majority of all servers would probably be *NIX based, and Code Red wouldn't have happened.
Re:Too fast... (Score:3, Informative)
Heh, why do people type so much? On RedHat at least, there is a script in /sbin called "service" which runs the given service for you.
For example, instead of typing:
You can just type:
service httpd restart
Less than perfect first impression (Score:3, Informative)
This is fixed by defining __TINYC__ in the rule for bcheck.o, and you get a tcc executable. Trying to remake it with itself
Results in complaints about stddef.h not found. Adding -I/usr/include/linux leaves us with other errors, and as Mr. Costello would say at this point, "I don't give a darn".My interest just ran dry for now.
-dB, on third base.
Re:But why? (Score:3, Informative)
Why not give some more information so we can figure out why it doesn't work? It could just be a misconfigured #define somewhere.
Re:Too fast... (Score:3, Informative)
Re:How? (Score:1, Informative)