percona server 5.7 build failed on mac osx
cmake -DWITH_BOOST=/opt/boost ~/Documents/work/xzy/percona-server/ -DWITHOUT_TOKUDB=1 -DCMAKE_INSTALL_PREFIX=/opt/percona-server-5.7 -DBUILD_CONFIG=mysql_release
.....
[ 0%] Building C object strings/CMakeFiles/strings.dir/bchange.c.o
In file included from /Users/xiezhenye/Documents/work/xzy/percona-server/strings/bchange.c:27:
/Users/xiezhenye/Documents/work/xzy/percona-server/include/my_global.h:672:3: error: unknown type name 'FILETIME'
FILETIME ft;
^
/Users/xiezhenye/Documents/work/xzy/percona-server/include/my_global.h:673:3: error: unknown type name '__int64'
__int64 i64;
^
/Users/xiezhenye/Documents/work/xzy/percona-server/include/my_global.h:676:8: error: redefinition of 'timespec'
struct timespec {
^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk/usr/include/sys/_types/_timespec.h:30:1: note: previous
definition is here
_STRUCT_TIMESPEC
^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk/usr/include/sys/_types/_timespec.h:29:33: note: expanded
from macro '_STRUCT_TIMESPEC'
#define _STRUCT_TIMESPEC struct timespec
^
In file included from /Users/xiezhenye/Documents/work/xzy/percona-server/strings/bchange.c:27:
/Users/xiezhenye/Documents/work/xzy/percona-server/include/my_global.h:702:3: warning: implicit declaration of function 'GetSystemTimeAsFileTime' is invalid
in C99 [-Wimplicit-function-declaration]
GetSystemTimeAsFileTime(&tv.ft);
^
/Users/xiezhenye/Documents/work/xzy/percona-server/include/my_global.h:703:12: error: no member named 'tv' in 'struct timespec'
abstime->tv.i64= tv.i64 + (__int64)(nsec / 100);
~~~~~~~ ^
/Users/xiezhenye/Documents/work/xzy/percona-server/include/my_global.h:703:38: error: called object type '<dependent type>' is not a function or function
pointer
abstime->tv.i64= tv.i64 + (__int64)(nsec / 100);
~~~~~~~~~^
/Users/xiezhenye/Documents/work/xzy/percona-server/include/my_global.h:708:12: error: no member named 'max_timeout_msec' in 'struct timespec'
abstime->max_timeout_msec= (long)max_timeout_msec;
~~~~~~~ ^
/Users/xiezhenye/Documents/work/xzy/percona-server/include/my_global.h:734:12: error: no member named 'tv' in 'struct timespec'
if (ts1->tv.i64 > ts2->tv.i64)
~~~ ^
/Users/xiezhenye/Documents/work/xzy/percona-server/include/my_global.h:734:26: error: no member named 'tv' in 'struct timespec'
if (ts1->tv.i64 > ts2->tv.i64)
~~~ ^
/Users/xiezhenye/Documents/work/xzy/percona-server/include/my_global.h:736:12: error: no member named 'tv' in 'struct timespec'
if (ts1->tv.i64 < ts2->tv.i64)
~~~ ^
/Users/xiezhenye/Documents/work/xzy/percona-server/include/my_global.h:736:26: error: no member named 'tv' in 'struct timespec'
if (ts1->tv.i64 < ts2->tv.i64)
~~~ ^
/Users/xiezhenye/Documents/work/xzy/percona-server/include/my_global.h:748:16: error: no member named 'tv' in 'struct timespec'
return (ts1->tv.i64 - ts2->tv.i64) * 100;
~~~ ^
/Users/xiezhenye/Documents/work/xzy/percona-server/include/my_global.h:748:30: error: no member named 'tv' in 'struct timespec'
return (ts1->tv.i64 - ts2->tv.i64) * 100;
~~~ ^
1 warning and 12 errors generated.
make[2]: *** [strings/CMakeFiles/strings.dir/bchange.c.o] Error 1
make[1]: *** [strings/CMakeFiles/strings.dir/all] Error 2
.....
I am able to build it on Mac OS X. Can you post full cmake output and build log with make VERBOSE=1 ?