[freetds] VMS decc FreeTDS compilation question

Craig Berry craigberry at mac.com
Mon Oct 13 16:47:05 EDT 2003


 
On Monday, October 13, 2003, at 03:06PM, Patrick Spinler <pspinler at yahoo.com> wrote:

>
>I'm trying to compile a sybase client C program using Compaq C V6.4-005 
>on OpenVMS Alpha V7.3-1 against FreeTDS 0.61_2 downloaded from 
><http://www.freetds.org>.  We're trying to use it to replace the no 
>longer valid sybase openclient for openvms.

It's ancient (10.0.4?) and now unsupported; is that what you mean by "no longer valid"?  I'm pretty sure I built DBD::Sybase against it in the last year or two, though.  Still, FreeTDS is a good migration path.

>When I compile a program, I'm getting errors like the following (please 
>forgive line wrapping):
>
>-------------------------
>cc /decc tsslistener  -
>/STAND=VAXC/FLOAT=IEEE_FLOAT/WARNING=(DISABLE=(LONGEXTERN,MISSINGRETURN,PROTOSCOPE))-
>/INCLUDE=(CTS_PROGRAMMER:[PSPINLER.SRC.FREETDS.FREETDS-0_61_2.INCLUDE],CTS:[SOURCE.INCLUDE])

>openClientStatus=ct_con_props(pConnection,CS_SET,CS_USERNAME,gpTSSListenerUsername,CS_NULLTERM,NULL);
>.....................................................^
>%CC-E-BADMCRORECURS, Recursive expansion of macro "CS_USERNAME" exceeded 
>1024 levels and was terminated.
>at line number 664 in file CTS:[SOURCE.CPP.TSS_LISTENER]TSSLISTENER.C;5

I suggest doing a test compile of cspublic.h with variations on your compiler options.  In particular, /STANDARD=VAXC is to be avoided wherever possible and in some simple testing of my own seems to be the direct cause of your problem.  

Try this:

$ set default [.include]
$ cc/include=([-],[])/noobj/standard=vaxc cspublic.h

Then try it again after removing the /standard=vaxc.  The vaxc option is only there for code that predates the C89 standard and that has some really good reason not to have been touched in the last decade.

You'll also need to use options compatible with those used to build FreeTDS, which (unless you've hacked the descrip.mms yourself) means /NAMES=AS_IS.  Good luck and let me know how it goes.





More information about the FreeTDS mailing list