FreeBSD 10.2-STABLE CMake 3.3.1 Our projects needs kqueue which means that sys/types.h and sys/event.h need to be found. Googling around also revealed that event.h is not self inclusive but depends on type.h. Not sure if that has to do with anything though.
CMakeLists.txt: check_include_file_cxx(sys/types.h HAVE_SYS_TYPES_H) if (HAVE_SYS_TYPES_H) check_include_file_cxx(sys/event.h HAVE_SYS_EVENT_H) endif() Result: cmake -G "Unix Makefiles" -H./ -B./build -- Looking for C++ include sys/types.h -- Looking for C++ include sys/types.h - found -- Looking for C++ include sys/event.h -- Looking for C++ include sys/event.h - not found Both files exist in /usr/include/sys. Tried with check_include_file too but same problem. Can anyone tell me if I am doing something wrong and any idea why event.h is not found? -- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Kitware offers various services to support the CMake community. For more information on each offering, please visit: CMake Support: http://cmake.org/cmake/help/support.html CMake Consulting: http://cmake.org/cmake/help/consulting.html CMake Training Courses: http://cmake.org/cmake/help/training.html Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/cmake