Hello,

        I'm trying to build the AppPkg on Ubuntu 12.04 using the
native installed complier.  GCC4.6 fails with the following message:

/UDK2010.SR1/StdLib/LibC/Uefi/SysCalls.c: In function ‘utimes’:
/UDK2010.SR1/StdLib/LibC/Uefi/SysCalls.c:1250:11: error: ‘va_start’ used 
in function with fixed args

        Apparently, the utimes() function in SysCalls.c is using a bad form of 
va_list.  It is attempting to create a fake va_list to pass on
to the kernel.  GCC expects the utimes() to have a variadic input.
        
int
utimes(
   const char *path,
   const struct timeval *times
   )
{
   struct __filedes   *filp;
   va_list             ap;
   int                 fd;
   int                 retval  = -1;

   va_start(ap, path);
   fd = open(path, O_RDWR, 0);
   if(fd >= 0) {
     filp = &gMD->fdarray[fd];
     retval = filp->f_ops->fo_ioctl( filp, FIOSETIME, ap);
     close(fd);
   }
   va_end(ap);
   return retval;

}

        To my knowledge, the only way to fix this is to have utimes() call a 
fake variadic function that finally calls the kernel.


Thanks,

Stephen



------------------------------------------------------------------------------
Keep yourself connected to Go Parallel: 
BUILD Helping you discover the best ways to construct your parallel projects.
http://goparallel.sourceforge.net
_______________________________________________
edk2-devel mailing list
edk2-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/edk2-devel

Reply via email to