Quote Originally Posted by slarty
You could rename the main() method in a.c and then declare it in an external header file (a.h).

Then include that header file in b.c and just call the renamed main method. When compiling the resulting program, link all of A and B's C files together.

Slarty
I thought about that too, but the reason I am asking specifically for the main() function is because I am observing the code for a toy shell (I would post the code here, but I am unsure whether it is copyrighted; it is in the book Operating Systems: Design and Implementation, page 29 for the third edition to be precise ).

[ASIDE]I am trying to get Minix to be a "real" operating system; an equivalent to Linux at least. I doubt I'll succeed soon (if at all) but everyone needs a hobby; a good friend of mine (who is a "real, professional" programmer) advised me to study the Minix book (OSDI) religiously.

I figured the best way I could do that is to take extensive notes on the book, and do all the problems. (I must confess that I am learning quite a bit, maybe I'll write a tutorial on using minix 3!)[/ASIDE]