blob: 89b647970e3b71a94db450abda234f11a2889d20 [file] [log] [blame]
Misha Brukman0abaaf42003-08-11 22:29:36 +00001/*===- sysutils.h - Utilities to do low-level system stuff -------*- C -*--===*\
2 * *
3 * This file contains functions used to do a variety of low-level, often *
4 * system-specific, tasks. *
5 * *
6\*===----------------------------------------------------------------------===*/
7
8#ifndef SYSUTILS_H
9#define SYSUTILS_H
10
11typedef unsigned bool;
12enum { false = 0, true = 1 };
13
14/*
15 * isExecutableFile - This function returns true if the filename specified
16 * exists and is executable.
17 */
18bool isExecutableFile(const char *ExeFileName);
19
20/*
21 * FindExecutable - Find a named executable, giving the argv[0] of program
22 * being executed. This allows us to find another LLVM tool if it is built into
23 * the same directory, but that directory is neither the current directory, nor
24 * in the PATH. If the executable cannot be found, return an empty string.
25 */
26char *FindExecutable(const char *ExeName);
27
28#endif