Need help moving from DOS to Unix (BSD)

Conor P. Cahill cpcahil at virtech.UUCP
Sat Sep 2 22:50:44 AEST 1989


In article <1287 at calvin.EE.CORNELL.EDU>, richard at calvin.EE.CORNELL.EDU (Richard Brittain) writes:
> Hello netland,
> 	 sorry if this is a rather vague question, but my problem is
> that I learned C on a pc using Turbo-C, and now I'm trying to write in C
> on a unix box (BSD and Ultrix) but nothing works!!!!!.  All of my pc source
> gives multitudinous errors under unix, and I'm not talking about obvious
> stuff like DOS specific functions, but things like header files in different
> places, or not there at all.  Function prototypes seem to give cc a fit, and
> I also get a lot of miscellaneous errors and warnings like "warning: old
> fashioned initialization" that I cannot make sense of.  I'd be really 
> grateful if anyone could give any general rules of thumb for converting
> between the two environments.

My *guess* would be that the turbo-c compiler is much more ANSI compliant
than the older compilers used on your BSD/Ultrix systems.  If you really
need to be portable accross these environments I would develop the software
on the BSD/Ultrix system and then port it to turbo-c. This gets you writing
the software at the "least common denominator" level of compiler.  An ANSI
compiler should not have too much trouble compiling software generated
under an older (K&R 1st Ed) compiler since that was part of thier mandate.



-- 
+-----------------------------------------------------------------------+
| Conor P. Cahill     uunet!virtech!cpcahil      	703-430-9247	!
| Virtual Technologies Inc.,    P. O. Box 876,   Sterling, VA 22170     |
+-----------------------------------------------------------------------+



More information about the Comp.lang.c mailing list