securesystemslab/multicompiler
cmake/config-ix.cmake
:170
check_symbol_exists(posix_spawn spawn.h HAVE_POSIX_SPAWN)
check_symbol_exists(posix_spawn spawn.h HAVE_POSIX_SPAWN)
check_function_exists(posix_spawn HAVE_POSIX_SPAWN)
check_symbol_exists(posix_spawn spawn.h HAVE_POSIX_SPAWN)
check_symbol_exists(posix_spawn spawn.h HAVE_POSIX_SPAWN)
check_c_source_compiles("
#include <spawn.h>
#include <unistd.h>
int main(void)
{
int pipes[2];
int pid;
const char * args[] = {
\"/bin/false\",
NULL
};
const char * env[] = { NULL };
pipe(pipes);
posix_spawnattr_t attr;
posix_spawn_file_actions_t fa;
posix_spawnattr_init(&attr);
posix_spawn_file_actions_init(&fa);
posix_spawn_file_actions_addclose(&fa, pipes[0]);
posix_spawn_file_actions_adddup2(&fa, pipes[1], STDOUT_FILENO);
posix_spawn(&pid, args[0], &fa, &attr, (char * const *) args, (char * const *) env);
posix_spawnp(&pid, args[0], &fa, &attr, (char * const *) args, (char * const *) env);
posix_spawn_file_actions_destroy(&fa);
posix_spawnattr_destroy(&attr);
return 0;
}
" HAVE_POSIX_SPAWN)
check_symbol_exists(posix_spawn spawn.h HAVE_POSIX_SPAWN)
check_function_exists(posix_spawn HAVE_POSIX_SPAWN)
check_c_source_compiles("
#include <spawn.h>
#include <unistd.h>
int main(void)
{
int pipes[2];
int pid;
const char * args[] = {
\"/bin/false\",
NULL
};
const char * env[] = { NULL };
pipe(pipes);
posix_spawnattr_t attr;
posix_spawn_file_actions_t fa;
posix_spawnattr_init(&attr);
posix_spawn_file_actions_init(&fa);
posix_spawn_file_actions_addclose(&fa, pipes[0]);
posix_spawn_file_actions_adddup2(&fa, pipes[1], STDOUT_FILENO);
posix_spawn(&pid, args[0], &fa, &attr, (char * const *) args, (char * const *) env);
posix_spawnp(&pid, args[0], &fa, &attr, (char * const *) args, (char * const *) env);
posix_spawn_file_actions_destroy(&fa);
posix_spawnattr_destroy(&attr);
return 0;
}
" HAVE_POSIX_SPAWN)
check_symbol_exists(posix_spawn spawn.h HAVE_POSIX_SPAWN)
check_function_exists(posix_spawn HAVE_POSIX_SPAWN)
check_symbol_exists(posix_spawn spawn.h HAVE_POSIX_SPAWN)
check_c_source_compiles("
#include <spawn.h>
#include <unistd.h>
int main(void)
{
int pipes[2];
int pid;
const char * args[] = {
\"/bin/false\",
NULL
};
const char * env[] = { NULL };
pipe(pipes);
posix_spawnattr_t attr;
posix_spawn_file_actions_t fa;
posix_spawnattr_init(&attr);
posix_spawn_file_actions_init(&fa);
posix_spawn_file_actions_addclose(&fa, pipes[0]);
posix_spawn_file_actions_adddup2(&fa, pipes[1], STDOUT_FILENO);
posix_spawn(&pid, args[0], &fa, &attr, (char * const *) args, (char * const *) env);
posix_spawnp(&pid, args[0], &fa, &attr, (char * const *) args, (char * const *) env);
posix_spawn_file_actions_destroy(&fa);
posix_spawnattr_destroy(&attr);
return 0;
}
" HAVE_POSIX_SPAWN)
check_symbol_exists(posix_spawn spawn.h HAVE_POSIX_SPAWN)
check_function_exists(posix_spawn HAVE_POSIX_SPAWN)
check_symbol_exists(posix_spawn spawn.h HAVE_POSIX_SPAWN)
check_symbol_exists(posix_spawn spawn.h HAVE_POSIX_SPAWN)
check_symbol_exists(posix_spawn spawn.h HAVE_POSIX_SPAWN)
CHECK_CXX_SYMBOL_EXISTS(posix_spawn "spawn.h" HAVE_POSIX_SPAWN)
check_symbol_exists(posix_spawn spawn.h HAVE_POSIX_SPAWN)
check_function_exists(posix_spawn HAVE_POSIX_SPAWN)
check_symbol_exists(posix_spawn spawn.h HAVE_POSIX_SPAWN)
check_symbol_exists(posix_spawn spawn.h HAVE_POSIX_SPAWN)
check_function_exists(posix_spawn HAVE_POSIX_SPAWN)
check_symbol_exists(posix_spawn spawn.h HAVE_POSIX_SPAWN)
check_c_source_compiles("
#include <spawn.h>
#include <unistd.h>
int main(void)
{
int pipes[2];
int pid;
const char * args[] = {
\"/bin/false\",
NULL
};
const char * env[] = { NULL };
pipe(pipes);
posix_spawnattr_t attr;
posix_spawn_file_actions_t fa;
posix_spawnattr_init(&attr);
posix_spawn_file_actions_init(&fa);
posix_spawn_file_actions_addclose(&fa, pipes[0]);
posix_spawn_file_actions_adddup2(&fa, pipes[1], STDOUT_FILENO);
posix_spawn(&pid, args[0], &fa, &attr, (char * const *) args, (char * const *) env);
posix_spawnp(&pid, args[0], &fa, &attr, (char * const *) args, (char * const *) env);
posix_spawn_file_actions_destroy(&fa);
posix_spawnattr_destroy(&attr);
return 0;
}
" HAVE_POSIX_SPAWN)
check_c_source_compiles("
#include <spawn.h>
#include <unistd.h>
int main(void)
{
int pipes[2];
int pid;
const char * args[] = {
\"/bin/false\",
NULL
};
const char * env[] = { NULL };
pipe(pipes);
posix_spawnattr_t attr;
posix_spawn_file_actions_t fa;
posix_spawnattr_init(&attr);
posix_spawn_file_actions_init(&fa);
posix_spawn_file_actions_addclose(&fa, pipes[0]);
posix_spawn_file_actions_adddup2(&fa, pipes[1], STDOUT_FILENO);
posix_spawn(&pid, args[0], &fa, &attr, (char * const *) args, (char * const *) env);
posix_spawnp(&pid, args[0], &fa, &attr, (char * const *) args, (char * const *) env);
posix_spawn_file_actions_destroy(&fa);
posix_spawnattr_destroy(&attr);
return 0;
}
" HAVE_POSIX_SPAWN)
check_symbol_exists(posix_spawn spawn.h HAVE_POSIX_SPAWN)
check_symbol_exists(posix_spawn spawn.h HAVE_POSIX_SPAWN)
check_function_exists(posix_spawn HAVE_POSIX_SPAWN)
check_symbol_exists(posix_spawn spawn.h HAVE_POSIX_SPAWN)
check_symbol_exists(posix_spawn spawn.h HAVE_POSIX_SPAWN)
check_function_exists(posix_spawn HAVE_POSIX_SPAWN)
check_c_source_compiles("
#include <spawn.h>
#include <unistd.h>
int main(void)
{
int pipes[2];
int pid;
const char * args[] = {
\"/bin/false\",
NULL
};
const char * env[] = { NULL };
pipe(pipes);
posix_spawnattr_t attr;
posix_spawn_file_actions_t fa;
posix_spawnattr_init(&attr);
posix_spawn_file_actions_init(&fa);
posix_spawn_file_actions_addclose(&fa, pipes[0]);
posix_spawn_file_actions_adddup2(&fa, pipes[1], STDOUT_FILENO);
posix_spawn(&pid, args[0], &fa, &attr, (char * const *) args, (char * const *) env);
posix_spawnp(&pid, args[0], &fa, &attr, (char * const *) args, (char * const *) env);
posix_spawn_file_actions_destroy(&fa);
posix_spawnattr_destroy(&attr);
return 0;
}
" HAVE_POSIX_SPAWN)