Path: utzoo!utgpu!news-server.csri.toronto.edu!bonnie.concordia.ca!uunet!elroy.jpl.nasa.gov!jato!kalessin!sam From: sam@kalessin.jpl.nasa.gov (Sam Sirlin) Newsgroups: comp.binaries.ibm.pc.d Subject: dj gcc problem Message-ID: <1991Jun18.045843.24870@jato.jpl.nasa.gov> Date: 18 Jun 91 04:58:43 GMT References: <1991Jun13.140903.29800@truevision.com> <1991Jun17.172132.31493@kuhub.cc.ukans.edu> Sender: Organization: Jet Propulsion Laboratory, Pasadena, CA Lines: 14 Nntp-Posting-Host: kalessin.jpl.nasa.gov I'm trying to port a compiler (apl2c) written in C to msdos using dj delorie's gcc (1.01 currently). The compiler has several stages that pass intermediate results using stdout, stdin. The problem is that the data passed ought to be binary rather than dos text. It appears to me that stdin (e.g. putchar, getchar etc.) only write/read dos text. If I use a file, I can toggle between the two using either the "b" option or setting _fmode (not _ftype as in the docs), but this doesn't seem to work for stdin/stdout. Is this true? Do I have to rewrite the io to use files or make it into printable text? Sam Sirlin Jet Propulsion Laboratory sam@kalessin.jpl.nasa.gov