You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
k-means/k-means$ make
gcc -c -w -D_LARGEFILE_SOURCE -D_ANSI_SOURCE -std=c99 -Wall -Wextra -pedantic -O3 -DNDEBUG gettimeofday.c -o gettimeofday.o
gettimeofday.c:35:31: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘epoch’
static const unsigned __int64 epoch = UINT64CONST(116444736000000000);
^
gettimeofday.c:44:1: error: conflicting types for ‘gettimeofday’
gettimeofday(struct timeval * tp, struct timezone * tzp)
^
In file included from gettimeofday.c:31:0:
/usr/include/x86_64-linux-gnu/sys/time.h:71:12: note: previous declaration of ‘gettimeofday’ was here
extern int gettimeofday (struct timeval *__restrict __tv,
^
gettimeofday.c: In function ‘gettimeofday’:
gettimeofday.c:46:5: error: unknown type name ‘FILETIME’
FILETIME file_time;
^
gettimeofday.c:47:5: error: unknown type name ‘SYSTEMTIME’
SYSTEMTIME system_time;
^
gettimeofday.c:48:5: error: unknown type name ‘ULARGE_INTEGER’
ULARGE_INTEGER ularge;
^
gettimeofday.c:52:11: error: request for member ‘LowPart’ in something not a structure or union
ularge.LowPart = file_time.dwLowDateTime;
^
gettimeofday.c:52:31: error: request for member ‘dwLowDateTime’ in something not a structure or union
ularge.LowPart = file_time.dwLowDateTime;
^
gettimeofday.c:53:11: error: request for member ‘HighPart’ in something not a structure or union
ularge.HighPart = file_time.dwHighDateTime;
^
gettimeofday.c:53:32: error: request for member ‘dwHighDateTime’ in something not a structure or union
ularge.HighPart = file_time.dwHighDateTime;
^
gettimeofday.c:55:33: error: request for member ‘QuadPart’ in something not a structure or union
tp->tv_sec = (long) ((ularge.QuadPart - epoch) / 10000000L);
^
gettimeofday.c:55:45: error: ‘epoch’ undeclared (first use in this function)
tp->tv_sec = (long) ((ularge.QuadPart - epoch) / 10000000L);
^
gettimeofday.c:55:45: note: each undeclared identifier is reported only once for each function it appears in
gettimeofday.c:56:38: error: request for member ‘wMilliseconds’ in something not a structure or union
tp->tv_usec = (long) (system_time.wMilliseconds * 1000);
^
Makefile:18: recipe for target 'gettimeofday.o' failed
make: *** [gettimeofday.o] Error 1
The text was updated successfully, but these errors were encountered:
k-means/k-means$ make
gcc -c -w -D_LARGEFILE_SOURCE -D_ANSI_SOURCE -std=c99 -Wall -Wextra -pedantic -O3 -DNDEBUG gettimeofday.c -o gettimeofday.o
gettimeofday.c:35:31: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘epoch’
static const unsigned __int64 epoch = UINT64CONST(116444736000000000);
^
gettimeofday.c:44:1: error: conflicting types for ‘gettimeofday’
gettimeofday(struct timeval * tp, struct timezone * tzp)
^
In file included from gettimeofday.c:31:0:
/usr/include/x86_64-linux-gnu/sys/time.h:71:12: note: previous declaration of ‘gettimeofday’ was here
extern int gettimeofday (struct timeval *__restrict __tv,
^
gettimeofday.c: In function ‘gettimeofday’:
gettimeofday.c:46:5: error: unknown type name ‘FILETIME’
FILETIME file_time;
^
gettimeofday.c:47:5: error: unknown type name ‘SYSTEMTIME’
SYSTEMTIME system_time;
^
gettimeofday.c:48:5: error: unknown type name ‘ULARGE_INTEGER’
ULARGE_INTEGER ularge;
^
gettimeofday.c:52:11: error: request for member ‘LowPart’ in something not a structure or union
ularge.LowPart = file_time.dwLowDateTime;
^
gettimeofday.c:52:31: error: request for member ‘dwLowDateTime’ in something not a structure or union
ularge.LowPart = file_time.dwLowDateTime;
^
gettimeofday.c:53:11: error: request for member ‘HighPart’ in something not a structure or union
ularge.HighPart = file_time.dwHighDateTime;
^
gettimeofday.c:53:32: error: request for member ‘dwHighDateTime’ in something not a structure or union
ularge.HighPart = file_time.dwHighDateTime;
^
gettimeofday.c:55:33: error: request for member ‘QuadPart’ in something not a structure or union
tp->tv_sec = (long) ((ularge.QuadPart - epoch) / 10000000L);
^
gettimeofday.c:55:45: error: ‘epoch’ undeclared (first use in this function)
tp->tv_sec = (long) ((ularge.QuadPart - epoch) / 10000000L);
^
gettimeofday.c:55:45: note: each undeclared identifier is reported only once for each function it appears in
gettimeofday.c:56:38: error: request for member ‘wMilliseconds’ in something not a structure or union
tp->tv_usec = (long) (system_time.wMilliseconds * 1000);
^
Makefile:18: recipe for target 'gettimeofday.o' failed
make: *** [gettimeofday.o] Error 1
The text was updated successfully, but these errors were encountered: