I have a problem!!

Alvin Fortson AFortson@thepantry.com
Mon Nov 15 15:01:00 GMT 1999


I just install gcc version 2.95 on my SCO 5.0.5a system.  I have written a
simple program and get the following error message in the stdin.h file.  I'm
not sure if I have asetup issue or a coding issue.  Could you tell me what
is wrong

Error Message

In file included from test.c:1:                                    
/RMS/PANTRYSCRIPTS/stdio.h:140: parse error before `__gnuc_va_list'
/RMS/PANTRYSCRIPTS/stdio.h:140: parse error before `__gnuc_va_list'
/RMS/PANTRYSCRIPTS/stdio.h:140: parse error before `__gnuc_va_list'



Code
###########

#include </RMS/PANTRYSCRIPTS/stdio.h>                                       
main ()                                                                     
{                                                                           
        char in_name[25], out_name[25];                                     
        int c;                                                              
        int cnt;                                                            
        FILE *in_file, *out_file, *fopen();                                 
        in_file = fopen(in_name, "r");                                      
        if ( in_file == NULL )                                              
                printf ("Couldn't  open %s for reading,\n", in_name);       
        else                                                                
        {                                                                   
                out_file = fopen (out_name, "w");                           
                if ( out_file == NULL )                                     
                        printf ("Couldn't  open %s for writing,\n", out_name
                else                                                        
                {                                                           
                        while ( ( c = getc(in_file)) != EOF)                
                        {                                                   
                                putc ( c, out_file);                        
                        }                                                   
                        printf ("File has been copied.\n");                 
                }                                                           
        }                                                                   
}

##################

Thanks,

Alvin Fortson
                                                                           


More information about the Libc-alpha mailing list