Usenet comp.sys.dec (1990-2013)
 help / color / mirror / Atom feed
From: howardy@freud.nia.nih.gov (Howard Wai-Chun Yeung)
Subject: problem with the risc c compiler on DEC
Date: Tue, 27 Apr 1993 16:25:18 GMT	[thread overview]
Message-ID: <1993Apr27.162518.10123@alw.nih.gov> (raw)

I compile a c program using a SGI ansi c compiler and
a DEC risc c compiler.

I my program, I have the following statements:
~
~
#include <sys/file.h>
#include <fcntl.h>
#include <sys/types.h>
#include <sys/mman.h>

~
~
caddr_t inmapped=NULL;
caddr_t outmapped=NULL;

outmapped=mmap((caddr_t)0,(dimx*dimy*dimz*bits)-1, PROT_READ|PROT_WRITE , MAP_SHARED, fd, (off_t)0);

~
~
inmapped=mmap((caddr_t)0, (dimx*dimy*dimz*bits)-1 , PROT_READ , MAP_SHARED , fd, (off_t)0);

~
~
dimx, dimy, dimz and bits are integers.
On the SGI c compiler, the compling is OK.
But on the DEC compiler, I get the following warning message:
ccom: Warning: genimg.c, line 184: illegal combination of pointer and integer, op =
       outmapped=mmap((caddr_t)0,(dimx*dimy*dimz*bits)-1, 0x1           |0x2             , 1         ,
 fd, (off_t)0);
      ------------------------------------------------------------------------------------------------
-----------------^
ccom: Warning: genimg.c, line 218: illegal combination of pointer and integer, op =
       inmapped=mmap((caddr_t)0, (dimx*dimy*dimz*bits)-1 , 0x1           , 1             , fd, (off_t)
0);
      ------------------------------------------------------------------------------------------------
--^


My program doesn't run on DEC.

Do anyone know why?
If you like the whole copy of the program, I will more than 
glad to send you one.  It has about 200 lines of code.


Howard.




                 reply	other threads:[~1993-04-27 16:25 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed
read-only archive

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