cmake HAVE_DUP2 examples

gccxml/gccxml GCC/config_cmake/CMakeLists.txt :475

CHECK_FUNCTION_EXISTS(dup2 HAVE_DUP2)