2010-05-17 05:00:50     stdarg.h missing compile error on uclinux-dist-07-r1.1-rc3 (toolchain-07R1-9)

Document created by Aaronwu Employee on Aug 21, 2013
Version 1Show Document
  • View in full screen mode

2010-05-17 05:00:50     stdarg.h missing compile error on uclinux-dist-07-r1.1-rc3 (toolchain-07R1-9)

Lan Lamphy (CHINA)

Message: 89482   

 

Hi, all,

 

    I was so confused by the stdarg.h error.

 

//------------------------------------------------------------------------------------------------------

 

Envirments:

 

    1. blackfin-toolchain-07r1-9.i386.rpm

 

    2. uClinux-dist.07R1.1-RC3.tar.bz2

 

    I had installed them step by step by   docs.blackfin.uclinux.org/doku.php?id=toolchain:installing

 

//------------------------------------------------------------------------------------------------------

 

Installation and global variables:

 

  rpm -i blackfin-toolchain-07r1-9.i386.rpm

 

  tar -xzf uClinux-dist.07R1.1-RC3.tar.bz2

 

  export PATH=$PATH: /opt/uClinux/bfin-linux-uclibc/bin: /opt/uClinux/bfin-uclinux/bin   // in .bashrc

 

  under the root permission

 

  I ran the below two commands, and return OK

 

//first, to test bfin-uclinux-gcc

 

  [root@localhost usr]# bfin-uclinux-gcc -v

Using built-in specs.

Target: bfin-uclinux

Configured with: /usr/src/packages/BUILD/blackfin-toolchain-07r1/../gcc-4.1/configure --build=i686-pc-linux-gnu --host=i686-pc-linux-gnu --target=bfin-uclinux --prefix=/opt/uClinux/bfin-uclinux --enable-threads=posix --with-sysroot=/opt/uClinux/bfin-uclinux/bfin-uclinux/runtime --disable-libstdcxx-pch --enable-languages=c,c++ --disable-symvers --disable-libssp --enable-version-specific-runtime-libs --enable-__cxa_atexit

Thread model: posix

gcc version 4.1.1 (ADI 07R1)

 

 

//second, to test bfin-linux-uclibc-gcc

 

[root@localhost voip]# bfin-linux-uclibc-gcc -v

Using built-in specs.

Target: bfin-linux-uclibc

Configured with: /usr/src/packages/BUILD/blackfin-toolchain-07r1/../gcc-4.1/configure --build=i686-pc-linux-gnu --host=i686-pc-linux-gnu --target=bfin-linux-uclibc --prefix=/opt/uClinux/bfin-linux-uclibc --enable-threads=posix --enable-shared --with-sysroot=/opt/uClinux/bfin-linux-uclibc/bfin-linux-uclibc/runtime --disable-libstdcxx-pch --enable-languages=c,c++

--disable-symvers --disable-libssp --enable-version-specific-runtime-libs --enable-__cxa_atexit

Thread model: posix

gcc version 4.1.1 (ADI 07R1)

[root@localhost voip]#

 

 

//Make a simple test of hello world to test gcc compiler

 

They were OK.

 

//------------------------------------------------------------------------------------------------------

 

Rebuild uClinux package error:

 

  on the uClinux folder uClinux-dist.07R1.1-RC3/

 

I ran the following commands:

 

  make clean

 

  make menuconfig    // to select uc-libc

 

  make dep

 

  make

 

  and stdarg.h missing errror encountered:

 

In file included from ../libc/stdio2/printf.c:27:

../libc/include/stdarg.h:3:28: error: machine/stdarg.h: No such file or directory

In file included from ../libc/stdio2/printf.c:34:

../libc/include/stdio.h:125: error: expected declaration specifiers or '...' before 'va_lis

t'

../libc/include/stdio.h:126: error: expected declaration specifiers or '...' before 'va_lis

t'

../libc/include/stdio.h:127: error: expected declaration specifiers or '...' before 'va_lis

t'

../libc/include/stdio.h:129: error: expected declaration specifiers or '...' before 'va_lis

t'

../libc/include/stdio.h:130: error: expected declaration specifiers or '...' before 'va_lis

t'

../libc/include/stdio.h:131: error: expected declaration specifiers or '...' before 'va_lis

t'

../libc/include/stdio.h:132: error: expected declaration specifiers or '...' before 'va_lis

t'

../libc/stdio2/printf.c:36: error: expected declaration specifiers or '...' before 'va_list

'

../libc/stdio2/printf.c: In function 'printf':

../libc/stdio2/printf.c:48: error: 'va_list' undeclared (first use in this function)

../libc/stdio2/printf.c:48: error: (Each undeclared identifier is reported only once

../libc/stdio2/printf.c:48: error: for each function it appears in.)

../libc/stdio2/printf.c:48: error: expected ';' before 'ptr'

../libc/stdio2/printf.c:51: warning: implicit declaration of function 'va_start'

../libc/stdio2/printf.c:51: error: 'ptr' undeclared (first use in this function)

../libc/stdio2/printf.c:52: error: too many arguments to function 'vfnprintf'

../libc/stdio2/printf.c:53: warning: implicit declaration of function 'va_end'

make[2]: *** [printf.o] Error 1

make[2]: Leaving directory `/usr/voip/uClinux-dist.07R1.1-RC3/lib/libm'

make[1]: *** [all] Error 2

make[1]: Leaving directory `/usr/voip/uClinux-dist.07R1.1-RC3/lib'

make: *** [subdirs] Error 1

//------------------------------------------------------------------------------------------------------

 

Problem solving:

 

1. on the blackfin forum: somebody advised that the uclibc was not installed, But I didn't find any sperate uclibc package for 07R1-9 toolchain. Where to get? And how to check exist or not?

 

2. on the blackfin forum: somebody advised me to read toolchain release note.pdf carefully, And I haven't seen any helpful information.

 

3. on the blackfin forum: somebody told the the version were mismatched on toolchain and uClinux package, is right?

 

How to do next step?

 

4. I found there are many FAQs about the uclibc problems, but I have never found successful case. Why?

 

Lamphy

QuoteReplyEditDelete

 

 

2010-05-17 13:58:43     Re: stdarg.h missing compile error on uclinux-dist-07-r1.1-rc3 (toolchain-07R1-9)

Robin Getz (UNITED STATES)

Message: 89485   

 

Lan:

 

Please upgrade to a recent toolchain. Install instructions are found at:

 

https://docs.blackfin.uclinux.org/doku.php?id=toolchain:installing

 

-Robin

QuoteReplyEditDelete

Attachments

    Outcomes