🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.std.unix
Article #82

Re: standard unix graphics package

#82
From: gwyn
Date: Thu, 19 Oct 1989 10:49
38 lines
2094 bytes
In article <403@longway.TIC.COM> uunet!dg-rtp.dg.com!dg-rtp!meissner (Michael Meissner) writes:
>|  In article <401@longway.TIC.COM>, gwyn@BRL.MIL quotes someone:
>|  > >3) that the final version be
>|  > >    b) portable to ALL UNIX SYSTEMS
>|  and then says ..
>|  > Wow, taken literally this would be EXTREMELY TOUGH.
>| [yet another contestant's entry here]
>You still lose.  Under ANSI C the above program is not valid, since
>printf is a varargs function that has no prototype in scope.  While we
>are at it, main should return a valid exit status.  Ok, the revised
>program is:
>	#include <stdio.h>
>	main()
>	{
>		printf("Hello world\n");
>		return 0;
>	}

UNIX systems are not general ANSI C conforming at present.
Some of them may not even support main() with no parameters..
I know that some of them ignore the value retuned by main()
and pretend it returned "success" status (0), but that doesn't
break the above program.

Certainly, back in prehistory, some UNIX systems did not have
<stdio.h>.  One would hope there are none like that still in
operation, but I wouldn't bet on it.

What Mike says is correct in the context of Standard C.

If there is this much variation possible simply in the UNIX
portability of the "Hello, world" program, imagine how much
more difficult it would be for a GRAPHICS program (as in the
original specification).  By the way, we all understand the
"graphics" requirement to not be satisfied by a text-oriented
program.

Volume-Number: Volume 17, Number 34
Technical Details
Message-ID: <404@longway.TIC.COM>
Path: arc1-ca.pugleaf.net!utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!cs.utexas.edu!uunet!longway!std-unix
References: <400@longway.TIC.COM> <401@longway.TIC.COM> <402@longway.TIC.COM> <403@longway.TIC.COM>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!cs.utexas.edu!uunet!longway!std-unix
From: gwyn@BRL.MIL
Newsgroups: comp.std.unix
Subject: Re: standard unix graphics package
Message-ID: <404@longway.TIC.COM>
Date: 19 Oct 89 10:49:38 GMT
References: <400@longway.TIC.COM> <401@longway.TIC.COM> <402@longway.TIC.COM> <403@longway.TIC.COM>
Sender: std-unix@longway.TIC.COM
Reply-To: gwyn@brl.arpa (Doug Gwyn)
Organization: Ballistic Research Lab (BRL), APG, MD.
Lines: 38
Approved: jsq@longway.tic.com (Moderator, John S. Quarterman)