[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Building NETCDF on VMS



Hi Kevin!

>Date: Wed, 17 Dec 1997 17:29:10 -0500 
>From: address@hidden
>Organization: Nova University
>To: address@hidden
>Subject: Building NETCDF on VMS 
>Keywords: 199712172229.PAA13382 

In the above message, you wrote:

> Hi Steve,
> 
> Sorry if the following is a bit wordy...

No prob.

> 
> About a year and a half ago, I was involved in
> trying to port NETCDF to Alpha VMS (incidentally,
> with no success). I contacted Angel Li at RSMAS
> who was also port a version (2.4, I believe), but
> on a slightly different system.
> 
> Well, enough background...
> 
> I'm now once again trying my hand at porting
> NETCDF to Alpha VMS 6.21h-3. I downloaded the file
> 
> VMS-2.4.3beta.tar.Z
> 
> from the ftp archives at ucar, and
> began to reassemble things. First off, are binaries
> and/or libraries directly available for Alpha VMS 6.2?

Such binaries are not available from us as we don't have a VMS system
in-house.  Someone else might, however.  Have you tried the netcdfgroup
mailing-list?

> 
> If not...
> 
> I began by running makevms.com in the [.xdr] 
> directory. In looking at makevms.com, it seems to have
> more Alpha oriented stuff, which theoretically should
> be to my benefit. However, my first stumbling block is
> the following:
> 
> in xdrtest.c, it needs the file 
> 
> include <ucx$rpcxdr.h>
> 
> I apparently don't have this file. Is this related
> to DEC's UCX TCPIP stack for VMS?

Yes.

> We run Multinet
> instead of UCX here, so that might account for the 
> lack of this file.  Multinet does have a
> [.include.rpc]xdr.h file (and also a xdr_vax.h file).
> Is there any way to know if this file is a suitable
> substitute? 

I think the only way to determine if the header-file is suitable or not
is by trying it -- though looking at it might help.  The "xdr.h" file
should contain things like the following (among a lot of other things):

    enum xdr_op {
            XDR_ENCODE=0,
            XDR_DECODE=1,
            XDR_FREE=2
    };

    typedef struct XDR {
            enum xdr_op x_op;           /* operation; fast additional param */
            struct xdr_ops {
                    bool_t      (*x_getlong) __((struct XDR *,  int *));        
/* get an int from 
underlying stream */
                    bool_t      (*x_putlong) __((struct XDR *,  int *));        
/* put an int to " */
                    bool_t      (*x_getbytes) __((struct XDR *, caddr_t, int)); 
/* get some bytes 
from " */
                    bool_t      (*x_putbytes) __((struct XDR *, caddr_t, int)); 
/* put some bytes 
to " */
                    u_int       (*x_getpostn) __((struct XDR *));               
/* returns bytes off from 
beginning */
                    bool_t  (*x_setpostn) __((struct XDR *, u_int));    /* lets 
you reposition 
the stream */
                    int *       (*x_inline) __((struct XDR *, int));            
/* buf quick ptr to buffered 
data */
                    void        (*x_destroy) __((struct XDR *));                
/* free privates of this 
xdr_stream */
            } *x_ops;
            caddr_t     x_public;       /* users' data */
            caddr_t             x_private;      /* pointer to private data */
            caddr_t     x_base;         /* private used for position info */
            int         x_handy;        /* extra private word */
    } XDR;

    typedef     bool_t (*xdrproc_t) __((XDR *, caddr_t *, ...));

    #define XDR_GETLONG(xdrs, intp)                             \
            (*(xdrs)->x_ops->x_getlong)(xdrs, intp)
    #define xdr_getlong(xdrs, intp)                             \
            (*(xdrs)->x_ops->x_getlong)(xdrs, intp)

    extern bool_t       xdr_void ();
    extern bool_t       xdr_int __((XDR *, int *));

> 
> If it is a suitable substitute, do you know what
> library I'd place it into? (Hopefully, you know more
> VMS than I know C ;-)

I've fogotten almost all my VMS!  

You can modify the "#include <>" directive in the file to reference the
header-file directly, e.g.

    #include <xdr.h>

then set the appropriate option on the compilation command-line to
reference the directory that contains "xdr.h".

> 
> Some of the choices on our system seem to be:
> 
> DECC$RTLDEF.TLB;2
> SYS$LIB_C.TLB;2
> SYS$STARLET_C.TLB;3

I wouldn't add it to a text library but would rather modify the command
line to reference the containing directory or text library.

> 
> Anyway, it looks like more work has been put into
> the build of NETCDF on Alpha VMS from your end. 
> Hopefully, I can take advantage of this. 
> 
> Thanks in advance for any suggestions.

I'd recommend the netCDF 3 distribution rather than the netCDF 2 one.
It's a better implementation.  Unfortunately, we've put no work into
porting it to VMS.  You might try the newsgroup.

> 
> -Kevin
> 
> ---------------------------------------------------
> Kevin E. Kohler   <address@hidden>   
> Senior Programmer/Coordinator of Computing Services
> Nova Southeastern University Oceanographic Center  
> 8000 North Ocean Drive  Dania, Florida  33004      
> Ph:  954.920.1909    Fax: 954.921.7764
> ---------------------------------------------------

Are you still playing the accordion?

--------
Steve Emmerson   <http://www.unidata.ucar.edu>