devisser@cs.utwente.nl (Jan de Visser) (06/17/91)
When trying to install g++ on my Amiga 3000UX, it complained that a FILE does not have a _bufsize field. I examined stdio.h, where FILE is defined, and what do you think? No _bufsize! (strange eh :-). To check, I took a look at /usr/5include/stdio.h on our Sun system. On there, FILE *has* a _bufsize field. What is the reason for this incompatibility? What to do to solve it? Are there more of this kind of incompatibilties? Jan. =========================================================================== Jan de Visser, | Internet: devisser@cs.utwente.nl University of Twente, | Dept. Computer Science, | < Still looking for something to fill PO Box 217, | this space. Hmm, I think I did it! > NL - 7500 AE Enschede. | ===========================================================================
ag@amix.commodore.com (Keith Gabryelski) (06/21/91)
devisser@cs.utwente.nl (Jan de Visser) writes: > When trying to install g++ on my Amiga 3000UX, it complained that a > FILE does not have a _bufsize field. I examined stdio.h, where FILE > is defined, and what do you think? No _bufsize! (strange eh :-). > [...] > What is the reason for this incompatibility? What to do to solve it? First, g++ should not be relying on non-portable features of some stdio implementations. I suspect, if you look hard, you will find some way around this. _bufsize could *probably* be emulated by the `_bufsiz' macro in the SVR4 implementation but I make no claims that it will actually do what you want. It would be better to fix the code in question then to add another non-portable hack. We have a compiled g++ here (but the executable doesn't do anything that interesting yet). > Are there more of this kind of incompatibilties? Yes. On a SUN4 running SunOS 4.0.3c the 42nd byte of the program `/bin/cat' is `03' on Amiga Unix Release 1.1 it is `00'. Don't rely on this! :-) Pax, Keith -- Keith Gabryelski Advanced Products Group ag@amix.commodore.com ...!cbmvax!amix!ag
skrenta@amix.commodore.com (Rich Skrenta) (06/21/91)
devisser@cs.utwente.nl (Jan de Visser) writes: > When trying to install g++ on my Amiga 3000UX, it complained that a FILE does > not have a _bufsize field. ... > What is the reason for this incompatibility? What to do to solve it? g++ does some pretty gross stuff with FILE, uncessesarily mucking about in the internals of stdio. This is inherently non-portable. The particular problem you're having can be fixed by simply turning on USG_STDIO in the Makefile, but that's not all you'll need to do to it to get g++ to work. I'm currently working on g++ for our 2.0 release. I will post diffs & instructions as soon as I get it working. Rich -- skrenta@amix.commodore.com