<div dir="ltr">cmake ..  <br>give the same error</div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Jul 28, 2016 at 12:49 PM, Meir Yanovich <span dir="ltr"><<a href="mailto:meiry242@gmail.com" target="_blank">meiry242@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hello <br>i try to compile lws + libuv on MAC but im getting compilation errors <br>the libuv compiled just fine : <div>







<p><span>meirs-Mac-mini:lib meiryanovich$ file libuv.1.dylib <br></span>libuv.1.dylib: Mach-O 64-bit dynamically linked shared library x86_64</p><p>using cmake 3.1 <br></p><p>OSX el capitan 10.11.4 (15E65)</p><p><span>cc --version<br></span>Apple LLVM version 7.3.0 (clang-703.0.31)<br>Target: x86_64-apple-darwin15.4.0<br>Thread model: posix</p><p>The command i run with cmake :<br>







</p><p><span>cmake .. -DLWS_WITH_LIBUV=ON -DLWS_LIBUV_LIBRARIES="/Users/meiryanovich/Documents/ws_game_server/libs/libuv/lib" -DLWS_LIBUV_INCLUDE_DIRS="/Users/meiryanovich/Documents/ws_game_server/libs/libuv/libuv-1.x/include" -DLIB_SUFFIX=64</span></p><p><span>output :<br>







</span></p><p><span>-- The C compiler identification is AppleClang 7.3.0.7030031</span></p><p><span>-- Check for working C compiler: /usr/bin/cc</span></p><p><span>-- Check for working C compiler: /usr/bin/cc -- works</span></p><p><span>-- Detecting C compiler ABI info</span></p><p><span>-- Detecting C compiler ABI info - done</span></p><p><span>-- CMAKE_TOOLCHAIN_FILE=''</span></p><p><span>-- Found Git: /usr/bin/git  </span></p><p><span>fatal: Not a git repository (or any of the parent directories): .git</span></p><p><span>Git commit hash: meiryanovich@meirs-Mac-mini.local-</span></p><p><span>-- Performing Test LWS_HAVE_inline</span></p><p><span>-- Performing Test LWS_HAVE_inline - Success</span></p><p><span>-- Performing Test LWS_HAVE___inline__</span></p><p><span>-- Performing Test LWS_HAVE___inline__ - Success</span></p><p><span>-- Performing Test LWS_HAVE___inline</span></p><p><span>-- Performing Test LWS_HAVE___inline - Success</span></p><p><span>-- Looking for bzero</span></p><p><span>-- Looking for bzero - found</span></p><p><span>-- Looking for fork</span></p><p><span>-- Looking for fork - found</span></p><p><span>-- Looking for getenv</span></p><p><span>-- Looking for getenv - found</span></p><p><span>-- Looking for malloc</span></p><p><span>-- Looking for malloc - found</span></p><p><span>-- Looking for memset</span></p><p><span>-- Looking for memset - found</span></p><p><span>-- Looking for realloc</span></p><p><span>-- Looking for realloc - found</span></p><p><span>-- Looking for socket</span></p><p><span>-- Looking for socket - found</span></p><p><span>-- Looking for strerror</span></p><p><span>-- Looking for strerror - found</span></p><p><span>-- Looking for vfork</span></p><p><span>-- Looking for vfork - found</span></p><p><span>-- Looking for execvpe</span></p><p><span>-- Looking for execvpe - not found</span></p><p><span>-- Looking for getifaddrs</span></p><p><span>-- Looking for getifaddrs - found</span></p><p><span>-- Looking for snprintf</span></p><p><span>-- Looking for snprintf - found</span></p><p><span>-- Looking for _snprintf</span></p><p><span>-- Looking for _snprintf - not found</span></p><p><span>-- Looking for _vsnprintf</span></p><p><span>-- Looking for _vsnprintf - not found</span></p><p><span>-- Looking for getloadavg</span></p><p><span>-- Looking for getloadavg - found</span></p><p><span>-- Looking for dlfcn.h</span></p><p><span>-- Looking for dlfcn.h - found</span></p><p><span>-- Looking for fcntl.h</span></p><p><span>-- Looking for fcntl.h - found</span></p><p><span>-- Looking for in6addr.h</span></p><p><span>-- Looking for in6addr.h - not found</span></p><p><span>-- Looking for inttypes.h</span></p><p><span>-- Looking for inttypes.h - found</span></p><p><span>-- Looking for memory.h</span></p><p><span>-- Looking for memory.h - found</span></p><p><span>-- Looking for netinet/in.h</span></p><p><span>-- Looking for netinet/in.h - found</span></p><p><span>-- Looking for stdint.h</span></p><p><span>-- Looking for stdint.h - found</span></p><p><span>-- Looking for stdlib.h</span></p><p><span>-- Looking for stdlib.h - found</span></p><p><span>-- Looking for strings.h</span></p><p><span>-- Looking for strings.h - found</span></p><p><span>-- Looking for string.h</span></p><p><span>-- Looking for string.h - found</span></p><p><span>-- Looking for sys/prctl.h</span></p><p><span>-- Looking for sys/prctl.h - not found</span></p><p><span>-- Looking for sys/socket.h</span></p><p><span>-- Looking for sys/socket.h - found</span></p><p><span>-- Looking for sys/stat.h</span></p><p><span>-- Looking for sys/stat.h - found</span></p><p><span>-- Looking for sys/types.h</span></p><p><span>-- Looking for sys/types.h - found</span></p><p><span>-- Looking for unistd.h</span></p><p><span>-- Looking for unistd.h - found</span></p><p><span>-- Looking for vfork.h</span></p><p><span>-- Looking for vfork.h - not found</span></p><p><span>-- Looking for zlib.h</span></p><p><span>-- Looking for zlib.h - found</span></p><p><span>-- Looking for 4 include files stdlib.h, ..., float.h</span></p><p><span>-- Looking for 4 include files stdlib.h, ..., float.h - found</span></p><p><span>-- Performing Test LWS_HAVE_VISIBILITY</span></p><p><span>-- Performing Test LWS_HAVE_VISIBILITY - Success</span></p><p><span>CMake Error at CMakeLists.txt:676 (if):</span></p><p><span>  if given arguments:</span></p><p><span></span><br></p><p><span>    "UNIX" "||" "LWS_WITH_ESP8266"</span></p><p><span></span><br></p><p><span>  Unknown arguments specified</span></p><p><span>
























































































</span></p><p><span></span><br></p><p><br></p><p><span><br></span></p><p><span><br></span></p><p><span>Error log :<br></span></p><p>Determining if the function execvpe exists failed with the following output:</p><p>Change Dir: /Users/meiryanovich/Documents/ws_game_server/libs/libwebsockets/libwebsockets-master/build/CMakeFiles/CMakeTmp</p><p><br></p><p>Run Build Command:"/usr/bin/make" "cmTryCompileExec1280293769/fast"</p><p>/Applications/Xcode.app/Contents/Developer/usr/bin/make -f CMakeFiles/cmTryCompileExec1280293769.dir/build.make CMakeFiles/cmTryCompileExec1280293769.dir/build</p><p>/usr/local/Cellar/cmake/3.1.0/bin/cmake -E cmake_progress_report /Users/meiryanovich/Documents/ws_game_server/libs/libwebsockets/libwebsockets-master/build/CMakeFiles/CMakeTmp/CMakeFiles 1</p><p>Building C object CMakeFiles/cmTryCompileExec1280293769.dir/CheckFunctionExists.c.o</p><p>/usr/bin/cc  -DKEYWORD=__inline -DCHECK_FUNCTION_EXISTS=execvpe -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk   -o CMakeFiles/cmTryCompileExec1280293769.dir/CheckFunctionExists.c.o   -c /usr/local/Cellar/cmake/3.1.0/share/cmake/Modules/CheckFunctionExists.c</p><p>Linking C executable cmTryCompileExec1280293769</p><p>/usr/local/Cellar/cmake/3.1.0/bin/cmake -E cmake_link_script CMakeFiles/cmTryCompileExec1280293769.dir/link.txt --verbose=1</p><p>/usr/bin/cc   -DCHECK_FUNCTION_EXISTS=execvpe -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk -Wl,-search_paths_first -Wl,-headerpad_max_install_names  CMakeFiles/cmTryCompileExec1280293769.dir/CheckFunctionExists.c.o  -o cmTryCompileExec1280293769  </p><p>Undefined symbols for architecture x86_64:</p><p>  "_execvpe", referenced from:</p><p>      _main in CheckFunctionExists.c.o</p><p>ld: symbol(s) not found for architecture x86_64</p><p>clang: error: linker command failed with exit code 1 (use -v to see invocation)</p><p>make[1]: *** [cmTryCompileExec1280293769] Error 1</p><p>make: *** [cmTryCompileExec1280293769/fast] Error 2</p><p><br></p><p><br></p><p>Determining if the function _snprintf exists failed with the following output:</p><p>Change Dir: /Users/meiryanovich/Documents/ws_game_server/libs/libwebsockets/libwebsockets-master/build/CMakeFiles/CMakeTmp</p><p><br></p><p>Run Build Command:"/usr/bin/make" "cmTryCompileExec149758955/fast"</p><p>/Applications/Xcode.app/Contents/Developer/usr/bin/make -f CMakeFiles/cmTryCompileExec149758955.dir/build.make CMakeFiles/cmTryCompileExec149758955.dir/build</p><p>/usr/local/Cellar/cmake/3.1.0/bin/cmake -E cmake_progress_report /Users/meiryanovich/Documents/ws_game_server/libs/libwebsockets/libwebsockets-master/build/CMakeFiles/CMakeTmp/CMakeFiles 1</p><p>Building C object CMakeFiles/cmTryCompileExec149758955.dir/CheckFunctionExists.c.o</p><p>/usr/bin/cc  -DKEYWORD=__inline -DCHECK_FUNCTION_EXISTS=_snprintf -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk   -o CMakeFiles/cmTryCompileExec149758955.dir/CheckFunctionExists.c.o   -c /usr/local/Cellar/cmake/3.1.0/share/cmake/Modules/CheckFunctionExists.c</p><p>Linking C executable cmTryCompileExec149758955</p><p>/usr/local/Cellar/cmake/3.1.0/bin/cmake -E cmake_link_script CMakeFiles/cmTryCompileExec149758955.dir/link.txt --verbose=1</p><p>/usr/bin/cc   -DCHECK_FUNCTION_EXISTS=_snprintf -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk -Wl,-search_paths_first -Wl,-headerpad_max_install_names  CMakeFiles/cmTryCompileExec149758955.dir/CheckFunctionExists.c.o  -o cmTryCompileExec149758955  </p><p>Undefined symbols for architecture x86_64:</p><p>  "__snprintf", referenced from:</p><p>      _main in CheckFunctionExists.c.o</p><p>ld: symbol(s) not found for architecture x86_64</p><p>clang: error: linker command failed with exit code 1 (use -v to see invocation)</p><p>make[1]: *** [cmTryCompileExec149758955] Error 1</p><p>make: *** [cmTryCompileExec149758955/fast] Error 2</p><p><br></p><p><br></p><p>Determining if the function _vsnprintf exists failed with the following output:</p><p>Change Dir: /Users/meiryanovich/Documents/ws_game_server/libs/libwebsockets/libwebsockets-master/build/CMakeFiles/CMakeTmp</p><p><br></p><p>Run Build Command:"/usr/bin/make" "cmTryCompileExec84506801/fast"</p><p>/Applications/Xcode.app/Contents/Developer/usr/bin/make -f CMakeFiles/cmTryCompileExec84506801.dir/build.make CMakeFiles/cmTryCompileExec84506801.dir/build</p><p>/usr/local/Cellar/cmake/3.1.0/bin/cmake -E cmake_progress_report /Users/meiryanovich/Documents/ws_game_server/libs/libwebsockets/libwebsockets-master/build/CMakeFiles/CMakeTmp/CMakeFiles 1</p><p>Building C object CMakeFiles/cmTryCompileExec84506801.dir/CheckFunctionExists.c.o</p><p>/usr/bin/cc  -DKEYWORD=__inline -DCHECK_FUNCTION_EXISTS=_vsnprintf -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk   -o CMakeFiles/cmTryCompileExec84506801.dir/CheckFunctionExists.c.o   -c /usr/local/Cellar/cmake/3.1.0/share/cmake/Modules/CheckFunctionExists.c</p><p>Linking C executable cmTryCompileExec84506801</p><p>/usr/local/Cellar/cmake/3.1.0/bin/cmake -E cmake_link_script CMakeFiles/cmTryCompileExec84506801.dir/link.txt --verbose=1</p><p>/usr/bin/cc   -DCHECK_FUNCTION_EXISTS=_vsnprintf -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk -Wl,-search_paths_first -Wl,-headerpad_max_install_names  CMakeFiles/cmTryCompileExec84506801.dir/CheckFunctionExists.c.o  -o cmTryCompileExec84506801  </p><p>Undefined symbols for architecture x86_64:</p><p>  "__vsnprintf", referenced from:</p><p>      _main in CheckFunctionExists.c.o</p><p>ld: symbol(s) not found for architecture x86_64</p><p>clang: error: linker command failed with exit code 1 (use -v to see invocation)</p><p>make[1]: *** [cmTryCompileExec84506801] Error 1</p><p>make: *** [cmTryCompileExec84506801/fast] Error 2</p><p><br></p><p><br></p><p>Determining if the include file in6addr.h exists failed with the following output:</p><p>Change Dir: /Users/meiryanovich/Documents/ws_game_server/libs/libwebsockets/libwebsockets-master/build/CMakeFiles/CMakeTmp</p><p><br></p><p>Run Build Command:"/usr/bin/make" "cmTryCompileExec3126646753/fast"</p><p>/Applications/Xcode.app/Contents/Developer/usr/bin/make -f CMakeFiles/cmTryCompileExec3126646753.dir/build.make CMakeFiles/cmTryCompileExec3126646753.dir/build</p><p>/usr/local/Cellar/cmake/3.1.0/bin/cmake -E cmake_progress_report /Users/meiryanovich/Documents/ws_game_server/libs/libwebsockets/libwebsockets-master/build/CMakeFiles/CMakeTmp/CMakeFiles 1</p><p>Building C object CMakeFiles/cmTryCompileExec3126646753.dir/CheckIncludeFile.c.o</p><p>/usr/bin/cc  -DKEYWORD=__inline -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk   -o CMakeFiles/cmTryCompileExec3126646753.dir/CheckIncludeFile.c.o   -c /Users/meiryanovich/Documents/ws_game_server/libs/libwebsockets/libwebsockets-master/build/CMakeFiles/CMakeTmp/CheckIncludeFile.c</p><p>/Users/meiryanovich/Documents/ws_game_server/libs/libwebsockets/libwebsockets-master/build/CMakeFiles/CMakeTmp/CheckIncludeFile.c:1:10: fatal error: 'in6addr.h' file not found</p><p>#include <in6addr.h></p><p>         ^</p><p>1 error generated.</p><p>make[1]: *** [CMakeFiles/cmTryCompileExec3126646753.dir/CheckIncludeFile.c.o] Error 1</p><p>make: *** [cmTryCompileExec3126646753/fast] Error 2</p><p><br></p><p><br></p><p>Determining if the include file sys/prctl.h exists failed with the following output:</p><p>Change Dir: /Users/meiryanovich/Documents/ws_game_server/libs/libwebsockets/libwebsockets-master/build/CMakeFiles/CMakeTmp</p><p><br></p><p>Run Build Command:"/usr/bin/make" "cmTryCompileExec3534415985/fast"</p><p>/Applications/Xcode.app/Contents/Developer/usr/bin/make -f CMakeFiles/cmTryCompileExec3534415985.dir/build.make CMakeFiles/cmTryCompileExec3534415985.dir/build</p><p>/usr/local/Cellar/cmake/3.1.0/bin/cmake -E cmake_progress_report /Users/meiryanovich/Documents/ws_game_server/libs/libwebsockets/libwebsockets-master/build/CMakeFiles/CMakeTmp/CMakeFiles 1</p><p>Building C object CMakeFiles/cmTryCompileExec3534415985.dir/CheckIncludeFile.c.o</p><p>/usr/bin/cc  -DKEYWORD=__inline -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk   -o CMakeFiles/cmTryCompileExec3534415985.dir/CheckIncludeFile.c.o   -c /Users/meiryanovich/Documents/ws_game_server/libs/libwebsockets/libwebsockets-master/build/CMakeFiles/CMakeTmp/CheckIncludeFile.c</p><p>/Users/meiryanovich/Documents/ws_game_server/libs/libwebsockets/libwebsockets-master/build/CMakeFiles/CMakeTmp/CheckIncludeFile.c:1:10: fatal error: 'sys/prctl.h' file not found</p><p>#include <sys/prctl.h></p><p>         ^</p><p>1 error generated.</p><p>make[1]: *** [CMakeFiles/cmTryCompileExec3534415985.dir/CheckIncludeFile.c.o] Error 1</p><p>make: *** [cmTryCompileExec3534415985/fast] Error 2</p><p><br></p><p><br></p><p>Determining if the include file vfork.h exists failed with the following output:</p><p>Change Dir: /Users/meiryanovich/Documents/ws_game_server/libs/libwebsockets/libwebsockets-master/build/CMakeFiles/CMakeTmp</p><p><br></p><p>Run Build Command:"/usr/bin/make" "cmTryCompileExec2021582694/fast"</p><p>/Applications/Xcode.app/Contents/Developer/usr/bin/make -f CMakeFiles/cmTryCompileExec2021582694.dir/build.make CMakeFiles/cmTryCompileExec2021582694.dir/build</p><p>/usr/local/Cellar/cmake/3.1.0/bin/cmake -E cmake_progress_report /Users/meiryanovich/Documents/ws_game_server/libs/libwebsockets/libwebsockets-master/build/CMakeFiles/CMakeTmp/CMakeFiles 1</p><p>Building C object CMakeFiles/cmTryCompileExec2021582694.dir/CheckIncludeFile.c.o</p><p>/usr/bin/cc  -DKEYWORD=__inline -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk   -o CMakeFiles/cmTryCompileExec2021582694.dir/CheckIncludeFile.c.o   -c /Users/meiryanovich/Documents/ws_game_server/libs/libwebsockets/libwebsockets-master/build/CMakeFiles/CMakeTmp/CheckIncludeFile.c</p><p>/Users/meiryanovich/Documents/ws_game_server/libs/libwebsockets/libwebsockets-master/build/CMakeFiles/CMakeTmp/CheckIncludeFile.c:1:10: fatal error: 'vfork.h' file not found</p><p>#include <vfork.h></p><p>         ^</p><p>1 error generated.</p><p>make[1]: *** [CMakeFiles/cmTryCompileExec2021582694.dir/CheckIncludeFile.c.o] Error 1</p><p>make: *** [cmTryCompileExec2021582694/fast] Error 2</p><p><br></p><p><span></span></p><p><br></p></div></div>
</blockquote></div><br></div>