This is the mail archive of the
newlib@sourceware.org
mailing list for the newlib project.
timeval.h bug
- From: Mihail Feraru <mihailferaru2000 at gmail dot com>
- To: newlib at sourceware dot org
- Date: Thu, 28 Apr 2016 18:20:53 +0300
- Subject: timeval.h bug
- Authentication-results: sourceware.org; auth=none
I was trying to compile Newlib for my OS and I got following error:
In file included from
/home/littlewho/Desktop/sourcecode/photon/devel/src/newlib/newlib/libc/include/sys/time.h:42:0,
from ../../../../../newlib/newlib/libc/time/time.c:38:
/home/littlewho/Desktop/sourcecode/photon/devel/src/newlib/newlib/libc/include/sys/_timeval.h:51:1:
error: expected '=', ',', ';', 'asm' or '__attribute__' before
'struct'
struct timeval {
^
I added ; before struct timeval and now works fine, but I am sure that
; should be in another place. I also got some warnings that are not
related to timeval.h error:
../../../../../newlib/newlib/libc/stdlib/aligned_alloc.c: In function
'aligned_alloc':
../../../../../newlib/newlib/libc/stdlib/aligned_alloc.c:35:10:
warning: implicit declaration of function 'posix_memalign'
[-Wimplicit-function-declaration]
error = posix_memalign(&p, alignment, size);
^
../../../../../newlib/newlib/libc/stdlib/quick_exit.c: In function 'quick_exit':
../../../../../newlib/newlib/libc/stdlib/quick_exit.c:80:2: warning:
implicit declaration of function '_exit'
[-Wimplicit-function-declaration]
_exit(status);
^
../../../../../newlib/newlib/libc/stdlib/quick_exit.c:81:1: warning:
'noreturn' function does return
}
^
Makefile:1920: warning: overriding recipe for target 'lib_a-vfwscanf.o'
Makefile:1622: warning: ignoring old recipe for target 'lib_a-vfwscanf.o'
../../../../../newlib/newlib/libc/string/gnu_basename.c: In function
'__gnu_basename':
../../../../../newlib/newlib/libc/string/gnu_basename.c:23:10:
warning: return discards 'const' qualifier from pointer target type
[-Wdiscarded-qualifiers]
return path;
^
I hope that I helped you!
Regards!