forked from lcompilers/lpython
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathutils.h
More file actions
32 lines (24 loc) · 801 Bytes
/
utils.h
File metadata and controls
32 lines (24 loc) · 801 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#ifndef LPYTHON_UTILS_H
#define LPYTHON_UTILS_H
#include <string>
#include <libasr/utils.h>
namespace LCompilers::LPython {
void get_executable_path(std::string &executable_path, int &dirname_length);
std::string get_runtime_library_dir();
std::string get_runtime_library_header_dir();
bool is_directory(std::string path);
bool path_exists(std::string path);
#ifdef HAVE_LFORTRAN_LLVM
struct DynamicLibrary {
void *l;
DynamicLibrary(): l(nullptr) {}
};
void open_cpython_library(DynamicLibrary &l);
void close_cpython_library(DynamicLibrary &l);
void open_symengine_library(DynamicLibrary &l);
void close_symengine_library(DynamicLibrary &l);
#endif
// Decodes the exit status code of the process (in Unix)
int32_t get_exit_status(int32_t err);
} // LFortran
#endif // LPYTHON_UTILS_H