Thread: Compilation error under Unix with GCC

  1. #1
    Registered User
    Join Date
    Jun 2005
    Posts
    3

    Question Compilation error under Unix with GCC

    Hi there,

    I'm getting the following error when compiling a C program under Unix using the GCC compiler via a Makefile.

    wvc_stream.c: In function `STREAM_Printf':
    wvc_stream.c:131: `__builtin_va_alist' undeclared (first use in this function)
    wvc_stream.c:131: (Each undeclared identifier is reported only once
    wvc_stream.c:131: for each function it appears in.)

    I did a search on google and this seems to be a frequent problem, perhaps related to an incorrect installation of GCC (notably an incorrect stdarg.h header file), but I've not been able to find a definitive solution.

    Anyone have any information on this?

    Thanks!

    Marcus

  2. #2
    ---
    Join Date
    May 2004
    Posts
    1,379
    It looks like it's not linking properly.

  3. #3
    Registered User
    Join Date
    Jun 2005
    Posts
    3
    Thanks, have managed to resolve the problem.

    It was caused by an old/incorrect version of stdarg.h in the /usr/include directory.

    I copied in a newer version of this file that I found under version 3.2.3 of GCC and the program compiled fine.


Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Profiler Valgrind
    By afflictedd2 in forum C++ Programming
    Replies: 4
    Last Post: 07-18-2008, 09:38 AM
  2. How to program in unix
    By Cpro in forum Linux Programming
    Replies: 21
    Last Post: 02-12-2008, 10:54 AM
  3. Replies: 4
    Last Post: 09-02-2007, 08:47 PM
  4. gcc
    By DavidP in forum A Brief History of Cprogramming.com
    Replies: 21
    Last Post: 10-22-2003, 03:46 PM
  5. Compiling error using GCC in Unix
    By csmatheng in forum C Programming
    Replies: 9
    Last Post: 09-08-2002, 05:49 PM