RE: Compilation of dostats.ec
Posted in 1999
After poking and prodding the $INFORMIXDIR/bin/esql script file, and looking at the man pages for "cc", I found that setting (and exporting, of course) the environment variable CCOPTS="-Ae" works like a charm! This is on HPUX 10.20, w/ ESQL/C version 7.24.UC8A. I can simply set CCOPTS in my .profile, so I don't have to fiddle around inside the esql script. BTW, the "e" option is for "extended ANSI". HTH ================================ Paul A. Mosser, Open Systems DBA Informix Certified DBSA Wells Fargo & Co. Tempe, Arizona paul.mosser@wellsfargo.com ================================ -----Original Message----- From: Eric_Melillo@agsea.com [mailto:Eric_Melillo@agsea.com] Sent: Tuesday, June 22, 1999 5:35 AM To: kagel@bloomberg.net Cc: informix-list@iiug.org Subject: Re: Compilation of dostats.ec Thanks for cross posting it here Art -- Since I use the listserv... I sometimes forget to reply to "All" which would include the list - not just the original sender. Just a correction -- The flag sequence is "-Aa" -Amode Specify the compilation standard to be used by the compiler. mode can be one of the following letters: c (Default) Compile in a mode compatible with HP-UX releases prior to 7.0. (See The C Programming Language, First Edition by Kernighan and Ritchie). This option also defines the symbol _HPUX_SOURCE and allows the user to access macros and typedefs provided by the HPUX Operating System. The default compilation mode may change in future releases. a Compile under ANSI mode (ANSI programming language C standard ISO 9899:1990). When compiling under ANSI mode, the header files would define only those names (macros and typedefs) specified by the Standard. To access macros and typedefs that are not defined by the ANSI Standard but are provided by the HPUX Operating System, define the symbol _HPUX_SOURCE; or use the extension option described below. Eric P. Melillo Sr. Database Administrator Associated Grocers, Inc. 3301 South Norfolk Seattle, WA 98118 vmail: (206) 767-8178 email: eric_melillo@agsea.com "Art S. Kagel" <kagel@bloomberg.net> on 06/17/99 01:28:41 PM Please respond to kagel@bloomberg.net To: informix-list@iiug.org cc: (bcc: Eric Melillo/AGInc) Subject: Re: Compilation of dostats.ec The HP compiler does not recognize ANSI syntax by default. There is a flag you need to add. Someone sent the required flag, so I am posting for all. You have to pass the -aA flag to cc. It is best to edit $INFORMIXDIR/bin/esql and add this there for all compiles since it cannot hurt K&R source programs. Art S. Kagel Chris.West@medas.co.uk wrote: > > Art, > > I've attempted to compile dostats.ec under I4GL 7.20, but receive the > following error message ... > > 'cc: "dostats.ec", line 181: error 1705: Function prototypes are an ANSI > feature.' > > Which I assume is related to the C compiler HP/UX 10.20 uses. Any > suggestions? > > Chris > > "Art S. Kagel" <kagel@bloomberg.net> on 16/06/99 19:35:14 > > Please respond to kagel@bloomberg.net > > To: informix-list@iiug.org > cc: (bcc: Chris West/Finance/MEDAS) > > Subject: Re: Compilation of dostats.ec > > Willaert Doris wrote: > > > > I have downloaded the dostats program from the IIUG website. I see that > this > > program has to be compiled by ESQL/C 7.xx. > > Can I compile this program without ESQL. On my system I just have 4GL > 7.20. > > Hi Willaert, 4GL 7.xx will do just fine. It was not out yet when I > first posted the README and I have neglected to change it. I4GL 6.xx > was not able to compile dostats.ec but I4GL 7.20 certainly is. > > Just use: > > c4gl -o dostats dostats.ec > > Art S. Kagel