diff options
| author | dacctal <dacctal@symlinx.net> | 2026-05-02 08:38:13 +0000 |
|---|---|---|
| committer | dacctal <dacctal@symlinx.net> | 2026-05-02 08:38:13 +0000 |
| commit | 44eb727dc537403be092326639a5b7c6d7182146 (patch) | |
| tree | 1459603e69496400c22f53dcec67ec2c3348400a /include/lua_state.hh | |
| parent | c555d4c25b5526c37e94ee2c593f34bdf28b159e (diff) | |
fixed like half of everything idk, you can install stuff now
Diffstat (limited to 'include/lua_state.hh')
| -rw-r--r-- | include/lua_state.hh | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/include/lua_state.hh b/include/lua_state.hh index a8dfed8..5965093 100644 --- a/include/lua_state.hh +++ b/include/lua_state.hh @@ -1,17 +1,46 @@ #ifndef LUA_STATE #define LUA_STATE +#include <unordered_map> +#include <string> extern "C" { #include <luajit-2.1/lua.h> #include <luajit-2.1/lauxlib.h> #include <luajit-2.1/lualib.h> } +typedef struct { + std::string key; + std::string value; +} url; + +typedef struct { + std::string url; + std::string version; +} dependency; + +typedef struct { + url source; + std::unordered_map<std::string, dependency> dependencies; + int build; + int pre_install; + int install; + int post_install; +} repo; + +extern std::unordered_map<std::string, std::string> cached_install_directories; +extern std::unordered_map<std::string, repo> cached_repos; +extern std::unordered_map<std::string, int> cached_build_systems; + + void init_lua_state(); void free_lua_state(); lua_State* get_lua_state(); void cache_install_directories(); +bool repo_build(const char* repoository); +bool bldit(const char* target); +bool config_build(const char* path); void cache_repos(); void cache_build_systems(); |
