Re: Compiling ncl/ncar graphics on OpenSolaris

From: Mary Haley <haley_at_nyahnyahspammersnyahnyah>
Date: Thu Jul 29 2010 - 16:44:12 MDT

Hi Richard,

This looks like an issue with HDF4 and not NCAR Graphics. What version of HDF4 did you install, and did you use the same compiler to build it?

Near line 401 in our version of the HDF "hproto.h" file, we have:

#if defined VMS || defined macintosh || defined MAC || defined SYMANTEC_C || defined MIPSEL || defined NEXT || defined CONVEX || defined IBM6000 || defined SUN || defined IRIX
    HDFPUBLIC extern char *HDstrdup
                (const char *s);

#endif

I wonder if you try a test and remove the "|| defined SUN" from this line, and type "make" in the /export/home/richard/src/ncarg/ncl_ncarg-5.2.1/ncarview/src/lib/libncarg_ras directory, does it work?

You might want to check with the HDF4 folks about this hproto.h file, and what they recommend to get it to work on an OpenSolaris system.

--Mary

On Jul 29, 2010, at 12:32 PM, Richard Jacobsen wrote:

> Hello,
>
> I'm trying to get ncl/ncarg compiling on OpenSolaris 2009.06. I've had the best luck with the Sun4Solaris target, but I'm getting one error:
>
> cc -Xt -D_FILE_OFFSET_BITS=64 -O -I../../../.././include -I/usr/openwin/include -I/usr/include -I/usr/local/include -DBuildRasterHDF -DSUN -DBuildRasterHPPCL -DBuildRasterNrif -DBuildRasterSun -DBuildRasterXWD -DBuildRasterAVS -DBuildRasterSGI -DBuildRasterAbekas -DBuildRasterBinary -DBuildRasterYUV -DNGTMPDIR='"tmp"' -DPC -DSUN -DSYSV -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED=1 -D__EXTENSIONS__ -DNeedFuncProto -c hdf.c
> "/usr/local/include/hdf/hproto.h", line 401: syntax error before or at: char
> "/usr/local/include/hdf/hproto.h", line 401: function cannot return function or array
> "/usr/local/include/hdf/hproto.h", line 401: warning: old-style declaration or incorrect type for: strdup
> "/usr/local/include/hdf/hproto.h", line 401: identifier redeclared: strdup
> current : function() returning int
> previous: function(pointer to const char) returning pointer to char : "/usr/include/string.h", line 107
> "/usr/local/include/hdf/hproto.h", line 401: syntax error before or at: )
> "/usr/local/include/hdf/hproto.h", line 402: warning: syntax error: empty declaration
> cc: acomp failed for hdf.c
> *** Error code 1
> make: Fatal error: Command failed for target `hdf.o'
> Current working directory /export/home/richard/src/ncarg/ncl_ncarg-5.2.1/ncarview/src/lib/libncarg_ras
> *** Error code 1
> The following command caused the error:
> for dir in libcgm libncarg_ras libctrans libictrans ; do \
> if (test -d $dir) then \
> (cd $dir; echo "Making ./ncarview/src/lib/$dir";\
> make );sleep 1;\
> else echo "NOT Making ./ncarview/src/lib/$dir"; fi \
> done
> make: Fatal error: Command failed for target `makesubdirs'
>
> Attached are my make-output from make Everything, Site.local, and SolarisPC (copied Sun4Solaris target)
>
> When I tried the autodetected SolarisPC target, I had an early compile error saying that it couldn't find libc.
>
> Has anyone succesfully compiled on Opensolaris?
>
> Thanks,
> Richard
> <make-output.txt><Site.local><SolarisPC.txt>_______________________________________________
> ncarg-talk mailing list
> ncarg-talk@ucar.edu
> http://mailman.ucar.edu/mailman/listinfo/ncarg-talk

_______________________________________________
ncarg-talk mailing list
ncarg-talk@ucar.edu
http://mailman.ucar.edu/mailman/listinfo/ncarg-talk
Received on Thu Jul 29 16:44:15 2010

This archive was generated by hypermail 2.1.8 : Fri Oct 15 2010 - 10:40:25 MDT