Usenet comp.sys.dec (1990-2013)
 help / color / mirror / Atom feed
* ANSI C compiler on DEC station
@ 1994-10-19  5:15 Hung Nguyen
  1994-10-19 19:29 ` Rich Peterson ZKO2-3/N30
  1994-10-25 19:49 ` Philip J. Tait
  0 siblings, 2 replies; 3+ messages in thread
From: Hung Nguyen @ 1994-10-19  5:15 UTC (permalink / raw)



  Hello all,

  We would like to know if the C compiler that normally comes
  with the Ultrix 4.3 ANSI compliant. If not, is there any
  ANSI C compiler that will work fine under Ultrix 4.3? 
  Because we are having a problem with our DEC-C (c89) compiler
  in which we cannot compile our source code without the -common
  flag. Without the -common flag the compiler would complain
  about one of the typedef in the Xlib.h file. The compiler would
  not pass even the X Window layer. When we install Ultrix and/or
  an ANSI C compiler on our DEC station do we need to upgrade the 
  X Window and Motif software as well? Do these software layers relate
  to one another in a sense that if we upgrade one then we have to 
  upgrade the other two? 

  We appreciate your help very much in this matter. Please respond
  to us either in this news group or in the private channel at the
  above e-mail address. Our thanks in advance for any of your inputs.

  Best regards,
 



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: ANSI C compiler on DEC station
  1994-10-19  5:15 ANSI C compiler on DEC station Hung Nguyen
@ 1994-10-19 19:29 ` Rich Peterson ZKO2-3/N30
  1994-10-25 19:49 ` Philip J. Tait
  1 sibling, 0 replies; 3+ messages in thread
From: Rich Peterson ZKO2-3/N30 @ 1994-10-19 19:29 UTC (permalink / raw)



In article <382a2f$npq@pendragon.jsc.nasa.gov>, hnguyen@killerbee.jsc.nasa.gov (Hung Nguyen) writes:

|>  We would like to know if the C compiler that normally comes
|>  with the Ultrix 4.3 ANSI compliant. If not, is there any
|>  ANSI C compiler that will work fine under Ultrix 4.3? 

The default C compiler (cc) that comes with Ultrix 4.3 is not ANSI
compliant.  The cc compiler that comes with Ultrix 4.4 is ANSI
compliant.

|>  Because we are having a problem with our DEC-C (c89) compiler
|>  in which we cannot compile our source code without the -common
|>  flag. Without the -common flag the compiler would complain
|>  about one of the typedef in the Xlib.h file.

The c89 compiler is ANSI compliant under the -std flag.  Under the
-common flag it accepts a dialect of C like that of the "portable
C compiler" common on Unix platforms and is not ANSI compliant
in that case.  Although the X header files have provisions in them
to compile under an ANSI compiler (i.e. they test the __STDC__ predfined
macro), it is possible that there is some problem in the headers you
have.  You didn't mention what the problem was or which typedef it was,
but I couldn't reproduce any problem of this kind compiling Xlib.h
with c89 and any of its language flags on RISC/Ultrix 4.3:

% head -2 /etc/motd
ULTRIX V4.3 (Rev. 44) System #3: Fri Apr 16 15:28:26 EDT 1993
UWS V4.3 (Rev. 10)
% cat c.c
#include <X11/Xlib.h>
% c89 -c c.c
% c89 -std -c c.c
% c89 -common -c c.c
% c89 -vaxc -c c.c

What version of the c89 compiler are you using?

% c89 -source_listing -c c.c
% head c.lis
c.c                                  DEC C for ULTRIX on RISC    V1.2a              Oct 19 1994    15:23:46                    1    

%

On the other hand, your best bet is probably to upgrade to Ultrix 4.4,
which has a number of bug fixes and the default C compiler has a
ANSI-compliant mode (-std1).

 -Rich
-- 
Rich Peterson,  ZK2-3/N30                       repete@tle.enet.dec.com
Digital Equipment Corporation			decwrl!tle!repete
110 Spit Brook Rd,
Nashua, NH 03062


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: ANSI C compiler on DEC station
  1994-10-19  5:15 ANSI C compiler on DEC station Hung Nguyen
  1994-10-19 19:29 ` Rich Peterson ZKO2-3/N30
@ 1994-10-25 19:49 ` Philip J. Tait
  1 sibling, 0 replies; 3+ messages in thread
From: Philip J. Tait @ 1994-10-25 19:49 UTC (permalink / raw)



In article <382a2f$npq@pendragon.jsc.nasa.gov>, hnguyen@killerbee.jsc.nasa.gov (Hung Nguyen) writes:
|>  We would like to know if the C compiler that normally comes
|>  with the Ultrix 4.3 ANSI compliant. If not, is there any
|>  ANSI C compiler that will work fine under Ultrix 4.3? 

gcc works well for us here.

-- 

Philip J. Tait         AlliedSignal Engines, Phoenix, Az        +1 602 231 7104
GED::B12635         pjt@pelab.allied.com      b12635@vaxc.phx1.aro.allied.com


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~1994-10-25 19:49 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1994-10-19  5:15 ANSI C compiler on DEC station Hung Nguyen
1994-10-19 19:29 ` Rich Peterson ZKO2-3/N30
1994-10-25 19:49 ` Philip J. Tait

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox